Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #42757
| Newsgroups | comp.lang.python |
|---|---|
| Date | 2013-04-04 08:28 -0700 |
| References | <515cd919$0$29966$c3e8da3$5496439d@news.astraweb.com> <c338b844-e9ce-46a7-9daf-20374372390e@googlegroups.com> <roy-46860E.07523804042013@news.panix.com> |
| Message-ID | <59b9df11-b5b5-430a-b37f-958cbbf9f3f0@googlegroups.com> (permalink) |
| Subject | Re: In defence of 80-char lines |
| From | llanitedave <llanitedave@veawb.coop> |
On Thursday, April 4, 2013 4:52:38 AM UTC-7, Roy Smith wrote: > In article <c338b844-e9ce-46a7-9daf-20374372390e@googlegroups.com>, > > llanitedave <llanitedave@veawb.coop> wrote: > > > > > I would hate to have to break up this line, for instance: > > > > > > self.mainLabel.SetFont(wx.Font(12, wx.DEFAULT, wx.NORMAL, wx.BOLD, faceName = > > > "FreeSans")) > > > > I would write that as some variation on > > > > self.mainLabel.SetFont(wx.Font(12, > > wx.DEFAULT, > > wx.NORMAL, > > wx.BOLD, > > faceName="FreeSans")) > > > > This lets the reader see at a glance that all the arguments go with > > wx.Font(), not with SetFont(), without having to visually parse and > > match parenthesis levels. > > > > Actually, I would probably break it up further as: > > > > my_font = wx.Font(12, > > wx.DEFAULT, > > wx.NORMAL, > > wx.BOLD, > > faceName="FreeSans") > > self.mainLabel.SetFont(my_font) > > > > The last thing on my mind when deciding how to format this is whether I > > would be able to punch it onto a single card. To each their own, definitely. For myself, I don't see the utility in adding a bunch of what appears to be superfluous horizontal white space at the expense of extra lines to scroll down. I like to limit my scrolling needs in *both* directions. (Although I do tend to be fairly generous with blank lines to break up code "paragraphs")
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
In defence of 80-char lines Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-04-04 01:36 +0000
Re: In defence of 80-char lines Andrew Berg <bahamutzero8825@gmail.com> - 2013-04-03 20:59 -0500
Re: In defence of 80-char lines Mitya Sirenef <msirenef@lightbird.net> - 2013-04-03 22:40 -0400
Re: In defence of 80-char lines llanitedave <llanitedave@veawb.coop> - 2013-04-03 21:32 -0700
Re: In defence of 80-char lines Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-04-04 06:33 +0000
Re: In defence of 80-char lines gregor <gregor@ediwo.com> - 2013-04-04 08:40 +0200
Re: In defence of 80-char lines Peter Otten <__peter__@web.de> - 2013-04-04 08:43 +0200
Re: In defence of 80-char lines Tim Chase <python.list@tim.thechases.com> - 2013-04-04 06:09 -0500
Re: In defence of 80-char lines Roy Smith <roy@panix.com> - 2013-04-04 07:52 -0400
Re: In defence of 80-char lines llanitedave <llanitedave@veawb.coop> - 2013-04-04 08:28 -0700
Re: In defence of 80-char lines Jason Swails <jason.swails@gmail.com> - 2013-04-04 08:18 -0400
Re: In defence of 80-char lines Joshua Landau <joshua.landau.ws@gmail.com> - 2013-04-04 18:18 +0100
Re: In defence of 80-char lines Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2013-04-04 18:22 -0400
Re: In defence of 80-char lines rusi <rustompmody@gmail.com> - 2013-04-03 21:56 -0700
Re: In defence of 80-char lines Rui Maciel <rui.maciel@gmail.com> - 2013-04-04 08:15 +0100
Re: In defence of 80-char lines Jason Swails <jason.swails@gmail.com> - 2013-04-04 08:13 -0400
Re: In defence of 80-char lines Roy Smith <roy@panix.com> - 2013-04-04 08:39 -0400
Re: In defence of 80-char lines Jason Swails <jason.swails@gmail.com> - 2013-04-04 09:23 -0400
Re: In defence of 80-char lines Neil Cerutti <neilc@norwich.edu> - 2013-04-04 15:56 +0000
Re: In defence of 80-char lines Kushal Kumaran <kushal.kumaran+python@gmail.com> - 2013-04-04 23:04 +0530
Re: In defence of 80-char lines Roy Smith <roy@panix.com> - 2013-04-04 19:55 -0400
Re: In defence of 80-char lines Mitya Sirenef <msirenef@lightbird.net> - 2013-04-04 12:12 -0400
Re: In defence of 80-char lines jmfauth <wxjmfauth@gmail.com> - 2013-04-04 13:28 -0700
Re: In defence of 80-char lines Jason Swails <jason.swails@gmail.com> - 2013-04-04 17:00 -0400
Re: In defence of 80-char lines Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-04-05 00:14 +0000
csiph-web