## Documentation

Table of Contents
Class Inheritance Tree
Widget Screenshots
Package groups

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.     -- As a special exception, if other files instantiate generics from  --

23.     -- this unit, or you link this unit with other files to produce an   --

24.     -- executable, this  unit  does not  by itself cause  the resulting  --

25.     -- executable to be covered by the GNU General Public License. This  --

26.     -- exception does not however invalidate any other reasons why the   --

27.     -- executable file  might be covered by the  GNU Public License.     --

28.     -----------------------------------------------------------------------

30.     --  <description>

31.     --  A Gtk_Frame is a simple border than can be added to any widget or group of

32.     --  widget to enhance its visual aspect. Optionally, a frame can have a title.

33.     --

34.     --  This is a very convenient widget to visually group related widgets (like

35.     --  groups of buttons for instance), possibly with a title to explain the

36.     --  purpose of this group.

37.     --

38.     --  A Gtk_Frame has only one child, so you have to put a container like for

39.     --  instance a Gtk_Box inside if you want the frame to surround multiple

40.     --  widgets.

41.     --

42.     --  </description>

43.     --  <screenshot>gtk-frame</screenshot>

44.     --  <group>Ornaments</group>

45.     --  <testgtk>create_frame.adb</testgtk>

47.     pragma Warnings (Off, "*is already use-visible*");

48.     with GlibTo API docTo specTo body;            use GlibTo API docTo specTo body;

49.     with Glib.PropertiesTo API docTo specTo body; use Glib.PropertiesTo API docTo specTo body;

50.     with Glib.TypesTo API docTo specTo body;      use Glib.TypesTo API docTo specTo body;

51.     with Gtk.BinTo API docTo specTo body;         use Gtk.BinTo API docTo specTo body;

52.     with Gtk.BuildableTo API docTo specTo body;   use Gtk.BuildableTo API docTo specTo body;

53.     with Gtk.EnumsTo API docTo specTo body;       use Gtk.EnumsTo API docTo specTo body;

54.     with Gtk.WidgetTo API docTo specTo body;      use Gtk.WidgetTo API docTo specTo body;

56.     package Gtk.FrameTo API docTo specTo body is

58.        type Gtk_Frame_Record is new Gtk_Bin_RecordTo API docTo spec with null record;

59.        type Gtk_Frame is access all Gtk_Frame_RecordTo API docTo spec'Class;

61.        ------------------

62.        -- Constructors --

63.        ------------------

65.        procedure Gtk_NewTo API docTo body (Frame : out Gtk_FrameTo API docTo spec; Label : UTF8_StringTo API docTo spec := "");

66.        procedure InitializeTo API docTo body

67.           (Frame : access Gtk_Frame_RecordTo API docTo spec'Class;

68.            Label : UTF8_StringTo API docTo spec := "");

69.        --  Creates a new Gtk.Frame.Gtk_Frame, with optional label Label. If Label

70.        --  is null, the label is omitted.

71.        --  "label": the text to use as the label of the frame

73.        function Get_TypeTo API docTo body return Glib.GTypeTo API docTo spec;

74.        pragma Import (C, Get_TypeTo API docTo spec, "gtk_frame_get_type");

76.        -------------

77.        -- Methods --

78.        -------------

80.        function Get_LabelTo API docTo body (Frame : access Gtk_Frame_RecordTo API docTo spec) return UTF8_StringTo API docTo spec;

81.        procedure Set_LabelTo API docTo body

82.           (Frame : access Gtk_Frame_RecordTo API docTo spec;

83.            Label : UTF8_StringTo API docTo spec);

84.        --  Sets the text of the label. If Label is null, the current label is

85.        --  removed.

86.        --  "label": the text to use as the label of the frame

88.        procedure Get_Label_AlignTo API docTo body

89.           (Frame  : access Gtk_Frame_RecordTo API docTo spec;

90.            Xalign : out GfloatTo API docTo spec;

91.            Yalign : out GfloatTo API docTo spec);

92.        procedure Set_Label_AlignTo API docTo body

93.           (Frame  : access Gtk_Frame_RecordTo API docTo spec;

94.            Xalign : GfloatTo API docTo spec;

95.            Yalign : GfloatTo API docTo spec);

96.        --  Sets the alignment of the frame widget's label. The default values for

97.        --  a newly created frame are 0.0 and 0.5.

98.        --  "xalign": The position of the label along the top edge of the widget. A

99.        --  value of 0.0 represents left alignment; 1.0 represents right alignment.

100.        --  "yalign": The y alignment of the label. A value of 0.0 aligns under the

101.        --  frame; 1.0 aligns above the frame. If the values are exactly 0.0 or 1.0

102.        --  the gap in the frame won't be painted because the label will be

103.        --  completely above or below the frame.

105.        function Get_Label_WidgetTo API docTo body

106.           (Frame : access Gtk_Frame_RecordTo API docTo spec) return Gtk.Widget.Gtk_WidgetTo API docTo spec;

