Beefy Boxes and Bandwidth Generously Provided by pair Networks Cowboy Neal with Hat
laziness, impatience, and hubris
 
PerlMonks  

(ichi) Re: Regex tutor in Perl/Tk

by ichimunki (Priest)
on Jul 01, 2002 at 15:40 UTC ( #178584=note: print w/ replies, xml ) Need Help??


in reply to Regex tutor in Perl/Tk

Just a suggestion (not a criticism!), when you have a lot of Tk widgets that share properties, like you do here with font, justify, offvalues, etc, you might consider simply making an array of those properties and stuffing that into the property list for each widget instead.

my @props = ( '-color' => COLOR, '-justify' => 'left', '-etc' => 'etc' ); my $button = $root->Button( -text => 'Sample', @props )->pack();
This keeps your code more concise and makes the differences between the widgets easier to see.


Comment on (ichi) Re: Regex tutor in Perl/Tk
Download Code
Re: (ichi) Re: Regex tutor in Perl/Tk
by Popcorn Dave (Abbot) on Jul 01, 2002 at 16:16 UTC
    Thanks for that!

    Every time I think I know Perl... : )

    Some people fall from grace. I prefer a running start...

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2014-04-16 11:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (424 votes), past polls