Author: lluis
Date: 2008-01-25 11:16:20 -0500 (Fri, 25 Jan 2008)
New Revision: 93921
Modified:
trunk/stetic/ChangeLog
trunk/stetic/libsteticui/PropertyTree.cs
Log:
* libsteticui/PropertyTree.cs: Use a theme color for the property group
headers. Fixes bug #356244.
Modified: trunk/stetic/ChangeLog
===================================================================
--- trunk/stetic/ChangeLog 2008-01-25 16:14:42 UTC (rev 93920)
+++ trunk/stetic/ChangeLog 2008-01-25 16:16:20 UTC (rev 93921)
@@ -1,5 +1,10 @@
2008-01-25 Lluis Sanchez Gual <[EMAIL PROTECTED]>
+ * libsteticui/PropertyTree.cs: Use a theme color for the property group
+ headers. Fixes bug #356244.
+
+2008-01-25 Lluis Sanchez Gual <[EMAIL PROTECTED]>
+
* libstetic/wrapper/Label.cs: Fix generation of MnemonicWidget property
assignment.
* libstetic/wrapper/objects.xml: The default way of
Modified: trunk/stetic/libsteticui/PropertyTree.cs
===================================================================
--- trunk/stetic/libsteticui/PropertyTree.cs 2008-01-25 16:14:42 UTC (rev
93920)
+++ trunk/stetic/libsteticui/PropertyTree.cs 2008-01-25 16:16:20 UTC (rev
93921)
@@ -306,15 +306,14 @@
PropertyDescriptor property;
object instance;
int rowHeight;
- Gdk.Color darkColor;
PropertyEditorCell editorCell;
bool sensitive;
bool visible;
+ TreeView tree;
public CellRendererProperty (TreeView tree)
{
- darkColor = tree.Style.Backgrounds [(int)
Gtk.StateType.Normal];
-
+ this.tree = tree;
Xalign = 0;
Xpad = 3;
@@ -329,7 +328,7 @@
this.instance = instance;
this.property = property;
if (property == null)
- this.CellBackgroundGdk = darkColor;
+ this.CellBackgroundGdk = tree.Style.MidColors
[(int)Gtk.StateType.Normal];
else
this.CellBackground = null;
@@ -407,9 +406,9 @@
class CellRendererPropertyGroup: CellRendererText
{
+ TreeView tree;
Pango.Layout layout;
bool isGroup;
- Gdk.Color darkColor;
bool sensitive;
public bool IsGroup {
@@ -417,7 +416,7 @@
set {
isGroup = value;
if (value)
- this.CellBackgroundGdk = darkColor;
+ this.CellBackgroundGdk =
tree.Style.MidColors [(int)Gtk.StateType.Normal];
else
this.CellBackground = null;
}
@@ -430,9 +429,9 @@
public CellRendererPropertyGroup (TreeView tree)
{
+ this.tree = tree;
layout = new Pango.Layout (tree.PangoContext);
layout.Wrap = Pango.WrapMode.Char;
- darkColor = tree.Style.Backgrounds [(int)
Gtk.StateType.Normal];
Pango.FontDescription des =
tree.Style.FontDescription.Copy();
layout.FontDescription = des;
@@ -485,7 +484,7 @@
window.DrawLayout (widget.Style.TextGC (state),
x, y, layout);
int bx = background_area.X +
background_area.Width - 1;
Gdk.GC gc = new Gdk.GC (window);
- gc.RgbFgColor = darkColor;
+ gc.RgbFgColor = tree.Style.MidColors
[(int)Gtk.StateType.Normal];
window.DrawLine (gc, bx, background_area.Y, bx,
background_area.Y + background_area.Height);
}
}
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches