renaming in the wx package (proposal)

Hi all,

Renaming convention in the core wx library
My proposal:
Remove the wx prefix of *all* the member names in the
new wx library, including names starting with a WX, like.
WXK_RETURN, WXK_ESCAPE, ...

Comments from the community?

Jean-Michel Fauth, Switzerland

Hi,

This is a first time offering to this mailing list (I'm fairly new to
Python/wxPython - but fairly old to programming languages and program
development).

Sorry to be a differ-begger, but I would be in favor of keeping the wx
prefixes.

They add clarity when programs get bigger or when code is revisited long
after it was written.

They're also helpful during debugging, to note the module or function
with problems is clearly one from a boxed set, and not one that I may
have written with a similar name (or usually vice versa).

For me, a major part of clear programming entails the use of good,
consistent naming conventions. The prefixes help to reduce confusion in
my own naming conventions (since I wouldn't write a function that
started with 'wx', I benefit by getting an automatic pointer to the
right modules, or documentation set).

I tend to write some 'tainted' class objects during development, to test
a piece of logic or a concept (and I suspect others do, too). The
prefixes help identify what has to be moved to a proper object during
cleanup.

And I think the prefixes help when plodding though documentation and
you're trying to figure out which arguments, calls, events, etc. have an
affect on what you're trying to understand.

To over emphasize the clarity point, would this mailing list become
Python-users@lists.windows.org, or possibly just users@lists.org?

Thanks for the opportunity to voice an opinion,
Dan Cherry, Florida, USA

···

-----Original Message-----
From: Jean-Michel Fauth [mailto:jmfauth@bluewin.ch]
Sent: Sunday, June 01, 2003 2:12 AM
To: wxpython-users@lists.wxwindows.org
Subject: [wxPython-users] renaming in the wx package (proposal)

Hi all,

Renaming convention in the core wx library
My proposal:
Remove the wx prefix of *all* the member names in the
new wx library, including names starting with a WX, like.
WXK_RETURN, WXK_ESCAPE, ...

Comments from the community?

Jean-Michel Fauth, Switzerland

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwindows.org
For additional commands, e-mail: wxPython-users-help@lists.wxwindows.org

"Dan Cherry" <dscherry@bellsouth.net> writes:

Hi,

This is a first time offering to this mailing list (I'm fairly new to
Python/wxPython - but fairly old to programming languages and program
development).

Sorry to be a differ-begger, but I would be in favor of keeping the wx
prefixes.

Then don't use the new wx package. It's your choice.

They add clarity when programs get bigger or when code is revisited long
after it was written.

They're also helpful during debugging, to note the module or function
with problems is clearly one from a boxed set, and not one that I may
have written with a similar name (or usually vice versa).

For me, a major part of clear programming entails the use of good,
consistent naming conventions. The prefixes help to reduce confusion in
my own naming conventions (since I wouldn't write a function that
started with 'wx', I benefit by getting an automatic pointer to the
right modules, or documentation set).

I tend to write some 'tainted' class objects during development, to test
a piece of logic or a concept (and I suspect others do, too). The
prefixes help identify what has to be moved to a proper object during
cleanup.

And I think the prefixes help when plodding though documentation and
you're trying to figure out which arguments, calls, events, etc. have an
affect on what you're trying to understand.

To over emphasize the clarity point, would this mailing list become
Python-users@lists.windows.org, or possibly just users@lists.org?

All of your arguments are addressed much better by modules/packages
and namespaces, both of which are wonderful features of Python. If
you don't believe me, just keep using the old wxPython.wx module which
will likely support the wx prefix for years and years. But the new wx
namespace will not have prefixes since the wx package name does the
job just fine. This horse was pronounced dead ages ago. :wink:

Thanks for the opportunity to voice an opinion,

You're welcome. Ditto.

···

--
Patrick K. O'Brien
Orbtech http://www.orbtech.com/web/pobrien
-----------------------------------------------
"Your source for Python programming expertise."
-----------------------------------------------

"Jean-Michel Fauth" <jmfauth@bluewin.ch> writes:

Hi all,

Renaming convention in the core wx library
My proposal:
Remove the wx prefix of *all* the member names in the
new wx library, including names starting with a WX, like.
WXK_RETURN, WXK_ESCAPE, ...

Comments from the community?

This has been discussed. Search the archives for details. One
suggestion was to change all the key constants to KEY_RETURN, etc, but
that breaks with the convention used by wxWindows, making it harder to
communicate with wxWindows developers, so Robin wasn't in favor of it.

···

--
Patrick K. O'Brien
Orbtech http://www.orbtech.com/web/pobrien
-----------------------------------------------
"Your source for Python programming expertise."
-----------------------------------------------

Sounds good to me. We've already broken from wxWindows by eliminating
the 'wx' prefix. And something like "KEY_RETURN" is not going to
demolish our ability to communicate back and forth between the C++ and
Python communities.

···

On Saturday 31 May 2003 11:12 pm, Jean-Michel Fauth wrote:

Hi all,

Renaming convention in the core wx library
My proposal:
Remove the wx prefix of *all* the member names in the
new wx library, including names starting with a WX, like.
WXK_RETURN, WXK_ESCAPE, ...

Comments from the community?

--
Chuck
http://ChuckEsterbrook.com