How can I set the GtkTreeSelection
to a specific row, to the row number 3
?
I can set the selection to the GtkTreeIter
, but how can i set the iter
to the row number 3
?
I didn't find anything useful at the google search, so I didn't try anything yet because I don't know what.
I hope you can help me and give me information about my questions!
EDIT:
GtkTreeModel *model = gtk_tree_view_get_model(GTK_TREE_VIEW(treeview));
GtkTreePath *path = gtk_tree_path_new_from_indices(3, -1);
gtk_tree_model_get_iter(model, &iter, path);
gtk_tree_path_free(path);
gtk_tree_selection_select_path(treeview_selection, path);
-> Don't work
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…