Re: [Tutor] Control Variables and a Dictionary with a GUI Interface

2009-02-16 Thread Wayne Watson
ger than 2 minutes to put that together. :-) Alan Gauld wrote: "Wayne Watson" wrote The question here is how is sdict being used here in terms of its need within the GUI?  Probably if I had written the program from scratch, I would have made all these variables global to Sentin

[Tutor] Changing the Attribute of a Variable

2009-02-16 Thread Wayne Watson
"stop_time" ] = self.stop_time.strftime("%H:%M:%S") When reading the configuration file, how do I make sure that self.time_stop is really has the strftime attribute? -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39

Re: [Tutor] Changing the Attribute of a Variable

2009-02-16 Thread Wayne Watson
Google "x.foobar=123", example is a pretty narrow focus on explaining, at least, setattr. Yes, consistency is important here, but it may take some rewriting of the original code. wesley chun wrote: On Mon, Feb 16, 2009 at 8:24 PM, Wayne Watson wrote: I suspect I'm i

Re: [Tutor] Changing the Attribute of a Variable

2009-02-17 Thread Wayne Watson
Note that the diagnostic output in the image shows attributeError: 'str' object has no attribute 'strftime'. Let me see if I clarify what's really going on by including some of the code. In Sentinel_GUI, the mainloop, the code shows (hard coded default values): ... self.slowdown

Re: [Tutor] Changing the Attribute of a Variable

2009-02-17 Thread Wayne Watson
So far it has paid off in many learning dividends. ConfigObj, if not the Win stuff, may be attractive. Anyway, I'd like to proceed for the moment with this effort. Marc Tompkins wrote: On Tue, Feb 17, 2009 at 4:44 AM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: Note that the

Re: [Tutor] Changing the Attribute of a Variable

2009-02-17 Thread Wayne Watson
min=50, max=80, default=66)     FIformLength = integer(min=50, max=80, default=64) Maybe things are looking up for ConfigObj!!! Whoops footnote: I think I got you and Kent confused, but I think I'm on track here with thinking of the right person. I posted the two pix to him. Marc Tompkins

Re: [Tutor] Changing the Attribute of a Variable

2009-02-18 Thread Wayne Watson
ter grip on the author's code. That should help as I continue to add new features. ... -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) "Nature, to be commanded, must be obeye

Re: [Tutor] Changing the Attribute of a Variable

2009-02-18 Thread Wayne Watson
ages of tracebacks by enabling 'Quick Edit' mode in your windows command prompt. More info here: http://support.microsoft.com/kb/282301 _______ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tut

[Tutor] Looking for ConfigObj Documentation

