From 90834467e88065c377170df0ba7514489d1f15b6 Mon Sep 17 00:00:00 2001 From: etienne Date: Mon, 31 Mar 2003 14:00:43 +0000 Subject: Gestion du packer revue --- Perl/Zinc/Debug.pm | 41 ++++++++++++++++++++++++++--------------- 1 file changed, 26 insertions(+), 15 deletions(-) diff --git a/Perl/Zinc/Debug.pm b/Perl/Zinc/Debug.pm index fedfe9d..62306ae 100644 --- a/Perl/Zinc/Debug.pm +++ b/Perl/Zinc/Debug.pm @@ -760,6 +760,7 @@ sub showresult { $result_fm->pack(-padx => 10, -pady => 10, -ipadx => 10, -fill => 'both', + -expand => 1, ); } # end showresult @@ -775,27 +776,27 @@ sub showalloptions { # header #---------------- - my $fm_top = $tl->Frame()->pack(-fill => 'both', -expand => 1, + my $fm_top = $tl->Frame()->pack(-fill => 'x', -expand => 0, -padx => 10, -pady => 10, -ipadx => 10, ); # show item my $btn = $fm_top->Button(-height => 2, -text => 'Show Item', - )->pack(-side => 'left', -fill => 'both', -expand => 1); + )->pack(-side => 'left', -fill => 'x', -expand => 1); $btn->bind('<1>', [\&highlightitem, $zinc, $item, 0]); $btn->bind('<2>', [\&highlightitem, $zinc, $item, 1]); $btn->bind('<3>', [\&highlightitem, $zinc, $item, 2]); # bounding box $btn = $fm_top->Button(-height => 2, -text => 'Bounding Box', - )->pack(-side => 'left', -fill => 'both', -expand => 1); + )->pack(-side => 'left', -fill => 'x', -expand => 1); $btn->bind("<1>", [\&showbbox, $zinc, $item]); $btn->bind("", [\&hidebbox, $zinc]); # transformations $btn = $fm_top->Button(-height => 2, -text => "treset") - ->pack(-side => 'left', -fill => 'both', -expand => 1); + ->pack(-side => 'left', -fill => 'x', -expand => 1); $btn->bind('<1>', [\&showtransfo, $zinc, $item, 0]); $btn->bind('<2>', [\&showtransfo, $zinc, $item, 1]); $btn->bind('<3>', [\&showtransfo, $zinc, $item, 2]); @@ -869,6 +870,7 @@ sub showcoords { -height => 200, )->pack(-padx => 10, -pady => 10, -ipadx => 10, + -expand => 1, -fill => 'both'); my @contour; my $contournum = $zinc->contour($item); @@ -945,7 +947,7 @@ sub showgroupattributes { # header #----------- - my $fm_top = $tl->Frame()->pack(-fill => 'both', -expand => 1, + my $fm_top = $tl->Frame()->pack(-fill => 'x', -expand => 0, -padx => 10, -pady => 10, -ipadx => 10, ); @@ -994,6 +996,7 @@ sub showgroupattributes { -height => 400, )->pack(-padx => 10, -pady => 10, -ipadx => 10, + -expand => 1, -fill => 'both'); my $r = 1; @@ -1108,6 +1111,7 @@ sub showgroupcontent { -height => 200, )->pack(-padx => 10, -pady => 10, -ipadx => 10, + -expand => 1, -fill => 'both'); &showattributes($zinc, $fm, [@items]); @@ -1563,7 +1567,7 @@ sub showattributes { } # tags my @tags = $zinc->gettags($item); - &entryoption($fm, $item, $zinc, -tags, join("\n", @tags), 50, scalar @tags) + &entryoption($fm, $item, $zinc, -tags, join("\n", @tags), 30, scalar @tags) ->grid(-row => $i, -col => 10, -sticky => 'nswe', -ipadx => 5); # other options @@ -1843,10 +1847,13 @@ sub showHelpAboutAttributes { $helptree_tl = $zinc->Toplevel; $helptree_tl->title("Help about attributes"); - my $text = $helptree_tl->Text(-font => scalar $zinc->cget(-font), - -wrap => 'word', - -foreground => 'gray10', - ); + my $text = $helptree_tl->Scrolled('Text', + -font => scalar $zinc->cget(-font), + -wrap => 'word', + -height => 30, + -foreground => 'gray10', + -scrollbars => 'oe', + ); $text->tagConfigure('keyword', -foreground => 'darkblue'); $text->tagConfigure('title', -foreground => 'ivory', -background => 'gray60', @@ -1856,11 +1863,11 @@ sub showHelpAboutAttributes { $text->insert('end', " To highlight a specific item\n", 'title'); $text->insert('end', - "\nFirst column contains items identifiers buttons you can press to ". - "highlight corresponding items in the application.\n"); + "\nThe column labeled 'Id' contains items identifiers buttons you ". + "can press to highlight corresponding items in the application.\n"); &infoAboutHighlighting($text); - $text->insert('end', "\n\nThird column contains groups identifiers buttons you can ". - "press to display groups content and attributes.\n\n"); + $text->insert('end', "\n\nThe column labeled 'Group' contains groups identifiers ". + "buttons you can press to display groups content and attributes.\n\n"); $text->insert('end', " To display the bounding box of an item\n", 'title'); $text->insert('end', "\nUse the buttons of the column labeled ". "'Bounding Box'.\n\n"); @@ -1868,7 +1875,11 @@ sub showHelpAboutAttributes { $text->insert('end', "\nMost of information fields are editable. A simple ". "colored feedback shows which attributes have changed. Use <"); $text->insert('end', "Control-z", "keyword"); - $text->insert('end', "> sequence to restore the initial value\n"); + $text->insert('end', "> sequence to restore the initial value\n\n"); + $text->insert('end', " To visualize item's transformations\n", 'title'); + $text->insert('end', "\nClick on the "); + $text->insert('end', "treset", "keyword"); + $text->insert('end', " button in the first column. This action restores the item's transformation to its initial state. Transition is displayed with a fade-in/fade-out animation (needs OpenGL rendering)\n"); $text->configure(-state => 'disabled'); -- cgit v1.1