View Single Post
Old 11-17-2009, 02:58 AM   #122
hansel
JSR FFD2
hansel can extract oil from cheesehansel can extract oil from cheesehansel can extract oil from cheesehansel can extract oil from cheesehansel can extract oil from cheesehansel can extract oil from cheesehansel can extract oil from cheesehansel can extract oil from cheese
 
hansel's Avatar
 
Posts: 305
Karma: 1045
Join Date: Aug 2008
Location: Rotterdam, Netherlands, Europe, Sol 3
Device: iliad
Quote:
Originally Posted by ericshliao View Post
I have one question: why the loading time of C apps (without modifying registry.xml) much longer than Lua?
Lua is not only cool, it's also fast

Seriously, it must be something in the way your app is coded. I did a small C gtk app once, it started in 7-8 seconds.

Some ideas and guesses:
  • Do you use xx in both cases? xx turns the led off when started...
  • If your app has items with a cursor: disable cursor blinking! With xedpmgr or xx this causes many display updates (eats a lot of cpu ( and battery)). This is handled automatically in the lgob-iliad package for GtkEntry an GtkTextview. The code is:

    Code:
      // ptr is a pointer to a   GtkEntry an GtkTextview  
            GtkSettings* settings = gtk_widget_get_settings(ptr);
            g_object_set(settings, "gtk-cursor-blink", (int)FALSE, NULL);

PS: xx has an option to delay the display refreshing: when you do 'myapp | xx -p -s6 ' , the refreshings starts after 6 seconds, possibly avoiding some needless refreshes while myapp is starting...

Last edited by hansel; 11-17-2009 at 03:00 AM. Reason: typos
hansel is offline   Reply With Quote