2009-02-18 Thread Wayne Watson
the meantime, I think I'll turn it into a more manageable pdf file before putting it to paper. -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) "Nature, to be

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-18 Thread Wayne Watson
Title: Signature.html OK, I got the ObjectConfig and Validate downloads, and copied your Global class successfully. Don't I need to get the two files into Python as a module? How does that work? Marc Tompkins wrote: On Wed, Feb 18, 2009 at 7:30 AM, Wayne Watson <sie

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-18 Thread Wayne Watson
nteger, booleand and option?  Items like start_time would then be called keywords? Marc Tompkins wrote: On Wed, Feb 18, 2009 at 1:01 PM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: OK, I got the ObjectConfig and Validate downloads, and copied your Global class successfully. Don&

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-18 Thread Wayne Watson
my laptop, which has 2.4; however, I recall being able to probe Python library paths. This may be irrelevant. The ConfigObj 4 Introduction and Ref doc doesn't seem to associate it with any version of Python. Its version is 4.5.3. Puzzled ... Marc Tompkins wrote: On Wed, Feb 18, 2009 at 1:01

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-19 Thread Wayne Watson
ke boolean,  integer, and others described?  The doc I have barely refers to them. Off to find wx... Marc Tompkins wrote: On Wed, Feb 18, 2009 at 7:42 PM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: I took your "starter" code, and formatted it to be what I hope is an

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-19 Thread Wayne Watson
I now have wxPython, IDLE and Vim installed. IDLE didn't disappear during the wx install.  It looks as though wxPython re-compiled library files. I'll be exploring vim now. Wayne Watson wrote: Hi, actually I had two aims with the pseudo code, 1. print it, and 2. check to see i

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-19 Thread Wayne Watson
rote: On Thu, Feb 19, 2009 at 9:58 AM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: I now have wxPython, IDLE and Vim installed. IDLE didn't disappear during the wx install.  It looks as though wxPython re-compiled library files. I'll be exploring vim now.

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-19 Thread Wayne Watson
. Not good. Maybe there's a way to disable F5!!! Maybe it's just too close to F3! Marc Tompkins wrote: On Thu, Feb 19, 2009 at 10:59 AM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote:   I'm willing to give vim a shot. I believe in an earlier thread unrelated to th

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-20 Thread Wayne Watson
file from there. I get exactly the same message (s) as above. I don't recall if you tried the program on your system. Comments? Marc Tompkins wrote: On Wed, Feb 18, 2009 at 7:42 PM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: I took your "starter" code, and

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-20 Thread Wayne Watson
and currently gets tossed when the file is read.  "_name" are strings. No others have seen the program, so development continues. Marc Tompkins wrote: On Fri, Feb 20, 2009 at 9:45 AM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: Marc, I'm reaching back here

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-20 Thread Wayne Watson
I see on screen. Very odd. Alan Gauld wrote: "Wayne Watson" wrote  I just ran the program again straight from the py file, and it put my the black window with my raw_input prompt.  Thats why, when debugging, its often better to open the command window first and run the progr

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-21 Thread Wayne Watson
ve their possibilities. TJG ___ Tutor maillist  -  Tutor@python.org http://mail.python.org/mailman/listinfo/tutor -- Signature.html Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W,

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-21 Thread Wayne Watson
Title: Signature.html I tried XP's Help on command prompts. Not much there. Is there another source? -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) "Nature, to be

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-21 Thread Wayne Watson
e I didn't yet know all the wrinkles in the file.   Marc Tompkins wrote: On Sat, Feb 21, 2009 at 6:46 PM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: Marc, did I miss your update on the file? No, just got distracted.  I'll get that to you shortly.

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-21 Thread Wayne Watson
Title: Signature.html I've found others like that, but I was looking for something more descriptive. Things like typing fill-in, or cut/paste, use of F8, etc.  I'd guess there are more. Marc Tompkins wrote: On Sat, Feb 21, 2009 at 6:42 PM, Wayne Watson <sierra_mtnv...@sbcglob

Re: [Tutor] Looking for ConfigObj Documentation

2009-02-22 Thread Wayne Watson
27;ve seen here.  Alan Gauld wrote: "Wayne Watson" wrote tried XP's Help on command prompts. Not much there. Is there another source? When you say XPs help do you mean the GUI help tool? There isn't much in there. For DOS things use the DOS help t

[Tutor] Converting "HH:MM:SS" to datetime

2009-03-01 Thread Wayne Watson
Title: Signature.html Ok, how do I do what's mentioned in Subject? -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) "Nature, to be commanded, must

Re: [Tutor] Converting "HH:MM:SS" to datetime

2009-03-01 Thread Wayne Watson
Sander -- Signature.html Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) "Nature, to be commanded, must be obeyed." -- Sir Fra

Re: [Tutor] Converting "HH:MM:SS" to datetime

2009-03-01 Thread Wayne Watson
leaves this bit of a struggle to get it right:     x = str(self.start_time)     set_loc_dict["start_time"] = datetime.datetime.strptime(x,"%H:%M:%S") It seems like there should be a simpler way to wrestle this to datetime. Marc Tompkins wrote: On Sun, Mar 1, 20

[Tutor] Returning the IDLE Shell Window to Prompt

2009-03-01 Thread Wayne Watson
program's menu and select exit. What can one do if the GUI has no such exit? -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) "Nature, to be commanded, must

Re: [Tutor] Returning the IDLE Shell Window to Prompt

2009-03-01 Thread Wayne Watson
o the black window. It works, but at what I consider a small IDLE penalty at this point. Alan Gauld wrote: "Wayne Watson" wrote My Tkinter program can crash at this stage, and the shell window is locked from text entry, and the GUI displayed. I can kill the window by using

[Tutor] Maintaining the Same Variable Type--Tkinter

2009-03-01 Thread Wayne Watson
value=1, variable=self.colorVar).grid(row=0, sticky=W)                    ... =End Settings Dialog -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “In mathematics you do

[Tutor] What is this [] construction?

