## 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-2013, 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_Alignment controls the size and alignment of its single child inside

32.     --  the area allocated to the alignment widget.

33.     --

34.     --  The scale/size settings indicate how much the child will expand to fill

35.     --  the container. The values should be in the range 0.0 (no expansion) to 1.0

36.     --  (full expansion). Note that the scale only indicates the minimal size for

37.     --  the child, it does not force an absolute size.

38.     --

39.     --  The alignment settings indicate where in the alignment widget the child

40.     --  should be located. The values are in the range 0.0 (top or left) to 1.0

41.     --  (bottom or right). These settings are irrelevant if the child is fully

42.     --  expanded.

43.     --

44.     --  </description>

45.     --  <screenshot>gtk-alignment</screenshot>

46.     --  <testgtk>create_alignment.adb</testgtk>

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

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

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

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

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

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

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

56.     package Gtk.AlignmentTo API docTo specTo body is

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

59.        type Gtk_Alignment is access all Gtk_Alignment_RecordTo API docTo spec'Class;

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

62.        -- Constructors --

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

65.        procedure Gtk_NewTo API docTo body

66.           (Alignment : out Gtk_AlignmentTo API docTo spec;

67.            Xalign    : GfloatTo API docTo spec;

68.            Yalign    : GfloatTo API docTo spec;

69.            Xscale    : GfloatTo API docTo spec;

70.            Yscale    : GfloatTo API docTo spec);

71.        procedure InitializeTo API docTo body

72.           (Alignment : access Gtk_Alignment_RecordTo API docTo spec'Class;

73.            Xalign    : GfloatTo API docTo spec;

74.            Yalign    : GfloatTo API docTo spec;

75.            Xscale    : GfloatTo API docTo spec;

76.            Yscale    : GfloatTo API docTo spec);

77.        --  Creates a new Gtk.Alignment.Gtk_Alignment.

78.        --  "xalign": the horizontal alignment of the child widget, from 0 (left)

79.        --  to 1 (right).

80.        --  "yalign": the vertical alignment of the child widget, from 0 (top) to 1

81.        --  (bottom).

82.        --  "xscale": the amount that the child widget expands horizontally to fill

83.        --  up unused space, from 0 to 1. A value of 0 indicates that the child

84.        --  widget should never expand. A value of 1 indicates that the child widget

85.        --  will expand to fill all of the space allocated for the

86.        --  Gtk.Alignment.Gtk_Alignment.

87.        --  "yscale": the amount that the child widget expands vertically to fill

88.        --  up unused space, from 0 to 1. The values are similar to Xscale.

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

91.        pragma Import (C, Get_TypeTo API docTo spec, "gtk_alignment_get_type");

93.        -------------

94.        -- Methods --

95.        -------------

97.        procedure Get_PaddingTo API docTo body

98.           (Alignment      : access Gtk_Alignment_RecordTo API docTo spec;

99.            Padding_Top    : out GuintTo API docTo spec;

100.            Padding_Bottom : out GuintTo API docTo spec;

101.            Padding_Left   : out GuintTo API docTo spec;

102.            Padding_Right  : out GuintTo API docTo spec);

103.        procedure Set_PaddingTo API docTo body

104.           (Alignment      : access Gtk_Alignment_RecordTo API docTo spec;

105.            Padding_Top    : GuintTo API docTo spec;

106.            Padding_Bottom : GuintTo API docTo spec;

107.            Padding_Left   : GuintTo API docTo spec;

108.            Padding_Right  : GuintTo API docTo spec);

109.        --  Sets the padding on the different sides of the widget. The padding adds

110.        --  blank space to the sides of the widget. For instance, this can be used

111.        --  to indent the child widget towards the right by adding padding on the

112.        --  left.

113.        --  Since: gtk+ 2.4

114.        --  "padding_top": the padding at the top of the widget

115.        --  "padding_bottom": the padding at the bottom of the widget

116.        --  "padding_left": the padding at the left of the widget

117.        --  "padding_right": the padding at the right of the widget.

119.        procedure SetTo API docTo body

120.           (Alignment : access Gtk_Alignment_RecordTo API docTo spec;

121.            Xalign    : GfloatTo API docTo spec;

122.            Yalign    : GfloatTo API docTo spec;

123.            Xscale    : GfloatTo API docTo spec;

124.            Yscale    : GfloatTo API docTo spec);

125.        --  Sets the Gtk.Alignment.Gtk_Alignment values.

126.        --  "xalign": the horizontal alignment of the child widget, from 0 (left)

127.        --  to 1 (right).

128.        --  "yalign": the vertical alignment of the child widget, from 0 (top) to 1

129.        --  (bottom).

130.        --  "xscale": the amount that the child widget expands horizontally to fill

131.        --  up unused space, from 0 to 1. A value of 0 indicates that the child

132.        --  widget should never expand. A value of 1 indicates that the child widget

133.        --  will expand to fill all of the space allocated for the

134.        --  Gtk.Alignment.Gtk_Alignment.

135.        --  "yscale": the amount that the child widget expands vertically to fill

136.        --  up unused space, from 0 to 1. The values are similar to Xscale.

138.        ------------

