Re: Creating a non-focused window

2008-05-22 Thread Tiberius DULUMAN
> The only way I know to do that is by calling window.set_accept_focus(False) > before window.show(). The serious flaw with that method is that the > resulting window, while being prevented from stealing the focus, also can > not receive focus at any later time, even by intentional user action. > W

ComboBox displaying data from a TreeStore

2008-04-15 Thread Tiberius Duluman
Hello I have one question about a ComboBox displaying data from a TreeStore. How can I make it to display the entire path? For example, when a child is selected, I want it to display something like "/item n/subitem c/subitem xx" In the application that I'm working to, display only child name, the

Re: Cant get GtkTextBuffer from GtkTextView widget

2008-04-14 Thread Tiberius DULUMAN
The handler should be: static void handler(GtkWidget *widget, GtkTextView *tview) { GtkTextBuffer *buffer = NULL; GtkTextIter iterator; buffer = gtk_text_view_get_buffer(tview); g_assert(buffer != NULL); <<< assert that it is not null gtk_text_buffer_get_end_iter(b

TreeModelFilter and TreeModelSort performance

2008-01-12 Thread Tiberius Duluman
I'm writing a window where users can filter a list of items. They enter a search criteria in a text box, and a TreeView is filled with the items that satisfy their criteria. Items are sorted by their relevance. In order to do this, I've loaded all the items into a ListStore. The ListStore contains

row_activated and modifiers keys

2008-01-11 Thread Tiberius DULUMAN
On the handler of the row_activated signal of the TreeView, I need to implement different behaviour if CTRL or SHIFT key is pressed. ( ie. when double-clicking a row something is happening, and when double-clicking it and SHIFT key is pressed something else should happen ). Does anyone have any ide

Re: GtkComboBox - how to clear and repopulate in one step?

2007-12-06 Thread Tiberius DULUMAN
You may create the combo box using gtk_combo_box_new_with_model. You insert all the items that may appear in the second combo box in a GtkListStore. Along with the text, you create a column that contains the index of the items in the first combo box that they belong to. Use a GtkTreeModelFilter ove