[gtksourceview/wip/chergert/gsv-gtk4] informative: use "other" for success color styling
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview/wip/chergert/gsv-gtk4] informative: use "other" for success color styling
- Date: Wed, 9 Sep 2020 23:56:21 +0000 (UTC)
commit 0dd500180d1145a971aa47ff74f7cee23c5c4b9a
Author: Christian Hergert <chergert redhat com>
Date: Wed Sep 9 16:56:14 2020 -0700
informative: use "other" for success color styling
This makes the INFO style more of a default type thing (which it is meant
for).
gtksourceview/GtkSourceView.css | 4 ++--
gtksourceview/gtksourceinformative.c | 4 ++++
2 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/gtksourceview/GtkSourceView.css b/gtksourceview/GtkSourceView.css
index ca514674..67d18c51 100644
--- a/gtksourceview/GtkSourceView.css
+++ b/gtksourceview/GtkSourceView.css
@@ -128,14 +128,14 @@ GtkSourceAssistant.informative.error image {
background-color: shade(@error_color, 0.8);
}
-GtkSourceAssistant.informative.info {
+GtkSourceAssistant.informative.other {
background-color: @success_color;
color: @theme_selected_fg_color;
border-color: shade(@success_color, 0.8);
text-shadow: 0 1px shade(@success_color, 0.8);
-gtk-icon-shadow: 0 1px shade(@success_color, 0.8);
}
-GtkSourceAssistant.informative.info image {
+GtkSourceAssistant.informative.other image {
background-color: shade(@success_color, 0.8);
}
diff --git a/gtksourceview/gtksourceinformative.c b/gtksourceview/gtksourceinformative.c
index 97bf3f60..ed26f50a 100644
--- a/gtksourceview/gtksourceinformative.c
+++ b/gtksourceview/gtksourceinformative.c
@@ -89,6 +89,7 @@ gtk_source_informative_set_message_type (GtkSourceInformative *self,
gtk_widget_remove_css_class (GTK_WIDGET (self), "info");
gtk_widget_remove_css_class (GTK_WIDGET (self), "question");
gtk_widget_remove_css_class (GTK_WIDGET (self), "warning");
+ gtk_widget_remove_css_class (GTK_WIDGET (self), "other");
switch (priv->message_type)
{
@@ -109,6 +110,9 @@ gtk_source_informative_set_message_type (GtkSourceInformative *self,
break;
case GTK_MESSAGE_OTHER:
+ gtk_widget_add_css_class (GTK_WIDGET (self), "other");
+ break;
+
default:
break;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]