This is the example code from Tk::Compound's documentation with a couple of things added to make it runnable. Note the addition of -side => 'left' as an option to the pack command. Tk::pack is not my genoetry manager of choice, but it is simple for this demonstration. I would suggest developing amore than nodding acquaintance with "Mastering Perl/Tk" by Lidie and Walsh, published by O'Reilly.#!/usr/bin/perl -w use strict; use Tk; use Tk::Compound; my $parent = MainWindow->new(); my $b = $parent->Button; my $c = $b->Compound; $b->configure(-image => $c); $c->Line; $c->Bitmap(-bitmap => 'warning'); $c->Space(-width => 8); $c->Text(-text => "Warning", -underline => 0); $b->pack(-side => 'left'); MainLoop();
In reply to Re^3: Placement of image with Tk::Compound and Tk::Menu
by jdtoronto
in thread Placement of image with Tk::Compound and Tk::Menu
by ldln
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |