From 9d5609b1291d339f1fb445157c09abf3b3082b12 Mon Sep 17 00:00:00 2001 From: armin Date: Mon, 20 Nov 2017 15:32:24 +0100 Subject: [PATCH] Added highlighting of focused UI elements in windows and linux, for mac it is still missing (see issue #547) --- .../ui/src/main/resources/css/linux_theme.css | 25 +++++++++++++++++++ main/ui/src/main/resources/css/win_theme.css | 12 +++++++++ 2 files changed, 37 insertions(+) diff --git a/main/ui/src/main/resources/css/linux_theme.css b/main/ui/src/main/resources/css/linux_theme.css index fdb8d341b..91a7de6d8 100644 --- a/main/ui/src/main/resources/css/linux_theme.css +++ b/main/ui/src/main/resources/css/linux_theme.css @@ -108,6 +108,13 @@ -fx-text-fill: COLOR_TEXT_DISABLED; } +.button:focused, +.toggle-button:focused { + -fx-border-color: black; + -fx-border-insets: 2px; + -fx-border-style: dotted inside; +} + /**************************************************************************** * * * Segmented Buttons * @@ -157,6 +164,10 @@ -fx-padding: 1; } +.list-view:focused { + -fx-border-style: dotted inside; +} + .list-cell { -fx-padding: 0.5em; -fx-text-fill: COLOR_TEXT; @@ -243,6 +254,12 @@ -fx-background-color: COLOR_VGRAD_DARK; } +.tool-bar.list-related-toolbar .toggle-button:focused, +.tool-bar.list-related-toolbar .button:focused { + -fx-border-style: dotted inside; + -fx-border-color: black; +} + /******************************************************************************* * * * PopupMenu * @@ -333,6 +350,10 @@ .check-box:selected > .box > .mark { -fx-background-color: COLOR_TEXT; } +/* focused */ +.check-box:focused { + -fx-border-style: dotted inside; +} /* disabled: */ .check-box:disabled > .box { -fx-background-color: COLOR_BORDER, COLOR_BACKGROUND; @@ -355,6 +376,10 @@ -fx-text-fill: COLOR_TEXT; } +.choice-box:focused { + -fx-border-style: dotted inside; +} + .choice-box > .open-button > .arrow { -fx-background-color: transparent, COLOR_TEXT; -fx-background-insets: 0 0 -1 0, 0; diff --git a/main/ui/src/main/resources/css/win_theme.css b/main/ui/src/main/resources/css/win_theme.css index 6bf949b6c..4d360032c 100644 --- a/main/ui/src/main/resources/css/win_theme.css +++ b/main/ui/src/main/resources/css/win_theme.css @@ -161,6 +161,10 @@ -fx-padding: 1; } +.list-view:focused { + -fx-border-style: dotted inside; +} + .list-view > .virtual-flow > .scroll-bar:vertical{ -fx-background-insets: 0, 0 0 0 1; -fx-padding: -1 -1 -1 0; @@ -380,6 +384,10 @@ .check-box:armed > .box { -fx-border-color: COLOR_BORDER_FOCUS; } +/* focused */ +.check-box:focused { + -fx-border-style: dotted inside; +} /* selected: */ .check-box:selected > .box > .mark { -fx-background-color: black; @@ -406,6 +414,10 @@ -fx-text-fill: COLOR_TEXT; } +.choice-box:focused { + -fx-border-style: dotted inside; +} + .choice-box > .open-button > .arrow { -fx-background-color: transparent, COLOR_TEXT; -fx-background-insets: 0 0 -1 0, 0;