After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 675990 - gtk_tree_column_set_visible badly interact with the a11y code
gtk_tree_column_set_visible badly interact with the a11y code
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Accessibility
3.5.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2012-05-13 22:10 UTC by Christophe Fergeau
Modified: 2012-07-08 23:32 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Christophe Fergeau 2012-05-13 22:10:14 UTC
gtk_tree_column_set_visible code does:

priv->visible = visible;
_gtk_tree_view_accessible_toggle_visibility (GTK_TREE_VIEW (priv->tree_view), tree_column);


_gtk_tree_view_accessible_toggle_visibility then uses:
id = get_column_number (treeview, column);

get_column_number iterates over the treeview columns and skip the non-visible ones. If it could not find the column, it outputs a runtime warning through 
g_return_val_if_fail (i < gtk_tree_view_get_n_columns (treeview), 0);

When hiding a column, the column will be marked as non-visible before get_column_number is called, so this function will skip the column as it's non visible, and will then outputs a runtime warning. The a11y code will then mark the column 0 as visible/non-visible instead of working with the right column.
Comment 1 Benjamin Otte (Company) 2012-07-08 23:32:13 UTC
I've pushed a potential fix to master. Could you test it works? If it does, I'll cherry-pick it into the 3.4 branch.