2009-03-02 Thread Wayne Watson
ists(event) and    (time.time() - os.path.getmtime(event)) < 3600.0 ] -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “In mathematics you don&#

[Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
="Number ").grid(row=0, sticky=W)     self.anumberVar = StringVar()     entry = Entry(master, width=10, textvariable=self.anumberVar).grid(row=0, column=1)     self.anumberVar.set( "%d" % self.sdict["anumber"] )     return entry     def apply(

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
Title: Signature.html WW,     good. Thanks. destroy() took care of it, but I wonder what advantage there was to Quit()? WW W W wrote: On Tue, Mar 3, 2009 at 1:54 PM, Wayne Watson wrote: BTW, the Quit function is original but doesn't kill the window when Quit is used.

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
local to Python. Alan Gauld wrote: "Wayne Watson" wrote see my post of yesterday, "Maintaining the Same Variable Type--Tkinter", went over like a lead balloon. :-) Yeah, I had no idea what you meant :-)  I've heavily modified the original

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
r.set. (I think I mixed this up in my first response to you with StringVar.) Alan Gauld wrote: "Wayne Watson" wrote Comments? class IntVar_GUI: I just noticed the name of the class. This kind of implies that you are intending writing GUIs for each

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
Alan Gauld wrote: "Wayne Watson" wrote BTW, the Quit function is original but doesn't kill the window when Quit is used. Does that include running from the command console? Is this another IDLE/Tkinter

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
Title: Signature.html There's another way? Alan Gauld wrote: "Wayne Watson" wrote Note though the use of control variables like IntVar, etc. FWIW. Personally I never use those "convenience" features of Tk. I prefer to explicitly set and get

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-03 Thread Wayne Watson
Title: Signature.html Memory malfunction. I've been using the program to add features so much with IDLE my brain went IDLE. One starts it by double clicking on the py file. It is possible some users might have drifted off into IDLE though, but unlikely. Wayne Watson wrote: Nope. I

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-04 Thread Wayne Watson
Title: Signature.html No error messages. Just a clean finish. Alan Gauld wrote: "Wayne Watson" wrote One starts it by double clicking on the py file. And just to be clear, it exits OK when you run it that way? I would expect so since that's the normal way t

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-04 Thread Wayne Watson
are automatically updated on the screen.. Alan Gauld wrote: "Wayne Watson" wrote There's another way? Sure, just create normal Entry widgets and capture the input string and convert/assign it as you would a string captured from raw_input() in a console. No magic

[Tutor] A Simple Tkinter Control Program--Slight Problem

2009-03-05 Thread Wayne Watson
Here's what I think the author meant in discussing a control variable sample program. from Tkinter import * v=StringVar() e = Entry(master, textvariable=v) e.pack() e.focus_set() v.set("a default value") s = v.get() mainloop()

Re: [Tutor] Configuration File, Tkinter, IntVars--Manufacturing Variables

2009-03-05 Thread Wayne Watson
Your age:', IntWidget), ('subscribe', 'Send emails', BoolWidget), ] # Create the widgets row = 0 self.widgets = {} for name, desc, widget in values: self.widgets[name] = widget(master, desc, row)

Re: [Tutor] A Simple Tkinter Control Program--Slight Problem

2009-03-05 Thread Wayne Watson
Title: Signature.html master!   Good. Thanks.   master.mainloop() Alan Gauld wrote: "Wayne Watson" wrote Here's what I think the author meant in discussing a control variable sample program. from Tkinter import * v=StringVar()

[Tutor] Misunderstanding the Entry Widget

