1. ----------------------------------------------------------------------- 
  2. --               GtkAda - Ada95 binding for Gtk+/Gnome               -- 
  3. --                                                                   -- 
  4. --   Copyright (C) 1998-2000 E. Briot, J. Brobecker and A. Charlet   -- 
  5. --                Copyright (C) 2000-2006 AdaCore                    -- 
  6. --                                                                   -- 
  7. -- This library is free software; you can redistribute it and/or     -- 
  8. -- modify it under the terms of the GNU General Public               -- 
  9. -- License as published by the Free Software Foundation; either      -- 
  10. -- version 2 of the License, or (at your option) any later version.  -- 
  11. --                                                                   -- 
  12. -- This library is distributed in the hope that it will be useful,   -- 
  13. -- but WITHOUT ANY WARRANTY; without even the implied warranty of    -- 
  14. -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU -- 
  15. -- General Public License for more details.                          -- 
  16. --                                                                   -- 
  17. -- You should have received a copy of the GNU General Public         -- 
  18. -- License along with this library; if not, write to the             -- 
  19. -- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      -- 
  20. -- Boston, MA 02111-1307, USA.                                       -- 
  21. --                                                                   -- 
  22. -- -- -- -- -- -- -- -- -- -- -- --
  23. ----------------------------------------------------------------------- 
  24.  
  25. --  <description> 
  26. --  Gtk_Menu_Bar is a subclass of Gtk_Menu_Shell which contains one to many 
  27. --  Gtk_Menu_Item. The result is a standard menu bar which can hold many menu 
  28. --  items. Gtk_Menu_Bar allows for a shadow type to be set for aesthetic 
  29. --  purposes. 
  30. --  </description> 
  31. --  <c_version>2.8.17</c_version> 
  32. --  <group>Menus and Toolbars</group> 
  33. --  <screenshot>gtk-menu_bar</screenshot> 
  34.  
  35. with Glib.Properties; 
  36. with Gtk.Enums; 
  37. with Gtk.Menu_Shell; 
  38.  
  39. package Gtk.Menu_Bar is 
  40.  
  41.    type Gtk_Menu_Bar_Record is new 
  42.      Gtk.Menu_Shell.Gtk_Menu_Shell_Record with private; 
  43.    type Gtk_Menu_Bar is access all Gtk_Menu_Bar_Record'Class; 
  44.  
  45.    procedure Gtk_New (Menu_Bar : out Gtk_Menu_Bar); 
  46.    --  Create a menu bar. 
  47.  
  48.    procedure Initialize (Menu_Bar : access Gtk_Menu_Bar_Record'Class); 
  49.    --  Internal initialization function. 
  50.    --  See the section "Creating your own widgets" in the documentation. 
  51.  
  52.    function Get_Type return Gtk.Gtk_Type; 
  53.    --  Return the internal value associated with a Gtk_Menu_Bar. 
  54.  
  55.    procedure Set_Child_Pack_Direction 
  56.      (Menubar        : access Gtk_Menu_Bar_Record; 
  57.       Child_Pack_Dir : Gtk.Enums.Gtk_Pack_Direction); 
  58.    function Get_Child_Pack_Direction 
  59.      (Menubar : access Gtk_Menu_Bar_Record) 
  60.       return Gtk.Enums.Gtk_Pack_Direction; 
  61.    --  Sets how widgets should be packed inside the children of a menubar. 
  62.  
  63.    procedure Set_Pack_Direction 
  64.      (Menubar  : access Gtk_Menu_Bar_Record; 
  65.       Pack_Dir : Gtk.Enums.Gtk_Pack_Direction); 
  66.    function Get_Pack_Direction 
  67.      (Menubar : access Gtk_Menu_Bar_Record) 
  68.       return Gtk.Enums.Gtk_Pack_Direction; 
  69.    --  Sets how items should be packed inside a menubar. 
  70.  
  71.    ---------------- 
  72.    -- Properties -- 
  73.    ---------------- 
  74.    --  The following properties are defined for this widget. See 
  75.    --  Glib.Properties for more information on properties. 
  76.  
  77.    --  <properties> 
  78.    --  Name:  Child_Pack_Direction_Property 
  79.    --  Type:  Enum 
  80.    --  Descr: The child pack direction of the menubar 
  81.    -- 
  82.    --  Name:  Pack_Direction_Property 
  83.    --  Type:  Enum 
  84.    --  Descr: The pack direction of the menubar 
  85.    --  </properties> 
  86.  
  87.    Child_Pack_Direction_Property : constant Gtk.Enums.Property_Pack_Direction; 
  88.    Pack_Direction_Property       : constant Gtk.Enums.Property_Pack_Direction; 
  89.  
  90.    ---------------------- 
  91.    -- Style Properties -- 
  92.    ---------------------- 
  93.    --  The following properties can be changed through the gtk theme and 
  94.    --  configuration files, and retrieved through Gtk.Widget.Style_Get_Property 
  95.  
  96.    --  <style_properties> 
  97.    --  Name:  Internal_Padding_Property 
  98.    --  Type:  Int 
  99.    --  Descr: Amount of border space between the menubar shadow and the menu 
  100.    --         items 
  101.    -- 
  102.    --  Name:  Shadow_Type_Property 
  103.    --  Type:  Enum 
  104.    --  Descr: Style of bevel around the menubar 
  105.    --  </style_properties> 
  106.  
  107.    Internal_Padding_Property : constant Glib.Properties.Property_Int; 
  108.    Shadow_Type_Property      : constant Gtk.Enums.Property_Gtk_Shadow_Type; 
  109.  
  110. private 
  111.    type Gtk_Menu_Bar_Record is new Gtk.Menu_Shell.Gtk_Menu_Shell_Record 
  112.      with null record; 
  113.  
  114.    Child_Pack_Direction_Property : constant Gtk.Enums.Property_Pack_Direction 
  115.      := Gtk.Enums.Build ("child-pack-direction"); 
  116.    Pack_Direction_Property : constant Gtk.Enums.Property_Pack_Direction := 
  117.      Gtk.Enums.Build ("pack-direction"); 
  118.  
  119.    Internal_Padding_Property : constant Glib.Properties.Property_Int := 
  120.      Glib.Properties.Build ("internal-padding"); 
  121.    Shadow_Type_Property : constant Gtk.Enums.Property_Gtk_Shadow_Type := 
  122.      Gtk.Enums.Build ("shadow-type"); 
  123.  
  124.    pragma Import (C, Get_Type, "gtk_menu_bar_get_type"); 
  125.  
  126. end Gtk.Menu_Bar;