1. ------------------------------------------------------------------------------ 
  2. --                                                                          -- 
  3. --      Copyright (C) 1998-2000 E. Briot, J. Brobecker and A. Charlet       -- 
  4. --                     Copyright (C) 2000-2014, AdaCore                     -- 
  5. --                                                                          -- 
  6. -- This library is free software;  you can redistribute it and/or modify it -- 
  7. -- under terms of the  GNU General Public License  as published by the Free -- 
  8. -- Software  Foundation;  either version 3,  or (at your  option) any later -- 
  9. -- version. This library is distributed in the hope that it will be useful, -- 
  10. -- but WITHOUT ANY WARRANTY;  without even the implied warranty of MERCHAN- -- 
  11. -- TABILITY or FITNESS FOR A PARTICULAR PURPOSE.                            -- 
  12. --                                                                          -- 
  13. -- As a special exception under Section 7 of GPL version 3, you are granted -- 
  14. -- additional permissions described in the GCC Runtime Library Exception,   -- 
  15. -- version 3.1, as published by the Free Software Foundation.               -- 
  16. --                                                                          -- 
  17. -- You should have received a copy of the GNU General Public License and    -- 
  18. -- a copy of the GCC Runtime Library Exception along with this program;     -- 
  19. -- see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see    -- 
  20. -- <http://www.gnu.org/licenses/>.                                          -- 
  21. --                                                                          -- 
  22. ------------------------------------------------------------------------------ 
  23.  
  24. --  <description> 
  25. --  Gtk.Scrolled_Window.Gtk_Scrolled_Window is a Gtk.Bin.Gtk_Bin subclass: 
  26. --  it's a container the accepts a single child widget. 
  27. --  Gtk.Scrolled_Window.Gtk_Scrolled_Window adds scrollbars to the child widget 
  28. --  and optionally draws a beveled frame around the child widget. 
  29. -- 
  30. --  The scrolled window can work in two ways. Some widgets have native 
  31. --  scrolling support; these widgets implement the 
  32. --  Gtk.Scrollable.Gtk_Scrollable interface. Widgets with native scroll support 
  33. --  include Gtk.Tree_View.Gtk_Tree_View, Gtk.Text_View.Gtk_Text_View, and 
  34. --  Gtk.Layout.Gtk_Layout. 
  35. -- 
  36. --  For widgets that lack native scrolling support, the 
  37. --  Gtk.Viewport.Gtk_Viewport widget acts as an adaptor class, implementing 
  38. --  scrollability for child widgets that lack their own scrolling capabilities. 
  39. --  Use Gtk.Viewport.Gtk_Viewport to scroll child widgets such as 
  40. --  Gtk.Grid.Gtk_Grid, Gtk.Box.Gtk_Box, and so on. 
  41. -- 
  42. --  If a widget has native scrolling abilities, it can be added to the 
  43. --  Gtk.Scrolled_Window.Gtk_Scrolled_Window with Gtk.Container.Add. If a widget 
  44. --  does not, you must first add the widget to a Gtk.Viewport.Gtk_Viewport, 
  45. --  then add the Gtk.Viewport.Gtk_Viewport to the scrolled window. 
  46. --  Gtk.Container.Add will do this for you for widgets that don't implement 
  47. --  Gtk.Scrollable.Gtk_Scrollable natively, so you can ignore the presence of 
  48. --  the viewport. 
  49. -- 
  50. --  The position of the scrollbars is controlled by the scroll adjustments. 
  51. --  See Gtk.Adjustment.Gtk_Adjustment for the fields in an adjustment - for 
  52. --  Gtk.Scrollbar.Gtk_Scrollbar, used by 
  53. --  Gtk.Scrolled_Window.Gtk_Scrolled_Window, the "value" field represents the 
  54. --  position of the scrollbar, which must be between the "lower" field and 
  55. --  "upper - page_size." The "page_size" field represents the size of the 
  56. --  visible scrollable area. The "step_increment" and "page_increment" fields 
  57. --  are used when the user asks to step down (using the small stepper arrows) 
  58. --  or page down (using for example the PageDown key). 
  59. -- 
  60. --  If a Gtk.Scrolled_Window.Gtk_Scrolled_Window doesn't behave quite as you 
  61. --  would like, or doesn't have exactly the right layout, it's very possible to 
  62. --  set up your own scrolling with Gtk.Scrollbar.Gtk_Scrollbar and for example 
  63. --  a Gtk.Grid.Gtk_Grid. 
  64. -- 
  65. --  </description> 
  66. pragma Ada_2005; 
  67.  
  68. pragma Warnings (Off, "*is already use-visible*"); 
  69. with Glib;            use Glib; 
  70. with Glib.Object;     use Glib.Object; 
  71. with Glib.Properties; use Glib.Properties; 
  72. with Glib.Types;      use Glib.Types; 
  73. with Gtk.Adjustment;  use Gtk.Adjustment; 
  74. with Gtk.Bin;         use Gtk.Bin; 
  75. with Gtk.Buildable;   use Gtk.Buildable; 
  76. with Gtk.Enums;       use Gtk.Enums; 
  77. with Gtk.Scrollbar;   use Gtk.Scrollbar; 
  78. with Gtk.Widget;      use Gtk.Widget; 
  79.  
  80. package Gtk.Scrolled_Window is 
  81.  
  82.    type Gtk_Scrolled_Window_Record is new Gtk_Bin_Record with null record; 
  83.    type Gtk_Scrolled_Window is access all Gtk_Scrolled_Window_Record'Class; 
  84.  
  85.    ------------------ 
  86.    -- Constructors -- 
  87.    ------------------ 
  88.  
  89.    procedure Gtk_New 
  90.       (Scrolled_Window : out Gtk_Scrolled_Window; 
  91.        Hadjustment     : Gtk.Adjustment.Gtk_Adjustment := null; 
  92.        Vadjustment     : Gtk.Adjustment.Gtk_Adjustment := null); 
  93.    procedure Initialize 
  94.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record'Class; 
  95.        Hadjustment     : Gtk.Adjustment.Gtk_Adjustment := null; 
  96.        Vadjustment     : Gtk.Adjustment.Gtk_Adjustment := null); 
  97.    --  Creates a new scrolled window. 
  98.    --  The two arguments are the scrolled window's adjustments; these will be 
  99.    --  shared with the scrollbars and the child widget to keep the bars in sync 
  100.    --  with the child. Usually you want to pass null for the adjustments, which 
  101.    --  will cause the scrolled window to create them for you. 
  102.    --  "hadjustment": horizontal adjustment 
  103.    --  "vadjustment": vertical adjustment 
  104.  
  105.    function Gtk_Scrolled_Window_New 
  106.       (Hadjustment : Gtk.Adjustment.Gtk_Adjustment := null; 
  107.        Vadjustment : Gtk.Adjustment.Gtk_Adjustment := null) 
  108.        return Gtk_Scrolled_Window; 
  109.    --  Creates a new scrolled window. 
  110.    --  The two arguments are the scrolled window's adjustments; these will be 
  111.    --  shared with the scrollbars and the child widget to keep the bars in sync 
  112.    --  with the child. Usually you want to pass null for the adjustments, which 
  113.    --  will cause the scrolled window to create them for you. 
  114.    --  "hadjustment": horizontal adjustment 
  115.    --  "vadjustment": vertical adjustment 
  116.  
  117.    function Get_Type return Glib.GType; 
  118.    pragma Import (C, Get_Type, "gtk_scrolled_window_get_type"); 
  119.  
  120.    ------------- 
  121.    -- Methods -- 
  122.    ------------- 
  123.  
  124.    procedure Add_With_Viewport 
  125.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record; 
  126.        Child           : not null access Gtk.Widget.Gtk_Widget_Record'Class); 
  127.    pragma Obsolescent (Add_With_Viewport); 
  128.    --  Used to add children without native scrolling capabilities. This is 
  129.    --  simply a convenience function; it is equivalent to adding the 
  130.    --  unscrollable child to a viewport, then adding the viewport to the 
  131.    --  scrolled window. If a child has native scrolling, use Gtk.Container.Add 
  132.    --  instead of this function. 
  133.    --  The viewport scrolls the child by moving its Gdk.Gdk_Window, and takes 
  134.    --  the size of the child to be the size of its toplevel Gdk.Gdk_Window. 
  135.    --  This will be very wrong for most widgets that support native scrolling; 
  136.    --  for example, if you add a widget such as Gtk.Tree_View.Gtk_Tree_View 
  137.    --  with a viewport, the whole widget will scroll, including the column 
  138.    --  headings. Thus, widgets with native scrolling support should not be used 
  139.    --  with the Gtk.Viewport.Gtk_Viewport proxy. 
  140.    --  A widget supports scrolling natively if it implements the 
  141.    --  Gtk.Scrollable.Gtk_Scrollable interface. 
  142.    --  Deprecated since 3.8, Gtk.Container.Add will now automatically add a 
  143.    --  Gtk.Viewport.Gtk_Viewport if the child doesn't implement 
  144.    --  Gtk.Scrollable.Gtk_Scrollable. 
  145.    --  "child": the widget you want to scroll 
  146.  
  147.    function Get_Capture_Button_Press 
  148.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  149.        return Boolean; 
  150.    --  Return whether button presses are captured during kinetic scrolling. 
  151.    --  See Gtk.Scrolled_Window.Set_Capture_Button_Press. 
  152.    --  Since: gtk+ 3.4 
  153.  
  154.    procedure Set_Capture_Button_Press 
  155.       (Scrolled_Window      : not null access Gtk_Scrolled_Window_Record; 
  156.        Capture_Button_Press : Boolean); 
  157.    --  Changes the behaviour of Scrolled_Window wrt. to the initial event that 
  158.    --  possibly starts kinetic scrolling. When Capture_Button_Press is set to 
  159.    --  True, the event is captured by the scrolled window, and then later 
  160.    --  replayed if it is meant to go to the child widget. 
  161.    --  This should be enabled if any child widgets perform non-reversible 
  162.    --  actions on Gtk.Widget.Gtk_Widget::button-press-event. If they don't, and 
  163.    --  handle additionally handle Gtk.Widget.Gtk_Widget::grab-broken-event, it 
  164.    --  might be better to set Capture_Button_Press to False. 
  165.    --  This setting only has an effect if kinetic scrolling is enabled. 
  166.    --  Since: gtk+ 3.4 
  167.    --  "capture_button_press": True to capture button presses 
  168.  
  169.    function Get_Hadjustment 
  170.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  171.        return Gtk.Adjustment.Gtk_Adjustment; 
  172.    --  Returns the horizontal scrollbar's adjustment, used to connect the 
  173.    --  horizontal scrollbar to the child widget's horizontal scroll 
  174.    --  functionality. 
  175.  
  176.    procedure Set_Hadjustment 
  177.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record; 
  178.        Hadjustment     : not null access Gtk.Adjustment.Gtk_Adjustment_Record'Class); 
  179.    --  Sets the Gtk.Adjustment.Gtk_Adjustment for the horizontal scrollbar. 
  180.    --  "hadjustment": horizontal scroll adjustment 
  181.  
  182.    function Get_Hscrollbar 
  183.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  184.        return Gtk.Scrollbar.Gtk_Scrollbar; 
  185.    --  Returns the horizontal scrollbar of Scrolled_Window. 
  186.    --  Since: gtk+ 2.8 
  187.  
  188.    function Get_Kinetic_Scrolling 
  189.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  190.        return Boolean; 
  191.    --  Returns the specified kinetic scrolling behavior. 
  192.    --  Since: gtk+ 3.4 
  193.  
  194.    procedure Set_Kinetic_Scrolling 
  195.       (Scrolled_Window   : not null access Gtk_Scrolled_Window_Record; 
  196.        Kinetic_Scrolling : Boolean); 
  197.    --  Turns kinetic scrolling on or off. Kinetic scrolling only applies to 
  198.    --  devices with source GDK_SOURCE_TOUCHSCREEN. 
  199.    --  Since: gtk+ 3.4 
  200.    --  "kinetic_scrolling": True to enable kinetic scrolling 
  201.  
  202.    function Get_Min_Content_Height 
  203.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  204.        return Gint; 
  205.    --  Gets the minimal content height of Scrolled_Window, or -1 if not set. 
  206.    --  Since: gtk+ 3.0 
  207.  
  208.    procedure Set_Min_Content_Height 
  209.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record; 
  210.        Height          : Gint); 
  211.    --  Sets the minimum height that Scrolled_Window should keep visible. Note 
  212.    --  that this can and (usually will) be smaller than the minimum size of the 
  213.    --  content. 
  214.    --  Since: gtk+ 3.0 
  215.    --  "height": the minimal content height 
  216.  
  217.    function Get_Min_Content_Width 
  218.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  219.        return Gint; 
  220.    --  Gets the minimum content width of Scrolled_Window, or -1 if not set. 
  221.    --  Since: gtk+ 3.0 
  222.  
  223.    procedure Set_Min_Content_Width 
  224.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record; 
  225.        Width           : Gint); 
  226.    --  Sets the minimum width that Scrolled_Window should keep visible. Note 
  227.    --  that this can and (usually will) be smaller than the minimum size of the 
  228.    --  content. 
  229.    --  Since: gtk+ 3.0 
  230.    --  "width": the minimal content width 
  231.  
  232.    function Get_Placement 
  233.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  234.        return Gtk.Enums.Gtk_Corner_Type; 
  235.    --  Gets the placement of the contents with respect to the scrollbars for 
  236.    --  the scrolled window. See Gtk.Scrolled_Window.Set_Placement. 
  237.  
  238.    procedure Set_Placement 
  239.       (Scrolled_Window  : not null access Gtk_Scrolled_Window_Record; 
  240.        Window_Placement : Gtk.Enums.Gtk_Corner_Type); 
  241.    --  Sets the placement of the contents with respect to the scrollbars for 
  242.    --  the scrolled window. 
  243.    --  The default is Gtk.Enums.Corner_Top_Left, meaning the child is in the 
  244.    --  top left, with the scrollbars underneath and to the right. Other values 
  245.    --  in Gtk.Enums.Gtk_Corner_Type are Gtk.Enums.Corner_Top_Right, 
  246.    --  Gtk.Enums.Corner_Bottom_Left, and Gtk.Enums.Corner_Bottom_Right. 
  247.    --  See also Gtk.Scrolled_Window.Get_Placement and 
  248.    --  Gtk.Scrolled_Window.Unset_Placement. 
  249.    --  "window_placement": position of the child window 
  250.  
  251.    procedure Get_Policy 
  252.       (Scrolled_Window   : not null access Gtk_Scrolled_Window_Record; 
  253.        Hscrollbar_Policy : out Gtk.Enums.Gtk_Policy_Type; 
  254.        Vscrollbar_Policy : out Gtk.Enums.Gtk_Policy_Type); 
  255.    --  Retrieves the current policy values for the horizontal and vertical 
  256.    --  scrollbars. See Gtk.Scrolled_Window.Set_Policy. 
  257.    --  "hscrollbar_policy": location to store the policy for the horizontal 
  258.    --  scrollbar, or null. 
  259.    --  "vscrollbar_policy": location to store the policy for the vertical 
  260.    --  scrollbar, or null. 
  261.  
  262.    procedure Set_Policy 
  263.       (Scrolled_Window   : not null access Gtk_Scrolled_Window_Record; 
  264.        Hscrollbar_Policy : Gtk.Enums.Gtk_Policy_Type; 
  265.        Vscrollbar_Policy : Gtk.Enums.Gtk_Policy_Type); 
  266.    --  Sets the scrollbar policy for the horizontal and vertical scrollbars. 
  267.    --  The policy determines when the scrollbar should appear; it is a value 
  268.    --  from the Gtk.Enums.Gtk_Policy_Type enumeration. If 
  269.    --  Gtk.Enums.Policy_Always, the scrollbar is always present; if 
  270.    --  Gtk.Enums.Policy_Never, the scrollbar is never present; if 
  271.    --  Gtk.Enums.Policy_Automatic, the scrollbar is present only if needed 
  272.    --  (that is, if the slider part of the bar would be smaller than the trough 
  273.    --  - the display is larger than the page size). 
  274.    --  "hscrollbar_policy": policy for horizontal bar 
  275.    --  "vscrollbar_policy": policy for vertical bar 
  276.  
  277.    function Get_Shadow_Type 
  278.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  279.        return Gtk.Enums.Gtk_Shadow_Type; 
  280.    --  Gets the shadow type of the scrolled window. See 
  281.    --  Gtk.Scrolled_Window.Set_Shadow_Type. 
  282.  
  283.    procedure Set_Shadow_Type 
  284.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record; 
  285.        The_Type        : Gtk.Enums.Gtk_Shadow_Type); 
  286.    --  Changes the type of shadow drawn around the contents of 
  287.    --  Scrolled_Window. 
  288.    --  "type": kind of shadow to draw around scrolled window contents 
  289.  
  290.    function Get_Vadjustment 
  291.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  292.        return Gtk.Adjustment.Gtk_Adjustment; 
  293.    --  Returns the vertical scrollbar's adjustment, used to connect the 
  294.    --  vertical scrollbar to the child widget's vertical scroll functionality. 
  295.  
  296.    procedure Set_Vadjustment 
  297.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record; 
  298.        Vadjustment     : not null access Gtk.Adjustment.Gtk_Adjustment_Record'Class); 
  299.    --  Sets the Gtk.Adjustment.Gtk_Adjustment for the vertical scrollbar. 
  300.    --  "vadjustment": vertical scroll adjustment 
  301.  
  302.    function Get_Vscrollbar 
  303.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record) 
  304.        return Gtk.Scrollbar.Gtk_Scrollbar; 
  305.    --  Returns the vertical scrollbar of Scrolled_Window. 
  306.    --  Since: gtk+ 2.8 
  307.  
  308.    procedure Unset_Placement 
  309.       (Scrolled_Window : not null access Gtk_Scrolled_Window_Record); 
  310.    --  Unsets the placement of the contents with respect to the scrollbars for 
  311.    --  the scrolled window. If no window placement is set for a scrolled 
  312.    --  window, it obeys the "gtk-scrolled-window-placement" XSETTING. 
  313.    --  See also Gtk.Scrolled_Window.Set_Placement and 
  314.    --  Gtk.Scrolled_Window.Get_Placement. 
  315.    --  Since: gtk+ 2.10 
  316.  
  317.    ---------------- 
  318.    -- Properties -- 
  319.    ---------------- 
  320.    --  The following properties are defined for this widget. See 
  321.    --  Glib.Properties for more information on properties) 
  322.  
  323.    Hadjustment_Property : constant Glib.Properties.Property_Object; 
  324.    --  Type: Gtk.Adjustment.Gtk_Adjustment 
  325.  
  326.    Hscrollbar_Policy_Property : constant Gtk.Enums.Property_Gtk_Policy_Type; 
  327.  
  328.    Kinetic_Scrolling_Property : constant Glib.Properties.Property_Boolean; 
  329.    --  The kinetic scrolling behavior flags. Kinetic scrolling only applies to 
  330.    --  devices with source GDK_SOURCE_TOUCHSCREEN 
  331.  
  332.    Min_Content_Height_Property : constant Glib.Properties.Property_Int; 
  333.    --  The minimum content height of Scrolled_Window, or -1 if not set. 
  334.  
  335.    Min_Content_Width_Property : constant Glib.Properties.Property_Int; 
  336.    --  The minimum content width of Scrolled_Window, or -1 if not set. 
  337.  
  338.    Shadow_Type_Property : constant Gtk.Enums.Property_Gtk_Shadow_Type; 
  339.  
  340.    Vadjustment_Property : constant Glib.Properties.Property_Object; 
  341.    --  Type: Gtk.Adjustment.Gtk_Adjustment 
  342.  
  343.    Vscrollbar_Policy_Property : constant Gtk.Enums.Property_Gtk_Policy_Type; 
  344.  
  345.    Window_Placement_Property : constant Gtk.Enums.Property_Gtk_Corner_Type; 
  346.  
  347.    Window_Placement_Set_Property : constant Glib.Properties.Property_Boolean; 
  348.    --  Whether "window-placement" should be used to determine the location of 
  349.    --  the contents with respect to the scrollbars. Otherwise, the 
  350.    --  "gtk-scrolled-window-placement" setting is used. 
  351.  
  352.    ------------- 
  353.    -- Signals -- 
  354.    ------------- 
  355.  
  356.    type Cb_Gtk_Scrolled_Window_Gtk_Direction_Type_Void is not null access procedure 
  357.      (Self           : access Gtk_Scrolled_Window_Record'Class; 
  358.       Direction_Type : Gtk.Enums.Gtk_Direction_Type); 
  359.  
  360.    type Cb_GObject_Gtk_Direction_Type_Void is not null access procedure 
  361.      (Self           : access Glib.Object.GObject_Record'Class; 
  362.       Direction_Type : Gtk.Enums.Gtk_Direction_Type); 
  363.  
  364.    Signal_Move_Focus_Out : constant Glib.Signal_Name := "move-focus-out"; 
  365.    procedure On_Move_Focus_Out 
  366.       (Self  : not null access Gtk_Scrolled_Window_Record; 
  367.        Call  : Cb_Gtk_Scrolled_Window_Gtk_Direction_Type_Void; 
  368.        After : Boolean := False); 
  369.    procedure On_Move_Focus_Out 
  370.       (Self  : not null access Gtk_Scrolled_Window_Record; 
  371.        Call  : Cb_GObject_Gtk_Direction_Type_Void; 
  372.        Slot  : not null access Glib.Object.GObject_Record'Class; 
  373.        After : Boolean := False); 
  374.    --  The ::move-focus-out signal is a <link 
  375.    --  linkend="keybinding-signals">keybinding signal</link> which gets emitted 
  376.    --  when focus is moved away from the scrolled window by a keybinding. The 
  377.    --  Gtk.Widget.Gtk_Widget::move-focus signal is emitted with Direction_Type 
  378.    --  on this scrolled windows toplevel parent in the container hierarchy. The 
  379.    --  default bindings for this signal are ['Tab''Ctrl'] and 
  380.    --  ['Tab''Ctrl''Shift']. 
  381.  
  382.    type Cb_Gtk_Scrolled_Window_Gtk_Scroll_Type_Boolean_Boolean is not null access function 
  383.      (Self       : access Gtk_Scrolled_Window_Record'Class; 
  384.       Scroll     : Gtk.Enums.Gtk_Scroll_Type; 
  385.       Horizontal : Boolean) return Boolean; 
  386.  
  387.    type Cb_GObject_Gtk_Scroll_Type_Boolean_Boolean is not null access function 
  388.      (Self       : access Glib.Object.GObject_Record'Class; 
  389.       Scroll     : Gtk.Enums.Gtk_Scroll_Type; 
  390.       Horizontal : Boolean) return Boolean; 
  391.  
  392.    Signal_Scroll_Child : constant Glib.Signal_Name := "scroll-child"; 
  393.    procedure On_Scroll_Child 
  394.       (Self  : not null access Gtk_Scrolled_Window_Record; 
  395.        Call  : Cb_Gtk_Scrolled_Window_Gtk_Scroll_Type_Boolean_Boolean; 
  396.        After : Boolean := False); 
  397.    procedure On_Scroll_Child 
  398.       (Self  : not null access Gtk_Scrolled_Window_Record; 
  399.        Call  : Cb_GObject_Gtk_Scroll_Type_Boolean_Boolean; 
  400.        Slot  : not null access Glib.Object.GObject_Record'Class; 
  401.        After : Boolean := False); 
  402.    --  The ::scroll-child signal is a <link 
  403.    --  linkend="keybinding-signals">keybinding signal</link> which gets emitted 
  404.    --  when a keybinding that scrolls is pressed. The horizontal or vertical 
  405.    --  adjustment is updated which triggers a signal that the scrolled windows 
  406.    --  child may listen to and scroll itself. 
  407.    --  
  408.    --  Callback parameters: 
  409.    --    --  "scroll": a Gtk.Enums.Gtk_Scroll_Type describing how much to scroll 
  410.    --    --  "horizontal": whether the keybinding scrolls the child horizontally or 
  411.    --    --  not 
  412.  
  413.    ---------------- 
  414.    -- Interfaces -- 
  415.    ---------------- 
  416.    --  This class implements several interfaces. See Glib.Types 
  417.    -- 
  418.    --  - "Buildable" 
  419.  
  420.    package Implements_Gtk_Buildable is new Glib.Types.Implements 
  421.      (Gtk.Buildable.Gtk_Buildable, Gtk_Scrolled_Window_Record, Gtk_Scrolled_Window); 
  422.    function "+" 
  423.      (Widget : access Gtk_Scrolled_Window_Record'Class) 
  424.    return Gtk.Buildable.Gtk_Buildable 
  425.    renames Implements_Gtk_Buildable.To_Interface; 
  426.    function "-" 
  427.      (Interf : Gtk.Buildable.Gtk_Buildable) 
  428.    return Gtk_Scrolled_Window 
  429.    renames Implements_Gtk_Buildable.To_Object; 
  430.  
  431. private 
  432.    Window_Placement_Set_Property : constant Glib.Properties.Property_Boolean := 
  433.      Glib.Properties.Build ("window-placement-set"); 
  434.    Window_Placement_Property : constant Gtk.Enums.Property_Gtk_Corner_Type := 
  435.      Gtk.Enums.Build ("window-placement"); 
  436.    Vscrollbar_Policy_Property : constant Gtk.Enums.Property_Gtk_Policy_Type := 
  437.      Gtk.Enums.Build ("vscrollbar-policy"); 
  438.    Vadjustment_Property : constant Glib.Properties.Property_Object := 
  439.      Glib.Properties.Build ("vadjustment"); 
  440.    Shadow_Type_Property : constant Gtk.Enums.Property_Gtk_Shadow_Type := 
  441.      Gtk.Enums.Build ("shadow-type"); 
  442.    Min_Content_Width_Property : constant Glib.Properties.Property_Int := 
  443.      Glib.Properties.Build ("min-content-width"); 
  444.    Min_Content_Height_Property : constant Glib.Properties.Property_Int := 
  445.      Glib.Properties.Build ("min-content-height"); 
  446.    Kinetic_Scrolling_Property : constant Glib.Properties.Property_Boolean := 
  447.      Glib.Properties.Build ("kinetic-scrolling"); 
  448.    Hscrollbar_Policy_Property : constant Gtk.Enums.Property_Gtk_Policy_Type := 
  449.      Gtk.Enums.Build ("hscrollbar-policy"); 
  450.    Hadjustment_Property : constant Glib.Properties.Property_Object := 
  451.      Glib.Properties.Build ("hadjustment"); 
  452. end Gtk.Scrolled_Window;