[Patches] [ python-Patches-1462222 ] Functioning Tix.Grid
SourceForge.net
noreply at sourceforge.net
Fri Mar 31 18:31:20 CEST 2006
Patches item #1462222, was opened at 2006-03-31 19:28
Message generated for change (Comment added) made by tzot
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1462222&group_id=5470
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Tkinter
Group: Python 2.5
Status: Open
Resolution: None
Priority: 5
Submitted By: Christos Georgiou (tzot)
Assigned to: Martin v. Löwis (loewis)
Summary: Functioning Tix.Grid
Initial Comment:
This patch to Tix.py provides the basic functionality
needed for the tixGrid widget to work in Tix
applications. As I unravel the Tix C / Tcl/Tk code and
find out what more functionality is available, I will
update the patch.
There will be an associated patch providing a module to
be used with tixwidgets.py as a demo.
----------------------------------------------------------------------
>Comment By: Christos Georgiou (tzot)
Date: 2006-03-31 19:31
Message:
Logged In: YES
user_id=539787
Here follows code (testgrid.py) I use to test the patched
Tix.py, used as 'python -i testgrid.py'
###
import Tix as tk
from pprint import pprint
r= tk.Tk()
r.title("test")
l=tk.Label(r, name="a_label")
l.pack()
class MyGrid(tk.Grid):
def __init__(self, *args, **kwargs):
kwargs['editnotify']= self.editnotify
tk.Grid.__init__(self, *args, **kwargs)
def editnotify(self, x, y):
return True
g = MyGrid(r, name="a_grid", selectunit="cell")
g.pack(fill=tk.BOTH)
for x in xrange(5):
for y in xrange(5):
g.set(x,y,text=str((x,y)))
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1462222&group_id=5470
More information about the Patches
mailing list