2009-03-05 Thread Wayne Watson
ly after I had to remove the dash from the name and replace it with an underscore. Whoops, that one doesn't really work either. -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time)

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-06 Thread Wayne Watson
aster,textvariable=v) e.pack() b = Button(master, text="Push to Print", width=10, command=mycallback) b.pack() e.focus_set() v.set(123) mainloop()    =End===== Alan Gauld wrote: "Wayne Watson" wrote Apparently Entry does not have a callback.

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-06 Thread Wayne Watson
scale widgets, but I'm looking at an example that says otherwise. Can you easily construct a simple example where they are absolutely necessary, or at least provide a situation where they are necessary? Kent Johnson wrote: On Fri, Mar 6, 2009 at 7:15 AM, Wayne Watson wrote: Control

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-07 Thread Wayne Watson
h the widgets used. That's OK. I just wanted to make sure I wasn't overlooking something. It provided a helpful interlude. :-) Alan Gauld wrote: "Wayne Watson" wrote > Can you easily construct a simple example where they are absolutely necessary, or at least provid

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-07 Thread Wayne Watson
use a StringVar to return the values entered. Is it possible to reach inside TwoEntries, after returning from it, and grab entry1 and 2? It would seem so if the call was dialog=TwoEntries(...). Wayne Watson wrote: I have no idea of the history of these variables, but they have very limited

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-08 Thread Wayne Watson
mply was taught to get this program completed. (It is not a classroom program.) I know he put it together quickly, and did quite a spectacular job of writing the code and interfacing it to some complex h/w. Alan Gauld wrote: "Wayne Watson" wrote Signature.htmlAnother thought

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-08 Thread Wayne Watson
Sounds like the O'Reilly book might be worth it. I have an interlibrary loan request out for a highly recommended Tk/Tcl book. I tried Cygwin about 5 years ago, and it just didn't cut it. Odd problems. It may be worth a shot again when I can free up some time. Alan Gauld wrote: &qu

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-09 Thread Wayne Watson
dition due in August 2009! How's that for service :-) BTW I also noticed that there is also now an O'Reilly pocket reference which might be even more useful to Python Tkinter users than the Nutshell - smaller and cheaper and even more terse! Although it doesn't appear to cover T

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-09 Thread Wayne Watson
sentuser\sentuserNC25-Dev5.py", line 115, in body     entry.insert(0,self.slowdown) AttributeError: OperationalSettingsDialog instance has no attribute 'slowdown' Kent Johnson wrote: On Mon, Mar 9, 2009 at 8:30 AM, Wayne Watson wrote:     entry = Entry(master, width=10).

Re: [Tutor] Misunderstanding the Entry Widget

2009-03-09 Thread Wayne Watson
Title: Signature.html On a branch off this thread, I've mentioned a problem with this approach. It seems right, but I haven't bridged it yet. Do you have some simple Tk Python code that shows how to do this? Alan Gauld wrote: "Wayne Watson" wrote Signature

Re: [Tutor] Misunderstanding the Entry Widget (Closed)

2009-03-10 Thread Wayne Watson
Finished. Closed. Done. It needed the second line here:    entry = Entry(master, width=10, textvariable=self.anumberVar)             entry.grid(row=0, column=1) Wayne Watson wrote: On a branch off this thread, I've mentioned a problem with this approach. It seems right,

[Tutor] Modifying Grayson's Example 5_14

2009-03-16 Thread Wayne Watson
  tkMessageBox.showerror('Bad Password',    'New Passwords do not match')     else:     # This is where we would set the new password...     pass root = Tk() dialog = GetPassword(root) -- Wayne Watson (Watso

Re: [Tutor] Modifying Grayson's Example 5_14

2009-03-16 Thread Wayne Watson
Title: Signature.html That worked. Why the "extra" blank window though? Martin Walsh wrote: Wayne Watson wrote: it. It works pretty well, but puts up a a few probably top level windows that are blank. How do I get around them, and is ther

[Tutor] Python and Tkinter Programming by Grayson--New Version?

