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-2011, 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. --  A separator is a vertical or horizontal line that can be displayed between 
  27. --  widgets, to provide visual grouping of the widgets into meaningful groups. 
  28. --  It is for instance used in dialogs to isolate the actual contents of the 
  29. --  dialogs and the various buttons to acknowledge the dialog (OK, Cancel,...) 
  30. -- 
  31. --  </description> 
  32. --  <screenshot>gtk-separator</screenshot> 
  33. --  <group>Ornaments</group> 
  34.  
  35. pragma Warnings (Off, "*is already use-visible*"); 
  36. with Glib;           use Glib; 
  37. with Glib.Types;     use Glib.Types; 
  38. with Gtk.Buildable;  use Gtk.Buildable; 
  39. with Gtk.Enums;      use Gtk.Enums; 
  40. with Gtk.Orientable; use Gtk.Orientable; 
  41. with Gtk.Widget;     use Gtk.Widget; 
  42.  
  43. package Gtk.Separator is 
  44.  
  45.    type Gtk_Separator_Record is new Gtk_Widget_Record with null record; 
  46.    type Gtk_Separator is access all Gtk_Separator_Record'Class; 
  47.  
  48.    subtype Gtk_Vseparator_Record is Gtk_Separator_Record; 
  49.    subtype Gtk_Vseparator is Gtk_Separator; 
  50.  
  51.    subtype Gtk_Hseparator_Record is Gtk_Separator_Record; 
  52.    subtype Gtk_Hseparator is Gtk_Separator; 
  53.  
  54.    ------------------ 
  55.    -- Constructors -- 
  56.    ------------------ 
  57.  
  58.    function Get_Type return Glib.GType; 
  59.    pragma Import (C, Get_Type, "gtk_separator_get_type"); 
  60.  
  61.    procedure Gtk_New_Vseparator (Separator : out Gtk_Vseparator); 
  62.    procedure Initialize_Vseparator 
  63.       (Separator : access Gtk_Vseparator_Record'Class); 
  64.    --  Creates a new Gtk.Separator.Gtk_Vseparator. 
  65.  
  66.    function Vseparator_Get_Type return Glib.GType; 
  67.    pragma Import (C, Vseparator_Get_Type, "gtk_vseparator_get_type"); 
  68.  
  69.    procedure Gtk_New_Hseparator (Separator : out Gtk_Hseparator); 
  70.    procedure Initialize_Hseparator 
  71.       (Separator : access Gtk_Hseparator_Record'Class); 
  72.  
  73.    function Hseparator_Get_Type return Glib.GType; 
  74.    pragma Import (C, Hseparator_Get_Type, "gtk_hseparator_get_type"); 
  75.  
  76.    --------------------- 
  77.    -- Interfaces_Impl -- 
  78.    --------------------- 
  79.  
  80.    function Get_Orientation 
  81.       (Self : access Gtk_Separator_Record) return Gtk.Enums.Gtk_Orientation; 
  82.    procedure Set_Orientation 
  83.       (Self        : access Gtk_Separator_Record; 
  84.        Orientation : Gtk.Enums.Gtk_Orientation); 
  85.  
  86.    ---------------- 
  87.    -- Interfaces -- 
  88.    ---------------- 
  89.    --  This class implements several interfaces. See Glib.Types 
  90.    -- 
  91.    --  - "Buildable" 
  92.    -- 
  93.    --  - "Orientable" 
  94.  
  95.    package Implements_Buildable is new Glib.Types.Implements 
  96.      (Gtk.Buildable.Gtk_Buildable, Gtk_Separator_Record, Gtk_Separator); 
  97.    function "+" 
  98.      (Widget : access Gtk_Separator_Record'Class) 
  99.    return Gtk.Buildable.Gtk_Buildable 
  100.    renames Implements_Buildable.To_Interface; 
  101.    function "-" 
  102.      (Interf : Gtk.Buildable.Gtk_Buildable) 
  103.    return Gtk_Separator 
  104.    renames Implements_Buildable.To_Object; 
  105.  
  106.    package Implements_Orientable is new Glib.Types.Implements 
  107.      (Gtk.Orientable.Gtk_Orientable, Gtk_Separator_Record, Gtk_Separator); 
  108.    function "+" 
  109.      (Widget : access Gtk_Separator_Record'Class) 
  110.    return Gtk.Orientable.Gtk_Orientable 
  111.    renames Implements_Orientable.To_Interface; 
  112.    function "-" 
  113.      (Interf : Gtk.Orientable.Gtk_Orientable) 
  114.    return Gtk_Separator 
  115.    renames Implements_Orientable.To_Object; 
  116.  
  117. end Gtk.Separator;