Still Loving Python

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Peter Decker

    #16
    Re: Still Loving Python

    On 12/13/05, Mike Meyer <mwm@mired.or g> wrote:
    [color=blue][color=green]
    > > A GUI builder is more pleasant to work with, at least
    > > with a good one like Delphi or Qt designer.[/color]
    >
    > That is your opinion, and I'm sure it's true for you. It isn't true
    > for me.[/color]

    Why, then, do you disparage those who like to do things differently?
    Why label visual tools as "evil"? Why this need to have everyone do
    things the way you do?

    This sounds a lot like the tabs vs. spaces argument, or the emacs vs.
    every other editor argument, in that one side seems to feel that "to
    each his own", while the other side has a religious zealotry about
    them that compels them to want to enforce their preferences on
    everyone.

    You like to write code? Great! Someone else like to use a visual
    designer? Great! Just realize that UI created with visual tools can be
    crap, and so can UIs written with raw code. Making fun of people whose
    preferences are different than yours only makes you look insecure.

    --

    # p.d.

    Comment

    • Mike Meyer

      #17
      Re: Still Loving Python

      Peter Decker <pydecker@gmail .com> writes:[color=blue][color=green][color=darkred]
      >> > A GUI builder is more pleasant to work with, at least
      >> > with a good one like Delphi or Qt designer.[/color]
      >> That is your opinion, and I'm sure it's true for you. It isn't true
      >> for me.[/color]
      > Why, then, do you disparage those who like to do things differently?
      > Why label visual tools as "evil"?[/color]

      I didn't label them as "evil" - I agreed with someone who did that
      :-).
      [color=blue]
      > Why this need to have everyone do things the way you do?[/color]

      Whatever makes you think I have this need? I said I hated them. I'm
      pretty sure I didn't say everyone should have to use them.

      <mike
      --
      Mike Meyer <mwm@mired.or g> http://www.mired.org/home/mwm/
      Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.

      Comment

      • Alex Martelli

        #18
        Re: Still Loving Python

        Jérôme Laheurte <fraca7@free.fr > wrote:
        ...[color=blue]
        > Sorry for the harsh tone, I just think GUI builders are *evil*. Except
        > maybe for QT Designer, which has a nice model where you implement
        > callbacks by subclassing the generated classes. At least you don't have to
        > look at the generated code.[/color]

        Try Interface Builder on a Mac: it builds interfaces as _data_ files,
        not "generated code". You can then use the same UI from Objective C,
        Java, Python (w/PyObjC), AppleScript... interface-painters which
        generate code are a really bad idea. (I'm sure Apple's IB is not the
        only interface-painter which encodes the UI as a datafile, easily
        interpreted at startup by a suitable library for whatever language
        you're using to flesh it out -- it's such an obviously RIGHT idea!).


        Alex

        Comment

        • Kamilche

          #19
          Re: Still Loving Python

          Yeah, I have a system like that on my product. It's a data file loaded
          at code startup time, which results in a UI - no need to cut code to
          change the interface. It's saved me a lot of time.

          I also have a problem with 'designers'. If the GUI designer is as easy
          as making an interface was in VB6, I would like it and use it. If it's
          complicated morass of sticky goo that I have to wade through at the
          start of the program, like tKinter, I'd rather use pure code, or data
          files.

          Comment

          • Paul Rubin

            #20
            Re: Still Loving Python

            aleax@mail.comc ast.net (Alex Martelli) writes:[color=blue]
            > Try Interface Builder on a Mac: it builds interfaces as _data_ files,
            > not "generated code". You can then use the same UI from Objective C,
            > Java, Python (w/PyObjC), AppleScript... interface-painters which
            > generate code are a really bad idea.[/color]

            Glade also does something like that.

            We see the same thing in HTML. Lots of people including serious
            designers use wysiwyg HTML layout programs. For fancy layouts they're
            almost indispensible. I hand-code my HTML but I keep it simple.

            Comment

            • Steve Holden

              #21
              Re: Still Loving Python

              Mike Meyer wrote:[color=blue]
              > Peter Decker <pydecker@gmail .com> writes:
              >[color=green][color=darkred]
              >>>>A GUI builder is more pleasant to work with, at least
              >>>>with a good one like Delphi or Qt designer.
              >>>
              >>>That is your opinion, and I'm sure it's true for you. It isn't true
              >>>for me.[/color]
              >>
              >>Why, then, do you disparage those who like to do things differently?
              >>Why label visual tools as "evil"?[/color]
              >
              >
              > I didn't label them as "evil" - I agreed with someone who did that
              > :-).
              >
              >[color=green]
              >>Why this need to have everyone do things the way you do?[/color]
              >
              >
              > Whatever makes you think I have this need? I said I hated them. I'm
              > pretty sure I didn't say everyone should have to use them.
              >[/color]

              Before we descend to the level of name calling :-), can I interject
              another, possibly heretical, point in favour of GUI builders that you
              might *both* be able to disagree with?

              It isn't often done, but I quite like the idea of giving users the GUI
              builder so that they can specify their preferred task interface, at
              least to a first approximation.

              With a good tool it's relatively easy to integrate application code
              after GUI clean-up. Users sometimes find this a more intuitive way of
              specifying what they want (and God knows, most users *need* better ways
              of specifying what they want ...)

              regards
              Steve
              --
              Steve Holden +44 150 684 7255 +1 800 494 3119
              Holden Web LLC www.holdenweb.com
              PyCon TX 2006 www.python.org/pycon/

              Comment

              • Steve Holden

                #22
                Re: Still Loving Python

                Alex Martelli wrote:[color=blue]
                > Jérôme Laheurte <fraca7@free.fr > wrote:
                > ...
                >[color=green]
                >>Sorry for the harsh tone, I just think GUI builders are *evil*. Except
                >>maybe for QT Designer, which has a nice model where you implement
                >>callbacks by subclassing the generated classes. At least you don't have to
                >>look at the generated code.[/color]
                >
                >
                > Try Interface Builder on a Mac: it builds interfaces as _data_ files,
                > not "generated code". You can then use the same UI from Objective C,
                > Java, Python (w/PyObjC), AppleScript... interface-painters which
                > generate code are a really bad idea. (I'm sure Apple's IB is not the
                > only interface-painter which encodes the UI as a datafile, easily
                > interpreted at startup by a suitable library for whatever language
                > you're using to flesh it out -- it's such an obviously RIGHT idea!).
                >[/color]
                You're right. For example wxDesigner will produce XML, as well as
                writing wxWidgets calls directly in Python, Perl or C++.

                regards
                Steve
                --
                Steve Holden +44 150 684 7255 +1 800 494 3119
                Holden Web LLC www.holdenweb.com
                PyCon TX 2006 www.python.org/pycon/

                Comment

                • Bengt Richter

                  #23
                  Re: Still Loving Python

                  On Tue, 13 Dec 2005 20:33:36 -0500, Mike Meyer <mwm@mired.or g> wrote:
                  [color=blue]
                  >Peter Maas <peter.maas@som ewhere.com> writes:[color=green]
                  >> Mike Meyer schrieb:[color=darkred]
                  >>> I agree. I've tried a number of different gui builders. I find it much
                  >>> faster to type something like:
                  >>> ui.add_button(" New", self.new)
                  >>> ui.add_button(" Open", self.open)
                  >>> ui.add_button(" Save", self.save)
                  >>> ui.add_button(" Save As", self.save_as)
                  >>> Than have to drag four menu buttons from a pallette, then open the
                  >>> properties of each one to edit the text of the button and the callback
                  >>> entry (or whatever dance they need so you can enter the required
                  >>> text).[/color]
                  >> If you design a moderately complex UI a designer will be faster. It's
                  >> not the speed of typing vs. dragging that matters. You see the result
                  >> instantly and don't have to start your program, look, type code, start
                  >> again and so on.[/color]
                  >
                  >But you only need to do that if you're wanting near-absolute control
                  >over what's displayed. Once you provide reasonable accessability and
                  >configuratio n features - letting the user specifiy fonts, which
                  >buttons show up, which toolbars you're going to have, what's in the
                  >menus, etc. In this case, "look" is trivial, and it seldom requires a
                  >second pass.
                  >[color=green]
                  >> A GUI builder is more pleasant to work with, at least
                  >> with a good one like Delphi or Qt designer.[/color]
                  >
                  >That is your opinion, and I'm sure it's true for you. It isn't true
                  >for me.[/color]
                  De gustibus non disputandum, or whatever ;-)
                  [color=blue]
                  >[color=green]
                  >> It's not a good idea to do everything in code. I find it tiresome to
                  >> create menus and toolbars by writing code.[/color]
                  >
                  >Maybe you're doing something wrong? Or maybe it is tiresome for you,
                  >and you should be using something else.
                  >[color=green]
                  >> Creating visual resources visually is the direct way, creating them in
                  >> code is a detour. Code is too lengthy and too versatile for such a
                  >> job.[/color]
                  >
                  >Your application creates code in the end, so that's the direct
                  >route. A visual representation of a modern app is a relatively static
                  >version of the real interface, and thus at best an approximation.
                  >
                  >Worse yet, there's a good chance your visual tool stores the
                  >information needed to recreate either the visual version or the code
                  >in either a binary format, or a proprietary one, or both. In the
                  >former case, standard code analysis tools are nearly useless. In the
                  >latter case, they own your code. While that price might be worth it if
                  >you place enough value onj being able to manipulate images instead of
                  >code, either is enough to make me avoid a tool.
                  >[/color]
                  If that is your concept of Delphi, it is wrong. A text view of what you have
                  created visually is available. I put four buttons on a blank form with
                  captions per your example. The result is

                  object Form1: TForm1
                  Left = 200
                  Top = 108
                  Width = 696
                  Height = 480
                  Caption = 'Form1'
                  Font.Charset = DEFAULT_CHARSET
                  Font.Color = clWindowText
                  Font.Height = -11
                  Font.Name = 'MS Sans Serif'
                  Font.Style = []
                  PixelsPerInch = 96
                  TextHeight = 13
                  object Button1: TButton
                  Left = 64
                  Top = 48
                  Width = 75
                  Height = 25
                  Caption = 'New'
                  TabOrder = 0
                  end
                  object Button2: TButton
                  Left = 152
                  Top = 48
                  Width = 75
                  Height = 25
                  Caption = 'Open'
                  TabOrder = 1
                  end
                  object Button3: TButton
                  Left = 240
                  Top = 48
                  Width = 75
                  Height = 25
                  Caption = 'Save'
                  TabOrder = 2
                  end
                  object Button4: TButton
                  Left = 328
                  Top = 48
                  Width = 75
                  Height = 25
                  Caption = 'Save As'
                  TabOrder = 3
                  end
                  end

                  You see the above sort of text if you are looking at a form you are working and you press Alt-F12.
                  If you do not violate the format, you can edit it as text right in the window you are looking at
                  and round-trip it back to a visual view with another Alt-F12, and you will see the adjusted visual view.
                  Other aspects of objects show up too if you set non-default conditions one way or the other. E.g.,
                  adding an individual mouse-over hint is a matter of typing the text in a slot in the object inspector
                  which is automatically showing the properties of the button etc that you have visually selected
                  on your form/dialog. E.g., above button with hint added.

                  object Button4: TButton
                  Left = 328
                  Top = 48
                  Width = 75
                  Height = 25
                  Hint = 'Opens a file dialog for saving'
                  Caption = 'Save As'
                  ParentShowHint = False
                  ShowHint = True
                  TabOrder = 3
                  end

                  A single click compiles, links and runs the resulting independent windows .exe in a fraction of a second
                  for the above, and I can see the hint, kill the .exe, and go on where I was.

                  Of course, as you see, I could select the text and put it in the clipboard, and post it here.

                  BTW, Delphi also compiles and links in a blink (literally for small programs), and generates
                  a small .exe. Delphi also lets you code without GUI and gives you a command line compiler for
                  its object pascal, and you can write very small executables that way if you like, even using x86 builtin assembler.
                  And it compiles and links _hella_ faster than C/C++ ;-) And you can make DLLs, and link also with non-Delphi.

                  Not that I've used it for quite some time, though ;-)

                  Anyway, I wouldn't diss Delphi too casually. I don't think you would if you'd spent enough time to
                  get fluent in it. (I don't know what the current state of Delphi is though. I'm speaking from experience
                  mostly with the ancient Delphi3 whose output you see above ;-)

                  Regards,
                  Bengt Richter

                  Comment

                  • Peter Decker

                    #24
                    Re: Still Loving Python

                    On 12/13/05, Mike Meyer <mwm@mired.or g> wrote:
                    [color=blue][color=green]
                    > > Why this need to have everyone do things the way you do?[/color]
                    >
                    > Whatever makes you think I have this need? I said I hated them. I'm
                    > pretty sure I didn't say everyone should have to use them.[/color]

                    Sorry, but there is a world of difference between saying "I prefer X
                    over Y" and "Yes, Y is evil". And unless English is a second language
                    for you, it's insulting to imply a difference between calling
                    something evil and agreeing with someone who did, even if you added a
                    smiley.

                    This is a 'discussion' list. Nothing kills discussion faster than
                    zealots who call those who disagree with them evil or idiots or
                    clueless n00bs.

                    --

                    # p.d.

                    Comment

                    • Daniel Crespo

                      #25
                      Re: Still Loving Python

                      Lawrence Oluyede wrote:
                      [color=blue]
                      > ps. the customer wants Windows as a platform, we develop on Linux using
                      > PyGTK, postgre and sql server for some old data. This is the true power of
                      > cross-platform :)[/color]

                      PyGTK is crossplatform, that's true, but it looks very ugly under
                      Windows and don't know under MacOS (if it's supported). I couldn't find
                      the way for get it running with an atractive look & feel under Windows
                      after compiling it. Also, it needs the GTK+ Runtime Environment. I use
                      wxPython and it is very very very very good. It's not perfect, but IMO,
                      it is much better than PyGTK. PyGTK is good if you intend to develop
                      for Linux.

                      Daniel

                      Comment

                      • TwistyCreek

                        #26
                        Re: Still Loving Python

                        Peter Decker wrote:
                        [color=blue]
                        > On 12/13/05, Mike Meyer <mwm@mired.or g> wrote:
                        >[color=green][color=darkred]
                        >> > Why this need to have everyone do things the way you do?[/color]
                        >>
                        >> Whatever makes you think I have this need? I said I hated them. I'm
                        >> pretty sure I didn't say everyone should have to use them.[/color]
                        >
                        > Sorry, but there is a world of difference between saying "I prefer X over
                        > Y" and "Yes, Y is evil". And unless English is a second language for you,
                        > it's insulting to imply a difference between calling something evil and
                        > agreeing with someone who did, even if you added a smiley.
                        >
                        > This is a 'discussion' list. Nothing kills discussion faster than zealots
                        > who call those who disagree with them evil or idiots or clueless n00bs.[/color]

                        Except maybe anal retentive prats who argue semantics to cover up the fact
                        that they wouldn't know a for loop from a foreskin.

                        And by the by... visual tools ARE evil. <nfgaa>

                        It's like your dad getting his drunken bar buddies to plow your mother
                        because he's too fat to do it himself. The unfortunate offspring of any
                        such union is equally the bastard be it human or machine. It will have
                        this queer tendency to have the same eyes as the guy over in the corner,
                        luxuriating in a puddle of his own urine.

                        Comment

                        • Lawrence Oluyede

                          #27
                          Re: Still Loving Python

                          Il 2005-12-14, Daniel Crespo <dcrespo@gmail. com> ha scritto:[color=blue]
                          > PyGTK is crossplatform, that's true, but it looks very ugly under
                          > Windows and don't know under MacOS (if it's supported).[/color]

                          You can use themes. Under MacOSX you have to install X11, but a native
                          version in on the way.
                          [color=blue]
                          > I couldn't find
                          > the way for get it running with an atractive look & feel under Windows
                          > after compiling it. Also, it needs the GTK+ Runtime Environment. I use
                          > wxPython and it is very very very very good. It's not perfect, but IMO,
                          > it is much better than PyGTK. PyGTK is good if you intend to develop
                          > for Linux.[/color]

                          So wxPython doesn't need a runtime? I don't think so. wxPython for me
                          sucks under Linux (built on gtk2) and I don't like its API at all. It
                          seems a bit awkward to me. Anyway... what do you mean with "much better" ?

                          --
                          Lawrence - http://www.oluyede.org/blog
                          "Anyone can freely use whatever he wants but the light at the end
                          of the tunnel for most of his problems is Python"

                          Comment

                          • Peter Decker

                            #28
                            Re: Still Loving Python

                            On 14 Dec 2005 13:49:39 -0000, TwistyCreek <anon@comments. header> wrote:
                            [color=blue]
                            > And by the by... visual tools ARE evil. <nfgaa>
                            >
                            > It's like your dad getting his drunken bar buddies to plow your mother
                            > because he's too fat to do it himself. The unfortunate offspring of any
                            > such union is equally the bastard be it human or machine. It will have
                            > this queer tendency to have the same eyes as the guy over in the corner,
                            > luxuriating in a puddle of his own urine.[/color]

                            Wow, I can't think of a response that would make you look more
                            clueless than what you just wrote.

                            And thank you for making my point: zealots have no place in a
                            discussion list, since they are incapable of discussing.

                            --

                            # p.d.

                            Comment

                            • Martin Christensen

                              #29
                              Re: Still Loving Python

                              -----BEGIN PGP SIGNED MESSAGE-----
                              Hash: SHA1
                              [color=blue][color=green][color=darkred]
                              >>>>> "Bengt" == Bengt Richter <bokr@oz.net> writes:[/color][/color][/color]
                              Bengt> De gustibus non disputandum, or whatever ;-)

                              Yeah, and quidquid latine dictum sit, altum viditur. :-)

                              Martin
                              -----BEGIN PGP SIGNATURE-----
                              Version: GnuPG v1.4.1 (GNU/Linux)
                              Comment: Using Mailcrypt+GnuPG <http://www.gnupg.org>

                              iEYEARECAAYFAkO gIuoACgkQYu1fMm OQldULYwCgjZovL w/gTJ8I/z/Wem203aca
                              DUUAoJ7GNNn2QOr mFINrgw58OkRnBm JU
                              =mUHX
                              -----END PGP SIGNATURE-----

                              Comment

                              • Mike Meyer

                                #30
                                Re: Still Loving Python

                                bokr@oz.net (Bengt Richter) writes:[color=blue]
                                > A single click compiles, links and runs the resulting independent windows .exe in a fraction of a second
                                > for the above, and I can see the hint, kill the .exe, and go on where I was.[/color]

                                Click? Yuck. If I wanted it, I've had environments where a single
                                keystroke (much better) compiled, linked and ran the resulting
                                app. Not in a fraction of a second, but that's sort of irrelevant to
                                the GUI/non-GUI question.

                                <mike
                                --
                                Mike Meyer <mwm@mired.or g> http://www.mired.org/home/mwm/
                                Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.

                                Comment

                                Working...