Commit 7b2d6e5c authored by Tristan Van Berkom's avatar Tristan Van Berkom

Make GtkTreeMenu a private class:

  - Removed GtkTreeMenu from gtk-docs.sgml
  - Removed GtkTreeMenu from gtk3-sections.txt
  - Removed GtkTreeMenu from gtk.symbols
  - Make GtkTreeMenu apis prefixed with '_' (including _get_type()).
  - Updated GtkComboBox sources to use the private apis
  - Updated GtkCellView to not mention #GtkTreeMenu in gtk-doc statements
  - Updated tests/testtreemenu to not use a GtkTreeMenu but still
    show a very fancy GtkComboBox
  - Moved gtktreemenu.h to private headers section in the makefile.
  - Removed include of gtktreemenu.h from gtk.h
parent 6ae724c0
......@@ -173,7 +173,6 @@
<xi:include href="xml/gtkcombobox.xml" />
<xi:include href="xml/gtkcomboboxtext.xml" />
<xi:include href="xml/gtkmenu.xml" />
<xi:include href="xml/gtktreemenu.xml" />
<xi:include href="xml/gtkmenubar.xml" />
<xi:include href="xml/gtkmenuitem.xml" />
<xi:include href="xml/gtkimagemenuitem.xml" />
......
......@@ -783,42 +783,6 @@ GtkColorSelectionDialogPrivate
gtk_color_selection_dialog_get_type
</SECTION>
<SECTION>
<FILE>gtktreemenu</FILE>
<TITLE>GtkTreeMenu</TITLE>
GtkTreeMenu
GtkTreeMenuClass
GtkTreeMenuHeaderFunc
gtk_tree_menu_new
gtk_tree_menu_new_with_area
gtk_tree_menu_new_full
gtk_tree_menu_set_model
gtk_tree_menu_get_model
gtk_tree_menu_set_root
gtk_tree_menu_get_root
gtk_tree_menu_get_tearoff
gtk_tree_menu_set_tearoff
gtk_tree_menu_get_wrap_width
gtk_tree_menu_set_wrap_width
gtk_tree_menu_get_row_span_column
gtk_tree_menu_set_row_span_column
gtk_tree_menu_get_column_span_column
gtk_tree_menu_set_column_span_column
gtk_tree_menu_get_row_separator_func
gtk_tree_menu_set_row_separator_func
gtk_tree_menu_get_header_func
gtk_tree_menu_set_header_func
<SUBSECTION Standard>
GTK_TREE_MENU
GTK_IS_TREE_MENU
GTK_TYPE_TREE_MENU
gtk_tree_menu_get_type
GTK_TREE_MENU_CLASS
GTK_IS_TREE_MENU_CLASS
GTK_TREE_MENU_GET_CLASS
GtkTreeMenuPrivate
</SECTION>
<SECTION>
<FILE>gtkcombobox</FILE>
<TITLE>GtkComboBox</TITLE>
......
......@@ -325,7 +325,6 @@ gtk_public_h_sources = \
gtktoolshell.h \
gtktooltip.h \
gtktreednd.h \
gtktreemenu.h \
gtktreemodel.h \
gtktreemodelfilter.h \
gtktreemodelsort.h \
......@@ -434,6 +433,7 @@ gtk_private_h_sources = \
gtktreeprivate.h \
gtkwidgetprivate.h \
gtkwindowprivate.h \
gtktreemenu.h \
$(gtk_clipboard_dnd_h_sources) \
$(gtk_appchooser_impl_h_sources)
......
......@@ -209,7 +209,6 @@
#include <gtk/gtktooltip.h>
#include <gtk/gtktestutils.h>
#include <gtk/gtktreednd.h>
#include <gtk/gtktreemenu.h>
#include <gtk/gtktreemodel.h>
#include <gtk/gtktreemodelfilter.h>
#include <gtk/gtktreemodelsort.h>
......
......@@ -3094,26 +3094,6 @@ gtk_tree_get_row_drag_data
gtk_tree_iter_copy
gtk_tree_iter_free
gtk_tree_iter_get_type G_GNUC_CONST
gtk_tree_menu_get_column_span_column
gtk_tree_menu_get_header_func
gtk_tree_menu_get_model
gtk_tree_menu_get_root
gtk_tree_menu_get_row_separator_func
gtk_tree_menu_get_row_span_column
gtk_tree_menu_get_tearoff
gtk_tree_menu_get_type G_GNUC_CONST
gtk_tree_menu_get_wrap_width
gtk_tree_menu_new
gtk_tree_menu_new_full
gtk_tree_menu_new_with_area
gtk_tree_menu_set_column_span_column
gtk_tree_menu_set_header_func
gtk_tree_menu_set_model
gtk_tree_menu_set_root
gtk_tree_menu_set_row_separator_func
gtk_tree_menu_set_row_span_column
gtk_tree_menu_set_tearoff
gtk_tree_menu_set_wrap_width
gtk_tree_model_filter_clear_cache
gtk_tree_model_filter_convert_child_iter_to_iter
gtk_tree_model_filter_convert_child_path_to_path
......
......@@ -40,11 +40,12 @@
* and #GtkCellAreaContext. A #GtkCellAreaContext can be provided to the
* #GtkCellView at construction time in order to keep the cellview in context
* of a group of cell views, this ensures that the renderers displayed will
* be properly aligned with eachother (like the aligned cells of #GtkTreeMenu).
* be properly aligned with eachother (like the aligned cells in the menus
* of #GtkComboBox).
*
* #GtkCellView is #GtkOrientable in order to decide in which orientation
* the underlying #GtkCellAreaContext should be allocated. Taking the #GtkTreeMenu
* as an example, cellviews should be oriented horizontally if the menus are
* the underlying #GtkCellAreaContext should be allocated. Taking the #GtkComboBox
* menu as an example, cellviews should be oriented horizontally if the menus are
* listed top-to-bottom and thus all share the same width but may have separate
* individual heights (left-to-right menus should be allocated vertically since
* they all share the same height but may have variable widths).
......@@ -251,7 +252,7 @@ gtk_cell_view_class_init (GtkCellViewClass *klass)
* ensure the sizes and cell alignments match across all the views with
* the same context.
*
* #GtkTreeMenu uses this to assign the same context to all cell views
* #GtkComboBox menus uses this to assign the same context to all cell views
* in the menu items for a single menu (each submenu creates it's own
* context since the size of each submenu does not depend on parent
* or sibling menus).
......@@ -1324,7 +1325,7 @@ gtk_cell_view_get_draw_sensitive (GtkCellView *cell_view)
* @draw_sensitive: whether to draw all cells in a sensitive state.
*
* Sets whether @cell_view should draw all of it's
* cells in a sensitive state, this is used by #GtkTreeMenu
* cells in a sensitive state, this is used by #GtkComboBox menus
* to ensure that rows with insensitive cells that contain
* children appear sensitive in the parent menu item.
*
......
......@@ -2989,28 +2989,28 @@ gtk_combo_box_menu_setup (GtkComboBox *combo_box,
combo_box);
/* create our funky menu */
menu = gtk_tree_menu_new_with_area (priv->area);
menu = _gtk_tree_menu_new_with_area (priv->area);
gtk_widget_set_name (menu, "gtk-combobox-popup-menu");
gtk_tree_menu_set_model (GTK_TREE_MENU (menu), priv->model);
_gtk_tree_menu_set_model (GTK_TREE_MENU (menu), priv->model);
gtk_tree_menu_set_wrap_width (GTK_TREE_MENU (menu), priv->wrap_width);
gtk_tree_menu_set_row_span_column (GTK_TREE_MENU (menu), priv->row_column);
gtk_tree_menu_set_column_span_column (GTK_TREE_MENU (menu), priv->col_column);
gtk_tree_menu_set_tearoff (GTK_TREE_MENU (menu),
combo_box->priv->add_tearoffs);
_gtk_tree_menu_set_wrap_width (GTK_TREE_MENU (menu), priv->wrap_width);
_gtk_tree_menu_set_row_span_column (GTK_TREE_MENU (menu), priv->row_column);
_gtk_tree_menu_set_column_span_column (GTK_TREE_MENU (menu), priv->col_column);
_gtk_tree_menu_set_tearoff (GTK_TREE_MENU (menu),
combo_box->priv->add_tearoffs);
g_signal_connect (menu, "menu-activate",
G_CALLBACK (gtk_combo_box_menu_activate), combo_box);
/* Chain our row_separator_func through */
gtk_tree_menu_set_row_separator_func (GTK_TREE_MENU (menu),
(GtkTreeViewRowSeparatorFunc)gtk_combo_box_row_separator_func,
combo_box, NULL);
_gtk_tree_menu_set_row_separator_func (GTK_TREE_MENU (menu),
(GtkTreeViewRowSeparatorFunc)gtk_combo_box_row_separator_func,
combo_box, NULL);
gtk_tree_menu_set_header_func (GTK_TREE_MENU (menu),
(GtkTreeMenuHeaderFunc)gtk_combo_box_header_func,
combo_box, NULL);
_gtk_tree_menu_set_header_func (GTK_TREE_MENU (menu),
(GtkTreeMenuHeaderFunc)gtk_combo_box_header_func,
combo_box, NULL);
gtk_widget_set_name (menu, "gtk-combobox-popup-menu");
......@@ -3916,7 +3916,7 @@ gtk_combo_box_set_wrap_width (GtkComboBox *combo_box,
gtk_combo_box_check_appearance (combo_box);
if (GTK_IS_TREE_MENU (priv->popup_widget))
gtk_tree_menu_set_wrap_width (GTK_TREE_MENU (priv->popup_widget), priv->wrap_width);
_gtk_tree_menu_set_wrap_width (GTK_TREE_MENU (priv->popup_widget), priv->wrap_width);
g_object_notify (G_OBJECT (combo_box), "wrap-width");
}
......@@ -3970,7 +3970,7 @@ gtk_combo_box_set_row_span_column (GtkComboBox *combo_box,
priv->row_column = row_span;
if (GTK_IS_TREE_MENU (priv->popup_widget))
gtk_tree_menu_set_row_span_column (GTK_TREE_MENU (priv->popup_widget), priv->row_column);
_gtk_tree_menu_set_row_span_column (GTK_TREE_MENU (priv->popup_widget), priv->row_column);
g_object_notify (G_OBJECT (combo_box), "row-span-column");
}
......@@ -4024,7 +4024,7 @@ gtk_combo_box_set_column_span_column (GtkComboBox *combo_box,
priv->col_column = column_span;
if (GTK_IS_TREE_MENU (priv->popup_widget))
gtk_tree_menu_set_column_span_column (GTK_TREE_MENU (priv->popup_widget), priv->col_column);
_gtk_tree_menu_set_column_span_column (GTK_TREE_MENU (priv->popup_widget), priv->col_column);
g_object_notify (G_OBJECT (combo_box), "column-span-column");
}
......@@ -4296,8 +4296,8 @@ gtk_combo_box_set_model (GtkComboBox *combo_box,
if (GTK_IS_TREE_MENU (combo_box->priv->popup_widget))
{
/* menu mode */
gtk_tree_menu_set_model (GTK_TREE_MENU (combo_box->priv->popup_widget),
combo_box->priv->model);
_gtk_tree_menu_set_model (GTK_TREE_MENU (combo_box->priv->popup_widget),
combo_box->priv->model);
}
if (combo_box->priv->cell_view)
......@@ -4992,8 +4992,8 @@ gtk_combo_box_set_row_separator_func (GtkComboBox *combo_box,
if (GTK_IS_TREE_MENU (combo_box->priv->popup_widget))
{
gtk_tree_menu_set_model (GTK_TREE_MENU (combo_box->priv->popup_widget), NULL);
gtk_tree_menu_set_model (GTK_TREE_MENU (combo_box->priv->popup_widget), combo_box->priv->model);
_gtk_tree_menu_set_model (GTK_TREE_MENU (combo_box->priv->popup_widget), NULL);
_gtk_tree_menu_set_model (GTK_TREE_MENU (combo_box->priv->popup_widget), combo_box->priv->model);
}
gtk_widget_queue_draw (GTK_WIDGET (combo_box));
......
......@@ -190,12 +190,12 @@ enum {
static guint tree_menu_signals[N_SIGNALS] = { 0 };
static GQuark tree_menu_path_quark = 0;
G_DEFINE_TYPE_WITH_CODE (GtkTreeMenu, gtk_tree_menu, GTK_TYPE_MENU,
G_DEFINE_TYPE_WITH_CODE (GtkTreeMenu, _gtk_tree_menu, GTK_TYPE_MENU,
G_IMPLEMENT_INTERFACE (GTK_TYPE_CELL_LAYOUT,
gtk_tree_menu_cell_layout_init));
static void
gtk_tree_menu_init (GtkTreeMenu *menu)
_gtk_tree_menu_init (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -234,7 +234,7 @@ gtk_tree_menu_init (GtkTreeMenu *menu)
}
static void
gtk_tree_menu_class_init (GtkTreeMenuClass *class)
_gtk_tree_menu_class_init (GtkTreeMenuClass *class)
{
GObjectClass *object_class = G_OBJECT_CLASS (class);
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (class);
......@@ -420,7 +420,7 @@ gtk_tree_menu_constructor (GType type,
GtkTreeMenu *menu;
GtkTreeMenuPrivate *priv;
object = G_OBJECT_CLASS (gtk_tree_menu_parent_class)->constructor
object = G_OBJECT_CLASS (_gtk_tree_menu_parent_class)->constructor
(type, n_construct_properties, construct_properties);
menu = GTK_TREE_MENU (object);
......@@ -451,7 +451,7 @@ gtk_tree_menu_dispose (GObject *object)
menu = GTK_TREE_MENU (object);
priv = menu->priv;
gtk_tree_menu_set_model (menu, NULL);
_gtk_tree_menu_set_model (menu, NULL);
gtk_tree_menu_set_area (menu, NULL);
if (priv->context)
......@@ -464,7 +464,7 @@ gtk_tree_menu_dispose (GObject *object)
priv->size_changed_id = 0;
}
G_OBJECT_CLASS (gtk_tree_menu_parent_class)->dispose (object);
G_OBJECT_CLASS (_gtk_tree_menu_parent_class)->dispose (object);
}
static void
......@@ -476,13 +476,13 @@ gtk_tree_menu_finalize (GObject *object)
menu = GTK_TREE_MENU (object);
priv = menu->priv;
gtk_tree_menu_set_row_separator_func (menu, NULL, NULL, NULL);
gtk_tree_menu_set_header_func (menu, NULL, NULL, NULL);
_gtk_tree_menu_set_row_separator_func (menu, NULL, NULL, NULL);
_gtk_tree_menu_set_header_func (menu, NULL, NULL, NULL);
if (priv->root)
gtk_tree_row_reference_free (priv->root);
G_OBJECT_CLASS (gtk_tree_menu_parent_class)->finalize (object);
G_OBJECT_CLASS (_gtk_tree_menu_parent_class)->finalize (object);
}
static void
......@@ -496,11 +496,11 @@ gtk_tree_menu_set_property (GObject *object,
switch (prop_id)
{
case PROP_MODEL:
gtk_tree_menu_set_model (menu, g_value_get_object (value));
_gtk_tree_menu_set_model (menu, g_value_get_object (value));
break;
case PROP_ROOT:
gtk_tree_menu_set_root (menu, g_value_get_boxed (value));
_gtk_tree_menu_set_root (menu, g_value_get_boxed (value));
break;
case PROP_CELL_AREA:
......@@ -509,19 +509,19 @@ gtk_tree_menu_set_property (GObject *object,
break;
case PROP_TEAROFF:
gtk_tree_menu_set_tearoff (menu, g_value_get_boolean (value));
_gtk_tree_menu_set_tearoff (menu, g_value_get_boolean (value));
break;
case PROP_WRAP_WIDTH:
gtk_tree_menu_set_wrap_width (menu, g_value_get_int (value));
_gtk_tree_menu_set_wrap_width (menu, g_value_get_int (value));
break;
case PROP_ROW_SPAN_COL:
gtk_tree_menu_set_row_span_column (menu, g_value_get_int (value));
_gtk_tree_menu_set_row_span_column (menu, g_value_get_int (value));
break;
case PROP_COL_SPAN_COL:
gtk_tree_menu_set_column_span_column (menu, g_value_get_int (value));
_gtk_tree_menu_set_column_span_column (menu, g_value_get_int (value));
break;
default:
......@@ -619,7 +619,7 @@ gtk_tree_menu_get_preferred_width (GtkWidget *widget,
sync_reserve_submenu_size (menu);
GTK_WIDGET_CLASS (gtk_tree_menu_parent_class)->get_preferred_width (widget, minimum_size, natural_size);
GTK_WIDGET_CLASS (_gtk_tree_menu_parent_class)->get_preferred_width (widget, minimum_size, natural_size);
g_signal_handler_unblock (priv->context, priv->size_changed_id);
}
......@@ -636,7 +636,7 @@ gtk_tree_menu_get_preferred_height (GtkWidget *widget,
sync_reserve_submenu_size (menu);
GTK_WIDGET_CLASS (gtk_tree_menu_parent_class)->get_preferred_height (widget, minimum_size, natural_size);
GTK_WIDGET_CLASS (_gtk_tree_menu_parent_class)->get_preferred_height (widget, minimum_size, natural_size);
g_signal_handler_unblock (priv->context, priv->size_changed_id);
}
......@@ -1278,23 +1278,23 @@ gtk_tree_menu_create_submenu (GtkTreeMenu *menu,
view = gtk_bin_get_child (GTK_BIN (item));
gtk_cell_view_set_draw_sensitive (GTK_CELL_VIEW (view), TRUE);
submenu = gtk_tree_menu_new_with_area (priv->area);
submenu = _gtk_tree_menu_new_with_area (priv->area);
gtk_tree_menu_set_row_separator_func (GTK_TREE_MENU (submenu),
priv->row_separator_func,
priv->row_separator_data,
priv->row_separator_destroy);
gtk_tree_menu_set_header_func (GTK_TREE_MENU (submenu),
priv->header_func,
priv->header_data,
priv->header_destroy);
_gtk_tree_menu_set_row_separator_func (GTK_TREE_MENU (submenu),
priv->row_separator_func,
priv->row_separator_data,
priv->row_separator_destroy);
_gtk_tree_menu_set_header_func (GTK_TREE_MENU (submenu),
priv->header_func,
priv->header_data,
priv->header_destroy);
gtk_tree_menu_set_wrap_width (GTK_TREE_MENU (submenu), priv->wrap_width);
gtk_tree_menu_set_row_span_column (GTK_TREE_MENU (submenu), priv->row_span_col);
gtk_tree_menu_set_column_span_column (GTK_TREE_MENU (submenu), priv->col_span_col);
_gtk_tree_menu_set_wrap_width (GTK_TREE_MENU (submenu), priv->wrap_width);
_gtk_tree_menu_set_row_span_column (GTK_TREE_MENU (submenu), priv->row_span_col);
_gtk_tree_menu_set_column_span_column (GTK_TREE_MENU (submenu), priv->col_span_col);
gtk_tree_menu_set_model_internal (GTK_TREE_MENU (submenu), priv->model);
gtk_tree_menu_set_root (GTK_TREE_MENU (submenu), path);
_gtk_tree_menu_set_root (GTK_TREE_MENU (submenu), path);
gtk_menu_item_set_submenu (GTK_MENU_ITEM (item), submenu);
g_signal_connect (submenu, "menu-activate",
......@@ -1531,7 +1531,7 @@ gtk_tree_menu_set_model_internal (GtkTreeMenu *menu,
****************************************************************/
/**
* gtk_tree_menu_new:
* _gtk_tree_menu_new:
*
* Creates a new #GtkTreeMenu.
*
......@@ -1540,13 +1540,13 @@ gtk_tree_menu_set_model_internal (GtkTreeMenu *menu,
* Since: 3.0
*/
GtkWidget *
gtk_tree_menu_new (void)
_gtk_tree_menu_new (void)
{
return (GtkWidget *)g_object_new (GTK_TYPE_TREE_MENU, NULL);
}
/**
* gtk_tree_menu_new_with_area:
* _gtk_tree_menu_new_with_area:
* @area: the #GtkCellArea to use to render cells in the menu
*
* Creates a new #GtkTreeMenu using @area to render it's cells.
......@@ -1556,7 +1556,7 @@ gtk_tree_menu_new (void)
* Since: 3.0
*/
GtkWidget *
gtk_tree_menu_new_with_area (GtkCellArea *area)
_gtk_tree_menu_new_with_area (GtkCellArea *area)
{
return (GtkWidget *)g_object_new (GTK_TYPE_TREE_MENU,
"cell-area", area,
......@@ -1564,7 +1564,7 @@ gtk_tree_menu_new_with_area (GtkCellArea *area)
}
/**
* gtk_tree_menu_new_full:
* _gtk_tree_menu_new_full:
* @area: (allow-none): the #GtkCellArea to use to render cells in the menu, or %NULL.
* @model: (allow-none): the #GtkTreeModel to build the menu heirarchy from, or %NULL.
* @root: (allow-none): the #GtkTreePath indicating the root row for this menu, or %NULL.
......@@ -1576,9 +1576,9 @@ gtk_tree_menu_new_with_area (GtkCellArea *area)
* Since: 3.0
*/
GtkWidget *
gtk_tree_menu_new_full (GtkCellArea *area,
GtkTreeModel *model,
GtkTreePath *root)
_gtk_tree_menu_new_full (GtkCellArea *area,
GtkTreeModel *model,
GtkTreePath *root)
{
return (GtkWidget *)g_object_new (GTK_TYPE_TREE_MENU,
"cell-area", area,
......@@ -1588,7 +1588,7 @@ gtk_tree_menu_new_full (GtkCellArea *area,
}
/**
* gtk_tree_menu_set_model:
* _gtk_tree_menu_set_model:
* @menu: a #GtkTreeMenu
* @model: (allow-none): the #GtkTreeModel to build the menu hierarchy from, or %NULL.
*
......@@ -1597,8 +1597,8 @@ gtk_tree_menu_new_full (GtkCellArea *area,
* Since: 3.0
*/
void
gtk_tree_menu_set_model (GtkTreeMenu *menu,
GtkTreeModel *model)
_gtk_tree_menu_set_model (GtkTreeMenu *menu,
GtkTreeModel *model)
{
g_return_if_fail (GTK_IS_TREE_MENU (menu));
g_return_if_fail (model == NULL || GTK_IS_TREE_MODEL (model));
......@@ -1609,7 +1609,7 @@ gtk_tree_menu_set_model (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_model:
* _gtk_tree_menu_get_model:
* @menu: a #GtkTreeMenu
*
* Gets the @model currently used for the menu heirarhcy.
......@@ -1620,7 +1620,7 @@ gtk_tree_menu_set_model (GtkTreeMenu *menu,
* Since: 3.0
*/
GtkTreeModel *
gtk_tree_menu_get_model (GtkTreeMenu *menu)
_gtk_tree_menu_get_model (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1632,7 +1632,7 @@ gtk_tree_menu_get_model (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_root:
* _gtk_tree_menu_set_root:
* @menu: a #GtkTreeMenu
* @path: (allow-none): the #GtkTreePath which is the root of @menu, or %NULL.
*
......@@ -1642,8 +1642,8 @@ gtk_tree_menu_get_model (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_root (GtkTreeMenu *menu,
GtkTreePath *path)
_gtk_tree_menu_set_root (GtkTreeMenu *menu,
GtkTreePath *path)
{
GtkTreeMenuPrivate *priv;
......@@ -1664,7 +1664,7 @@ gtk_tree_menu_set_root (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_root:
* _gtk_tree_menu_get_root:
* @menu: a #GtkTreeMenu
*
* Gets the @root path for @menu's hierarchy, or returns %NULL if @menu
......@@ -1676,7 +1676,7 @@ gtk_tree_menu_set_root (GtkTreeMenu *menu,
* Since: 3.0
*/
GtkTreePath *
gtk_tree_menu_get_root (GtkTreeMenu *menu)
_gtk_tree_menu_get_root (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1691,7 +1691,7 @@ gtk_tree_menu_get_root (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_get_tearoff:
* _gtk_tree_menu_get_tearoff:
* @menu: a #GtkTreeMenu
*
* Gets whether this menu is build with a leading tearoff menu item.
......@@ -1701,7 +1701,7 @@ gtk_tree_menu_get_root (GtkTreeMenu *menu)
* Since: 3.0
*/
gboolean
gtk_tree_menu_get_tearoff (GtkTreeMenu *menu)
_gtk_tree_menu_get_tearoff (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1713,7 +1713,7 @@ gtk_tree_menu_get_tearoff (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_tearoff:
* _gtk_tree_menu_set_tearoff:
* @menu: a #GtkTreeMenu
* @tearoff: whether the menu should have a leading tearoff menu item.
*
......@@ -1722,8 +1722,8 @@ gtk_tree_menu_get_tearoff (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_tearoff (GtkTreeMenu *menu,
gboolean tearoff)
_gtk_tree_menu_set_tearoff (GtkTreeMenu *menu,
gboolean tearoff)
{
GtkTreeMenuPrivate *priv;
......@@ -1742,7 +1742,7 @@ gtk_tree_menu_set_tearoff (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_wrap_width:
* _gtk_tree_menu_get_wrap_width:
* @menu: a #GtkTreeMenu
*
* Gets the wrap width which is used to determine the number of columns
......@@ -1753,7 +1753,7 @@ gtk_tree_menu_set_tearoff (GtkTreeMenu *menu,
* Since: 3.0
*/
gint
gtk_tree_menu_get_wrap_width (GtkTreeMenu *menu)
_gtk_tree_menu_get_wrap_width (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1765,7 +1765,7 @@ gtk_tree_menu_get_wrap_width (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_wrap_width:
* _gtk_tree_menu_set_wrap_width:
* @menu: a #GtkTreeMenu
* @width: the wrap width
*
......@@ -1775,8 +1775,8 @@ gtk_tree_menu_get_wrap_width (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_wrap_width (GtkTreeMenu *menu,
gint width)
_gtk_tree_menu_set_wrap_width (GtkTreeMenu *menu,
gint width)
{
GtkTreeMenuPrivate *priv;
......@@ -1796,7 +1796,7 @@ gtk_tree_menu_set_wrap_width (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_row_span_column:
* _gtk_tree_menu_get_row_span_column:
* @menu: a #GtkTreeMenu
*
* Gets the column with row span information for @menu.
......@@ -1808,7 +1808,7 @@ gtk_tree_menu_set_wrap_width (GtkTreeMenu *menu,
* Since: 3.0
*/
gint
gtk_tree_menu_get_row_span_column (GtkTreeMenu *menu)
_gtk_tree_menu_get_row_span_column (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1820,7 +1820,7 @@ gtk_tree_menu_get_row_span_column (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_row_span_column:
* _gtk_tree_menu_set_row_span_column:
* @menu: a #GtkTreeMenu
* @row_span: the column in the model to fetch the row span for a given menu item.
*
......@@ -1831,8 +1831,8 @@ gtk_tree_menu_get_row_span_column (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_row_span_column (GtkTreeMenu *menu,
gint row_span)
_gtk_tree_menu_set_row_span_column (GtkTreeMenu *menu,
gint row_span)
{
GtkTreeMenuPrivate *priv;
......@@ -1852,7 +1852,7 @@ gtk_tree_menu_set_row_span_column (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_column_span_column:
* _gtk_tree_menu_get_column_span_column:
* @menu: a #GtkTreeMenu
*
* Gets the column with column span information for @menu.
......@@ -1864,7 +1864,7 @@ gtk_tree_menu_set_row_span_column (GtkTreeMenu *menu,
* Since: 3.0
*/
gint
gtk_tree_menu_get_column_span_column (GtkTreeMenu *menu)
_gtk_tree_menu_get_column_span_column (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1876,7 +1876,7 @@ gtk_tree_menu_get_column_span_column (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_column_span_column:
* _gtk_tree_menu_set_column_span_column:
* @menu: a #GtkTreeMenu
* @column_span: the column in the model to fetch the column span for a given menu item.
*
......@@ -1887,8 +1887,8 @@ gtk_tree_menu_get_column_span_column (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_column_span_column (GtkTreeMenu *menu,
gint column_span)
_gtk_tree_menu_set_column_span_column (GtkTreeMenu *menu,
gint column_span)
{
GtkTreeMenuPrivate *priv;
......@@ -1908,7 +1908,7 @@ gtk_tree_menu_set_column_span_column (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_row_separator_func:
* _gtk_tree_menu_get_row_separator_func:
* @menu: a #GtkTreeMenu
*
* Gets the current #GtkTreeViewRowSeparatorFunc separator function.
......@@ -1918,7 +1918,7 @@ gtk_tree_menu_set_column_span_column (GtkTreeMenu *menu,
* Since: 3.0
*/
GtkTreeViewRowSeparatorFunc
gtk_tree_menu_get_row_separator_func (GtkTreeMenu *menu)
_gtk_tree_menu_get_row_separator_func (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1930,7 +1930,7 @@ gtk_tree_menu_get_row_separator_func (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_row_separator_func:
* _gtk_tree_menu_set_row_separator_func:
* @menu: a #GtkTreeMenu
* @func: (allow-none): a #GtkTreeViewRowSeparatorFunc, or %NULL to unset the separator function.
* @data: (allow-none): user data to pass to @func, or %NULL
......@@ -1943,10 +1943,10 @@ gtk_tree_menu_get_row_separator_func (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_row_separator_func (GtkTreeMenu *menu,
GtkTreeViewRowSeparatorFunc func,
gpointer data,
GDestroyNotify destroy)
_gtk_tree_menu_set_row_separator_func (GtkTreeMenu *menu,
GtkTreeViewRowSeparatorFunc func,
gpointer data,
GDestroyNotify destroy)
{
GtkTreeMenuPrivate *priv;
......@@ -1965,7 +1965,7 @@ gtk_tree_menu_set_row_separator_func (GtkTreeMenu *menu,
}
/**
* gtk_tree_menu_get_header_func:
* _gtk_tree_menu_get_header_func:
* @menu: a #GtkTreeMenu
*
* Gets the current #GtkTreeMenuHeaderFunc header function.
......@@ -1975,7 +1975,7 @@ gtk_tree_menu_set_row_separator_func (GtkTreeMenu *menu,
* Since: 3.0
*/
GtkTreeMenuHeaderFunc
gtk_tree_menu_get_header_func (GtkTreeMenu *menu)
_gtk_tree_menu_get_header_func (GtkTreeMenu *menu)
{
GtkTreeMenuPrivate *priv;
......@@ -1987,7 +1987,7 @@ gtk_tree_menu_get_header_func (GtkTreeMenu *menu)
}
/**
* gtk_tree_menu_set_header_func:
* _gtk_tree_menu_set_header_func:
* @menu: a #GtkTreeMenu
* @func: (allow-none): a #GtkTreeMenuHeaderFunc, or %NULL to unset the header function.
* @data: (allow-none): user data to pass to @func, or %NULL
......@@ -2003,10 +2003,10 @@ gtk_tree_menu_get_header_func (GtkTreeMenu *menu)
* Since: 3.0
*/
void
gtk_tree_menu_set_header_func (GtkTreeMenu *menu,
GtkTreeMenuHeaderFunc func,
gpointer data,
GDestroyNotify destroy)
_gtk_tree_menu_set_header_func (GtkTreeMenu *menu,
GtkTreeMenuHeaderFunc func,
gpointer data,
GDestroyNotify destroy)
{
GtkTreeMenuPrivate *priv;
......
......@@ -35,7 +35,7 @@
G_BEGIN_DECLS
#define GTK_TYPE_TREE_MENU (gtk_tree_menu_get_type ())
#define GTK_TYPE_TREE_MENU (_gtk_tree_menu_get_type ())
#define GTK_TREE_MENU(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_TREE_MENU, GtkTreeMenu))
#define GTK_TREE_MENU_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_TREE_MENU, GtkTreeMenuClass))
#define GTK_IS_TREE_MENU(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_TREE_MENU))
......@@ -85,43 +85,43 @@ struct _GtkTreeMenuClass
void (*_gtk_reserved6) (void);
};
GType gtk_tree_menu_get_type (void) G_GNUC_CONST;
GtkWidget *gtk_tree_menu_new (void);
GtkWidget *gtk_tree_menu_new_with_area (GtkCellArea *area);
GtkWidget *gtk_tree_menu_new_full (GtkCellArea *area,
GtkTreeModel *model,
GtkTreePath *root);
void gtk_tree_menu_set_model (GtkTreeMenu *menu,
GtkTreeModel *model);
GtkTreeModel *gtk_tree_menu_get_model (GtkTreeMenu *menu);
void gtk_tree_menu_set_root (GtkTreeMenu *menu,
GtkTreePath *path);
GtkTreePath *gtk_tree_menu_get_root (GtkTreeMenu *menu);
gboolean gtk_tree_menu_get_tearoff (GtkTreeMenu *menu);
void gtk_tree_menu_set_tearoff (GtkTreeMenu *menu,
gboolean tearoff);
gint gtk_tree_menu_get_wrap_width (GtkTreeMenu *menu);
void gtk_tree_menu_set_wrap_width (GtkTreeMenu *menu,
gint width);
gint gtk_tree_menu_get_row_span_column (GtkTreeMenu *menu);
void gtk_tree_menu_set_row_span_column (GtkTreeMenu *menu,
gint row_span);
gint gtk_tree_menu_get_