Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!npeer03.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: John Salerno Newsgroups: comp.lang.python Subject: Re: Tkinter: Why aren't my widgets expanding when I resize the window? Date: Mon, 5 Mar 2012 14:07:05 -0800 (PST) Organization: http://groups.google.com Lines: 43 Message-ID: <20757474.2202.1330985225312.JavaMail.geo-discussion-forums@ynlt17> References: <32271364.3080.1330931558529.JavaMail.geo-discussion-forums@ynjd19> <19872402.359.1330968669581.JavaMail.geo-discussion-forums@ynnj12> <01a0499e-616f-4395-95d2-b6e54e03bc79@i5g2000yqo.googlegroups.com> NNTP-Posting-Host: 76.30.237.113 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1330985324 12664 127.0.0.1 (5 Mar 2012 22:08:44 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Mon, 5 Mar 2012 22:08:44 +0000 (UTC) In-Reply-To: <01a0499e-616f-4395-95d2-b6e54e03bc79@i5g2000yqo.googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=76.30.237.113; posting-account=Wdz3OgoAAACumWTKfPjpOEJc3twpMp_1 User-Agent: G2/1.0 X-Received-Bytes: 3510 Xref: csiph.com comp.lang.python:21240 > > I don't like importing things piecemeal. I suppose I could do: >=20 > So you prefer to pollute? How bout we just auto import the whole > Python stdlib so you can save a few keystrokes? > > so that's four more constants I'd have to explicitly import. And > > (tk.N, tk.S, tk.E, tk.W) is just horrible to look at. >=20 > Wah! >=20 > Stop whining and act like a professional! You complain about > qualifying constants but you happily type "self" until your fingers > bleed without even a whimper??? >=20 > Look, either import ONLY the constants you need, or qualify each > constant with a module name/variable; that is the choices available to > a professional. Or, just be lazy and pollute your namespace. >=20 > FYI: Lazy coders get what they deserve in the end. How exactly am I being lazy and polluting the namespace? I never said I wan= ted to use the "*" import method, if that's what you are (wrongly) assuming= . I said it seems cleaner and, to me, LESS lazy to import the whole module = as "import tkinter.constants as tkc" and qualify everything. It's certainly= more explicit than importing constants on an as-needed basis, having an ev= er-increasing list of constants, and referring to them unqualified in the c= ode. Yes, I complain that tk.N, tk.S, etc. is ugly to look at, but I'm saying it= seems like a better way than using them unqualified, unless maybe there is= yet another, better way. As far as using "self" all the time, how do you know I never "whimpered" ab= out it? The first time I learned about it I DIDN'T like it, because it seem= ed like a lot of unnecessary typing, but eventually I came to accept it bec= ause 1) you HAVE to do it, unlike the various options for referring to thes= e constants, and 2) I began to like the explicitness of qualifying everythi= ng with "self." You are very helpful, but you sure like to throw around the term "lazy" a l= ittle too unabashedly. I never said I wanted to import with "*", which you = seem to think I want to do. I LIKE qualifying things, which is the reason I= didn't care so much for your method of importing the constants by name.