Home > Archive > PerlTk > May 2007 > Text and a close button in Notebook tab
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Text and a close button in Notebook tab
|
|
|
| Hello All,
I am relatively new to UI programming..
I am working on multiple tabs in the notebook, which can be added and
deleted
anytime by the user..
Currently i have some basic working stuff..arrived after some digging
in this group
It looks something like
my $tab = $mn->add("Page".$tab_index,
-label => $label[$tab_index],
-underline => 0);
$tab->Button(-image =>$close_icon,
-relief=>'groove',
-command => [sub {
$mn->delete("Page".$_[0]);
},$tab_index])
->pack( -side=>'top'
);
Here the tab label has the text and the close button is positioned at
the top within the page..
I am looking for a way to position the close button alongside the tab
label/text for every page.
thanks for any help.
Thanks,
Xabi
| |
| Dean Arnold 2007-05-04, 7:02 pm |
| Xabi wrote:
> Hello All,
>
> I am relatively new to UI programming..
>
> I am working on multiple tabs in the notebook, which can be added and
> deleted
> anytime by the user..
>
> Currently i have some basic working stuff..arrived after some digging
> in this group
> It looks something like
<snip/>
>
> I am looking for a way to position the close button alongside the tab
> label/text for every page.
>
> thanks for any help.
>
> Thanks,
> Xabi
>
Have you looked at Tk::DynaTabFrame ? It natively
supports small close buttons in the tabs.
See http://www.presicient.com/dynatabframe for details
and screenshots.
Dean Arnold
Presicient Corp.
| |
|
|
|
|
|
|
|