|
@@ -6,6 +6,8 @@ import javax.swing.*;
|
|
|
public class Sidepane extends JPanel implements Observer
|
|
|
{
|
|
|
private Model model;
|
|
|
+ private Colours colours;
|
|
|
+ private JPanel thiccness;
|
|
|
|
|
|
// Bob the Builder this shit
|
|
|
public Sidepane(Model model)
|
|
@@ -14,6 +16,8 @@ public class Sidepane extends JPanel implements Observer
|
|
|
// changes.
|
|
|
this.model = model;
|
|
|
this.setPreferredSize(new Dimension(100, 300));
|
|
|
+ colours = new Colours();
|
|
|
+ this.add(colours);
|
|
|
model.addObserver(this);
|
|
|
}
|
|
|
|
|
@@ -27,3 +31,36 @@ public class Sidepane extends JPanel implements Observer
|
|
|
repaint();
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+private class Colours extends JPanel
|
|
|
+{
|
|
|
+ private jButton red;
|
|
|
+ private jButton green;
|
|
|
+ private jButton blue;
|
|
|
+ private jButton yellow;
|
|
|
+ private jButton purple;
|
|
|
+ private jButton orange;
|
|
|
+ private jButton cyan;
|
|
|
+ private jButton custom;
|
|
|
+
|
|
|
+ public colours()
|
|
|
+ {
|
|
|
+ this.setLayout(new GridLayout(0, 2));
|
|
|
+ red = new jButton("Red");
|
|
|
+ green = new jButton("Green");
|
|
|
+ blue = new jButton("Blue");
|
|
|
+ yellow = new jButton("Yellow");
|
|
|
+ purple = new jButton("Purple");
|
|
|
+ orange = new jButton("Orange");
|
|
|
+ cyan = new jButton("Cyan");
|
|
|
+ custom = new jButton("Custom");
|
|
|
+ this.add(red);
|
|
|
+ this.add(green);
|
|
|
+ this.add(blue);
|
|
|
+ this.add(yellow);
|
|
|
+ this.add(purple);
|
|
|
+ this.add(orange);
|
|
|
+ this.add(cyan);
|
|
|
+ this.add(custom);
|
|
|
+ }
|
|
|
+}
|