Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: Name spaces and Perl::Tk coding style

by elwarren (Priest)
on Oct 05, 2005 at 21:13 UTC ( #497748=note: print w/replies, xml ) Need Help??

in reply to Name spaces and Perl::Tk coding style

You are correct, put it into modules if you can. When I wrote an app with Win32::GUI I found myself constantly frustrated with scrolling through so much of the init code. Pages and pages just to setup the windows and labels. When I put it into modules it was easier to work with, but then I went overboard. I started trying to make it too much of a general purpose module for GUI apps, it got too complex, and got pushed back to the end of my "to work on later" list, and I haven't thought about it in years.

Ah, so much wasted code, never to see the light of day...
  • Comment on Re: Name spaces and Perl::Tk coding style

Replies are listed 'Best First'.
Re^2: Name spaces and Perl::Tk coding style
by TGI (Parson) on Oct 05, 2005 at 22:12 UTC

    I've been bitten by the excessive generality bug a few times as well. It's the easiest way to never finish a project. I've done in a few projects this way myself--on the good side, I learned a lot while doing it.

    My app is currently weighing in at around 3000 lines of code (including whitespace and comments, but not counting the libraries I wrote for backend stuff). It's just too damn big to navigate around easily. Amazingly, it is maintainable, I was able to get in and make some changes after 8 months away from working on it without too much pain. Let's hear it for good documentation practices.

    Any thoughts on the namespace issue? I'm planning on keeping the libraries in the same directory with the script, so top level names are OK. I'm leaning towards MyApp::PhoneList and MyApp::DisplayData and so forth.

    TGI says moo

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://497748]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (3)
As of 2023-03-20 19:15 GMT
Find Nodes?
    Voting Booth?
    Which type of climate do you prefer to live in?

    Results (59 votes). Check out past polls.