2009-03-17 Thread Wayne Watson
A Mapping Tk to Tkinter 383 appendix B Tkinter reference 425 appendix C Pmw reference: Python megawidgets 542 appendix D Building and installing Python, Tkinter 610 appendix E Events and keysyms 617 appendix F Cursors 621 appendix G References 625 index 629 -- Wayne Watson (Watson A

[Tutor] Checking Entry Values in Tkinter Widgets

2009-03-17 Thread Wayne Watson
    self.rateVar.set( "%s" % self.sdict["hourly_rate"] )              ...     def apply(self):     self.sdict["ok"] = True     #END of class Furthermore, doesn't the use of tkSimpleDialog.Dialog provide an OK and Cancel button, which upon use causes the the

[Tutor] Fun with Label and Entry--Why NoneType?

2009-03-17 Thread Wayne Watson
lf.long)     return         def apply(self):     print "apply"     print self.lat.get()     print self.long.get()     print "setting"     lat=1.0     long=0.0 root = Tk() root.withdraw() dialog = DialogPrototype(root) -- Wayne Watson (Watson Adventur

Re: [Tutor] Fun with Label and Entry--Why NoneType?

2009-03-17 Thread Wayne Watson
27;tkwait', 'visibility', window._w) TclError: window ".60529560" was deleted before its visibility changed Martin Walsh wrote: Wayne Watson wrote: The program below is derived from an example in Grayson for showing how one might a dialog for entering passwords. Th

Re: [Tutor] Checking Entry Values in Tkinter Widgets

2009-03-17 Thread Wayne Watson
fashioned way -- if statements. Alan Gauld wrote: "Wayne Watson" wrote The program I'm modifying uses something of a primitive way to check the validity of values entered into widgets on a larger dialog. You can bind events to the individual entry widgets to check value

Re: [Tutor] Fun with Label and Entry--Why NoneType?

2009-03-17 Thread Wayne Watson
he grab   File "C:\Python25\lib\lib-tk\Tkinter.py", line 415, in wait_visibility     self.tk.call('tkwait', 'visibility', window._w) TclError: window ".85342728" was deleted before its visibility changed Alan Gauld wrote: "Wayne Watson" wrote

Re: [Tutor] Checking Entry Values in Tkinter Widgets

2009-03-17 Thread Wayne Watson
As I thought this over, while on a long walk, apply might not be the place. That is, if pressing OK gets you to apply and the code discovers how do you get back to the dialog. I think you may have answered that below with the validation code. Alan Gauld wrote: "Wayne Watson" wrote

Re: [Tutor] Fun with Label and Entry--Why NoneType?

2009-03-17 Thread Wayne Watson
nloop() Extra blank window at start up and crashed the same way when pressing OK. I'm using this code to prototype a larger dialog with more data entry, so it doesn't really matter that it crashes when I exit. John Fouhy wrote: 2009/3/18 Wayne Watson : Unfortunately, that t

Re: [Tutor] Python and Tkinter Programming by Grayson--New Version?

2009-03-17 Thread Wayne Watson
Title: Signature.html Working with Tkinter is like trying to dig through fossils. So much out there is old or incomplete. It's like the Tk species went extinct. The trail seems to end in 2005. I think I read it's not quite dead, and a newer looking is coming. Alan Gauld wrote: &qu

Re: [Tutor] Fun with Label and Entry--Why NoneType?

2009-03-18 Thread Wayne Watson
my purposes if I stick to the command window, which nicely closes when I hit OK. IDLE forces a hang in the shell window, which requires effort to recover. The Tk window appears in using either command prompt or IDLE. Alan Gauld wrote: "Wayne Watson" wrote Unfortunately, that takes me

[Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-18 Thread Wayne Watson
produce different executable code. The too I would want to do this in Win. Is there, in fact, some Linux environment in Win that would allow me to test its executable? -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time

Re: [Tutor] Python and Tkinter Programming by Grayson--New Version?

2009-03-18 Thread Wayne Watson
n To Program website http://www.alan-g.me.uk/ From: Wayne Watson To: ALAN GAULD Sent: Wednesday, 18 March, 2009 12:25:58 PM Subject: Re: [Tutor] Python and Tkinter Programming by Grayson--New Version? How do I get to that mail list? I see no evidence of a "ne

[Tutor] Playing with CENTER, Grid, Labels and Entry

2009-03-18 Thread Wayne Watson
mn(anchor=CENTER), columnspan=3)     title=Label(master, text="This is a Title").grid(row=8, column=0, columnspan=3).columnconfigure(0,anchor=CENTER)     #title.configure(anchor=CENTER)           ... -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA)

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-18 Thread Wayne Watson
m w/i Win OS. My other choice is recoding 38K lines of C code into Python. I'll pass on that. :-) Unless there's a very good translator between languages. Alan Gauld wrote: "Wayne Watson" wrote The Subject contains the interest here. Can it be done? A C p

Re: [Tutor] Iterating over letters or arbitrary symbols like they were numbers...

2009-03-18 Thread Wayne Watson
rather, looking for improvement if it's glaringly dumb) ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA)

Re: [Tutor] Playing with CENTER, Grid, Labels and Entry

2009-03-18 Thread Wayne Watson
root = Tk() root.option_add('*font', ('verdana', 12, 'bold')) root.title("Pack - Example 11") display = App(root) root.mainloop() Wayne Watson wrote: I'm prototyping a dialog with about 10 rows of 4 columns of widgets. Most rows are like:       

Re: [Tutor] Python and Tkinter Programming by Grayson--New Version?

2009-03-18 Thread Wayne Watson
Alan Gauld wrote: "Wayne Watson" wrote As I wander around the internet trying to get info from Lundh, New Mexico, and other sites, I wonder if, in particular New Mexico is not using the "new" Tkinter. How would I know? Nobody is using the new ve

Re: [Tutor] Fun with Label and Entry--Why NoneType?

2009-03-18 Thread Wayne Watson
agreed. BTW I just double checked and when I double click in Explorer on -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “Life is one damn thing after another."

Re: [Tutor] Playing with CENTER, Grid, Labels and Entry

2009-03-18 Thread Wayne Watson
Title: Signature.html This couldn't be more timely. I finally gave up on the present idea, and thought to myself, "Try frames". You just saved me some Google work. Thanks. Alan Gauld wrote: "Wayne Watson" wrote I'm using Grid. It's gone pretty well

Re: [Tutor] Python and Tkinter Programming by Grayson--New Version?

2009-03-18 Thread Wayne Watson
Well, after all that churning hours ago before the PC went down, it actually set up the newreader. Wayne Watson wrote: Thanks. My computer continued to struggle. An hour later it was so bad I rebooted. Nothing like cleaning house. I seem to go for about 5-7 days, then things get

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-18 Thread Wayne Watson
could execute a RH executable from C on Ubuntu. Is there a simple example of this in action from a Python program and some small C Linux executable program? greg whittier wrote: On Wed, Mar 18, 2009 at 4:06 PM, Wayne Watson wrote: Thanks to both above posts before this reply. I&

Re: [Tutor] Fun with Label and Entry--Why N....(Command Prompt)

2009-03-19 Thread Wayne Watson
grab it with the mouse and hit enter. You can then paste it wherever you like... QuickEdit is on, but dragging over the area to be copied is not very selective. It forms a rectangle. Further, Ctrl-C doesn't copy anything. Help gives no clue about copy. Alan G.

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-19 Thread Wayne Watson
l size) >From wolf.h #define wolf #include #include #include #include #include "cgi-draw.h"   << #include "novas.h" #include "global.h" #include "calstars.h" #include "imatrix.h" #include "cnstl.h" Alan Gauld wrote

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-19 Thread Wayne Watson
Good. See my follow up to Alan's post for more details on what I'm doing. Apparently, not SWIG. Thanks for the Alan link. Martin Walsh wrote: Wayne Watson wrote: If you can execute a C program compiled on a Linux with SWIG, then that's what I'm looking for.

