Skip to content

Commit

Permalink
* - Use libadwaita more
Browse files Browse the repository at this point in the history
  • Loading branch information
Lains committed Aug 20, 2021
1 parent d365bb3 commit 41d2cc1
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 195 deletions.
13 changes: 1 addition & 12 deletions build-aux/flatpak/io.github.lainsce.DotMatrix.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,17 +33,6 @@
"*.la"
],
"modules" : [
{
"name" : "pango",
"buildsystem" : "meson",
"sources" : [
{
"type" : "archive",
"url" : "https://download.gnome.org/sources/pango/1.48/pango-1.48.0.tar.xz",
"sha256" : "391f26f3341c2d7053e0fb26a956bd42360dadd825efe7088b1e9340a65e74e6"
}
]
},
{
"name": "libsass",
"sources": [
Expand Down Expand Up @@ -85,7 +74,7 @@
"sources" : [
{
"type" : "git",
"url" : "https://gitlab.gnome.org/exalm/libadwaita.git",
"url" : "https://gitlab.gnome.org/gnome/libadwaita.git",
"branch" : "main"
}
]
Expand Down
181 changes: 6 additions & 175 deletions data/app.css
Original file line number Diff line number Diff line change
@@ -1,184 +1,15 @@
@define-color accent_color #66c7ae;
@define-color accent_bg_color #72dec2;

headerbar {
background-image: none;
background-color: @theme_bg_color;
}

headerbar.flat {
border: none;
}

headerbar.flat:backdrop {
background-image: none;
background-color: @theme_base_color;
}

actionbar.flat box {
background-image: none;
border: none;
background-color: @theme_bg_color;
}

actionbar.flat:backdrop box {
background-image: none;
background-color: @theme_base_color;
}

box.flat {
background-image: none;
border: none;
background-color: @theme_bg_color;
}

box.flat:backdrop {
background-image: none;
background-color: @theme_base_color;
}

searchbar box {
background-image: none;
background-color: alpha(@theme_fg_color, 0.1);
}

.circular,
.circular button,
.image-button {
border-radius: 8px;
background: alpha(@theme_fg_color, 0.1);
border: none;
box-shadow: none;
transition: 100ms ease-in-out;
}

.circular:hover,
.toggle:checked,
.image-button:hover {
background: alpha(@theme_fg_color, 0.2);
}

.circular:active,
.toggle:active,
.image-button:active {
background: alpha(@theme_fg_color, 0.05);
box-shadow: inset 0 0 3px 0 alpha(@theme_fg_color, 0.5);
}

.toggle-button > button:hover {
background: alpha(@theme_fg_color, 0.2);
}

.toggle-button > button:active {
background: alpha(@theme_fg_color, 0.05);
box-shadow: inset 0 0 3px 0 alpha(@theme_fg_color, 0.5);
}

.color:not(.marks-after) {
border-radius: 8px;
min-width: 48px;
min-height: 24px;
background: alpha(@theme_fg_color, 0.1);
box-shadow: none;
}

.color:not(.marks-after) * {
min-width: 24px;
min-height: 16px;
border-radius: 4px;
border: none;
box-shadow: none;
}

.color:not(.marks-after):hover {
background: alpha(@theme_fg_color, 0.2);
}

.color:not(.marks-after):active {
background: alpha(@theme_fg_color, 0.05);
box-shadow: inset 0 0 3px 0 alpha(@theme_fg_color, 0.5);
}

.spinpill {
border-radius: 8px;
min-width: 48px;
min-height: 16px;
box-shadow: none;
}

.spinpill text {
margin-left: 6px;
}

.spinpill button {
box-shadow: none;
background: none;
border-radius: 8px;
}

.spinpill button:hover {
background: alpha(@theme_fg_color, 0.15);
}

.spinpill button:active {
background: alpha(@theme_fg_color, 0.2);
}

.rotated image {
-gtk-icon-transform: rotate(180deg);
}

.text-button,
.activatable {
background: alpha(@theme_fg_color, 0.1);
border: none;
box-shadow: none;
transition: 100ms ease-in-out;
}

.text-button:hover,
.activatable:hover {
background: alpha(@theme_fg_color, 0.2);
}

.text-button:active,
.activatable:hover {
background: alpha(@theme_fg_color, 0.05);
box-shadow: inset 0 0 3px 0 alpha(@theme_fg_color, 0.5);
}

.text-button.suggested-action {
background: mix(#1c71d8, alpha(@theme_bg_color, 0.2), 0.8);
color: @theme_fg_color;
border: 1px solid transparent;
box-shadow: none;
}

.text-button.suggested-action:disabled {
color: mix(#1c71d8, alpha(@theme_bg_color, 0.2), 0.5);
background: none;
border: 1px solid mix(#1c71d8, alpha(@theme_bg_color, 0.2), 0.5);
}

.text-button.suggested-action:hover {
background: mix(#1c71d8, alpha(@theme_bg_color, 0.2), 0.7);
}

.text-button.suggested-action:active,
.text-button.suggested-action:active:checked {
background: mix(#1c71d8, alpha(@theme_bg_color, 0.05), 0.9);
box-shadow: inset 0 0 3px 0 alpha(@theme_fg_color, 0.5);
}

.text-button.destructive-action {
background: mix(#e01b24, alpha(@theme_bg_color, 0.2), 0.8);
color: @theme_fg_color;
border: 1px solid transparent;
}

.text-button.destructive-action:hover {
background: mix(#e01b24, alpha(@theme_bg_color, 0.2), 0.7);
border-bottom: 1px solid @borders;
}

.text-button.destructive-action:active,
.text-button.destructive-action:active:checked {
background: mix(#e01b24, alpha(@theme_bg_color, 0.05), 0.9);
box-shadow: inset 0 0 3px 0 alpha(@theme_fg_color, 0.5);
.suggested-action {
color: black;
}
8 changes: 8 additions & 0 deletions data/io.github.lainsce.DotMatrix.appdata.xml.in
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@
<content_attribute id="money-gambling">none</content_attribute>
</content_rating>
<releases>
<release version="3.0.2" date="2021-08-20">
<description>
<p>Release: Cyan Sunset</p>
<ul>
<li>Changed: Using libadwaita recent UI styling.</li>
</ul>
</description>
</release>
<release version="3.0.1" date="2021-04-25">
<description>
<p>Release: A New UI Hope</p>
Expand Down
2 changes: 1 addition & 1 deletion meson.build
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
project('io.github.lainsce.DotMatrix', ['vala', 'c'], version: '3.0.1')
project('io.github.lainsce.DotMatrix', ['vala', 'c'], version: '3.0.2')
gnome = import('gnome')
i18n = import('i18n')

Expand Down
3 changes: 1 addition & 2 deletions po/it.po
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# ITALIAN TRANSLATION FOR DOT-MATRIX.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the com.github.lainsce.dot-matrix package.
# ALBANO BATTISTELLA <[email protected]>, 2021.
Expand All @@ -13,7 +12,7 @@ msgstr ""
"Language-Team: ITALIAN <[email protected]>\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"

#: src/MainWindow.vala:29
Expand Down
5 changes: 0 additions & 5 deletions src/MainWindow.vala
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,6 @@ namespace DotMatrix {
var theme = Gtk.IconTheme.get_for_display (Gdk.Display.get_default ());
theme.add_resource_path ("/io/github/lainsce/DotMatrix");

Gtk.StyleContext style = get_style_context ();
if (Config.PROFILE == "Devel") {
style.add_class ("devel");
}

// Actions
actions = new SimpleActionGroup ();
actions.add_action_entries (ACTION_ENTRIES, this);
Expand Down

0 comments on commit 41d2cc1

Please sign in to comment.