#17 Luotu custom label luokka, otettu uudet säädöt käyttöön mahdollisimman monessa paikkaa
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
package fi.lpam.gui.elementit;
|
||||
|
||||
import javafx.scene.control.Label;
|
||||
import javafx.scene.text.Font;
|
||||
|
||||
public class FontLabel extends Label {
|
||||
public FontLabel(Font font, String text) {
|
||||
super(text);
|
||||
this.setFont(font);
|
||||
}
|
||||
}
|
||||
@@ -18,10 +18,12 @@ public class TabPohja extends StackPane {
|
||||
public static String oletusStyle;
|
||||
public static Font buttonFont;
|
||||
public static Font tekstiFont;
|
||||
public static double spacing;
|
||||
|
||||
public TabPohja() {
|
||||
Properties prop = Main.properties;
|
||||
oletusInsets = new Insets(Double.parseDouble(prop.getProperty("insets")));
|
||||
spacing = Double.parseDouble(prop.getProperty("insets"));
|
||||
oletusStyle = "-fx-background-color: " + prop.getProperty("taustaVari") + ";";
|
||||
buttonFont = Font.font(prop.getProperty("buttonFontti"), FontWeight.BOLD, Double.parseDouble(prop.getProperty("buttonFonttiKoko")));
|
||||
tekstiFont = Font.font(prop.getProperty("tekstiFontti"), FontWeight.NORMAL, Double.parseDouble(prop.getProperty("tekstiFonttiKoko")));
|
||||
|
||||
Reference in New Issue
Block a user