Implicit initialization is EVIL!
rantingrick at gmail.com
Wed Jul 6 17:10:27 CEST 2011
On Jul 6, 9:32 am, Steven D'Aprano <steve
+comp.lang.pyt... at pearwood.info> wrote:
> rantingrick wrote:
> > If you design a GRAPHICAL user interface, then once the GRAPHICAL part
> > is removed (window), why do need the main code to stick around?
> Open your mind to ideas that go beyond your simple window-centric paradigm!
Correction: Window-Centric GUI paradigm! BIG DIFFERENCE.
> There is more to graphical user interfaces than windows!
OMG, you mean like, widgets? Whoa! Tell me more, Tell me more!
> In the Mac OS GUI, an application can have a menubar and no windows. Windows
> come and go as needed, but the menubar stays until the users quits the
That's just window visibility (whether by hiding or destroying) under
the veil of a detached UI window manager bar and has nothing to do
with window hierarchy. Your half stuffed straw men are leaking like a
> In the Unix/Linux world, there is a graphical application called xkill which
> has no menus and no windows, all it has is a mouse cursor! No, it does not
> run in the background: it is a foreground app.
Wow nice corner case. Can you come up with at least five of them
though? You and I both know that the vast majority of GUI's require
But wait! What is a GUI WINDOW exactly?
I'll tell you in the simplest terms i can muster... GUI "windows" are
an abstraction and nothing more. A GUI window is nothing more than an
imaginary area of the screen that can be drawn to. This area has
borders that define it. No not visible borders but two dimensional
spacial borders. THAT'S IT! The area could be 1x1 pixels OR the entire
screen space, OR even larger!
Most time you want the user to see the boundaries of this abstraction
(window) space and so the GUI library draws borders that represent
this boundary. Your "supposedly" windowless xkill application is not
windowless at all; THE WINDOW BOUNDARIES ARE JUST NOT DRAWN! The
window is the entire screen space OR IS JUST THE DESKTOP SPACE (same
> An extreme case, but telling. There is no absolute need for any windows at
> all, let alone for one privileged window to rule all the others.
Again your fear of losing "imaginary" freedoms is acting out again.
And your veiled attempts to link root GUI windows and Sauron (the
great antagonist of LOTH) is quite entertaining. Next you'll suggest
that root windows are really just a great eye, lidless, and wreathed
in flame and that i am Saruman building an army of Orc followers hell
bent on destroying the freedom to believe self serving fantasies.
More information about the Python-list