Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • See the geometry() method.
    • Yeah, I've seen the geometry() method -- I don't see how to make it be "just the right size" the way it normally would be without that Pack thingamajigger.
      • Wow! What a funny happenstance of your comment and the random (as in I Ching) Larry Wall quote that I was just served up:


        What about WRITING it first and rationalizing it afterwords? :-)

        --Larry Wall in <8162@jpl-devvax.JPL.NASA.GOV>

      • Oh, I see what you mean. Here's your code, revamped by me (plus an "exit" button). This work like you want?

        use strict;
        use Tk;
        use Tk::Pane;

        my $main = MainWindow->new;

        my($container, $pane);

        $pane = $main->Scrolled('Pane',
           -scrollbars => 'osoe',
           -sticky     => 'nsew',
           -gridded    => 'y'
        );
        $pane->pack(-fill => 'both', -expand => 1,);

        my $width = 0;
        my $height = 0;

        for(0 .. 10) {
           my $label  = $pane->Label(