[gnome-calendar/calendar-editor] window: add a nice style to the calendar listbox
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calendar/calendar-editor] window: add a nice style to the calendar listbox
- Date: Fri, 1 May 2015 16:57:09 +0000 (UTC)
commit 33711e87c116ec297db38a26ecad7622693bda7b
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Fri May 1 13:56:45 2015 -0300
window: add a nice style to the calendar listbox
data/theme/gtk-styles.css | 4 ++++
src/gcal-window.c | 7 +++++++
2 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/data/theme/gtk-styles.css b/data/theme/gtk-styles.css
index 0f6a577..b411897 100644
--- a/data/theme/gtk-styles.css
+++ b/data/theme/gtk-styles.css
@@ -227,3 +227,7 @@ GcalEventWidget.color-light:backdrop {
.calendar-list {
background-color: transparent;
}
+
+.calendar-list > GtkListBoxRow{
+ border-radius: 4px;
+}
diff --git a/src/gcal-window.c b/src/gcal-window.c
index 9c2a36c..7e848cf 100644
--- a/src/gcal-window.c
+++ b/src/gcal-window.c
@@ -820,11 +820,18 @@ make_row_from_source (GcalWindow *window,
{
GcalWindowPrivate *priv = gcal_window_get_instance_private (window);
GtkWidget *label, *icon, *separator, *checkbox, *box, *row;
+ GtkStyleContext *context;
GdkPixbuf *pixbuf;
GdkRGBA color;
row = gtk_list_box_row_new ();
+ /* apply some nice styling */
+ context = gtk_widget_get_style_context (row);
+ gtk_style_context_add_class (context, "button");
+ gtk_style_context_add_class (context, "flat");
+ gtk_style_context_add_class (context, "menuitem");
+
/* main box */
box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 12);
gtk_container_set_border_width (GTK_CONTAINER (box), 6);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]