]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/demo/TreeListCtrl.py
add a little extra padding around text in new tab theme
[wxWidgets.git] / wxPython / demo / TreeListCtrl.py
index c41ab3160d72f690b79f361cffe6f0224e6f28b5..c5371334a288bf3047cd00bd5a716145b20bd609 100644 (file)
@@ -14,23 +14,19 @@ class TestPanel(wx.Panel):
 
         self.tree = gizmos.TreeListCtrl(self, -1, style =
                                         wx.TR_DEFAULT_STYLE
 
         self.tree = gizmos.TreeListCtrl(self, -1, style =
                                         wx.TR_DEFAULT_STYLE
-                                        #wx.TR_TWIST_BUTTONS
+                                        #| wx.TR_HAS_BUTTONS
+                                        #| wx.TR_TWIST_BUTTONS
                                         #| wx.TR_ROW_LINES
                                         #| wx.TR_ROW_LINES
+                                        #| wx.TR_COLUMN_LINES
                                         #| wx.TR_NO_LINES 
                                         | wx.TR_FULL_ROW_HIGHLIGHT
                                         #| wx.TR_NO_LINES 
                                         | wx.TR_FULL_ROW_HIGHLIGHT
-
-                                        # By default the style will be adjusted on
-                                        # Mac to use twisty buttons and no lines.  If
-                                        # you would rather control this yourself then
-                                        # add this style.
-                                        #| wx.TR_DONT_ADJUST_MAC
                                    )
 
         isz = (16,16)
         il = wx.ImageList(isz[0], isz[1])
         fldridx     = il.Add(wx.ArtProvider_GetBitmap(wx.ART_FOLDER,      wx.ART_OTHER, isz))
         fldropenidx = il.Add(wx.ArtProvider_GetBitmap(wx.ART_FILE_OPEN,   wx.ART_OTHER, isz))
                                    )
 
         isz = (16,16)
         il = wx.ImageList(isz[0], isz[1])
         fldridx     = il.Add(wx.ArtProvider_GetBitmap(wx.ART_FOLDER,      wx.ART_OTHER, isz))
         fldropenidx = il.Add(wx.ArtProvider_GetBitmap(wx.ART_FILE_OPEN,   wx.ART_OTHER, isz))
-        fileidx     = il.Add(wx.ArtProvider_GetBitmap(wx.ART_REPORT_VIEW, wx.ART_OTHER, isz))
+        fileidx     = il.Add(wx.ArtProvider_GetBitmap(wx.ART_NORMAL_FILE, wx.ART_OTHER, isz))
         smileidx    = il.Add(images.getSmilesBitmap())
 
         self.tree.SetImageList(il)
         smileidx    = il.Add(images.getSmilesBitmap())
 
         self.tree.SetImageList(il)
@@ -85,7 +81,8 @@ class TestPanel(wx.Panel):
         pos = evt.GetPosition()
         item, flags, col = self.tree.HitTest(pos)
         if item:
         pos = evt.GetPosition()
         item, flags, col = self.tree.HitTest(pos)
         if item:
-            print flags, col, self.tree.GetItemText(item, col)
+            self.log.write('Flags: %s, Col:%s, Text: %s' %
+                           (flags, col, self.tree.GetItemText(item, col)))
 
     def OnSize(self, evt):
         self.tree.SetSize(self.GetSize())
 
     def OnSize(self, evt):
         self.tree.SetSize(self.GetSize())