139.        -- Fields --

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

142.        function Get_XalignTo API docTo body

143.           (Alignment : access Gtk_Alignment_RecordTo API docTo spec) return GfloatTo API docTo spec;

145.        function Get_YalignTo API docTo body

146.           (Alignment : access Gtk_Alignment_RecordTo API docTo spec) return GfloatTo API docTo spec;

148.        function Get_XscaleTo API docTo body

149.           (Alignment : access Gtk_Alignment_RecordTo API docTo spec) return GfloatTo API docTo spec;

151.        function Get_YscaleTo API docTo body

152.           (Alignment : access Gtk_Alignment_RecordTo API docTo spec) return GfloatTo API docTo spec;

154.        ----------------

155.        -- Interfaces --

156.        ----------------

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

158.        --

159.        --  - "Buildable"

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

162.          (Gtk.Buildable.Gtk_BuildableTo API docTo spec, Gtk_Alignment_RecordTo API docTo spec, Gtk_AlignmentTo API docTo spec);

163.        function "+"

164.          (Widget : access Gtk_Alignment_RecordTo API docTo spec'Class)

165.        return Gtk.Buildable.Gtk_BuildableTo API docTo spec

166.        renames Implements_Buildable.To_InterfaceTo API docTo specTo body;

167.        function "-"

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

169.        return Gtk_AlignmentTo API docTo spec

170.        renames Implements_Buildable.To_ObjectTo API docTo specTo body;

172.        ----------------

173.        -- Properties --

174.        ----------------

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

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

177.        --

178.        --  Name: Bottom_Padding_Property

179.        --  Type: Guint

180.        --  Flags: read-write

181.        --  The padding to insert at the bottom of the widget.

182.        --

183.        --  Name: Left_Padding_Property

184.        --  Type: Guint

185.        --  Flags: read-write

186.        --  The padding to insert at the left of the widget.

187.        --

188.        --  Name: Right_Padding_Property

189.        --  Type: Guint

190.        --  Flags: read-write

191.        --  The padding to insert at the right of the widget.

192.        --

193.        --  Name: Top_Padding_Property

194.        --  Type: Guint

195.        --  Flags: read-write

196.        --  The padding to insert at the top of the widget.

197.        --

198.        --  Name: Xalign_Property

199.        --  Type: Gfloat

200.        --  Flags: read-write

201.        --

202.        --  Name: Xscale_Property

203.        --  Type: Gfloat

204.        --  Flags: read-write

205.        --

206.        --  Name: Yalign_Property

207.        --  Type: Gfloat

208.        --  Flags: read-write

209.        --

210.        --  Name: Yscale_Property

211.        --  Type: Gfloat

212.        --  Flags: read-write

214.        Bottom_Padding_Property : constant Glib.Properties.Property_UintTo API docTo spec;

215.        Left_Padding_Property : constant Glib.Properties.Property_UintTo API docTo spec;

216.        Right_Padding_Property : constant Glib.Properties.Property_UintTo API docTo spec;

217.        Top_Padding_Property : constant Glib.Properties.Property_UintTo API docTo spec;

218.        Xalign_Property : constant Glib.Properties.Property_FloatTo API docTo spec;

219.        Xscale_Property : constant Glib.Properties.Property_FloatTo API docTo spec;

220.        Yalign_Property : constant Glib.Properties.Property_FloatTo API docTo spec;

221.        Yscale_Property : constant Glib.Properties.Property_FloatTo API docTo spec;

223.     private

224.        Bottom_Padding_PropertyTo API docTo spec : constant Glib.Properties.Property_UintTo API docTo spec :=

225.          Glib.Properties.BuildTo API docTo specTo body ("bottom-padding");

226.        Left_Padding_PropertyTo API docTo spec : constant Glib.Properties.Property_UintTo API docTo spec :=

227.          Glib.Properties.BuildTo API docTo specTo body ("left-padding");

228.        Right_Padding_PropertyTo API docTo spec : constant Glib.Properties.Property_UintTo API docTo spec :=

229.          Glib.Properties.BuildTo API docTo specTo body ("right-padding");

230.        Top_Padding_PropertyTo API docTo spec : constant Glib.Properties.Property_UintTo API docTo spec :=

231.          Glib.Properties.BuildTo API docTo specTo body ("top-padding");

232.        Xalign_PropertyTo API docTo spec : constant Glib.Properties.Property_FloatTo API docTo spec :=

233.          Glib.Properties.BuildTo API docTo specTo body ("xalign");

234.        Xscale_PropertyTo API docTo spec : constant Glib.Properties.Property_FloatTo API docTo spec :=

235.          Glib.Properties.BuildTo API docTo specTo body ("xscale");

236.        Yalign_PropertyTo API docTo spec : constant Glib.Properties.Property_FloatTo API docTo spec :=

237.          Glib.Properties.BuildTo API docTo specTo body ("yalign");

238.        Yscale_PropertyTo API docTo spec : constant Glib.Properties.Property_FloatTo API docTo spec :=

239.          Glib.Properties.BuildTo API docTo specTo body ("yscale");

240.     end Gtk.AlignmentTo API docTo specTo body;