From 0334cd85d577d4ca9af183a072c63758c7ca653d Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Tue, 12 Dec 2017 09:21:44 +0100 Subject: [PATCH] Added #ids for menu items + re-set 'SubMenuStyleSheet' + improved fxml.model --- Classes/css/user/ContextBuilder.java | 4 ++-- Classes/css/user/SubMenuStyleSheet.java | 30 ++++++++++++------------- fxml/model.fxml | 14 ++++++------ 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a/Classes/css/user/ContextBuilder.java b/Classes/css/user/ContextBuilder.java index 527f2f9..1d4bc80 100644 --- a/Classes/css/user/ContextBuilder.java +++ b/Classes/css/user/ContextBuilder.java @@ -13,14 +13,14 @@ public class ContextBuilder{ /* (2) Base layout dimension */ Context.bind("header-height", 50); Context.bind("menu-width", 237); - Context.bind("submenu-width", 166); + Context.bind("submenu-width", 2); Context.bind("article-width", 800); Context.bind("article-height", 96); /* (3) Colors */ Context.bind("main-color", 63, 81, 181); Context.bind("menu-bg", 255, 255, 253); - Context.bind("submenu-bg", 250, 250, 250); + Context.bind("submenu-bg", 244, 244, 244); } diff --git a/Classes/css/user/SubMenuStyleSheet.java b/Classes/css/user/SubMenuStyleSheet.java index 742b319..16bdd8e 100644 --- a/Classes/css/user/SubMenuStyleSheet.java +++ b/Classes/css/user/SubMenuStyleSheet.java @@ -10,22 +10,22 @@ public class SubMenuStyleSheet{ public SubMenuStyleSheet(Node target) throws Exception{ /* (1) Set rules */ -// Ruleset.load(target) -// .add("top", Context.getInt("header-height")) -// .add("left", Context.getInt("menu-width")-3) -// .add("bottom", 0) -// -// .add("min-width", Context.getInt("submenu-width")) -// .add("max-width", Context.getInt("submenu-width")) -// -// .add("min-height", Context.getInt("screen-height") - Context.getInt("header-height")) -// .add("max-height", Context.getInt("screen-height") - Context.getInt("header-height")) -// -// .add("pref-width", Context.getInt("submenu-width")) -// .add("pref-height", Context.getInt("screen-height") - Context.getInt("header-height")) + Ruleset.load(target) + .add("top", Context.getInt("header-height")) + .add("left", Context.getInt("menu-width")-3) + .add("bottom", 0) + + .add("min-width", Context.getInt("submenu-width")) + .add("max-width", Context.getInt("submenu-width")) + + .add("min-height", Context.getInt("screen-height") - Context.getInt("header-height")) + .add("max-height", Context.getInt("screen-height") - Context.getInt("header-height")) -// .add("background-color", Context.getString("submenu-bg")) -// .apply(); + .add("pref-width", Context.getInt("submenu-width")) + .add("pref-height", Context.getInt("screen-height") - Context.getInt("header-height")) + + .add("background-color", Context.getString("submenu-bg")) + .apply(); } } diff --git a/fxml/model.fxml b/fxml/model.fxml index 27d63c8..e824e78 100644 --- a/fxml/model.fxml +++ b/fxml/model.fxml @@ -32,7 +32,7 @@ - + @@ -57,7 +57,7 @@ - + @@ -70,7 +70,7 @@ - + @@ -83,7 +83,7 @@ - + @@ -96,7 +96,7 @@ - + @@ -113,7 +113,7 @@ - + @@ -308,7 +308,7 @@ - +