basic gui implemented for week11 challenge.

This commit is contained in:
Josh Ashton
2023-11-15 10:14:25 -07:00
parent 23054afaba
commit edce1d4ff9
5 changed files with 136 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
import javax.swing.JPanel;
import java.awt.BorderLayout;
import java.awt.Color;
public class Panel extends JPanel {
private Color bg;
private Color fg;
public Panel(Color bg, Color fg) {
super();
this.bg = bg;
this.fg = fg;
init();
}
private void init() {
setBackground(bg);
setForeground(fg);
add(new Button("Example text", new Color(160, 32, 240), Color.WHITE));
}
}