1. ----------------------------------------------------------------------- 
  2. --               GtkAda - Ada95 binding for Gtk+/Gnome               -- 
  3. --                                                                   -- 
  4. --                    Copyright (C) 2010-2013, AdaCore               -- 
  5. --                                                                   -- 
  6. -- This library is free software; you can redistribute it and/or     -- 
  7. -- modify it under the terms of the GNU General Public               -- 
  8. -- License as published by the Free Software Foundation; either      -- 
  9. -- version 2 of the License, or (at your option) any later version.  -- 
  10. --                                                                   -- 
  11. -- This library is distributed in the hope that it will be useful,   -- 
  12. -- but WITHOUT ANY WARRANTY; without even the implied warranty of    -- 
  13. -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU -- 
  14. -- General Public License for more details.                          -- 
  15. --                                                                   -- 
  16. -- You should have received a copy of the GNU General Public         -- 
  17. -- License along with this library; if not, write to the             -- 
  18. -- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      -- 
  19. -- Boston, MA 02111-1307, USA.                                       -- 
  20. --                                                                   -- 
  21. -- As a special exception, if other files instantiate generics from  -- 
  22. -- this unit, or you link this unit with other files to produce an   -- 
  23. -- executable, this  unit  does not  by itself cause  the resulting  -- 
  24. -- executable to be covered by the GNU General Public License. This  -- 
  25. -- exception does not however invalidate any other reasons why the   -- 
  26. -- executable file  might be covered by the  GNU Public License.     -- 
  27. ----------------------------------------------------------------------- 
  28.  
  29. --  <description> 
  30. --  A Gtk_Cell_Renderer_Accel displays a keyboard accelerator (i.e. a key 
  31. --  combination like <Control>-a). If the cell renderer is editable, the 
  32. --  accelerator can be changed by simply typing the new combination. 
  33. -- 
  34. --  The Gtk_Cell_Renderer_Accel cell renderer was added in GTK+ 2.10. 
  35. --  </description> 
  36. --  <c_version>2.16.6</c_version> 
  37.  
  38. with Glib.Properties; 
  39. with Gtk.Cell_Renderer_Text; 
  40.  
  41. package Gtk.Cell_Renderer_Accel is 
  42.  
  43.    type Gtk_Cell_Renderer_Accel_Record is 
  44.      new Gtk.Cell_Renderer_Text.Gtk_Cell_Renderer_Text_Record with private; 
  45.    type Gtk_Cell_Renderer_Accel is 
  46.      access all Gtk_Cell_Renderer_Accel_Record'Class; 
  47.  
  48.    procedure Gtk_New (Widget : out Gtk_Cell_Renderer_Accel); 
  49.    --  Creates a new Gtk_Cell_Renderer_Accel. 
  50.  
  51.    procedure Initialize 
  52.      (Widget : access Gtk_Cell_Renderer_Accel_Record'Class); 
  53.    --  Creates a new Gtk_Cell_Renderer_Accel. 
  54.  
  55.    function Get_Type return GType; 
  56.    --  Return the internal value associated with this widget. 
  57.  
  58.    ---------------- 
  59.    -- Properties -- 
  60.    ---------------- 
  61.  
  62.    --  <properties> 
  63.    --  Name:  Accel_Key_Property 
  64.    --  Type:  Uint 
  65.    --  Descr: The keyval of the accelerator 
  66.    -- 
  67.    --  Name:  Accel_Mode_Property 
  68.    --  Type:  Enum 
  69.    --  Descr: The type of accelerators 
  70.    -- 
  71.    --  Name:  Accel_Mods_Property 
  72.    --  Type:  Flags 
  73.    --  Descr: The modifier mask of the accelerator 
  74.    -- 
  75.    --  Name:  Keycode_Property 
  76.    --  Type:  Uint 
  77.    --  Descr: The hardware keycode of the accelerator 
  78.    -- 
  79.    --  </properties> 
  80.  
  81.    Accel_Key_Property  : constant Glib.Properties.Property_Uint; 
  82.    Accel_Mode_Property : constant Glib.Properties.Property_Enum; 
  83.    --  Accel_Mods_Property : constant Glib.Properties.Property_Flags; 
  84.    Keycode_Property    : constant Glib.Properties.Property_Uint; 
  85.  
  86. private 
  87.    type Gtk_Cell_Renderer_Accel_Record is 
  88.      new Gtk.Cell_Renderer_Text.Gtk_Cell_Renderer_Text_Record with null record; 
  89.  
  90.    Accel_Key_Property : constant Glib.Properties.Property_Uint := 
  91.      Glib.Properties.Build ("accel-key"); 
  92.    Accel_Mode_Property : constant Glib.Properties.Property_Enum := 
  93.      Glib.Properties.Build ("accel-mode"); 
  94.    --  Accel_Mods_Property : constant Glib.Properties.Property_Flags := 
  95.    --    Glib.Properties.Build ("accel-mods"); 
  96.    Keycode_Property : constant Glib.Properties.Property_Uint := 
  97.      Glib.Properties.Build ("keycode"); 
  98.  
  99.    pragma Import (C, Get_Type, "gtk_cell_renderer_accel_get_type"); 
  100. end Gtk.Cell_Renderer_Accel;