hello,

your question seems very similar to Re^2: why is the size of notebooks area smaller than main window (Tk).. normally is preferable to continue the old thread instead of creating a new one..

Anyway.. even if i have not a solution I have some suggestion: first our is not appropriate in the example: my is better.

You also repack two times the same widget, creating a bit of confusion; also the withdraw / Popup is avoidable.

Then a smaller example will be better to play with. You can add Tk::WidgetDump to see how each part of your Tk program is configured, I find it very useful.

In my smaller example seems that anything i do the Tk::NotePad object has a limited size with or without -fill => 'both', -expand => 1

Can be this related to the fact (in the docs) that: The options -width and -height do not work. ?

#!/usr/bin/perl # THIS DOES NOT RESOLVE YOR ISSUE, but is simpler to play with use warnings; use strict; use Tk; use Tk::NoteBook; use Tk::Pane; my $mw = MainWindow->new; $mw->packPropagate(0);#->geometry('300x200'); my $frame = $mw->Scrolled( 'Frame',-background=>'purple', -scrollbars +=> "s") ->pack(-expand=>1, -fill=>'both', -anchor=>' +nw'); my $nb_widget = $frame->NoteBook->pack(-expand=>1, -fill=>'both'); for (1..20){ $nb_widget->add("page$_", -label=>"PAGE $_") ->Scrolled("Text", -scrollbars => "e", -wrap = +> 'none') ->pack(-expand => 1, -fill => 'both');; } MainLoop;

L*

There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.

In reply to Re: Perl Tk Notebook not filling main window height by Discipulus
in thread Perl Tk Notebook not filling main window height by madhusudhan_s

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.