[gtk+] Adwaita: Remove focus outlines from scrollbars and scales



commit 0d82de585cf6e6c4205f6238db27712726640b0e
Author: Timm Bäder <mail baedert org>
Date:   Wed Oct 25 09:34:52 2017 +0200

    Adwaita: Remove focus outlines from scrollbars and scales
    
    gtk3 didn't have focus outlines for these, so remove them for now.
    
    Sorry lapo.

 gtk/theme/Adwaita/_common.scss           |    7 +++++++
 gtk/theme/Adwaita/gtk-contained-dark.css |   30 +++++++++++++++++++++---------
 gtk/theme/Adwaita/gtk-contained.css      |   30 +++++++++++++++++++++---------
 3 files changed, 49 insertions(+), 18 deletions(-)
---
diff --git a/gtk/theme/Adwaita/_common.scss b/gtk/theme/Adwaita/_common.scss
index 607e1d3..40aaa14 100644
--- a/gtk/theme/Adwaita/_common.scss
+++ b/gtk/theme/Adwaita/_common.scss
@@ -2374,6 +2374,11 @@ scrollbar {
   &.left { border-right: 1px solid $borders_color; }
   &.right { border-left: 1px solid $borders_color; }
 
+  &:focus,
+  &:focus>box:focus,
+  &:focus>box:focus>range:focus,
+  &:focus>box:focus>range:focus>trough:focus{ outline: none };
+
   &:backdrop {
     background-color: $backdrop_scrollbar_bg_color;
     border-color: $backdrop_borders_color;
@@ -2880,6 +2885,8 @@ scale {
     margin: -9px;
   }
 
+  &:focus { outline: none; }
+
   // click-and-hold the slider to activate
   &.fine-tune {
     &.horizontal {
diff --git a/gtk/theme/Adwaita/gtk-contained-dark.css b/gtk/theme/Adwaita/gtk-contained-dark.css
index d7010c8..b77c052 100644
--- a/gtk/theme/Adwaita/gtk-contained-dark.css
+++ b/gtk/theme/Adwaita/gtk-contained-dark.css
@@ -30,6 +30,8 @@
 
 .view:selected:focus, iconview:selected:focus, .view:selected, iconview:selected, .view text:selected:focus, 
iconview text:selected:focus, textview text:selected:focus, .view text:selected, iconview text:selected, 
textview text:selected { border-radius: 3px; }
 
+.view, iconview, textview { outline: none; }
+
 textview border { background-color: #2b3032; }
 
 .rubberband, rubberband, flowbox rubberband, treeview.view rubberband, .content-view rubberband, 
.content-view .rubberband { border: 1px solid #184472; background-color: rgba(24, 68, 114, 0.2); }
@@ -98,7 +100,7 @@ spinbutton:not(.vertical) undershoot.right, entry undershoot.right { background-
 
 spinbutton.flat:focus:not(.vertical), spinbutton.flat:not(.vertical), entry.flat:focus, entry.flat { 
min-height: 0; padding: 2px; background-color: transparent; border-color: transparent; border-radius: 0; }
 
-spinbutton:focus:not(.vertical), entry:focus { box-shadow: inset 0 0 0 1px #215d9c; border-color: #0f2b48; }
+spinbutton:focus:not(.vertical), entry:focus { box-shadow: inset 0 0 0 1px #215d9c; border-color: #0f2b48; 
outline: none; }
 
 spinbutton:disabled:not(.vertical), entry:disabled { color: #919494; border-color: #1b1f20; 
background-color: #2d3234; box-shadow: none; }
 
@@ -108,13 +110,13 @@ spinbutton:backdrop:disabled:not(.vertical), entry:backdrop:disabled { color: #5
 
 spinbutton.error:not(.vertical), entry.error { color: #cc0000; border-color: #1a0000; }
 
-spinbutton.error:focus:not(.vertical), entry.error:focus { box-shadow: inset 0 0 0 1px #cc0000; 
border-color: #1a0000; }
+spinbutton.error:focus:not(.vertical), entry.error:focus { box-shadow: inset 0 0 0 1px #cc0000; 
border-color: #1a0000; outline: none; }
 
 spinbutton.error:not(.vertical) selection, entry.error selection { background-color: #cc0000; }
 
 spinbutton.warning:not(.vertical), entry.warning { color: #f57900; border-color: #432100; }
 
-spinbutton.warning:focus:not(.vertical), entry.warning:focus { box-shadow: inset 0 0 0 1px #f57900; 
border-color: #432100; }
+spinbutton.warning:focus:not(.vertical), entry.warning:focus { box-shadow: inset 0 0 0 1px #f57900; 
border-color: #432100; outline: none; }
 
 spinbutton.warning:not(.vertical) selection, entry.warning selection { background-color: #f57900; }
 
@@ -575,7 +577,7 @@ toolbar:not(.inline-toolbar):not(.osd) switch, toolbar:not(.inline-toolbar):not(
 
 .inline-toolbar { padding: 3px; border-width: 0 1px 1px; border-radius: 0  0 5px 5px; }
 
-searchbar, .location-bar { border-width: 0 0 1px; padding: 3px; }
+searchbar, .location-bar { border-width: 0 0 1px; padding: 0px; }
 
 .inline-toolbar, searchbar, .location-bar { border-style: solid; border-color: #1b1f20; background-color: 
#2c3133; }
 
@@ -984,6 +986,8 @@ scrollbar.left { border-right: 1px solid #1b1f20; }
 
 scrollbar.right { border-left: 1px solid #1b1f20; }
 
+scrollbar:focus, scrollbar:focus > box:focus, scrollbar:focus > box:focus > range:focus, scrollbar:focus > 
box:focus > range:focus > trough:focus { outline: none; }
+
 scrollbar:backdrop { background-color: #2c3133; border-color: #202425; transition: 200ms ease-out; }
 
 scrollbar slider { min-width: 6px; min-height: 6px; margin: -1px; border: 4px solid transparent; 
border-radius: 8px; background-clip: padding-box; background-color: #a3a6a5; }
@@ -996,11 +1000,11 @@ scrollbar slider:backdrop { background-color: #595d5f; }
 
 scrollbar slider:disabled { background-color: transparent; }
 
-scrollbar.fine-tune slider { min-width: 4px; min-height: 4px; }
+scrollbar range.fine-tune slider { min-width: 4px; min-height: 4px; }
 
-scrollbar.fine-tune.horizontal slider { border-width: 5px 4px; }
+scrollbar range.fine-tune.horizontal slider { border-width: 5px 4px; }
 
-scrollbar.fine-tune.vertical slider { border-width: 4px 5px; }
+scrollbar range.fine-tune.vertical slider { border-width: 4px 5px; }
 
 scrollbar.overlay-indicator:not(.dragging):not(.hovering) { border-color: transparent; opacity: 0.4; 
background-color: transparent; }
 
@@ -1203,6 +1207,8 @@ scale fill, scale highlight { margin: -1px; }
 
 scale slider { min-height: 18px; min-width: 18px; margin: -9px; }
 
+scale:focus { outline: none; }
+
 scale.fine-tune.horizontal { padding-top: 9px; padding-bottom: 9px; min-height: 16px; }
 
 scale.fine-tune.vertical { padding-left: 9px; padding-right: 9px; min-width: 16px; }
@@ -1474,9 +1480,11 @@ levelbar block.empty { background-color: transparent; border-color: rgba(238, 23
 levelbar block.empty:backdrop { border-color: rgba(145, 148, 148, 0.15); }
 
 /**************** Print dialog * */
-printdialog paper { color: #eeeeec; border: 1px solid #1b1f20; background: white; padding: 0; }
+printdialog drawing { color: #eeeeec; background: white; border: none; padding: 0; }
 
-printdialog paper:backdrop { color: #919494; border-color: #202425; }
+printdialog drawing:backdrop { color: #919494; border-color: #202425; }
+
+printdialog drawing paper { border: 1px solid #1b1f20; }
 
 printdialog .dialog-action-box { margin: 12px; }
 
@@ -1887,6 +1895,10 @@ cursor-handle.insertion-cursor:active:dir(ltr), cursor-handle.insertion-cursor:a
 
 .context-menu { font: initial; }
 
+shortcuts-section { margin: 20px; }
+
+.shortcuts-search-results { margin: 20px; border-spacing: 24px; }
+
 .keycap { min-width: 20px; min-height: 25px; margin-top: 2px; padding-bottom: 3px; padding-left: 6px; 
padding-right: 6px; color: #eeeeec; background-color: #232729; border: 1px solid; border-color: #1b1f20; 
border-radius: 5px; box-shadow: inset 0 -3px #1e2223; font-size: smaller; }
 
 .keycap:backdrop { background-color: #252a2c; color: #919494; transition: 200ms ease-out; }
diff --git a/gtk/theme/Adwaita/gtk-contained.css b/gtk/theme/Adwaita/gtk-contained.css
index a5f18f3..ab54fdb 100644
--- a/gtk/theme/Adwaita/gtk-contained.css
+++ b/gtk/theme/Adwaita/gtk-contained.css
@@ -30,6 +30,8 @@
 
 .view:selected:focus, iconview:selected:focus, .view:selected, iconview:selected, .view text:selected:focus, 
iconview text:selected:focus, textview text:selected:focus, .view text:selected, iconview text:selected, 
textview text:selected { border-radius: 3px; }
 
+.view, iconview, textview { outline: none; }
+
 textview border { background-color: #f4f4f3; }
 
 .rubberband, rubberband, flowbox rubberband, treeview.view rubberband, .content-view rubberband, 
.content-view .rubberband { border: 1px solid #2a76c6; background-color: rgba(42, 118, 198, 0.2); }
@@ -98,7 +100,7 @@ spinbutton:not(.vertical) undershoot.right, entry undershoot.right { background-
 
 spinbutton.flat:focus:not(.vertical), spinbutton.flat:not(.vertical), entry.flat:focus, entry.flat { 
min-height: 0; padding: 2px; background-color: transparent; border-color: transparent; border-radius: 0; }
 
-spinbutton:focus:not(.vertical), entry:focus { box-shadow: inset 0 0 0 1px #4a90d9; border-color: #4a90d9; }
+spinbutton:focus:not(.vertical), entry:focus { box-shadow: inset 0 0 0 1px #4a90d9; border-color: #4a90d9; 
outline: none; }
 
 spinbutton:disabled:not(.vertical), entry:disabled { color: #8b8e8f; border-color: #b6b6b3; 
background-color: #f1f1f1; box-shadow: none; }
 
@@ -108,13 +110,13 @@ spinbutton:backdrop:disabled:not(.vertical), entry:backdrop:disabled { color: #c
 
 spinbutton.error:not(.vertical), entry.error { color: #cc0000; border-color: #cc0000; }
 
-spinbutton.error:focus:not(.vertical), entry.error:focus { box-shadow: inset 0 0 0 1px #cc0000; 
border-color: #cc0000; }
+spinbutton.error:focus:not(.vertical), entry.error:focus { box-shadow: inset 0 0 0 1px #cc0000; 
border-color: #cc0000; outline: none; }
 
 spinbutton.error:not(.vertical) selection, entry.error selection { background-color: #cc0000; }
 
 spinbutton.warning:not(.vertical), entry.warning { color: #f57900; border-color: #f57900; }
 
-spinbutton.warning:focus:not(.vertical), entry.warning:focus { box-shadow: inset 0 0 0 1px #f57900; 
border-color: #f57900; }
+spinbutton.warning:focus:not(.vertical), entry.warning:focus { box-shadow: inset 0 0 0 1px #f57900; 
border-color: #f57900; outline: none; }
 
 spinbutton.warning:not(.vertical) selection, entry.warning selection { background-color: #f57900; }
 
@@ -583,7 +585,7 @@ toolbar:not(.inline-toolbar):not(.osd) switch, toolbar:not(.inline-toolbar):not(
 
 .inline-toolbar { padding: 3px; border-width: 0 1px 1px; border-radius: 0  0 5px 5px; }
 
-searchbar, .location-bar { border-width: 0 0 1px; padding: 3px; }
+searchbar, .location-bar { border-width: 0 0 1px; padding: 0px; }
 
 .inline-toolbar, searchbar, .location-bar { border-style: solid; border-color: #b6b6b3; background-color: 
#d9d9d7; }
 
@@ -992,6 +994,8 @@ scrollbar.left { border-right: 1px solid #b6b6b3; }
 
 scrollbar.right { border-left: 1px solid #b6b6b3; }
 
+scrollbar:focus, scrollbar:focus > box:focus, scrollbar:focus > box:focus > range:focus, scrollbar:focus > 
box:focus > range:focus > trough:focus { outline: none; }
+
 scrollbar:backdrop { background-color: #e1e1df; border-color: #c0c0bd; transition: 200ms ease-out; }
 
 scrollbar slider { min-width: 6px; min-height: 6px; margin: -1px; border: 4px solid transparent; 
border-radius: 8px; background-clip: padding-box; background-color: #787c7d; }
@@ -1004,11 +1008,11 @@ scrollbar slider:backdrop { background-color: #c3c4c4; }
 
 scrollbar slider:disabled { background-color: transparent; }
 
-scrollbar.fine-tune slider { min-width: 4px; min-height: 4px; }
+scrollbar range.fine-tune slider { min-width: 4px; min-height: 4px; }
 
-scrollbar.fine-tune.horizontal slider { border-width: 5px 4px; }
+scrollbar range.fine-tune.horizontal slider { border-width: 5px 4px; }
 
-scrollbar.fine-tune.vertical slider { border-width: 4px 5px; }
+scrollbar range.fine-tune.vertical slider { border-width: 4px 5px; }
 
 scrollbar.overlay-indicator:not(.dragging):not(.hovering) { border-color: transparent; opacity: 0.4; 
background-color: transparent; }
 
@@ -1223,6 +1227,8 @@ scale fill, scale highlight { margin: -1px; }
 
 scale slider { min-height: 18px; min-width: 18px; margin: -9px; }
 
+scale:focus { outline: none; }
+
 scale.fine-tune.horizontal { padding-top: 9px; padding-bottom: 9px; min-height: 16px; }
 
 scale.fine-tune.vertical { padding-left: 9px; padding-right: 9px; min-width: 16px; }
@@ -1494,9 +1500,11 @@ levelbar block.empty { background-color: transparent; border-color: rgba(46, 52,
 levelbar block.empty:backdrop { border-color: rgba(139, 142, 143, 0.15); }
 
 /**************** Print dialog * */
-printdialog paper { color: #2e3436; border: 1px solid #b6b6b3; background: white; padding: 0; }
+printdialog drawing { color: #2e3436; background: white; border: none; padding: 0; }
 
-printdialog paper:backdrop { color: #8b8e8f; border-color: #c0c0bd; }
+printdialog drawing:backdrop { color: #8b8e8f; border-color: #c0c0bd; }
+
+printdialog drawing paper { border: 1px solid #b6b6b3; }
 
 printdialog .dialog-action-box { margin: 12px; }
 
@@ -1907,6 +1915,10 @@ cursor-handle.insertion-cursor:active:dir(ltr), cursor-handle.insertion-cursor:a
 
 .context-menu { font: initial; }
 
+shortcuts-section { margin: 20px; }
+
+.shortcuts-search-results { margin: 20px; border-spacing: 24px; }
+
 .keycap { min-width: 20px; min-height: 25px; margin-top: 2px; padding-bottom: 3px; padding-left: 6px; 
padding-right: 6px; color: #2e3436; background-color: #ffffff; border: 1px solid; border-color: #cfcfcd; 
border-radius: 5px; box-shadow: inset 0 -3px #ededec; font-size: smaller; }
 
 .keycap:backdrop { background-color: #fcfcfc; color: #8b8e8f; transition: 200ms ease-out; }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]