Re: Gtk::Notebook page-switch decreasing response



On Thu, 2007-05-17 at 12:02 +0200, angelo wrote:
> Hi all,
> 
> i have developed a gtkmm application and i have seen a strange response 
> of the notebook widget, quite sure that i'm missing some notion on using 
> the widgets in the correct way.
> 
> This is the scenario:
> 
> I have a notebook with for example 5 pages added, all the 5 widgets are 
> TextView based widget. On the widgets i display the messages of some 
> different network logs.
> 
> On every textview based widget i've implemented a check of the line 
> count, to clean old lines, to mantain a limit of a maximum number of 
> lines displayed, about 200 for now.
> 
> By the way, i noticed that at the first startup, the notebook page 
> switching has a fast graphic response, and quite fast even whit all the 
> windows filled with 200 lines. As the time elapse, after some hours of 
> activities, the notebook page switching response is coming worse, im 
> talking of delay of 500msecs about, not so much, but the reactivity of 
> the page switching is really different  from the start.

I have not seen this myself, and I can't think what would cause it. You
might investigate with a tool such as Kcachegrind or oprofile, I
suppose.

> this is the function i've written for the TextView old-lines deletion, 
> and seems working fine:
> 
> void ScrollPanel::on_size_allocate (Gtk::Allocation& alloc)
> {
>     Gtk::ScrolledWindow::on_size_allocate(alloc);
> 
>     if (m_rtbBuffer->get_line_count() >= 200)
>     {
>         m_rtbBuffer->erase (m_rtbBuffer->begin(), 
> m_rtbBuffer->get_iter_at_line(50));
>     }
> 
>     /* new autoscroll, done reading ScrolledWindow documentation */
>     get_vadjustment()->set_value(
>         get_vadjustment()->get_upper()-get_vadjustment()->get_page_size());
> }
> 
> any help is very appreciated.
> 
> Angelo Dureghello
> 
> 
>  
> 
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list
-- 
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]