From 968545ca98d391949eac89a1cf168f0c1812fc7f Mon Sep 17 00:00:00 2001 From: Guillaume Cottenceau Date: Fri, 30 Jan 2004 15:03:17 +0000 Subject: hack :( if ' ' is at the beginning of a text section, don't forget it, substitute with an unbreakable space because gtk allocates too much space otherwise --- perl-install/ugtk2.pm | 3 +++ 1 file changed, 3 insertions(+) (limited to 'perl-install/ugtk2.pm') diff --git a/perl-install/ugtk2.pm b/perl-install/ugtk2.pm index 430c5f734..cb21fccf7 100644 --- a/perl-install/ugtk2.pm +++ b/perl-install/ugtk2.pm @@ -799,6 +799,9 @@ sub wrap_paragraph { my $currentx; foreach (@elements) { my ($text, %options) = @$_; + #- hack :( if ' ' is at the beginning, don't forget it, substitute + #- with an unbreakable space because gtk allocates too much space otherwise + $text =~ /^ (.*)/ and $text = " $1"; my @newlines = get_text_coord($text, $widget4style, $max_width, $currentx, $ydec); $currentx = $newlines[-1]{'x'} + $newlines[-1]{width}; $ydec = $newlines[-1]{'y'}; -- cgit v1.2.1