Skip Menu |

This queue is for tickets about the Tk CPAN distribution.

Report information
The Basics
Id: 43718
Status: open
Priority: 0/
Queue: Tk

People
Owner: Nobody in particular
Requestors: djibrilo [...] yahoo.fr
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



CC: bug-tk [...] rt.cpan.org
Subject: [Tk::ProgressBar] Suggestion update (Tk-804.028)
Date: Fri, 27 Feb 2009 20:54:04 +0000 (GMT)
To: slaven [...] rezic.de
From: djibrilo <djibrilo [...] yahoo.fr>
Dear slaven, Tk version : Tk-804.028 and Tk-804.028_501 I want to tell thank you for your module because It's work very well. I want to suggest you 2 updates to your [Tk::ProgressBar module. 1 - When I use value method ( $Widget->value($Value); ), I have to refresh the widget with (update) if I want to see the modification inthe widget. Can you add an update widget in you code, I have test and it's work well. ProgressBar.pm sub value { my $c = shift; my $val = defined($c->{'-variable'}) ? $c->{'-variable'} : \$c->{'-value'}; my $old = defined($$val) ? $$val : $c->{Configure}{'-from'}; if(@_) { my $value = shift; $$val = defined($value) ? $value : $c->{Configure}{'-from'}; _layoutRequest($c,2); } $c->update; # <===== add an update here $old; } 2- It's possible to create another option in constructeur new as -text to add this text in the rectangle (for ex 10%) ? If you want my participation I can try to understand your code and help you. Best regards Djibril
Le Ven. Fév. 27 18:41:43 2009, djibrilo@yahoo.fr a écrit : Show quoted text
> Dear slaven, > > > Tk version : Tk-804.028 and Tk-804.028_501 > > I want to tell thank you for your module because It's work very well. > I want to suggest you 2 updates to your [Tk::ProgressBar module. > > 1 - When I use value method ( $Widget->value($Value); ), I have to > refresh the widget > with (update) if I want to see the modification inthe widget. > Can you add an update widget in you code, I have test and it's work > well. > > ProgressBar.pm > > sub value { > my $c = shift; > my $val = defined($c->{'-variable'}) > ? $c->{'-variable'} > : \$c->{'-value'}; > my $old = defined($$val) ? $$val : $c->{Configure}{'-from'}; > > if(@_) { > my $value = shift; > $$val = defined($value) ? $value : $c->{Configure}{'-from'}; > _layoutRequest($c,2); > } > > $c->update; # <===== add an update here > > $old; > } > > 2- It's possible to create another option in constructeur new as -text > to add this text in the rectangle (for ex 10%) ? > > If you want my participation I can try to understand your code and > help you. > > Best regards > > Djibril > >
Tk::ProgressBarPlus module is available and allow us to display Percent in progressBar. But we have to update widget to update progress bar.