-
- toggle_rect.x += style->xthickness;
- toggle_rect.y += style->ythickness;
- toggle_rect.width -= style->xthickness * 2;
- toggle_rect.height -= style->ythickness * 2;
-
- if (state == GTK_STATE_INSENSITIVE)
+ GtkBorder border = { 1, 1, 1, 1 };
+
+#if 0
+ /* FIXME: for some reason calling gtk_style_context_get_border
+ * makes the icon only visible on hover, so use border = 1
+ * for now as a workaround
+ */
+ gtk_style_context_get_border (context, state, &border);
+#endif
+
+ toggle_rect.x += border.left;
+ toggle_rect.y += border.top;
+ toggle_rect.width -= (border.left + border.right);
+ toggle_rect.height -= (border.top + border.bottom);
+
+ if (state & GTK_STATE_FLAG_INSENSITIVE)