Re: Setting default option values for Tkinter widgets

2005-03-05 Thread [EMAIL PROTECTED]
yep, that works better under Windows.   Pretty obscure use of Python,
though! :-)

S

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Setting default option values for Tkinter widgets

2005-03-04 Thread [EMAIL PROTECTED]
Eric, your tagline doesn't parse correctly on my Python 2.4 shell.

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Setting default option values for Tkinter widgets

2005-03-04 Thread Kent Johnson
Steve Holden wrote:
[EMAIL PROTECTED] wrote:
Eric, your tagline doesn't parse correctly on my Python 2.4 shell.
So, are you using Windows?
If you interchange single and double quotes it works on Windows too
python -c print ''.join([chr(154 - ord(c)) for c in 
'U(17zX(%,5.z^5(17l8(%,5.Z*(93-965$l7+-'])
Kent
--
http://mail.python.org/mailman/listinfo/python-list


Setting default option values for Tkinter widgets

2005-03-03 Thread Harlin Seritt
There are certain options for Tkinter widgets that have default values
that I don't much care for (borderwidth, font come to mind) and
continuously change when I'm building interfaces. With a bit of
tweaking I have been able to give the widgets a look that rivals the
best of them. However, I get tired of doing this when I'm writing code
and would like a way that I could universally change them on my system.
I have tried to find where in the class files (Tkinter.py) that I can
change these and haven't been able to find them. Are there certain
lines in certain files/modules/classes that I can change the values for
these things like font, border, etc.?

Thanks,

Harlin

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Setting default option values for Tkinter widgets

2005-03-03 Thread Eric Brunel
On 3 Mar 2005 03:02:48 -0800, Harlin Seritt [EMAIL PROTECTED] wrote:
There are certain options for Tkinter widgets that have default values
that I don't much care for (borderwidth, font come to mind) and
continuously change when I'm building interfaces. With a bit of
tweaking I have been able to give the widgets a look that rivals the
best of them. However, I get tired of doing this when I'm writing code
and would like a way that I could universally change them on my system.
I have tried to find where in the class files (Tkinter.py) that I can
change these and haven't been able to find them. Are there certain
lines in certain files/modules/classes that I can change the values for
these things like font, border, etc.?
tk allows to write your preffered options to an option file and to load it 
via the method option_readfile in your application.
For an example on how the options can be set, see:
http://mini.net/tcl/10424
The file should contain the arguments passed to option add commands.
For a reference on what options are available and how to specify them in an 
option file, see the tk manual pages here:
http://www.tcl.tk/man/tcl8.4/TkCmd/contents.htm
The name for the widget is usually the name of the corresponding Tkinter class; the name 
for the option is the second name found in the standard and widget-specific options 
sections in the man pages (named Database name in the section text). So for 
example, if you want to set the default select color for checkbuttons, you'll put in your 
option file a line:
*Checkbutton.selectColor: blue
HTH
--
python -c 'print .join([chr(154 - ord(c)) for c in 
U(17zX(%,5.z^5(17l8(%,5.Z*(93-965$l7+-])'
--
http://mail.python.org/mailman/listinfo/python-list