Unretrievable GtkWidget pointers in GtkItemFactory



Hi,

I think I've come across an obscure bug in GtkItemFactory. Either that
or I'm doing something I'm not supposed too.

I need to iterate over a static GtkItemFactoryEntry array and retrieve
some widget pointers by calling 'gtk_item_factory_get_widget'; using the
path from each array item. Everything works OK, until you come across a
path with an underscore character. In this case
'gtk_item_factory_get_widget' returns NULL. I think this happens because
when each item is created 'gtk_item_factory_create_item' calls the
static function 'gtk_item_factory_parse_path to parse out the underscore
and set the mnemonic character. The parsed path is then stored in the
internal widget list and if the querying path contains an underscore the
two paths wont match.
 
Perhaps 'gtk_item_factory_get_widget' should parse the supplied path so
this doesn't happen.

Jeff.




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