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-2010, 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 Gtk_Label is a light widget associated with some text you want 
  27. --  to display on the screen. You can change the text dynamically if 
  28. --  needed. 
  29. -- 
  30. --  The text can be on multiple lines if you separate each line with 
  31. --  the ASCII.LF character. However, this is not the recommended way 
  32. --  to display long texts (see the Gtk_Text widget instead). 
  33. -- 
  34. --  Mnemonics 
  35. --  ========= 
  36. --  Labels may contain mnemonics. Mnemonics are underlined characters in the 
  37. --  label, used for keyboard navigation. Mnemonics are created by providing 
  38. --  string with an underscore before the mnemonic character, such as "_File", 
  39. --  to the functions gtk_new_with_mnemonic or set_text_with_mnemonic(). 
  40. -- 
  41. --  Mnemonics automatically activate any activatable widget the label is 
  42. --  inside, such as a Gtk_Button; if the label is not inside the mnemonic's 
  43. --  target widget, you have to tell the label about the target using 
  44. --  set_mnemonic_widget(). For instance: 
  45. --      declare 
  46. --         Button : Gtk_Button; 
  47. --         Label  : Gtk_Label; 
  48. --      begin 
  49. --         Gtk_New (Button); 
  50. --         Gtk_New_With_Mnemonic (Label, "_File"); 
  51. --         Add (Button, Label); 
  52. --      end; 
  53. --  However, there exists a convenience function in Gtk.Button to create such 
  54. --  a button already. 
  55. -- 
  56. --  Markup 
  57. --  ====== 
  58. --  To make it easy to format text in a label (changing colors, fonts, etc.), 
  59. --  label text can be provided in a simple markup format. Here's how to create 
  60. --  a label with a small font: 
  61. --       Gtk_New (Label, "<small>hello</small>"); 
  62. -- 
  63. --  The markup must be valid, and <>& characters must be escaped with 
  64. --  &lt; &gt; and &amp; 
  65. -- 
  66. --  Markup strings are just a convenient way to set the Pango_Attr_List on 
  67. --  label; Set_Attributes() may be a simpler way to set attributes in some 
  68. --  cases. Be careful though; Pango_Attr_List tends to cause 
  69. --  internationalization problems, unless you're applying attributes to the 
  70. --  entire string (i.e. unless you set the range of each attribute to [0, 
  71. --  G_MAXINT)). The reason is that specifying the start_index and end_index for 
  72. --  a Pango_Attribute requires knowledge of the exact string being displayed, 
  73. --  so translations will cause problems. 
  74. -- 
  75. --  Selectable labels 
  76. --  ================= 
  77. --  Labels can be made selectable with Set_Selectable. Selectable 
  78. --  labels allow the user to copy the label contents to the clipboard. Only 
  79.  
  80. --  should be made selectable. 
  81. --  </description> 
  82. --  <c_version>2.8.17</c_version> 
  83. --  <group>Display widgets</group> 
  84. --  <testgtk>create_label.adb</testgtk> 
  85. --  <screenshot>gtk-label</screenshot> 
  86.  
  87. with Gdk.Types; 
  88. with Glib.Properties; 
  89. with Gtk.Enums; 
  90. with Gtk.Misc; 
  91. with Gtk.Widget; 
  92. with Pango.Attributes; 
  93. with Pango.Layout; 
  94.  
  95. package Gtk.Label is 
  96.  
  97.    type Gtk_Label_Record is new Misc.Gtk_Misc_Record with private; 
  98.    type Gtk_Label is access all Gtk_Label_Record'Class; 
  99.  
  100.    procedure Gtk_New (Label : out Gtk_Label; Str : UTF8_String := ""); 
  101.    procedure Initialize 
  102.      (Label : access Gtk_Label_Record'Class; Str : UTF8_String); 
  103.    --  Creates or initializes a new label. 
  104.    --  Str is the string to be displayed. 
  105.  
  106.    procedure Gtk_New_With_Mnemonic (Label : out Gtk_Label; Str : UTF8_String); 
  107.    procedure Initialize_With_Mnemonic 
  108.      (Label : access Gtk_Label_Record'Class; Str : UTF8_String); 
  109.    --  Creates or initializes a new label containing the text in Str. 
  110.    --  If characters in Str are preceded by an underscore, they are underlined 
  111.    --  indicating that they represent a keyboard accelerator called a mnemonic. 
  112.    --  The mnemonic key can be used to activate another widget, chosen 
  113.    --  automatically or explicitely using Set_Mnemonic_Widget. 
  114.  
  115.    function Get_Type return Glib.GType; 
  116.    --  Return the internal value associated with a Gtk_Label. 
  117.  
  118.    procedure Set_Justify 
  119.      (Label : access Gtk_Label_Record; 
  120.       Jtype : Enums.Gtk_Justification); 
  121.    function Get_Justify 
  122.      (Label : access Gtk_Label_Record) return Enums.Gtk_Justification; 
  123.    --  Set the justification for the label. 
  124.    --  The default value is Justify_Center, which means that the text will be 
  125.    --  centered in the label. Note that this setting has an impact only when 
  126.    --  the Gtk_Label is larger than the text (its default width is the same 
  127.    --  as the text) and contains multiple lines. 
  128.    --  To justify a single line label, you should instead call Set_Alignment 
  129.    --  and make sure that the label or any surrounding container fills its 
  130.    --  horizontal allocated space. 
  131.  
  132.    procedure Set_Line_Wrap (Label : access Gtk_Label_Record; Wrap : Boolean); 
  133.    function  Get_Line_Wrap (Label : access Gtk_Label_Record) return Boolean; 
  134.    --  Toggle line wrapping within Label. 
  135.    --  if Wrap is True, then Label will break lines if the text is larger 
  136.    --  then the widget's size. If Wrap is False, then the text is simply 
  137.    --  cut off. 
  138.  
  139.    procedure Set_Line_Wrap_Mode 
  140.      (Label     : access Gtk_Label_Record; 
  141.       Wrap_Mode : Pango.Layout.Pango_Wrap_Mode); 
  142.    function Get_Line_Wrap_Mode 
  143.      (Label : access Gtk_Label_Record) return Pango.Layout.Pango_Wrap_Mode; 
  144.    --  If line wrapping is on (see Set_Line_Wrap) this controls how the 
  145.    --  line wrapping is done. The default is Pango_Wrap_Word which means 
  146.    --  wrap on word boundaries. 
  147.  
  148.    procedure Set_Selectable 
  149.      (Label : access Gtk_Label_Record; Selectable : Boolean); 
  150.    function  Get_Selectable (Label : access Gtk_Label_Record) return Boolean; 
  151.    --  Selectable labels allow the user to select text from the label, 
  152.    --  for copy-and-paste. 
  153.  
  154.    procedure Set_Use_Markup 
  155.      (Label : access Gtk_Label_Record; Markup : Boolean); 
  156.    function Get_Use_Markup (Label : access Gtk_Label_Record) return Boolean; 
  157.    --  Sets whether the text of the label contains markup in Pango's 
  158.    --  text markup language.  If Markup is True, then Label will be 
  159.    --  parsed for markup. 
  160.  
  161.    procedure Set_Use_Underline 
  162.      (Label : access Gtk_Label_Record; Underline : Boolean); 
  163.    function Get_Use_Underline (Label : access Gtk_Label_Record) return Boolean; 
  164.    --  Indicates wether an embedded underline in the label indicates the 
  165.    --  mnemonic accelerator key. 
  166.  
  167.    procedure Set_Angle (Label : access Gtk_Label_Record;  Angle : Gdouble); 
  168.    function Get_Angle  (Label : access Gtk_Label_Record) return Gdouble; 
  169.    --  Sets the angle of rotation for the label. An angle of 90 reads from 
  170.    --  from bottom to top, an angle of 270, from top to bottom. The angle 
  171.    --  setting for the label is ignored if the label is selectable, 
  172.    --  wrapped, or ellipsized. 
  173.  
  174.    procedure Set_Ellipsize 
  175.      (Label : access Gtk_Label_Record; 
  176.       Mode  : Pango.Layout.Pango_Ellipsize_Mode); 
  177.    function Get_Ellipsize 
  178.      (Label : access Gtk_Label_Record) 
  179.       return Pango.Layout.Pango_Ellipsize_Mode; 
  180.    --  Sets the mode used to ellipsize (add an ellipsis: "...") to the text if 
  181.    --  there is not enough space to render the entire string. 
  182.  
  183.    procedure Set_Text (Label : access Gtk_Label_Record; Str : UTF8_String); 
  184.    function  Get_Text (Label : access Gtk_Label_Record) return UTF8_String; 
  185.    --  Change the text of the label. 
  186.    --  The new text is visible on the screen at once. Note that the underline 
  187.    --  pattern is not modified. 
  188.  
  189.    procedure Set_Label (Label : access Gtk_Label_Record; Str : String); 
  190.    function Get_Label  (Label : access Gtk_Label_Record) return String; 
  191.    --  Sets the text of the label. The label is interpreted as 
  192.    --  including embedded underlines and/or Pango markup depending 
  193.    --  on the values of label->use_underline and label->use_markup. 
  194.  
  195.    function Get_Layout 
  196.      (Label : access Gtk_Label_Record) return Pango.Layout.Pango_Layout; 
  197.    --  Gets the layout used to display the label. 
  198.    --  The layout is useful to e.g. convert text positions to pixel positions, 
  199.    --  in combination with Get_Layout_Offsets(). The returned layout is owned 
  200.    --  by the label so need not be freed by the caller. 
  201.  
  202.    procedure Get_Layout_Offsets 
  203.      (Label : access Gtk_Label_Record; 
  204.       X, Y  : out Gint); 
  205.    --  Obtains the coordinates where the label will draw the layout 
  206.    --  representing the text in the label; useful to convert mouse events into 
  207.    --  coordinates inside the layout, e.g. to take some action if some part of 
  208.    --  the label is clicked. Of course you will need to create a Gtk_Event_Box 
  209.    --  to receive the events, and pack the label inside it, since labels are a 
  210.    --  #GTK_NO_WINDOW widget. Remember when using the layout functions you need 
  211.    --  to convert to and from pixels using PANGO_PIXELS() or #PANGO_SCALE. 
  212.  
  213.    procedure Set_Max_Width_Chars 
  214.      (Label : access Gtk_Label_Record; N_Chars : Gint); 
  215.    function Get_Max_Width_Chars (Label : access Gtk_Label_Record) return Gint; 
  216.    --  Sets the desired maximum width in characters of Label 
  217.  
  218.    procedure Set_Width_Chars (Label : access Gtk_Label_Record; N_Chars : Gint); 
  219.    function Get_Width_Chars  (Label : access Gtk_Label_Record) return Gint; 
  220.    --  Sets the desired width in characters of Label. 
  221.  
  222.    procedure Set_Single_Line_Mode 
  223.      (Label            : access Gtk_Label_Record; 
  224.       Single_Line_Mode : Boolean); 
  225.    function Get_Single_Line_Mode 
  226.      (Label : access Gtk_Label_Record) return Boolean; 
  227.    --  Sets whether the label is in single line mode. 
  228.  
  229.    function Get_Mnemonic_Keyval 
  230.      (Label : access Gtk_Label_Record) return Gdk.Types.Gdk_Key_Type; 
  231.    --  Return the key value of the mnemonic accelerator key indicated by an 
  232.    --  embedded underline in the label. If there is no mnemonic set up it 
  233.    --  returns Gdk.Types.Keysyms.GDK_VoidSymbol. 
  234.  
  235.    procedure Set_Attributes 
  236.      (Label : access Gtk_Label_Record; 
  237.       Attrs : Pango.Attributes.Pango_Attr_List); 
  238.    function Get_Attributes 
  239.      (Label : access Gtk_Label_Record) return Pango.Attributes.Pango_Attr_List; 
  240.    --  Sets a list of attributes to be applied to the label text. These 
  241.    --  attributes will be ignored if the use_underline or use_markup 
  242.    --  properties are set. 
  243.    --  Get_Attributes does not reflect attributes that come from the label's 
  244.    --  markup (see Set_Markup). If you want to get the effective attributes for 
  245.    --  the label, use Pango.Layout.Get_Attribute (Get_Layout (Label)). 
  246.  
  247.    procedure Set_Text_With_Mnemonic 
  248.      (Label : access Gtk_Label_Record; 
  249.       Str   : UTF8_String); 
  250.    --  Change the text and mnemonic key of the label. 
  251.    --  The new text and mnemonic are visible on the screen at once. 
  252.    --  The mnemonic key can be used to activate another widget, chosen 
  253.    --  automatically or explicitely using Set_Mnemonic_Widget. 
  254.  
  255.    procedure Set_Markup (Label : access Gtk_Label_Record; Str : UTF8_String); 
  256.    --  Parses Str which is marked up with the Pango text markup language, 
  257.    --  setting the label's text and attribute list based on the parse results. 
  258.  
  259.    procedure Set_Markup_With_Mnemonic 
  260.      (Label : access Gtk_Label_Record; 
  261.       Str   : UTF8_String); 
  262.    --  Parse Str which is marked up with the Pango text markup language, 
  263.    --  setting the label's text and attribute list based on the parse results. 
  264.    --  If characters in Str are preceded by an underscore, they are underlined 
  265.    --  indicating that they represent a mnemonic. 
  266.    --  The mnemonic key can be used to activate another widget, chosen 
  267.    --  automatically or explicitely using Set_Mnemonic_Widget. 
  268.  
  269.    procedure Set_Mnemonic_Widget 
  270.      (Label  : access Gtk_Label_Record; 
  271.       Widget : access Gtk.Widget.Gtk_Widget_Record'Class); 
  272.    function Get_Mnemonic_Widget 
  273.      (Label : access Gtk_Label_Record) return Gtk.Widget.Gtk_Widget; 
  274.    --  If the label has been set so that it has an mnemonic key, the label can 
  275.    --  be associated with a widget that is the target of the mnemonic. 
  276.    --  When the label is inside a widget (like a Gtk_Button or a Gtk_Notebook 
  277.    --  tab), it is automatically associated with the correct widget, but 
  278.    --  sometimes (i.e. when the target is a Gtk_Entry next to the label), 
  279.    --  you need to set it explicitly using this procedure. 
  280.    --  The target widget will be accelerated by emitting "mnemonic_activate" 
  281.    --  on it. The default handler for this signal will activate the widget if 
  282.    --  there are no mnemonic collisions and toggle focus between the colliding 
  283.    --  widgets otherwise. 
  284.  
  285.    procedure Select_Region 
  286.      (Label        : access Gtk_Label_Record; 
  287.       Start_Offset : Integer := -1; 
  288.       End_Offset   : Integer := -1); 
  289.    --  Selects a range of characters in the label, if the label is 
  290.    --  selectable.  If Start or End are -1, then the end of the label 
  291.    --  will be substituted. 
  292.  
  293.    procedure Get_Selection_Bounds 
  294.      (Label         : access Gtk_Label_Record; 
  295.       First, Last   : out Gint; 
  296.       Has_Selection : out Boolean); 
  297.    --  Gets the selected range of characters in the label, returning True 
  298.    --  if there's a selection. 
  299.  
  300.    procedure Set_Pattern 
  301.      (Label   : access Gtk_Label_Record; 
  302.       Pattern : String); 
  303.    --  Change the underlines pattern. 
  304.    --  Pattern is a simple string made of underscore and space characters, 
  305.    --  matching the ones in the string. GtkAda will underline every letter 
  306.    --  that matches an underscore. 
  307.    --  An empty string disables the underlines. 
  308.    --  example: If the text is FooBarBaz and the Pattern is "___   ___" 
  309.    --  then both "Foo" and "Baz" will be underlined, but not "Bar". 
  310.  
  311.    ----------------- 
  312.    -- Obsolescent -- 
  313.    ----------------- 
  314.    --  All subprograms below are now obsolescent in gtk+. They might be removed 
  315.    --  from future versions of gtk+ (and therefore GtkAda). 
  316.    --  To find out whether your code uses any of these, we recommend compiling 
  317.    --  with the -gnatwj switch 
  318.    --  <doc_ignore> 
  319.  
  320.    function Get 
  321.      (Label : access Gtk_Label_Record) return UTF8_String renames Get_Text; 
  322.    --  pragma Obsolescent; 
  323.    --  Same as Get_Text. 
  324.  
  325.    --  </doc_ignore> 
  326.  
  327.    ---------------- 
  328.    -- Properties -- 
  329.    ---------------- 
  330.  
  331.    --  <properties> 
  332.    --  The following properties are defined for this widget. See 
  333.    --  Glib.Properties for more information on properties. 
  334.    -- 
  335.    --  Name:  Label_Property 
  336.    --  Type:  UTF8_String 
  337.    --  Flags: read-write 
  338.    --  Descr: The text of the label. 
  339.    --  See also: Set_Text and Get_Text 
  340.    -- 
  341.    --  Name:  Attributes_Property 
  342.    --  Type:  Pango_Type_Attr_List 
  343.    --  Flags: read-write 
  344.    --  Descr: A list of style attributes to apply to the text of the label. 
  345.    --  See also: ??? Unsupported yet 
  346.    -- 
  347.    --  Name:  Use_Markup_Property 
  348.    --  Type:  Boolean 
  349.    --  Flags: read-write 
  350.    --  Descr: The text of the label includes XML markup. 
  351.    --         See pango_parse_markup(). 
  352.    --  See also: <none> 
  353.    -- 
  354.    --  Name:  Use_Underline_Property 
  355.    --  Type:  Boolean 
  356.    --  Flags: read-write 
  357.    --  Descr: If set, an underline in the text indicates the next character 
  358.    --         should be used for the mnemonic accelerator key 
  359.    --  See also: <none> 
  360.    -- 
  361.    --  Name:  Justify_Property 
  362.    --  Type:  Gtk_Justification 
  363.    --  Flags: read-write 
  364.    --  Descr: The alignment of the lines in the text of the label relative to 
  365.    --         each other. This does NOT affect the alignment of the label 
  366.    --         within its allocation. 
  367.    --  See also: Set_Justify 
  368.    -- 
  369.    --  Name:  Pattern_Property 
  370.    --  Type:  String 
  371.    --  Flags: read-write 
  372.    --  Descr: A string with _ characters in positions correspond to 
  373.    --         characters in the text to underline. 
  374.    --  See also: Set_Pattern 
  375.    -- 
  376.    --  Name:  Wrap_Property 
  377.    --  Type:  Boolean 
  378.    --  Flags: read-write 
  379.    --  Descr: If set, wrap lines if the text becomes too wide. 
  380.    --  See also: Set_Line_Wrap 
  381.    -- 
  382.    --  Name:  Wrap_Mode_Property 
  383.    --  Type:  Enum 
  384.    --  Descr: If wrap is set, controls how linewrapping is done 
  385.    -- 
  386.    --  Name:  Selectable_Property 
  387.    --  Type:  Boolean 
  388.    --  Flags: read-write 
  389.    --  Descr: Whether the label text can be selected with the mouse. 
  390.    --  See also: <none> 
  391.    -- 
  392.    --  Name:  Mnemonic_Keyval_Property 
  393.    --  Type:  Guint 
  394.    --  Flags: readable 
  395.    --  Descr: The mnemonic accelerator key for this label. 
  396.    --  See also: Gtk_New_With_Mnemonic 
  397.    -- 
  398.    --  Name:  Mnemonic_Widget_Property 
  399.    --  Type:  Gtk_Widget_Record'Class 
  400.    --  Flags: read-write 
  401.    --  Descr: The widget to be activated when the label's mnemonic key is 
  402.    --         pressed 
  403.    -- 
  404.    --  Name:  Angle_Property 
  405.    --  Type:  Double 
  406.    --  Descr: Angle at which the label is rotated 
  407.    -- 
  408.    --  Name:  Cursor_Position_Property 
  409.    --  Type:  Int 
  410.    --  Descr: The current position of the insertion cursor in chars 
  411.    -- 
  412.    --  Name:  Ellipsize_Property 
  413.    --  Type:  Enum 
  414.    --  Descr: The preferred place to ellipsize the string, if the label does 
  415.    --         not have enough room to display the entire string, if at all 
  416.    -- 
  417.    --  Name:  Max_Width_Chars_Property 
  418.    --  Type:  Int 
  419.    --  Descr: The desired maximum width of the label, in characters 
  420.    -- 
  421.    --  Name:  Selection_Bound_Property 
  422.    --  Type:  Int 
  423.    --  Descr: The position of the opposite end of the selection from the cursor 
  424.    --         in chars 
  425.    -- 
  426.    --  Name:  Single_Line_Mode_Property 
  427.    --  Type:  Boolean 
  428.    --  Descr: Whether the label is in single line mode 
  429.    -- 
  430.    --  Name:  Width_Chars_Property 
  431.    --  Type:  Int 
  432.    --  Descr: The desired width of the label, in characters 
  433.    -- 
  434.    --  </properties> 
  435.  
  436.    Label_Property            : constant Glib.Properties.Property_String; 
  437.    --  Attributes_Property   : constant ??? 
  438.    Use_Markup_Property       : constant Glib.Properties.Property_Boolean; 
  439.    Use_Underline_Property    : constant Glib.Properties.Property_Boolean; 
  440.    Justify_Property          : constant Gtk.Enums.Property_Gtk_Justification; 
  441.    Pattern_Property          :  constant Glib.Properties.Property_String; 
  442.    Wrap_Property             : constant Glib.Properties.Property_Boolean; 
  443.    Wrap_Mode_Property        : constant Glib.Properties.Property_Enum; 
  444.    Selectable_Property       : constant Glib.Properties.Property_Boolean; 
  445.    Mnemonic_Keyval_Property  : constant Glib.Properties.Property_Uint_RO; 
  446.    Mnemonic_Widget_Property  : constant Glib.Properties.Property_Object; 
  447.    Angle_Property            : constant Glib.Properties.Property_Double; 
  448.    Cursor_Position_Property  : constant Glib.Properties.Property_Int; 
  449.    --  Ellipsize_Property        : constant Glib.Properties.Property_Enum; 
  450.    Max_Width_Chars_Property  : constant Glib.Properties.Property_Int; 
  451.    Selection_Bound_Property  : constant Glib.Properties.Property_Int; 
  452.    Single_Line_Mode_Property : constant Glib.Properties.Property_Boolean; 
  453.    Width_Chars_Property      : constant Glib.Properties.Property_Int; 
  454.  
  455.    ------------- 
  456.    -- Signals -- 
  457.    ------------- 
  458.  
  459.    --  <signals> 
  460.    --  The following new signals are defined for this widget: 
  461.    -- 
  462.    --  - "copy_clipboard" 
  463.    --    procedure Handler (Label : access Gtk_Label_Record'Class); 
  464.    --    Request a copy the label's text into the clipboard. This should be 
  465.    --    bound to a key. 
  466.    -- 
  467.    --  - "move_cursor" 
  468.    --    procedure Handler 
  469.    --       (Label  : access Gtk_Label_Record'Class; 
  470.    --        Step   : Gtk_Movement_Step; 
  471.    --        Amount : Gint; 
  472.    --        Extend_Selection : Boolean); 
  473.    --    You should emit this signal to request that the cursor be moved inside 
  474.    --    the label. This is mostly useful from a keybinding. The cursor is 
  475.    --    also used as the insertion point when modifying the label 
  476.    -- 
  477.    --  - "populate_popup" 
  478.    --    procedure Handler 
  479.    --       (Label : access Gtk_Label_Record'Class; 
  480.    --        Menu  : access Gtk_Menu_Record'Class); 
  481.    --    ??? 
  482.    -- 
  483.    --  </signals> 
  484.  
  485.    Signal_Copy_Clipboard : constant Glib.Signal_Name := "copy_clipboard"; 
  486.    Signal_Move_Cursor    : constant Glib.Signal_Name := "move_cursor"; 
  487.    Signal_Populate_Popup : constant Glib.Signal_Name := "populate_popup"; 
  488.  
  489. private 
  490.    type Gtk_Label_Record is new Misc.Gtk_Misc_Record with null record; 
  491.  
  492.    Label_Property           : constant Glib.Properties.Property_String := 
  493.      Glib.Properties.Build ("label"); 
  494.    Use_Markup_Property      : constant Glib.Properties.Property_Boolean := 
  495.      Glib.Properties.Build ("use_markup"); 
  496.    Use_Underline_Property   : constant Glib.Properties.Property_Boolean := 
  497.      Glib.Properties.Build ("use_underline"); 
  498.    Justify_Property         : constant Gtk.Enums.Property_Gtk_Justification := 
  499.      Gtk.Enums.Build ("justify"); 
  500.    Pattern_Property         : constant Glib.Properties.Property_String := 
  501.      Glib.Properties.Build ("pattern"); 
  502.    Wrap_Property            : constant Glib.Properties.Property_Boolean := 
  503.      Glib.Properties.Build ("wrap"); 
  504.    Wrap_Mode_Property : constant Glib.Properties.Property_Enum := 
  505.      Glib.Properties.Build ("wrap-mode"); 
  506.    Selectable_Property      : constant Glib.Properties.Property_Boolean := 
  507.      Glib.Properties.Build ("selectable"); 
  508.    Mnemonic_Keyval_Property : constant Glib.Properties.Property_Uint_RO := 
  509.      Glib.Properties.Build ("mnemonic_keyval"); 
  510.    Mnemonic_Widget_Property : constant Glib.Properties.Property_Object := 
  511.      Glib.Properties.Build ("mnemonic_widget"); 
  512.    Angle_Property : constant Glib.Properties.Property_Double := 
  513.      Glib.Properties.Build ("angle"); 
  514.    Cursor_Position_Property : constant Glib.Properties.Property_Int := 
  515.      Glib.Properties.Build ("cursor-position"); 
  516.    --     Ellipsize_Property : constant Glib.Properties.Property_Enum := 
  517.    --       Glib.Properties.Build ("ellipsize"); 
  518.    Max_Width_Chars_Property : constant Glib.Properties.Property_Int := 
  519.      Glib.Properties.Build ("max-width-chars"); 
  520.    Selection_Bound_Property : constant Glib.Properties.Property_Int := 
  521.      Glib.Properties.Build ("selection-bound"); 
  522.    Single_Line_Mode_Property : constant Glib.Properties.Property_Boolean := 
  523.      Glib.Properties.Build ("single-line-mode"); 
  524.    Width_Chars_Property : constant Glib.Properties.Property_Int := 
  525.      Glib.Properties.Build ("width-chars"); 
  526.  
  527.    pragma Import (C, Get_Type, "gtk_label_get_type"); 
  528. end Gtk.Label; 
  529.  
  530. --  These subprograms never had a binding, but are now obsolescent: 
  531. --  No binding: gtk_label_get 
  532. --  No binding: gtk_label_parse_uline