dabo Commit
Revision 3946
Date: 2008-03-06 15:37:32 -0800 (Thu, 06 Mar 2008)
Author: Paul
Trac: http://svn.dabodev.com/trac/dabo/changeset/3946

Changed:
U   trunk/dabo/ui/uiwx/dGrid.py
U   trunk/dabo/ui/uiwx/gridRenderers.py

Log:
The grid renderer looks much better IMO without the extra buffer space around
it. I have a grid with a small rowheight and the checkbox wasn't fully 
displayed. This fixes that without (as far as I can tell) screwing anything
else up. 

Centered the checkbox vertically and horizontally in the dGrid.py test case.


Diff:
Modified: trunk/dabo/ui/uiwx/dGrid.py
===================================================================
--- trunk/dabo/ui/uiwx/dGrid.py 2008-03-05 22:00:04 UTC (rev 3945)
+++ trunk/dabo/ui/uiwx/dGrid.py 2008-03-06 23:37:32 UTC (rev 3946)
@@ -4616,7 +4616,8 @@
 
                self.addColumn(Name="Geek", DataField="coder", Caption="Geek?",
                                Order=10, DataType="bool", Width=60, 
Sortable=False,
-                               Searchable=False, Editable=True, 
HeaderFontBold=False)
+                               Searchable=False, Editable=True, 
HeaderFontBold=False,
+                               HorizontalAlignment="Center", 
VerticalAlignment="Center")
 
                col = dColumn(self, Name="Person", Order=20, DataField="name",
                                DataType="string", Width=200, 
Caption="Celebrity Name",

Modified: trunk/dabo/ui/uiwx/gridRenderers.py
===================================================================
--- trunk/dabo/ui/uiwx/gridRenderers.py 2008-03-05 22:00:04 UTC (rev 3945)
+++ trunk/dabo/ui/uiwx/gridRenderers.py 2008-03-06 23:37:32 UTC (rev 3946)
@@ -60,8 +60,8 @@
                        dc.SetBrush(wx.NullBrush) 
 
                a = attr.GetAlignment()
-               hbuffer = 5
-               wbuffer = 3
+               hbuffer = 0
+               wbuffer = 0
 
                if (a[0] & wx.ALIGN_RIGHT) == wx.ALIGN_RIGHT:
                        l = rect.width - bitmap.GetWidth() - wbuffer




_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: http://leafe.com/archives/byMID/dabo-dev/[EMAIL PROTECTED]

Reply via email to