| Extracted from Pike v7.8 release 866 at 2016-04-05.

[Top]
GTKSupport
GTKSupport.MenuFactory

# Method GTKSupport.MenuFactory.MenuFactory()

Method MenuFactory

  `array(object) MenuFactory(MenuDef ... definition)`

Description

  This is the function that actually builds the menubar.

Example

      import GTK.MenuFactory;
       [GTK.MenuBar bar, GTK.AcceleratorTable map] =
        MenuFactory(
          MenuDef( "File/New", new_file, 0, "A-N" ),
          MenuDef( "File/Open", new_file, 1, "A-O" ),
          MenuDef( "File/Save", save_file, 0, "A-S" ),
          MenuDef( "File/<separator>", 0, 0 ),
          MenuDef( "File/Quit", _exit, 0, "A-Q" ),
        );

Returns

  Array
  `GTK.MenuBar 0` | GTK.MenuBar
  `GTK.AcceleratorTable 1` | GTK.AcceleratorTable