diff --git a/gtk-3.0/scss/_base.scss b/gtk-3.0/scss/_base.scss index 0080480..e9afca8 100755 --- a/gtk-3.0/scss/_base.scss +++ b/gtk-3.0/scss/_base.scss @@ -43,8 +43,8 @@ outline-color: alpha($selected_bg_color, 0.5); outline-style: dashed; outline-width: 1px; - outline-offset: -2px; - outline-radius: 2px; + outline-offset: -1px; + outline-radius: $roundness; } diff --git a/gtk-3.0/scss/_button.scss b/gtk-3.0/scss/_button.scss index c834f43..f5ff5c6 100755 --- a/gtk-3.0/scss/_button.scss +++ b/gtk-3.0/scss/_button.scss @@ -6,56 +6,59 @@ ! Buttons **********/ -%button { - padding: ($spacing - 1px) ($spacing + 1px); - border-width: 1px; - border-style: solid; - border-radius: $roundness; - transition: 100ms ease; - - -GtkWidget-focus-padding: 1; - -GtkWidget-focus-line-width: 0; -} - -%linked_button { - border-width: 1px; - border-style: solid; - border-radius: 0; - border-right-style: none; - border-left-style: none; - - &:first-child { - border-width: 1px; - border-radius: $roundness; - border-left-style: solid; - border-right-style: none; - border-top-right-radius: 0; - border-bottom-right-radius: 0; - - &:dir(rtl) { - border-left-style: none; - border-right-style: solid; - } - } - - &:last-child { - border-width: 1px; - border-radius: $roundness; - border-left-style: none; - border-right-style: solid; - border-top-left-radius: 0; - border-bottom-left-radius: 0; - - &:dir(rtl) { - border-left-style: solid; - border-right-style: none; - } - } - - &:only-child, &:first-child:only-child { +@include exports("button_extends") { + %button { + padding: ($spacing - 1px) ($spacing + 1px); border-width: 1px; border-style: solid; border-radius: $roundness; + transition: 100ms ease; + outline-color: transparent; + + -GtkWidget-focus-padding: 1; + -GtkWidget-focus-line-width: 0; + } + + %linked_button { + border-width: 1px; + border-style: solid; + border-radius: 0; + border-right-style: none; + border-left-style: none; + + &:first-child { + border-width: 1px; + border-radius: $roundness; + border-left-style: solid; + border-right-style: none; + border-top-right-radius: 0; + border-bottom-right-radius: 0; + + &:dir(rtl) { + border-left-style: none; + border-right-style: solid; + } + } + + &:last-child { + border-width: 1px; + border-radius: $roundness; + border-left-style: none; + border-right-style: solid; + border-top-left-radius: 0; + border-bottom-left-radius: 0; + + &:dir(rtl) { + border-left-style: solid; + border-right-style: none; + } + } + + &:only-child, &:first-child:only-child { + border-width: 1px; + border-style: solid; + border-radius: $roundness; + } } } @@ -184,7 +187,7 @@ &.default { @include button($selected_bg_color, $selected_fg_color); } - .linked & { @include linked_button($bg_color); } + &.linked, .linked & { @include linked_button($bg_color); } .spinbutton & { color: mix($text_color, $base_color, 0.4); @@ -198,7 +201,7 @@ &:insensitive { color: mix($text_color, $base_color, 0.7); - box-shadow: inset 1px 0 shade($base_color, 0.95); + box-shadow: inset 1px 0 shade($base_color, 0.85); } &:active, &:checked, &:hover { color: $text_color; } @@ -214,12 +217,12 @@ } .spinbutton.vertical & { - border: 1px solid shade($bg_color, 0.8); - border-radius: $roundness; - background-color: shade($bg_color, 1.08); - background-image: none; - color: $fg_color; - box-shadow: none; + border: 1px solid shade($bg_color, 0.8); + border-radius: $roundness; + background-color: shade($bg_color, 1.08); + background-image: none; + color: $fg_color; + box-shadow: none; &:hover { border-color: shade($bg_color, 0.7); @@ -248,7 +251,6 @@ &:first-child { border-width: 1px; border-bottom-width: 0; - border-radius: $roundness; border-bottom-right-radius: 0; border-bottom-left-radius: 0; } @@ -256,7 +258,6 @@ &:last-child { border-width: 1px; border-top-width: 0; - border-radius: $roundness; border-top-left-radius: 0; border-top-right-radius: 0; } diff --git a/gtk-3.0/scss/_functions.scss b/gtk-3.0/scss/_functions.scss index 0c81dcd..a072ca0 100755 --- a/gtk-3.0/scss/_functions.scss +++ b/gtk-3.0/scss/_functions.scss @@ -65,9 +65,11 @@ $modules: () !default; &:focus, &:hover { border-color: border_focus($color); } &:active, &:active:hover, - &:active:focus, &:active:hover:focus { border-color: border_active($color); } + &:active:focus, &:active:hover:focus, + &:checked, &:checked:hover, + &:checked:focus, &:checked:hover:focus { border-color: border_active($color); } &:insensitive { border-color: border_insensitive($color); } - &:active *:insensitive { border-color: border_normal($color); } + &:active:insensitive, &:checked:insensitive { border-color: border_normal($color); } } diff --git a/gtk-3.0/scss/_toolbar.scss b/gtk-3.0/scss/_toolbar.scss index cea024a..96b44b7 100755 --- a/gtk-3.0/scss/_toolbar.scss +++ b/gtk-3.0/scss/_toolbar.scss @@ -31,7 +31,7 @@ .button { @include button($bg, $fg); } - .linked .button { @include linked_button($bg); } + .button.linked, .linked .button { @include linked_button($bg); } GtkComboBox, .button { padding: $spacing - 1px; diff --git a/gtk-3.0/scss/_view.scss b/gtk-3.0/scss/_view.scss index aee0d6b..a8cf5b4 100644 --- a/gtk-3.0/scss/_view.scss +++ b/gtk-3.0/scss/_view.scss @@ -181,13 +181,13 @@ ***********/ @include exports("frame") { - .frame { border: none; } + .frame { + border: 1px solid border_normal($bg_color); - GtkScrolledWindow { - &.frame { border: 1px solid border_normal($bg_color); } - - /* avoid double borders when a viewport is packed into a GtkScrolledWindow */ - GtkViewport.frame { border: none; } + &.flat { border: none; } } + + /* avoid double borders when a viewport is packed into a GtkScrolledWindow */ + GtkScrolledWindow GtkViewport.frame { border: none; } }