Re: [Tutor] Fun with Label and Entry--Why N....(Command Prompt)

2009-03-19 Thread Wayne Watson
lp system but I find that slower (although the HTML formatted text is easier to read I guess). Alan G. -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “Lif

[Tutor] Tkinter Geometry Management and Other Basics

2009-03-19 Thread Wayne Watson
x27;).grid(row=0, column=2)     self.zenith_y = Entry(fZenith, width=6)     self.zenith_y.grid(row=0, column=3)     return end== -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-19 Thread Wayne Watson
close_fds=False Why not just class Popen instead of subprocess.Popen? Is there a suggestion here that I need only do: myProg=Popen() myProg.call("wolf", "-h") where wolf is the executable C program? Wayne Watson wrote: Good. See my follow up to Alan's post

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
es on the file and it shows "A". I'm the admin on my XP Pro, and the file is owned by Admin. wolf is a 1 meg file. Alan Gauld wrote: "Wayne Watson" wrote What is meant by "The arguments are the same as for the Popen constructor.", in Convenience

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
Title: Signature.html Yes, good, but I tried myProg = call([r"C:\Sandia_Meteors\Various\FuzzyLogic\wolf", "-h"]), and get exactly the same results. A.T.Hofkamp wrote: Wayne Watson wrote: Good. Thanks. Here's my code. == # Executing a L

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
orming the call it is dealing with a non-Win program. A.T.Hofkamp wrote: Wayne Watson wrote: Yes, good, but I tried myProg = call([r"C:\Sandia_Meteors\Various\FuzzyLogic\wolf", "-h"]), and get exactly the same results. So the next step is to find out

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
Title: Signature.html You understand it perfectly. Michael Farnham wrote: On Fri, 2009-03-20 at 04:35 -0700, Wayne Watson wrote: Good. Thanks. Here's my code. == # Executing a Linux program under Win XP from subprocess import call myProg = call(["C:\Sand

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
small computers, these sorts of things were possible, usually through a simulator of some sort. Wayne Watson wrote: You understand it perfectly. Michael Farnham wrote: On Fri, 2009-03-20 at 04:35 -0700, Wayne Watson wrote: Good. Thanks. Here's my code. == # E

