diff --git a/clean-old-theme.sh b/clean-old-theme.sh deleted file mode 100755 index ba0edd50..00000000 --- a/clean-old-theme.sh +++ /dev/null @@ -1,55 +0,0 @@ -#! /usr/bin/env bash - -ROOT_UID=0 -DEST_DIR= - -# Destination directory -if [ "$UID" -eq "$ROOT_UID" ]; then - DEST_DIR="/usr/share/themes" -else - DEST_DIR="$HOME/.themes" -fi - -THEME_NAME=Colloid -THEME_VARIANTS=('' '-purple' '-pink' '-red' '-orange' '-yellow' '-green' '-teal' '-grey') -COLOR_VARIANTS=('' '-light' '-dark') -SIZE_VARIANTS=('' '-compact') -TYPE_VARIANTS=('' '-nord' '-dracula') -SCREEN_VARIANTS=('' '-hdpi' '-xhdpi') - -clean() { - local dest=${1} - local name=${2} - local theme=${3} - local color=${4} - local size=${5} - local type=${6} - local screen=${7} - - local THEME_DIR=${dest}/${name}${theme}${color}${size}${type}${screen} - - if [[ ${theme} == '' && ${color} == '' && ${size} == '' && ${type} == '' ]]; then - cleantheme='none' - elif [[ -d ${THEME_DIR} ]]; then - rm -rf ${THEME_DIR} - echo -e "Find: ${THEME_DIR} ! removing it ..." - fi -} - -clean_theme() { - for theme in "${themes[@]-${THEME_VARIANTS[@]}}"; do - for color in "${colors[@]-${COLOR_VARIANTS[@]}}"; do - for size in "${sizes[@]-${SIZE_VARIANTS[@]}}"; do - for type in "${types[@]-${TYPE_VARIANTS[@]}}"; do - for screen in "${screens[@]-${SCREEN_VARIANTS[@]}}"; do - clean "${dest:-${DEST_DIR}}" "${name:-${THEME_NAME}}" "${theme}" "${color}" "${size}" "${type}" "${screen}" - done - done - done - done - done -} - -clean_theme - -exit 0 diff --git a/install.sh b/install.sh index 596d9520..bfd62c4a 100755 --- a/install.sh +++ b/install.sh @@ -136,13 +136,6 @@ install() { sassc $SASSC_OPT "${SRC_DIR}/main/gtk-4.0/gtk${color}.scss" "${THEME_DIR}/gtk-4.0/gtk.css" sassc $SASSC_OPT "${SRC_DIR}/main/gtk-4.0/gtk-Dark.scss" "${THEME_DIR}/gtk-4.0/gtk-dark.css" - # link gtk4.0 for libadwaita - mkdir -p "${HOME}/.config/gtk-4.0" - rm -rf "${HOME}/.config/gtk-4.0/"{assets,gtk.css,gtk-dark.css} - ln -sf "${THEME_DIR}/gtk-4.0/assets" "${HOME}/.config/gtk-4.0/assets" - ln -sf "${THEME_DIR}/gtk-4.0/gtk.css" "${HOME}/.config/gtk-4.0/gtk.css" - ln -sf "${THEME_DIR}/gtk-4.0/gtk-dark.css" "${HOME}/.config/gtk-4.0/gtk-dark.css" - mkdir -p "${THEME_DIR}/cinnamon" cp -r "${SRC_DIR}/assets/cinnamon/common-assets" "${THEME_DIR}/cinnamon/assets" cp -r "${SRC_DIR}/assets/cinnamon/assets${ELSE_DARK:-}/"*'.svg' "${THEME_DIR}/cinnamon/assets" @@ -494,6 +487,72 @@ theme_tweaks() { fi } +link_libadwaita() { + local dest="${1}" + local name="${2}" + local theme="${3}" + local color="${4}" + local size="${5}" + local ctype="${6}" + + local THEME_DIR="${1}/${2}${3}${4}${5}${6}" + + [[ -L "${HOME}/.config/gtk-4.0/assets" ]] && rm -rf "${HOME}/.config/gtk-4.0/assets" + [[ -L "${HOME}/.config/gtk-4.0/gtk.css" ]] && rm -rf "${HOME}/.config/gtk-4.0/gtk.css" + [[ -L "${HOME}/.config/gtk-4.0/gtk-dark.css" ]] && rm -rf "${HOME}/.config/gtk-4.0/gtk-dark.css" + + echo -e "\nLink '$THEME_DIR/gtk-4.0' to '${HOME}/.config/gtk-4.0' for libadwaita..." + + mkdir -p "${HOME}/.config/gtk-4.0" + rm -rf "${HOME}/.config/gtk-4.0/"{assets,gtk.css,gtk-dark.css} + ln -sf "${THEME_DIR}/gtk-4.0/assets" "${HOME}/.config/gtk-4.0/assets" + ln -sf "${THEME_DIR}/gtk-4.0/gtk.css" "${HOME}/.config/gtk-4.0/gtk.css" + ln -sf "${THEME_DIR}/gtk-4.0/gtk-dark.css" "${HOME}/.config/gtk-4.0/gtk-dark.css" +} + +link_theme() { + for theme in "${themes[@]}"; do + for color in "${colors[1]}"; do + for size in "${sizes[@]}"; do + link_libadwaita "${dest:-$DEST_DIR}" "${_name:-$THEME_NAME}" "$theme" "$color" "$size" "$ctype" + done + done + done +} + +clean() { + local dest=${1} + local name=${2} + local theme=${3} + local color=${4} + local size=${5} + local type=${6} + local screen=${7} + + local THEME_DIR=${dest}/${name}${theme}${color}${size}${type}${screen} + + if [[ ${theme} == '' && ${color} == '' && ${size} == '' && ${type} == '' ]]; then + cleantheme='none' + elif [[ -d ${THEME_DIR} ]]; then + rm -rf ${THEME_DIR} + echo -e "Find: ${THEME_DIR} ! removing it ..." + fi +} + +clean_theme() { + for theme in '' '-purple' '-pink' '-red' '-orange' '-yellow' '-green' '-teal' '-grey'; do + for color in '' '-light' '-dark'; do + for size in '' '-compact'; do + for type in '' '-nord' '-dracula'; do + for screen in '' '-hdpi' '-xhdpi'; do + clean "${dest:-${DEST_DIR}}" "${name:-${THEME_NAME}}" "${theme}" "${color}" "${size}" "${type}" "${screen}" + done + done + done + done + done +} + install_theme() { for theme in "${themes[@]}"; do for color in "${colors[@]}"; do @@ -509,9 +568,7 @@ install_theme() { fi } -./clean-old-theme.sh - -install_package && tweaks_temp && gnome_shell_version && install_theme +clean_theme && install_package && tweaks_temp && gnome_shell_version && install_theme && link_theme echo echo Done. diff --git a/src/main/gnome-shell/gnome-shell-Dark.css b/src/main/gnome-shell/gnome-shell-Dark.css index cce37afd..14f8a515 100644 --- a/src/main/gnome-shell/gnome-shell-Dark.css +++ b/src/main/gnome-shell/gnome-shell-Dark.css @@ -2353,7 +2353,6 @@ StEntry StLabel.hint-text, .popup-menu .search-entry StLabel.hint-text { -arrow-rise: 6px; -arrow-box-shadow: none; background: transparent; - box-shadow: none; } .popup-menu { diff --git a/src/main/gnome-shell/gnome-shell-Light.css b/src/main/gnome-shell/gnome-shell-Light.css index 0cff1082..7ca5fe74 100644 --- a/src/main/gnome-shell/gnome-shell-Light.css +++ b/src/main/gnome-shell/gnome-shell-Light.css @@ -2353,7 +2353,6 @@ StEntry StLabel.hint-text, .popup-menu .search-entry StLabel.hint-text { -arrow-rise: 6px; -arrow-box-shadow: none; background: transparent; - box-shadow: none; } .popup-menu { diff --git a/src/main/gtk-3.0/gtk-Dark.css b/src/main/gtk-3.0/gtk-Dark.css index df98e59d..913e864f 100644 --- a/src/main/gtk-3.0/gtk-Dark.css +++ b/src/main/gtk-3.0/gtk-Dark.css @@ -2192,7 +2192,7 @@ tabbox > tab:checked, notebook > header tab:checked { transition: all 75ms cubic-bezier(0, 0, 0.2, 1); background-color: rgba(255, 255, 255, 0.15); color: #FFFFFF; - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); } tabbox > tab:checked:disabled, notebook > header tab:checked:disabled { diff --git a/src/main/gtk-3.0/gtk-Light.css b/src/main/gtk-3.0/gtk-Light.css index 860c56e8..806a2002 100644 --- a/src/main/gtk-3.0/gtk-Light.css +++ b/src/main/gtk-3.0/gtk-Light.css @@ -2192,7 +2192,7 @@ tabbox > tab:checked, notebook > header tab:checked { transition: all 75ms cubic-bezier(0, 0, 0.2, 1); background-color: white; color: rgba(0, 0, 0, 0.87); - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); } tabbox > tab:checked:disabled, notebook > header tab:checked:disabled { diff --git a/src/main/gtk-4.0/gtk-Dark.css b/src/main/gtk-4.0/gtk-Dark.css index 0b3fbaef..792e6d4d 100644 --- a/src/main/gtk-4.0/gtk-Dark.css +++ b/src/main/gtk-4.0/gtk-Dark.css @@ -881,7 +881,7 @@ windowcontrols button:not(.suggested-action):not(.destructive-action) label, fil padding: 0; } -placessidebar.sidebar row button.sidebar-button, notebook > header tab button.flat, popover.menu box.circular-buttons button.circular.image-button.model, spinbutton.vertical > button, spinbutton:not(.vertical) > button { +placessidebar.sidebar row button.sidebar-button, notebook > header > tabs > tab button.flat, popover.menu box.circular-buttons button.circular.image-button.model, spinbutton.vertical > button, spinbutton:not(.vertical) > button { min-height: 24px; min-width: 24px; padding: 0; @@ -2295,11 +2295,12 @@ magnifier { /************* * Notebooks * *************/ -tabbar tab, notebook > header tab { +tabbar tab, notebook > header > tabs > tab { transition: all 75ms cubic-bezier(0, 0, 0.2, 1), background-size 0ms, background-image 0ms; min-height: 24px; min-width: 24px; padding: 3px 12px; + margin: 0; border: none; outline: none; background-clip: padding-box; @@ -2310,25 +2311,26 @@ tabbar tab, notebook > header tab { background-color: transparent; } -tabbar tab:hover, notebook > header tab:hover { +tabbar tab:hover, notebook > header > tabs > tab:hover { background-color: rgba(255, 255, 255, 0.04); background-image: none; color: #FFFFFF; + box-shadow: none; } -tabbar tab:disabled, notebook > header tab:disabled { +tabbar tab:disabled, notebook > header > tabs > tab:disabled { color: rgba(255, 255, 255, 0.3); } -tabbar tab:checked, notebook > header tab:checked { +tabbar tab:checked, notebook > header > tabs > tab:checked { transition: all 75ms cubic-bezier(0, 0, 0.2, 1); background-color: rgba(255, 255, 255, 0.15); color: #FFFFFF; - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); background-image: none; } -tabbar tab:checked:disabled, notebook > header tab:checked:disabled { +tabbar tab:checked:disabled, notebook > header > tabs > tab:checked:disabled { color: rgba(255, 255, 255, 0.5); } @@ -2410,53 +2412,63 @@ notebook > header > tabs > arrow { border-radius: 6px; } -notebook > header tab > box { +notebook > header > tabs > tab > box { transition: background-color 75ms cubic-bezier(0, 0, 0.2, 1); margin: -6px -12px; padding: 6px 12px; } -notebook > header tab > box:drop(active) { +notebook > header > tabs > tab > box:drop(active) { background-color: rgba(255, 255, 255, 0.12); color: #FFFFFF; } -notebook > header tab button.flat:last-child { +notebook > header > tabs > tab button.flat:last-child { margin-left: 6px; margin-right: -6px; } -notebook > header tab button.flat:first-child { +notebook > header > tabs > tab button.flat:first-child { margin-left: -6px; margin-right: 6px; } -notebook > header tab button.close-button { +notebook > header > tabs > tab button.close-button { min-width: 24px; min-height: 24px; } -notebook > header.top tabs:not(:only-child):first-child, notebook > header.bottom tabs:not(:only-child):first-child { +notebook > header.top > tabs, notebook > header.bottom > tabs { + padding-left: 0; + padding-right: 0; +} + +notebook > header.top > tabs:not(:only-child):first-child, notebook > header.bottom > tabs:not(:only-child):first-child { margin-left: 0; } -notebook > header.top tabs:not(:only-child):last-child, notebook > header.bottom tabs:not(:only-child):last-child { +notebook > header.top > tabs:not(:only-child):last-child, notebook > header.bottom > tabs:not(:only-child):last-child { margin-right: 0; } -notebook > header.top tabs tab.reorderable-page, notebook > header.bottom tabs tab.reorderable-page { +notebook > header.top > tabs tab.reorderable-page, notebook > header.bottom > tabs tab.reorderable-page { border-style: solid; } -notebook > header.left tabs:not(:only-child):first-child, notebook > header.right tabs:not(:only-child):first-child { +notebook > header.left > tabs, notebook > header.right > tabs { + padding-top: 0; + padding-bottom: 0; +} + +notebook > header.left > tabs:not(:only-child):first-child, notebook > header.right > tabs:not(:only-child):first-child { margin-top: 0; } -notebook > header.left tabs:not(:only-child):last-child, notebook > header.right tabs:not(:only-child):last-child { +notebook > header.left > tabs:not(:only-child):last-child, notebook > header.right > tabs:not(:only-child):last-child { margin-bottom: 0; } -notebook > header.left tabs tab.reorderable-page, notebook > header.right tabs tab.reorderable-page { +notebook > header.left > tabs tab.reorderable-page, notebook > header.right > tabs tab.reorderable-page { border-style: solid; } @@ -2657,6 +2669,13 @@ scrollbar.right { border-left: 1px solid rgba(255, 255, 255, 0.12); } +scrollbar > range > trough { + border: none; + background: none; + padding: 0; + outline: none; +} + scrollbar > range > trough > slider { transition: background-color 75ms cubic-bezier(0, 0, 0.2, 1); min-width: 8px; diff --git a/src/main/gtk-4.0/gtk-Light.css b/src/main/gtk-4.0/gtk-Light.css index 10e11198..fb460e7e 100644 --- a/src/main/gtk-4.0/gtk-Light.css +++ b/src/main/gtk-4.0/gtk-Light.css @@ -881,7 +881,7 @@ windowcontrols button:not(.suggested-action):not(.destructive-action) label, fil padding: 0; } -placessidebar.sidebar row button.sidebar-button, notebook > header tab button.flat, popover.menu box.circular-buttons button.circular.image-button.model, spinbutton.vertical > button, spinbutton:not(.vertical) > button { +placessidebar.sidebar row button.sidebar-button, notebook > header > tabs > tab button.flat, popover.menu box.circular-buttons button.circular.image-button.model, spinbutton.vertical > button, spinbutton:not(.vertical) > button { min-height: 24px; min-width: 24px; padding: 0; @@ -2303,11 +2303,12 @@ magnifier { /************* * Notebooks * *************/ -tabbar tab, notebook > header tab { +tabbar tab, notebook > header > tabs > tab { transition: all 75ms cubic-bezier(0, 0, 0.2, 1), background-size 0ms, background-image 0ms; min-height: 24px; min-width: 24px; padding: 3px 12px; + margin: 0; border: none; outline: none; background-clip: padding-box; @@ -2318,25 +2319,26 @@ tabbar tab, notebook > header tab { background-color: transparent; } -tabbar tab:hover, notebook > header tab:hover { +tabbar tab:hover, notebook > header > tabs > tab:hover { background-color: rgba(0, 0, 0, 0.04); background-image: none; color: rgba(0, 0, 0, 0.87); + box-shadow: none; } -tabbar tab:disabled, notebook > header tab:disabled { +tabbar tab:disabled, notebook > header > tabs > tab:disabled { color: rgba(0, 0, 0, 0.26); } -tabbar tab:checked, notebook > header tab:checked { +tabbar tab:checked, notebook > header > tabs > tab:checked { transition: all 75ms cubic-bezier(0, 0, 0.2, 1); background-color: white; color: rgba(0, 0, 0, 0.87); - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); background-image: none; } -tabbar tab:checked:disabled, notebook > header tab:checked:disabled { +tabbar tab:checked:disabled, notebook > header > tabs > tab:checked:disabled { color: rgba(0, 0, 0, 0.38); } @@ -2418,53 +2420,63 @@ notebook > header > tabs > arrow { border-radius: 6px; } -notebook > header tab > box { +notebook > header > tabs > tab > box { transition: background-color 75ms cubic-bezier(0, 0, 0.2, 1); margin: -6px -12px; padding: 6px 12px; } -notebook > header tab > box:drop(active) { +notebook > header > tabs > tab > box:drop(active) { background-color: rgba(0, 0, 0, 0.12); color: rgba(0, 0, 0, 0.87); } -notebook > header tab button.flat:last-child { +notebook > header > tabs > tab button.flat:last-child { margin-left: 6px; margin-right: -6px; } -notebook > header tab button.flat:first-child { +notebook > header > tabs > tab button.flat:first-child { margin-left: -6px; margin-right: 6px; } -notebook > header tab button.close-button { +notebook > header > tabs > tab button.close-button { min-width: 24px; min-height: 24px; } -notebook > header.top tabs:not(:only-child):first-child, notebook > header.bottom tabs:not(:only-child):first-child { +notebook > header.top > tabs, notebook > header.bottom > tabs { + padding-left: 0; + padding-right: 0; +} + +notebook > header.top > tabs:not(:only-child):first-child, notebook > header.bottom > tabs:not(:only-child):first-child { margin-left: 0; } -notebook > header.top tabs:not(:only-child):last-child, notebook > header.bottom tabs:not(:only-child):last-child { +notebook > header.top > tabs:not(:only-child):last-child, notebook > header.bottom > tabs:not(:only-child):last-child { margin-right: 0; } -notebook > header.top tabs tab.reorderable-page, notebook > header.bottom tabs tab.reorderable-page { +notebook > header.top > tabs tab.reorderable-page, notebook > header.bottom > tabs tab.reorderable-page { border-style: solid; } -notebook > header.left tabs:not(:only-child):first-child, notebook > header.right tabs:not(:only-child):first-child { +notebook > header.left > tabs, notebook > header.right > tabs { + padding-top: 0; + padding-bottom: 0; +} + +notebook > header.left > tabs:not(:only-child):first-child, notebook > header.right > tabs:not(:only-child):first-child { margin-top: 0; } -notebook > header.left tabs:not(:only-child):last-child, notebook > header.right tabs:not(:only-child):last-child { +notebook > header.left > tabs:not(:only-child):last-child, notebook > header.right > tabs:not(:only-child):last-child { margin-bottom: 0; } -notebook > header.left tabs tab.reorderable-page, notebook > header.right tabs tab.reorderable-page { +notebook > header.left > tabs tab.reorderable-page, notebook > header.right > tabs tab.reorderable-page { border-style: solid; } @@ -2665,6 +2677,13 @@ scrollbar.right { border-left: 1px solid rgba(0, 0, 0, 0.12); } +scrollbar > range > trough { + border: none; + background: none; + padding: 0; + outline: none; +} + scrollbar > range > trough > slider { transition: background-color 75ms cubic-bezier(0, 0, 0.2, 1); min-width: 8px; diff --git a/src/sass/gtk/_common-3.0.scss b/src/sass/gtk/_common-3.0.scss index 05785bcf..d811bd97 100644 --- a/src/sass/gtk/_common-3.0.scss +++ b/src/sass/gtk/_common-3.0.scss @@ -1899,7 +1899,7 @@ popover.background { transition: $transition; background-color: if($variant == 'light', rgba($base, 1), rgba(white, 0.15)); color: $text; - box-shadow: 0 1px 3px rgba(black, 0.06); + box-shadow: 0 1px 3px rgba(black, 0.1); &:disabled { color: $text-disabled; } } diff --git a/src/sass/gtk/_common-4.0.scss b/src/sass/gtk/_common-4.0.scss index 56a142f2..c7f9c411 100644 --- a/src/sass/gtk/_common-4.0.scss +++ b/src/sass/gtk/_common-4.0.scss @@ -2124,6 +2124,7 @@ magnifier { min-height: $small-size; min-width: $small-size; padding: $space-size / 2 $space-size * 2; + margin: 0; border: none; outline: none; background-clip: padding-box; @@ -2137,6 +2138,7 @@ magnifier { background-color: $fill; background-image: none; color: $text; + box-shadow: none; } &:disabled { color: $text-secondary-disabled; } @@ -2145,7 +2147,7 @@ magnifier { transition: $transition; background-color: if($variant == 'light', rgba($base, 1), rgba(white, 0.15)); color: $text; - box-shadow: 0 1px 3px rgba(black, 0.06); + box-shadow: 0 1px 3px rgba(black, 0.1); background-image: none; &:disabled { color: $text-disabled; } @@ -2236,55 +2238,57 @@ notebook { } } - > tabs > arrow { - @extend %button-flat-simple; + > tabs { + > arrow { + @extend %button-flat-simple; - min-height: 16px; - min-width: 16px; - border-radius: $corner-radius; - } - - tab { - @extend %tabs_tab; - - // FIXME: The tab node doesn't have :drop(active), instead its child box has it. - > box { - transition: background-color $duration $ease-out; - margin: -$space-size -12px; - padding: $space-size 12px; - - &:drop(active) { - background-color: $divider; - color: $text; - } + min-height: 16px; + min-width: 16px; + border-radius: $corner-radius; } - // colors the button like the label, overridden otherwise - button.flat { - @extend %small-button; + > tab { + @extend %tabs_tab; - &:last-child { - margin-left: $space-size; - margin-right: $space-size - 12px; + // FIXME: The tab node doesn't have :drop(active), instead its child box has it. + > box { + transition: background-color $duration $ease-out; + margin: -$space-size -12px; + padding: $space-size 12px; + + &:drop(active) { + background-color: $divider; + color: $text; + } } - &:first-child { - margin-left: $space-size - 12px; - margin-right: $space-size; - } - } + // colors the button like the label, overridden otherwise + button.flat { + @extend %small-button; - button.close-button { - min-width: $small-size; - min-height: $small-size; + &:last-child { + margin-left: $space-size; + margin-right: $space-size - 12px; + } + + &:first-child { + margin-left: $space-size - 12px; + margin-right: $space-size; + } + } + + button.close-button { + min-width: $small-size; + min-height: $small-size; + } } } &.top, &.bottom { - tabs { - // padding-left: 8px; - // padding-right: 8px; + > tabs { + padding-left: 0; + padding-right: 0; &:not(:only-child) { &:first-child { margin-left: 0; } @@ -2298,9 +2302,9 @@ notebook { &.left, &.right { - tabs { - // padding-top: 8px; - // padding-bottom: 8px; + > tabs { + padding-top: 0; + padding-bottom: 0; &:not(:only-child) { &:first-child { margin-top: 0; } @@ -2563,22 +2567,29 @@ scrollbar { &.right { border-left: 1px solid $divider; } // slider - > range > trough > slider { - transition: background-color $duration $ease-out; - min-width: 8px; - min-height: 8px; - border: 4px solid transparent; - border-radius: $circular-radius; - background-clip: padding-box; - background-color: $text-disabled; - box-shadow: none; + > range > trough { + border: none; + background: none; + padding: 0; outline: none; - &:hover { background-color: $text-secondary; } + > slider { + transition: background-color $duration $ease-out; + min-width: 8px; + min-height: 8px; + border: 4px solid transparent; + border-radius: $circular-radius; + background-clip: padding-box; + background-color: $text-disabled; + box-shadow: none; + outline: none; - &:active { background-color: $text; } + &:hover { background-color: $text-secondary; } - &:disabled { background-color: $text-secondary-disabled; } + &:active { background-color: $text; } + + &:disabled { background-color: $text-secondary-disabled; } + } } > range.fine-tune {