Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Perl TK performance issue

by perltux (Scribe)
on Dec 05, 2012 at 09:31 UTC ( #1007246=note: print w/replies, xml ) Need Help??


in reply to Perl TK performance issue

Ok, just an update, I have narrowed down the performance issue to the BrowseEntry widgets, if I comment out the BrowseEntry widgets then the window shows up almost instantly.

So it looks like BrowseEntry widgets (or at least the way I'm using them) are very cpu intensive.

What could be functionally equivalent but more efficient substitute widgets for the BrowseEntry widget?

Replies are listed 'Best First'.
Re^2: Perl TK performance issue
by Anonymous Monk on Dec 05, 2012 at 11:02 UTC

    plain listbox/combobox?

    FWIW, it takes about 2 seconds for the sub to run for me, plus a few more (I guesstimate 4) for Tk to actually draw it

    OTOH, wxPerl pops up an equal amount of widgets in 1 sec, and it takes 1 sec to destroy them all

    Both take up about the same amount of RAM

    Its fairly similar to Tk (snippet of code generated by wxglade)

    $self->{label_A} = Wx::StaticText->new($self, -1, "A", wxDefaultPositi +on, wxDefaultSize, ); $self->{bank1_sizer2_combo1} = Wx::ComboBox->new($self, -1, "", wxDefa +ultPosition, wxDefaultSize, [], wxCB_DROPDOWN); $self->{bank1_sizer2_combo2} = Wx::ComboBox->new($self, -1, "", wxDefa +ultPosition, wxDefaultSize, [], wxCB_DROPDOWN); $self->{bank1_sizer2_slider} = Wx::Slider->new($self, -1, 0, 0, 10, wx +DefaultPosition, wxDefaultSize, wxSL_VERTICAL|wxSL_AUTOTICKS|wxSL_LAB +ELS|wxSL_TOP); $self->{bank2_sizer2_combo1} = Wx::ComboBox->new($self, -1, "", wxDefa +ultPosition, wxDefaultSize, [], wxCB_DROPDOWN); $self->{bank2_sizer2_combo2} = Wx::ComboBox->new($self, -1, "", wxDefa +ultPosition, wxDefaultSize, [], wxCB_DROPDOWN); $self->{bank2_sizer2_slider} = Wx::Slider->new($self, -1, 0, 0, 10, wx +DefaultPosition, wxDefaultSize, wxSL_VERTICAL|wxSL_AUTOTICKS|wxSL_LAB +ELS|wxSL_TOP); $self->{bank3__ck_sizer2_a} = Wx::CheckBox->new($self, -1, "", wxDefau +ltPosition, wxDefaultSize, ); $self->{bank1_sizer2_combo1}->SetMinSize(Wx::Size->new(30, 21)); $self->{bank1_sizer2_combo1}->SetSelection(-1); $self->{grid_sizer_1} = Wx::GridSizer->new(49, 3, 0, 0); $self->{bank1_sizer2} = Wx::BoxSizer->new(wxHORIZONTAL); $self->{bank2_sizer2} = Wx::BoxSizer->new(wxHORIZONTAL); $self->{bank3__ck_sizer2} = Wx::BoxSizer->new(wxHORIZONTAL); $self->{grid_sizer_1}->Add($self->{bank1_sizer2}, 1, wxEXPAND, 0); $self->{grid_sizer_1}->Add($self->{bank2_sizer2}, 1, wxEXPAND, 0);

    Distribution is easy with http://www.citrusperl.com//http://www.cavapackager.com/ for many platforms

    There is even my wxWidgets / wxPerl / wxGlade tutorial

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1007246]
help
Chatterbox?
[Corion]: Meh. I need to find myself a better "programming" feed than r/programming (which is just HackerNews reposts and advertisements, very little code). Maybe I should select a list of links that I liked on r/programming and then google for ...
[Corion]: ... an aggregator site that also listed (ideally) all of these links once. And maybe also have an exclude list to blacklist some of the most spammy links that the site may have never mentioned at all
[marto]: I gave up reading HN at all, and feel much better for it :P
[Corion]: Now, how to best automate that Google search ... :-)
[Corion]: marto: Yeah, I'm also short of not reading it at all. I already stopped reading it in the morning because it gave me a foul mood.

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (7)
As of 2017-07-24 13:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I came, I saw, I ...
























    Results (354 votes). Check out past polls.