Re: [Tutor] Tkinter Geometry Management and Other Basics

2009-03-20 Thread Wayne Watson
tuff. Its easy to translate the Tk command to Tkinter. HTH, -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “Life is one damn thing after another."

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
t "unepxected" stars.    write_on_target - if 1, type labels on the output image. In this case,    output image must be specified.    inverted - if 1, the image is inverted (black background and white stars).    constellations - if 1, draw constellations (

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
sary files in a zip file. If not, then I'll be back to ask questions about what might be going wrong either here or in some Cygwin newsgroup.  I distantly recall there is one. greg whittier wrote: On Fri, Mar 20, 2009 at 1:01 PM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote:

Re: [Tutor] Executing a C Program from RH Linux ... (Cygwin)

2009-03-20 Thread Wayne Watson
Title: Signature.html First questions about Cygwin is I see a 1.7 Beta download version for it, and references to 1.5 downloads. Where's 1.6? Is it past Beta? Wayne Watson wrote: That's a lot of text to respond to, but let me see if I can broadly do it. It appears that t

Re: [Tutor] Executing a C Program from RH Linux in Python for Win

2009-03-20 Thread Wayne Watson
eph.c     $(CC) $(CFLAGS) sweph.c swephlib.o: swephlib.c     $(CC) $(CFLAGS) swephlib.c clean:     rm -f wolf *.o core See my post to Marc about the header file and graphics use. greg whittier wrote: On Fri, Mar 20, 2009 at 1:41 PM, Wayne Watson <sierra_mtnv...@sbcglobal.net> wrote: Ye

Re: [Tutor] Executing a C Program from RH Linux ... (Cygwin)

2009-03-20 Thread Wayne Watson
Title: Signature.html Sounds right to me. I won't. Kent Johnson wrote: On Fri, Mar 20, 2009 at 1:49 PM, Wayne Watson wrote: First questions about Cygwin is I see a 1.7 Beta download version for it, and references to 1.5 downloads. Where's 1.6? Is it past Beta? Wa

Re: [Tutor] Tkinter Geometry Management and Other Basics

2009-03-20 Thread Wayne Watson
mail.python.org/mailman/listinfo/tutor -- Signature.html Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “Life is one damn thing after another."

[Tutor] Posting to Tkinter NG in new.gmane.org

2009-03-25 Thread Wayne Watson
y Trash folder, then choose Compact Folders, ... My e-mail address is valid. Any ideas? I've compacted related Trash folders, etc -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “Life is one

Re: [Tutor] Posting to Tkinter NG in new.gmane.org

2009-03-26 Thread Wayne Watson
Title: Signature.html Yes, a typo. Alan Gauld wrote: "Wayne Watson" wrote My e-mail address is valid. Any ideas? I've compacted related Trash folders, etc It should be news.gmane.org... Or is that just a typ

[Tutor] Left Alignment -- Tkinter

2009-03-27 Thread Wayne Watson
    print "apply"     print self.lat.get()     print self.long.get()     print "setting"     lat=1.0     long=0.0 root = Tk() root.withdraw() DialogPrototype(root) -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg.

Re: [Tutor] Left Alignment -- Tkinter

2009-03-27 Thread Wayne Watson
hat I want this line left justified. If I put a similar frame above it, the lower one gets centered. -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.01 Deg. W, 39.26 Deg. N) GMT-8 hr std. time) “Life is one damn thing after an

Re: [Tutor] Left Alignment -- Tkinter

2009-03-27 Thread Wayne Watson
d=YES,fill=BOTH,side=TOP) Have a good vacation ... Alan Gauld wrote: Try packing the frame to the left and set it to expand. HTH, Going on vacation Bye Alan G. "Wayne Watson" wrote in message news:49cd0d40.5090...@sbcglobal.net... Signature.htmlThe code

<    1   2   3   4   5   >