107.        procedure Set_Label_WidgetTo API docTo body

108.           (Frame        : access Gtk_Frame_RecordTo API docTo spec;

109.            Label_Widget : access Gtk.Widget.Gtk_Widget_RecordTo API docTo specTo body'Class);

110.        --  Sets the label widget for the frame. This is the widget that will

111.        --  appear embedded in the top edge of the frame as a title.

112.        --  "label_widget": the new label widget

114.        function Get_Shadow_TypeTo API docTo body

115.           (Frame : access Gtk_Frame_RecordTo API docTo spec) return Gtk.Enums.Gtk_Shadow_TypeTo API docTo spec;

116.        procedure Set_Shadow_TypeTo API docTo body

117.           (Frame    : access Gtk_Frame_RecordTo API docTo spec;

118.            The_TypeTo API docTo body : Gtk.Enums.Gtk_Shadow_TypeTo API docTo spec);

119.        --  Sets the shadow type for Frame.

120.        --  "type": the new Gtk.Enums.Gtk_Shadow_Type

122.        ----------------

123.        -- Interfaces --

124.        ----------------

125.        --  This class implements several interfaces. See Glib.Types

126.        --

127.        --  - "Buildable"

129.        package Implements_Buildable is new Glib.Types.ImplementsTo API docTo specTo body

130.          (Gtk.Buildable.Gtk_BuildableTo API docTo spec, Gtk_Frame_RecordTo API docTo spec, Gtk_FrameTo API docTo spec);

131.        function "+"

132.          (Widget : access Gtk_Frame_RecordTo API docTo spec'Class)

133.        return Gtk.Buildable.Gtk_BuildableTo API docTo spec

134.        renames Implements_Buildable.To_InterfaceTo API docTo specTo body;

135.        function "-"

136.          (Interf : Gtk.Buildable.Gtk_BuildableTo API docTo spec)

137.        return Gtk_FrameTo API docTo spec

138.        renames Implements_Buildable.To_ObjectTo API docTo specTo body;

140.        ----------------

141.        -- Properties --

142.        ----------------

143.        --  The following properties are defined for this widget. See

144.        --  Glib.Properties for more information on properties)

145.        --

146.        --  Name: Label_Property

147.        --  Type: UTF8_String

148.        --  Flags: read-write

149.        --

150.        --  Name: Label_Widget_Property

151.        --  Type: Gtk.Widget.Gtk_Widget

152.        --  Flags: read-write

153.        --

154.        --  Name: Label_Xalign_Property

155.        --  Type: Gfloat

156.        --  Flags: read-write

157.        --

158.        --  Name: Label_Yalign_Property

159.        --  Type: Gfloat

160.        --  Flags: read-write

161.        --

162.        --  Name: Shadow_Property

163.        --  Type: Gtk.Enums.Gtk_Shadow_Type

164.        --  Flags: read-write

165.        --

166.        --  Name: Shadow_Type_Property

167.        --  Type: Gtk.Enums.Gtk_Shadow_Type

168.        --  Flags: read-write

170.        Label_Property : constant Glib.Properties.Property_StringTo API docTo spec;

171.        Label_Widget_Property : constant Glib.Properties.Property_ObjectTo API docTo spec;

172.        Label_Xalign_Property : constant Glib.Properties.Property_FloatTo API docTo spec;

173.        Label_Yalign_Property : constant Glib.Properties.Property_FloatTo API docTo spec;

174.        Shadow_Property : constant Gtk.Enums.Property_Gtk_Shadow_TypeTo API docTo spec;

175.        Shadow_Type_Property : constant Gtk.Enums.Property_Gtk_Shadow_TypeTo API docTo spec;

177.     private

178.        Label_PropertyTo API docTo spec : constant Glib.Properties.Property_StringTo API docTo spec :=

179.          Glib.Properties.BuildTo API docTo specTo body ("label");

180.        Label_Widget_PropertyTo API docTo spec : constant Glib.Properties.Property_ObjectTo API docTo spec :=

181.          Glib.Properties.BuildTo API docTo specTo body ("label-widget");

182.        Label_Xalign_PropertyTo API docTo spec : constant Glib.Properties.Property_FloatTo API docTo spec :=

183.          Glib.Properties.BuildTo API docTo specTo body ("label-xalign");

184.        Label_Yalign_PropertyTo API docTo spec : constant Glib.Properties.Property_FloatTo API docTo spec :=

185.          Glib.Properties.BuildTo API docTo specTo body ("label-yalign");

186.        Shadow_PropertyTo API docTo spec : constant Gtk.Enums.Property_Gtk_Shadow_TypeTo API docTo spec :=

187.          Gtk.Enums.BuildTo API docTo specTo body ("shadow");

188.        Shadow_Type_PropertyTo API docTo spec : constant Gtk.Enums.Property_Gtk_Shadow_TypeTo API docTo spec :=

189.          Gtk.Enums.BuildTo API docTo specTo body ("shadow-type");

190.     end Gtk.FrameTo API docTo specTo body;