PROGRAM(menu_item);
// You probably want to use GTK.MenuFactory.
// A menu item is basically a button that will pop up a menu when pressed,
// it can be used to create selection type widgets. This kind of widget:
// <form><select><option>Option 1<option>Option 2</select></form>
// IMG: GTK.Frame()->set_shadow_type(GTK.SHADOW_OUT)->add(GTK.Hbox(0,0)->add(GTK.Menu_item("Hej")->set_submenu(GTK.Menu())->show())->add(GTK.Arrow(GTK.ARROW_DOWN, GTK.SHADOW_OUT)->show()->set_padding(10,0))->show())
INHERIT(item);
FUNCTION(create, "function(string|void:void)")
NAME_ARGS(label);
{
  if(THIS->obj) error("GTK.Menu_item->create() can only be called once.\n");
  if(args)
  {
    char *s;
    get_all_args("GTK.Menu_item", args, "%s", &s);
    THIS->obj = GTK_OBJECT( gtk_menu_item_new_with_label( s ) );
  } else {
    THIS->obj = GTK_OBJECT( gtk_menu_item_new( ) );
  }
  pgtk__init_this_object();
}
COMPLEX_FUNCTION(set_submenu, widget);
NAME_ARGS(menu);
// Set the submenu for this menu button.
COMPLEX_FUNCTION(remove_submenu);
// Remove the submenu for this menu button.
COMPLEX_FUNCTION(set_placement,int);
NAME_ARGS(dir);
// (sub menu placement) One of CONST(GTK_DIRECTION)
COMPLEX_FUNCTION(configure, int,int);
NAME_ARGS(toggle_indicator, submenu_indicator);
// First argument is 'show_toggle_indicator', second is
// 'show_submenu_indicator'.
SIMPLE_FUNCTION(select);
// Emulate a select signal
SIMPLE_FUNCTION(deselect);
// Emulate a deselect signal
SIMPLE_FUNCTION(activate);
// Emulate an activate signal
SIMPLE_FUNCTION(right_justify);
// Make the menu item stick to the right edge of it's container.
CLASSMEMBER(right_justify, int);
CLASSMEMBER(submenu_direction, int);
CLASSMEMBER(submenu_placement, int);
CLASSMEMBER(show_submenu_indicator, int);
CLASSMEMBER(show_toggle_indicator, int);
CLASSMEMBER(toggle_size, int);
CLASSMEMBER(accelerator_width, int);
