package eu.theunitry.fabula.launcher;

import eu.theunitry.fabula.graphics.UNColor;

import javax.swing.*;
import javax.swing.border.EmptyBorder;
import java.awt.*;

public class UNLauncher extends JPanel
{

    private JLabel label;
    private JButton startBtn;
    private UNColor color;

    public UNLauncher()
    {
        this.color = new UNColor();

        this.setBackground(color.getPrimaryColor());
        this.setLayout(new BorderLayout());
        this.setBorder(new EmptyBorder(20, 20, 20, 20));

        label = new JLabel("Fabula");
        label.setForeground(Color.white);
        label.setFont(new Font(Font.SANS_SERIF, Font.PLAIN, 40));
        label.setHorizontalAlignment(JLabel.CENTER);

        startBtn = new JButton("Start");
        startBtn.setPreferredSize(new Dimension(200,100));

        /* Remove default styling */
        startBtn.setFocusPainted(false);
        startBtn.setBorderPainted(false);

        startBtn.setBackground(Color.white);
        startBtn.setFont(new Font(Font.SANS_SERIF, Font.PLAIN, 20));
        startBtn.setForeground(color.getPrimaryColor());
        startBtn.setOpaque(true);


        this.add(label, BorderLayout.CENTER);
        this.add(startBtn, BorderLayout.SOUTH);
    }

    public JPanel getPanel() {
        return this;
    }

}

@@ -351,16 +351,365 @@
 olor();%0A
+        this.label = new JLabel(%22Fabula%22);%0A        this.startBtn = new JButton(%22Start%22);%0A%0A        this.setStyling();%0A        %0A        this.add(label, BorderLayout.CENTER);%0A        this.add(startBtn, BorderLayout.SOUTH);%0A    %7D%0A%0A    public JPanel getPanel() %7B%0A        return this;%0A    %7D%0A%0A    private void setStyling()%0A    %7B%0A        /* Panel styling */
 %0A       
@@ -868,37 +868,27 @@
     
-label = new JLabel(%22Fabula%22);
+/* Label styling */
 %0A   
@@ -1058,40 +1058,28 @@
     
-startBtn = new JButton(%22Start%22);
+/* Button styling */
 %0A   
@@ -1138,130 +1138,8 @@
 ));%0A
-%0A        /* Remove default styling */%0A        startBtn.setFocusPainted(false);%0A        startBtn.setBorderPainted(false);%0A%0A
     
@@ -1340,25 +1340,24 @@
 true);%0A%0A
-%0A
         
 this.add
@@ -1352,151 +1352,117 @@
     
-this.add(label, BorderLayout.CENTER);%0A        this.add(startBtn, BorderLayout.SOUTH);%0A    %7D%0A%0A    public JPanel getPanel() %7B%0A        return this
+/* Reset default styling */%0A        startBtn.setFocusPainted(false);%0A        startBtn.setBorderPainted(false)
 ;%0A  

Clean up styling code for UNLauncher