The unified diff between revisions [ae250f26..] and [cce1c44c..] is displayed below. It can also be downloaded as a raw diff.

#
#
# add_dir "examples/calendar_combo"
#
# add_file "examples/calendar_combo/Makefile"
#  content [65624aa02061d3ff374984dc6630d3063aee498d]
#
# add_file "examples/calendar_combo/README"
#  content [ffe50973c828a92ae062c7482291d21b2972d630]
#
# add_file "examples/calendar_combo/calendar_combo.adb"
#  content [fb93fd7c2b56933ebdbe6054a9ed0d116ea8b1ea]
#
# add_file "examples/calendar_combo/calendar_combo.ads"
#  content [f7ea39cf828ec880ef48eed33f077d5e50f12528]
#
# add_file "examples/calendar_combo/default.gpr"
#  content [9de0cb15a353738bc4b1d1937b2cdb31db67c839]
#
# add_file "examples/calendar_combo/main.adb"
#  content [7813a6f554ecb96c108d85d92f2d05699ebc48b5]
#
# add_file "src/gtk-extra-border_combo.adb"
#  content [bc6039546cfa594f9bf0698aa28bfc40bf2fd40f]
#
# add_file "src/gtk-extra-border_combo.ads"
#  content [cc820ee99ad4399a6f1e29c634968996adb252cd]
#
# add_file "src/gtk-extra-color_combo.adb"
#  content [4a82c1126ebc86ec37c9d3ab8d18b503a3746ea0]
#
# add_file "src/gtk-extra-color_combo.ads"
#  content [4fec363c7a97c4a2e9f2a3729205939b49754eb2]
#
# add_file "src/gtk-extra-combo_button.adb"
#  content [f570878260a4aa912e37ddef4787f2dc5cf47bce]
#
# add_file "src/gtk-extra-combo_button.ads"
#  content [d340f0ade2f4e369b4e77ae5a323fbcb8b534046]
#
# add_file "src/gtk-extra-font_combo.adb"
#  content [b304e28cfadabfe367bb4714a8ec5c60ba185cca]
#
# add_file "src/gtk-extra-font_combo.ads"
#  content [bc1cae5678b29481a3fe064e83619c9672f96d30]
#
# add_file "src/gtk-extra-item_entry.adb"
#  content [6de4ad11a43854aef065a3d7eeb82aed57f6ad8b]
#
# add_file "src/gtk-extra-item_entry.ads"
#  content [db9b783cf390bb2988e528bf46f915336f9701ee]
#
# add_file "src/gtk-extra-plot.adb"
#  content [d217f35999435fe1f99f44a5ada34bfcb1176116]
#
# add_file "src/gtk-extra-plot.ads"
#  content [3972c2a4a746eb9cb9be89227276b4886f6d1cc7]
#
# add_file "src/gtk-extra-plot_3d.adb"
#  content [0e6c2a1c8d5150615c04e1ba18b11be2f16d2082]
#
# add_file "src/gtk-extra-plot_3d.ads"
#  content [38a8667ca9fe9c868a9f785984430d243d4be122]
#
# add_file "src/gtk-extra-plot_bar.adb"
#  content [869695180e937b1b157534e5f23aad2216b39b12]
#
# add_file "src/gtk-extra-plot_bar.ads"
#  content [41a2a299515a5367e3cb91119920f6e8c2b80623]
#
# add_file "src/gtk-extra-plot_box.adb"
#  content [00410c82754bc402f9984d9648ce391fb80c9cdb]
#
# add_file "src/gtk-extra-plot_box.ads"
#  content [978c1f8eef3a0a0b5d36ebf7d7eb6927e6191357]
#
# add_file "src/gtk-extra-plot_canvas-ellipse.adb"
#  content [10b9df3474b9b7467d7433a778217bfa107cb290]
#
# add_file "src/gtk-extra-plot_canvas-ellipse.ads"
#  content [53ca9fc4a80435c29e482eece85b8ea6e177522e]
#
# add_file "src/gtk-extra-plot_canvas-line.adb"
#  content [b4035eac2f0190b9ec69d706b2a2312532e64e6d]
#
# add_file "src/gtk-extra-plot_canvas-line.ads"
#  content [2f9e9db0d5cdf7aa649656c634e1e4e366722605]
#
# add_file "src/gtk-extra-plot_canvas-pixmap.adb"
#  content [bdd26c4848ef1c1c576aeb307f34a106c5d581ef]
#
# add_file "src/gtk-extra-plot_canvas-pixmap.ads"
#  content [adc349d259728e358e53cfb566ae40394200de5f]
#
# add_file "src/gtk-extra-plot_canvas-plot.adb"
#  content [43102ab60118f53a63f99d861ab6a371a063bb47]
#
# add_file "src/gtk-extra-plot_canvas-plot.ads"
#  content [2f85637afa155f748d8919cceae6a45b4acabfab]
#
# add_file "src/gtk-extra-plot_canvas-rectangle.adb"
#  content [682c49766a2302dbae99fc4eb23f9c5c4be0cd65]
#
# add_file "src/gtk-extra-plot_canvas-rectangle.ads"
#  content [c963391494dbb94f7d0e7ed1e8f376c59c295673]
#
# add_file "src/gtk-extra-plot_canvas-text.adb"
#  content [2837b3804a0cd59f24e3d059ea1844f854483e19]
#
# add_file "src/gtk-extra-plot_canvas-text.ads"
#  content [7e0d5ffa8fd3c982602dea115940e96b5f33f70f]
#
# add_file "src/gtk-extra-plot_canvas.adb"
#  content [6f4bf477777c86f8dcc38d97d92d531fe6df6833]
#
# add_file "src/gtk-extra-plot_canvas.ads"
#  content [06e39bbcbef0276629e6a59e44c00ec8a0f58dc2]
#
# add_file "src/gtk-extra-plot_data.adb"
#  content [6de9b2f25ae173b9683152815a12e9f843054e5a]
#
# add_file "src/gtk-extra-plot_data.ads"
#  content [6ba620bcec28e873d612a186f0c5ab3b7cb6d78b]
#
# add_file "src/gtk-extra-plot_polar.adb"
#  content [9f676a82ad85bff427bfc7b17b5b4008939e29bf]
#
# add_file "src/gtk-extra-plot_polar.ads"
#  content [0d166b1916130270f744ed86a042b4930718a082]
#
# add_file "src/gtk-extra-plot_ps.adb"
#  content [52cddc14b96f05b9f14c9a60fd49618ab3dbb67f]
#
# add_file "src/gtk-extra-plot_ps.ads"
#  content [38865cdbfcb48472719da41d3d5a09220b9565a4]
#
# add_file "src/gtk-extra-plot_surface.adb"
#  content [fc762d6b378ea57c9c4b6288bcc1352b62dc6efc]
#
# add_file "src/gtk-extra-plot_surface.ads"
#  content [cdbe49226340d455231d235bd6af6f8bb03264db]
#
# add_file "src/gtk-extra-sheet.adb"
#  content [1bf8fc6a372cb9a70103307fb5b18fc8c268dc78]
#
# add_file "src/gtk-extra-sheet.ads"
#  content [cbca264d5a5f4fda4c40c27164767d2e37b012c6]
#
# add_file "src/gtk-extra.ads"
#  content [1005919c171d5cb68a1d6915c500025d728815f1]
#
# add_file "src/misc_extra.c"
#  content [23c4cc0b4866a4c380adaccc8906755cc544b6b8]
#
# add_file "testgtk/create_plot.adb"
#  content [47e692e9ca2d3ba5fe762c0ae3b16ce92ca74dff]
#
# add_file "testgtk/create_plot.ads"
#  content [f0898e228224f08d3d940b12a9e47f19bf499578]
#
# add_file "testgtk/create_plot_3d.adb"
#  content [4a498613d7322869439b296cfd2bdf9e5cf6c833]
#
# add_file "testgtk/create_plot_3d.ads"
#  content [abfa57ced7e01e1d6722c41384f63294dd734118]
#
# add_file "testgtk/create_plot_realtime.adb"
#  content [e0f3f3f51f80bfa088a586c02706134c04a0197d]
#
# add_file "testgtk/create_plot_realtime.ads"
#  content [91fa1432c884c42a76fb9dc0d4850eac77a766e0]
#
# add_file "testgtk/create_sheet.adb"
#  content [e928a443fd779b6e259174926a9a8cb901dfcde1]
#
# add_file "testgtk/create_sheet.ads"
#  content [a9ace23da2b57ea2d1bb28661a71c51c971baca5]
#
# patch "configure"
#  from [87b5a93533eadb7c7a77c419872398516654a384]
#    to [2a0c47618af215c6a45a70469554924ae8e86fa0]
#
# patch "configure.in"
#  from [847aecc17e4fe98d131a2ed8bee5f131ad83a256]
#    to [13e616415969b698f50b0d0f067b22fe42d890b9]
#
# patch "projects/gtkada.lgpr"
#  from [17d02abffffab660b97678988db9008b9aa51dc9]
#    to [1d7433918b25033e5f64c4931db4d0574da730e4]
#
# patch "src/Makefile.in"
#  from [ed94ba0b7f35f130bfedc2de14076d307897ed67]
#    to [abf20d5657a276401df89f57f94f5790b39b66c7]
#
# patch "src/gtk-about_dialog.ads"
#  from [47e0174262e5214600390006e2b169f2f385b4f4]
#    to [dd5c4bbd28d4c2248f198d54bda94c7aeadc8489]
#
# patch "src/gtkada_src.gpr"
#  from [f670b24b3909a75f811365e8644acb45f7212397]
#    to [7df34e9bdd2097b656079bee63ce0c3400abf4d8]
#
# patch "testgtk/common.adb"
#  from [31926839371cbaeae8347cc8fc30a82ac15290cf]
#    to [08c79af2fe41a190afaf0c78cc7047f2a09203dd]
#
# patch "testgtk/common.ads"
#  from [28def28b5bd0d3671afdc0589e50baaee1b2a9c6]
#    to [c2bae17ebeea7552129330198c66a645be00f4d0]
#
# patch "testgtk/main_windows.adb"
#  from [ad6cf2b351a912f91cc2d369bc155570b8ba9382]
#    to [e41d8ec6ecd2d92b8b60ef67b19a982cdbc3f88f]
#
============================================================
--- examples/calendar_combo/Makefile	65624aa02061d3ff374984dc6630d3063aee498d
+++ examples/calendar_combo/Makefile	65624aa02061d3ff374984dc6630d3063aee498d
@@ -0,0 +1,7 @@
+all: main
+
+main:
+	gnatmake -Pdefault
+
+clean:
+	gnat clean -Pdefault
============================================================
--- examples/calendar_combo/README	ffe50973c828a92ae062c7482291d21b2972d630
+++ examples/calendar_combo/README	ffe50973c828a92ae062c7482291d21b2972d630
@@ -0,0 +1,4 @@
+This directory shows how one can use the Gtk_Combo_Box widget
+to implement some special combo boxes.
+In this example, we implement a combo box that allows the user to
+select a date.
============================================================
--- examples/calendar_combo/calendar_combo.adb	fb93fd7c2b56933ebdbe6054a9ed0d116ea8b1ea
+++ examples/calendar_combo/calendar_combo.adb	fb93fd7c2b56933ebdbe6054a9ed0d116ea8b1ea
@@ -0,0 +1,101 @@
+with Glib;        use Glib;
+with Glib.Values; use Glib.Values;
+with Gtk.Frame;   use Gtk.Frame;
+with Gtk.Widget;  use Gtk.Widget;
+with Gtk.Button;  use Gtk.Button;
+with Gtk.Toggle_Button; use Gtk.Toggle_Button;
+with Unchecked_Conversion;
+with System;
+with Gtk.Handlers; use Gtk.Handlers;
+
+package body Calendar_Combo is
+
+   type Requisition_Access is access Gtk.Widget.Gtk_Requisition;
+   function Convert is new Unchecked_Conversion
+     (System.Address, Requisition_Access);
+
+   package Cal_Cb is new Gtk.Handlers.Callback (Gtk_Calendar_Combo_Record);
+
+   ------------------
+   -- Size_Request --
+   ------------------
+
+   procedure Size_Request
+     (Widget      : access Gtk_Calendar_Combo_Record'Class;
+      Params      : Glib.Values.GValues)
+   is
+      use type Gint;
+      Requisition : Requisition_Access :=
+        Convert (Get_Address (Nth (Params, 1)));
+      Req_Arrow,
+      Req_Button : Gtk_Requisition;
+   begin
+      Size_Request (Get_Button (Widget), Req_Button);
+      Size_Request (Get_Toggle_Button (Widget), Req_Arrow);
+      Requisition.Width := Req_Button.Width + Req_Arrow.Width;
+      Requisition.Height := Gint'Max (Req_Button.Height, Req_Arrow.Height);
+
+      --  Stop the signal from being propagated to the parent's default
+      --  size_request function
+      Emit_Stop_By_Name (Widget, "size_request");
+   end Size_Request;
+
+   -----------------
+   -- Format_Date --
+   -----------------
+
+   function Format_Date (Cal : access Gtk_Calendar_Record'Class)
+                        return String
+   is
+      Year, Month, Day : Guint;
+   begin
+      Get_Date (Cal, Year, Month, Day);
+      return Guint'Image (Month + 1) & "/"
+        & Guint'Image (Day) & "/"
+        & Guint'Image (Year);
+   end Format_Date;
+
+   ------------------
+   -- Day_Selected --
+   ------------------
+
+   procedure Day_Selected
+     (Calendar : access Gtk_Calendar_Combo_Record'Class)
+   is
+   begin
+      Set_Text (Calendar.Label, Format_Date (Calendar.Cal));
+      Hide_Popdown_Window (Calendar);
+   end Day_Selected;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Calendar : out Gtk_Calendar_Combo) is
+   begin
+      Calendar := new Gtk_Calendar_Combo_Record;
+      Calendar_Combo.Initialize (Calendar);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Calendar : access Gtk_Calendar_Combo_Record'Class) is
+   begin
+      Gtk.Extra.Combo_Button.Initialize (Calendar);
+      Gtk_New (Calendar.Cal);
+      Show (Calendar.Cal);
+
+      Gtk_New (Calendar.Label, Format_Date (Calendar.Cal));
+      Add (Get_Button (Calendar), Calendar.Label);
+      Show (Calendar.Label);
+      Add (Get_Frame (Calendar), Calendar.Cal);
+
+      Cal_Cb.Connect (Calendar, "size_request", Size_Request'Access);
+      Cal_Cb.Object_Connect (Calendar.Cal, "day_selected",
+                             Cal_Cb.To_Marshaller (Day_Selected'Access),
+                             Slot_Object => Calendar);
+   end Initialize;
+
+end Calendar_Combo;
============================================================
--- examples/calendar_combo/calendar_combo.ads	f7ea39cf828ec880ef48eed33f077d5e50f12528
+++ examples/calendar_combo/calendar_combo.ads	f7ea39cf828ec880ef48eed33f077d5e50f12528
@@ -0,0 +1,25 @@
+
+--  This file shows how a special kind of combo box can be implemented.
+--  In this example, we create a combo box that contains a calendar, and
+--  that allows the user to easily select a date.
+
+with Gtk.Extra.Combo_Button; use Gtk.Extra.Combo_Button;
+with Gtk.Calendar;        use Gtk.Calendar;
+with Gtk.Label;           use Gtk.Label;
+
+package Calendar_Combo is
+
+   type Gtk_Calendar_Combo_Record is new Gtk_Combo_Button_Record with private;
+   type Gtk_Calendar_Combo is access all Gtk_Calendar_Combo_Record'Class;
+
+   procedure Gtk_New (Calendar : out Gtk_Calendar_Combo);
+   procedure Initialize (Calendar : access Gtk_Calendar_Combo_Record'Class);
+
+private
+   type Gtk_Calendar_Combo_Record is new Gtk_Combo_Button_Record
+     with record
+        Cal   : Gtk_Calendar;
+        Label : Gtk_Label;
+     end record;
+end Calendar_Combo;
+
============================================================
--- examples/calendar_combo/default.gpr	9de0cb15a353738bc4b1d1937b2cdb31db67c839
+++ examples/calendar_combo/default.gpr	9de0cb15a353738bc4b1d1937b2cdb31db67c839
@@ -0,0 +1,7 @@
+--  The following with clause is the only thing necessary to compile and link
+--  a GtkAda application
+
+with "gtkada";
+project Default is
+   for Main use ("main.adb");
+end Default;
============================================================
--- examples/calendar_combo/main.adb	7813a6f554ecb96c108d85d92f2d05699ebc48b5
+++ examples/calendar_combo/main.adb	7813a6f554ecb96c108d85d92f2d05699ebc48b5
@@ -0,0 +1,43 @@
+with Gtk.Enums;  use Gtk.Enums;
+with Gtk.Handlers;
+with Gtk.Main;   use Gtk.Main;
+with Gtk.Window; use Gtk.Window;
+with Calendar_Combo; use Calendar_Combo;
+
+procedure Main is
+   Win : Gtk_Window;
+   Cal : Gtk_Calendar_Combo;
+
+   function On_Main_Window_Delete_Event
+     (Object : access Gtk_Window_Record'Class) return Boolean;
+   --  Handler for the delete_event signal
+
+   function On_Main_Window_Delete_Event
+     (Object : access Gtk_Window_Record'Class)
+      return Boolean
+   is
+      pragma Unreferenced (Object);
+   begin
+      Gtk.Main.Gtk_Exit (0);
+      return True;
+   end On_Main_Window_Delete_Event;
+
+   package Window_Cb is new Gtk.Handlers.Return_Callback
+     (Gtk_Window_Record, Boolean);
+
+begin
+   Gtk.Main.Init;
+
+   Gtk_New (Win, Window_Toplevel);
+
+   Gtk_New (Cal);
+   Add (Win, Cal);
+
+   Window_Cb.Connect
+     (Win, "delete_event",
+      Window_Cb.To_Marshaller (On_Main_Window_Delete_Event'Access));
+
+   Show_All (Win);
+
+   Gtk.Main.Main;
+end Main;
============================================================
--- src/gtk-extra-border_combo.adb	bc6039546cfa594f9bf0698aa28bfc40bf2fd40f
+++ src/gtk-extra-border_combo.adb	bc6039546cfa594f9bf0698aa28bfc40bf2fd40f
@@ -0,0 +1,57 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                     Copyright (C) 2000                            --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Border_Combo is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Border_Combo_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Widget : out Gtk_Border_Combo) is
+   begin
+      Widget := new Gtk_Border_Combo_Record;
+      Gtk.Extra.Border_Combo.Initialize (Widget);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Widget : access Gtk_Border_Combo_Record'Class)
+   is
+      function Internal return System.Address;
+      pragma Import (C, Internal, "gtk_border_combo_new");
+   begin
+      Set_Object (Widget, Internal);
+   end Initialize;
+
+end Gtk.Extra.Border_Combo;
============================================================
--- src/gtk-extra-border_combo.ads	cc820ee99ad4399a6f1e29c634968996adb252cd
+++ src/gtk-extra-border_combo.ads	cc820ee99ad4399a6f1e29c634968996adb252cd
@@ -0,0 +1,69 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Border_Combo is a special kind of combo box that allows the
+--  user to select the border to apply to cells in a spreadsheet.
+--  Its main usage seems to be with a Gtk_Sheet.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Selectors</group>
+
+with Gtk.Extra.Combo_Button;
+
+package Gtk.Extra.Border_Combo is
+
+   type Gtk_Border_Combo_Record is
+     new Gtk.Extra.Combo_Button.Gtk_Combo_Button_Record with private;
+   type Gtk_Border_Combo is access all Gtk_Border_Combo_Record'Class;
+
+   procedure Gtk_New (Widget : out Gtk_Border_Combo);
+   --  Create a new border combo.
+   --  The button contains the currently selected border.
+
+   procedure Initialize (Widget : access Gtk_Border_Combo_Record'Class);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Border_Combo.
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --
+   --  - "changed"
+   --  procedure Handler (Combo : access Gtk_Border_Combo_Record'Class;
+   --                     Selection : Gint);
+   --
+   --  Emitted when a new font has been selected.
+   --  Selection is the number of the selection font.
+   --  </signals>
+private
+   type Gtk_Border_Combo_Record is
+     new Gtk.Extra.Combo_Button.Gtk_Combo_Button_Record with null record;
+   pragma Import (C, Get_Type, "gtk_border_combo_get_type");
+end Gtk.Extra.Border_Combo;
============================================================
--- src/gtk-extra-color_combo.adb	4a82c1126ebc86ec37c9d3ab8d18b503a3746ea0
+++ src/gtk-extra-color_combo.adb	4a82c1126ebc86ec37c9d3ab8d18b503a3746ea0
@@ -0,0 +1,286 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gdk.Color;   use Gdk.Color;
+with System;
+with Gtk.Widget;
+with Ada.Unchecked_Conversion;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Color_Combo is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Color_Combo_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   procedure Set_Row
+     (Combo : access Gtk_Color_Combo_Record'Class;
+      Row   : Gint);
+   --  Set the selected row in the widget
+
+   procedure Set_Column
+     (Combo  : access Gtk_Color_Combo_Record'Class;
+      Column : Gint);
+   --  Set the selected column in the widget
+
+   type Color_Access is access Gdk_Color;
+   function Convert is new Ada.Unchecked_Conversion
+     (System.Address, Color_Access);
+
+   ----------------
+   -- Find_Color --
+   ----------------
+
+   procedure Find_Color (Color_Combo : access Gtk_Color_Combo_Record;
+                         Color       : in Gdk.Color.Gdk_Color;
+                         Row         : out Gint;
+                         Col         : out Gint)
+   is
+      procedure Internal (Color_Combo : in System.Address;
+                          Color       : in System.Address;
+                          Row         : out Gint;
+                          Col         : out Gint);
+      pragma Import (C, Internal, "gtk_color_combo_find_color");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+   begin
+      if Color = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Color_Combo), Ca, Row, Col);
+   end Find_Color;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Widget : out Gtk_Color_Combo) is
+   begin
+      Widget := new Gtk_Color_Combo_Record;
+      Gtk.Extra.Color_Combo.Initialize (Widget);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Widget : access Gtk_Color_Combo_Record'Class) is
+      function Internal return System.Address;
+      pragma Import (C, Internal, "gtk_color_combo_new");
+   begin
+      Set_Object (Widget, Internal);
+   end Initialize;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Widget : out Gtk_Color_Combo;
+      Nrows  : Gint;
+      Ncols  : Gint;
+      Values : Gdk.Color.Gdk_Color_Array) is
+   begin
+      Widget := new Gtk_Color_Combo_Record;
+      Initialize (Widget, Nrows, Ncols, Values);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Widget : access Gtk_Color_Combo_Record;
+      Nrows  : Gint;
+      Ncols  : Gint;
+      Values : Gdk.Color.Gdk_Color_Array)
+   is
+      function Internal (Nrows  : in Gint;
+                         Ncols  : in Gint;
+                         Values : in System.Address)
+                        return System.Address;
+      pragma Import (C, Internal, "gtk_color_combo_new_with_values");
+   begin
+      Set_Object
+        (Widget, Internal (Nrows, Ncols,  Values (Values'First)'Address));
+   end Initialize;
+
+   ------------------
+   -- Get_Color_At --
+   ------------------
+
+   function Get_Color_At (Widget : access Gtk_Color_Combo_Record;
+                          Row    : Gint;
+                          Col    : Gint)
+                         return Gdk_Color
+   is
+      function Internal
+        (Widget : System.Address;
+         Row    : Gint;
+         Col    : Gint) return System.Address;
+      pragma Import (C, Internal, "gtk_color_combo_get_color_at");
+
+      Color : Color_Access;
+   begin
+      Color := Convert (Internal (Get_Object (Widget), Row, Col));
+      return Color.all;
+   end Get_Color_At;
+
+   ---------------
+   -- Set_Color --
+   ---------------
+
+   function Set_Color
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Name        : String)
+      return Boolean
+   is
+      Color : Gdk_Color;
+   begin
+      Color := Parse (Name);
+      Alloc (Gtk.Widget.Get_Default_Colormap, Color);
+      return Set_Color (Color_Combo, Color);
+   end Set_Color;
+
+   ---------------
+   -- Set_Color --
+   ---------------
+
+   function Set_Color
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Color       : Gdk.Color.Gdk_Color)
+      return Boolean
+   is
+      Row, Col : Gint;
+   begin
+      Find_Color (Color_Combo, Color, Row, Col);
+
+      if Row = -1 or else Col = -1 then
+         return False;
+      end if;
+
+      --  ??? Need to press the button in the popup window
+
+      Set_Row (Color_Combo, Row);
+      Set_Column (Color_Combo, Col);
+      Changed (Color_Combo, Row, Col);
+      return True;
+   end Set_Color;
+
+   -------------
+   -- Changed --
+   -------------
+
+   procedure Changed
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Row : Gint;
+      Col : Gint)
+   is
+      procedure Internal
+        (Combo     : System.Address;
+         Signal    : String;
+         Selection : Gint;
+         Color     : System.Address);
+      pragma Import (C, Internal, "ada_g_signal_emit_by_name_int_ptr");
+
+      C : aliased constant Gdk_Color := Get_Color_At (Color_Combo, Row, Col);
+   begin
+      Internal (Get_Object (Color_Combo), "changed" & ASCII.NUL,
+                Row * Get_Ncols (Color_Combo) + Col, C'Address);
+   end Changed;
+
+   ---------------
+   -- Get_Ncols --
+   ---------------
+
+   function Get_Ncols (Color_Combo : access Gtk_Color_Combo_Record)
+      return Gint
+   is
+      function Internal (Combo : System.Address) return Gint;
+      pragma Import (C, Internal, "ada_gtk_extra_color_combo_get_ncols");
+   begin
+      return Internal (Get_Object (Color_Combo));
+   end Get_Ncols;
+
+   ---------------
+   -- Get_Nrows --
+   ---------------
+
+   function Get_Nrows (Color_Combo : access Gtk_Color_Combo_Record)
+      return Gint
+   is
+      function Internal (Combo : System.Address) return Gint;
+      pragma Import (C, Internal, "ada_gtk_extra_color_combo_get_nrows");
+   begin
+      return Internal (Get_Object (Color_Combo));
+   end Get_Nrows;
+
+   -------------
+   -- Set_Row --
+   -------------
+
+   procedure Set_Row
+     (Combo : access Gtk_Color_Combo_Record'Class;
+      Row   : Gint)
+   is
+      procedure Internal (Combo : System.Address; Row : Gint);
+      pragma Import (C, Internal, "ada_gtk_extra_color_combo_set_row");
+   begin
+      Internal (Get_Object (Combo), Row);
+   end Set_Row;
+
+   ----------------
+   -- Set_Column --
+   ----------------
+
+   procedure Set_Column
+     (Combo  : access Gtk_Color_Combo_Record'Class;
+      Column : Gint)
+   is
+      procedure Internal (Combo : System.Address; Column : Gint);
+      pragma Import (C, Internal, "ada_gtk_extra_color_combo_set_column");
+   begin
+      Internal (Get_Object (Combo), Column);
+   end Set_Column;
+
+   -------------------
+   -- Get_Selection --
+   -------------------
+
+   function Get_Selection (Color_Combo : access Gtk_Color_Combo_Record)
+      return Gdk.Color.Gdk_Color
+   is
+      function Internal (Combo : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_color_combo_get_selection");
+
+      C : constant Color_Access :=
+        Convert (Internal (Get_Object (Color_Combo)));
+   begin
+      return C.all;
+   end Get_Selection;
+
+end Gtk.Extra.Color_Combo;
============================================================
--- src/gtk-extra-color_combo.ads	4fec363c7a97c4a2e9f2a3729205939b49754eb2
+++ src/gtk-extra-color_combo.ads	4fec363c7a97c4a2e9f2a3729205939b49754eb2
@@ -0,0 +1,146 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Color_Combo is a widget that ease the selection of colors
+--  by the user. It is a special form of a Gtk_Combo_Box, that displays
+--  a special popup window, with a list of colors.
+--
+--  Note that nothing appears in the button, this your responsibility to
+--  update it when the user selects a new color (see the "changed" signal).
+--
+--  The recommended solution is to put a Gtk_Pixmap as the
+--  child of the button of the combo box ("Add (Get_Button (Combo), Pixmap)"),
+--  and updated it in the handler for this signal.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Selectors</group>
+
+with Gdk.Color;
+with Gtk.Extra.Combo_Button;
+
+package Gtk.Extra.Color_Combo is
+
+   type Gtk_Color_Combo_Record is
+     new Gtk.Extra.Combo_Button.Gtk_Combo_Button_Record with private;
+   type Gtk_Color_Combo is access all Gtk_Color_Combo_Record'Class;
+
+   procedure Gtk_New (Widget : out Gtk_Color_Combo);
+   --  Create a new default combo box.
+   --  It shows a list of 40 default colors.
+
+   procedure Initialize (Widget : access Gtk_Color_Combo_Record'Class);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   procedure Gtk_New
+     (Widget : out Gtk_Color_Combo;
+      Nrows  : Gint;
+      Ncols  : Gint;
+      Values : Gdk.Color.Gdk_Color_Array);
+   --  Create a new combo box with a specific list of colors.
+   --  Note that Color_Names must contain at least Nrows * Ncols elements.
+
+   procedure Initialize
+     (Widget : access Gtk_Color_Combo_Record;
+      Nrows  : Gint;
+      Ncols  : Gint;
+      Values : Gdk.Color.Gdk_Color_Array);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Color_Combo.
+
+   function Get_Color_At
+     (Widget : access Gtk_Color_Combo_Record;
+      Row    : Gint;
+      Col    : Gint) return Gdk.Color.Gdk_Color;
+   --  Return the name of the color at specific coordinates.
+
+   procedure Find_Color
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Color       : Gdk.Color.Gdk_Color;
+      Row         : out Gint;
+      Col         : out Gint);
+   --  Return the coordinates in which a color appear in the popup window.
+   --  (-1, -1) is returned if the color was not found in the combo box.
+
+   function Get_Selection (Color_Combo : access Gtk_Color_Combo_Record)
+      return Gdk.Color.Gdk_Color;
+   --  Return the current selection in the combo.
+
+   function Set_Color
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Name        : String)
+     return Boolean;
+   --  Set the new current color. If the color is not found in the list of
+   --  colors provided in the popup window, False is returned.
+
+   function Set_Color
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Color       : Gdk.Color.Gdk_Color)
+     return Boolean;
+   --  Set the new current color. Color must have been allocated first.  If the
+   --  color is not found in the list of colors provided in the popup window,
+   --  False is returned.
+
+   function Get_Ncols (Color_Combo : access Gtk_Color_Combo_Record)
+      return Gint;
+   --  Return the number of columns in the popup window
+
+   function Get_Nrows (Color_Combo : access Gtk_Color_Combo_Record)
+      return Gint;
+   --  Return the number of rows in the popup window
+
+   procedure Changed
+     (Color_Combo : access Gtk_Color_Combo_Record;
+      Row : Gint;
+      Col : Gint);
+   --  Emit the changed signal for the widget, as if the color at coordinates
+   --  (Row, Col) had been selected.
+   --  Note that this doesn't change the internal state of the widget (use
+   --  Set_Color for that).
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --
+   --  - "changed"
+   --  procedure Handler (Color_Combo : access Gtk_Color_Combo_Record'Class;
+   --                     Selection   : Gint;
+   --                     Color       : access Gdk.Color.Gdk_Color);
+   --
+   --  Emitted when the color has selected a new color.
+   --  Selection is the number of the selection (this is the total
+   --  row * Ncols + col). Color_Name is the name of the selected color.
+   --  </signals>
+
+private
+   type Gtk_Color_Combo_Record is
+     new Gtk.Extra.Combo_Button.Gtk_Combo_Button_Record with null record;
+   pragma Import (C, Get_Type, "gtk_color_combo_get_type");
+end Gtk.Extra.Color_Combo;
============================================================
--- src/gtk-extra-combo_button.adb	f570878260a4aa912e37ddef4787f2dc5cf47bce
+++ src/gtk-extra-combo_button.adb	f570878260a4aa912e37ddef4787f2dc5cf47bce
@@ -0,0 +1,115 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Combo_Button is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Combo_Button_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Widget : out Gtk_Combo_Button)
+   is
+   begin
+      Widget := new Gtk_Combo_Button_Record;
+      Gtk.Extra.Combo_Button.Initialize (Widget);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Widget : access Gtk_Combo_Button_Record'Class)
+   is
+      function Internal return System.Address;
+      pragma Import (C, Internal, "gtk_combo_button_new");
+   begin
+      Set_Object (Widget, Internal);
+   end Initialize;
+
+   -------------------------
+   -- Hide_Popdown_Window --
+   -------------------------
+
+   procedure Hide_Popdown_Window (Combo : access Gtk_Combo_Button_Record)
+   is
+      procedure Internal (Combo : in System.Address);
+      pragma Import (C, Internal, "gtk_combo_button_hide_popdown_window");
+   begin
+      Internal (Get_Object (Combo));
+   end Hide_Popdown_Window;
+
+   ----------------
+   -- Get_Button --
+   ----------------
+
+   function Get_Button (Combo : access Gtk_Combo_Button_Record)
+                       return Gtk.Button.Gtk_Button
+   is
+      function Internal (Combo : System.Address) return System.Address;
+      pragma Import (C, Internal, "ada_gtk_combo_button_get_button");
+      Stub : Gtk.Button.Gtk_Button_Record;
+   begin
+      return Gtk.Button.Gtk_Button
+        (Get_User_Data (Internal (Get_Object (Combo)), Stub));
+   end Get_Button;
+
+   -----------------------
+   -- Get_Toggle_Button --
+   -----------------------
+
+   function Get_Toggle_Button
+     (Combo : access Gtk_Combo_Button_Record)
+      return Gtk.Toggle_Button.Gtk_Toggle_Button
+   is
+      function Internal (Combo : System.Address) return System.Address;
+      pragma Import (C, Internal, "ada_gtk_combo_button_get_arrow");
+      Stub : Gtk.Toggle_Button.Gtk_Toggle_Button_Record;
+   begin
+      return Gtk.Toggle_Button.Gtk_Toggle_Button
+        (Get_User_Data (Internal (Get_Object (Combo)), Stub));
+   end Get_Toggle_Button;
+
+   ---------------
+   -- Get_Frame --
+   ---------------
+
+   function Get_Frame (Combo : access Gtk_Combo_Button_Record)
+                      return Gtk.Frame.Gtk_Frame
+   is
+      function Internal (Combo : System.Address) return System.Address;
+      pragma Import (C, Internal, "ada_gtk_combo_button_get_frame");
+      Stub : Gtk.Frame.Gtk_Frame_Record;
+   begin
+      return Gtk.Frame.Gtk_Frame
+        (Get_User_Data (Internal (Get_Object (Combo)), Stub));
+   end Get_Frame;
+
+end Gtk.Extra.Combo_Button;
============================================================
--- src/gtk-extra-combo_button.ads	d340f0ade2f4e369b4e77ae5a323fbcb8b534046
+++ src/gtk-extra-combo_button.ads	d340f0ade2f4e369b4e77ae5a323fbcb8b534046
@@ -0,0 +1,87 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2008, AdaCore                   --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Combo_Button is a general form for a combo box (ie a button
+--  associated with a popup window to select its value).
+--  This widget should be used only if you intend to write your own kind
+--  of combo box. You should look at the following widgets for specific
+--  implementation: Gtk_Combo, Gtk_Color_Combo, Gtk_Border_Combo.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Menus and Toolbars</group>
+
+with Gtk.Box;
+with Gtk.Button;
+with Gtk.Toggle_Button;
+with Gtk.Frame;
+
+package Gtk.Extra.Combo_Button is
+
+   type Gtk_Combo_Button_Record is new Gtk.Box.Gtk_Box_Record with private;
+   type Gtk_Combo_Button is access all Gtk_Combo_Button_Record'Class;
+
+   procedure Gtk_New (Widget : out Gtk_Combo_Button);
+   --  Create a new combo box.
+   --  This creates all the internal subwidgets (the popup window,...) but
+   --  this is your responsibility to put something inside the button or
+   --  the popup window.
+
+   procedure Initialize (Widget : access Gtk_Combo_Button_Record'Class);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Combo_Box.
+
+   procedure Hide_Popdown_Window (Combo : access Gtk_Combo_Button_Record);
+   --  Hide the popup window, release the mouse grabs, and restore the
+   --  default aspect for the arrow.
+
+   function Get_Button
+     (Combo : access Gtk_Combo_Button_Record) return Gtk.Button.Gtk_Button;
+   --  Return the button that shows the value of the combo.
+
+   function Get_Toggle_Button
+     (Combo : access Gtk_Combo_Button_Record)
+      return Gtk.Toggle_Button.Gtk_Toggle_Button;
+   --  Return the arrow button.
+   --  The user has to click on it to open the popup window.
+
+   function Get_Frame
+     (Combo : access Gtk_Combo_Button_Record) return Gtk.Frame.Gtk_Frame;
+   --  The frame displayed in the popup window.
+   --  You should add whatever value the popup window should display in it.
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --  </signals>
+
+private
+   type Gtk_Combo_Button_Record is new Gtk.Box.Gtk_Box_Record with null record;
+   pragma Import (C, Get_Type, "gtk_combo_button_get_type");
+end Gtk.Extra.Combo_Button;
============================================================
--- src/gtk-extra-font_combo.adb	b304e28cfadabfe367bb4714a8ec5c60ba185cca
+++ src/gtk-extra-font_combo.adb	b304e28cfadabfe367bb4714a8ec5c60ba185cca
@@ -0,0 +1,161 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+with Pango.Font; use Pango.Font;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Font_Combo is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Font_Combo_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -----------------------
+   -- Font_Combo_Select --
+   -----------------------
+
+   procedure Font_Combo_Select
+     (Font_Combo : access Gtk_Font_Combo_Record;
+      Family     : String;
+      Bold       : Boolean;
+      Italic     : Boolean;
+      Height     : Gint)
+   is
+      procedure Internal
+        (Font_Combo : System.Address;
+         Family     : String;
+         Bold       : Gint;
+         Italic     : Gint;
+         Height     : Gint);
+      pragma Import (C, Internal, "gtk_font_combo_select");
+
+   begin
+      Internal
+        (Get_Object (Font_Combo),
+         Family & ASCII.NUL,
+         Boolean'Pos (Bold),
+         Boolean'Pos (Italic),
+         Height);
+   end Font_Combo_Select;
+
+   ---------------------------
+   -- Font_Combo_Select_Nth --
+   ---------------------------
+
+   procedure Font_Combo_Select_Nth
+     (Font_Combo : access Gtk_Font_Combo_Record;
+      N          : Gint;
+      Bold       : Boolean;
+      Italic     : Boolean;
+      Height     : Gint)
+   is
+      procedure Internal
+        (Font_Combo : System.Address;
+         N          : Gint;
+         Bold       : Gint;
+         Italic     : Gint;
+         Height     : Gint);
+      pragma Import (C, Internal, "gtk_font_combo_select_nth");
+
+   begin
+      Internal
+        (Get_Object (Font_Combo),
+         N,
+         Boolean'Pos (Bold),
+         Boolean'Pos (Italic),
+         Height);
+   end Font_Combo_Select_Nth;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Widget : out Gtk_Font_Combo) is
+   begin
+      Widget := new Gtk_Font_Combo_Record;
+      Gtk.Extra.Font_Combo.Initialize (Widget);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Widget : access Gtk_Font_Combo_Record'Class) is
+      function Internal return System.Address;
+      pragma Import (C, Internal, "gtk_font_combo_new");
+
+      procedure Psfont_Init;
+      pragma Import (C, Psfont_Init, "gtk_psfont_init");
+
+   begin
+      --  gtk_psfont needs to be initialized. Since we no longer provide
+      --  a binding for it (it is replaced by pango), this needs to be done
+      --  automatically. Subsequent calls to Psfont_Init are ignored.
+
+      Psfont_Init;
+      Set_Object (Widget, Internal);
+   end Initialize;
+
+   -----------------
+   -- Get_GdkFont --
+   -----------------
+
+   function Get_GdkFont
+     (Font_Combo : access Gtk_Font_Combo_Record) return Gdk.Font.Gdk_Font
+   is
+      function Internal (Font_Combo : System.Address) return Gdk.Font.Gdk_Font;
+      pragma Import (C, Internal, "gtk_font_combo_get_gdkfont");
+   begin
+      return Internal (Get_Object (Font_Combo));
+   end Get_GdkFont;
+
+   ---------------------
+   -- Get_Font_Height --
+   ---------------------
+
+   function Get_Font_Height
+     (Font_Combo : access Gtk_Font_Combo_Record)  return Glib.Gint
+   is
+      function Internal (Combo : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_font_combo_get_font_height");
+   begin
+      return Internal (Get_Object (Font_Combo));
+   end Get_Font_Height;
+
+   --------------------------
+   -- Get_Font_Description --
+   --------------------------
+
+   function Get_Font_Description
+     (Font_Combo : access Gtk_Font_Combo_Record)
+      return Pango.Font.Pango_Font_Description
+   is
+      function Internal (Combo : System.Address) return Pango_Font_Description;
+      pragma Import (C, Internal, "gtk_font_combo_get_font_description");
+   begin
+      return Internal (Get_Object (Font_Combo));
+   end Get_Font_Description;
+
+end Gtk.Extra.Font_Combo;
============================================================
--- src/gtk-extra-font_combo.ads	bc1cae5678b29481a3fe064e83619c9672f96d30
+++ src/gtk-extra-font_combo.ads	bc1cae5678b29481a3fe064e83619c9672f96d30
@@ -0,0 +1,105 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Font_Combo is a small toolbar used to select fonts.
+--  This widget takes less real-estate on the screen than a
+--  Gtk_Font_Selection widget, and thus can be kept permanently on the
+--  screen.
+--  This widget only works with postscript fonts (see Gtk.Extra.PsFont).
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>GtkExtra, additional widgets</group>
+
+with Glib;
+with Gtk.Toolbar;
+with Gdk.Font;
+with Pango.Font;
+
+package Gtk.Extra.Font_Combo is
+
+   type Gtk_Font_Combo_Record is new Gtk.Toolbar.Gtk_Toolbar_Record
+     with private;
+   type Gtk_Font_Combo is access all Gtk_Font_Combo_Record'Class;
+
+   procedure Gtk_New (Widget : out Gtk_Font_Combo);
+   --  Create a new combo box
+
+   procedure Initialize (Widget : access Gtk_Font_Combo_Record'Class);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Glib.GType;
+   --  Return the internal value associated with a Gtk_Font_Combo.
+
+   procedure Font_Combo_Select
+     (Font_Combo : access Gtk_Font_Combo_Record;
+      Family     : String;
+      Bold       : Boolean;
+      Italic     : Boolean;
+      Height     : Gint);
+   --  Selects a new font
+   --  Family is the name of the postscript font.
+
+   procedure Font_Combo_Select_Nth
+     (Font_Combo : access Gtk_Font_Combo_Record;
+      N          : Gint;
+      Bold       : Boolean;
+      Italic     : Boolean;
+      Height     : Gint);
+   --  Selects the nth font in the combo box.
+
+   function Get_Font_Height
+     (Font_Combo : access Gtk_Font_Combo_Record) return Glib.Gint;
+   --  Return the height of the selected font
+
+   function Get_GdkFont
+     (Font_Combo : access Gtk_Font_Combo_Record) return Gdk.Font.Gdk_Font;
+   --  Return the selected font.
+
+   function Get_Font_Description
+     (Font_Combo : access Gtk_Font_Combo_Record)
+     return Pango.Font.Pango_Font_Description;
+   --  Return the selected font.
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --
+   --  - "changed"
+   --  procedure Handler (Combo : access Gtk_Font_Combo_Record'Class);
+   --
+   --  Emitted when a new font was selected by the user.
+   --  </signals>
+
+private
+   type Gtk_Font_Combo_Record is new Gtk.Toolbar.Gtk_Toolbar_Record
+     with null record;
+   pragma Import (C, Get_Type, "gtk_font_combo_get_type");
+
+   --  Unbound:
+   --     gtk_font_combo_get_psfont
+end Gtk.Extra.Font_Combo;
============================================================
--- src/gtk-extra-item_entry.adb	6de4ad11a43854aef065a3d7eeb82aed57f6ad8b
+++ src/gtk-extra-item_entry.adb	6de4ad11a43854aef065a3d7eeb82aed57f6ad8b
@@ -0,0 +1,128 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--     Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet      --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gtk.Enums; use Gtk.Enums;
+with System;
+with Glib.Type_Conversion_Hooks;
+pragma Elaborate_All (Glib.Type_Conversion_Hooks);
+
+package body Gtk.Extra.Item_Entry is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Item_Entry_Record);
+   pragma Warnings (Off, Type_Conversion);
+   --  This package is used to implement a minimal automated type conversion
+   --  without having to drag the whole Gtk.Type_Conversion package for the
+   --  most common widgets.
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Widget : out Gtk_IEntry;
+                      Max    : Guint16 := 0)
+   is
+   begin
+      Widget := new Gtk_IEntry_Record;
+      Initialize (Widget, Max);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Widget : access Gtk_IEntry_Record'Class;
+                         Max    : Guint16)
+   is
+      function Internal (Max    : Guint16)
+                         return      System.Address;
+      pragma Import (C, Internal, "gtk_item_entry_new_with_max_length");
+   begin
+      Set_Object (Widget, Internal (Max));
+   end Initialize;
+
+   -----------------------
+   -- Set_Justification --
+   -----------------------
+
+   procedure Set_Justification
+      (Item_Entry    : access Gtk_IEntry_Record;
+       Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Item_Entry    : System.Address;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_item_entry_set_justification");
+
+   begin
+      Internal (Get_Object (Item_Entry), Justification);
+   end Set_Justification;
+
+   --------------
+   -- Set_Text --
+   --------------
+
+   procedure Set_Text
+      (Item_Entry    : access Gtk_IEntry_Record;
+       Text          : String;
+       Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Item_Entry    : System.Address;
+         Text          : String;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_item_entry_set_text");
+
+   begin
+      Internal (Get_Object (Item_Entry),
+                Text & ASCII.NUL,
+                Justification);
+   end Set_Text;
+
+   ------------------------
+   -- Set_Cursor_Visible --
+   ------------------------
+
+   procedure Set_Cursor_Visible
+     (Item_Entry : access Gtk_IEntry_Record; Visible : Boolean)
+   is
+      procedure Internal (Ent : System.Address; Visible : Gboolean);
+      pragma Import (C, Internal, "gtk_item_entry_set_cursor_visible");
+   begin
+      Internal (Get_Object (Item_Entry), Boolean'Pos (Visible));
+   end Set_Cursor_Visible;
+
+   ------------------------
+   -- Get_Cursor_Visible --
+   ------------------------
+
+   function Get_Cursor_Visible
+     (Item_Entry : access Gtk_IEntry_Record) return Boolean
+   is
+      function Internal (Ent : System.Address) return Gboolean;
+      pragma Import (C, Internal, "gtk_item_entry_get_cursor_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Item_Entry)));
+   end Get_Cursor_Visible;
+
+end Gtk.Extra.Item_Entry;
============================================================
--- src/gtk-extra-item_entry.ads	db9b783cf390bb2988e528bf46f915336f9701ee
+++ src/gtk-extra-item_entry.ads	db9b783cf390bb2988e528bf46f915336f9701ee
@@ -0,0 +1,88 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Item_Entry is a special kind of entry item used in a
+--  Gtk_Sheet to edit the current cell.
+--  It can be used independently, but you should rather use a more general
+--  Gtk_Entry widget.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>GtkExtra, additional widgets</group>
+
+with Gtk.Enums;
+with Gtk.GEntry;
+
+package Gtk.Extra.Item_Entry is
+
+   type Gtk_IEntry_Record is new Gtk.GEntry.Gtk_Entry_Record with private;
+   type Gtk_IEntry is access all Gtk_IEntry_Record'Class;
+
+   subtype Gtk_Item_Entry_Record is Gtk_IEntry_Record;
+   subtype Gtk_Item_Entry is Gtk_IEntry;
+   --  This type is provided so as to be compatible with the new name used
+   --  in gtk+extra. Both names are kept for backward compatibility.
+
+   procedure Gtk_New (Widget : out Gtk_IEntry;
+                      Max    : in Guint16 := 0);
+   --  Create a new entry item.
+   --  By default, the maximal length depends only on the size of the widget.
+
+   procedure Initialize (Widget : access Gtk_IEntry_Record'Class;
+                         Max    : in Guint16);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Item_Entry.
+
+   procedure Set_Justification
+     (Item_Entry    : access Gtk_IEntry_Record;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Change the justification of the text in the entry.
+
+   procedure Set_Text
+     (Item_Entry    : access Gtk_IEntry_Record;
+      Text          : String;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Change the text in the entry.
+
+   procedure Set_Cursor_Visible
+     (Item_Entry : access Gtk_IEntry_Record; Visible : Boolean);
+   --  Whether the cursor should be visible
+
+   function Get_Cursor_Visible
+     (Item_Entry : access Gtk_IEntry_Record) return Boolean;
+   --  Whether the cursor is visible
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --  </signals>
+private
+   type Gtk_IEntry_Record is new Gtk.GEntry.Gtk_Entry_Record with null record;
+   pragma Import (C, Get_Type, "gtk_item_entry_get_type");
+end Gtk.Extra.Item_Entry;
============================================================
--- src/gtk-extra-plot.adb	d217f35999435fe1f99f44a5ada34bfcb1176116
+++ src/gtk-extra-plot.adb	d217f35999435fe1f99f44a5ada34bfcb1176116
@@ -0,0 +1,2119 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2001-2009, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gdk.Color;            use Gdk.Color;
+with Gdk.Rectangle;        use Gdk.Rectangle;
+with Gdk.Pixmap;           use Gdk.Pixmap;
+with Gtk.Enums;            use Gtk.Enums;
+with Interfaces.C.Strings; use Interfaces.C.Strings;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Plot     : out Gtk_Plot;
+                      Drawable : Gdk.Drawable.Gdk_Drawable
+                        :=  Gdk.Drawable.Null_Drawable)
+   is
+   begin
+      Plot := new Gtk_Plot_Record;
+      Initialize (Plot, Drawable);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Plot     : access Gtk_Plot_Record'Class;
+                         Drawable : Gdk.Drawable.Gdk_Drawable)
+   is
+      function Internal (Drawable : Gdk.Drawable.Gdk_Drawable)
+                         return        System.Address;
+      pragma Import (C, Internal, "gtk_plot_new");
+   begin
+      Set_Object (Plot, Internal (Drawable));
+   end Initialize;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Plot     : out Gtk_Plot;
+                      Width    : Gdouble;
+                      Height   : Gdouble;
+                      Drawable : Gdk.Drawable.Gdk_Drawable
+                        :=  Gdk.Drawable.Null_Drawable)
+   is
+   begin
+      Plot := new Gtk_Plot_Record;
+      Initialize (Plot, Drawable, Width, Height);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Plot     : access Gtk_Plot_Record'Class;
+                         Drawable : Gdk.Drawable.Gdk_Drawable;
+                         Width    : Gdouble;
+                         Height   : Gdouble)
+   is
+      function Internal (Drawable : Gdk.Drawable.Gdk_Drawable;
+                         Width    : Gdouble;
+                         Height   : Gdouble)
+                        return        System.Address;
+      pragma Import (C, Internal, "gtk_plot_new_with_size");
+   begin
+      Set_Object (Plot, Internal (Drawable, Width, Height));
+   end Initialize;
+
+   ------------------
+   -- Set_Drawable --
+   ------------------
+
+   procedure Set_Drawable (Plot     : access Gtk_Plot_Record;
+                           Drawable : Gdk.Drawable.Gdk_Drawable)
+   is
+      procedure Internal (Plot     : System.Address;
+                          Drawable : Gdk.Drawable.Gdk_Drawable);
+      pragma Import (C, Internal, "gtk_plot_set_drawable");
+   begin
+      Internal (Get_Object (Plot), Drawable);
+   end Set_Drawable;
+
+   ------------------
+   -- Get_Drawable --
+   ------------------
+
+   function Get_Drawable (Plot   : access Gtk_Plot_Record)
+                          return      Gdk.Drawable.Gdk_Drawable
+   is
+      function Internal (Plot : System.Address)
+                        return Gdk.Drawable.Gdk_Drawable;
+      pragma Import (C, Internal, "gtk_plot_get_drawable");
+   begin
+      return Internal (Get_Object (Plot));
+   end Get_Drawable;
+
+   ------------------
+   -- Get_Position --
+   ------------------
+
+   procedure Get_Position (Plot : access Gtk_Plot_Record;
+                           X    : out Gdouble;
+                           Y    : out Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          X    : out Gdouble;
+                          Y    : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_get_position");
+   begin
+      Internal (Get_Object (Plot), X, Y);
+   end Get_Position;
+
+   --------------
+   -- Get_Size --
+   --------------
+
+   procedure Get_Size (Plot   : access Gtk_Plot_Record;
+                       Width  : out Gdouble;
+                       Height : out Gdouble)
+   is
+      procedure Internal (Plot   : System.Address;
+                          Width  : out Gdouble;
+                          Height : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_get_size");
+   begin
+      Internal (Get_Object (Plot), Width, Height);
+   end Get_Size;
+
+   -----------------------------
+   -- Get_Internal_Allocation --
+   -----------------------------
+
+   function Get_Internal_Allocation (Plot   : access Gtk_Plot_Record)
+                                     return      Gtk.Widget.Gtk_Allocation
+   is
+      function Internal (Plot   : System.Address)
+                         return      Gtk.Widget.Gtk_Allocation;
+      pragma Import (C, Internal, "gtk_plot_get_internal_allocation");
+   begin
+      return Internal (Get_Object (Plot));
+   end Get_Internal_Allocation;
+
+   --------------------
+   -- Set_Background --
+   --------------------
+
+   procedure Set_Background (Plot       : access Gtk_Plot_Record;
+                             Background : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Plot       : System.Address;
+                          Background : System.Address);
+      pragma Import (C, Internal, "gtk_plot_set_background");
+
+      Back : aliased Gdk.Color.Gdk_Color := Background;
+      Backa : System.Address := Back'Address;
+   begin
+      if Background = Gdk.Color.Null_Color then
+         Backa := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Backa);
+   end Set_Background;
+
+   -----------
+   -- Paint --
+   -----------
+
+   procedure Paint (Plot : access Gtk_Plot_Record) is
+      procedure Internal (Widget : System.Address);
+      pragma Import (C, Internal, "gtk_plot_paint");
+   begin
+      Internal (Get_Object (Plot));
+   end Paint;
+
+   -------------
+   -- Refresh --
+   -------------
+
+   procedure Refresh
+      (Plot : access Gtk_Plot_Record;
+       Area : Gdk.Rectangle.Gdk_Rectangle)
+   is
+      procedure Internal (Plot : System.Address;
+                          Area : System.Address);
+      pragma Import (C, Internal, "gtk_plot_refresh");
+
+      Rec : aliased Gdk.Rectangle.Gdk_Rectangle := Area;
+      R : System.Address := Rec'Address;
+   begin
+      if Rec = Full_Area then
+         R := System.Null_Address;
+      end if;
+      Internal (Get_Object (Plot), R);
+   end Refresh;
+
+   ----------
+   -- Move --
+   ----------
+
+   procedure Move (Plot : access Gtk_Plot_Record;
+                   X    : Gdouble;
+                   Y    : Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          X    : Gdouble;
+                          Y    : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_move");
+   begin
+      Internal (Get_Object (Plot), X, Y);
+   end Move;
+
+   ------------
+   -- Resize --
+   ------------
+
+   procedure Resize (Plot   : access Gtk_Plot_Record;
+                     Width  : Gdouble;
+                     Height : Gdouble)
+   is
+      procedure Internal (Plot   : System.Address;
+                          Width  : Gdouble;
+                          Height : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_resize");
+   begin
+      Internal (Get_Object (Plot), Width, Height);
+   end Resize;
+
+   -----------------
+   -- Move_Resize --
+   -----------------
+
+   procedure Move_Resize (Plot   : access Gtk_Plot_Record;
+                          X      : Gdouble;
+                          Y      : Gdouble;
+                          Width  : Gdouble;
+                          Height : Gdouble)
+   is
+      procedure Internal (Plot   : System.Address;
+                          X      : Gdouble;
+                          Y      : Gdouble;
+                          Width  : Gdouble;
+                          Height : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_move_resize");
+   begin
+      Internal (Get_Object (Plot), X, Y, Width, Height);
+   end Move_Resize;
+
+   ---------------
+   -- Get_Pixel --
+   ---------------
+
+   procedure Get_Pixel (Plot : access Gtk_Plot_Record;
+                        Xx   : Gdouble;
+                        Yy   : Gdouble;
+                        X    : out Gdouble;
+                        Y    : out Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          Xx   : Gdouble;
+                          Yy   : Gdouble;
+                          X    : out Gdouble;
+                          Y    : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_get_pixel");
+   begin
+      Internal (Get_Object (Plot), Xx, Yy, X, Y);
+   end Get_Pixel;
+
+   ---------------
+   -- Clip_Data --
+   ---------------
+
+   procedure Clip_Data (Plot : access Gtk_Plot_Record; Clip : Boolean) is
+      procedure Internal (Plot : System.Address; Clip : Gint);
+      pragma Import (C, Internal, "gtk_plot_clip_data");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Clip));
+   end Clip_Data;
+
+   ---------------
+   -- Get_Point --
+   ---------------
+
+   procedure Get_Point (Plot : access Gtk_Plot_Record;
+                        X    : Gint;
+                        Y    : Gint;
+                        Xx   : out Gdouble;
+                        Yy   : out Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          X    : Gint;
+                          Y    : Gint;
+                          Xx   : out Gdouble;
+                          Yy   : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_get_point");
+   begin
+      Internal (Get_Object (Plot), X, Y, Xx, Yy);
+   end Get_Point;
+
+   ----------------
+   -- Set_Xrange --
+   ----------------
+
+   procedure Set_Xrange (Plot : access Gtk_Plot_Record;
+                         Xmin : Gdouble := 0.0;
+                         Xmax : Gdouble := 1.0)
+   is
+      procedure Internal (Plot : System.Address;
+                          Xmin : Gdouble;
+                          Xmax : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_xrange");
+   begin
+      Internal (Get_Object (Plot), Xmin, Xmax);
+   end Set_Xrange;
+
+   ----------------
+   -- Set_Yrange --
+   ----------------
+
+   procedure Set_Yrange (Plot : access Gtk_Plot_Record;
+                         Ymin : Gdouble := 0.0;
+                         Ymax : Gdouble := 1.0)
+   is
+      procedure Internal (Plot : System.Address;
+                          Ymin : Gdouble;
+                          Ymax : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_yrange");
+   begin
+      Internal (Get_Object (Plot), Ymin, Ymax);
+   end Set_Yrange;
+
+   ---------------
+   -- Set_Range --
+   ---------------
+
+   procedure Set_Range (Plot : access Gtk_Plot_Record;
+                        Xmin : Gdouble := 0.0;
+                        Xmax : Gdouble := 1.0;
+                        Ymin : Gdouble := 0.0;
+                        Ymax : Gdouble := 1.0)
+   is
+      procedure Internal (Plot : System.Address;
+                          Xmin : Gdouble;
+                          Xmax : Gdouble;
+                          Ymin : Gdouble;
+                          Ymax : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_range");
+   begin
+      Internal (Get_Object (Plot), Xmin, Xmax, Ymin, Ymax);
+   end Set_Range;
+
+   ---------------
+   -- Autoscale --
+   ---------------
+
+   procedure Autoscale (Plot : access Gtk_Plot_Record) is
+      procedure Internal (Plot : System.Address);
+      pragma Import (C, Internal, "gtk_plot_autoscale");
+   begin
+      Internal (Get_Object (Plot));
+   end Autoscale;
+
+   ----------------
+   -- Get_Xrange --
+   ----------------
+
+   procedure Get_Xrange (Plot : access Gtk_Plot_Record;
+                         Xmin : out Gdouble;
+                         Xmax : out Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          Xmin : out Gdouble;
+                          Xmax : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_get_xrange");
+   begin
+      Internal (Get_Object (Plot), Xmin, Xmax);
+   end Get_Xrange;
+
+   ----------------
+   -- Get_Yrange --
+   ----------------
+
+   procedure Get_Yrange (Plot : access Gtk_Plot_Record;
+                         Ymin : out Gdouble;
+                         Ymax : out Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          Ymin : out Gdouble;
+                          Ymax : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_get_yrange");
+   begin
+      Internal (Get_Object (Plot), Ymin, Ymax);
+   end Get_Yrange;
+
+   ----------------
+   -- Set_Xscale --
+   ----------------
+
+   procedure Set_Xscale (Plot       : access Gtk_Plot_Record;
+                         Scale_Type : Plot_Scale)
+   is
+      procedure Internal
+        (Plot       : System.Address;
+         Scale_Type : Plot_Scale);
+      pragma Import (C, Internal, "gtk_plot_set_xscale");
+
+   begin
+      Internal (Get_Object (Plot), Scale_Type);
+   end Set_Xscale;
+
+   ----------------
+   -- Set_Yscale --
+   ----------------
+
+   procedure Set_Yscale (Plot       : access Gtk_Plot_Record;
+                         Scale_Type : Plot_Scale)
+   is
+      procedure Internal
+        (Plot       : System.Address;
+         Scale_Type : Plot_Scale);
+      pragma Import (C, Internal, "gtk_plot_set_yscale");
+
+   begin
+      Internal (Get_Object (Plot), Scale_Type);
+   end Set_Yscale;
+
+   ----------------
+   -- Get_Xscale --
+   ----------------
+
+   function Get_Xscale (Plot   : access Gtk_Plot_Record)
+                        return      Plot_Scale
+   is
+      function Internal (Plot   : System.Address)
+                         return      Gint;
+      pragma Import (C, Internal, "gtk_plot_get_xscale");
+   begin
+      return Plot_Scale'Val (Internal (Get_Object (Plot)));
+   end Get_Xscale;
+
+   ----------------
+   -- Get_Yscale --
+   ----------------
+
+   function Get_Yscale (Plot   : access Gtk_Plot_Record)
+                        return      Plot_Scale
+   is
+      function Internal (Plot   : System.Address)
+                         return      Gint;
+      pragma Import (C, Internal, "gtk_plot_get_yscale");
+   begin
+      return Plot_Scale'Val (Internal (Get_Object (Plot)));
+   end Get_Yscale;
+
+   --------------
+   -- Put_Text --
+   --------------
+
+   function Put_Text
+      (Plot          : access Gtk_Plot_Record;
+       X             : Gdouble;
+       Y             : Gdouble;
+       Font          : String := "";
+       Font_Height   : Gint := 10;
+       Angle         : Plot_Angle;
+       Foreground    : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+       Background    : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+       Transparent   : Boolean := False;
+       Justification : Gtk.Enums.Gtk_Justification := Gtk.Enums.Justify_Center;
+       Text          : String := "") return Gtk_Plot_Text
+   is
+      function Internal
+        (Plot          : System.Address;
+         X             : Gdouble;
+         Y             : Gdouble;
+         Font          : System.Address;
+         Height        : Gint;
+         Angle         : Plot_Angle;
+         Foreground    : System.Address;
+         Background    : System.Address;
+         Transparent   : Gint;
+         Justification : Gtk.Enums.Gtk_Justification;
+         Text          : String) return Gtk_Plot_Text;
+      pragma Import (C, Internal, "gtk_plot_put_text");
+
+      Back  : aliased Gdk.Color.Gdk_Color := Background;
+      Fore  : aliased Gdk.Color.Gdk_Color := Foreground;
+      Backa : System.Address := Back'Address;
+      Forea : System.Address := Fore'Address;
+      F     : aliased String := Font & ASCII.NUL;
+
+   begin
+      if Foreground = Gdk.Color.Null_Color then
+         Forea := System.Null_Address;
+      end if;
+
+      if Background = Gdk.Color.Null_Color then
+         Backa := System.Null_Address;
+      end if;
+
+      if Font = "" then
+         return Internal
+           (Get_Object (Plot), X, Y,
+            System.Null_Address, Font_Height,
+            Angle, Forea, Backa,
+            Boolean'Pos (Transparent),
+            Justification,
+            Text & ASCII.NUL);
+      else
+         return Internal
+           (Get_Object (Plot), X, Y,
+            F'Address, Font_Height,
+            Angle, Forea, Backa,
+            Boolean'Pos (Transparent),
+            Justification,
+            Text & ASCII.NUL);
+      end if;
+   end Put_Text;
+
+   ----------------------
+   -- Axis_Set_Visible --
+   ----------------------
+
+   procedure Axis_Set_Visible
+     (Axis    : access Gtk_Plot_Axis_Record;
+      Visible : Boolean)
+   is
+      procedure Internal
+        (Axis    : System.Address;
+         Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_set_visible");
+
+   begin
+      Internal (Get_Object (Axis), Boolean'Pos (Visible));
+   end Axis_Set_Visible;
+
+   ------------------
+   -- Axis_Visible --
+   ------------------
+
+   function Axis_Visible
+     (Axis   : access Gtk_Plot_Axis_Record) return Boolean
+   is
+      function Internal
+        (Axis : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_axis_visible");
+
+   begin
+      return Boolean'Val (Internal (Get_Object (Axis)));
+   end Axis_Visible;
+
+   --------------------
+   -- Axis_Set_Title --
+   --------------------
+
+   procedure Axis_Set_Title
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Title : String)
+   is
+      procedure Internal
+        (Axis  : System.Address;
+         Title : String);
+      pragma Import (C, Internal, "gtk_plot_axis_set_title");
+
+   begin
+      Internal (Get_Object (Axis), Title & ASCII.NUL);
+   end Axis_Set_Title;
+
+   ---------------------
+   -- Axis_Show_Title --
+   ---------------------
+
+   procedure Axis_Show_Title (Axis : access Gtk_Plot_Axis_Record) is
+      procedure Internal (Axis : System.Address);
+      pragma Import (C, Internal, "gtk_plot_axis_show_title");
+
+   begin
+      Internal (Get_Object (Axis));
+   end Axis_Show_Title;
+
+   ---------------------
+   -- Axis_Hide_Title --
+   ---------------------
+
+   procedure Axis_Hide_Title (Axis : access Gtk_Plot_Axis_Record) is
+      procedure Internal (Axis : System.Address);
+      pragma Import (C, Internal, "gtk_plot_axis_hide_title");
+   begin
+      Internal (Get_Object (Axis));
+   end Axis_Hide_Title;
+
+   ---------------------
+   -- Axis_Move_Title --
+   ---------------------
+
+   procedure Axis_Move_Title
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Angle : Plot_Angle;
+      X     : Gdouble;
+      Y     : Gdouble)
+   is
+      procedure Internal
+        (Axis  : System.Address;
+         Angle : Plot_Angle;
+         X     : Gdouble;
+         Y     : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_axis_move_title");
+
+   begin
+      Internal (Get_Object (Axis), Angle, X, Y);
+   end Axis_Move_Title;
+
+   ------------------------
+   -- Axis_Justify_Title --
+   ------------------------
+
+   procedure Axis_Justify_Title
+     (Axis          : access Gtk_Plot_Axis_Record;
+      Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Axis          : System.Address;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_plot_axis_justify_title");
+
+   begin
+      Internal (Get_Object (Axis), Justification);
+   end Axis_Justify_Title;
+
+   -------------------------
+   -- Axis_Set_Attributes --
+   -------------------------
+
+   procedure Axis_Set_Attributes
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Axis  : System.Address;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_axis_set_attributes");
+
+      C  : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Axis), Width, Ca);
+   end Axis_Set_Attributes;
+
+   -------------------------
+   -- Axis_Get_Attributes --
+   -------------------------
+
+   procedure Axis_Get_Attributes
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Width : out    Gfloat;
+      Color : out    Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Axis  : System.Address;
+         Width : out Gfloat;
+         Color : out Gdk.Color.Gdk_Color);
+      pragma Import (C, Internal, "gtk_plot_axis_get_attributes");
+
+   begin
+      Internal (Get_Object (Axis), Width, Color);
+   end Axis_Get_Attributes;
+
+   --------------------
+   -- Axis_Set_Ticks --
+   --------------------
+
+   procedure Axis_Set_Ticks
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Major_Step  : Gdouble;
+      Num_Minor   : Gint)
+   is
+      procedure Internal
+        (Axis        : System.Address;
+         Major_Step  : Gdouble;
+         Num_Minor   : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_set_ticks");
+
+   begin
+      Internal (Get_Object (Axis), Major_Step, Num_Minor);
+   end Axis_Set_Ticks;
+
+   --------------------------
+   -- Axis_Set_Major_Ticks --
+   --------------------------
+
+   procedure Axis_Set_Major_Ticks
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Major_Step  : Gdouble)
+   is
+      procedure Internal
+        (Axis        : System.Address;
+         Major_Step  : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_axis_set_major_ticks");
+
+   begin
+      Internal (Get_Object (Axis), Major_Step);
+   end Axis_Set_Major_Ticks;
+
+   --------------------------
+   -- Axis_Set_Minor_Ticks --
+   --------------------------
+
+   procedure Axis_Set_Minor_Ticks
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Num_Minor   : Gint)
+   is
+      procedure Internal
+        (Axis        : System.Address;
+         Num_Minor   : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_set_minor_ticks");
+
+   begin
+      Internal (Get_Object (Axis), Num_Minor);
+   end Axis_Set_Minor_Ticks;
+
+   ---------------------------
+   -- Axis_Set_Ticks_Length --
+   ---------------------------
+
+   procedure Axis_Set_Ticks_Length
+     (Axis   : access Gtk_Plot_Axis_Record;
+      Length : Gint)
+   is
+      procedure Internal
+        (Axis   : System.Address;
+         Length : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_set_ticks_length");
+
+   begin
+      Internal (Get_Object (Axis), Length);
+   end Axis_Set_Ticks_Length;
+
+   --------------------------
+   -- Axis_Set_Ticks_Width --
+   --------------------------
+
+   procedure Axis_Set_Ticks_Width
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Width : Gfloat)
+   is
+      procedure Internal
+        (Axis  : System.Address;
+         Width : Gfloat);
+      pragma Import (C, Internal, "gtk_plot_axis_set_ticks_width");
+
+   begin
+      Internal (Get_Object (Axis), Width);
+   end Axis_Set_Ticks_Width;
+
+   ---------------------
+   -- Axis_Show_Ticks --
+   ---------------------
+
+   procedure Axis_Show_Ticks
+     (Axis       : access Gtk_Plot_Axis_Record;
+      Major_Mask : Plot_Ticks_Pos;
+      Minor_Mask : Plot_Ticks_Pos)
+   is
+      procedure Internal
+         (Axis       : System.Address;
+          Major_Mask : Plot_Ticks_Pos;
+          Minor_Mask : Plot_Ticks_Pos);
+      pragma Import (C, Internal, "gtk_plot_axis_show_ticks");
+
+   begin
+      Internal (Get_Object (Axis), Major_Mask, Minor_Mask);
+   end Axis_Show_Ticks;
+
+   ---------------------------
+   -- Axis_Set_Ticks_Limits --
+   ---------------------------
+
+   procedure Axis_Set_Ticks_Limits
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Ticks_Begin : Gdouble;
+      Ticks_End   : Gdouble)
+   is
+      procedure Internal
+        (Axis        : System.Address;
+         Beg         : Gdouble;
+         The_End     : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_axis_set_ticks_limits");
+
+   begin
+      Internal (Get_Object (Axis), Ticks_Begin, Ticks_End);
+   end Axis_Set_Ticks_Limits;
+
+   -----------------------------
+   -- Axis_Unset_Ticks_Limits --
+   -----------------------------
+
+   procedure Axis_Unset_Ticks_Limits
+     (Axis        : access Gtk_Plot_Axis_Record)
+   is
+      procedure Internal (Axis : System.Address);
+      pragma Import (C, Internal, "gtk_plot_axis_unset_ticks_limits");
+
+   begin
+      Internal (Get_Object (Axis));
+   end Axis_Unset_Ticks_Limits;
+
+   ----------------------
+   -- Axis_Show_Labels --
+   ----------------------
+
+   procedure Axis_Show_Labels
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Labels_Mask : Plot_Label_Pos)
+   is
+      procedure Internal
+        (Axis        : System.Address;
+         Labels_Mask : Plot_Label_Pos);
+      pragma Import (C, Internal, "gtk_plot_axis_show_labels");
+
+   begin
+      Internal (Get_Object (Axis), Labels_Mask);
+   end Axis_Show_Labels;
+
+   -------------------------------
+   -- Axis_Title_Set_Attributes --
+   -------------------------------
+
+   procedure Axis_Title_Set_Attributes
+     (Axis       : access Gtk_Plot_Axis_Record;
+      Font       : String;
+      Height     : Gint;
+      Angle      : Plot_Angle;
+      Foreground : Gdk.Color.Gdk_Color;
+      Background : Gdk.Color.Gdk_Color;
+      Transparent   : Boolean;
+      Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Axis          : System.Address;
+         Font          : String;
+         Height        : Gint;
+         Angle         : Plot_Angle;
+         Foreground    : System.Address;
+         Background    : System.Address;
+         Transparent   : Gint;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_plot_axis_title_set_attributes");
+
+      Fore : aliased Gdk.Color.Gdk_Color := Foreground;
+      Fa   : System.Address := Fore'Address;
+      Back : aliased Gdk.Color.Gdk_Color := Background;
+      Ba   : System.Address := Back'Address;
+   begin
+      if Fore = Gdk.Color.Null_Color then
+         Fa := System.Null_Address;
+      end if;
+
+      if Back = Gdk.Color.Null_Color then
+         Ba := System.Null_Address;
+      end if;
+
+      Internal
+        (Get_Object (Axis), Font & ASCII.NUL,
+         Height, Angle, Fa, Ba,
+         Boolean'Pos (Transparent), Justification);
+   end Axis_Title_Set_Attributes;
+
+   --------------------------------
+   -- Axis_Set_Labels_Attributes --
+   --------------------------------
+
+   procedure Axis_Set_Labels_Attributes
+     (Axis          : access Gtk_Plot_Axis_Record;
+      Font          : String;
+      Height        : Gint;
+      Angle         : Plot_Angle;
+      Foreground    : Gdk.Color.Gdk_Color;
+      Background    : Gdk.Color.Gdk_Color;
+      Transparent   : Boolean;
+      Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Axis          : System.Address;
+         Font          : String;
+         Height        : Gint;
+         Angle         : Plot_Angle;
+         Foreground    : System.Address;
+         Background    : System.Address;
+         Transparent   : Gint;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_plot_axis_set_labels_attributes");
+
+      Fore : aliased Gdk.Color.Gdk_Color := Foreground;
+      Fa   : System.Address := Fore'Address;
+      Back : aliased Gdk.Color.Gdk_Color := Background;
+      Ba   : System.Address := Back'Address;
+   begin
+      if Fore = Gdk.Color.Null_Color then
+         Fa := System.Null_Address;
+      end if;
+
+      if Back = Gdk.Color.Null_Color then
+         Ba := System.Null_Address;
+      end if;
+
+      Internal
+        (Get_Object (Axis), Font & ASCII.NUL,
+         Height, Angle, Fa, Ba, Boolean'Pos (Transparent), Justification);
+   end Axis_Set_Labels_Attributes;
+
+   ---------------------------------
+   -- Axis_Use_Custom_Tick_Labels --
+   ---------------------------------
+
+   procedure Axis_Use_Custom_Tick_Labels
+     (Axis   : access Gtk_Plot_Axis_Record;
+      Custom : Boolean := True)
+   is
+      procedure Internal
+        (Axis   : System.Address;
+         Custom : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_use_custom_tick_labels");
+
+   begin
+      Internal (Get_Object (Axis), Boolean'Pos (Custom));
+   end Axis_Use_Custom_Tick_Labels;
+
+   ----------------
+   -- X0_Visible --
+   ----------------
+
+   function X0_Visible (Plot   : access Gtk_Plot_Record)
+                       return Boolean
+   is
+      function Internal (Plot   : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_x0_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end X0_Visible;
+
+   --------------------
+   -- X0_Set_Visible --
+   --------------------
+
+   procedure X0_Set_Visible (Plot    : access Gtk_Plot_Record;
+                             Visible : Boolean)
+   is
+      procedure Internal
+         (Plot    : System.Address;
+          Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_x0_set_visible");
+
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Visible));
+   end X0_Set_Visible;
+
+   ----------------
+   -- Y0_Visible --
+   ----------------
+
+   function Y0_Visible (Plot   : access Gtk_Plot_Record)
+                       return Boolean
+   is
+      function Internal (Plot   : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_y0_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end Y0_Visible;
+
+   --------------------
+   -- Y0_Set_Visible --
+   --------------------
+
+   procedure Y0_Set_Visible (Plot    : access Gtk_Plot_Record;
+                             Visible : Boolean)
+   is
+      procedure Internal
+         (Plot    : System.Address;
+          Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_y0_set_visible");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Visible));
+   end Y0_Set_Visible;
+
+   -------------------
+   -- Grids_Visible --
+   -------------------
+
+   procedure Grids_Visible (Plot   : access Gtk_Plot_Record;
+                            Vmajor : out Boolean;
+                            Vminor : out Boolean;
+                            Hmajor : out Boolean;
+                            Hminor : out Boolean)
+   is
+      procedure Internal (Plot   : System.Address;
+                          Vmajor : out Gboolean;
+                          Vminor : out Gboolean;
+                          Hmajor : out Gboolean;
+                          Hminor : out Gboolean);
+      pragma Import (C, Internal, "gtk_plot_grids_visible");
+
+      Vma, Vmi, Hma, Hmi : Gboolean;
+   begin
+      Internal (Get_Object (Plot), Vma, Vmi, Hma, Hmi);
+      Vmajor := Boolean'Val (Vma);
+      Vminor := Boolean'Val (Vmi);
+      Hmajor := Boolean'Val (Hma);
+      Hminor := Boolean'Val (Hmi);
+   end Grids_Visible;
+
+   -----------------------
+   -- Grids_Set_Visible --
+   -----------------------
+
+   procedure Grids_Set_Visible (Plot   : access Gtk_Plot_Record;
+                                Vmajor : Boolean;
+                                Vminor : Boolean;
+                                Hmajor : Boolean;
+                                Hminor : Boolean)
+   is
+      procedure Internal
+         (Plot   : System.Address;
+          Vmajor : Gint;
+          Vminor : Gint;
+          Hmajor : Gint;
+          Hminor : Gint);
+      pragma Import (C, Internal, "gtk_plot_grids_set_visible");
+   begin
+      Internal (Get_Object (Plot),
+                Boolean'Pos (Vmajor),
+                Boolean'Pos (Vminor),
+                Boolean'Pos (Hmajor),
+                Boolean'Pos (Hminor));
+   end Grids_Set_Visible;
+
+   ---------------------------
+   -- X0line_Set_Attributes --
+   ---------------------------
+
+   procedure X0line_Set_Attributes (Plot  : access Gtk_Plot_Record;
+                                    Style : Plot_Line_Style;
+                                    Width : Gfloat;
+                                    Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_x0line_set_attributes");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Style, Width, Ca);
+   end X0line_Set_Attributes;
+
+   ---------------------------
+   -- Y0line_Set_Attributes --
+   ---------------------------
+
+   procedure Y0line_Set_Attributes (Plot  : access Gtk_Plot_Record;
+                                    Style : Plot_Line_Style;
+                                    Width : Gfloat;
+                                    Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+         (Plot  : System.Address;
+          Style : Plot_Line_Style;
+          Width : Gfloat;
+          Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_y0line_set_attributes");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Style, Width, Ca);
+   end Y0line_Set_Attributes;
+
+   --------------------------------
+   -- Major_Hgrid_Set_Attributes --
+   --------------------------------
+
+   procedure Major_Hgrid_Set_Attributes (Plot  : access Gtk_Plot_Record;
+                                         Style : Plot_Line_Style;
+                                         Width : Gfloat;
+                                         Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_major_hgrid_set_attributes");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Style, Width, Ca);
+   end Major_Hgrid_Set_Attributes;
+
+   --------------------------------
+   -- Major_Vgrid_Set_Attributes --
+   --------------------------------
+
+   procedure Major_Vgrid_Set_Attributes (Plot  : access Gtk_Plot_Record;
+                                         Style : Plot_Line_Style;
+                                         Width : Gfloat;
+                                         Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_major_vgrid_set_attributes");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Style, Width, Ca);
+   end Major_Vgrid_Set_Attributes;
+
+   --------------------------------
+   -- Minor_Hgrid_Set_Attributes --
+   --------------------------------
+
+   procedure Minor_Hgrid_Set_Attributes (Plot  : access Gtk_Plot_Record;
+                                         Style : Plot_Line_Style;
+                                         Width : Gfloat;
+                                         Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_minor_hgrid_set_attributes");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Style, Width, Ca);
+   end Minor_Hgrid_Set_Attributes;
+
+   --------------------------------
+   -- Minor_Vgrid_Set_Attributes --
+   --------------------------------
+
+   procedure Minor_Vgrid_Set_Attributes (Plot  : access Gtk_Plot_Record;
+                                         Style : Plot_Line_Style;
+                                         Width : Gfloat;
+                                         Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_minor_vgrid_set_attributes");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if C = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), Style, Width, Ca);
+   end Minor_Vgrid_Set_Attributes;
+
+   ------------------
+   -- Show_Legends --
+   ------------------
+
+   procedure Show_Legends (Plot : access Gtk_Plot_Record)
+   is
+      procedure Internal (Plot : System.Address);
+      pragma Import (C, Internal, "gtk_plot_show_legends");
+   begin
+      Internal (Get_Object (Plot));
+   end Show_Legends;
+
+   ------------------
+   -- Hide_Legends --
+   ------------------
+
+   procedure Hide_Legends (Plot : access Gtk_Plot_Record)
+   is
+      procedure Internal (Plot : System.Address);
+      pragma Import (C, Internal, "gtk_plot_hide_legends");
+   begin
+      Internal (Get_Object (Plot));
+   end Hide_Legends;
+
+   ------------------------
+   -- Set_Legends_Border --
+   ------------------------
+
+   procedure Set_Legends_Border (Plot         : access Gtk_Plot_Record;
+                                 Border       : Plot_Border_Style;
+                                 Shadow_Width : Gint)
+   is
+      procedure Internal
+        (Plot         : System.Address;
+         Border       : Plot_Border_Style;
+         Shadow_Width : Gint);
+      pragma Import (C, Internal, "gtk_plot_set_legends_border");
+
+   begin
+      Internal (Get_Object (Plot), Border, Shadow_Width);
+   end Set_Legends_Border;
+
+   ------------------
+   -- Legends_Move --
+   ------------------
+
+   procedure Legends_Move (Plot : access Gtk_Plot_Record;
+                           X    : Gdouble;
+                           Y    : Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          X    : Gdouble;
+                          Y    : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_legends_move");
+   begin
+      Internal (Get_Object (Plot), X, Y);
+   end Legends_Move;
+
+   --------------------------
+   -- Legends_Get_Position --
+   --------------------------
+
+   procedure Legends_Get_Position (Plot : access Gtk_Plot_Record;
+                                   X    : out Gdouble;
+                                   Y    : out Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          X    : out Gdouble;
+                          Y    : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_legends_get_position");
+   begin
+      Internal (Get_Object (Plot), X, Y);
+   end Legends_Get_Position;
+
+   ----------------------------
+   -- Legends_Get_Allocation --
+   ----------------------------
+
+   function Legends_Get_Allocation (Plot   : access Gtk_Plot_Record)
+                                    return      Gtk.Widget.Gtk_Allocation
+   is
+      function Internal (Plot   : System.Address)
+                         return      Gtk.Widget.Gtk_Allocation;
+      pragma Import (C, Internal, "gtk_plot_legends_get_allocation");
+   begin
+      return Internal (Get_Object (Plot));
+   end Legends_Get_Allocation;
+
+   ----------------------------
+   -- Legends_Set_Attributes --
+   ----------------------------
+
+   procedure Legends_Set_Attributes (Plot       : access Gtk_Plot_Record;
+                                     Ps_Font    : String;
+                                     Height     : Gint;
+                                     Foreground : Gdk.Color.Gdk_Color;
+                                     Background : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Plot       : System.Address;
+                          Font       : System.Address;
+                          Height     : Gint;
+                          Foreground : System.Address;
+                          Background : System.Address);
+      pragma Import (C, Internal, "gtk_plot_legends_set_attributes");
+
+      Fore  : aliased Gdk.Color.Gdk_Color := Foreground;
+      Forea : System.Address := Fore'Address;
+      Back  : aliased Gdk.Color.Gdk_Color := Background;
+      Backa : System.Address := Back'Address;
+      Font  : String := Ps_Font & ASCII.NUL;
+      F     : System.Address := Font'Address;
+
+   begin
+      if Foreground = Gdk.Color.Null_Color then
+         Forea := System.Null_Address;
+      end if;
+
+      if Background = Gdk.Color.Null_Color then
+         Backa := System.Null_Address;
+      end if;
+
+      if Ps_Font = "" then
+         F := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Plot), F, Height, Forea, Backa);
+   end Legends_Set_Attributes;
+
+   --------------
+   -- Add_Data --
+   --------------
+
+   procedure Add_Data
+     (Plot : access Gtk_Plot_Record;
+      Data : access Gtk_Plot_Data_Record'Class)
+   is
+      procedure Internal (Plot : System.Address;
+                          Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_add_data");
+   begin
+      Internal (Get_Object (Plot), Get_Object (Data));
+   end Add_Data;
+
+   ------------------
+   -- Add_Function --
+   ------------------
+
+   function Add_Function (Plot   : access Gtk_Plot_Record;
+                          Func   : Plot_Function)
+                         return      Gtk_Plot_Data
+   is
+      function Internal (Plot   : System.Address;
+                         Func   : Plot_Function)
+                        return System.Address;
+      pragma Import (C, Internal, "gtk_plot_add_function");
+      Stub : Gtk_Plot_Data_Record;
+   begin
+      return Gtk_Plot_Data
+        (Get_User_Data (Internal (Get_Object (Plot), Func), Stub));
+   end Add_Function;
+
+   -----------------
+   -- Remove_Data --
+   -----------------
+
+   function Remove_Data
+     (Plot : access Gtk_Plot_Record;
+      Data : access Gtk_Plot_Data_Record'Class) return Boolean
+   is
+      function Internal
+        (Plot : System.Address; Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_remove_data");
+
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot), Get_Object (Data)));
+   end Remove_Data;
+
+   --------------
+   -- Get_Axis --
+   --------------
+
+   function Get_Axis
+     (Plot   : access Gtk_Plot_Record;
+      Axis   : Plot_Axis_Pos) return Gtk_Plot_Axis
+   is
+      function Internal
+        (Plot : System.Address; Axis : Plot_Axis_Pos) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_get_axis");
+
+      Stub : Gtk_Plot_Axis_Record;
+
+   begin
+      return Gtk_Plot_Axis (Get_User_Data
+         (Internal (Get_Object (Plot), Axis), Stub));
+   end Get_Axis;
+
+   ---------------------------
+   -- Generic_Plot_Function --
+   ---------------------------
+
+   function Generic_Plot_Function
+     (Plot  : System.Address;
+      Set   : Gtk_Plot_Data;
+      X     : Gdouble;
+      Error : access Gboolean) return Gdouble
+   is
+      Stub : Gtk_Plot_Record;
+      B    : aliased Boolean;
+      Y    : Gdouble;
+
+   begin
+      Y := Func (Gtk_Plot (Get_User_Data (Plot, Stub)), Set, X, B'Access);
+      Error.all := Boolean'Pos (B);
+
+      return Y;
+   end Generic_Plot_Function;
+
+   -----------------------------
+   -- Generic_Plot3D_Function --
+   -----------------------------
+
+   function Generic_Plot3D_Function
+     (Plot  : System.Address;
+      Set   : Gtk_Plot_Data;
+      X     : Gdouble;
+      Y     : Gdouble;
+      Error : access Gboolean) return Gdouble
+   is
+      Stub : Gtk_Plot_Record;
+      B    : aliased Boolean;
+      Z    : Gdouble;
+
+   begin
+      Z := Func (Gtk_Plot (Get_User_Data (Plot, Stub)), Set, X, Y, B'Access);
+      Error.all := Boolean'Pos (B);
+      return Z;
+   end Generic_Plot3D_Function;
+
+   -----------------
+   -- Remove_Text --
+   -----------------
+
+   procedure Remove_Text (Plot : access Gtk_Plot_Record;
+                          Text : Gtk_Plot_Text)
+   is
+      procedure Internal (Plot : System.Address;
+                          Text : Gtk_Plot_Text);
+      pragma Import (C, Internal, "gtk_plot_remove_text");
+   begin
+      Internal (Get_Object (Plot), Text);
+   end Remove_Text;
+
+   -----------------------
+   -- Set_Magnification --
+   -----------------------
+
+   procedure Set_Magnification (Plot          : access Gtk_Plot_Record;
+                                Magnification : Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          Magnification : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_magnification");
+   begin
+      Internal (Get_Object (Plot), Magnification);
+   end Set_Magnification;
+
+   -------------------------
+   -- Text_Set_Attributes --
+   -------------------------
+
+   procedure Text_Set_Attributes
+     (Text          : Gtk_Plot_Text;
+      Font          : String;
+      Height        : Gint;
+      Angle         : Plot_Angle;
+      Fg            : Gdk.Color.Gdk_Color;
+      Bg            : Gdk.Color.Gdk_Color;
+      Transparent   : Boolean := False;
+      Justification : Gtk.Enums.Gtk_Justification :=
+        Gtk.Enums.Justify_Center;
+      Str           : String := "")
+   is
+      procedure Internal
+        (Text          : Gtk_Plot_Text;
+         Font          : String;
+         Height        : Gint;
+         Angle         : Plot_Angle;
+         Fg            : System.Address;
+         Bg            : System.Address;
+         Transparent   : Gint;
+         Justification : Gtk.Enums.Gtk_Justification;
+         Str           : String);
+      pragma Import (C, Internal, "gtk_plot_text_set_attributes");
+
+      Back  : aliased Gdk.Color.Gdk_Color := Bg;
+      Fore  : aliased Gdk.Color.Gdk_Color := Fg;
+      Backa : System.Address := Back'Address;
+      Forea : System.Address := Fore'Address;
+
+   begin
+      if Fg = Gdk.Color.Null_Color then
+         Forea := System.Null_Address;
+      end if;
+
+      if Bg = Gdk.Color.Null_Color then
+         Backa := System.Null_Address;
+      end if;
+
+      Internal (Text, Font & ASCII.NUL, Height, Angle,
+                Forea, Backa, Boolean'Pos (Transparent),
+                Justification, Str & ASCII.NUL);
+   end Text_Set_Attributes;
+
+   -------------------
+   -- Text_Get_Size --
+   -------------------
+
+   procedure Text_Get_Size (Text          : Gtk_Plot_Text;
+                            Angle         : Plot_Angle;
+                            Font_Name     : String;
+                            Font_Size     : Gint;
+                            Width         : out Gint;
+                            Height        : out Gint;
+                            Ascent        : out Gint;
+                            Descent       : out Gint)
+   is
+      procedure Internal (Text          : Gtk_Plot_Text;
+                          Angle         : Plot_Angle;
+                          Font_Name     : String;
+                          Font_Size     : Gint;
+                          Width         : out Gint;
+                          Height        : out Gint;
+                          Ascent        : out Gint;
+                          Descent       : out Gint);
+      pragma Import (C, Internal, "gtk_plot_text_get_size");
+   begin
+      Internal (Text, Angle, Font_Name & ASCII.NUL, Font_Size, Width, Height,
+                Ascent, Descent);
+   end Text_Get_Size;
+
+   -------------------
+   -- Text_Get_Area --
+   -------------------
+
+   procedure Text_Get_Area (Text          : Gtk_Plot_Text;
+                            Angle         : Plot_Angle;
+                            Just          : Gtk_Justification;
+                            Font_Name     : String;
+                            Font_Size     : Gint;
+                            X             : out Gint;
+                            Y             : out Gint;
+                            Width         : out Gint;
+                            Height        : out Gint)
+   is
+      procedure Internal (Text          : Gtk_Plot_Text;
+                          Angle         : Plot_Angle;
+                          Just          : Gtk_Justification;
+                          Font_Name     : String;
+                          Font_Size     : Gint;
+                          X             : out Gint;
+                          Y             : out Gint;
+                          Width         : out Gint;
+                          Height        : out Gint);
+      pragma Import (C, Internal, "gtk_plot_text_get_area");
+   begin
+      Internal (Text, Angle, Just, Font_Name & ASCII.NUL, Font_Size, X, Y,
+                Width, Height);
+   end Text_Get_Area;
+
+   ---------------
+   -- Draw_Line --
+   ---------------
+
+   procedure Draw_Line (Plot : access Gtk_Plot_Record;
+                        Line : Gtk_Plot_Line;
+                        X1, Y1, X2, Y2 : Gdouble)
+   is
+      procedure Internal (Plot : System.Address;
+                          Line : Gtk_Plot_Line;
+                          X1, Y1, X2, Y2 : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_draw_line");
+   begin
+      Internal (Get_Object (Plot), Line, X1, Y1, X2, Y2);
+   end Draw_Line;
+
+   ---------------
+   -- Draw_Text --
+   ---------------
+
+   procedure Draw_Text (Plot : access Gtk_Plot_Record;
+                        Text : Gtk_Plot_Text)
+   is
+      procedure Internal (Plot : System.Address; Text : Gtk_Plot_Text);
+      pragma Import (C, Internal, "gtk_plot_draw_text");
+   begin
+      Internal (Get_Object (Plot), Text);
+   end Draw_Text;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New (Axis     : out Gtk_Plot_Axis;
+                      Orientation : Plot_Orientation) is
+   begin
+      Axis := new Gtk_Plot_Axis_Record;
+      Initialize (Axis, Orientation);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize (Axis     : access Gtk_Plot_Axis_Record'Class;
+                         Orientation : Plot_Orientation) is
+      function Internal (Orientation : Plot_Orientation) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_axis_new");
+   begin
+      Set_Object (Axis, Internal (Orientation));
+   end Initialize;
+
+   ----------------------------
+   -- Axis_Set_Labels_Suffix --
+   ----------------------------
+
+   procedure Axis_Set_Labels_Suffix
+     (Axis : access Gtk_Plot_Axis_Record;
+      Text : String)
+   is
+      procedure Internal
+        (Axis : System.Address;
+         Text : String);
+      pragma Import (C, Internal, "gtk_plot_axis_set_labels_suffix");
+
+   begin
+      Internal (Get_Object (Axis), Text & ASCII.NUL);
+   end Axis_Set_Labels_Suffix;
+
+   ----------------------------
+   -- Axis_Set_Labels_Prefix --
+   ----------------------------
+
+   procedure Axis_Set_Labels_Prefix
+     (Axis : access Gtk_Plot_Axis_Record;
+      Text : String)
+   is
+      procedure Internal
+        (Axis : System.Address;
+         Text : String);
+      pragma Import (C, Internal, "gtk_plot_axis_set_labels_prefix");
+
+   begin
+      Internal (Get_Object (Axis), Text & ASCII.NUL);
+   end Axis_Set_Labels_Prefix;
+
+   ----------------------------
+   -- Axis_Get_Labels_Suffix --
+   ----------------------------
+
+   function Axis_Get_Labels_Suffix
+     (Axis : access Gtk_Plot_Axis_Record) return String
+   is
+      function Internal (Axis : System.Address)
+         return Interfaces.C.Strings.chars_ptr;
+      pragma Import (C, Internal, "gtk_plot_axis_get_labels_suffix");
+
+   begin
+      return Value (Internal (Get_Object (Axis)));
+   end Axis_Get_Labels_Suffix;
+
+   ----------------------------
+   -- Axis_Get_Labels_Prefix --
+   ----------------------------
+
+   function Axis_Get_Labels_Prefix
+     (Axis : access Gtk_Plot_Axis_Record) return String
+   is
+      function Internal (Axis : System.Address)
+         return Interfaces.C.Strings.chars_ptr;
+      pragma Import (C, Internal, "gtk_plot_axis_get_labels_prefix");
+
+   begin
+      return Value (Internal (Get_Object (Axis)));
+   end Axis_Get_Labels_Prefix;
+
+   ---------------------------
+   -- Set_Background_Pixmap --
+   ---------------------------
+
+   procedure Set_Background_Pixmap
+     (Plot : access Gtk_Plot_Record; Pixmap : Gdk.Pixmap.Gdk_Pixmap)
+   is
+      procedure Internal (Plot : System.Address; Pixmap : Gdk.Gdk_Pixmap);
+      pragma Import (C, Internal, "gtk_plot_set_background_pixmap");
+   begin
+      Internal (Get_Object (Plot), Pixmap);
+   end Set_Background_Pixmap;
+
+   ---------------------
+   -- Set_Transparent --
+   ---------------------
+
+   procedure Set_Transparent
+     (Plot : access Gtk_Plot_Record; Transparent : Boolean)
+   is
+      procedure Internal (Plot : System.Address; Transparent : Integer);
+      pragma Import (C, Internal, "gtk_plot_set_transparent");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Transparent));
+   end Set_Transparent;
+
+   --------------------
+   -- Is_Transparent --
+   --------------------
+
+   function Is_Transparent (Plot : access Gtk_Plot_Record) return Boolean is
+      function Internal (Plot : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_plot_is_transparent");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end Is_Transparent;
+
+   ---------------
+   -- Reflect_X --
+   ---------------
+
+   procedure Reflect_X (Plot : access Gtk_Plot_Record; Reflect : Boolean) is
+      procedure Internal (Plot : System.Address; Reflect : Integer);
+      pragma Import (C, Internal, "gtk_plot_reflect_x");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Reflect));
+   end Reflect_X;
+
+   --------------------
+   -- Is_X_Reflected --
+   --------------------
+
+   function Is_X_Reflected (Plot : access Gtk_Plot_Record) return Boolean is
+      function Internal (Plot : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_plot_is_x_reflected");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end Is_X_Reflected;
+
+   ---------------
+   -- Reflect_Y --
+   ---------------
+
+   procedure Reflect_Y (Plot : access Gtk_Plot_Record; Reflect : Boolean) is
+      procedure Internal (Plot : System.Address; Reflect : Integer);
+      pragma Import (C, Internal, "gtk_plot_reflect_y");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Reflect));
+   end Reflect_Y;
+
+   --------------------
+   -- Is_Y_Reflected --
+   --------------------
+
+   function Is_Y_Reflected (Plot : access Gtk_Plot_Record) return Boolean is
+      function Internal (Plot : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_plot_is_y_reflected");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end Is_Y_Reflected;
+
+   --------------------
+   -- Axis_Set_Break --
+   --------------------
+
+   procedure Axis_Set_Break
+     (Axis         : access Gtk_Plot_Axis_Record;
+      Min, Max     : Gdouble;
+      Step_After   : Gdouble;
+      Nminor_After : Gint;
+      Scale_After  : Plot_Scale;
+      Pos          : Gdouble)
+   is
+      procedure Internal (Axis : System.Address;
+                          Min, Max, Step : Gdouble;
+                          Nminor : Gint;
+                          Scale : Plot_Scale;
+                          Pos   : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_axis_set_break");
+   begin
+      Internal (Get_Object (Axis), Min, Max, Step_After,
+                Nminor_After, Scale_After, Pos);
+   end Axis_Set_Break;
+
+   -----------------------
+   -- Axis_Remove_Break --
+   -----------------------
+
+   procedure Axis_Remove_Break
+     (Axis : access Gtk_Plot_Axis_Record)
+   is
+      procedure Internal (Axis : System.Address);
+      pragma Import (C, Internal, "gtk_plot_axis_remove_break");
+   begin
+      Internal (Get_Object (Axis));
+   end Axis_Remove_Break;
+
+   ----------------------------
+   -- Axis_Set_Labels_Offset --
+   ----------------------------
+
+   procedure Axis_Set_Labels_Offset
+     (Axis   : access Gtk_Plot_Axis_Record;
+      Offset : Gint)
+   is
+      procedure Internal (Axis : System.Address; O : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_set_labels_offset");
+   begin
+      Internal (Get_Object (Axis), Offset);
+   end Axis_Set_Labels_Offset;
+
+   ----------------------------
+   -- Axis_Get_Labels_Offset --
+   ----------------------------
+
+   function Axis_Get_Labels_Offset
+     (Axis : access Gtk_Plot_Axis_Record) return Gint
+   is
+      function Internal (Axis : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_axis_get_labels_offset");
+   begin
+      return Internal (Get_Object (Axis));
+   end Axis_Get_Labels_Offset;
+
+   ---------------------------
+   -- Axis_Set_Labels_Style --
+   ---------------------------
+
+   procedure Axis_Set_Labels_Style
+     (Axis      : access Gtk_Plot_Axis_Record;
+      Style     : Plot_Label_Style;
+      Precision : Gint)
+   is
+      procedure Internal
+        (Axis         : System.Address;
+         Style     : Plot_Label_Style;
+         Precision : Gint);
+      pragma Import (C, Internal, "gtk_plot_axis_set_labels_style");
+
+   begin
+      Internal (Get_Object (Axis), Style, Precision);
+   end Axis_Set_Labels_Style;
+
+   ----------------------
+   -- Grids_Set_On_Top --
+   ----------------------
+
+   procedure Grids_Set_On_Top
+     (Plot : access Gtk_Plot_Record; On_Top : Boolean)
+   is
+      procedure Internal (Plot : System.Address; On_Top : Integer);
+      pragma Import (C, Internal, "gtk_plot_grids_set_on_top");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (On_Top));
+   end Grids_Set_On_Top;
+
+   ------------------
+   -- Grids_On_Top --
+   ------------------
+
+   function Grids_On_Top (Plot : access Gtk_Plot_Record) return Boolean is
+      function Internal (Plot : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_plot_grids_on_top");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end Grids_On_Top;
+
+   -------------------------
+   -- Set_Line_Attributes --
+   -------------------------
+
+   procedure Set_Line_Attributes
+     (Plot : access Gtk_Plot_Record;
+      Line : Gtk_Plot_Line)
+   is
+      procedure Internal (Plot : System.Address; Line : Gtk_Plot_Line);
+      pragma Import (C, Internal, "gtk_plot_set_line_attributes");
+   begin
+      Internal (Get_Object (Plot), Line);
+   end Set_Line_Attributes;
+
+   ---------------
+   -- Set_Ticks --
+   ---------------
+
+   procedure Set_Ticks
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Major_Step  : Gdouble;
+      Num_Minor   : Gint)
+   is
+      procedure Internal
+        (Plot : System.Address;
+         Orientation : Plot_Orientation;
+         Major : Gdouble;
+         Minor : Gint);
+      pragma Import (C, Internal, "gtk_plot_set_ticks");
+   begin
+      Internal (Get_Object (Plot), Orientation, Major_Step, Num_Minor);
+   end Set_Ticks;
+
+   ---------------------
+   -- Set_Major_Ticks --
+   ---------------------
+
+   procedure Set_Major_Ticks
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Major_Step  : Gdouble)
+   is
+      procedure Internal
+        (Plot : System.Address;
+         Orientation : Plot_Orientation;
+         Major : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_major_ticks");
+   begin
+      Internal (Get_Object (Plot), Orientation, Major_Step);
+   end Set_Major_Ticks;
+
+   ---------------------
+   -- Set_Minor_Ticks --
+   ---------------------
+
+   procedure Set_Minor_Ticks
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Num_Minor   : Gint)
+   is
+      procedure Internal
+        (Plot : System.Address; Orient : Plot_Orientation; Minor : Gint);
+      pragma Import (C, Internal, "gtk_plot_set_minor_ticks");
+   begin
+      Internal (Get_Object (Plot), Orientation, Num_Minor);
+   end Set_Minor_Ticks;
+
+   ----------------------
+   -- Set_Ticks_Limits --
+   ----------------------
+
+   procedure Set_Ticks_Limits
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Ticks_Begin : Gdouble;
+      Ticks_End   : Gdouble)
+   is
+      procedure Internal
+        (Plot : System.Address; Orient : Plot_Orientation; B, E : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_ticks_limits");
+   begin
+      Internal (Get_Object (Plot), Orientation, Ticks_Begin, Ticks_End);
+   end Set_Ticks_Limits;
+
+   ------------------------
+   -- Unset_Ticks_Limits --
+   ------------------------
+
+   procedure Unset_Ticks_Limits
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation)
+   is
+      procedure Internal (Plot : System.Address; Orient : Plot_Orientation);
+      pragma Import (C, Internal, "gtk_plot_unset_ticks_limits");
+   begin
+      Internal (Get_Object (Plot), Orientation);
+   end Unset_Ticks_Limits;
+
+   ---------------
+   -- Set_Break --
+   ---------------
+
+   procedure Set_Break
+     (Plot         : access Gtk_Plot_Record;
+      Orient       : Plot_Orientation;
+      Min, Max     : Gdouble;
+      Step_After   : Gdouble;
+      Nminor_After : Gint;
+      Scale_After  : Plot_Scale;
+      Pos          : Gdouble)
+   is
+      procedure Internal
+        (Plot : System.Address;
+         Orien : Plot_Orientation;
+         Min, Max, Step : Gdouble;
+         Minor : Gint;
+         Scale : Plot_Scale;
+         Pos   : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_set_break");
+   begin
+      Internal (Get_Object (Plot), Orient, Min, Max, Step_After,
+                Nminor_After, Scale_After, Pos);
+   end Set_Break;
+
+   ------------------
+   -- Remove_Break --
+   ------------------
+
+   procedure Remove_Break
+     (Plot : access Gtk_Plot_Record; Orient : Plot_Orientation)
+   is
+      procedure Internal (Plot : System.Address; Orient : Plot_Orientation);
+      pragma Import (C, Internal, "gtk_plot_remove_break");
+   begin
+      Internal (Get_Object (Plot), Orient);
+   end Remove_Break;
+
+   -----------------------
+   -- Axis_Ticks_Recalc --
+   -----------------------
+
+   procedure Axis_Ticks_Recalc (Axis : access Gtk_Plot_Axis_Record) is
+      procedure Internal (Axis : System.Address);
+      pragma Import (C, Internal, "gtk_plot_axis_ticks_recalc");
+   begin
+      Internal (Get_Object (Axis));
+   end Axis_Ticks_Recalc;
+
+   --------------------------
+   -- Axis_Ticks_Transform --
+   --------------------------
+
+   function Axis_Ticks_Transform
+     (Axis : access Gtk_Plot_Axis_Record;
+      Y    : Gdouble) return Gdouble
+   is
+      function Internal (Axis : System.Address; Y : Gdouble) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_axis_ticks_transform");
+   begin
+      return Internal (Get_Object (Axis), Y);
+   end Axis_Ticks_Transform;
+
+   ------------------------
+   -- Axis_Ticks_Inverse --
+   ------------------------
+
+   function Axis_Ticks_Inverse
+     (Axis : access Gtk_Plot_Axis_Record;
+      X    : Gdouble) return Gdouble
+   is
+      function Internal (Axis : System.Address; X : Gdouble) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_axis_ticks_inverse");
+   begin
+      return Internal (Get_Object (Axis), X);
+   end Axis_Ticks_Inverse;
+
+   ----------------------
+   -- Axis_Parse_Label --
+   ----------------------
+
+   procedure Axis_Parse_Label
+     (Axis      : access Gtk_Plot_Axis_Record;
+      Val       : Gdouble;
+      Precision : Gint;
+      Style     : Gint;
+      Label     : String)
+   is
+      procedure Internal
+        (Axis : System.Address;
+         Val : Gdouble;
+         Precision, Style : Gint;
+         Label : String);
+      pragma Import (C, Internal, "gtk_plot_axis_parse_label");
+   begin
+      Internal (Get_Object (Axis), Val, Precision, Style, Label);
+   end Axis_Parse_Label;
+
+   --------------
+   -- Gradient --
+   --------------
+
+   function Gradient
+     (Data : access Gtk_Plot_Data_Record'Class) return Gtk_Plot_Axis
+   is
+      function Internal (Data : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_gradient");
+      Stub : Gtk_Plot_Axis_Record;
+   begin
+      return Gtk_Plot_Axis
+        (Get_User_Data (Internal (Get_Object (Data)), Stub));
+   end Gradient;
+
+end Gtk.Extra.Plot;
============================================================
--- src/gtk-extra-plot.ads	3972c2a4a746eb9cb9be89227276b4886f6d1cc7
+++ src/gtk-extra-plot.ads	3972c2a4a746eb9cb9be89227276b4886f6d1cc7
@@ -0,0 +1,1113 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--
+--  This package implements a high-level, general purpose plotting widget.
+--  You can display any set of data (set of points, curve defined by a
+--  parametric function, ...). This widget can automatically display them
+--  as a curve, along with labelled axis, axis tic marks, legends,...
+--
+--  This is the base class, that provides 2D graphics. Some children provide
+--  polar-coordinates and 3D graphics in addition.
+--
+--  It fully supports the drag-and-drop protocol for all of its children,
+--  which means that the user can interactively move them in the Gtk_Plot
+--  area.
+--
+--  A Gtk_Plot is closely associated with a Gdk_Drawable, on which all the
+--  drawings are done. It can be done anywhere within that drawable, its
+--  "position" is indicated by a tuple (X, Y), which are two values between
+--  0.0 and 1.0 (from left to right, or from top to bottom).
+--  Its size is also given as a ratio other the drawable's size.
+--
+--  Most points in the plot have also this relative coordinates systems, which
+--  makes it really easy to handle resizing of a plot window.
+--
+--  See the package Gtk.Extra.Plot_Ps for a way to easily print a Gtk_Plot to
+--  a postscript file.
+--
+--  In this package, font parameters are sometimes required. Here is the
+--  list of possible fonts used by Gtk.Extra:
+--
+--   - "Times-Roman",
+--   - "Times-Italic",
+--   - "Times-Bold",
+--   - "Times-BoldItalic",
+--   - "AvantGarde-Book",
+--   - "AvantGarde-BookOblique",
+--   - "AvantGarde-Demi",
+--   - "AvantGarde-DemiOblique",
+--   - "Bookman-Light",
+--   - "Bookman-LightItalic",
+--   - "Bookman-Demi",
+--   - "Bookman-DemiItalic",
+--   - "Courier",
+--   - "Courier-Oblique",
+--   - "Courier-Bold",
+--   - "Courier-BoldOblique",
+--   - "Helvetica",
+--   - "Helvetica-Oblique",
+--   - "Helvetica-Bold",
+--   - "Helvetica-BoldOblique",
+--   - "Helvetica-Narrow",
+--   - "Helvetica-Narrow-Oblique",
+--   - "Helvetica-Narrow-Bold",
+--   - "Helvetica-Narrow-BoldOblique",
+--   - "NewCenturySchoolbook-Roman",
+--   - "NewCenturySchoolbook-Italic",
+--   - "NewCenturySchoolbook-Bold",
+--   - "NewCenturySchoolbook-BoldItalic",
+--   - "Palatino-Roman",
+--   - "Palatino-Italic",
+--   - "Palatino-Bold",
+--   - "Palatino-BoldItalic",
+--   - "Symbol",
+--   - "ZapfChancery-MediumItalic",
+--   - "ZapfDingbats",
+--
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+--  <testgtk>create_plot.adb</testgtk>
+--  <screenshot>gtk-plot</screenshot>
+
+with System;
+with Gdk.Color;
+with Gdk.Drawable;
+with Gdk.Pixmap;
+with Gdk.Rectangle;
+with Gtk.Enums;
+with Gtk.Extra.Plot_Data;   use Gtk.Extra.Plot_Data;
+with Gtk.Object;
+with Gtk.Widget;
+
+package Gtk.Extra.Plot is
+
+   type Gtk_Plot_Record is new Gtk.Widget.Gtk_Widget_Record with private;
+   type Gtk_Plot is access all Gtk_Plot_Record'Class;
+
+   type Gtk_Plot_Axis_Record is new Gtk.Object.Gtk_Object_Record with private;
+   type Gtk_Plot_Axis is access all Gtk_Plot_Axis_Record'Class;
+   --  One of the axis of the plot.
+   --  There are up to six axis for each plot, one on each side. They can have
+   --  ticks, labels, etc.
+
+   type Gtk_Plot_Text is new Gdk.C_Proxy;
+   --  A text that can be displayed anywhere on the plot.
+
+   type Gtk_Plot_Line is new Gdk.C_Proxy;
+   --  A simple line drawn on the plot.
+
+   type Gtk_Plot_Symbol is new Gdk.C_Proxy;
+   type Gtk_Plot_Tick   is new Gdk.C_Proxy;
+   type Gtk_Plot_Ticks  is new Gdk.C_Proxy;
+
+   type Plot_Vector is record
+      X, Y, Z : Gdouble;
+   end record;
+
+   ----------------
+   -- Enum types --
+   ----------------
+
+   type Plot_Border_Style is
+     (Border_None,
+      --  No border is drawn
+
+      Border_Line,
+      --  A simple line on each side
+
+      Border_Shadow
+      --  The right and bottom lines are
+      --  thicker
+     );
+   --  Border types used for legends.
+   pragma Convention (C, Plot_Border_Style);
+
+   --     subtype Plot_Scale        is Gtk.Extra.Plot_Data.Plot_Scale;
+   --     subtype Plot_Label_Style  is Gtk.Extra.Plot_Data.Plot_Label_Style;
+   --     subtype Plot_Symbol_Style is Gtk.Extra.Plot_Data.Plot_Symbol_Style;
+   --     subtype Plot_Symbol_Type  is Gtk.Extra.Plot_Data.Plot_Symbol_Type;
+   --     subtype Plot_Line_Style   is Gtk.Extra.Plot_Data.Plot_Line_Style;
+   --     subtype Plot_Connector    is Gtk.Extra.Plot_Data.Plot_Connector;
+
+   --  In C, these types are declared in gtkplot.h. However, because of type
+   --  circularity, we need to define them in Gtk.Extra.Plot_Data, and have
+   --  subtypes here. This would lead to unnecessary required qualification in
+   --  user code though...
+
+   type Plot_Label_Pos is new Integer;
+   --  Position of labels along an axis.
+
+   Label_None   : constant Plot_Label_Pos;
+   Label_In     : constant Plot_Label_Pos;
+   Label_Out    : constant Plot_Label_Pos;
+
+   type Plot_Error is (Error_Div_Zero, Error_Log_Neg);
+   --  Errors that can be encountered while calculating a graph.
+   pragma Convention (C, Plot_Error);
+
+   type Plot_Axis_Pos is (Axis_Left, Axis_Right, Axis_Top, Axis_Bottom);
+   --  Where the axis should be put
+   pragma Convention (C, Plot_Axis_Pos);
+
+   type Plot_Orientation is (Axis_X, Axis_Y, Axis_Z);
+   --  How to reference axis in 3D plots
+   pragma Convention (C, Plot_Orientation);
+
+   type Plot_Ticks_Pos is new Integer;
+   --  The position and orientation of the ticks along an axis.
+   --  See the constants below for the possible values.
+   --  Note also that not all the values are valid with all types of axis.
+
+   Ticks_None  : constant Plot_Ticks_Pos;
+   Ticks_In    : constant Plot_Ticks_Pos;
+   Ticks_Out   : constant Plot_Ticks_Pos;
+
+   ---------------------
+   -- Creating a plot --
+   ---------------------
+
+   procedure Gtk_New
+     (Plot     : out Gtk_Plot;
+      Drawable : Gdk.Drawable.Gdk_Drawable := Gdk.Drawable.Null_Drawable);
+   --  Create a new plot, that will be displayed in Drawable.
+   --  All the dataset, labels, axis,... associated with the plot will be drawn
+   --  in that drawable, which must have been created beforehand.
+   --  Note that the drawable can also be set later with Set_Drawable.
+
+   procedure Gtk_New
+     (Plot     : out Gtk_Plot;
+      Width    : Gdouble;
+      Height   : Gdouble;
+      Drawable : Gdk.Drawable.Gdk_Drawable := Gdk.Drawable.Null_Drawable);
+   --  Create a new plot with a specific size.
+
+   procedure Initialize
+     (Plot     : access Gtk_Plot_Record'Class;
+      Drawable : Gdk.Drawable.Gdk_Drawable);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   procedure Initialize
+     (Plot     : access Gtk_Plot_Record'Class;
+      Drawable : Gdk.Drawable.Gdk_Drawable;
+      Width    : Gdouble;
+      Height   : Gdouble);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Plot.
+
+   procedure Set_Drawable
+     (Plot     : access Gtk_Plot_Record;
+      Drawable : Gdk.Drawable.Gdk_Drawable);
+   --  Modify the drawable on which the graphs are displayed.
+   --  From now on, all the drawings will be done on that drawable. Note that
+   --  they are not automatically copied to the new Drawable until the Plot
+   --  needs to be redrawn.
+
+   function Get_Drawable
+     (Plot : access Gtk_Plot_Record) return Gdk.Drawable.Gdk_Drawable;
+   --  Return the drawable on which the graphs are plotted.
+
+   procedure Set_Background
+     (Plot       : access Gtk_Plot_Record;
+      Background : Gdk.Color.Gdk_Color);
+   --  Change the background for the plot.
+   --  Note that this has no effect if the plot has been set to transparent
+   --  (see the flags below).
+   --  The Plot is also redrawn as soon as you modify this color.
+
+   procedure Set_Background_Pixmap
+     (Plot : access Gtk_Plot_Record; Pixmap : Gdk.Pixmap.Gdk_Pixmap);
+   --  Specificy a background pixmap to use for the plot
+
+   procedure Set_Transparent
+     (Plot : access Gtk_Plot_Record; Transparent : Boolean);
+   --  Whether the plot is transparent. If Transparent is True, all background
+   --  attributes are ignored (pixmap, color,...)
+
+   function Is_Transparent (Plot : access Gtk_Plot_Record) return Boolean;
+   --  Whether the plot is current transparent
+
+   procedure Paint (Plot : access Gtk_Plot_Record);
+   --  Force an immediate repaint of the widget in its pixmap.
+   --  The modification won't appear on the screen until you call Refresh.
+   --  It is probably not a good idea to call this function directly, and it
+   --  is more efficient to queue a draw request (see the Gtk.Widget package
+   --  for related functions).
+
+   procedure Refresh
+     (Plot : access Gtk_Plot_Record;
+      Area : Gdk.Rectangle.Gdk_Rectangle);
+   --  Copy the plot's pixmap to the screen.
+   --  The same comment as for Paint applies here, and you probably don't
+   --  have to call this function yourself, since queuing a draw request is
+   --  more efficient.
+
+   ----------------------------
+   --  Coordinates and sizes --
+   ----------------------------
+
+   procedure Get_Position
+     (Plot : access Gtk_Plot_Record;
+      X    : out Gdouble;
+      Y    : out Gdouble);
+   --  Return the position of the Plot within its drawable.
+   --  X and Y are in the range 0.0 .. 1.0, where (0.0, 0.0) is the top-left
+   --  corner and (1.0, 1.0) the bottom-right corner. The position can be
+   --  modified by Move below.
+
+   procedure Get_Size
+     (Plot   : access Gtk_Plot_Record;
+      Width  : out Gdouble;
+      Height : out Gdouble);
+   --  Return the size of the Plot.
+   --  Width and Height are both in the range 0.0 .. 1.0, where 1.0 means they
+   --  occupy all the space available in the Drawable, 0.5 means they only
+   --  occupy half of it.
+
+   function Get_Internal_Allocation
+     (Plot : access Gtk_Plot_Record) return Gtk.Widget.Gtk_Allocation;
+   --  Return the real position/size of the plot inside its parent container.
+   --  You should use this function instead of converting yourself the result
+   --  of Get_Position and Get_Size.
+
+   procedure Set_Magnification
+     (Plot          : access Gtk_Plot_Record;
+      Magnification : Gdouble);
+   --  Change the magnification level of the plot.
+   --  1.0 is the default magnification, higher values will zoom in while lower
+   --  values will zoom out.
+
+   procedure Move
+     (Plot : access Gtk_Plot_Record;
+      X    : Gdouble;
+      Y    : Gdouble);
+   --  Move the plot widget inside its drawable.
+   --  X and Y should both be in the range 0.0 .. 1.0 (from top-left corner
+   --  to bottom-right corner).
+
+   procedure Resize
+     (Plot   : access Gtk_Plot_Record;
+      Width  : Gdouble;
+      Height : Gdouble);
+   --  Resize the widget.
+   --  Width and Height should both be in the range 0.0 .. 1.0, this indicates
+   --  which ratio of the drawable's screen real-estate they should use.
+
+   procedure Move_Resize
+     (Plot   : access Gtk_Plot_Record;
+      X      : Gdouble;
+      Y      : Gdouble;
+      Width  : Gdouble;
+      Height : Gdouble);
+   --  Move and resize the widget in a single operation.
+   --  This is faster than doing each operation separately.
+
+   procedure Get_Pixel
+     (Plot : access Gtk_Plot_Record;
+      Xx   : Gdouble;
+      Yy   : Gdouble;
+      X    : out Gdouble;
+      Y    : out Gdouble);
+   --  Get the screen coordinate (relative to Plot's parent) of a point.
+   --  The initial coordinates (Xx, Yy) should be in the range 0.0 .. 1.0.
+
+   procedure Clip_Data (Plot : access Gtk_Plot_Record; Clip : Boolean);
+   --  If Clip is True, any drawing of a Gtk_Plot_Data will be limited to the
+   --  area occupied by Plot. Otherwise, it might draw outside of Plot.
+
+   procedure Get_Point
+     (Plot : access Gtk_Plot_Record;
+      X    : Gint;
+      Y    : Gint;
+      Xx   : out Gdouble;
+      Yy   : out Gdouble);
+   --  Convert from an absolute screen coordinate to a relative one.
+   --  (X, Y) should be relative to Plot's parent.
+   --  This function is the opposite of Get_Pixel.
+
+   procedure Set_Xrange
+     (Plot : access Gtk_Plot_Record;
+      Xmin : Gdouble := 0.0;
+      Xmax : Gdouble := 1.0);
+   --  Set the range of visible points for this plot.
+   --  Only the points of the graph those coordinates are in the range
+   --  Xmin .. Xmax will be visible.
+
+   procedure Set_Yrange
+     (Plot : access Gtk_Plot_Record;
+      Ymin : Gdouble := 0.0;
+      Ymax : Gdouble := 1.0);
+   --  Set the range of visible points for this plot.
+   --  Only the points of the graph those coordinates are in the range
+   --  Xmin .. Xmax will be visible.
+
+   procedure Set_Range
+     (Plot : access Gtk_Plot_Record;
+      Xmin : Gdouble := 0.0;
+      Xmax : Gdouble := 1.0;
+      Ymin : Gdouble := 0.0;
+      Ymax : Gdouble := 1.0);
+   --  Set both ranges at the same time
+
+   procedure Autoscale (Plot : access Gtk_Plot_Record);
+   --  Calculate automically the appropriate ranges for the plot.
+
+   procedure Get_Xrange
+     (Plot : access Gtk_Plot_Record;
+      Xmin : out Gdouble;
+      Xmax : out Gdouble);
+   --  Get the current range for the X axis.
+
+   procedure Get_Yrange
+     (Plot : access Gtk_Plot_Record;
+      Ymin : out Gdouble;
+      Ymax : out Gdouble);
+   --  Get the current range for the X axis.
+
+   procedure Set_Xscale
+     (Plot       : access Gtk_Plot_Record;
+      Scale_Type : Plot_Scale);
+   --  Set the type of the X axis (logarithmic, linear, ...).
+
+   procedure Set_Yscale
+     (Plot       : access Gtk_Plot_Record;
+      Scale_Type : Plot_Scale);
+   --  Set the type of the Y axis (logarithmic, linear, ...).
+
+   function Get_Xscale
+     (Plot : access Gtk_Plot_Record) return Plot_Scale;
+   --  Get the type of the X axis.
+
+   function Get_Yscale
+     (Plot : access Gtk_Plot_Record) return Plot_Scale;
+   --  Get the type of the Y axis.
+
+   procedure Reflect_X (Plot : access Gtk_Plot_Record; Reflect : Boolean);
+   --  Reverse the direction of the X axis
+
+   function Is_X_Reflected (Plot : access Gtk_Plot_Record) return Boolean;
+   --  Whether the X axis is currently reflected
+
+   procedure Reflect_Y (Plot : access Gtk_Plot_Record; Reflect : Boolean);
+   --  Reverse the direction of the Y axis
+
+   function Is_Y_Reflected (Plot : access Gtk_Plot_Record) return Boolean;
+   --  Whether the Y axis is currently reflected
+
+   ----------
+   -- Text --
+   ----------
+
+   function Put_Text
+     (Plot          : access Gtk_Plot_Record;
+      X             : Gdouble;
+      Y             : Gdouble;
+      Font          : String := "";
+      Font_Height   : Gint := 10;
+      Angle         : Plot_Angle;
+      Foreground    : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Background    : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Transparent   : Boolean := False;
+      Justification : Gtk.Enums.Gtk_Justification := Gtk.Enums.Justify_Center;
+      Text          : String := "") return Gtk_Plot_Text;
+   --  Print some text in Plot.
+   --  The text will be drawn at the relative coordinates (X, Y), with a
+   --  specified Angle.
+   --  If Font is the empty string, a default font and default Font_Height
+   --  will be used. Likewise, default colors will be used if you don't
+   --  specify any. Font should be the name of a postscript font, the list of
+   --  which can be found in Gtk.Plot.Psfont.
+   --  If Transparent is True, then no background will be drawn for the text.
+
+   procedure Remove_Text
+     (Plot : access Gtk_Plot_Record;
+      Text : Gtk_Plot_Text);
+   --  Remove some text that is currently visible on the plot.
+   --  Nothing is done if Text is currently not visible.
+
+   procedure Text_Get_Area
+     (Text          : Gtk_Plot_Text;
+      Angle         : Plot_Angle;
+      Just          : Gtk.Enums.Gtk_Justification;
+      Font_Name     : String;
+      Font_Size     : Gint;
+      X             : out Gint;
+      Y             : out Gint;
+      Width         : out Gint;
+      Height        : out Gint);
+   --  Return the area currently occupied by a text.
+   --  The coordinates are relative to the top-left corner of the plot in
+   --  which the text was put.
+
+   procedure Text_Get_Size
+     (Text          : Gtk_Plot_Text;
+      Angle         : Plot_Angle;
+      Font_Name     : String;
+      Font_Size     : Gint;
+      Width         : out Gint;
+      Height        : out Gint;
+      Ascent        : out Gint;
+      Descent       : out Gint);
+   --  Return the size in pixels occupied by a text in the plot.
+   --  See Gtk.Extra.Plot_Canvas for a function that returns a Gtk_Plot_Text.
+
+   procedure Text_Set_Attributes
+     (Text          : Gtk_Plot_Text;
+      Font          : String;
+      Height        : Gint;
+      Angle         : Plot_Angle;
+      Fg            : Gdk.Color.Gdk_Color;
+      Bg            : Gdk.Color.Gdk_Color;
+      Transparent   : Boolean := False;
+      Justification : Gtk.Enums.Gtk_Justification := Gtk.Enums.Justify_Center;
+      Str           : String := "");
+   --  Change the attributes of Text.
+
+   procedure Text_Set_Border
+     (Text         : Gtk_Plot_Text;
+      Border       : Plot_Border_Style;
+      Border_Space : Gint;
+      Border_Width : Gint;
+      Shadow_Width : Gint);
+   --  Set the border attributes for the text
+
+   procedure Draw_Text
+     (Plot : access Gtk_Plot_Record;
+      Text : Gtk_Plot_Text);
+   --  Draw the text
+
+   -----------
+   -- Lines --
+   -----------
+
+   procedure Draw_Line
+     (Plot           : access Gtk_Plot_Record;
+      Line           : Gtk_Plot_Line;
+      X1, Y1, X2, Y2 : Gdouble);
+   --  Draw a line on the plot
+
+   procedure Set_Line_Attributes
+     (Plot : access Gtk_Plot_Record;
+      Line : Gtk_Plot_Line);
+
+   ----------
+   -- Axis --
+   ----------
+   --  A Gtk_Plot has four axis, one one each of its sides. These axis can
+   --  have ticks, labels for ticks, titles, ... associated with them.
+
+   procedure Set_Ticks
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Major_Step  : Gdouble;
+      Num_Minor   : Gint);
+   --  Set up ticks for a specific orientation.
+   --  A horizontal orientation will match the left and right sides, whereas
+   --  a vertical orientation will match the top and bottom sides.
+   --  Major_Step is a value between 0.0 and 1.0 which indicates the
+   --  proportion of the total axis length between successive big ticks.
+   --  For instance, if Major_Step has a value of 0.2, there will be 5 big
+   --  ticks drawn along the axis.
+   --  Num_Minor is the number of minor ticks between each major one.
+
+   procedure Set_Major_Ticks
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Major_Step  : Gdouble);
+   --  Modify the step for major ticks.
+   --  Major_Step is a value between 0.0 and 1.0 which indicates the
+   --  proportion of the total axis length between successive big ticks.
+   --  For instance, if Major_Step has a value of 0.2, there will be 5 big
+   --  ticks drawn along the axis.
+   --  See also Set_Ticks.
+
+   procedure Set_Minor_Ticks
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Num_Minor   : Gint);
+   --  Modify the number of minor ticks between each major one.
+   --  See also Axis_Set_Ticks.
+
+   procedure Set_Ticks_Limits
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation;
+      Ticks_Begin : Gdouble;
+      Ticks_End   : Gdouble);
+   --  Indicate the area of the axis that should have ticks.
+   --  Ticks will be displayed only from Ticks_Beg to Ticks_End.
+
+   procedure Unset_Ticks_Limits
+     (Plot        : access Gtk_Plot_Record;
+      Orientation : Plot_Orientation);
+   --  Cancel the ticks limits set by a previous call to
+   --  Axis_Set_Ticks_Limits.
+
+   procedure Set_Break
+     (Plot         : access Gtk_Plot_Record;
+      Orient       : Plot_Orientation;
+      Min, Max     : Gdouble;
+      Step_After   : Gdouble;
+      Nminor_After : Gint;
+      Scale_After  : Plot_Scale;
+      Pos          : Gdouble);
+   --  ???
+
+   procedure Remove_Break
+     (Plot : access Gtk_Plot_Record; Orient : Plot_Orientation);
+   --  ???
+
+   procedure Gtk_New
+     (Axis        : out Gtk_Plot_Axis;
+      Orientation : Plot_Orientation);
+   --  Create a new axis
+
+   procedure Initialize
+     (Axis        : access Gtk_Plot_Axis_Record'Class;
+      Orientation : Plot_Orientation);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Axis_Get_Type return Gtk_Type;
+   --  Return the internal value associated with a Gtk_Plot_Axis.
+
+   function Get_Axis
+     (Plot   : access Gtk_Plot_Record;
+      Axis   : Plot_Axis_Pos) return Gtk_Plot_Axis;
+   --  Get a pointer to an axis.
+
+   function Gradient
+     (Data : access Gtk_Plot_Data_Record'Class) return Gtk_Plot_Axis;
+   --  Return the gradient associated with Data.
+   --
+   --  This function cannot be defined in Gtk.Plot_Data, since Gtk_Plot_Axis
+   --  must be defined in the same package as its primitive operations, ie
+   --  Gtk.Plot
+
+   procedure Axis_Set_Visible
+     (Axis    : access Gtk_Plot_Axis_Record;
+      Visible : Boolean);
+   --  Indicate whether the axis should be visible or not.
+
+   function Axis_Visible
+     (Axis    : access Gtk_Plot_Axis_Record) return Boolean;
+   --  Return the visibility state of the axis
+
+   procedure Axis_Set_Title
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Title : String);
+   --  Modify the title of the axis.
+   --  Each axis has a title that is displayed along its line (vertically
+   --  for the left and right sides).
+
+   procedure Axis_Show_Title
+     (Axis : access Gtk_Plot_Axis_Record);
+   --  Show the title associated with the axis.
+
+   procedure Axis_Hide_Title
+     (Axis : access Gtk_Plot_Axis_Record);
+   --  Hide the title associated with the axis.
+
+   procedure Axis_Move_Title
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Angle : Plot_Angle;
+      X     : Gdouble;
+      Y     : Gdouble);
+   --  Modify the position and orientation of the axis' title.
+   --  X and Y indicate a position relative to the location of the axis (0.0
+   --  to display it to the left (resp. top) of the axis, 1.0 to display it
+   --  to the right (resp. bottom) of the axis.
+
+   procedure Axis_Justify_Title
+     (Axis          : access Gtk_Plot_Axis_Record;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Modify the justification for the axis.
+
+   procedure Axis_Set_Attributes
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Modify the attributes of the lines of the axis.
+
+   procedure Axis_Get_Attributes
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Width : out    Gfloat;
+      Color : out    Gdk.Color.Gdk_Color);
+   --  Get the attributes of the axis.
+
+   procedure Axis_Set_Ticks
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Major_Step  : Gdouble;
+      Num_Minor   : Gint);
+   --  Set up ticks for a specific orientation.
+   --  A horizontal orientation will match the left and right sides, whereas
+   --  a vertical orientation will match the top and bottom sides.
+   --  Major_Step is a value between 0.0 and 1.0 which indicates the
+   --  proportion of the total axis length between successive big ticks.
+   --  For instance, if Major_Step has a value of 0.2, there will be 5 big
+   --  ticks drawn along the axis.
+
+   procedure Axis_Set_Major_Ticks
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Major_Step  : Gdouble);
+   --  Modify the step for major ticks.
+   --  Major_Step is a value between 0.0 and 1.0 which indicates the
+   --  proportion of the total axis length between successive big ticks.
+   --  For instance, if Major_Step has a value of 0.2, there will be 5 big
+   --  ticks drawn along the axis.
+   --  See also Axis_Set_Ticks.
+
+   procedure Axis_Set_Minor_Ticks
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Num_Minor   : Gint);
+   --  Modify the number of minor ticks between each major one.
+   --  See also Axis_Set_Ticks.
+
+   procedure Axis_Set_Ticks_Length
+     (Axis   : access Gtk_Plot_Axis_Record;
+      Length : Gint);
+   --  Set the length (in pixels) of the big ticks.
+   --  The small ticks will have half this length.
+
+   procedure Axis_Set_Ticks_Width
+     (Axis  : access Gtk_Plot_Axis_Record;
+      Width : Gfloat);
+   --  Set the width (in pixels) of the ticks.
+   --  This width is common to both the long and short ticks.
+
+   procedure Axis_Show_Ticks
+     (Axis       : access Gtk_Plot_Axis_Record;
+      Major_Mask : Plot_Ticks_Pos;
+      Minor_Mask : Plot_Ticks_Pos);
+   --  Set the style of the ticks.
+
+   procedure Axis_Set_Ticks_Limits
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Ticks_Begin : Gdouble;
+      Ticks_End   : Gdouble);
+   --  Indicate the area of the axis that should have ticks.
+   --  Ticks will be displayed only from Ticks_Beg to Ticks_End.
+
+   procedure Axis_Unset_Ticks_Limits
+     (Axis        : access Gtk_Plot_Axis_Record);
+   --  Cancel the ticks limits set by a previous call to
+   --  Axis_Set_Ticks_Limits.
+
+   procedure Axis_Set_Break
+     (Axis         : access Gtk_Plot_Axis_Record;
+      Min, Max     : Gdouble;
+      Step_After   : Gdouble;
+      Nminor_After : Gint;
+      Scale_After  : Plot_Scale;
+      Pos          : Gdouble);
+   --  ???
+
+   procedure Axis_Remove_Break (Axis : access Gtk_Plot_Axis_Record);
+   --  ???
+
+   procedure Axis_Show_Labels
+     (Axis        : access Gtk_Plot_Axis_Record;
+      Labels_Mask : Plot_Label_Pos);
+   --  Indicate whether a label should be drawn at each ticks to indicate
+   --  its value.
+   --  Not all values of Labels_Mask are relevant for all axis. For instance,
+   --  for a vertical axis, the relevant values are Axis_Right and Axis_Left.
+
+   procedure Axis_Title_Set_Attributes
+     (Axis          : access Gtk_Plot_Axis_Record;
+      Font          : String;
+      Height        : Gint;
+      Angle         : Plot_Angle;
+      Foreground    : Gdk.Color.Gdk_Color;
+      Background    : Gdk.Color.Gdk_Color;
+      Transparent   : Boolean;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Set the attributes to be used for the title of the axis.
+   --  Font is a postscript font name (as listed in the beginning of this
+   --  package).
+
+   procedure Axis_Set_Labels_Attributes
+     (Axis          : access Gtk_Plot_Axis_Record;
+      Font          : String;
+      Height        : Gint;
+      Angle         : Plot_Angle;
+      Foreground    : Gdk.Color.Gdk_Color;
+      Background    : Gdk.Color.Gdk_Color;
+      Transparent   : Boolean;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Set the attributes to be used for the ticks labels.
+
+   procedure Axis_Set_Labels_Offset
+     (Axis   : access Gtk_Plot_Axis_Record;
+      Offset : Gint);
+   --  Set the distance between the axis and its labels
+
+   function Axis_Get_Labels_Offset
+     (Axis : access Gtk_Plot_Axis_Record) return Gint;
+   --  Get the distance between the axis and its labels.
+
+   procedure Axis_Set_Labels_Style
+     (Axis      : access Gtk_Plot_Axis_Record;
+      Style     : Plot_Label_Style;
+      Precision : Gint);
+   --  Set the style of labels.
+   --  This indicates whether the labels should be displayed as floating
+   --  point values or in the scientific notation.
+   --  Precision is the number of digits to be printed.
+
+   procedure Axis_Use_Custom_Tick_Labels
+     (Axis   : access Gtk_Plot_Axis_Record;
+      Custom : Boolean := True);
+   --  Indicate which kind of labels should be used for major ticks.
+   --  If Custom is True, then the labels set by Axis_Set_Tick_Labels will
+   --  be used.
+
+   procedure Axis_Set_Labels_Suffix
+     (Axis : access Gtk_Plot_Axis_Record;
+      Text : String);
+   --  Defines a suffix to add after each label on the axis
+
+   procedure Axis_Set_Labels_Prefix
+     (Axis : access Gtk_Plot_Axis_Record;
+      Text : String);
+   --  Defines a prefix to add before each label on the axis
+
+   function Axis_Get_Labels_Suffix
+     (Axis : access Gtk_Plot_Axis_Record) return String;
+   --  Return the suffix added to each label.
+
+   function Axis_Get_Labels_Prefix
+     (Axis : access Gtk_Plot_Axis_Record) return String;
+   --  Return the prefix added to each label.
+
+   procedure Axis_Ticks_Recalc (Axis : access Gtk_Plot_Axis_Record);
+
+   function Axis_Ticks_Transform
+     (Axis : access Gtk_Plot_Axis_Record;
+      Y    : Gdouble) return Gdouble;
+
+   function Axis_Ticks_Inverse
+     (Axis : access Gtk_Plot_Axis_Record;
+      X    : Gdouble) return Gdouble;
+
+   procedure Axis_Parse_Label
+     (Axis      : access Gtk_Plot_Axis_Record;
+      Val       : Gdouble;
+      Precision : Gint;
+      Style     : Gint;
+      Label     : String);
+
+   -----------
+   -- Grids --
+   -----------
+   --  A grid can be displayed in the graph.
+   --  This makes it easier to understand a graphics in some situations.
+   --  The grid has two simultaneous line styles, each with its own specific
+   --  step (minor and major steps).
+   --
+   --  There are two special lines in the grid, that you can display even if
+   --  you don't display the rest of the line. These are the origin of the
+   --  coordinates system, ie the lines at X=0 and Y=0.
+
+   procedure X0_Set_Visible
+     (Plot    : access Gtk_Plot_Record;
+      Visible : Boolean);
+   --  Indicate whether the line at X=0 should be displayed.
+
+   function X0_Visible
+     (Plot : access Gtk_Plot_Record) return Boolean;
+   --  Return the visibility state of the line at X=0
+
+   procedure Y0_Set_Visible
+     (Plot    : access Gtk_Plot_Record;
+      Visible : Boolean);
+   --  Indicate whether the line at Y=0 should be displayed.
+
+   function Y0_Visible
+     (Plot   : access Gtk_Plot_Record) return Boolean;
+   --  Return the visibility state of the line at Y=0
+
+   procedure X0line_Set_Attributes
+     (Plot  : access Gtk_Plot_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes of the line at X=0
+
+   procedure Y0line_Set_Attributes
+     (Plot  : access Gtk_Plot_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes of the line at Y=0
+
+   procedure Grids_Set_On_Top
+     (Plot : access Gtk_Plot_Record; On_Top : Boolean);
+   --  Whether the grid should be displayed on top of the plots
+
+   function Grids_On_Top (Plot : access Gtk_Plot_Record) return Boolean;
+   --  Whether the gris is currently displayed on top of the plots
+
+   procedure Grids_Set_Visible
+     (Plot   : access Gtk_Plot_Record;
+      Vmajor : Boolean;
+      Vminor : Boolean;
+      Hmajor : Boolean;
+      Hminor : Boolean);
+   --  Indicate whether the lines of the grids should be displayed.
+   --  You can decide separately whether the major and minor lines should
+   --  be displayed.
+
+   procedure Grids_Visible
+     (Plot   : access Gtk_Plot_Record;
+      Vmajor : out Boolean;
+      Vminor : out Boolean;
+      Hmajor : out Boolean;
+      Hminor : out Boolean);
+   --  Return the visibility state of the grid.
+
+   procedure Major_Hgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes for the major horizontal lines in the grid.
+
+   procedure Major_Vgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes for the major vertical lines in the grid.
+
+   procedure Minor_Hgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes for the minor horizontal lines in the grid.
+
+   procedure Minor_Vgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes for the minor vertical lines in the grid.
+
+   -------------
+   -- Legends --
+   -------------
+   --  Each graph is associated with one legend, that is supposed to
+   --  indicate what the plot represents.
+
+   procedure Show_Legends (Plot : access Gtk_Plot_Record);
+   --  Indicate that the legend should be displayed.
+
+   procedure Hide_Legends (Plot : access Gtk_Plot_Record);
+   --  Indicate that the legend should not be displayed.
+
+   procedure Set_Legends_Border
+     (Plot         : access Gtk_Plot_Record;
+      Border       : Plot_Border_Style;
+      Shadow_Width : Gint);
+   --  Modify the way the borders of the legend look like.
+
+   procedure Legends_Move
+     (Plot : access Gtk_Plot_Record;
+      X    : Gdouble;
+      Y    : Gdouble);
+   --  Move the legend relative to the widget's area.
+   --  X and Y are percentage values. (0.0, 0.0) indicates the top-left
+   --  corner of the plot, (1.0, 1.0) indicates the bottom-right corner.
+
+   procedure Legends_Get_Position
+     (Plot : access Gtk_Plot_Record;
+      X    : out Gdouble;
+      Y    : out Gdouble);
+   --  Return the current position of the legend.
+
+   function Legends_Get_Allocation
+     (Plot   : access Gtk_Plot_Record) return Gtk.Widget.Gtk_Allocation;
+   --  Return the exact coordinates and size in pixels of the legend.
+   --  The coordinates are relative to the widget's parent container.
+
+   procedure Legends_Set_Attributes
+     (Plot       : access Gtk_Plot_Record;
+      Ps_Font    : String;
+      Height     : Gint;
+      Foreground : Gdk.Color.Gdk_Color;
+      Background : Gdk.Color.Gdk_Color);
+   --  Set the attributes to use when displaying the legend.
+
+   --------------
+   -- Datasets --
+   --------------
+   --  A dataset is a set of points, either given explicitly by your
+   --  application or calculated with a specific function, and that can be
+   --  plotted on the screen.
+   --  In Gtk_Plot, such a set is represented with symbols (special points in
+   --  the graph, that can be manipulated interactively if you so wish), linked
+   --  by connectors, which are either straight lines, splines, sets, ...
+   --  Multiple data sets can of course be printed on a single graph.
+
+   --  <doc_ignore>
+   generic
+      with function Func (Plot  : access Gtk_Plot_Record'Class;
+                          Set   : in     Gtk_Plot_Data;
+                          X     : in     Gdouble;
+                          Error : access Boolean)
+                         return Gdouble;
+   function Generic_Plot_Function (Plot  : System.Address;
+                                   Set   : Gtk_Plot_Data;
+                                   X     : Gdouble;
+                                   Error : access Gboolean)
+                                  return Gdouble;
+   --  Generic function that can be instantiated for Plot_Function below.
+   --  </doc_ignore>
+
+   --  <doc_ignore>
+   generic
+      with function Func (Plot  : access Gtk_Plot_Record'Class;
+                          Set   : in     Gtk_Plot_Data;
+                          X     : in     Gdouble;
+                          Y     : in     Gdouble;
+                          Error : access Boolean)
+                         return Gdouble;
+   function Generic_Plot3D_Function (Plot  : System.Address;
+                                     Set   : Gtk_Plot_Data;
+                                     X     : Gdouble;
+                                     Y     : Gdouble;
+                                     Error : access Gboolean)
+                                    return Gdouble;
+   --  Generic function that can be instanciated for Plot3D_Function below.
+   --  </doc_ignore>
+
+   type Plot3D_Function is access function
+     (Plot  : System.Address;
+      Set   : Gtk_Plot_Data;
+      X     : Gdouble;
+      Y     : Gdouble;
+      Error : access Gboolean) return Gdouble;
+   --  Function used for plotting 3D graphs.
+   --  It should return the value associated with (X, Y) in its graph, and set
+   --  Error to True if there was an error while calculating the value.
+
+   pragma Convention (C, Generic_Plot_Function);
+   pragma Convention (C, Generic_Plot3D_Function);
+   pragma Convention (C, Plot3D_Function);
+
+   procedure Add_Data
+     (Plot : access Gtk_Plot_Record;
+      Data : access Gtk_Plot_Data_Record'Class);
+   --  Add an existing set of data to the plot.
+   --  This set will automatically be drawn the next time the Plot itself is
+   --  drawn.
+
+   function Remove_Data
+     (Plot : access Gtk_Plot_Record;
+      Data : access Gtk_Plot_Data_Record'Class)
+      return Boolean;
+   --  Remove the dataset from Plot.
+   --  This function returns True if the dataset was indeed found and could be
+   --  removed, False otherwise.
+
+   function Add_Function
+     (Plot   : access Gtk_Plot_Record;
+      Func   : Plot_Function)
+      return  Gtk_Plot_Data;
+   --  Allocate a new dataset, whose point are automatically calculated.
+   --  Func is a function that takes the X coordinate value, and should return
+   --  the Y coordinate value.
+   --  The newly allocated set should be freed by calling Free above.
+   --  The set is automatically added to the plot, so you don't need to
+   --  explicitly call Add_Dataset.
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --
+   --  - "changed"
+   --    procedure Handler (Plot : access Gtk_Plot_Record'Class);
+   --
+   --    Called every time some property of the widget is changed, or the
+   --    widget is moved or resized.
+   --
+   --  - "moved"
+   --    function Handler (Plot : access Gtk_Plot_Record'Class;
+   --                      X    : Gdouble;
+   --                      Y    : Gdouble)
+   --                     return Boolean;
+   --
+   --    Called when the widget has been moved relative to its drawable.
+   --    Its new position is given in parameters.
+   --
+   --  - "resized"
+   --    function Handler (Plot   : access Gtk_Plot_Record'Class;
+   --                      Width  : Gdouble;
+   --                      Height : Gdouble)
+   --                     return Boolean;
+   --
+   --    Called when the widget has been resized relative to its drawable.
+   --    Its new size is given in parameters.
+   --
+   --  - "tick_label"
+   --    function Handler (Axis  : access Gtk_Plot_Axis_Record'Class;
+   --                      Tick  : Gdouble_Access;
+   --                      Label : Interfaces.C.Strings.chars_ptr)
+   --                     return Boolean;
+   --
+   --     Called when a label should be drawn. You can modify the contents
+   --     of Label (up to 100 characters) a
+   --
+   --  </signals>
+
+private
+   type Gtk_Plot_Record is new Gtk.Widget.Gtk_Widget_Record with null record;
+   type Gtk_Plot_Axis_Record is new Gtk.Object.Gtk_Object_Record with
+     null record;
+
+   Label_None   : constant Plot_Label_Pos := 0;
+   Label_In     : constant Plot_Label_Pos := 1;
+   Label_Out    : constant Plot_Label_Pos := 2;
+
+   Ticks_None  : constant Plot_Ticks_Pos := 0;
+   Ticks_In    : constant Plot_Ticks_Pos := 1;
+   Ticks_Out   : constant Plot_Ticks_Pos := 2;
+
+   pragma Import (C, Get_Type, "gtk_plot_get_type");
+   pragma Import (C, Axis_Get_Type, "gtk_plot_axis_get_type");
+   pragma Import (C, Text_Set_Border, "gtk_plot_text_set_border");
+end Gtk.Extra.Plot;
+
+--  Unbound:
+--    gtk_plot_set_pc
+--    gtk_plot_axis_set_tick_labels
+--    gtk_plot_axis_ticks_autoscale
============================================================
--- src/gtk-extra-plot_3d.adb	0e6c2a1c8d5150615c04e1ba18b11be2f16d2082
+++ src/gtk-extra-plot_3d.adb	0e6c2a1c8d5150615c04e1ba18b11be2f16d2082
@@ -0,0 +1,862 @@
+-----------------------------------------------------------------------
+--              GtkAda - Ada95 binding for Gtk+/Gnome                --
+--                                                                   --
+--                 Copyright (C) 2001-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+with Gdk.Color;           use Gdk.Color;
+with Gtk;                 use Gtk;
+with Gtk.Extra.Plot;      use Gtk.Extra.Plot;
+with Gtk.Extra.Plot_Data; use Gtk.Extra.Plot_Data;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_3D is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_3D_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Widget   : out Gtk_Plot_3D;
+      Drawable : Gdk.Drawable.Gdk_Drawable;
+      Width, Height : Gdouble := 0.0) is
+   begin
+      Widget := new Gtk_Plot_3D_Record;
+      Gtk.Extra.Plot_3D.Initialize (Widget, Drawable, Width, Height);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Widget   : access Gtk_Plot_3D_Record'Class;
+      Drawable : Gdk.Drawable.Gdk_Drawable;
+      Width    : Gdouble;
+      Height   : Gdouble)
+   is
+      function Internal (Drawable : Gdk_Drawable; Width, Height : Gdouble)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot3d_new_with_size");
+
+      function Internal2 (Drawable : Gdk_Drawable) return System.Address;
+      pragma Import (C, Internal2, "gtk_plot3d_new");
+
+   begin
+      if Width = 0.0 and then Height = 0.0 then
+         Set_Object (Widget, Internal2 (Drawable));
+      else
+         Set_Object (Widget, Internal (Drawable, Width, Height));
+      end if;
+   end Initialize;
+
+   ---------------
+   -- Autoscale --
+   ---------------
+
+   procedure Autoscale (Plot : access Gtk_Plot_3D_Record)
+   is
+      procedure Internal (Plot : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_autoscale");
+   begin
+      Internal (Get_Object (Plot));
+   end Autoscale;
+
+   ----------------
+   -- Hide_Title --
+   ----------------
+
+   procedure Hide_Title
+     (Plot : access Gtk_Plot_3D_Record; Side : Plot_Side)
+   is
+      procedure Internal (Plot : System.Address; Side : Plot_Side);
+      pragma Import (C, Internal, "gtk_plot3d_hide_title");
+
+   begin
+      Internal (Get_Object (Plot), Side);
+   end Hide_Title;
+
+   ---------------------
+   -- Set_Major_Ticks --
+   ---------------------
+
+   procedure Set_Major_Ticks
+     (Plot       : access Gtk_Plot_3D_Record;
+      Axis       : Plot_Orientation;
+      Major_Step : Gdouble)
+   is
+      procedure Internal
+        (Plot : System.Address; Axis : Plot_Orientation; Major_Step : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_major_ticks");
+
+   begin
+      Internal (Get_Object (Plot), Axis, Major_Step);
+   end Set_Major_Ticks;
+
+   ---------------------
+   -- Set_Minor_Ticks --
+   ---------------------
+
+   procedure Set_Minor_Ticks
+     (Plot   : access Gtk_Plot_3D_Record;
+      Axis   : Plot_Orientation;
+      Nminor : Gint)
+   is
+      procedure Internal
+        (Plot : System.Address; Axis : Plot_Orientation; Nminor : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_set_minor_ticks");
+
+   begin
+      Internal (Get_Object (Plot), Axis, Nminor);
+   end Set_Minor_Ticks;
+
+   ---------------
+   -- Set_Ticks --
+   ---------------
+
+   procedure Set_Ticks
+     (Plot       : access Gtk_Plot_3D_Record;
+      Axis       : Plot_Orientation;
+      Major_Step : Gdouble;
+      Nminor     : Gint)
+   is
+      procedure Internal
+        (Plot       : System.Address;
+         Axis       : Plot_Orientation;
+         Major_Step : Gdouble;
+         Nminor     : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_set_ticks");
+
+   begin
+      Internal
+        (Get_Object (Plot), Axis, Major_Step, Nminor);
+   end Set_Ticks;
+
+   ----------------------
+   -- Set_Ticks_Length --
+   ----------------------
+
+   procedure Set_Ticks_Length
+     (Plot : access Gtk_Plot_3D_Record; Axis : Plot_Orientation; Length : Gint)
+   is
+      procedure Internal
+        (Plot : System.Address; Axis : Plot_Orientation; Length : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_set_ticks_length");
+
+   begin
+      Internal (Get_Object (Plot), Axis, Length);
+   end Set_Ticks_Length;
+
+   ---------------------
+   -- Set_Ticks_Width --
+   ---------------------
+
+   procedure Set_Ticks_Width
+     (Plot  : access Gtk_Plot_3D_Record;
+      Axis  : Plot_Orientation;
+      Width : Gfloat)
+   is
+      procedure Internal
+        (Plot : System.Address; Axis : Plot_Orientation; Width : Gfloat);
+      pragma Import (C, Internal, "gtk_plot3d_set_ticks_width");
+
+   begin
+      Internal (Get_Object (Plot), Axis, Width);
+   end Set_Ticks_Width;
+
+   -----------------
+   -- Show_Labels --
+   -----------------
+
+   procedure Show_Labels
+     (Plot : access Gtk_Plot_3D_Record; Side : Plot_Side; Label_Mask : Gint)
+   is
+      procedure Internal
+        (Plot : System.Address; Side : Plot_Side;  Label_Mask : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_show_labels");
+
+   begin
+      Internal (Get_Object (Plot), Side, Label_Mask);
+   end Show_Labels;
+
+   ----------------
+   -- Show_Ticks --
+   ----------------
+
+   procedure Show_Ticks
+     (Plot       : access Gtk_Plot_3D_Record;
+      Side       : Plot_Side;
+      Major_Mask : Plot_Ticks_Pos;
+      Minor_Mask : Plot_Ticks_Pos)
+   is
+      procedure Internal
+        (Plot       : System.Address;
+         Side       : Plot_Side;
+         Major_Mask : Plot_Ticks_Pos;
+         Minor_Mask : Plot_Ticks_Pos);
+      pragma Import (C, Internal, "gtk_plot3d_show_ticks");
+
+   begin
+      Internal
+        (Get_Object (Plot), Side, Major_Mask, Minor_Mask);
+   end Show_Ticks;
+
+   ----------------
+   -- Show_Title --
+   ----------------
+
+   procedure Show_Title
+     (Plot : access Gtk_Plot_3D_Record; Side : Plot_Side)
+   is
+      procedure Internal (Plot : System.Address; Side : Plot_Side);
+      pragma Import (C, Internal, "gtk_plot3d_show_title");
+
+   begin
+      Internal (Get_Object (Plot), Side);
+   end Show_Title;
+
+   ---------------------------
+   -- Corner_Get_Attributes --
+   ---------------------------
+
+   procedure Corner_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : out Plot_Line_Style;
+         Width : out Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_corner_get_attributes");
+      C : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+      Color := C;
+   end Corner_Get_Attributes;
+
+   ---------------------------
+   -- Corner_Set_Attributes --
+   ---------------------------
+
+   procedure Corner_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_corner_set_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+   end Corner_Set_Attributes;
+
+   ------------------------
+   -- Corner_Set_Visible --
+   ------------------------
+
+   procedure Corner_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; Visible : Boolean)
+   is
+      procedure Internal (Plot    : System.Address; Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_corner_set_visible");
+   begin
+      Internal (Get_Object (Plot), Boolean'Pos (Visible));
+   end Corner_Set_Visible;
+
+   --------------------
+   -- Corner_Visible --
+   --------------------
+
+   function Corner_Visible (Plot   : access Gtk_Plot_3D_Record) return Boolean
+   is
+      function Internal (Plot   : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot3d_corner_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Plot)));
+   end Corner_Visible;
+
+   --------------------------
+   -- Frame_Get_Attributes --
+   --------------------------
+
+   procedure Frame_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : out Plot_Line_Style;
+         Width : out Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_frame_get_attributes");
+      C : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+      Color := C;
+   end Frame_Get_Attributes;
+
+   --------------------------
+   -- Frame_Set_Attributes --
+   --------------------------
+
+   procedure Frame_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_frame_set_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+   end Frame_Set_Attributes;
+
+   --------------
+   -- Get_Axis --
+   --------------
+
+   function Get_Axis
+     (Plot        : access Gtk_Plot_3D_Record;
+      Orientation : Plot_Orientation)
+      return Gtk_Plot_Axis
+   is
+      function Internal
+        (Plot        : System.Address;
+         Orientation : Plot_Orientation) return System.Address;
+      pragma Import (C, Internal, "gtk_plot3d_get_axis");
+
+      Stub : Gtk_Plot_Axis_Record;
+
+   begin
+      return Gtk_Plot_Axis (Get_User_Data
+        (Internal (Get_Object (Plot), Orientation), Stub));
+   end Get_Axis;
+
+   ---------------
+   -- Get_Pixel --
+   ---------------
+
+   procedure Get_Pixel
+     (Plot       : access Gtk_Plot_3D_Record;
+      X, Y, Z    : Gdouble;
+      Px, Py, Pz : out Gdouble)
+   is
+      procedure Internal
+        (Plot       : System.Address;
+         X, Y, Z    : Gdouble;
+         Px, Py, Pz : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_get_pixel");
+   begin
+      Internal (Get_Object (Plot), X, Y, Z, Px, Py, Pz);
+   end Get_Pixel;
+
+   --------------
+   -- Get_Side --
+   --------------
+
+   function Get_Side
+     (Plot   : access Gtk_Plot_3D_Record;
+      Side   : Plot_Side) return Gtk_Plot_Axis
+   is
+      function Internal
+        (Plot : System.Address; Side : Plot_Side) return System.Address;
+      pragma Import (C, Internal, "gtk_plot3d_get_side");
+
+      Stub : Gtk_Plot_Axis_Record;
+
+   begin
+      return Gtk_Plot_Axis (Get_User_Data
+         (Internal (Get_Object (Plot), Side), Stub));
+   end Get_Side;
+
+   -----------------------
+   -- Get_Titles_Offset --
+   -----------------------
+
+   function Get_Titles_Offset (Plot : access Gtk_Plot_3D_Record) return Gint is
+      function Internal (Plot   : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot3d_get_titles_offset");
+   begin
+      return Internal (Get_Object (Plot));
+   end Get_Titles_Offset;
+
+   -----------------
+   -- Get_Xfactor --
+   -----------------
+
+   function Get_Xfactor (Plot   : access Gtk_Plot_3D_Record) return Gdouble
+   is
+      function Internal (Plot   : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot3d_get_xfactor");
+   begin
+      return Internal (Get_Object (Plot));
+   end Get_Xfactor;
+
+   -----------------
+   -- Get_Yfactor --
+   -----------------
+
+   function Get_Yfactor (Plot   : access Gtk_Plot_3D_Record) return Gdouble
+   is
+      function Internal (Plot   : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot3d_get_yfactor");
+   begin
+      return Internal (Get_Object (Plot));
+   end Get_Yfactor;
+
+   -----------------
+   -- Get_Zfactor --
+   -----------------
+
+   function Get_Zfactor (Plot   : access Gtk_Plot_3D_Record) return Gdouble
+   is
+      function Internal (Plot   : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot3d_get_zfactor");
+   begin
+      return Internal (Get_Object (Plot));
+   end Get_Zfactor;
+
+   -----------------------------
+   -- Major_Grids_Set_Visible --
+   -----------------------------
+
+   procedure Major_Grids_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : Boolean)
+   is
+      procedure Internal (Plot : System.Address; X, Y, Z : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_major_grids_set_visible");
+   begin
+      Internal
+        (Get_Object (Plot), Boolean'Pos (X), Boolean'Pos (Y), Boolean'Pos (Z));
+   end Major_Grids_Set_Visible;
+
+   -------------------------
+   -- Major_Grids_Visible --
+   -------------------------
+
+   procedure Major_Grids_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : out Boolean)
+   is
+      procedure Internal (Plot : System.Address; X, Y, Z : out Gboolean);
+      pragma Import (C, Internal, "gtk_plot3d_major_grids_visible");
+      Xb, Yb, Zb : Gboolean;
+   begin
+      Internal (Get_Object (Plot), Xb, Yb, Zb);
+      X := Boolean'Val (Xb);
+      Y := Boolean'Val (Yb);
+      Z := Boolean'Val (Zb);
+   end Major_Grids_Visible;
+
+   --------------------------------
+   -- Major_Zgrid_Get_Attributes --
+   --------------------------------
+
+   procedure Major_Zgrid_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : out Plot_Line_Style;
+         Width : out Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_major_zgrid_get_attributes");
+      C : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+      Color := C;
+   end Major_Zgrid_Get_Attributes;
+
+   --------------------------------
+   -- Major_Zgrid_Set_Attributes --
+   --------------------------------
+
+   procedure Major_Zgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_major_zgrid_set_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+   end Major_Zgrid_Set_Attributes;
+
+   -----------------------------
+   -- Minor_Grids_Set_Visible --
+   -----------------------------
+
+   procedure Minor_Grids_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : Boolean)
+   is
+      procedure Internal (Plot : System.Address; X, Y, Z : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_minor_grids_set_visible");
+   begin
+      Internal
+        (Get_Object (Plot), Boolean'Pos (X), Boolean'Pos (Y), Boolean'Pos (Z));
+   end Minor_Grids_Set_Visible;
+
+   -------------------------
+   -- Minor_Grids_Visible --
+   -------------------------
+
+   procedure Minor_Grids_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : out Boolean)
+   is
+      procedure Internal (Plot : System.Address; X, Y, Z : out Gboolean);
+      pragma Import (C, Internal, "gtk_plot3d_minor_grids_visible");
+      Xb, Yb, Zb : Gboolean;
+   begin
+      Internal (Get_Object (Plot), Xb, Yb, Zb);
+      X := Boolean'Val (Xb);
+      Y := Boolean'Val (Yb);
+      Z := Boolean'Val (Zb);
+   end Minor_Grids_Visible;
+
+   --------------------------------
+   -- Minor_Zgrid_Get_Attributes --
+   --------------------------------
+
+   procedure Minor_Zgrid_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : out Plot_Line_Style;
+         Width : out Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_minor_zgrid_get_attributes");
+      C : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+      Color := C;
+   end Minor_Zgrid_Get_Attributes;
+
+   --------------------------------
+   -- Minor_Zgrid_Set_Attributes --
+   --------------------------------
+
+   procedure Minor_Zgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_minor_zgrid_set_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal (Get_Object (Plot), Style, Width, C'Address);
+   end Minor_Zgrid_Set_Attributes;
+
+   ---------------------
+   -- Plane_Set_Color --
+   ---------------------
+
+   procedure Plane_Set_Color
+     (Plot  : access Gtk_Plot_3D_Record;
+      Plane : Plot_Plane;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Plane : Plot_Plane;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_plane_set_color");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal (Get_Object (Plot), Plane, C'Address);
+   end Plane_Set_Color;
+
+   -----------------------
+   -- Plane_Set_Visible --
+   -----------------------
+
+   procedure Plane_Set_Visible
+     (Plot    : access Gtk_Plot_3D_Record;
+      Plane   : Plot_Plane;
+      Visible : Boolean)
+   is
+      procedure Internal
+        (Plot : System.Address; Plane : Plot_Plane; Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_plane_set_visible");
+
+   begin
+      Internal
+        (Get_Object (Plot), Plane, Boolean'Pos (Visible));
+   end Plane_Set_Visible;
+
+   -------------------
+   -- Plane_Visible --
+   -------------------
+
+   function Plane_Visible
+     (Plot : access Gtk_Plot_3D_Record; Plane : Plot_Plane) return Boolean
+   is
+      function Internal
+        (Plot : System.Address; Plane : Plot_Plane) return Gint;
+      pragma Import (C, Internal, "gtk_plot3d_plane_visible");
+
+   begin
+      return Boolean'Val
+        (Internal (Get_Object (Plot), Plane));
+   end Plane_Visible;
+
+   ------------------
+   -- Reset_Angles --
+   ------------------
+
+   procedure Reset_Angles (Plot : access Gtk_Plot_3D_Record) is
+      procedure Internal (Plot : System.Address);
+      pragma Import (C, Internal, "gtk_plot3d_reset_angles");
+   begin
+      Internal (Get_Object (Plot));
+   end Reset_Angles;
+
+   ------------
+   -- Rotate --
+   ------------
+
+   procedure Rotate
+     (Plot    : access Gtk_Plot_3D_Record; Angle_X, Angle_Y, Angle_Z : Gdouble)
+   is
+      procedure Internal
+        (Plot    : System.Address; Angle_X, Angle_Y, Angle_Z : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_rotate");
+   begin
+      Internal (Get_Object (Plot), Angle_X, Angle_Y, Angle_Z);
+   end Rotate;
+
+   -------------------
+   -- Rotate_Vector --
+   -------------------
+
+   procedure Rotate_Vector
+     (Plot   : access Gtk_Plot_3D_Record;
+      Vector : Plot_Vector;
+      A1, A2, A3 : Gdouble)
+   is
+      procedure Internal
+        (Plot, Vector : System.Address; A1, A2, A3 : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_rotate_vector");
+      V : aliased Plot_Vector := Vector;
+   begin
+      Internal (Get_Object (Plot), V'Address, A1, A2, A3);
+   end Rotate_Vector;
+
+   --------------
+   -- Rotate_X --
+   --------------
+
+   procedure Rotate_X (Plot  : access Gtk_Plot_3D_Record; Angle : Gdouble) is
+      procedure Internal (Plot  : System.Address; Angle : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_rotate_x");
+   begin
+      Internal (Get_Object (Plot), Angle);
+   end Rotate_X;
+
+   --------------
+   -- Rotate_Y --
+   --------------
+
+   procedure Rotate_Y (Plot  : access Gtk_Plot_3D_Record; Angle : Gdouble) is
+      procedure Internal (Plot  : System.Address; Angle : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_rotate_y");
+   begin
+      Internal (Get_Object (Plot), Angle);
+   end Rotate_Y;
+
+   --------------
+   -- Rotate_Z --
+   --------------
+
+   procedure Rotate_Z (Plot  : access Gtk_Plot_3D_Record;  Angle : Gdouble) is
+      procedure Internal (Plot  : System.Address; Angle : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_rotate_z");
+   begin
+      Internal (Get_Object (Plot), Angle);
+   end Rotate_Z;
+
+   -----------------------
+   -- Set_Titles_Offset --
+   -----------------------
+
+   procedure Set_Titles_Offset
+     (Plot : access Gtk_Plot_3D_Record; Offset : Gint)
+   is
+      procedure Internal (Plot : System.Address; Offset : Gint);
+      pragma Import (C, Internal, "gtk_plot3d_set_titles_offset");
+   begin
+      Internal (Get_Object (Plot), Offset);
+   end Set_Titles_Offset;
+
+   -----------------
+   -- Set_Xfactor --
+   -----------------
+
+   procedure Set_Xfactor (Plot : access Gtk_Plot_3D_Record; Xfactor : Gdouble)
+   is
+      procedure Internal (Plot    : System.Address; Xfactor : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_xfactor");
+   begin
+      Internal (Get_Object (Plot), Xfactor);
+   end Set_Xfactor;
+
+   ----------------
+   -- Set_Xrange --
+   ----------------
+
+   procedure Set_Xrange (Plot : access Gtk_Plot_3D_Record; Min, Max : Gdouble)
+   is
+      procedure Internal (Plot : System.Address; Min, Max  : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_xrange");
+   begin
+      Internal (Get_Object (Plot), Min,  Max);
+   end Set_Xrange;
+
+   -----------------
+   -- Set_Yfactor --
+   -----------------
+
+   procedure Set_Yfactor (Plot : access Gtk_Plot_3D_Record; Yfactor : Gdouble)
+   is
+      procedure Internal (Plot : System.Address; Yfactor : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_yfactor");
+   begin
+      Internal (Get_Object (Plot), Yfactor);
+   end Set_Yfactor;
+
+   ----------------
+   -- Set_Yrange --
+   ----------------
+
+   procedure Set_Yrange (Plot : access Gtk_Plot_3D_Record; Min, Max : Gdouble)
+   is
+      procedure Internal (Plot : System.Address; Min, Max  : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_yrange");
+   begin
+      Internal (Get_Object (Plot), Min,  Max);
+   end Set_Yrange;
+
+   -----------------
+   -- Set_Zfactor --
+   -----------------
+
+   procedure Set_Zfactor (Plot : access Gtk_Plot_3D_Record; Zfactor : Gdouble)
+   is
+      procedure Internal (Plot : System.Address; Zfactor : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_zfactor");
+   begin
+      Internal (Get_Object (Plot), Zfactor);
+   end Set_Zfactor;
+
+   ----------------
+   -- Set_Zrange --
+   ----------------
+
+   procedure Set_Zrange (Plot : access Gtk_Plot_3D_Record; Min, Max : Gdouble)
+   is
+      procedure Internal (Plot : System.Address; Min, Max  : Gdouble);
+      pragma Import (C, Internal, "gtk_plot3d_set_zrange");
+   begin
+      Internal (Get_Object (Plot), Min,  Max);
+   end Set_Zrange;
+
+   ---------------
+   -- Set_Scale --
+   ---------------
+
+   procedure Set_Scale
+     (Plot  : access Gtk_Plot_3D_Record;
+      Axis  : Plot_Orientation;
+      Scale : Plot_Scale)
+   is
+      procedure Internal
+        (Plot  : System.Address;
+         Axis  : Plot_Orientation;
+         Scale : Plot_Scale);
+      pragma Import (C, Internal, "gtk_plot3d_set_scale");
+   begin
+      Internal (Get_Object (Plot), Axis, Scale);
+   end Set_Scale;
+
+   ---------------
+   -- Get_Scale --
+   ---------------
+
+   function Get_Scale
+     (Plot  : access Gtk_Plot_3D_Record;
+      Axis  : Gtk.Extra.Plot.Plot_Orientation)
+      return Plot_Scale
+   is
+      function Internal
+        (Plot : System.Address; Axis : Plot_Orientation)
+         return Plot_Scale;
+      pragma Import (C, Internal, "gtk_plot3d_get_scale");
+   begin
+      return Internal (Get_Object (Plot), Axis);
+   end Get_Scale;
+
+end Gtk.Extra.Plot_3D;
============================================================
--- src/gtk-extra-plot_3d.ads	38a8667ca9fe9c868a9f785984430d243d4be122
+++ src/gtk-extra-plot_3d.ads	38a8667ca9fe9c868a9f785984430d243d4be122
@@ -0,0 +1,352 @@
+-----------------------------------------------------------------------
+--              GtkAda - Ada95 binding for Gtk+/Gnome                --
+--                                                                   --
+--                     Copyright (C) 2001-2006                       --
+--                         AdaCore                                   --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special plot that draws its data in three dimension. The data associated
+--  with such plots should either be a function or a Gtk.Extra.Plot_Surface.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+--  <testgtk>create_plot_3d.adb</testgtk>
+--  <screenshot>gtk-plot_3d</screenshot>
+
+with Gdk.Color;
+with Gdk.Drawable;
+with Gtk.Extra.Plot;
+with Gtk.Extra.Plot_Data;
+
+package Gtk.Extra.Plot_3D is
+
+   type Gtk_Plot_3D_Record is new Gtk.Extra.Plot.Gtk_Plot_Record with private;
+   type Gtk_Plot_3D is access all Gtk_Plot_3D_Record'Class;
+
+   type Plot_Plane is new Integer;
+   Plot_Plane_Xy : constant Plot_Plane := 0;
+   Plot_Plane_Yx : constant Plot_Plane := 0;
+   Plot_Plane_Xz : constant Plot_Plane := 1;
+   Plot_Plane_Zx : constant Plot_Plane := 1;
+   Plot_Plane_Yz : constant Plot_Plane := 2;
+   Plot_Plane_Zy : constant Plot_Plane := 2;
+
+   type Plot_Side is mod 2 ** 32;
+   Plot_Side_Xy : constant Plot_Side := 2 ** 0;
+   Plot_Side_Xz : constant Plot_Side := 2 ** 1;
+   Plot_Side_Yx : constant Plot_Side := 2 ** 2;
+   Plot_Side_Yz : constant Plot_Side := 2 ** 3;
+   Plot_Side_Zx : constant Plot_Side := 2 ** 4;
+   Plot_Side_Zy : constant Plot_Side := 2 ** 5;
+
+   procedure Gtk_New
+     (Widget        : out Gtk_Plot_3D;
+      Drawable      : Gdk.Drawable.Gdk_Drawable;
+      Width, Height : Gdouble := 0.0);
+   --  Create a new 3D plot.
+
+   procedure Initialize
+     (Widget        : access Gtk_Plot_3D_Record'Class;
+      Drawable      : Gdk.Drawable.Gdk_Drawable;
+      Width, Height : Gdouble);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with this widget.
+
+   procedure Autoscale (Plot : access Gtk_Plot_3D_Record);
+   --  Chooses the best ranges for all coordinates depending on the data sets
+   --  put in Plot. Note that only data sets whose points you have set
+   --  explicitely are taken into account, not the ones based on functions.
+
+   function Get_Xfactor (Plot : access Gtk_Plot_3D_Record) return Gdouble;
+   function Get_Yfactor (Plot : access Gtk_Plot_3D_Record) return Gdouble;
+   function Get_Zfactor (Plot : access Gtk_Plot_3D_Record) return Gdouble;
+   --  Get the scaling factor along each of the coordinates.
+
+   procedure Set_Xfactor (Plot : access Gtk_Plot_3D_Record; Xfactor : Gdouble);
+   procedure Set_Yfactor (Plot : access Gtk_Plot_3D_Record; Yfactor : Gdouble);
+   procedure Set_Zfactor (Plot : access Gtk_Plot_3D_Record; Zfactor : Gdouble);
+   --  Set the scaling factor along each of the coordinates
+
+   procedure Set_Xrange (Plot : access Gtk_Plot_3D_Record; Min, Max : Gdouble);
+   procedure Set_Yrange (Plot : access Gtk_Plot_3D_Record; Min, Max : Gdouble);
+   procedure Set_Zrange (Plot : access Gtk_Plot_3D_Record; Min, Max : Gdouble);
+   --  Set the minimal and maximal values for each axis.
+
+   ----------
+   -- Axis --
+   ----------
+
+   procedure Show_Title
+     (Plot : access Gtk_Plot_3D_Record; Side : Plot_Side);
+   --  Show the title associated with the axis.
+
+   procedure Hide_Title
+     (Plot : access Gtk_Plot_3D_Record; Side : Plot_Side);
+   --  Hide the title associated with the axis.
+
+   procedure Set_Major_Ticks
+     (Plot       : access Gtk_Plot_3D_Record;
+      Axis       : Gtk.Extra.Plot.Plot_Orientation;
+      Major_Step : Gdouble);
+   --  Modify the step for major ticks.
+   --  This is a percentage value that indicates how many major ticks are
+   --  drawn along the axis. See also Axis_Set_Ticks.
+
+   procedure Set_Minor_Ticks
+     (Plot   : access Gtk_Plot_3D_Record;
+      Axis   : Gtk.Extra.Plot.Plot_Orientation;
+      Nminor : Gint);
+   --  Modify the number of minor ticks between each major one.
+   --  See also Axis_Set_Ticks.
+
+   procedure Set_Ticks
+     (Plot       : access Gtk_Plot_3D_Record;
+      Axis       : Gtk.Extra.Plot.Plot_Orientation;
+      Major_Step : Gdouble;
+      Nminor     : Gint);
+   --  Set up ticks for a specific orientation.
+   --  A horizontal orientation will match the left and right sides, whereas
+   --  a vertical orientation will match the top and bottom sides.
+   --  Major_Step is a percentage value of the widget size, and indicate the
+   --  step between each big ticks. For instance, if Major_Step has a value
+   --  of 0.2, there will be 5 big ticks drawn along the axis.
+   --  Num_Minor is the number of minor ticks between each major one.
+
+   procedure Set_Ticks_Length
+     (Plot   : access Gtk_Plot_3D_Record;
+      Axis   : Gtk.Extra.Plot.Plot_Orientation;
+      Length : Gint);
+   --  Set the length (in pixels) of the big ticks.
+   --  The small ticks will have half this length.
+
+   procedure Set_Ticks_Width
+     (Plot  : access Gtk_Plot_3D_Record;
+      Axis  : Gtk.Extra.Plot.Plot_Orientation;
+      Width : Gfloat);
+   --  Set the width (in pixels) of the ticks.
+   --  This width is common to both the long and short ticks.
+
+   procedure Show_Labels
+     (Plot       : access Gtk_Plot_3D_Record;
+      Side       : Plot_Side;
+      Label_Mask : Gint);
+   --  Indicate whether a label should be drawn at each ticks to indicate
+   --  its value.
+   --  Not all values of Labels_Mask are relevant for all axis. For instance,
+   --  for a vertical axis, the relevant values are Label_Right and Label_Left.
+
+   procedure Show_Ticks
+     (Plot       : access Gtk_Plot_3D_Record;
+      Side       : Plot_Side;
+      Major_Mask : Gtk.Extra.Plot.Plot_Ticks_Pos;
+      Minor_Mask : Gtk.Extra.Plot.Plot_Ticks_Pos);
+   --  Set the style of the ticks.
+
+   function Get_Axis
+     (Plot        : access Gtk_Plot_3D_Record;
+      Orientation : Gtk.Extra.Plot.Plot_Orientation)
+      return Gtk.Extra.Plot.Gtk_Plot_Axis;
+   --  Return a handle to a specific axis.
+
+   function Get_Side
+     (Plot : access Gtk_Plot_3D_Record; Side : Plot_Side)
+      return Gtk.Extra.Plot.Gtk_Plot_Axis;
+   --  Get the axis for a specific side.
+
+   procedure Set_Scale
+     (Plot  : access Gtk_Plot_3D_Record;
+      Axis  : Gtk.Extra.Plot.Plot_Orientation;
+      Scale : Gtk.Extra.Plot_Data.Plot_Scale);
+   --  Set the scale for the axis
+
+   function Get_Scale
+     (Plot  : access Gtk_Plot_3D_Record;
+      Axis  : Gtk.Extra.Plot.Plot_Orientation)
+      return Gtk.Extra.Plot_Data.Plot_Scale;
+   --  Get the current sale for the axis
+
+   ----------
+   -- Grid --
+   ----------
+
+   procedure Major_Grids_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : Boolean);
+   --  Indicate whether the grid should be displayed for each coordinate
+
+   procedure Major_Grids_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : out Boolean);
+   --  Indicate whether the grid is currently displayed.
+
+   procedure Minor_Grids_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : Boolean);
+   --  Indicate whether the grid should be displayed for each coordinate
+
+   procedure Minor_Grids_Visible
+     (Plot : access Gtk_Plot_3D_Record; X, Y, Z : out Boolean);
+   --  Indicate whether the grid is currently displayed.
+
+   procedure Major_Zgrid_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color);
+   --  Get the attributes of the major grid
+
+   procedure Major_Zgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes of the major grid
+
+   procedure Minor_Zgrid_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color);
+   --  Get the attributes of the minor grid
+
+   procedure Minor_Zgrid_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Set the attributes of the minor grid
+
+   --------------
+   -- Rotating --
+   --------------
+
+   procedure Reset_Angles (Plot : access Gtk_Plot_3D_Record);
+   --  reset all the angles to their default values
+
+   procedure Rotate
+     (Plot    : access Gtk_Plot_3D_Record;
+      Angle_X, Angle_Y, Angle_Z : Gdouble);
+   --  Rotate the plot along the three axis at the same time.
+   --  The angles are specified in degrees.
+
+   procedure Rotate_Vector
+     (Plot       : access Gtk_Plot_3D_Record;
+      Vector     : Gtk.Extra.Plot.Plot_Vector;
+      A1, A2, A3 : Gdouble);
+   --  Rotate Vector along the three axis.
+   --  The three angles A1, A2 and A3 are specified in degrees.
+
+   procedure Rotate_X (Plot  : access Gtk_Plot_3D_Record; Angle : Gdouble);
+   procedure Rotate_Y (Plot  : access Gtk_Plot_3D_Record; Angle : Gdouble);
+   procedure Rotate_Z (Plot  : access Gtk_Plot_3D_Record; Angle : Gdouble);
+   --  Rotate the plot along a specific axis.
+   --  Angle is specific in degrees.
+
+   ------------
+   -- Planes --
+   ------------
+   --  A 3D plot is associated, as usual, with three axis (one per coordinate
+   --  X, Y and Z). These three axis, together, define 3 planes that can be
+   --  shown or hidden, and on which a grid can be displayed to make it easy
+   --  to visualize the value of the data.
+
+   procedure Plane_Set_Color
+     (Plot : access Gtk_Plot_3D_Record;
+      Plane : Plot_Plane;
+      Color : Gdk.Color.Gdk_Color);
+   --  Define the background color to use for one of the planes. Each plane
+   --  can have its own color.
+
+   procedure Plane_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; Plane : Plot_Plane; Visible : Boolean);
+   --  Indicate whether each plane should be displayed or not.
+
+   function Plane_Visible
+     (Plot : access Gtk_Plot_3D_Record; Plane : Plot_Plane) return Boolean;
+   --  Indicate whether a plane is currently visible or not.
+
+   -------------
+   -- Corners --
+   -------------
+   --  In addition to drawing the three planes defined by the axis, a 3D plot
+   --  can also draw some lines to draw a cube around the plot (although the
+   --  three new planes defined by these lines are left transparent so that
+   --  the plot is visible.
+
+   procedure Corner_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color);
+   --  Get the style of the corner lines.
+
+   procedure Corner_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Define the style of the corner lines.
+
+   procedure Corner_Set_Visible
+     (Plot : access Gtk_Plot_3D_Record; Visible : Boolean);
+   --  Whether corners should be visible
+
+   function Corner_Visible (Plot : access Gtk_Plot_3D_Record) return Boolean;
+   --  Indicate whether corners are visible
+
+   ----------
+   -- Misc --
+   ----------
+
+   procedure Frame_Get_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : out Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : out Gfloat;
+      Color : out Gdk.Color.Gdk_Color);
+
+   procedure Frame_Set_Attributes
+     (Plot  : access Gtk_Plot_3D_Record;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+
+   procedure Get_Pixel
+     (Plot       : access Gtk_Plot_3D_Record;
+      X, Y, Z    : Gdouble;
+      Px, Py, Pz : out Gdouble);
+
+   function Get_Titles_Offset (Plot : access Gtk_Plot_3D_Record) return Gint;
+
+   procedure Set_Titles_Offset
+     (Plot : access Gtk_Plot_3D_Record; Offset : Gint);
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --  </signals>
+
+private
+   type Gtk_Plot_3D_Record is new Gtk.Extra.Plot.Gtk_Plot_Record
+     with null record;
+   pragma Import (C, Get_Type, "gtk_plot3d_get_type");
+end Gtk.Extra.Plot_3D;
============================================================
--- src/gtk-extra-plot_bar.adb	869695180e937b1b157534e5f23aad2216b39b12
+++ src/gtk-extra-plot_bar.adb	869695180e937b1b157534e5f23aad2216b39b12
@@ -0,0 +1,89 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                     Copyright (C) 2000                            --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gtk.Extra.Plot_Data;  use Gtk.Extra.Plot_Data;
+with Gtk.Enums;            use Gtk.Enums;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Bar is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Bar_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Bar         : out Gtk_Plot_Bar;
+      Orientation : Gtk.Enums.Gtk_Orientation) is
+   begin
+      Bar := new Gtk_Plot_Bar_Record;
+      Initialize (Bar, Orientation);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Bar         : access Gtk_Plot_Bar_Record'Class;
+      Orientation : Gtk.Enums.Gtk_Orientation)
+   is
+      function Internal (Orientation : Gtk_Orientation) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_bar_new");
+   begin
+      Set_Object (Bar, Internal (Orientation));
+   end Initialize;
+
+   ---------------
+   -- Set_Width --
+   ---------------
+
+   procedure Set_Width
+     (Bar   : access Gtk_Plot_Bar_Record'Class;
+      Width : Gdouble)
+   is
+      procedure Internal (Bar : System.Address; Width : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_bar_set_width");
+   begin
+      Internal (Get_Object (Bar), Width);
+   end Set_Width;
+
+   ---------------
+   -- Get_Width --
+   ---------------
+
+   function Get_Width (Bar : access Gtk_Plot_Bar_Record'Class)
+      return Gdouble
+   is
+      function Internal (Bar : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_bar_get_width");
+   begin
+      return Internal (Get_Object (Bar));
+   end Get_Width;
+   --  Return the width used to draw the bars
+end Gtk.Extra.Plot_Bar;
============================================================
--- src/gtk-extra-plot_bar.ads	41a2a299515a5367e3cb91119920f6e8c2b80623
+++ src/gtk-extra-plot_bar.ads	41a2a299515a5367e3cb91119920f6e8c2b80623
@@ -0,0 +1,66 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  This special type of data set displays itself with bar (also known
+--  as histograms).
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gtk.Extra.Plot_Data;
+with Gtk.Enums;
+
+package Gtk.Extra.Plot_Bar is
+
+   type Gtk_Plot_Bar_Record is new Gtk.Extra.Plot_Data.Gtk_Plot_Data_Record
+     with private;
+   type Gtk_Plot_Bar is access all Gtk_Plot_Bar_Record'Class;
+
+   procedure Gtk_New
+     (Bar         : out Gtk_Plot_Bar;
+      Orientation : Gtk.Enums.Gtk_Orientation);
+   --  Create a new Plot bar.
+
+   procedure Initialize
+     (Bar         : access Gtk_Plot_Bar_Record'Class;
+      Orientation : Gtk.Enums.Gtk_Orientation);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Bar.
+
+   procedure Set_Width
+     (Bar   : access Gtk_Plot_Bar_Record'Class;
+      Width : Gdouble);
+   --  Set the width of the bars
+
+   function Get_Width (Bar : access Gtk_Plot_Bar_Record'Class) return Gdouble;
+   --  Return the width used to draw the bars
+
+private
+   type Gtk_Plot_Bar_Record is new Gtk.Extra.Plot_Data.Gtk_Plot_Data_Record
+     with null record;
+   pragma Import (C, Get_Type, "gtk_plot_bar_get_type");
+end Gtk.Extra.Plot_Bar;
============================================================
--- src/gtk-extra-plot_box.adb	00410c82754bc402f9984d9648ce391fb80c9cdb
+++ src/gtk-extra-plot_box.adb	00410c82754bc402f9984d9648ce391fb80c9cdb
@@ -0,0 +1,61 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                     Copyright (C) 2000                            --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gtk.Extra.Plot_Data;  use Gtk.Extra.Plot_Data;
+with Gtk.Enums;            use Gtk.Enums;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Box is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Box_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Box         : out Gtk_Plot_Box;
+      Orientation : Gtk.Enums.Gtk_Orientation) is
+   begin
+      Box := new Gtk_Plot_Box_Record;
+      Initialize (Box, Orientation);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Box         : access Gtk_Plot_Box_Record'Class;
+      Orientation : Gtk.Enums.Gtk_Orientation)
+   is
+      function Internal (Orientation : Gtk_Orientation) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_box_new");
+   begin
+      Set_Object (Box, Internal (Orientation));
+   end Initialize;
+end Gtk.Extra.Plot_Box;
============================================================
--- src/gtk-extra-plot_box.ads	978c1f8eef3a0a0b5d36ebf7d7eb6927e6191357
+++ src/gtk-extra-plot_box.ads	978c1f8eef3a0a0b5d36ebf7d7eb6927e6191357
@@ -0,0 +1,57 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  This special type of data set displays itself with boxes
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gtk.Extra.Plot_Data;
+with Gtk.Enums;
+
+package Gtk.Extra.Plot_Box is
+
+   type Gtk_Plot_Box_Record is new Gtk.Extra.Plot_Data.Gtk_Plot_Data_Record
+     with private;
+   type Gtk_Plot_Box is access all Gtk_Plot_Box_Record'Class;
+
+   procedure Gtk_New
+     (Box         : out Gtk_Plot_Box;
+      Orientation : Gtk.Enums.Gtk_Orientation);
+   --  Create a new Plot bar.
+
+   procedure Initialize
+     (Box         : access Gtk_Plot_Box_Record'Class;
+      Orientation : Gtk.Enums.Gtk_Orientation);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Box
+
+private
+   type Gtk_Plot_Box_Record is new Gtk.Extra.Plot_Data.Gtk_Plot_Data_Record
+     with null record;
+   pragma Import (C, Get_Type, "gtk_plot_box_get_type");
+end Gtk.Extra.Plot_Box;
============================================================
--- src/gtk-extra-plot_canvas-ellipse.adb	10b9df3474b9b7467d7433a778217bfa107cb290
+++ src/gtk-extra-plot_canvas-ellipse.adb	10b9df3474b9b7467d7433a778217bfa107cb290
@@ -0,0 +1,83 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gdk.Color;            use Gdk.Color;
+with Gtk.Extra.Plot_Data;  use Gtk.Extra.Plot_Data;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Canvas.Ellipse is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Canvas_Ellipse_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Child : out Gtk_Plot_Canvas_Ellipse;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Fg    : Gdk.Color.Gdk_Color;
+      Bg    : Gdk.Color.Gdk_Color;
+      Fill  : Boolean)
+   is
+      function Internal
+        (Style : Plot_Line_Style;
+         Width : Gfloat;
+         Fg    : Gdk_Color;
+         Bg    : Gdk_Color;
+         Fill  : Gboolean) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_ellipse_new");
+   begin
+      Child := new Gtk_Plot_Canvas_Ellipse_Record;
+      Set_Object (Child, Internal (Style, Width, Fg, Bg, Boolean'Pos (Fill)));
+   end Gtk_New;
+
+   --------------------
+   -- Set_Attributes --
+   --------------------
+
+   procedure Set_Attributes
+     (Ellipse : access Gtk_Plot_Canvas_Ellipse_Record;
+      Style   : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width   : Gdouble;
+      Fg      : Gdk.Color.Gdk_Color;
+      Bg      : Gdk.Color.Gdk_Color;
+      Fill    : Boolean)
+   is
+      procedure Internal
+        (Ellipse : System.Address;
+         Style   : Plot_Line_Style;
+         Width   : Gdouble;
+         Fg      : Gdk_Color;
+         Bg      : Gdk_Color;
+         Fill    : Gboolean);
+      pragma Import (C, Internal, "gtk_plot_canvas_ellipse_set_attributes");
+   begin
+      Internal
+        (Get_Object (Ellipse), Style, Width, Fg, Bg, Boolean'Pos (Fill));
+   end Set_Attributes;
+
+end Gtk.Extra.Plot_Canvas.Ellipse;
============================================================
--- src/gtk-extra-plot_canvas-ellipse.ads	53ca9fc4a80435c29e482eece85b8ea6e177522e
+++ src/gtk-extra-plot_canvas-ellipse.ads	53ca9fc4a80435c29e482eece85b8ea6e177522e
@@ -0,0 +1,62 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk.Color;
+with Gtk.Extra.Plot_Data;
+
+package Gtk.Extra.Plot_Canvas.Ellipse is
+
+   type Gtk_Plot_Canvas_Ellipse_Record is new Gtk_Plot_Canvas_Child_Record
+     with null record;
+   type Gtk_Plot_Canvas_Ellipse is access
+     all Gtk_Plot_Canvas_Ellipse_Record'Class;
+
+   procedure Gtk_New
+     (Child : out Gtk_Plot_Canvas_Ellipse;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Fg    : Gdk.Color.Gdk_Color;
+      Bg    : Gdk.Color.Gdk_Color;
+      Fill  : Boolean);
+   --  Creates a new ellipse child
+
+   function Get_Type return Glib.GType;
+   --  Return the internal type used for this child
+
+   procedure Set_Attributes
+     (Ellipse : access Gtk_Plot_Canvas_Ellipse_Record;
+      Style   : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width   : Gdouble;
+      Fg      : Gdk.Color.Gdk_Color;
+      Bg      : Gdk.Color.Gdk_Color;
+      Fill    : Boolean);
+   --  Change the attributes of the ellipse
+
+private
+   pragma Import (C, Get_Type, "gtk_plot_canvas_ellipse_get_type");
+end Gtk.Extra.Plot_Canvas.Ellipse;
============================================================
--- src/gtk-extra-plot_canvas-line.adb	b4035eac2f0190b9ec69d706b2a2312532e64e6d
+++ src/gtk-extra-plot_canvas-line.adb	b4035eac2f0190b9ec69d706b2a2312532e64e6d
@@ -0,0 +1,98 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gtk.Extra.Plot_Data; use Gtk.Extra.Plot_Data;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Canvas.Line is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Canvas_Line_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Child      : out Gtk_Plot_Canvas_Line;
+      Style      : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color;
+      Arrow_Mask : Plot_Canvas_Arrow)
+   is
+      function Internal
+        (Style      : Plot_Line_Style;
+         Width      : Gfloat;
+         Color      : Gdk.Color.Gdk_Color;
+         Arrow_Mask : Plot_Canvas_Arrow)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_line_new");
+   begin
+      Child := new Gtk_Plot_Canvas_Line_Record;
+      Set_Object (Child, Internal (Style, Width, Color, Arrow_Mask));
+   end Gtk_New;
+
+   ---------------
+   -- Set_Arrow --
+   ---------------
+
+   procedure Set_Arrow
+     (Line   : access Gtk_Plot_Canvas_Line_Record;
+      Style  : Plot_Symbol_Style;
+      Width  : Gfloat;
+      Length : Gfloat;
+      Mask   : Plot_Canvas_Arrow)
+   is
+      procedure Internal
+        (Line   : System.Address;
+         Style  : Plot_Symbol_Style;
+         Width  : Gfloat;
+         Length : Gfloat;
+         Mask   : Plot_Canvas_Arrow);
+      pragma Import (C, Internal, "gtk_plot_canvas_line_set_arrow");
+   begin
+      Internal (Get_Object (Line), Style, Width, Length, Mask);
+   end Set_Arrow;
+
+   --------------------
+   -- Set_Attributes --
+   --------------------
+
+   procedure Set_Attributes
+     (Line  : access Gtk_Plot_Canvas_Line_Record;
+      Style : Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Line  : System.Address;
+         Style : Plot_Line_Style;
+         Width : Gfloat;
+         Color : Gdk.Color.Gdk_Color);
+      pragma Import (C, Internal, "gtk_plot_canvas_line_set_attributes");
+   begin
+      Internal (Get_Object (Line), Style, Width, Color);
+   end Set_Attributes;
+
+end Gtk.Extra.Plot_Canvas.Line;
============================================================
--- src/gtk-extra-plot_canvas-line.ads	2f9e9db0d5cdf7aa649656c634e1e4e366722605
+++ src/gtk-extra-plot_canvas-line.ads	2f9e9db0d5cdf7aa649656c634e1e4e366722605
@@ -0,0 +1,71 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk.Color;
+with Gtk.Extra.Plot_Data;
+
+package Gtk.Extra.Plot_Canvas.Line is
+
+   type Gtk_Plot_Canvas_Line_Record is new Gtk_Plot_Canvas_Child_Record
+     with null record;
+   type Gtk_Plot_Canvas_Line is access all Gtk_Plot_Canvas_Line_Record'Class;
+
+   type Plot_Canvas_Arrow is new Gint;
+   Arrow_None   : constant Plot_Canvas_Arrow := 0;
+   Arrow_Origin : constant Plot_Canvas_Arrow := 1;
+   Arrow_End    : constant Plot_Canvas_Arrow := 2;
+
+   procedure Gtk_New
+     (Child      : out Gtk_Plot_Canvas_Line;
+      Style      : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color;
+      Arrow_Mask : Plot_Canvas_Arrow);
+   --  Create a new line child
+
+   function Get_Type return Glib.GType;
+   --  Return the internal type used for this child
+
+   procedure Set_Arrow
+     (Line   : access Gtk_Plot_Canvas_Line_Record;
+      Style  : Gtk.Extra.Plot_Data.Plot_Symbol_Style;
+      Width  : Gfloat;
+      Length : Gfloat;
+      Mask   : Plot_Canvas_Arrow);
+   --  Change the arrow style for this line
+
+   procedure Set_Attributes
+     (Line  : access Gtk_Plot_Canvas_Line_Record;
+      Style : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width : Gfloat;
+      Color : Gdk.Color.Gdk_Color);
+   --  Change the attributes of the line
+
+private
+   pragma Import (C, Get_Type, "gtk_plot_canvas_line_get_type");
+end Gtk.Extra.Plot_Canvas.Line;
============================================================
--- src/gtk-extra-plot_canvas-pixmap.adb	bdd26c4848ef1c1c576aeb307f34a106c5d581ef
+++ src/gtk-extra-plot_canvas-pixmap.adb	bdd26c4848ef1c1c576aeb307f34a106c5d581ef
@@ -0,0 +1,58 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+
+with Gdk.Bitmap;           use Gdk.Bitmap;
+with Gdk.Pixmap;           use Gdk.Pixmap;
+with System;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Canvas.Pixmap is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Canvas_Pixmap_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Child    : out Gtk_Plot_Canvas_Pixmap;
+      Pixmap   : Gdk.Pixmap.Gdk_Pixmap;
+      Mask     : Gdk.Bitmap.Gdk_Bitmap)
+   is
+      function Internal
+        (Pixmap : Gdk.Pixmap.Gdk_Pixmap; Mask : Gdk.Bitmap.Gdk_Bitmap)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_pixmap_new");
+   begin
+      Child := new Gtk_Plot_Canvas_Pixmap_Record;
+      Set_Object (Child, Internal (Pixmap, Mask));
+   end Gtk_New;
+
+end Gtk.Extra.Plot_Canvas.Pixmap;
============================================================
--- src/gtk-extra-plot_canvas-pixmap.ads	adc349d259728e358e53cfb566ae40394200de5f
+++ src/gtk-extra-plot_canvas-pixmap.ads	adc349d259728e358e53cfb566ae40394200de5f
@@ -0,0 +1,52 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk.Bitmap;
+with Gdk.Pixmap;
+
+package Gtk.Extra.Plot_Canvas.Pixmap is
+
+   type Gtk_Plot_Canvas_Pixmap_Record is new Gtk_Plot_Canvas_Child_Record
+     with private;
+   type Gtk_Plot_Canvas_Pixmap is access
+     all Gtk_Plot_Canvas_Pixmap_Record'Class;
+
+   procedure Gtk_New
+     (Child    : out Gtk_Plot_Canvas_Pixmap;
+      Pixmap   : Gdk.Pixmap.Gdk_Pixmap;
+      Mask     : Gdk.Bitmap.Gdk_Bitmap);
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Plot.
+
+private
+   type Gtk_Plot_Canvas_Pixmap_Record is new Gtk_Plot_Canvas_Child_Record
+      with null record;
+
+   pragma Import (C, Get_Type, "gtk_plot_canvas_pixmap_get_type");
+end Gtk.Extra.Plot_Canvas.Pixmap;
============================================================
--- src/gtk-extra-plot_canvas-plot.adb	43102ab60118f53a63f99d861ab6a371a063bb47
+++ src/gtk-extra-plot_canvas-plot.adb	43102ab60118f53a63f99d861ab6a371a063bb47
@@ -0,0 +1,113 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+with Gtk.Extra.Plot_Data; use Gtk.Extra.Plot_Data;
+
+package body Gtk.Extra.Plot_Canvas.Plot is
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Child    : out Gtk_Plot_Canvas_Plot;
+      Plot     : access Gtk.Extra.Plot.Gtk_Plot_Record'Class)
+   is
+      function Internal (Plot : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_plot_new");
+   begin
+      Child := new Gtk_Plot_Canvas_Plot_Record;
+      Set_Object (Child, Internal (Get_Object (Plot)));
+   end Gtk_New;
+
+   -------------
+   -- Get_Pos --
+   -------------
+
+   function Get_Pos
+     (Child : access Gtk_Plot_Canvas_Plot_Record) return Plot_Canvas_Plot_Pos
+   is
+      function Internal (Child : System.Address) return Plot_Canvas_Plot_Pos;
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_plot_get_pos");
+   begin
+      return Internal (Get_Object (Child));
+   end Get_Pos;
+
+   --------------
+   -- Get_Data --
+   --------------
+
+   function Get_Data
+     (Child : access Gtk_Plot_Canvas_Plot_Record)
+      return Gtk.Extra.Plot_Data.Gtk_Plot_Data
+   is
+      function Internal (Child : System.Address) return System.Address;
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_plot_get_data");
+      Stub : Gtk_Plot_Data_Record;
+   begin
+      return Gtk_Plot_Data
+        (Get_User_Data (Internal (Get_Object (Child)), Stub));
+   end Get_Data;
+
+   -------------------
+   -- Get_Datapoint --
+   -------------------
+
+   function Get_Datapoint
+     (Child : access Gtk_Plot_Canvas_Plot_Record) return Gint
+   is
+      function Internal (Child : System.Address) return Gint;
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_plot_get_datapoint");
+   begin
+      return Internal (Get_Object (Child));
+   end Get_Datapoint;
+
+   ---------------
+   -- Set_Flags --
+   ---------------
+
+   procedure Set_Flags
+     (Child : access Gtk_Plot_Canvas_Plot_Record;
+      Flags : Plot_Canvas_Plot_Flags)
+   is
+      procedure Internal (Child : System.Address; Flags : Integer);
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_plot_set_flags");
+   begin
+      Internal (Get_Object (Child), Integer (Flags));
+   end Set_Flags;
+
+   -----------------
+   -- Unset_Flags --
+   -----------------
+
+   procedure Unset_Flags
+     (Child : access Gtk_Plot_Canvas_Plot_Record;
+      Flags : Plot_Canvas_Plot_Flags)
+   is
+      procedure Internal (Child : System.Address; Flags : Integer);
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_plot_unset_flags");
+   begin
+      Internal (Get_Object (Child), Integer (Flags));
+   end Unset_Flags;
+
+end Gtk.Extra.Plot_Canvas.Plot;
============================================================
--- src/gtk-extra-plot_canvas-plot.ads	2f85637afa155f748d8919cceae6a45b4acabfab
+++ src/gtk-extra-plot_canvas-plot.ads	2f85637afa155f748d8919cceae6a45b4acabfab
@@ -0,0 +1,85 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gtk.Extra.Plot;
+with Gtk.Extra.Plot_Data;
+
+package Gtk.Extra.Plot_Canvas.Plot is
+
+   type Gtk_Plot_Canvas_Plot_Record is new Gtk_Plot_Canvas_Child_Record
+     with private;
+   type Gtk_Plot_Canvas_Plot is access all Gtk_Plot_Canvas_Plot_Record'Class;
+
+   type Plot_Canvas_Plot_Pos is
+     (Plot_Out,
+      Plot_In_Plot,
+      Plot_In_Legends,
+      Plot_In_Title,
+      Plot_In_Axis,
+      Plot_In_Data,
+      Plot_In_Gradient,
+      Plot_In_Marker);
+   --  The various parts of a plot in which a user can click
+
+   procedure Gtk_New
+     (Child    : out Gtk_Plot_Canvas_Plot;
+      Plot     : access Gtk.Extra.Plot.Gtk_Plot_Record'Class);
+   --  Create a new plot child, wrapping Plot
+
+   function Get_Pos
+     (Child : access Gtk_Plot_Canvas_Plot_Record) return Plot_Canvas_Plot_Pos;
+   --  Return the position in the plot where the user has last clicked
+
+   function Get_Data
+     (Child : access Gtk_Plot_Canvas_Plot_Record)
+      return Gtk.Extra.Plot_Data.Gtk_Plot_Data;
+   --  Return the data associated with Child
+
+   function Get_Datapoint
+     (Child : access Gtk_Plot_Canvas_Plot_Record) return Gint;
+   --  Return the point in the plot data that was selected by the user
+
+   type Plot_Canvas_Plot_Flags is mod 2 ** 8;
+   Flags_Select_Point : constant Plot_Canvas_Plot_Flags := 2 ** 0;
+   Flags_Dnd_Point    : constant Plot_Canvas_Plot_Flags := 2 ** 1;
+   --  Flags specific to a Gtk_Plot_Canvas_Plot
+
+   procedure Set_Flags
+     (Child : access Gtk_Plot_Canvas_Plot_Record;
+      Flags : Plot_Canvas_Plot_Flags);
+   procedure Unset_Flags
+     (Child : access Gtk_Plot_Canvas_Plot_Record;
+      Flags : Plot_Canvas_Plot_Flags);
+   --  Set or Unset specific flags from Child
+
+private
+   pragma Convention (C, Plot_Canvas_Plot_Pos);
+
+   type Gtk_Plot_Canvas_Plot_Record is new Gtk_Plot_Canvas_Child_Record
+     with null record;
+end Gtk.Extra.Plot_Canvas.Plot;
============================================================
--- src/gtk-extra-plot_canvas-rectangle.adb	682c49766a2302dbae99fc4eb23f9c5c4be0cd65
+++ src/gtk-extra-plot_canvas-rectangle.adb	682c49766a2302dbae99fc4eb23f9c5c4be0cd65
@@ -0,0 +1,90 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gdk.Color;           use Gdk.Color;
+with Gtk.Extra.Plot;      use Gtk.Extra.Plot;
+with Gtk.Extra.Plot_Data; use Gtk.Extra.Plot_Data;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Canvas.Rectangle is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Canvas_Rectangle_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Child       : out Gtk_Plot_Canvas_Rectangle;
+      Style       : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Line_Width  : Gfloat;
+      Fg          : Gdk.Color.Gdk_Color;
+      Bg          : Gdk.Color.Gdk_Color;
+      Border      : Gtk.Extra.Plot.Plot_Border_Style;
+      Fill        : Boolean)
+   is
+      function Internal
+        (Style  : Plot_Line_Style;
+         Width  : Gfloat;
+         Fg     : Gdk_Color;
+         Bg     : Gdk_Color;
+         Border : Plot_Border_Style;
+         Fill   : Gboolean)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_rectangle_new");
+   begin
+      Child := new Gtk_Plot_Canvas_Rectangle_Record;
+      Set_Object (Child, Internal (Style, Line_Width, Fg, Bg, Border,
+                                   Boolean'Pos (Fill)));
+   end Gtk_New;
+
+   --------------------
+   -- Set_Attributes --
+   --------------------
+
+   procedure Set_Attributes
+     (Rectangle : access Gtk_Plot_Canvas_Rectangle_Record;
+      Style     : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width     : Gfloat;
+      Fg        : Gdk.Color.Gdk_Color;
+      Bg        : Gdk.Color.Gdk_Color;
+      Border    : Gtk.Extra.Plot.Plot_Border_Style;
+      Fill      : Boolean)
+   is
+      procedure Internal
+        (Rectangle : System.Address;
+         Style     : Plot_Line_Style;
+         Width     : Gfloat;
+         Fg        : Gdk_Color;
+         Bg        : Gdk_Color;
+         Border    : Plot_Border_Style;
+         Fill      : Gboolean);
+      pragma Import (C, Internal, "gtk_plot_canvas_rectangle_set_attributes");
+   begin
+      Internal (Get_Object (Rectangle), Style, Width, Fg, Bg, Border,
+                Boolean'Pos (Fill));
+   end Set_Attributes;
+
+end Gtk.Extra.Plot_Canvas.Rectangle;
============================================================
--- src/gtk-extra-plot_canvas-rectangle.ads	c963391494dbb94f7d0e7ed1e8f376c59c295673
+++ src/gtk-extra-plot_canvas-rectangle.ads	c963391494dbb94f7d0e7ed1e8f376c59c295673
@@ -0,0 +1,64 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk.Color;
+with Gtk.Extra.Plot;
+
+package Gtk.Extra.Plot_Canvas.Rectangle is
+
+   type Gtk_Plot_Canvas_Rectangle_Record is new Gtk_Plot_Canvas_Child_Record
+     with null record;
+   type Gtk_Plot_Canvas_Rectangle is access
+     all Gtk_Plot_Canvas_Rectangle_Record'Class;
+
+   procedure Gtk_New
+     (Child       : out Gtk_Plot_Canvas_Rectangle;
+      Style       : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Line_Width  : Gfloat;
+      Fg          : Gdk.Color.Gdk_Color;
+      Bg          : Gdk.Color.Gdk_Color;
+      Border      : Gtk.Extra.Plot.Plot_Border_Style;
+      Fill        : Boolean);
+   --  Creates a new rectangle child
+
+   function Get_Type return Glib.GType;
+   --  Return the internal type used for this child
+
+   procedure Set_Attributes
+     (Rectangle : access Gtk_Plot_Canvas_Rectangle_Record;
+      Style     : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width     : Gfloat;
+      Fg        : Gdk.Color.Gdk_Color;
+      Bg        : Gdk.Color.Gdk_Color;
+      Border    : Gtk.Extra.Plot.Plot_Border_Style;
+      Fill      : Boolean);
+   --  Change the attributes of the rectangle
+
+private
+   pragma Import (C, Get_Type, "gtk_plot_canvas_rectangle_get_type");
+end Gtk.Extra.Plot_Canvas.Rectangle;
============================================================
--- src/gtk-extra-plot_canvas-text.adb	2837b3804a0cd59f24e3d059ea1844f854483e19
+++ src/gtk-extra-plot_canvas-text.adb	2837b3804a0cd59f24e3d059ea1844f854483e19
@@ -0,0 +1,118 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gtkada.Bindings;      use Gtkada.Bindings;
+with Gdk.Color;            use Gdk.Color;
+with Gtk.Enums;            use Gtk.Enums;
+with Gtk.Extra.Plot_Data;  use Gtk.Extra.Plot_Data;
+with Interfaces.C.Strings; use Interfaces.C.Strings;
+with System;
+
+package body Gtk.Extra.Plot_Canvas.Text is
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Child    : out Gtk_Plot_Canvas_Text;
+      Text     : String;
+      Font     : String := "";
+      Height   : Gint := 0;
+      Angle    : Gtk.Extra.Plot_Data.Plot_Angle := Gtk.Extra.Plot_Data.Angle_0;
+      Fg       : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Bg            : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Transparent   : Boolean := True;
+      Justification : Gtk.Enums.Gtk_Justification := Gtk.Enums.Justify_Center)
+   is
+      function Internal
+        (Font : chars_ptr; Height : Gint; Angle : Plot_Angle;
+         Fg, Bg : System.Address;
+         Transparent : Gboolean;
+         Justification : Gtk_Justification;
+         Text : String) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_text_new");
+
+      F1   : aliased Gdk_Color := Fg;
+      B1   : aliased Gdk_Color := Bg;
+      F, B : System.Address := System.Null_Address;
+      T    : chars_ptr := String_Or_Null (Font);
+
+   begin
+      if Fg /= Null_Color then
+         F := F1'Address;
+      end if;
+      if Bg /= Null_Color then
+         B := B1'Address;
+      end if;
+
+      Child := new Gtk_Plot_Canvas_Text_Record;
+      Set_Object
+        (Child, Internal
+           (T, Height, Angle, F, B,
+            Boolean'Pos (Transparent), Justification,
+            Text & ASCII.NUL));
+      Free (T);
+   end Gtk_New;
+
+   --------------------
+   -- Set_Attributes --
+   --------------------
+
+   procedure Set_Attributes
+     (Child         : access Gtk_Plot_Canvas_Text_Record;
+      Font          : String := "";
+      Height        : Gint;
+      Angle         : Gtk.Extra.Plot_Data.Plot_Angle;
+      Fg            : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Bg            : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Transparent   : Boolean;
+      Justification : Gtk.Enums.Gtk_Justification;
+      Text          : String)
+   is
+      procedure Internal
+        (Child         : System.Address;
+         Font          : chars_ptr;
+         Height        : Gint;
+         Angle         : Plot_Angle;
+         Fg, Bg        : System.Address;
+         Transparent   : Gboolean;
+         Justification : Gtk_Justification;
+         Text          : String);
+      pragma Import (C, Internal, "gtk_plot_canvas_text_set_attributes");
+      F1   : aliased Gdk_Color := Fg;
+      B1   : aliased Gdk_Color := Bg;
+      F, B : System.Address := System.Null_Address;
+      T    : chars_ptr := String_Or_Null (Font);
+   begin
+      if Fg /= Null_Color then
+         F := F1'Address;
+      end if;
+      if Bg /= Null_Color then
+         B := B1'Address;
+      end if;
+      Internal (Get_Object (Child), T, Height, Angle, F, B,
+                Boolean'Pos (Transparent), Justification, Text & ASCII.NUL);
+      Free (T);
+   end Set_Attributes;
+
+end Gtk.Extra.Plot_Canvas.Text;
============================================================
--- src/gtk-extra-plot_canvas-text.ads	7e0d5ffa8fd3c982602dea115940e96b5f33f70f
+++ src/gtk-extra-plot_canvas-text.ads	7e0d5ffa8fd3c982602dea115940e96b5f33f70f
@@ -0,0 +1,68 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of child that can be put in a Gtk_Plot_Canvas.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk.Color;
+with Gtk.Enums;
+with Gtk.Extra.Plot_Data;
+
+package Gtk.Extra.Plot_Canvas.Text is
+
+   type Gtk_Plot_Canvas_Text_Record is new Gtk_Plot_Canvas_Child_Record
+     with private;
+   type Gtk_Plot_Canvas_Text is access all Gtk_Plot_Canvas_Text_Record'Class;
+
+   procedure Gtk_New
+     (Child    : out Gtk_Plot_Canvas_Text;
+      Text     : String;
+      Font     : String := "";
+      Height   : Gint := 0;
+      Angle    : Gtk.Extra.Plot_Data.Plot_Angle := Gtk.Extra.Plot_Data.Angle_0;
+      Fg       : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Bg            : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Transparent   : Boolean := True;
+      Justification : Gtk.Enums.Gtk_Justification := Gtk.Enums.Justify_Center);
+   --  Create a new text child.
+   --  If default values are used, the corresponding attribute isn't set
+
+   procedure Set_Attributes
+     (Child         : access Gtk_Plot_Canvas_Text_Record;
+      Font          : String := "";
+      Height        : Gint;
+      Angle         : Gtk.Extra.Plot_Data.Plot_Angle;
+      Fg            : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Bg            : Gdk.Color.Gdk_Color := Gdk.Color.Null_Color;
+      Transparent   : Boolean;
+      Justification : Gtk.Enums.Gtk_Justification;
+      Text          : String);
+   --  Change the attribute of Text. The attributes with their default
+   --  values are not changed.
+
+private
+   type Gtk_Plot_Canvas_Text_Record is new Gtk_Plot_Canvas_Child_Record
+     with null record;
+end Gtk.Extra.Plot_Canvas.Text;
============================================================
--- src/gtk-extra-plot_canvas.adb	6f4bf477777c86f8dcc38d97d92d531fe6df6833
+++ src/gtk-extra-plot_canvas.adb	6f4bf477777c86f8dcc38d97d92d531fe6df6833
@@ -0,0 +1,500 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                     Copyright (C) 2000                            --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--               Copyright (C) 2001-2008, AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+with Gdk.Color;           use Gdk.Color;
+with Gtk.Extra.Plot_Data; use Gtk.Extra.Plot_Data;
+with Glib.Type_Conversion_Hooks;
+pragma Elaborate_All (Glib.Type_Conversion_Hooks);
+
+package body Gtk.Extra.Plot_Canvas is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Canvas_Record);
+   pragma Warnings (Off, Type_Conversion);
+   --  This package is used to implement a minimal automated type conversion
+   --  without having to drag the whole Gtk.Type_Conversion package for the
+   --  most common widgets.
+
+   -------------------
+   -- Cancel_Action --
+   -------------------
+
+   procedure Cancel_Action (Plot_Canvas : access Gtk_Plot_Canvas_Record)
+   is
+      procedure Internal (Plot_Canvas : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_cancel_action");
+   begin
+      Internal (Get_Object (Plot_Canvas));
+   end Cancel_Action;
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Widget        : out Gtk_Plot_Canvas;
+      Width         : Gint;
+      Height        : Gint;
+      Magnification : Gdouble := 1.0)
+   is
+   begin
+      Widget := new Gtk_Plot_Canvas_Record;
+      Initialize (Widget, Width, Height, Magnification);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Widget        : access Gtk_Plot_Canvas_Record'Class;
+      Width         : Gint;
+      Height        : Gint;
+      Magnification : Gdouble := 1.0)
+   is
+      function Internal (Width         : Gint;
+                         Height        : Gint;
+                         Magnification : Gdouble)
+                        return      System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_new");
+   begin
+      Set_Object (Widget, Internal (Width, Height, Magnification));
+   end Initialize;
+
+   -----------------------------
+   -- Plot_Canvas_Flag_Is_Set --
+   -----------------------------
+
+   function Plot_Canvas_Flag_Is_Set
+     (Plot_Canvas : access Gtk_Plot_Canvas_Record;
+      Flag        : Guint16)
+     return Boolean
+   is
+      function Internal (Canvas : System.Address;
+                         Flag   : Guint16)
+                        return Guint16;
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_flag_is_set");
+   begin
+      return Internal (Get_Object (Plot_Canvas), Flag) /= 0;
+   end Plot_Canvas_Flag_Is_Set;
+
+   ---------------------------
+   -- Set_Plot_Canvas_Flags --
+   ---------------------------
+
+   procedure Plot_Canvas_Set_Flags
+     (Plot_Canvas  : access Gtk_Plot_Canvas_Record;
+      Flags        : Guint16)
+   is
+      procedure Internal (Canvas : System.Address;
+                          Flags  : Guint16);
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_set_flags");
+   begin
+      Internal (Get_Object (Plot_Canvas), Flags);
+   end Plot_Canvas_Set_Flags;
+
+   -----------------------------
+   -- Plot_Canvas_Unset_Flags --
+   -----------------------------
+
+   procedure Plot_Canvas_Unset_Flags
+     (Plot_Canvas  : access Gtk_Plot_Canvas_Record;
+      Flags        : Guint16)
+   is
+      procedure Internal (Canvas : System.Address;
+                          Flags  : Guint16);
+      pragma Import (C, Internal, "ada_gtk_plot_canvas_unset_flags");
+   begin
+      Internal (Get_Object (Plot_Canvas), Flags);
+   end Plot_Canvas_Unset_Flags;
+
+   --------------
+   -- Set_Size --
+   --------------
+
+   procedure Set_Size (Canvas  : access Gtk_Plot_Canvas_Record;
+                       Width   : Gint;
+                       Height  : Gint)
+   is
+      procedure Internal (Canvas : System.Address;
+                          Width  : Gint;
+                          Height : Gint);
+      pragma Import (C, Internal, "gtk_plot_canvas_set_size");
+   begin
+      Internal (Get_Object (Canvas), Width, Height);
+   end Set_Size;
+
+   -------------
+   -- Refresh --
+   -------------
+
+   procedure Refresh (Canvas : access Gtk_Plot_Canvas_Record) is
+      procedure Internal (Canvas : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_refresh");
+   begin
+      Internal (Get_Object (Canvas));
+   end Refresh;
+
+   --------------
+   -- Unselect --
+   --------------
+
+   procedure Unselect (Canvas : access Gtk_Plot_Canvas_Record) is
+      procedure Internal (Canvas : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_unselect");
+   begin
+      Internal (Get_Object (Canvas));
+   end Unselect;
+
+   ---------------------
+   -- Get_Active_Item --
+   ---------------------
+
+   function Get_Active_Item (Canvas  : access Gtk_Plot_Canvas_Record)
+                            return Gtk_Plot_Canvas_Child
+   is
+      function Internal (Canvas : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_canvas_get_active_item");
+      Stub : Gtk_Plot_Canvas_Child_Record;
+   begin
+      return Gtk_Plot_Canvas_Child
+        (Get_User_Data (Internal (Get_Object (Canvas)), Stub));
+   end Get_Active_Item;
+
+   ----------------------
+   -- Grid_Set_Visible --
+   ----------------------
+
+   procedure Grid_Set_Visible (Canvas  : access Gtk_Plot_Canvas_Record;
+                               Visible : Boolean)
+   is
+      procedure Internal (Canvas  : System.Address;
+                          Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_canvas_grid_set_visible");
+   begin
+      Internal (Get_Object (Canvas), Boolean'Pos (Visible));
+   end Grid_Set_Visible;
+
+   -------------------
+   -- Grid_Set_Step --
+   -------------------
+
+   procedure Grid_Set_Step (Canvas : access Gtk_Plot_Canvas_Record;
+                            Step   : Gdouble)
+   is
+      procedure Internal (Canvas : System.Address;
+                          Step   : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_grid_set_step");
+   begin
+      Internal (Get_Object (Canvas), Step);
+   end Grid_Set_Step;
+
+   -------------------------
+   -- Grid_Set_Attributes --
+   -------------------------
+
+   procedure Grid_Set_Attributes
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Style  : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width  : Gint;
+      Color  : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Canvas : System.Address;
+         Style  : Gtk.Extra.Plot_Data.Plot_Line_Style;
+         Width  : Gint;
+         Color  : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_grid_set_attributes");
+
+      Col : aliased Gdk.Color.Gdk_Color := Color;
+      Cola : System.Address := Col'Address;
+
+   begin
+      if Color = Gdk.Color.Null_Color then
+         Cola := System.Null_Address;
+      end if;
+      Internal (Get_Object (Canvas), Style, Width, Cola);
+   end Grid_Set_Attributes;
+
+   -----------------------
+   -- Set_Magnification --
+   -----------------------
+
+   procedure Set_Magnification
+     (Canvas        : access Gtk_Plot_Canvas_Record;
+      Magnification : Gdouble := 1.0)
+   is
+      procedure Internal (Canvas : System.Address;
+                          Magnification : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_set_magnification");
+   begin
+      Internal (Get_Object (Canvas), Magnification);
+   end Set_Magnification;
+
+   --------------------
+   -- Set_Background --
+   --------------------
+
+   procedure Set_Background
+     (Canvas     : access Gtk_Plot_Canvas_Record;
+      Background : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Canvas : System.Address; Color  : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_set_background");
+      Col : aliased Gdk.Color.Gdk_Color := Background;
+      Cola : System.Address := Col'Address;
+   begin
+      if Background = Gdk.Color.Null_Color then
+         Cola := System.Null_Address;
+      end if;
+      Internal (Get_Object (Canvas), Cola);
+   end Set_Background;
+
+   ---------------
+   -- Get_Pixel --
+   ---------------
+
+   procedure Get_Pixel
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Px     : Gdouble;
+      Py     : Gdouble;
+      X      : out Gint;
+      Y      : out Gint)
+   is
+      procedure Internal (Canvas : System.Address;
+                          Px     : Gdouble;
+                          Py     : Gdouble;
+                          X      : out Gint;
+                          Y      : out Gint);
+      pragma Import (C, Internal, "gtk_plot_canvas_get_pixel");
+   begin
+      Internal (Get_Object (Canvas), Px, Py, X, Y);
+   end Get_Pixel;
+
+   ------------------
+   -- Get_Position --
+   ------------------
+
+   procedure Get_Position
+      (Canvas : access Gtk_Plot_Canvas_Record;
+       X      : Gint;
+       Y      : Gint;
+       Px     : out Gdouble;
+       Py     : out Gdouble)
+   is
+      procedure Internal
+         (Canvas : System.Address;
+          X      : Gint;
+          Y      : Gint;
+          Px     : out Gdouble;
+          Py     : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_get_position");
+   begin
+      Internal (Get_Object (Canvas), X, Y, Px, Py);
+   end Get_Position;
+
+   ---------------
+   -- Put_Child --
+   ---------------
+
+   procedure Put_Child
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1     : Gdouble;
+      Y1     : Gdouble;
+      X2     : Gdouble := 0.0;
+      Y2     : Gdouble := 0.0)
+   is
+      procedure Internal
+        (Canvas : System.Address;
+         Child  : System.Address;
+         X1, Y1, X2, Y2 : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_put_child");
+   begin
+      Internal (Get_Object (Canvas), Get_Object (Child), X1, Y1, X2, Y2);
+   end Put_Child;
+
+   ----------------
+   -- Child_Move --
+   ----------------
+
+   procedure Child_Move
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1     : Gdouble;
+      Y1     : Gdouble)
+   is
+      procedure Internal
+        (Canvas : System.Address;
+         Child  : System.Address;
+         X1, Y1 : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_child_move");
+   begin
+      Internal (Get_Object (Canvas), Get_Object (Child), X1, Y1);
+   end Child_Move;
+
+   -----------------------
+   -- Child_Move_Resize --
+   -----------------------
+
+   procedure Child_Move_Resize
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1     : Gdouble;
+      Y1     : Gdouble;
+      X2     : Gdouble;
+      Y2     : Gdouble)
+   is
+      procedure Internal
+        (Canvas : System.Address;
+         Child  : System.Address;
+         X1, Y1, X2, Y2 : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_child_move_resize");
+   begin
+      Internal (Get_Object (Canvas), Get_Object (Child), X1, Y1, X2, Y2);
+   end Child_Move_Resize;
+
+   -----------
+   -- Paint --
+   -----------
+
+   procedure Paint (Canvas : access Gtk_Plot_Canvas_Record) is
+      procedure Internal (Canvas : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_paint");
+   begin
+      Internal (Get_Object (Canvas));
+   end Paint;
+
+   ------------
+   -- Freeze --
+   ------------
+
+   procedure Freeze (Canvas : access Gtk_Plot_Canvas_Record) is
+      procedure Internal (Canvas : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_freeze");
+   begin
+      Internal (Get_Object (Canvas));
+   end Freeze;
+
+   ----------
+   -- Thaw --
+   ----------
+
+   procedure Thaw (Canvas : access Gtk_Plot_Canvas_Record) is
+      procedure Internal (Canvas : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_thaw");
+   begin
+      Internal (Get_Object (Canvas));
+   end Thaw;
+
+   ---------------------
+   -- Set_Transparent --
+   ---------------------
+
+   procedure Set_Transparent
+     (Canvas : access Gtk_Plot_Canvas_Record; Transparent : Boolean)
+   is
+      procedure Internal (Canvas : System.Address; Transparent : Integer);
+      pragma Import (C, Internal, "gtk_plot_canvas_set_transparent");
+   begin
+      Internal (Get_Object (Canvas), Boolean'Pos (Transparent));
+   end Set_Transparent;
+
+   -----------------
+   -- Transparent --
+   -----------------
+
+   function Transparent
+     (Canvas : access Gtk_Plot_Canvas_Record) return Boolean
+   is
+      function Internal (Canvas : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_plot_canvas_transparent");
+   begin
+      return Boolean'Val (Internal (Get_Object (Canvas)));
+   end Transparent;
+
+   ------------------
+   -- Remove_Child --
+   ------------------
+
+   procedure Remove_Child
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class)
+   is
+      procedure Internal (C : System.Address; Child : System.Address);
+      pragma Import (C, Internal, "gtk_plot_canvas_remove_child");
+   begin
+      Internal (Get_Object (Canvas), Get_Object (Child));
+   end Remove_Child;
+
+   -------------------
+   -- Set_Selection --
+   -------------------
+
+   procedure Set_Selection
+     (Child     : access Gtk_Plot_Canvas_Child_Record;
+      Selection : Plot_Canvas_Selection)
+   is
+      procedure Internal
+        (Child : System.Address; Selection : Plot_Canvas_Selection);
+      pragma Import (C, Internal, "gtk_plot_canvas_child_set_selection");
+   begin
+      Internal (Get_Object (Child), Selection);
+   end Set_Selection;
+
+   ------------------------
+   -- Set_Selection_Mode --
+   ------------------------
+
+   procedure Set_Selection_Mode
+     (Child     : access Gtk_Plot_Canvas_Child_Record;
+      Mode      : Plot_Canvas_Selection_Mode)
+   is
+      procedure Internal
+        (Child : System.Address; Selection : Plot_Canvas_Selection_Mode);
+      pragma Import (C, Internal, "gtk_plot_canvas_child_set_selection_mode");
+   begin
+      Internal (Get_Object (Child), Mode);
+   end Set_Selection_Mode;
+
+   ------------------
+   -- Get_Position --
+   ------------------
+
+   procedure Get_Position
+     (Canvas    : access Gtk_Plot_Canvas_Record;
+      Child     : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1, Y1    : out Gdouble;
+      X2, Y2    : out Gdouble)
+   is
+      procedure Internal
+        (Canvas, Child : System.Address;
+         X1, Y1, X2, Y2 : out Gdouble);
+      pragma Import (C, Internal, "gtk_plot_canvas_child_get_position");
+   begin
+      Internal (Get_Object (Canvas), Get_Object (Child), X1, Y1, X2, Y2);
+   end Get_Position;
+
+end Gtk.Extra.Plot_Canvas;
============================================================
--- src/gtk-extra-plot_canvas.ads	06e39bbcbef0276629e6a59e44c00ec8a0f58dc2
+++ src/gtk-extra-plot_canvas.ads	06e39bbcbef0276629e6a59e44c00ec8a0f58dc2
@@ -0,0 +1,392 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Plot_Canvas is a special kind of drawing area used with Gtk_Plot
+--  widgets.
+--  It provides drag-and-drop capabilities for the texts, legends, points...
+--  available in a Gtk_Plot.
+--  Note that this widget is specifically designed for Gtk_Plot widgets, and
+--  won't provide any other capability for other kinds of widgets.
+--
+--  Like any child of Gtk_Layout, this widget can have an almost unlimited
+--  size for its children, and provides scrolling.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk;
+with Gtk.Extra.Plot_Data;
+with Gtk.Fixed;
+with Gtk.Object;
+with Gdk.Color;
+
+package Gtk.Extra.Plot_Canvas is
+
+   type Gtk_Plot_Canvas_Record is new Gtk.Fixed.Gtk_Fixed_Record with private;
+   type Gtk_Plot_Canvas is access all Gtk_Plot_Canvas_Record'Class;
+
+   type Gtk_Plot_Canvas_Child_Record is
+     new Gtk.Object.Gtk_Object_Record with private;
+   type Gtk_Plot_Canvas_Child is access all Gtk_Plot_Canvas_Child_Record'Class;
+
+   ----------------
+   -- Enum types --
+   ----------------
+
+   type Plot_Canvas_Action is
+     (Action_Inactive,
+      Action_Selection,
+      Action_Drag,
+      Action_Resize);
+   --  The action being performed on the canvas.
+   pragma Convention (C, Plot_Canvas_Action);
+
+   type Plot_Canvas_Flag is new Gint;
+   Frozen     : constant Plot_Canvas_Flag;
+   Can_Move   : constant Plot_Canvas_Flag;
+   Can_Resize : constant Plot_Canvas_Flag;
+
+   type Plot_Canvas_Selection is
+     (Select_None,
+      Select_Markers,
+      Select_Target);
+   pragma Convention (C, Plot_Canvas_Selection);
+
+   type Plot_Canvas_Pos is
+     (Canvas_Out,
+      Canvas_In,
+      Canvas_Left,
+      Canvas_Right,
+      Canvas_Top,
+      Canvas_Bottom,
+      Canvas_Top_Left,
+      Canvas_Top_Right,
+      Canvas_Bottom_Left,
+      Canvas_Bottom_Right);
+   --  The position of the items in the canvas.
+   pragma Convention (C, Plot_Canvas_Pos);
+
+   type Plot_Canvas_Selection_Mode is
+     (Select_Click_1,
+      Select_Click_2);
+   pragma Convention (C, Plot_Canvas_Selection_Mode);
+
+   ------------------------------------------
+   -- Creating and manipulating the canvas --
+   ------------------------------------------
+
+   procedure Gtk_New
+     (Widget        : out Gtk_Plot_Canvas;
+      Width         : Gint;
+      Height        : Gint;
+      Magnification : Gdouble := 1.0);
+   --  Create a new Gtk_Plot_Canvas, with a specific screen size.
+   --  Since the widget can have an unlimited internal size, it does not try
+   --  to set its size to accommodate all of its children.
+
+   procedure Initialize
+     (Widget        : access Gtk_Plot_Canvas_Record'Class;
+      Width         : Gint;
+      Height        : Gint;
+      Magnification : Gdouble := 1.0);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Plot_Canvas.
+
+   function Child_Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Plot_Canvas_Child.
+
+   procedure Refresh (Canvas : access Gtk_Plot_Canvas_Record);
+   --  Force a refresh of the canvas on the screen. The screen is updated from
+   --  the contents of the double-buffer.
+
+   procedure Paint (Canvas : access Gtk_Plot_Canvas_Record);
+   --  Redraw each of the items included in the canvas. The painting is done
+   --  in the double-buffer, and must be drawn on the screen with Refresh.
+
+   procedure Freeze (Canvas : access Gtk_Plot_Canvas_Record);
+   --  Freeze all graphical updates to the screen. This significanly speeds up
+   --  the updates to the plot
+
+   procedure Thaw (Canvas : access Gtk_Plot_Canvas_Record);
+   --  Reactivate all graphical updates to the screen
+
+   procedure Grid_Set_Visible
+     (Canvas  : access Gtk_Plot_Canvas_Record;
+      Visible : Boolean);
+   --  Indicate whether the grid should be visible or not.
+
+   procedure Grid_Set_Step
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Step   : Gdouble);
+   --  Set the space between two lines of the grid.
+
+   procedure Grid_Set_Attributes
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Style  : Gtk.Extra.Plot_Data.Plot_Line_Style;
+      Width  : Gint;
+      Color  : Gdk.Color.Gdk_Color);
+   --  Set the attributes of the grid.
+
+   procedure Cancel_Action (Plot_Canvas : access Gtk_Plot_Canvas_Record);
+   --  Cancel the current action.
+   --  This can be called in the user callbacks to ignore temporarily some of
+   --  the signals below.
+
+   procedure Unselect (Canvas : access Gtk_Plot_Canvas_Record);
+   --  Unselect the currently selected item.
+
+   function Get_Active_Item
+     (Canvas  : access Gtk_Plot_Canvas_Record)
+     return Gtk_Plot_Canvas_Child;
+   --  Return the currently selected item.
+
+   procedure Set_Size
+     (Canvas  : access Gtk_Plot_Canvas_Record;
+      Width   : Gint;
+      Height  : Gint);
+   --  Modify the size allocated for the canvas, and the size of the pixmap
+   --  the plots are displayed on.
+
+   procedure Set_Magnification
+     (Canvas        : access Gtk_Plot_Canvas_Record;
+      Magnification : Gdouble := 1.0);
+   --  Changes the magnification for the canvas.
+   --  1.0 is the default value. Higher values will zoom in, while lower values
+   --  will zoom out.
+
+   procedure Set_Transparent
+     (Canvas : access Gtk_Plot_Canvas_Record; Transparent : Boolean);
+   --  Whether the canvas should be transparent. If Transparent is True, all
+   --  background attributes are ignored
+
+   function Transparent
+     (Canvas : access Gtk_Plot_Canvas_Record) return Boolean;
+   --  Whether the canvas is currently transparent
+
+   procedure Set_Background
+     (Canvas     : access Gtk_Plot_Canvas_Record;
+      Background : Gdk.Color.Gdk_Color);
+   --  Set the background color for the canvas.
+
+   procedure Get_Pixel
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Px     : Gdouble;
+      Py     : Gdouble;
+      X      : out Gint;
+      Y      : out Gint);
+   --  Convert from relative coordinates to absolute ones.
+
+   procedure Get_Position
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      X      : Gint;
+      Y      : Gint;
+      Px     : out Gdouble;
+      Py     : out Gdouble);
+   --  Convert from absolute coordinates to relative ones.
+
+   procedure Put_Child
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1     : Gdouble;
+      Y1     : Gdouble;
+      X2     : Gdouble := 0.0;
+      Y2     : Gdouble := 0.0);
+   --  Insert a new item in the canvas. It will occupy the area defined by
+   --  the four coordinates.
+   --  See the various packages Gtk.Extra.Plot_Canvas.* on how to create
+   --  such children.
+   --  Leaving X2 and Y2 to their default value will ensure that the child uses
+   --  as much space as it needs
+
+   procedure Remove_Child
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class);
+   --  Remove a child from the canvas
+
+   procedure Child_Move
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1     : Gdouble;
+      Y1     : Gdouble);
+   --  Move an item, but does not change its size.
+
+   procedure Child_Move_Resize
+     (Canvas : access Gtk_Plot_Canvas_Record;
+      Child  : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1     : Gdouble;
+      Y1     : Gdouble;
+      X2     : Gdouble;
+      Y2     : Gdouble);
+   --  Move an resize an item in the canvas.
+
+   procedure Set_Selection
+     (Child     : access Gtk_Plot_Canvas_Child_Record;
+      Selection : Plot_Canvas_Selection);
+
+   procedure Set_Selection_Mode
+     (Child     : access Gtk_Plot_Canvas_Child_Record;
+      Mode      : Plot_Canvas_Selection_Mode);
+
+   procedure Get_Position
+     (Canvas    : access Gtk_Plot_Canvas_Record;
+      Child     : access Gtk_Plot_Canvas_Child_Record'Class;
+      X1, Y1    : out Gdouble;
+      X2, Y2    : out Gdouble);
+
+   ---------------------
+   -- Custom children --
+   ---------------------
+   --  You can insert your own items in a canvas.
+   --  While the canvas will take care of moving the item, it is your
+   --  responsability to provide a visual rendering for it.
+
+   -----------
+   -- Flags --
+   -----------
+   --  Some flags are defined for this widget. You can not access them through
+   --  the usual interface in Gtk.Object.Flag_Is_Set since this widget is not
+   --  part of the standard gtk+ packages. Instead, use the functions below.
+   --
+   --  - "can_select"
+   --    True if it is possible to select a region of the canvas
+   --
+   --  - "can_select_item"
+   --    True if it is possible to select any of the item on the canvas.
+   --
+   --  - "can_dnd"
+   --    True if it is possible to drag an item on the canvas.
+   --
+
+   Can_Select       : constant := 2 ** 0;
+   Can_Select_Item  : constant := 2 ** 1;
+   Can_Dnd          : constant := 2 ** 2;
+   Dnd_Flags        : constant := Can_Select_Item + Can_Dnd;
+
+   function Plot_Canvas_Flag_Is_Set
+     (Plot_Canvas : access Gtk_Plot_Canvas_Record;
+      Flag        : in Guint16)
+     return Boolean;
+   --  Test whether one of the flags for a Gtk_Plot_Canvas widget or its
+   --  children is set.
+
+   procedure Plot_Canvas_Set_Flags
+     (Plot_Canvas  : access Gtk_Plot_Canvas_Record;
+      Flags        : in Guint16);
+   --  Set the flags for a Gtk_Plot_Canvas widget or its children.
+   --  Note that the flags currently set are not touched by this function.
+   --  This can only be used for the flags defined in the
+   --  Gtk.Extra.Gtk_Plot_Canvas package.
+
+   procedure Plot_Canvas_Unset_Flags
+     (Plot_Canvas  : access Gtk_Plot_Canvas_Record;
+      Flags        : in Guint16);
+   --  Unset the flags for a Gtk_Plot_Canvas.
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --
+   --  - "select_item"
+   --    function Handler (Canvas : access Gtk_Plot_Canvas_Record'Class;
+   --                      Event  : Gdk_Button_Event;
+   --                      Item   : Gtk_Plot_Canvas_Child)
+   --                     return Boolean;
+   --
+   --    Called when an item was selected.
+   --    An item can be anything, from a text to a plot
+   --    When this signal is called, the item was simply selected, but not
+   --    dragged.
+   --    The handler should return False if the item can not be selected.
+   --
+   --  - "move_item"
+   --    function Handler (Canvas : access Gtk_Plot_Canvas_Record'Class;
+   --                      Item   : Gtk_Plot_Canvas_Child;
+   --                      New_X  : Gdouble;
+   --                      New_Y  : Gdouble)
+   --                     return Boolean;
+   --
+   --    An item was moved on the canvas.
+   --    Its coordinates have not changed yet, but if the handler returns True
+   --    they will become (New_X, New_Y). If the handler returns False,
+   --    nothing happens.
+   --
+   --  - "resize_item"
+   --    function Handler (Canvas     : access Gtk_Plot_Canvas_Record'Class;
+   --                      Item       : Gtk_Plot_Canvas_Child;
+   --                      New_Width  : Gdouble;
+   --                      New_Height : Gdouble)
+   --                     return Boolean;
+   --
+   --    An item is being resized.
+   --    Its size has not changed yet, but if the handler returns True
+   --    it will become (New_Width, New_Height). If the handler returns False,
+   --    nothing happens.
+   --
+   --  - "add_item"
+   --    procedure Handler (Canvas : access Gtk_Plot_Canvas_Record'Class;
+   --                       Item   : Gtk_Plot_Canvas_Child);
+   --    Called when a new child is added into the canvas
+   --
+   --  - "delete_item"
+   --    function Handler (Canvas : access Gtk_Plot_Canvas_Record'Class;
+   --                      Item   : Gtk_Plot_Canvas_Child) return GBoolean;
+   --    Called when an item is being removed from the canvas
+   --
+   --  - "select_region"
+   --    procedure Handler (Canvas : access Gtk_Plot_Canvas_Record'Class;
+   --                       X_Min  : Gdouble;
+   --                       Y_Min  : Gdouble;
+   --                       X_Max  : Gdouble;
+   --                       Y_Max  : Gdouble);
+   --    A region of the canvas was selected by the user.
+   --
+   --  - "changed"
+   --    procedure Handler (Canvas : access Gtk_Plot_Canvas_Record'Class);
+   --    Called when the contents of the canvas has changed (an item was
+   --    moved interactively by the user).
+   --  </signals>
+
+private
+   type Gtk_Plot_Canvas_Record is new Gtk.Fixed.Gtk_Fixed_Record
+     with null record;
+   type Gtk_Plot_Canvas_Child_Record is
+     new Gtk.Object.Gtk_Object_Record with null record;
+   pragma Import (C, Get_Type, "gtk_plot_canvas_get_type");
+   pragma Import (C, Child_Get_Type, "gtk_plot_canvas_child_get_type");
+
+   Frozen     : constant Plot_Canvas_Flag := 0;
+   Can_Move   : constant Plot_Canvas_Flag := 1;
+   Can_Resize : constant Plot_Canvas_Flag := 2;
+
+end Gtk.Extra.Plot_Canvas;
+
+--  Unbound
+--    gtk_plot_canvas_set_pc
+--    gtk_plot_canvas_set_line_attributes
============================================================
--- src/gtk-extra-plot_data.adb	6de9b2f25ae173b9683152815a12e9f843054e5a
+++ src/gtk-extra-plot_data.adb	6de9b2f25ae173b9683152815a12e9f843054e5a
@@ -0,0 +1,1430 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                       Copyright (C) 2000                          --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2001-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Ada.Unchecked_Conversion;
+with Interfaces.C; use Interfaces.C;
+
+with Gdk.Color;       use Gdk.Color;
+with Gdk.GC;          use Gdk.GC;
+with Gtk.Widget;      use Gtk.Widget;
+with Gtkada.Bindings; use Gtkada.Bindings;
+with Gtkada.Types;    use Gtkada.Types;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Data is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Data_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   type Color_Access is access Gdk_Color;
+   function Convert is new Ada.Unchecked_Conversion
+     (System.Address, Color_Access);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Data : out Gtk_Plot_Data; Func : Plot_Function := null) is
+   begin
+      Data := new Gtk_Plot_Data_Record;
+      Initialize (Data, Func);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Data : access Gtk_Plot_Data_Record'Class; Func : Plot_Function := null)
+   is
+      function Internal return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_new");
+
+      function Internal2 (Func : Plot_Function) return System.Address;
+      pragma Import (C, Internal2, "gtk_plot_data_new_function");
+   begin
+      if Func = null then
+         Set_Object (Data, Internal);
+      else
+         Set_Object (Data, Internal2 (Func));
+      end if;
+   end Initialize;
+
+   --------------
+   -- Set_Name --
+   --------------
+
+   procedure Set_Name (Data : access Gtk_Plot_Data_Record; Name : String) is
+      procedure Internal (Data : System.Address; Name : in String);
+      pragma Import (C, Internal, "gtk_plot_data_set_name");
+   begin
+      Internal (Get_Object (Data), Name & ASCII.NUL);
+   end Set_Name;
+
+   -----------
+   -- Paint --
+   -----------
+
+   procedure Paint (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_paint");
+   begin
+      Internal (Get_Object (Data));
+   end Paint;
+
+   -----------------
+   -- Draw_Points --
+   -----------------
+
+   procedure Draw_Points (Data : access Gtk_Plot_Data_Record; N : Gint) is
+      procedure Internal (Data : System.Address; N : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_draw_points");
+   begin
+      Internal (Get_Object (Data), N);
+   end Draw_Points;
+
+   -----------------
+   -- Draw_Symbol --
+   -----------------
+
+   procedure Draw_Symbol
+     (Data : access Gtk_Plot_Data_Record; X, Y : Gdouble)
+   is
+      procedure Internal (Data : System.Address; X, Y : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_data_draw_symbol");
+   begin
+      Internal (Get_Object (Data), X, Y);
+   end Draw_Symbol;
+
+   ----------------
+   -- Set_Points --
+   ----------------
+
+   procedure Set_Points
+     (Data : access Gtk_Plot_Data_Record;
+      X    : Gdouble_Array_Access;
+      Y    : Gdouble_Array_Access;
+      Dx   : Gdouble_Array_Access;
+      Dy   : Gdouble_Array_Access)
+   is
+      procedure Internal (Data       : in System.Address;
+                          X          : in System.Address;
+                          Y          : in System.Address;
+                          Dx         : in System.Address;
+                          Dy         : in System.Address;
+                          Num_Points : in Gint);
+      pragma Import (C, Internal, "gtk_plot_data_set_points");
+      Xa, Ya, Dxa, Dya : System.Address := System.Null_Address;
+   begin
+      if X /= null then
+         Xa := X (X'First)'Address;
+      end if;
+
+      if Y /= null then
+         Ya := Y (Y'First)'Address;
+      end if;
+
+      if Dx /= null then
+         Dxa := Dx (Dx'First)'Address;
+      end if;
+
+      if Dy /= null then
+         Dya := Dy (Dy'First)'Address;
+      end if;
+
+      Internal (Get_Object (Data), Xa, Ya, Dxa, Dya, X'Length);
+   end Set_Points;
+
+   ----------------
+   -- Get_Points --
+   ----------------
+
+   procedure Get_Points
+     (Data : access Gtk_Plot_Data_Record;
+      X    : out Points_Array;
+      Y    : out Points_Array;
+      Dx   : out Points_Array;
+      Dy   : out Points_Array)
+   is
+      procedure Internal (Data       : in System.Address;
+                          X          : out System.Address;
+                          Y          : out System.Address;
+                          Dx         : out System.Address;
+                          Dy         : out System.Address;
+                          Num_Points : out Gint);
+      pragma Import (C, Internal, "gtk_plot_data_get_points");
+      Num_Points : Gint;
+      X1, Y1, Dx1, Dy1 : System.Address;
+   begin
+      Internal (Get_Object (Data), X1, Y1, Dx1, Dy1, Num_Points);
+      X  := (Points => To_Double_Array (X1),  Num_Points => Num_Points);
+      Y  := (Points => To_Double_Array (Y1),  Num_Points => Num_Points);
+      Dx := (Points => To_Double_Array (Dx1), Num_Points => Num_Points);
+      Dy := (Points => To_Double_Array (Dy1), Num_Points => Num_Points);
+   end Get_Points;
+
+   -----------
+   -- Set_X --
+   -----------
+
+   procedure Set_X
+     (Data : access Gtk_Plot_Data_Record; X : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; X : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_x");
+   begin
+      pragma Assert (Get_Numpoints (Data) = X'Length);
+      Internal (Get_Object (Data), X (X'First)'Address);
+   end Set_X;
+
+   -----------
+   -- Set_Y --
+   -----------
+
+   procedure Set_Y
+     (Data : access Gtk_Plot_Data_Record; Y : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; Y : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_y");
+   begin
+      pragma Assert (Get_Numpoints (Data) = Y'Length);
+      Internal (Get_Object (Data), Y (Y'First)'Address);
+   end Set_Y;
+
+   -----------
+   -- Set_Z --
+   -----------
+
+   procedure Set_Z
+     (Data : access Gtk_Plot_Data_Record; Z : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; Z : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_z");
+   begin
+      pragma Assert (Get_Numpoints (Data) = Z'Length);
+      Internal (Get_Object (Data), Z (Z'First)'Address);
+   end Set_Z;
+
+   -----------
+   -- Set_A --
+   -----------
+
+   procedure Set_A
+     (Data : access Gtk_Plot_Data_Record; A : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; A : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_a");
+   begin
+      pragma Assert (Get_Numpoints (Data) = A'Length);
+      Internal (Get_Object (Data), A (A'First)'Address);
+   end Set_A;
+
+   ------------
+   -- Set_Dx --
+   ------------
+
+   procedure Set_Dx
+     (Data : access Gtk_Plot_Data_Record; Dx : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; Dx : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_dx");
+   begin
+      pragma Assert (Get_Numpoints (Data) = Dx'Length);
+      Internal (Get_Object (Data), Dx (Dx'First)'Address);
+   end Set_Dx;
+
+   ------------
+   -- Set_Dy --
+   ------------
+
+   procedure Set_Dy
+     (Data : access Gtk_Plot_Data_Record; Dy : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; Dy : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_dy");
+   begin
+      pragma Assert (Get_Numpoints (Data) = Dy'Length);
+      Internal (Get_Object (Data), Dy (Dy'First)'Address);
+   end Set_Dy;
+
+   ------------
+   -- Set_Dz --
+   ------------
+
+   procedure Set_Dz
+     (Data : access Gtk_Plot_Data_Record; Dz : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; Dz : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_dz");
+   begin
+      pragma Assert (Get_Numpoints (Data) = Dz'Length);
+      Internal (Get_Object (Data), Dz (Dz'First)'Address);
+   end Set_Dz;
+
+   ------------
+   -- Set_Da --
+   ------------
+
+   procedure Set_Da
+     (Data : access Gtk_Plot_Data_Record; Da : Gdouble_Array_Access)
+   is
+      procedure Internal (Data : System.Address; Da : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_da");
+   begin
+      pragma Assert (Get_Numpoints (Data) = Da'Length);
+      Internal (Get_Object (Data), Da (Da'First)'Address);
+   end Set_Da;
+
+   -----------
+   -- Get_X --
+   -----------
+
+   function Get_X (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_x");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_X;
+
+   -----------
+   -- Get_Y --
+   -----------
+
+   function Get_Y (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_y");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_Y;
+
+   -----------
+   -- Get_Z --
+   -----------
+
+   function Get_Z (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_z");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_Z;
+
+   -----------
+   -- Get_A --
+   -----------
+
+   function Get_A (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_a");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_A;
+
+   ------------
+   -- Get_Dx --
+   ------------
+
+   function Get_Dx (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_dx");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_Dx;
+
+   ------------
+   -- Get_Dy --
+   ------------
+
+   function Get_Dy (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_dy");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_Dy;
+
+   ------------
+   -- Get_Dz --
+   ------------
+
+   function Get_Dz (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal
+        (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_dz");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_Dz;
+
+   ------------
+   -- Get_Da --
+   ------------
+
+   function Get_Da  (Data : access Gtk_Plot_Data_Record) return Points_Array is
+      function Internal (Data : System.Address; Num_Points : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_da");
+
+      Num_Points : aliased Gint;
+      S          : constant System.Address :=
+        Internal (Get_Object (Data), Num_Points'Address);
+
+   begin
+      return (Points => To_Double_Array (S), Num_Points => Num_Points);
+   end Get_Da;
+
+   -------------------
+   -- Set_Numpoints --
+   -------------------
+
+   procedure Set_Numpoints (Data : access Gtk_Plot_Data_Record; Num : Gint) is
+      procedure Internal (Data : System.Address; Num : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_set_numpoints");
+   begin
+      Internal (Get_Object (Data), Num);
+   end Set_Numpoints;
+
+   -------------------
+   -- Get_Numpoints --
+   -------------------
+
+   function Get_Numpoints (Data : access Gtk_Plot_Data_Record) return Gint is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_data_get_numpoints");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Numpoints;
+
+   ----------------
+   -- Set_Labels --
+   ----------------
+
+   procedure Set_Labels
+     (Data : access Gtk_Plot_Data_Record;
+      Labels : Gtkada.Types.Chars_Ptr_Array)
+   is
+      procedure Internal (Data : System.Address; Labels : Chars_Ptr_Array);
+      pragma Import (C, Internal, "gtk_plot_data_set_labels");
+   begin
+      Internal (Get_Object (Data), Labels);
+   end Set_Labels;
+
+   ----------------
+   -- Get_Labels --
+   ----------------
+
+   function Get_Labels (Data : access Gtk_Plot_Data_Record)
+      return Gtkada.Types.Chars_Ptr_Array
+   is
+      function Internal (Data : System.Address) return chars_ptr_array_access;
+      pragma Import (C, Internal, "gtk_plot_data_get_labels");
+
+      N : constant size_t := size_t (Get_Numpoints (Data));
+
+   begin
+      return Chars_Ptr_Array
+        (Internal (Get_Object (Data))(0 .. N - 1));
+   end Get_Labels;
+
+   -----------------
+   -- Show_Labels --
+   -----------------
+
+   procedure Show_Labels
+     (Data : access Gtk_Plot_Data_Record; Show : Boolean)
+   is
+      procedure Internal (Data : System.Address; Show : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_show_labels");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Show));
+   end Show_Labels;
+
+   ---------------------------
+   -- Labels_Set_Attributes --
+   ---------------------------
+
+   procedure Labels_Set_Attributes
+     (Data : access Gtk_Plot_Data_Record;
+      Font : String;
+      Height : Gint;
+      Angle  : Plot_Angle;
+      Foreground : Gdk.Color.Gdk_Color;
+      Background : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data : System.Address;
+         Font : String;
+         Height : Gint;
+         Angle : Plot_Angle;
+         Foreground, Background : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_labels_set_attributes");
+
+      F : aliased Gdk_Color := Foreground;
+      B : aliased Gdk_Color := Background;
+   begin
+      Internal (Get_Object (Data), Font & ASCII.NUL, Height, Angle,
+                F'Address, B'Address);
+   end Labels_Set_Attributes;
+
+   ----------------
+   -- Set_Symbol --
+   ----------------
+
+   procedure Set_Symbol
+     (Data         : access Gtk_Plot_Data_Record;
+      The_Type     : Plot_Symbol_Type;
+      Style        : Plot_Symbol_Style;
+      Size         : Gint;
+      Line_Width   : Gfloat;
+      Color        : Gdk.Color.Gdk_Color;
+      Border_Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data                  : System.Address;
+         The_Type              : Plot_Symbol_Type;
+         Style                 : Plot_Symbol_Style;
+         Size                  : Gint;
+         Line_Width            : Gfloat;
+         Color, Border_Color   : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_symbol");
+
+      C : aliased Gdk_Color := Color;
+      B : aliased Gdk_Color := Border_Color;
+
+   begin
+      Internal
+        (Get_Object (Data), The_Type, Style, Size,
+         Line_Width, C'Address, B'Address);
+   end Set_Symbol;
+
+   ----------------
+   -- Get_Symbol --
+   ----------------
+
+   procedure Get_Symbol
+     (Data         : access Gtk_Plot_Data_Record;
+      The_Type     : out Plot_Symbol_Type;
+      Style        : out Plot_Symbol_Style;
+      Size         : out Gint;
+      Line_Width   : out Gint;
+      Color        : out Gdk.Color.Gdk_Color;
+      Border_Color : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data         : System.Address;
+         The_Type     : out Plot_Symbol_Type;
+         Style        : out Plot_Symbol_Style;
+         Size         : out Gint;
+         Line_Width   : out Gint;
+         Color        : System.Address;
+         Border_Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_get_symbol");
+      C, B : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Data), The_Type, Style, Size, Line_Width,
+                C'Address, B'Address);
+      Color := C;
+      Border_Color := B;
+   end Get_Symbol;
+
+   -------------------
+   -- Set_Connector --
+   -------------------
+
+   procedure Set_Connector
+     (Data : access Gtk_Plot_Data_Record; Connector : Plot_Connector)
+   is
+      procedure Internal (Data : System.Address; Connector : Plot_Connector);
+      pragma Import (C, Internal, "gtk_plot_data_set_connector");
+
+   begin
+      Internal (Get_Object (Data), Connector);
+   end Set_Connector;
+
+   -------------------
+   -- Get_Connector --
+   -------------------
+
+   function Get_Connector (Data : access Gtk_Plot_Data_Record)
+      return Plot_Connector
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_data_get_connector");
+   begin
+      return Plot_Connector'Val (Internal (Get_Object (Data)));
+   end Get_Connector;
+
+   -------------------------
+   -- Set_Line_Attributes --
+   -------------------------
+
+   procedure Set_Line_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data  : System.Address;
+         Style : Plot_Line_Style;
+         Cap_Style : Gdk_Cap_Style;
+         Join_Style : Gdk_Join_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_line_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal
+        (Get_Object (Data), Style, Cap_Style, Join_Style, Width, C'Address);
+   end Set_Line_Attributes;
+
+   -------------------------
+   -- Get_Line_Attributes --
+   -------------------------
+
+   procedure Get_Line_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : out Plot_Line_Style;
+      Cap_Style  : out Gdk.GC.Gdk_Cap_Style;
+      Join_Style : out Gdk.GC.Gdk_Join_Style;
+      Width      : out Gfloat;
+      Color      : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data       : System.Address;
+         Style      : out Plot_Line_Style;
+         Cap_Style  : out Gdk.GC.Gdk_Cap_Style;
+         Join_Style : out Gdk.GC.Gdk_Join_Style;
+         Width      : out Gfloat;
+         Color      : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_get_line_attributes");
+      C : aliased Gdk_Color;
+   begin
+      Internal
+        (Get_Object (Data), Style, Cap_Style, Join_Style, Width, C'Address);
+      Color := C;
+   end Get_Line_Attributes;
+
+   ----------------------
+   -- Set_X_Attributes --
+   ----------------------
+
+   procedure Set_X_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data  : System.Address;
+         Style : Plot_Line_Style;
+         Cap_Style : Gdk_Cap_Style;
+         Join_Style : Gdk_Join_Style;
+         Width : Gfloat;
+         Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_x_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal
+        (Get_Object (Data), Style, Cap_Style, Join_Style, Width, C'Address);
+   end Set_X_Attributes;
+
+   ----------------------
+   -- Set_Y_Attributes --
+   ----------------------
+
+   procedure Set_Y_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data       : System.Address;
+         Style      : Plot_Line_Style;
+         Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+         Join_Style : Gdk.GC.Gdk_Join_Style;
+         Width      : Gfloat;
+         Color      : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_y_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal
+        (Get_Object (Data), Style, Cap_Style, Join_Style, Width, C'Address);
+   end Set_Y_Attributes;
+
+   ----------------------
+   -- Set_Z_Attributes --
+   ----------------------
+
+   procedure Set_Z_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data       : System.Address;
+         Style      : Plot_Line_Style;
+         Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+         Join_Style : Gdk.GC.Gdk_Join_Style;
+         Width      : Gfloat;
+         Color      : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_z_attributes");
+
+      C : aliased Gdk_Color := Color;
+
+   begin
+      Internal
+        (Get_Object (Data), Style, Cap_Style, Join_Style, Width, C'Address);
+   end Set_Z_Attributes;
+
+   -------------------
+   -- Show_Xerrbars --
+   -------------------
+
+   procedure Show_Xerrbars (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_show_xerrbars");
+   begin
+      Internal (Get_Object (Data));
+   end Show_Xerrbars;
+
+   -------------------
+   -- Show_Yerrbars --
+   -------------------
+
+   procedure Show_Yerrbars (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_show_yerrbars");
+   begin
+      Internal (Get_Object (Data));
+   end Show_Yerrbars;
+
+   -------------------
+   -- Show_Zerrbars --
+   -------------------
+
+   procedure Show_Zerrbars (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_show_zerrbars");
+   begin
+      Internal (Get_Object (Data));
+   end Show_Zerrbars;
+
+   -------------------
+   -- Hide_Xerrbars --
+   -------------------
+
+   procedure Hide_Xerrbars (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_hide_xerrbars");
+   begin
+      Internal (Get_Object (Data));
+   end Hide_Xerrbars;
+
+   -------------------
+   -- Hide_Yerrbars --
+   -------------------
+
+   procedure Hide_Yerrbars (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_hide_yerrbars");
+   begin
+      Internal (Get_Object (Data));
+   end Hide_Yerrbars;
+
+   -------------------
+   -- Hide_Zerrbars --
+   -------------------
+
+   procedure Hide_Zerrbars (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_hide_zerrbars");
+   begin
+      Internal (Get_Object (Data));
+   end Hide_Zerrbars;
+
+   ---------------
+   -- Fill_Area --
+   ---------------
+
+   procedure Fill_Area (Data : access Gtk_Plot_Data_Record; Fill : Boolean) is
+      procedure Internal (Data : System.Address; Fill : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_fill_area");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Fill));
+   end Fill_Area;
+
+   --------------------
+   -- Area_Is_Filled --
+   --------------------
+
+   function Area_Is_Filled (Data : access Gtk_Plot_Data_Record)
+      return Boolean
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_data_area_is_filled");
+   begin
+      return Boolean'Val (Internal (Get_Object (Data)));
+   end Area_Is_Filled;
+
+   ----------------
+   -- Set_Legend --
+   ----------------
+
+   procedure Set_Legend (Data : access Gtk_Plot_Data_Record; Legend : String)
+   is
+      procedure Internal (Data : System.Address; Legend : String);
+      pragma Import (C, Internal, "gtk_plot_data_set_legend");
+   begin
+      Internal (Get_Object (Data), Legend & ASCII.NUL);
+   end Set_Legend;
+
+   -----------------
+   -- Show_Legend --
+   -----------------
+
+   procedure Show_Legend (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_show_legend");
+   begin
+      Internal (Get_Object (Data));
+   end Show_Legend;
+
+   -----------------
+   -- Hide_Legend --
+   -----------------
+
+   procedure Hide_Legend (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_hide_legend");
+   begin
+      Internal (Get_Object (Data));
+   end Hide_Legend;
+
+   --------------------------
+   -- Set_Legend_Precision --
+   --------------------------
+
+   procedure Set_Legend_Precision
+     (Data : access Gtk_Plot_Data_Record; Precision : Gint)
+   is
+      procedure Internal (Data : System.Address; Precision : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_set_legend_precision");
+   begin
+      Internal (Get_Object (Data), Precision);
+   end Set_Legend_Precision;
+
+   --------------------------
+   -- Get_Legend_Precision --
+   --------------------------
+
+   function Get_Legend_Precision (Data : access Gtk_Plot_Data_Record)
+      return Gint
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_data_get_legend_precision");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Legend_Precision;
+
+   -----------------------
+   -- Set_Gradient_Mask --
+   -----------------------
+
+   procedure Set_Gradient_Mask
+     (Data : access Gtk_Plot_Data_Record; Mask : Plot_Gradient)
+   is
+      procedure Internal (Data : System.Address; Mask : Plot_Gradient);
+      pragma Import (C, Internal, "gtk_plot_data_set_gradient_mask");
+
+   begin
+      Internal (Get_Object (Data), Mask);
+   end Set_Gradient_Mask;
+
+   -----------------------
+   -- Get_Gradient_Mask --
+   -----------------------
+
+   function Get_Gradient_Mask (Data : access Gtk_Plot_Data_Record)
+      return Plot_Gradient
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_data_get_gradient_mask");
+   begin
+      return Plot_Gradient'Val (Internal (Get_Object (Data)));
+   end Get_Gradient_Mask;
+
+   --------------------------
+   -- Gradient_Set_Visible --
+   --------------------------
+
+   procedure Gradient_Set_Visible
+     (Data : access Gtk_Plot_Data_Record; Visible : Boolean)
+   is
+      procedure Internal (Data : System.Address; Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_set_visible");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Visible));
+   end Gradient_Set_Visible;
+
+   ----------------------
+   -- Gradient_Visible --
+   ----------------------
+
+   function Gradient_Visible (Data : access Gtk_Plot_Data_Record)
+      return Boolean
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_data_gradient_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Data)));
+   end Gradient_Visible;
+
+   -------------------------
+   -- Set_Gradient_Colors --
+   -------------------------
+
+   procedure Set_Gradient_Colors
+     (Data : access Gtk_Plot_Data_Record;
+      Min, Max : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data, Min, Max : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_gradient_colors");
+      Mi : aliased Gdk_Color := Min;
+      Ma : aliased Gdk_Color := Max;
+   begin
+      Internal (Get_Object (Data), Mi'Address, Ma'Address);
+   end Set_Gradient_Colors;
+
+   -------------------------
+   -- Get_Gradient_Colors --
+   -------------------------
+
+   procedure Get_Gradient_Colors
+     (Data : access Gtk_Plot_Data_Record;
+      Min, Max : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data, Min, Max : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_get_gradient_colors");
+      Mi, Ma : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Data), Mi'Address, Ma'Address);
+      Min := Mi;
+      Max := Ma;
+   end Get_Gradient_Colors;
+
+   ------------------
+   -- Set_Gradient --
+   ------------------
+
+   procedure Set_Gradient
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : Gdouble;
+      Nlevels  : Gint;
+      Nsublevels : Gint)
+   is
+      procedure Internal
+        (Data : System.Address; Min, Max : Gdouble; N, N2 : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_set_gradient");
+   begin
+      Internal (Get_Object (Data), Min, Max, Nlevels, Nsublevels);
+   end Set_Gradient;
+
+   ------------------
+   -- Get_Gradient --
+   ------------------
+
+   procedure Get_Gradient
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : out Gdouble;
+      Nlevels  : out Gint;
+      Nsublevels : out Gint)
+   is
+      procedure Internal (Data : System.Address;
+                          Min, Max : out Gdouble;
+                          N, N2 : out Gint);
+      pragma Import (C, Internal, "gtk_plot_data_get_gradient");
+   begin
+      Internal (Get_Object (Data), Min, Max, Nlevels, Nsublevels);
+   end Get_Gradient;
+
+   ------------------------
+   -- Get_Gradient_Level --
+   ------------------------
+
+   procedure Get_Gradient_Level
+     (Data  : access Gtk_Plot_Data_Record;
+      Level : Gdouble;
+      Color : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data : System.Address;
+                          Level : Gdouble;
+                          Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_get_gradient_level");
+      C : aliased Gdk_Color;
+   begin
+      Internal (Get_Object (Data), Level, C'Address);
+      Color := C;
+   end Get_Gradient_Level;
+
+   --------------
+   -- Set_Link --
+   --------------
+
+   procedure Set_Link
+     (Data : access Gtk_Plot_Data_Record;
+      Link : System.Address)
+   is
+      procedure Internal (Data, Link : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_link");
+   begin
+      Internal (Get_Object (Data), Link);
+   end Set_Link;
+
+   --------------
+   -- Get_Link --
+   --------------
+
+   function Get_Link (Data : access Gtk_Plot_Data_Record)
+      return System.Address
+   is
+      function Internal (Data : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_link");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Link;
+
+   -----------------
+   -- Remove_Link --
+   -----------------
+
+   procedure Remove_Link (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_remove_link");
+   begin
+      Internal (Get_Object (Data));
+   end Remove_Link;
+
+   ------------
+   -- Update --
+   ------------
+
+   procedure Update (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_update");
+   begin
+      Internal (Get_Object (Data));
+   end Update;
+
+   -----------------
+   -- Set_A_Scale --
+   -----------------
+
+   procedure Set_A_Scale
+     (Data : access Gtk_Plot_Data_Record; A_Scale : Gdouble)
+   is
+      procedure Internal (Data : System.Address; A_Scale : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_data_set_a_scale");
+   begin
+      Internal (Get_Object (Data), A_Scale);
+   end Set_A_Scale;
+
+   -----------------
+   -- Get_A_Scale --
+   -----------------
+
+   function Get_A_Scale
+     (Data : access Gtk_Plot_Data_Record) return Gdouble
+   is
+      function Internal (Data : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_data_get_a_scale");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_A_Scale;
+
+   --------------------
+   -- Reset_Gradient --
+   --------------------
+
+   procedure Reset_Gradient (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_reset_gradient");
+   begin
+      Internal (Get_Object (Data));
+   end Reset_Gradient;
+
+   ---------------------------
+   -- Reset_Gradient_Colors --
+   ---------------------------
+
+   procedure Reset_Gradient_Colors (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_reset_gradient_colors");
+   begin
+      Internal (Get_Object (Data));
+   end Reset_Gradient_Colors;
+
+   ----------------------------
+   -- Set_Gradient_Nth_Color --
+   ----------------------------
+
+   procedure Set_Gradient_Nth_Color
+     (Data  : access Gtk_Plot_Data_Record;
+      Level : Guint;
+      Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data : System.Address; Level : Guint; Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_gradient_nth_color");
+      C : aliased Gdk_Color := Color;
+   begin
+      Internal (Get_Object (Data), Level, C'Address);
+   end Set_Gradient_Nth_Color;
+
+   ----------------------------
+   -- Get_Gradient_Nth_Color --
+   ----------------------------
+
+   function Get_Gradient_Nth_Color
+     (Data  : access Gtk_Plot_Data_Record; Level : Guint)
+      return Gdk.Color.Gdk_Color
+   is
+      function Internal (Data : System.Address; Level : Guint)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_data_get_gradient_nth_color");
+
+      C : constant Color_Access :=
+        Convert (Internal (Get_Object (Data), Level));
+   begin
+      return C.all;
+   end Get_Gradient_Nth_Color;
+
+   -------------------------------
+   -- Set_Gradient_Outer_Colors --
+   -------------------------------
+
+   procedure Set_Gradient_Outer_Colors
+     (Data : access Gtk_Plot_Data_Record;
+      Min, Max : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (D, Min, Max : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_set_gradient_outer_colors");
+      Mi : aliased Gdk_Color := Min;
+      Ma : aliased Gdk_Color := Max;
+   begin
+      Internal (Get_Object (Data), Mi'Address, Ma'Address);
+   end Set_Gradient_Outer_Colors;
+
+   --------------------------
+   -- Gradient_Autoscale_A --
+   --------------------------
+
+   procedure Gradient_Autoscale_A (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_autoscale_a");
+   begin
+      Internal (Get_Object (Data));
+   end Gradient_Autoscale_A;
+
+   ---------------------------
+   -- Gradient_Autoscale_Da --
+   ---------------------------
+
+   procedure Gradient_Autoscale_Da (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_autoscale_da");
+   begin
+      Internal (Get_Object (Data));
+   end Gradient_Autoscale_Da;
+
+   --------------------------
+   -- Gradient_Autoscale_Z --
+   --------------------------
+
+   procedure Gradient_Autoscale_Z (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_autoscale_z");
+   begin
+      Internal (Get_Object (Data));
+   end Gradient_Autoscale_Z;
+
+   ------------------------
+   -- Gradient_Set_Style --
+   ------------------------
+
+   procedure Gradient_Set_Style
+     (Data      : access Gtk_Plot_Data_Record;
+      Style     : Plot_Label_Style;
+      Precision : Gint)
+   is
+      procedure Internal (D : System.Address; S : Plot_Label_Style; P : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_set_style");
+   begin
+      Internal (Get_Object (Data), Style, Precision);
+   end Gradient_Set_Style;
+
+   ------------------------
+   -- Gradient_Set_Scale --
+   ------------------------
+
+   procedure Gradient_Set_Scale
+     (Data      : access Gtk_Plot_Data_Record;
+      Scale     : Plot_Scale)
+   is
+      procedure Internal (Data : System.Address; Scale : Plot_Scale);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_set_scale");
+   begin
+      Internal (Get_Object (Data), Scale);
+   end Gradient_Set_Scale;
+
+   ----------------
+   -- Add_Marker --
+   ----------------
+
+   function Add_Marker
+     (Data : access Gtk_Plot_Data_Record; Point : Guint)
+      return Gtk_Plot_Marker
+   is
+      function Internal (D : System.Address; P : Guint) return Gtk_Plot_Marker;
+      pragma Import (C, Internal, "gtk_plot_data_add_marker");
+   begin
+      return Internal (Get_Object (Data), Point);
+   end Add_Marker;
+
+   -------------------
+   -- Remove_Marker --
+   -------------------
+
+   procedure Remove_Marker
+     (Data : access Gtk_Plot_Data_Record; Marker : Gtk_Plot_Marker)
+   is
+      procedure Internal (Data : System.Address; Marker : Gtk_Plot_Marker);
+      pragma Import (C, Internal, "gtk_plot_data_remove_marker");
+   begin
+      Internal (Get_Object (Data), Marker);
+   end Remove_Marker;
+
+   --------------------
+   -- Remove_Markers --
+   --------------------
+
+   procedure Remove_Markers (Data : access Gtk_Plot_Data_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_remove_markers");
+   begin
+      Internal (Get_Object (Data));
+   end Remove_Markers;
+
+   ------------------
+   -- Show_Markers --
+   ------------------
+
+   procedure Show_Markers
+     (Data : access Gtk_Plot_Data_Record; Show : Boolean)
+   is
+      procedure Internal (Data : System.Address; Show : Gboolean);
+      pragma Import (C, Internal, "gtk_plot_data_show_markers");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Show));
+   end Show_Markers;
+
+   ---------------------
+   -- Markers_Visible --
+   ---------------------
+
+   function Markers_Visible (Data : access Gtk_Plot_Data_Record)
+      return Boolean
+   is
+      function Internal (Data : System.Address) return Gboolean;
+      pragma Import (C, Internal, "gtk_plot_data_markers_visible");
+   begin
+      return Internal (Get_Object (Data)) /= 0;
+   end Markers_Visible;
+
+   -----------
+   -- Clone --
+   -----------
+
+   procedure Clone
+     (Data : access Gtk_Plot_Data_Record;
+      Copy : access Gtk_Plot_Data_Record'Class)
+   is
+      procedure Internal (Data, Copy : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_clone");
+   begin
+      Internal (Get_Object (Data), Get_Object (Copy));
+   end Clone;
+
+   --------------------------
+   -- Dimension_Set_Points --
+   --------------------------
+
+   procedure Dimension_Set_Points
+     (Data   : access Gtk_Plot_Data_Record;
+      Name   : String;
+      Points : Gdouble_Array_Access)
+   is
+      procedure Internal
+        (Data : System.Address; Name : String; Points : System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_dimension_set_points");
+      P : System.Address := System.Null_Address;
+   begin
+      if Points /= null then
+         P := Points (Points'First)'Address;
+      end if;
+
+      Internal (Get_Object (Data), Name & ASCII.NUL, P);
+   end Dimension_Set_Points;
+
+   -------------------
+   -- Move_Gradient --
+   -------------------
+
+   procedure Move_Gradient
+     (Data : access Gtk_Plot_Data_Record; X, Y : Gdouble)
+   is
+      procedure Internal (Data : System.Address; X, Y : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_data_move_gradient");
+   begin
+      Internal (Get_Object (Data), X, Y);
+   end Move_Gradient;
+
+   -----------------------
+   -- Set_Gradient_Size --
+   -----------------------
+
+   procedure Set_Gradient_Size
+     (Data : access Gtk_Plot_Data_Record; Size : Gint)
+   is
+      procedure Internal (Data : System.Address; Size : Gint);
+      pragma Import (C, Internal, "gtk_plot_data_set_gradient_size");
+   begin
+      Internal (Get_Object (Data), Size);
+   end Set_Gradient_Size;
+
+   --------------------------------
+   -- Gradient_Use_Custom_Colors --
+   --------------------------------
+
+   procedure Gradient_Use_Custom_Colors
+     (Data : access Gtk_Plot_Data_Record; Custom : Boolean)
+   is
+      procedure Internal (Data : System.Address; Custom : Gboolean);
+      pragma Import (C, Internal, "gtk_plot_data_gradient_use_custom_colors");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Custom));
+   end Gradient_Use_Custom_Colors;
+
+   ----------------------------
+   -- Gradient_Custom_Colors --
+   ----------------------------
+
+   function Gradient_Custom_Colors
+     (Data : access Gtk_Plot_Data_Record) return Boolean
+   is
+      function Internal (Data : System.Address) return Gboolean;
+      pragma Import (C, Internal, "gtk_plot_data_gradient_custom_colors");
+   begin
+      return Boolean'Val (Internal (Get_Object (Data)));
+   end Gradient_Custom_Colors;
+
+   -------------------------------
+   -- Get_Gradient_Outer_Colors --
+   -------------------------------
+
+   procedure Get_Gradient_Outer_Colors
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : out Gdk.Color.Gdk_Color)
+   is
+      procedure Internal
+        (Data : System.Address;
+         MinA, MaxA : out System.Address);
+      pragma Import (C, Internal, "gtk_plot_data_get_gradient_outer_colors");
+
+      Mi, Ma : System.Address;
+   begin
+      Internal (Get_Object (Data), Mi, Ma);
+      Min := Convert (Mi).all;
+      Max := Convert (Ma).all;
+   end Get_Gradient_Outer_Colors;
+
+end Gtk.Extra.Plot_Data;
============================================================
--- src/gtk-extra-plot_data.ads	6ba620bcec28e873d612a186f0c5ab3b7cb6d78b
+++ src/gtk-extra-plot_data.ads	6ba620bcec28e873d612a186f0c5ab3b7cb6d78b
@@ -0,0 +1,714 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  This package defines the root of the plot hierarchy. It defines several
+--  display strategies that can be used to show scientific data on the
+--  screen (see the children for 3D, polar, bars,...)
+--
+--  All coordinates are in percent of the total size allocates for the data
+--  set (ie the actual position is (x * width, y * height), where (x, y) is
+--  the value stored in the data set and (width, height) its allocated screen
+--  size.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+--  <testgtk>create_plot_realtime.adb</testgtk>
+
+with Gdk.Color;
+with Gdk.GC;
+with Glib;
+with Gtk.Widget;
+with Gtkada.Types;
+with Unchecked_Conversion;
+
+package Gtk.Extra.Plot_Data is
+
+   type Plot_Label_Style is (Label_Float, Label_Exp, Label_Pow);
+   --  The style of labels (floating point, or scientific notation)
+   pragma Convention (C, Plot_Label_Style);
+
+   type Plot_Scale is (Scale_Linear, Scale_Log10);
+   --  Type of scale used for each axis of a graph.
+   pragma Convention (C, Plot_Scale);
+
+   type Gtk_Plot_Data_Record is new Gtk.Widget.Gtk_Widget_Record with private;
+   type Gtk_Plot_Data is access all Gtk_Plot_Data_Record'Class;
+   --  A set of values that can be represented on the screen. There are
+   --  several strategies to set the values, either explicitely in your
+   --  application, or by having them automatically generated by a function.
+
+   type Gtk_Plot_Marker is new Gdk.C_Proxy;
+
+   --  <doc_ignore>
+   --  The convert functions are needed to e.g. instantiate Generic_List
+   --  They should not be used directly
+   function Convert is new Unchecked_Conversion
+     (Gtk_Plot_Data, System.Address);
+   function Convert is new Unchecked_Conversion
+     (System.Address, Gtk_Plot_Data);
+   --  </doc_ignore>
+
+   -----------
+   -- Types --
+   -----------
+
+   type No_Range_Gdouble_Array is array (Natural) of Gdouble;
+   --  An array of values.
+   --  This is used to represent the data values displayed in the plot.
+   --  This array does not have any range information (so that it can be
+   --  easily returned from a C function, without requiring an extra
+   --  copy of the table). You can not use 'Range on this array.
+
+   type No_Range_Gdouble_Array_Access is access all No_Range_Gdouble_Array;
+   --  An access to a flat array.
+
+   type Gdouble_Array_Access is access all Glib.Gdouble_Array;
+   --  The reason we use this type in the functions below is because
+   --  gtk+-extra does not keep a copy of the arrays, but points to the one
+   --  given in argument. Thus, the Ada arrays should not be allocated on the
+   --  stack, or at least they should be at library level. Using this 'Access
+   --  will force the compiler to do the check for us.
+
+   type Points_Array is record
+      Points     : No_Range_Gdouble_Array_Access;
+      Num_Points : Gint := 0;
+   end record;
+   --  The points are indexed from 0 to Num_Points-1.
+   --  Note that you can't use 'Range, 'First or 'Last on Points.
+
+   type Plot_Connector is
+     (Connect_None,
+      --  No connection
+
+      Connect_Straight,
+      --  straight line
+
+      Connect_Spline,
+      --  spline or Bezier curve
+
+      Connect_Hv_Step,
+      --  Horizontal then vertical
+
+      Connect_Vh_Step,
+      --  Vertical then horizontal
+
+      Connect_Middle_Step
+      --  Split in the middle
+     );
+   --  The type of connection between two adjacent points in a graph.
+   pragma Convention (C, Plot_Connector);
+
+   type Plot_Gradient is new Integer;
+   --  Indicate which color components vary along the gradient
+
+   Gradient_H : constant Plot_Gradient; --  Hue
+   Gradient_V : constant Plot_Gradient; --  Value
+   Gradient_S : constant Plot_Gradient; --  Saturation
+
+   type Plot_Symbol_Type is
+     (Symbol_None,
+      Symbol_Square,
+      Symbol_Circle,
+      Symbol_Up_Triangle,
+      Symbol_Down_Triangle,
+      Symbol_Right_Triangle,
+      Symbol_Left_Triangle,
+      Symbol_Diamond,
+      Symbol_Plus,
+      Symbol_Cross,
+      Symbol_Star,
+      Symbol_Dot,
+      Symbol_Impulse);
+   --  Type of symbol used to represent the points in a graph.
+   pragma Convention (C, Plot_Symbol_Type);
+
+   type Plot_Symbol_Style is
+     (Symbol_Empty,
+      Symbol_Filled,
+      Symbol_Opaque);
+   --  Style used to draw the points in a graph.
+   pragma Convention (C, Plot_Symbol_Style);
+
+   type Plot_Line_Style is
+     (Line_None,
+      Line_Solid,
+      Line_Dotted,
+      Line_Dashed,
+      Line_Dot_Dash,
+      Line_Dot_Dot_Dash,
+      Line_Dot_Dash_Dash);
+   --  Lines used to connect two adjacent points in a graph.
+   pragma Convention (C, Plot_Line_Style);
+
+   type Plot_Angle is (Angle_0, Angle_90, Angle_180, Angle_270);
+   --  Valid values for the angles of texts and titles.
+   pragma Convention (C, Plot_Angle);
+
+   --------------------
+   -- Plot functions --
+   --------------------
+   --  Plot functions should generate a unique Y value given a parameter.
+   --  These can be used for instance to represent exactly mathematical
+   --  functions.
+   --  Note that due to the C interface, the subprograms in Gtk.Extra.Plot and
+   --  in this package expect functions that take a System.Address as a
+   --  parameter. However, since it is much more convenient in your application
+   --  to get a Gtk_Plot_Record directly, GtkAda includes a generic function
+   --  that automatically does the conversion for you (see
+   --  Gtk.Plot.Generic_Plot_Function).
+
+   type Plot_Function is access function
+     (Plot  : System.Address;
+      Set   : Gtk_Plot_Data;
+      X     : Gdouble;
+      Error : access Gboolean) return Gdouble;
+   --  Function used for plotting.
+   --  It should return the value associated with X in its graph, and set
+   --  Error to True if there was an error while calculating the value.
+
+   pragma Convention (C, Plot_Function);
+
+   -------------------------
+   -- Creating a Data set --
+   -------------------------
+
+   procedure Gtk_New (Data : out Gtk_Plot_Data; Func : Plot_Function := null);
+   --  Creates a new data set. Its values can either be generated automatically
+   --  from Func, or will have to be set explicitely using the other
+   --  subprograms in this package.
+
+   procedure Initialize
+     (Data : access Gtk_Plot_Data_Record'Class; Func : Plot_Function := null);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Plot_Data.
+
+   procedure Set_Name (Data : access Gtk_Plot_Data_Record; Name : String);
+   --  Set the name used internally for that dataset.
+   --  This name does not appear anywhere on the screen, but it is easier to
+   --  find the dataset afterward by using this name.
+
+   procedure Clone
+     (Data : access Gtk_Plot_Data_Record;
+      Copy : access Gtk_Plot_Data_Record'Class);
+   --  Copy the contents of Data into Copy, which must have been allocated
+   --  first
+
+   -------------------
+   -- Drawing a set --
+   -------------------
+   --  Although a set is basically a list of values, it is closely associated
+   --  with its representation on the screen (see the children of Gtk_Plot_Data
+   --  for various possible representations).
+   --  The Gtk.Extra packages are designed so that the drawing can be done
+   --  either to the screen (through a Gdk adapter), to a postscript file for
+   --  easy printing, or to any other media.
+
+   procedure Paint (Data : access Gtk_Plot_Data_Record);
+   --  Emits the "draw_data" signal to request a redrawing of the data set.
+
+   procedure Update (Data : access Gtk_Plot_Data_Record);
+   --  Indicates that the data has changed, and the graphical view should
+   --  reflect this.
+
+   procedure Draw_Points (Data : access Gtk_Plot_Data_Record; N : Gint);
+   --  Draw the N last (most recent) values of the Data set on the screen.
+   --  If N is greater than the actual number of values in Data, then they are
+   --  all displayed. This subprogram should be used when you want to
+   --  periodically update the contents of a dataset (you would then modify
+   --  the number of points in the dataset with a call to Set_Numpoints, then
+   --  register the new points with Set_X and Set_Y, and finally refresh the
+   --  dataset with a call to Draw_Points and Gtk.Plot.Refresh).
+
+   procedure Draw_Symbol (Data : access Gtk_Plot_Data_Record; X, Y : Gdouble);
+   --  Draw the current symbol (see Set_Symbol) at specific coordinates on
+   --  the screen.
+
+   ----------------
+   -- Dimensions --
+   ----------------
+   --  The coordinates of the points to draw are specified in space. Therefore,
+   --  they have multiple coordinates, each associate with a specific
+   --  dimension.
+   --  The name of dimensions below must be one of "x", "y", "z", "dx", "dy",
+   --  "dz", "a", "da".
+   --  "d..." are the size (precision of these points). A bigger symbol is
+   --  displayed for the points whose (dx,dy) is bigger.
+   --  "a" is used to specify the size of the symbols. When plotting boxes in
+   --  two dimensions, "Z" is used to specify the size of the box.
+
+   procedure Dimension_Set_Points
+     (Data   : access Gtk_Plot_Data_Record;
+      Name   : String;
+      Points : Gdouble_Array_Access);
+   --  Set the coordinates of the points along one dimension
+
+   procedure Set_Numpoints (Data : access Gtk_Plot_Data_Record; Num : Gint);
+   --  Set the number of points that should be expected in the graph.
+   --  Note that this does not automatically resize all the internal structure,
+   --  it just indicates what size the parameters to Set_X, Set_Y,... should
+   --  have.
+
+   function Get_Numpoints (Data : access Gtk_Plot_Data_Record) return Gint;
+   --  Return the number of points expected in the graph.
+
+   -------------------------
+   -- Manipulating values --
+   -------------------------
+   --  These are older functions, kept for compatibility. They provide a
+   --  somewhat simpler interface to the dimensions, but the use of dimensions
+   --  is recommended.
+   --  See the comment for dimensions on the meaning of X, Y, Dx, Dy,...
+
+   procedure Set_Points
+     (Data   : access Gtk_Plot_Data_Record;
+      X, Y, Dx, Dy : Gdouble_Array_Access);
+   --  Set some explicit points in the set.
+   --  Note that the set must not be associated with a function, or the points
+   --  will simply be ignored.
+   --  All of the arrays must have the same length, the behavior is undefined
+   --  otherwise.
+
+   procedure Get_Points
+     (Data : access Gtk_Plot_Data_Record;
+      X    : out Points_Array;
+      Y    : out Points_Array;
+      Dx   : out Points_Array;
+      Dy   : out Points_Array);
+   --  Return the value of the points in the set.
+   --  Null-length arrays are returned if the set is associated with a
+   --  function, since no explicit point has been set.
+
+   procedure Set_X
+     (Data : access Gtk_Plot_Data_Record; X : Gdouble_Array_Access);
+   procedure Set_Y
+     (Data : access Gtk_Plot_Data_Record; Y : Gdouble_Array_Access);
+   procedure Set_Z
+     (Data : access Gtk_Plot_Data_Record; Z : Gdouble_Array_Access);
+   procedure Set_A
+     (Data : access Gtk_Plot_Data_Record; A : Gdouble_Array_Access);
+   --  Set the values for one specific coordinate in the set.
+   --  The array must have a length of Get_Numpoints (if GtkAda was
+   --  compiled with assertions enabled, an exception will be raised if the
+   --  length are different).
+   --  No copy of the array is made for efficiency reasons, thus modifying
+   --  the array content later on will also modify the plot.
+
+   procedure Set_A_Scale
+     (Data : access Gtk_Plot_Data_Record; A_Scale : Gdouble);
+   function Get_A_Scale
+     (Data : access Gtk_Plot_Data_Record) return Gdouble;
+   --  Changes the scale used for the "A" coordinate
+
+   procedure Set_Dx
+     (Data : access Gtk_Plot_Data_Record; Dx : Gdouble_Array_Access);
+   procedure Set_Dy
+     (Data : access Gtk_Plot_Data_Record; Dy : Gdouble_Array_Access);
+   procedure Set_Dz
+     (Data : access Gtk_Plot_Data_Record; Dz : Gdouble_Array_Access);
+   --  Set the precision of the points in the set. A bigger symbol is displayed
+   --  for the points whose (Dx, Dy, Dz) is bigger.
+   --  The array must have a length of Get_Numpoints (if GtkAda was
+   --  compiled with assertions enabled, an exception will be raised if the
+   --  length are different).
+   --  No copy of the array is made for efficiency reasons, thus modifying
+   --  the array content later on will also modify the plot.
+
+   procedure Set_Da
+     (Data : access Gtk_Plot_Data_Record; Da : Gdouble_Array_Access);
+   --  Specifies the colors to use for the points.
+   --  The color of the symbols is detemined using the gradient. the gradient
+   --  has (min, max) values, and corresponding colors. The symbol's color is
+   --  interpolated between these values using hue/saturation/value depending
+   --  on the gradient_mask.
+
+   function Get_X  (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_Y  (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_Z  (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_A  (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_Dx (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_Dy (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_Dz (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   function Get_Da (Data : access Gtk_Plot_Data_Record) return Points_Array;
+   --  Return the coordinates for the points in the set.
+   --  This is a direct access to the underlying C array, thus modifying this
+   --  array's contents also modifies the graph.
+   --  See the corresponding Set_* functions for a definition of the
+   --  coordinates
+
+   ------------
+   -- Labels --
+   ------------
+   --  Each point in the data set can be associated with a label that describes
+   --  it. This is only relevant for data sets where you explicitely give
+   --  values, not when the values are generated by a function.
+
+   procedure Set_Labels
+     (Data   : access Gtk_Plot_Data_Record;
+      Labels : Gtkada.Types.Chars_Ptr_Array);
+   --  Set the labels associated which each point in the canvas.
+   --  There must be at least Get_Numpoints elements in Labels, or the
+   --  behavior is undefined
+
+   function Get_Labels (Data : access Gtk_Plot_Data_Record)
+      return Gtkada.Types.Chars_Ptr_Array;
+   --  Return the labels associated with the points in the data set.
+   --  Note that this returns a *copy* of the actual array, and thus might
+   --  be expensive to call.
+
+   procedure Show_Labels (Data : access Gtk_Plot_Data_Record; Show : Boolean);
+   --  Indicate whether the labels should be displayed next to each point in
+   --  the data set. This has no effect if no labels were specified.
+
+   procedure Labels_Set_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Font       : String;
+      Height     : Gint;
+      Angle      : Plot_Angle;
+      Foreground : Gdk.Color.Gdk_Color;
+      Background : Gdk.Color.Gdk_Color);
+   --  Set the properties of the labels
+
+   ----------------------------
+   -- Symbols and Connectors --
+   ----------------------------
+   --  Each point that is explicitely set in the data set through the
+   --  Set_X, Set_Y,... subprograms is visually associated with a symbol. There
+   --  are several representations for the symbols.
+   --
+   --  All these symbols are then connected by a line, a curve or any other
+   --  link. These are called connectors.
+   --
+   --  Each symbol, in addition to being connected to the next one with a
+   --  connector, can also be linked to the axis X=0, Y=0 or Z=0 so that it is
+   --  easier to read its coordinates. These are called errbars, and they must
+   --  be explicitely shown.
+
+   procedure Set_Symbol
+     (Data         : access Gtk_Plot_Data_Record;
+      The_Type     : Plot_Symbol_Type;
+      Style        : Plot_Symbol_Style;
+      Size         : Gint;
+      Line_Width   : Gfloat;
+      Color        : Gdk.Color.Gdk_Color;
+      Border_Color : Gdk.Color.Gdk_Color);
+   --  Set the visual aspect of the symbols.
+
+   procedure Get_Symbol
+     (Data         : access Gtk_Plot_Data_Record;
+      The_Type     : out Plot_Symbol_Type;
+      Style        : out Plot_Symbol_Style;
+      Size         : out Gint;
+      Line_Width   : out Gint;
+      Color        : out Gdk.Color.Gdk_Color;
+      Border_Color : out Gdk.Color.Gdk_Color);
+   --  Return the visual characteristics of the symbols.
+
+   procedure Set_Connector
+     (Data : access Gtk_Plot_Data_Record; Connector : Plot_Connector);
+   --  Set the style of the connectors.
+
+   function Get_Connector (Data : access Gtk_Plot_Data_Record)
+      return Plot_Connector;
+   --  Return the connector style used for the data set.
+
+   procedure Set_Line_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color);
+   --  Set the line style used for the connectors.
+
+   procedure Get_Line_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : out Plot_Line_Style;
+      Cap_Style  : out Gdk.GC.Gdk_Cap_Style;
+      Join_Style : out Gdk.GC.Gdk_Join_Style;
+      Width      : out Gfloat;
+      Color      : out Gdk.Color.Gdk_Color);
+   --  Return the line attributes used for the connectors.
+
+   procedure Set_X_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color);
+   --  Set the style of the lines used to connect the symbols to the X axis.
+
+   procedure Set_Y_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color);
+   --  Set the style of the lines used to connect the symbols to the Y axis.
+
+   procedure Set_Z_Attributes
+     (Data       : access Gtk_Plot_Data_Record;
+      Style      : Plot_Line_Style;
+      Cap_Style  : Gdk.GC.Gdk_Cap_Style;
+      Join_Style : Gdk.GC.Gdk_Join_Style;
+      Width      : Gfloat;
+      Color      : Gdk.Color.Gdk_Color);
+   --  Set the style of the lines used to connect the symbols to the Z axis.
+
+   procedure Show_Xerrbars (Data : access Gtk_Plot_Data_Record);
+   procedure Show_Yerrbars (Data : access Gtk_Plot_Data_Record);
+   procedure Show_Zerrbars (Data : access Gtk_Plot_Data_Record);
+   --  Indicate that each symbol should be connected to the various axis
+
+   procedure Hide_Xerrbars (Data : access Gtk_Plot_Data_Record);
+   procedure Hide_Yerrbars (Data : access Gtk_Plot_Data_Record);
+   procedure Hide_Zerrbars (Data : access Gtk_Plot_Data_Record);
+   --  Indicate the the symbol should not be connected to the axis.
+
+   procedure Fill_Area (Data : access Gtk_Plot_Data_Record; Fill : Boolean);
+   --  Indicate whether the area between two points should be filled or not.
+
+   function Area_Is_Filled (Data : access Gtk_Plot_Data_Record)
+      return Boolean;
+   --  Indicate whether the area between two points is filled.
+
+   -------------
+   -- Legends --
+   -------------
+   --  In addition to the drawing corresponding to the data set, it is possible
+   --  to display a box that contains a legend. This is particulary useful when
+   --  multiple data sets are displayed on the same plot.
+
+   procedure Set_Legend (Data : access Gtk_Plot_Data_Record; Legend : String);
+   --  Set the string printed in the legend for that data set.
+   --  Note that an entry can exist in the legend even if there is no name
+   --  associated with the graph.
+
+   procedure Show_Legend (Data : access Gtk_Plot_Data_Record);
+   --  An entry will be made in the plot's legend for that dataset.
+
+   procedure Hide_Legend (Data : access Gtk_Plot_Data_Record);
+   --  No entry will appear in the plot's legend for that dataset.
+
+   procedure Set_Legend_Precision
+     (Data : access Gtk_Plot_Data_Record; Precision : Gint);
+   --  Number of digits to display when the legends is associated with values,
+   --  as is the case for gradients.
+
+   function Get_Legend_Precision (Data : access Gtk_Plot_Data_Record)
+      return Gint;
+   --  Return the number of digits used for values in the legend
+
+   ---------------
+   -- Gradients --
+   ---------------
+   --  The symbols displayed in the plot can be assigned specific colors. But
+   --  they can also compute their own color by picking it in a gradient,
+   --  depending on the value.
+
+   --  See function Gtk.Plot.Gradient
+
+   procedure Move_Gradient
+     (Data : access Gtk_Plot_Data_Record; X, Y : Gdouble);
+
+   procedure Set_Gradient_Size
+     (Data : access Gtk_Plot_Data_Record; Size : Gint);
+
+   procedure Reset_Gradient (Data : access Gtk_Plot_Data_Record);
+   --  Reset the gradient to its default value
+
+   procedure Reset_Gradient_Colors (Data : access Gtk_Plot_Data_Record);
+   --  Reset the colors of the gradient to their default values
+
+   procedure Gradient_Use_Custom_Colors
+     (Data : access Gtk_Plot_Data_Record; Custom : Boolean);
+   function Gradient_Custom_Colors
+     (Data : access Gtk_Plot_Data_Record) return Boolean;
+   --  Whether the gradient uses custom colors
+
+   procedure Set_Gradient_Mask
+     (Data : access Gtk_Plot_Data_Record; Mask : Plot_Gradient);
+   function Get_Gradient_Mask
+     (Data : access Gtk_Plot_Data_Record) return Plot_Gradient;
+   --  Set or Get how the component of the colors vary along the gradient.
+
+   procedure Gradient_Set_Visible
+     (Data : access Gtk_Plot_Data_Record; Visible : Boolean);
+   function Gradient_Visible
+     (Data : access Gtk_Plot_Data_Record) return Boolean;
+   --  Set or get whether the gradient is currently visible (this looks like a
+   --  legend for the plot)
+
+   procedure Gradient_Autoscale_A (Data : access Gtk_Plot_Data_Record);
+   procedure Gradient_Autoscale_Da (Data : access Gtk_Plot_Data_Record);
+   procedure Gradient_Autoscale_Z (Data : access Gtk_Plot_Data_Record);
+   --  ???
+
+   procedure Set_Gradient_Colors
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : Gdk.Color.Gdk_Color);
+   procedure Get_Gradient_Colors
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : out Gdk.Color.Gdk_Color);
+   --  Set or Get the colors that define the gradient. The colors will vary
+   --  from Min to Max along the components specified in Set_Gradient_Mask.
+
+   procedure Set_Gradient_Nth_Color
+     (Data  : access Gtk_Plot_Data_Record;
+      Level : Guint;
+      Color : Gdk.Color.Gdk_Color);
+   function Get_Gradient_Nth_Color
+     (Data  : access Gtk_Plot_Data_Record; Level : Guint)
+      return Gdk.Color.Gdk_Color;
+   --  Set or Get the nth color in the gradient
+
+   procedure Set_Gradient_Outer_Colors
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : Gdk.Color.Gdk_Color);
+   procedure Get_Gradient_Outer_Colors
+     (Data     : access Gtk_Plot_Data_Record;
+      Min, Max : out Gdk.Color.Gdk_Color);
+   --  Set the outer colors for the gradient
+
+   procedure Set_Gradient
+     (Data       : access Gtk_Plot_Data_Record;
+      Min, Max   : Gdouble;
+      Nlevels    : Gint;
+      Nsublevels : Gint);
+   procedure Get_Gradient
+     (Data       : access Gtk_Plot_Data_Record;
+      Min, Max   : out Gdouble;
+      Nlevels    : out Gint;
+      Nsublevels : out Gint);
+   --  Define the values associated with the minimal color and the maximal
+   --  color. Any value in between will have a color computed in between.
+   --  Nlevels is the number of ticks to display in the gradient.
+
+   procedure Get_Gradient_Level
+     (Data  : access Gtk_Plot_Data_Record;
+      Level : Gdouble;
+      Color : out Gdk.Color.Gdk_Color);
+   --  Return the color associated with a specific level.
+   --  The color depends on the parameters to Set_Gradient and
+   --  Set_Gradient_Colors.
+
+   procedure Gradient_Set_Style
+     (Data      : access Gtk_Plot_Data_Record;
+      Style     : Plot_Label_Style;
+      Precision : Gint);
+   --  ???
+
+   procedure Gradient_Set_Scale
+     (Data      : access Gtk_Plot_Data_Record;
+      Scale     : Plot_Scale);
+   --  Set the scale of the gradient
+
+   -------------
+   -- Markers --
+   -------------
+
+   function Add_Marker
+     (Data : access Gtk_Plot_Data_Record; Point : Guint)
+      return Gtk_Plot_Marker;
+   --  Add a new marker
+
+   procedure Remove_Marker
+     (Data : access Gtk_Plot_Data_Record; Marker : Gtk_Plot_Marker);
+   --  Remove a marker from the plot
+
+   procedure Remove_Markers (Data : access Gtk_Plot_Data_Record);
+   --  Remove all markers
+
+   procedure Show_Markers (Data : access Gtk_Plot_Data_Record; Show : Boolean);
+   --  Whether markers should be shown
+
+   function Markers_Visible
+     (Data : access Gtk_Plot_Data_Record) return Boolean;
+   --  Whether markers are currently visible
+
+   ---------------
+   -- User Data --
+   ---------------
+   --  It is possible to associated your own user data with a plot. This is
+   --  the mechanism provided by the C version of gtkextra. However, the best
+   --  way to do this in Ada is to inherit from Gtk_Plot_Data_Record (or one
+   --  of its children), and add your own fields.
+
+   procedure Set_Link
+     (Data : access Gtk_Plot_Data_Record;
+      Link : System.Address);
+   --  Associate some user data with Data.
+   --  It is the responsability of the user to do some convert conversion to
+   --  System.Address.
+
+   function Get_Link (Data : access Gtk_Plot_Data_Record)
+      return System.Address;
+   --  Return the user data associated with Data, or Null_Address if there is
+   --  none.
+
+   procedure Remove_Link (Data : access Gtk_Plot_Data_Record);
+   --  Remove the user data associated with Data.
+
+   --  <doc_ignore>
+   function To_Double_Array is new Unchecked_Conversion
+     (System.Address, No_Range_Gdouble_Array_Access);
+   --  </doc_ignore>
+
+private
+   type Gtk_Plot_Data_Record is new Gtk.Widget.Gtk_Widget_Record with
+     null record;
+
+   Gradient_H : constant Plot_Gradient := 1;
+   Gradient_V : constant Plot_Gradient := 2;
+   Gradient_S : constant Plot_Gradient := 4;
+
+   for Plot_Angle use
+     (Angle_0   => 0,
+      Angle_90  => 90,
+      Angle_180 => 180,
+      Angle_270 => 270);
+
+   pragma Import (C, Get_Type, "gtk_plot_data_get_type");
+end Gtk.Extra.Plot_Data;
+
+--  Unbound:
+--    gtk_plot_data_new_iterator
+--    gtk_plot_data_clone
+--    gtk_plot_data_get_gradient_outer_colors
+--    gtk_plot_data_add_dimension
+--    gtk_plot_data_remove_dimension
+--    gtk_plot_data_find_dimension
+--    gtk_plot_data_required_dimensions
+--    gtk_plot_data_independent_dimensions
+--    gtk_plot_data_dimension_set_array
+--    gtk_plot_data_dimension_get_array
+--    gtk_plot_data_get_point
+--    gtk_plot_get_gradient_allocation
+--  These subprograms appear in gtkplotdata.h, but not in gtkplotdata.c
+--    gtk_plot_data_dimension_set_scale
+--    gtk_plot_data_dimension_get_scale
============================================================
--- src/gtk-extra-plot_polar.adb	9f676a82ad85bff427bfc7b17b5b4008939e29bf
+++ src/gtk-extra-plot_polar.adb	9f676a82ad85bff427bfc7b17b5b4008939e29bf
@@ -0,0 +1,91 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                       Copyright (C) 2000                          --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                 Copyright (C) 2001-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Polar is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Polar_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Polar       : out Gtk_Plot_Polar;
+      Drawable      : Gdk.Drawable.Gdk_Drawable := null;
+      Width, Height : Gdouble := 0.0) is
+   begin
+      Polar := new Gtk_Plot_Polar_Record;
+      Initialize (Polar, Drawable, Width, Height);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Polar       : access Gtk_Plot_Polar_Record'Class;
+      Drawable      : Gdk.Drawable.Gdk_Drawable;
+      Width, Height : Gdouble := 0.0)
+   is
+      function Internal (Drawable : Gdk_Drawable) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_polar_new");
+
+      function Internal2
+        (Drawable : Gdk_Drawable; W, H : Gdouble) return System.Address;
+      pragma Import (C, Internal2, "gtk_plot_polar_new_with_size");
+   begin
+      if Width = 0.0 and then Height = 0.0 then
+         Set_Object (Polar, Internal (Drawable));
+      else
+         Set_Object (Polar, Internal2 (Drawable, Width, Height));
+      end if;
+   end Initialize;
+
+   ------------
+   -- Rotate --
+   ------------
+
+   procedure Rotate (Polar : access Gtk_Plot_Polar_Record; Angle : Gdouble) is
+      procedure Internal (Polar : System.Address; Angle : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_polar_rotate");
+   begin
+      Internal (Get_Object (Polar), Angle);
+   end Rotate;
+
+   ---------------
+   -- Get_Angle --
+   ---------------
+
+   function Get_Angle (Polar : access Gtk_Plot_Polar_Record) return Gdouble is
+      function Internal (Polar : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_polar_get_angle");
+   begin
+      return Internal (Get_Object (Polar));
+   end Get_Angle;
+
+end Gtk.Extra.Plot_Polar;
============================================================
--- src/gtk-extra-plot_polar.ads	0d166b1916130270f744ed86a042b4930718a082
+++ src/gtk-extra-plot_polar.ads	0d166b1916130270f744ed86a042b4930718a082
@@ -0,0 +1,67 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  This special type of data set displays itself in polar coordinates.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gtk.Extra.Plot;
+with Gdk.Drawable;
+
+package Gtk.Extra.Plot_Polar is
+
+   type Gtk_Plot_Polar_Record is new Gtk.Extra.Plot.Gtk_Plot_Record
+     with private;
+   type Gtk_Plot_Polar is access all Gtk_Plot_Polar_Record'Class;
+
+   procedure Gtk_New
+     (Polar         : out Gtk_Plot_Polar;
+      Drawable      : Gdk.Drawable.Gdk_Drawable := null;
+      Width, Height : Gdouble := 0.0);
+   --  Create a new polar plot.
+   --  If Width and Height are 0, they are left unspecified when calling the
+   --  C function.
+
+   procedure Initialize
+     (Polar         : access Gtk_Plot_Polar_Record'Class;
+      Drawable      : Gdk.Drawable.Gdk_Drawable;
+      Width, Height : Gdouble := 0.0);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Box
+
+   procedure Rotate (Polar : access Gtk_Plot_Polar_Record; Angle : Gdouble);
+   --  Rotate the graph by a given amount of radians.
+
+   function Get_Angle (Polar : access Gtk_Plot_Polar_Record) return Gdouble;
+   --  Return the current angle for the polar plot
+
+private
+   type Gtk_Plot_Polar_Record is new Gtk.Extra.Plot.Gtk_Plot_Record
+     with null record;
+   pragma Import (C, Get_Type, "gtk_plot_polar_get_type");
+end Gtk.Extra.Plot_Polar;
============================================================
--- src/gtk-extra-plot_ps.adb	52cddc14b96f05b9f14c9a60fd49618ab3dbb67f
+++ src/gtk-extra-plot_ps.adb	52cddc14b96f05b9f14c9a60fd49618ab3dbb67f
@@ -0,0 +1,149 @@
+-----------------------------------------------------------------------
+--          GtkAda - Ada95 binding for the Gimp Toolkit              --
+--                                                                   --
+--                     Copyright (C) 2000                            --
+--        Emmanuel Briot, Joel Brobecker and Arnaud Charlet          --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Gtk.Extra.Plot;        use Gtk.Extra.Plot;
+with System;
+
+package body Gtk.Extra.Plot_Ps is
+
+   --------------------
+   -- Plot_Export_Ps --
+   --------------------
+
+   procedure Plot_Export_Ps
+      (Plot        : access Gtk.Extra.Plot.Gtk_Plot_Record'Class;
+       Psfile      : in String;
+       Orientation : in Ps_Orientation;
+       Epsflag     : in Boolean;
+       Page_Size   : in Ps_Page_Size)
+   is
+      procedure Internal
+        (Plot        : System.Address;
+         Psfile      : String;
+         Orientation : Ps_Orientation;
+         Epsflag     : Gint;
+         Page_Size   : Ps_Page_Size);
+      pragma Import (C, Internal, "gtk_plot_export_ps");
+
+   begin
+      Internal (Get_Object (Plot),
+                Psfile & ASCII.NUL,
+                Orientation,
+                Boolean'Pos (Epsflag),
+                Page_Size);
+   end Plot_Export_Ps;
+
+   ------------------------------
+   -- Plot_Export_Ps_With_Size --
+   ------------------------------
+
+   procedure Plot_Export_Ps_With_Size
+      (Plot        : access Gtk.Extra.Plot.Gtk_Plot_Record'Class;
+       Psfile      : in String;
+       Orientation : in Ps_Orientation;
+       Epsflag     : in Boolean;
+       Units       : in Ps_Units;
+       Width       : in Gint;
+       Height      : in Gint)
+   is
+      procedure Internal
+        (Plot        : System.Address;
+         Psfile      : String;
+         Orientation : Ps_Orientation;
+         Epsflag     : Gint;
+         Units       : Ps_Units;
+         Width       : Gint;
+         Height      : Gint);
+      pragma Import (C, Internal, "gtk_plot_export_ps_with_size");
+
+   begin
+      Internal (Get_Object (Plot),
+                Psfile & ASCII.NUL,
+                Orientation,
+                Boolean'Pos (Epsflag),
+                Units,
+                Width,
+                Height);
+   end Plot_Export_Ps_With_Size;
+
+   ---------------------------
+   -- Plot_Canvas_Export_Ps --
+   ---------------------------
+
+   procedure Plot_Canvas_Export_Ps
+      (Canvas      : access Gtk.Extra.Plot_Canvas.Gtk_Plot_Canvas_Record'Class;
+       File_Name   : in String;
+       Orientation : in Ps_Orientation;
+       Epsflag     : in Boolean;
+       Page_Size   : in Ps_Page_Size)
+   is
+      procedure Internal
+        (Canvas      : System.Address;
+         File_Name   : String;
+         Orientation : Ps_Orientation;
+         Epsflag     : Gint;
+         Page_Size   : Ps_Page_Size);
+      pragma Import (C, Internal, "gtk_plot_canvas_export_ps");
+
+   begin
+      Internal (Get_Object (Canvas),
+                File_Name & ASCII.NUL,
+                Orientation,
+                Boolean'Pos (Epsflag),
+                Page_Size);
+   end Plot_Canvas_Export_Ps;
+
+   -------------------------------------
+   -- Plot_Canvas_Export_Ps_With_Size --
+   -------------------------------------
+
+   procedure Plot_Canvas_Export_Ps_With_Size
+      (Canvas      : access Gtk.Extra.Plot_Canvas.Gtk_Plot_Canvas_Record'Class;
+       File_Name   : in String;
+       Orientation : in Ps_Orientation;
+       Epsflag     : in Boolean;
+       Units       : in Ps_Units;
+       Width       : in Gint;
+       Height      : in Gint)
+   is
+      procedure Internal
+        (Canvas      : System.Address;
+         File_Name   : String;
+         Orientation : Ps_Orientation;
+         Epsflag     : Gint;
+         Units       : Ps_Units;
+         Width       : Gint;
+         Height      : Gint);
+      pragma Import (C, Internal, "gtk_plot_canvas_export_ps_with_size");
+
+   begin
+      Internal (Get_Object (Canvas),
+                File_Name & ASCII.NUL,
+                Orientation,
+                Boolean'Pos (Epsflag),
+                Units,
+                Width,
+                Height);
+   end Plot_Canvas_Export_Ps_With_Size;
+
+end Gtk.Extra.Plot_Ps;
============================================================
--- src/gtk-extra-plot_ps.ads	38865cdbfcb48472719da41d3d5a09220b9565a4
+++ src/gtk-extra-plot_ps.ads	38865cdbfcb48472719da41d3d5a09220b9565a4
@@ -0,0 +1,113 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  This package does not implement any new widget.
+--  Instead, if provides postscript support for Gtk_Plot widgets, and can
+--  create a postscript file from any Gtk_Plot widget.
+--  </description>
+--  This is a binding to gtkplotprint.h
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gtk.Extra.Plot;
+with Gtk.Extra.Plot_Canvas;  use Gtk.Extra.Plot_Canvas;
+
+package Gtk.Extra.Plot_Ps is
+
+   type Ps_Page_Size is
+     (Plot_Letter,
+      Plot_Legal,
+      Plot_A4,
+      Plot_Executive,
+      Plot_Custom);
+   --  The formats that can be used for paper sizes.
+   pragma Convention (C, Ps_Page_Size);
+
+   type Ps_Orientation is (Plot_Portrait, Plot_Landscape);
+   --  Portrait format means that the vertical size is longer than
+   --  the horizontal size. Landscape is the reverse.
+   pragma Convention (C, Ps_Orientation);
+
+   type Ps_Units is (Plot_Inches, Plot_Mm, Plot_Cm, Plot_Pspoints);
+   --  Units of measure for paper sizes.
+   pragma Convention (C, Ps_Units);
+
+   procedure Plot_Export_Ps
+     (Plot        : access Gtk.Extra.Plot.Gtk_Plot_Record'Class;
+      Psfile      : String;
+      Orientation : Ps_Orientation;
+      Epsflag     : Boolean;
+      Page_Size   : Ps_Page_Size);
+   --  Create a new postscript file PsFile with the content of Plot.
+   --  Epsflag should be true if the generated file should be in
+   --  Encapsulated Postscript format instead of simple Postscript.
+
+   procedure Plot_Export_Ps_With_Size
+     (Plot        : access Gtk.Extra.Plot.Gtk_Plot_Record'Class;
+      Psfile      : in String;
+      Orientation : in Ps_Orientation;
+      Epsflag     : in Boolean;
+      Units       : in Ps_Units;
+      Width       : in Gint;
+      Height      : in Gint);
+   --  Create a new postscript file PsFile with the content of Plot.
+   --  Epsflag should be true if the generated file should be in
+   --  Encapsulated Postscript format instead of simple Postscript.
+   --  The page has a custom size.
+
+   procedure Plot_Canvas_Export_Ps
+     (Canvas      : access Gtk_Plot_Canvas_Record'Class;
+      File_Name   : in String;
+      Orientation : in Ps_Orientation;
+      Epsflag     : in Boolean;
+      Page_Size   : in Ps_Page_Size);
+   --  Create a new postscript file PsFile with the content of Canvas.
+   --  Every plot on it is exported to the postscript file.
+   --  Epsflag should be true if the generated file should be in
+   --  Encapsulated Postscript format instead of simple Postscript.
+
+   procedure Plot_Canvas_Export_Ps_With_Size
+     (Canvas      : access Gtk_Plot_Canvas_Record'Class;
+      File_Name   : in String;
+      Orientation : in Ps_Orientation;
+      Epsflag     : in Boolean;
+      Units       : in Ps_Units;
+      Width       : in Gint;
+      Height      : in Gint);
+   --  Create a new postscript file PsFile with the content of Canvas.
+   --  Every plot on it is exported to the postscript file.
+   --  Epsflag should be true if the generated file should be in
+   --  Encapsulated Postscript format instead of simple Postscript.
+   --  The page has a custom size.
+
+   --  Unbound:
+   --     gtk_plot_ps_get_type
+   --     gtk_plot_ps_new
+   --     gtk_plot_ps_new_with_size
+   --     gtk_plot_ps_construct
+   --     gtk_plot_ps_construct_with_size
+   --     gtk_plot_ps_set_size
+   --     gtk_plot_ps_set_scale
+
+end Gtk.Extra.Plot_Ps;
============================================================
--- src/gtk-extra-plot_surface.adb	fc762d6b378ea57c9c4b6288bcc1352b62dc6efc
+++ src/gtk-extra-plot_surface.adb	fc762d6b378ea57c9c4b6288bcc1352b62dc6efc
@@ -0,0 +1,477 @@
+-----------------------------------------------------------------------
+--              GtkAda - Ada95 binding for Gtk+/Gnome                --
+--                                                                   --
+--                Copyright (C) 2001-2008, AdaCore                   --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with System;
+
+with Gdk.Color;              use Gdk.Color;
+with Gtk.Extra.Plot;         use Gtk.Extra.Plot;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Plot_Surface is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Plot_Surface_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Widget : out Gtk_Plot_Surface; Func : Plot3D_Function := null) is
+   begin
+      Widget := new Gtk_Plot_Surface_Record;
+      Initialize (Widget, Func);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Widget : access Gtk_Plot_Surface_Record'Class;
+      Func : Plot3D_Function := null)
+   is
+      function Internal return System.Address;
+      pragma Import (C, Internal, "gtk_plot_surface_new");
+
+      function Internal2 (Func : Plot3D_Function) return System.Address;
+      pragma Import (C, Internal2, "gtk_plot_surface_new_function");
+   begin
+      if Func = null then
+         Set_Object (Widget, Internal);
+      else
+         Set_Object (Widget, Internal2 (Func));
+      end if;
+   end Initialize;
+
+   ----------------------
+   -- Get_Grid_Visible --
+   ----------------------
+
+   function Get_Grid_Visible
+     (Data : access Gtk_Plot_Surface_Record) return Boolean
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_surface_get_grid_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Data)));
+   end Get_Grid_Visible;
+
+   ----------------------
+   -- Get_Mesh_Visible --
+   ----------------------
+
+   function Get_Mesh_Visible
+     (Data : access Gtk_Plot_Surface_Record) return Boolean
+   is
+      function Internal (Data : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_surface_get_mesh_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Data)));
+   end Get_Mesh_Visible;
+
+   ------------
+   -- Get_Nx --
+   ------------
+
+   function Get_Nx (Data : access Gtk_Plot_Surface_Record) return Gint is
+      function Internal (Data   : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_surface_get_nx");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Nx;
+
+   ------------
+   -- Get_Ny --
+   ------------
+
+   function Get_Ny (Data : access Gtk_Plot_Surface_Record) return Gint is
+      function Internal (Data   : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_plot_surface_get_ny");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Ny;
+
+   ----------------
+   -- Get_Points --
+   ----------------
+
+   procedure Get_Points
+     (Data : access Gtk_Plot_Surface_Record;
+      X    : out Points_Array;
+      Y    : out Points_Array;
+      Z    : out Points_Array;
+      Dx   : out Points_Array;
+      Dy   : out Points_Array;
+      Dz   : out Points_Array)
+   is
+      procedure Internal
+        (Data : System.Address;
+         X    : out System.Address;
+         Y    : out System.Address;
+         Z    : out System.Address;
+         Dx   : out System.Address;
+         Dy   : out System.Address;
+         Dz   : out System.Address;
+         Nx   : out Gint;
+         Ny   : out Gint);
+      pragma Import (C, Internal, "gtk_plot_surface_get_points");
+      Nx, Ny : Gint;
+      X1, Y1, Z1, Dx1, Dy1, Dz1 : System.Address;
+   begin
+      Internal (Get_Object (Data), X1, Y1, Z1, Dx1, Dy1, Dz1, Nx, Ny);
+      X  := (Points => To_Double_Array (X1),  Num_Points => Nx);
+      Y  := (Points => To_Double_Array (Y1),  Num_Points => Ny);
+      Z  := (Points => To_Double_Array (Z1),  Num_Points => Nx * Ny);
+      Dx := (Points => To_Double_Array (Dx1), Num_Points => Nx);
+      Dy := (Points => To_Double_Array (Dy1), Num_Points => Ny);
+      Dz := (Points => To_Double_Array (Dy1), Num_Points => Nx * Ny);
+   end Get_Points;
+
+   -----------
+   -- Get_X --
+   -----------
+
+   function Get_X (Data : access Gtk_Plot_Surface_Record) return Points_Array
+   is
+      function Internal (Data : System.Address; Nx : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_surface_get_x");
+      N : aliased Gint;
+      X : constant System.Address := Internal (Get_Object (Data), N'Address);
+
+   begin
+      return (To_Double_Array (X), N);
+   end Get_X;
+
+   ---------------
+   -- Get_Xstep --
+   ---------------
+
+   function Get_Xstep (Data : access Gtk_Plot_Surface_Record) return Gdouble is
+      function Internal (Data   : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_surface_get_xstep");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Xstep;
+
+   -----------
+   -- Get_Y --
+   -----------
+
+   function Get_Y
+     (Data : access Gtk_Plot_Surface_Record) return Points_Array
+   is
+      function Internal
+        (Data : System.Address; Ny : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_plot_surface_get_y");
+
+      N : aliased Gint;
+      Y : constant System.Address := Internal (Get_Object (Data), N'Address);
+
+   begin
+      return (To_Double_Array (Y), N);
+   end Get_Y;
+
+   ---------------
+   -- Get_Ystep --
+   ---------------
+
+   function Get_Ystep (Data : access Gtk_Plot_Surface_Record) return Gdouble
+   is
+      function Internal (Data : System.Address) return Gdouble;
+      pragma Import (C, Internal, "gtk_plot_surface_get_ystep");
+   begin
+      return Internal (Get_Object (Data));
+   end Get_Ystep;
+
+   -----------
+   -- Get_Z --
+   -----------
+
+   function Get_Z (Data : access Gtk_Plot_Surface_Record) return Points_Array
+   is
+      function Internal (Data : System.Address; Nz : System.Address)
+         return System.Address;
+      pragma Import (C, Internal, "gtk_plot_surface_get_z");
+      N : aliased Gint;
+      Z : constant System.Address := Internal (Get_Object (Data), N'Address);
+
+   begin
+      return (To_Double_Array (Z), N);
+   end Get_Z;
+
+   -----------------
+   -- Set_Ambient --
+   -----------------
+
+   procedure Set_Ambient
+     (Data : access Gtk_Plot_Surface_Record; Ambient : Gdouble)
+   is
+      procedure Internal (Data : System.Address; Ambient : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_surface_set_ambient");
+   begin
+      Internal (Get_Object (Data), Ambient);
+   end Set_Ambient;
+
+   ---------------
+   -- Set_Color --
+   ---------------
+
+   procedure Set_Color
+     (Data  : access Gtk_Plot_Surface_Record; Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data  : System.Address; Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_surface_set_color");
+      C : aliased Gdk_Color := Color;
+   begin
+      Internal (Get_Object (Data), C'Address);
+   end Set_Color;
+
+   -------------------------
+   -- Set_Grid_Background --
+   -------------------------
+
+   procedure Set_Grid_Background
+     (Data       : access Gtk_Plot_Surface_Record;
+      Background : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data : System.Address; Background : System.Address);
+      pragma Import (C, Internal, "gtk_plot_surface_set_grid_background");
+      C : aliased Gdk_Color := Background;
+   begin
+      Internal (Get_Object (Data), C'Address);
+   end Set_Grid_Background;
+
+   -------------------------
+   -- Set_Grid_Foreground --
+   -------------------------
+
+   procedure Set_Grid_Foreground
+     (Data       : access Gtk_Plot_Surface_Record;
+      Foreground : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data : System.Address; Foreground : System.Address);
+      pragma Import (C, Internal, "gtk_plot_surface_set_grid_foreground");
+      C : aliased Gdk_Color := Foreground;
+   begin
+      Internal (Get_Object (Data), C'Address);
+   end Set_Grid_Foreground;
+
+   ----------------------
+   -- Set_Grid_Visible --
+   ----------------------
+
+   procedure Set_Grid_Visible
+     (Data : access Gtk_Plot_Surface_Record; Visible : Boolean)
+   is
+      procedure Internal (Data : System.Address; Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_surface_set_grid_visible");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Visible));
+   end Set_Grid_Visible;
+
+   ---------------
+   -- Set_Light --
+   ---------------
+
+   procedure Set_Light
+     (Data : access Gtk_Plot_Surface_Record; X, Y, Z : Gdouble)
+   is
+      procedure Internal (Data : System.Address; X, Y, Z : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_surface_set_light");
+   begin
+      Internal (Get_Object (Data), X, Y, Z);
+   end Set_Light;
+
+   ----------------------
+   -- Set_Mesh_Visible --
+   ----------------------
+
+   procedure Set_Mesh_Visible
+     (Data : access Gtk_Plot_Surface_Record; Visible : Boolean)
+   is
+      procedure Internal (Data    : System.Address; Visible : Gint);
+      pragma Import (C, Internal, "gtk_plot_surface_set_mesh_visible");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Visible));
+   end Set_Mesh_Visible;
+
+   ------------
+   -- Set_Nx --
+   ------------
+
+   procedure Set_Nx (Data : access Gtk_Plot_Surface_Record; Nx : Gint) is
+      procedure Internal (Data : System.Address; Nx   : Gint);
+      pragma Import (C, Internal, "gtk_plot_surface_set_nx");
+   begin
+      Internal (Get_Object (Data), Nx);
+   end Set_Nx;
+
+   ------------
+   -- Set_Ny --
+   ------------
+
+   procedure Set_Ny (Data : access Gtk_Plot_Surface_Record; Ny : Gint) is
+      procedure Internal (Data : System.Address; Ny   : Gint);
+      pragma Import (C, Internal, "gtk_plot_surface_set_ny");
+   begin
+      Internal (Get_Object (Data), Ny);
+   end Set_Ny;
+
+   ----------------
+   -- Set_Points --
+   ----------------
+
+   procedure Set_Points
+     (Data : access Gtk_Plot_Surface_Record;
+      X    : Gdouble_Array_Access;
+      Y    : Gdouble_Array_Access;
+      Z    : Gdouble_Array_Access;
+      Dx   : Gdouble_Array_Access;
+      Dy   : Gdouble_Array_Access;
+      Dz   : Gdouble_Array_Access)
+   is
+      procedure Internal
+        (Data : System.Address;
+         X    : System.Address;
+         Y    : System.Address;
+         Z    : System.Address;
+         Dx   : System.Address;
+         Dy   : System.Address;
+         Dz   : System.Address;
+         Nx   : Gint;
+         Ny   : Gint);
+      pragma Import (C, Internal, "gtk_plot_surface_set_points");
+   begin
+      pragma Assert (X'Length = Dx'Length);
+      pragma Assert (Y'Length = Dy'Length);
+      pragma Assert (Z'Length = Dz'Length);
+      pragma Assert (Z'Length = X'Length * Y'Length);
+      Internal (Get_Object (Data),
+                X (X'First)'Address, Y (Y'First)'Address, Z (Z'First)'Address,
+                Dx (Dx'First)'Address, Dy (Dy'First)'Address,
+                Dz (Dz'First)'Address, X'Length, Y'Length);
+   end Set_Points;
+
+   ----------------
+   -- Set_Shadow --
+   ----------------
+
+   procedure Set_Shadow
+     (Data  : access Gtk_Plot_Surface_Record; Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Data  : System.Address; Color : System.Address);
+      pragma Import (C, Internal, "gtk_plot_surface_set_shadow");
+      C : aliased Gdk_Color := Color;
+   begin
+      Internal (Get_Object (Data), C'Address);
+   end Set_Shadow;
+
+   ---------------
+   -- Set_Xstep --
+   ---------------
+
+   procedure Set_Xstep (Data : access Gtk_Plot_Surface_Record; Step : Gdouble)
+   is
+      procedure Internal (Data  : System.Address; Xstep : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_surface_set_xstep");
+   begin
+      Internal (Get_Object (Data), Step);
+   end Set_Xstep;
+
+   ---------------
+   -- Set_Ystep --
+   ---------------
+
+   procedure Set_Ystep (Data : access Gtk_Plot_Surface_Record; Step : Gdouble)
+   is
+      procedure Internal (Data  : System.Address; Ystep : Gdouble);
+      pragma Import (C, Internal, "gtk_plot_surface_set_ystep");
+   begin
+      Internal (Get_Object (Data), Step);
+   end Set_Ystep;
+
+   ----------------
+   -- Build_Mesh --
+   ----------------
+
+   procedure Build_Mesh (Data : access Gtk_Plot_Surface_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_surface_build_mesh");
+   begin
+      Internal (Get_Object (Data));
+   end Build_Mesh;
+
+   ------------------
+   -- Recalc_Nodes --
+   ------------------
+
+   procedure Recalc_Nodes (Data : access Gtk_Plot_Surface_Record) is
+      procedure Internal (Data : System.Address);
+      pragma Import (C, Internal, "gtk_plot_surface_recalc_nodes");
+   begin
+      Internal (Get_Object (Data));
+   end Recalc_Nodes;
+
+   -------------------------
+   -- Use_Height_Gradient --
+   -------------------------
+
+   procedure Use_Height_Gradient
+     (Data : access Gtk_Plot_Surface_Record; Use_Gradient : Boolean)
+   is
+      procedure Internal (Data : System.Address; Gradient : Integer);
+      pragma Import (C, Internal, "gtk_plot_surface_use_height_gradient");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Use_Gradient));
+   end Use_Height_Gradient;
+
+   ------------------
+   -- Use_Amplitud --
+   ------------------
+
+   procedure Use_Amplitud
+     (Data : access Gtk_Plot_Surface_Record; Amplitud : Boolean)
+   is
+      procedure Internal (Data : System.Address; Amplitud : Integer);
+      pragma Import (C, Internal, "gtk_plot_surface_use_amplitud");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Amplitud));
+   end Use_Amplitud;
+
+   ---------------------
+   -- Set_Transparent --
+   ---------------------
+
+   procedure Set_Transparent
+     (Data : access Gtk_Plot_Surface_Record; Transparent : Boolean)
+   is
+      procedure Internal (Data : System.Address; Transparent : Integer);
+      pragma Import (C, Internal, "gtk_plot_surface_set_transparent");
+   begin
+      Internal (Get_Object (Data), Boolean'Pos (Transparent));
+   end Set_Transparent;
+
+end Gtk.Extra.Plot_Surface;
============================================================
--- src/gtk-extra-plot_surface.ads	cdbe49226340d455231d235bd6af6f8bb03264db
+++ src/gtk-extra-plot_surface.ads	cdbe49226340d455231d235bd6af6f8bb03264db
@@ -0,0 +1,192 @@
+-----------------------------------------------------------------------
+--              GtkAda - Ada95 binding for Gtk+/Gnome                --
+--                                                                   --
+--                     Copyright (C) 2001-2006                       --
+--                         AdaCore                                   --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A special kind of data set that stores three-dimensional data.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>Plotting Data</group>
+
+with Gdk.Color;
+with Gtk;
+with Gtk.Extra.Plot_Data;    use Gtk.Extra.Plot_Data;
+with Gtk.Extra.Plot;
+
+package Gtk.Extra.Plot_Surface is
+
+   type Gtk_Plot_Surface_Record is new Gtk.Extra.Plot_Data.Gtk_Plot_Data_Record
+     with private;
+   type Gtk_Plot_Surface is access all Gtk_Plot_Surface_Record'Class;
+
+   type Gtk_Plot_Polygon is new Gdk.C_Proxy;
+
+   procedure Gtk_New
+     (Widget : out Gtk_Plot_Surface;
+      Func   : Gtk.Extra.Plot.Plot3D_Function := null);
+   --  Create a new surface.
+   --  If Func is null, you have to explicitely specify the set of points
+   --  found in the data set. Otherwise, the points will be generated
+   --  automatically from Func.
+
+   procedure Initialize
+     (Widget : access Gtk_Plot_Surface_Record'Class;
+      Func   : Gtk.Extra.Plot.Plot3D_Function := null);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with this widget.
+
+   function Get_Grid_Visible
+     (Data : access Gtk_Plot_Surface_Record) return Boolean;
+   --  Return True if the grid is currently visible for this data set.
+
+   procedure Set_Grid_Visible
+     (Data : access Gtk_Plot_Surface_Record; Visible : Boolean);
+   --  Choose whether the grid should be visible
+
+   function Get_Mesh_Visible
+     (Data : access Gtk_Plot_Surface_Record) return Boolean;
+   --  Return True if the wireframe mesh should be drawn.
+
+   procedure Set_Mesh_Visible
+     (Data    : access Gtk_Plot_Surface_Record; Visible : Boolean);
+   --  Indicate whether the wireframe mesh should be visible.
+
+   function Get_Nx (Data : access Gtk_Plot_Surface_Record) return Gint;
+   function Get_Ny (Data : access Gtk_Plot_Surface_Record) return Gint;
+   --  Return the number of points along each coordinate, when drawing a
+   --  data set based on a function.
+
+   procedure Set_Nx (Data : access Gtk_Plot_Surface_Record; Nx : Gint);
+   procedure Set_Ny (Data : access Gtk_Plot_Surface_Record; Ny : Gint);
+   --  Set the number of points along each coordinate
+
+   procedure Set_Points
+     (Data : access Gtk_Plot_Surface_Record;
+      X    : Gdouble_Array_Access;
+      Y    : Gdouble_Array_Access;
+      Z    : Gdouble_Array_Access;
+      Dx   : Gdouble_Array_Access;
+      Dy   : Gdouble_Array_Access;
+      Dz   : Gdouble_Array_Access);
+   --  Set all the values of the data set at once.
+
+   procedure Get_Points
+     (Data : access Gtk_Plot_Surface_Record;
+      X    : out Points_Array;
+      Y    : out Points_Array;
+      Z    : out Points_Array;
+      Dx   : out Points_Array;
+      Dy   : out Points_Array;
+      Dz   : out Points_Array);
+   --  Return the values contained in the data set.
+
+   function Get_X (Data : access Gtk_Plot_Surface_Record) return Points_Array;
+   function Get_Y (Data : access Gtk_Plot_Surface_Record) return Points_Array;
+   function Get_Z (Data : access Gtk_Plot_Surface_Record) return Points_Array;
+   --  Return the values contained in the data set.
+
+   function Get_Xstep (Data : access Gtk_Plot_Surface_Record) return Gdouble;
+   function Get_Ystep (Data : access Gtk_Plot_Surface_Record) return Gdouble;
+   --  Return the step between two points along one of the axis
+
+   procedure Set_Xstep (Data : access Gtk_Plot_Surface_Record; Step : Gdouble);
+   procedure Set_Ystep (Data : access Gtk_Plot_Surface_Record; Step : Gdouble);
+   --  Set the step between two points along one of the axis
+
+   procedure Set_Color
+     (Data  : access Gtk_Plot_Surface_Record; Color : Gdk.Color.Gdk_Color);
+   --  Set the color to use for the surface
+
+   procedure Set_Shadow
+     (Data  : access Gtk_Plot_Surface_Record; Color : Gdk.Color.Gdk_Color);
+   --  Set the color to use for the shadows.
+
+   procedure Set_Grid_Foreground
+     (Data       : access Gtk_Plot_Surface_Record;
+      Foreground : Gdk.Color.Gdk_Color);
+   --  Set the foreground color to use for the grid
+
+   procedure Set_Grid_Background
+     (Data       : access Gtk_Plot_Surface_Record;
+      Background : Gdk.Color.Gdk_Color);
+   --  Set the background color to use for the grid
+
+   procedure Set_Transparent
+     (Data : access Gtk_Plot_Surface_Record; Transparent : Boolean);
+   --  Whether the plot is transparent. If Transparent is true, all background
+   --  attributes are ignored
+
+   procedure Build_Mesh (Data : access Gtk_Plot_Surface_Record);
+   --  ???
+
+   procedure Recalc_Nodes (Data : access Gtk_Plot_Surface_Record);
+   --  ???
+
+   ---------------------
+   -- Lightning model --
+   ---------------------
+
+   procedure Set_Ambient
+     (Data : access Gtk_Plot_Surface_Record; Ambient : Gdouble);
+   --  Set the ambient
+
+   procedure Set_Light
+     (Data : access Gtk_Plot_Surface_Record; X, Y, Z : Gdouble);
+   --  Set the orientation of the light vector
+
+   procedure Use_Height_Gradient
+     (Data : access Gtk_Plot_Surface_Record; Use_Gradient : Boolean);
+   --  ???
+
+   procedure Use_Amplitud
+     (Data : access Gtk_Plot_Surface_Record; Amplitud : Boolean);
+
+   -------------
+   -- Signals --
+   -------------
+
+   --  <signals>
+   --  The following new signals are defined for this widget:
+   --  </signals>
+
+private
+   type Gtk_Plot_Surface_Record is new Gtk.Extra.Plot_Data.Gtk_Plot_Data_Record
+     with null record;
+   pragma Import (C, Get_Type, "gtk_plot_surface_get_type");
+
+   --  Not bound, since these duplicates exactly functions from
+   --  Gtk.Extra.Plot_Data:
+   --     gtk_plot_surface_set_x
+   --     gtk_plot_surface_set_y
+   --     gtk_plot_surface_set_z
+   --     gtk_plot_surface_set_dx
+   --     gtk_plot_surface_set_dy
+   --     gtk_plot_surface_set_dz
+   --     gtk_plot_surface_get_dx
+   --     gtk_plot_surface_get_dy
+   --     gtk_plot_surface_get_dz
+   --  </doc_ignore>
+
+end Gtk.Extra.Plot_Surface;
============================================================
--- src/gtk-extra-sheet.adb	1bf8fc6a372cb9a70103307fb5b18fc8c268dc78
+++ src/gtk-extra-sheet.adb	1bf8fc6a372cb9a70103307fb5b18fc8c268dc78
@@ -0,0 +1,2017 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                 Copyright (C) 2000-2008, AdaCore                  --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+with Interfaces.C.Strings; use Interfaces.C.Strings;
+with System;
+with Unchecked_Conversion;
+
+with Gdk.Color;            use Gdk.Color;
+with Pango.Font;           use Pango.Font;
+
+with Glib.Type_Conversion_Hooks;
+
+package body Gtk.Extra.Sheet is
+
+   package Type_Conversion is new Glib.Type_Conversion_Hooks.Hook_Registrator
+     (Get_Type'Access, Gtk_Sheet_Record);
+   pragma Warnings (Off, Type_Conversion);
+
+   -------------
+   -- Gtk_New --
+   -------------
+
+   procedure Gtk_New
+     (Sheet      : out Gtk_Sheet;
+      Rows       : Guint;
+      Columns    : Guint;
+      Title      : UTF8_String := "";
+      Entry_Type : Gtk_Type := GType_Invalid) is
+   begin
+      Sheet := new Gtk_Sheet_Record;
+      Initialize (Sheet, Rows, Columns, Title, Entry_Type);
+   end Gtk_New;
+
+   ----------------
+   -- Initialize --
+   ----------------
+
+   procedure Initialize
+     (Sheet      : access Gtk_Sheet_Record'Class;
+      Rows       : Guint;
+      Columns    : Guint;
+      Title      : UTF8_String := "";
+      Entry_Type : Gtk_Type := GType_Invalid)
+   is
+      function Internal
+        (Rows    : Guint;
+         Columns : Guint;
+         Title   : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_new");
+
+      function Internal2
+        (Rows       : Guint;
+         Columns    : Guint;
+         Title      : System.Address;
+         Entry_Type : Gtk_Type) return System.Address;
+      pragma Import (C, Internal2, "gtk_sheet_new_with_custom_entry");
+
+      S  : aliased UTF8_String := Title & ASCII.NUL;
+      Sa : System.Address := S'Address;
+
+   begin
+      if Title = "" then
+         Sa := System.Null_Address;
+      end if;
+
+      if Entry_Type /= GType_Invalid then
+         Set_Object (Sheet, Internal2 (Rows, Columns, Sa, Entry_Type));
+      else
+         Set_Object (Sheet, Internal (Rows, Columns, Sa));
+      end if;
+   end Initialize;
+
+   ---------------------
+   -- Gtk_New_Browser --
+   ---------------------
+
+   procedure Gtk_New_Browser
+     (Sheet   : out Gtk_Sheet;
+      Rows    : Guint;
+      Columns : Guint;
+      Title   : UTF8_String := "") is
+   begin
+      Sheet := new Gtk_Sheet_Record;
+      Initialize_Browser (Sheet, Rows, Columns, Title);
+   end Gtk_New_Browser;
+
+   ------------------------
+   -- Initialize_Browser --
+   ------------------------
+
+   procedure Initialize_Browser
+     (Sheet   : access Gtk_Sheet_Record'Class;
+      Rows    : Guint;
+      Columns : Guint;
+      Title   : UTF8_String := "")
+   is
+      function Internal
+        (Rows    : Guint;
+         Columns : Guint;
+         Title   : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_new_browser");
+
+      S  : aliased UTF8_String := Title & ASCII.NUL;
+      Sa : System.Address := S'Address;
+
+   begin
+      if Title = "" then
+         Sa := System.Null_Address;
+      end if;
+
+      Set_Object (Sheet, Internal (Rows, Columns, Sa));
+   end Initialize_Browser;
+
+   ---------------------
+   -- Set_Hadjustment --
+   ---------------------
+
+   procedure Set_Hadjustment
+     (Sheet      : access Gtk_Sheet_Record;
+      Adjustment : access Gtk.Adjustment.Gtk_Adjustment_Record'Class)
+   is
+      procedure Internal
+        (Sheet : System.Address; Adjustment : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_set_hadjustment");
+
+   begin
+      Internal (Get_Object (Sheet), Get_Object (Adjustment));
+   end Set_Hadjustment;
+
+   ---------------------
+   -- Set_Vadjustment --
+   ---------------------
+
+   procedure Set_Vadjustment
+      (Sheet      : access Gtk_Sheet_Record;
+       Adjustment : access Gtk.Adjustment.Gtk_Adjustment_Record'Class)
+   is
+      procedure Internal
+        (Sheet      : System.Address;
+         Adjustment : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_set_vadjustment");
+
+   begin
+      Internal (Get_Object (Sheet), Get_Object (Adjustment));
+   end Set_Vadjustment;
+
+   ------------------
+   -- Change_Entry --
+   ------------------
+
+   procedure Change_Entry
+     (Sheet      : access Gtk_Sheet_Record;
+      Entry_Type : Gtk_Type)
+   is
+      procedure Internal
+        (Sheet      : System.Address;
+         Entry_Type : Gtk_Type);
+      pragma Import (C, Internal, "gtk_sheet_change_entry");
+
+   begin
+      Internal (Get_Object (Sheet), Entry_Type);
+   end Change_Entry;
+
+   ---------------
+   -- Get_Entry --
+   ---------------
+
+   function Get_Entry
+     (Sheet : access Gtk_Sheet_Record) return Gtk.GEntry.Gtk_Entry
+   is
+      function Internal (Sheet : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_get_entry");
+
+      Stub : Gtk.GEntry.Gtk_Entry_Record;
+   begin
+      return Gtk.GEntry.Gtk_Entry
+        (Get_User_Data (Internal (Get_Object (Sheet)), Stub));
+   end Get_Entry;
+
+   ----------------------
+   -- Get_Entry_Widget --
+   ----------------------
+
+   function Get_Entry_Widget
+     (Sheet : access Gtk_Sheet_Record) return Gtk.Widget.Gtk_Widget
+   is
+      function Internal (Sheet : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_get_entry_widget");
+
+      Stub : Gtk.Widget.Gtk_Widget_Record;
+   begin
+      return Gtk.Widget.Gtk_Widget
+        (Get_User_Data (Internal (Get_Object (Sheet)), Stub));
+   end Get_Entry_Widget;
+
+   ---------------
+   -- Get_State --
+   ---------------
+
+   function Get_State (Sheet : access Gtk_Sheet_Record) return Sheet_State is
+      function Internal (Sheet : System.Address) return Gint;
+      pragma Import (C, Internal, "gtk_sheet_get_state");
+   begin
+      return Sheet_State'Val (Internal (Get_Object (Sheet)));
+   end Get_State;
+
+   -----------------------
+   -- Get_Visible_Range --
+   -----------------------
+
+   procedure Get_Visible_Range
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : out Gtk_Sheet_Range)
+   is
+      procedure Internal
+        (Sheet : System.Address; The_Range : access Gtk_Sheet_Range);
+      pragma Import (C, Internal, "gtk_sheet_get_visible_range");
+
+      R : aliased Gtk_Sheet_Range;
+
+   begin
+      Internal (Get_Object (Sheet), R'Access);
+      The_Range := R;
+   end Get_Visible_Range;
+
+   ------------------------
+   -- Set_Selection_Mode --
+   ------------------------
+
+   procedure Set_Selection_Mode
+     (Sheet : access Gtk_Sheet_Record;
+      Mode  : Gtk.Enums.Gtk_Selection_Mode)
+   is
+      procedure Internal
+        (Sheet : System.Address;
+         Mode  : Gtk.Enums.Gtk_Selection_Mode);
+      pragma Import (C, Internal, "gtk_sheet_set_selection_mode");
+
+   begin
+      Internal (Get_Object (Sheet), Mode);
+   end Set_Selection_Mode;
+
+   ---------------
+   -- Set_Title --
+   ---------------
+
+   procedure Set_Title
+     (Sheet : access Gtk_Sheet_Record;
+      Title : UTF8_String)
+   is
+      procedure Internal (Sheet : System.Address; Title : UTF8_String);
+      pragma Import (C, Internal, "gtk_sheet_set_title");
+
+   begin
+      Internal (Get_Object (Sheet), Title & ASCII.NUL);
+   end Set_Title;
+
+   ------------
+   -- Freeze --
+   ------------
+
+   procedure Freeze (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_freeze");
+   begin
+      Internal (Get_Object (Sheet));
+   end Freeze;
+
+   ----------
+   -- Thaw --
+   ----------
+
+   procedure Thaw (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_thaw");
+   begin
+      Internal (Get_Object (Sheet));
+   end Thaw;
+
+   ----------------------
+   -- Set_Column_Title --
+   ----------------------
+
+   procedure Set_Column_Title
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint;
+      Title  : UTF8_String)
+   is
+      procedure Internal
+        (Sheet  : System.Address;
+         Column : Gint;
+         Title  : UTF8_String);
+      pragma Import (C, Internal, "gtk_sheet_set_column_title");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Title & ASCII.NUL);
+   end Set_Column_Title;
+
+   -------------------
+   -- Set_Row_Title --
+   -------------------
+
+   procedure Set_Row_Title
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Title : UTF8_String)
+   is
+      procedure Internal
+        (Sheet : System.Address;
+         Row   : Gint;
+         Title : UTF8_String);
+      pragma Import (C, Internal, "gtk_sheet_set_row_title");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Title & ASCII.NUL);
+   end Set_Row_Title;
+
+   --------------------------
+   -- Row_Button_Add_Label --
+   --------------------------
+
+   procedure Row_Button_Add_Label
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Label : UTF8_String)
+   is
+      procedure Internal
+        (Sheet : System.Address;
+         Row   : Gint;
+         Label : UTF8_String);
+      pragma Import (C, Internal, "gtk_sheet_row_button_add_label");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Label & ASCII.NUL);
+   end Row_Button_Add_Label;
+
+   -----------------------------
+   -- Column_Button_Add_Label --
+   -----------------------------
+
+   procedure Column_Button_Add_Label
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint;
+      Label  : UTF8_String)
+   is
+      procedure Internal
+        (Sheet  : System.Address;
+         Column : Gint;
+         Label  : UTF8_String);
+      pragma Import (C, Internal, "gtk_sheet_column_button_add_label");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Label & ASCII.NUL);
+   end Column_Button_Add_Label;
+
+   ------------------------
+   -- Row_Button_Justify --
+   ------------------------
+
+   procedure Row_Button_Justify
+     (Sheet         : access Gtk_Sheet_Record;
+      Row           : Gint;
+      Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Sheet         : System.Address;
+         Row           : Gint;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_sheet_row_button_justify");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Justification);
+   end Row_Button_Justify;
+
+   ---------------------------
+   -- Column_Button_Justify --
+   ---------------------------
+
+   procedure Column_Button_Justify
+      (Sheet         : access Gtk_Sheet_Record;
+       Column        : Gint;
+       Justification : Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+         (Sheet         : System.Address;
+          Column        : Gint;
+          Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_sheet_column_button_justify");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Justification);
+   end Column_Button_Justify;
+
+   ------------
+   -- Moveto --
+   ------------
+
+   procedure Moveto
+     (Sheet     : access Gtk_Sheet_Record;
+      Row       : Gint;
+      Column    : Gint;
+      Row_Align : Gfloat;
+      Col_Align : Gfloat)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         Row       : Gint;
+         Column    : Gint;
+         Row_Align : Gfloat;
+         Col_Align : Gfloat);
+      pragma Import (C, Internal, "gtk_sheet_moveto");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Column, Row_Align, Col_Align);
+   end Moveto;
+
+   --------------------------
+   -- Set_Row_Titles_Width --
+   --------------------------
+
+   procedure Set_Row_Titles_Width
+     (Sheet : access Gtk_Sheet_Record;
+      Width : Guint)
+   is
+      procedure Internal
+        (Sheet : System.Address; Width : Guint);
+      pragma Import (C, Internal, "gtk_sheet_set_row_titles_width");
+
+   begin
+      Internal (Get_Object (Sheet), Width);
+   end Set_Row_Titles_Width;
+
+   ------------------------------
+   -- Set_Column_Titles_Height --
+   ------------------------------
+
+   procedure Set_Column_Titles_Height
+     (Sheet  : access Gtk_Sheet_Record;
+      Height : Guint)
+   is
+      procedure Internal
+        (Sheet : System.Address; Height : Guint);
+      pragma Import (C, Internal, "gtk_sheet_set_column_titles_height");
+
+   begin
+      Internal (Get_Object (Sheet), Height);
+   end Set_Column_Titles_Height;
+
+   ------------------------
+   -- Show_Column_Titles --
+   ------------------------
+
+   procedure Show_Column_Titles (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_show_column_titles");
+   begin
+      Internal (Get_Object (Sheet));
+   end Show_Column_Titles;
+
+   ---------------------
+   -- Show_Row_Titles --
+   ---------------------
+
+   procedure Show_Row_Titles (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_show_row_titles");
+   begin
+      Internal (Get_Object (Sheet));
+   end Show_Row_Titles;
+
+   ------------------------
+   -- Hide_Column_Titles --
+   ------------------------
+
+   procedure Hide_Column_Titles (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_hide_column_titles");
+   begin
+      Internal (Get_Object (Sheet));
+   end Hide_Column_Titles;
+
+   ---------------------
+   -- Hide_Row_Titles --
+   ---------------------
+
+   procedure Hide_Row_Titles (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_hide_row_titles");
+   begin
+      Internal (Get_Object (Sheet));
+   end Hide_Row_Titles;
+
+   -----------------------------
+   -- Columns_Set_Sensitivity --
+   -----------------------------
+
+   procedure Columns_Set_Sensitivity
+     (Sheet     : access Gtk_Sheet_Record;
+      Sensitive : Boolean)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         Sensitive : Gint);
+      pragma Import (C, Internal, "gtk_sheet_columns_set_sensitivity");
+
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Sensitive));
+   end Columns_Set_Sensitivity;
+
+   ----------------------------
+   -- Column_Set_Sensitivity --
+   ----------------------------
+
+   procedure Column_Set_Sensitivity
+     (Sheet     : access Gtk_Sheet_Record;
+      Column    : Gint;
+      Sensitive : Boolean)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         Column    : Gint;
+         Sensitive : Gint);
+      pragma Import (C, Internal, "gtk_sheet_column_set_sensitivity");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Boolean'Pos (Sensitive));
+   end Column_Set_Sensitivity;
+
+   --------------------------
+   -- Rows_Set_Sensitivity --
+   --------------------------
+
+   procedure Rows_Set_Sensitivity
+     (Sheet     : access Gtk_Sheet_Record;
+      Sensitive : Boolean)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         Sensitive : Gint);
+      pragma Import (C, Internal, "gtk_sheet_rows_set_sensitivity");
+
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Sensitive));
+   end Rows_Set_Sensitivity;
+
+   -------------------------
+   -- Row_Set_Sensitivity --
+   -------------------------
+
+   procedure Row_Set_Sensitivity
+     (Sheet     : access Gtk_Sheet_Record;
+      Row       : Gint;
+      Sensitive : Boolean)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         Row       : Gint;
+         Sensitive : Gint);
+      pragma Import (C, Internal, "gtk_sheet_row_set_sensitivity");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Boolean'Pos (Sensitive));
+   end Row_Set_Sensitivity;
+
+   ---------------------------
+   -- Column_Set_Visibility --
+   ---------------------------
+
+   procedure Column_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Column  : Gint;
+      Visible : Boolean)
+   is
+      procedure Internal
+        (Sheet   : System.Address;
+         Column  : Gint;
+         Visible : Gint);
+      pragma Import (C, Internal, "gtk_sheet_column_set_visibility");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Boolean'Pos (Visible));
+   end Column_Set_Visibility;
+
+   ---------------------------------
+   -- Column_Label_Set_Visibility --
+   ---------------------------------
+
+   procedure Column_Label_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Column  : Gint;
+      Visible : Boolean := True)
+   is
+      procedure Internal
+        (Sheet   : System.Address;
+         Column  : Gint;
+         Visible : Gint);
+      pragma Import (C, Internal, "gtk_sheet_column_label_set_visibility");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Boolean'Pos (Visible));
+   end Column_Label_Set_Visibility;
+
+   -----------------------------------
+   -- Columns_Labels_Set_Visibility --
+   -----------------------------------
+
+   procedure Columns_Labels_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Visible : Boolean := True)
+   is
+      procedure Internal (Sheet : System.Address; Visible : Gint);
+      pragma Import (C, Internal, "gtk_sheet_columns_labels_set_visibility");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Visible));
+   end Columns_Labels_Set_Visibility;
+
+   ------------------------
+   -- Row_Set_Visibility --
+   ------------------------
+
+   procedure Row_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Row     : Gint;
+      Visible : Boolean)
+   is
+      procedure Internal
+        (Sheet   : System.Address;
+         Row     : Gint;
+         Visible : Gint);
+      pragma Import (C, Internal, "gtk_sheet_row_set_visibility");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Boolean'Pos (Visible));
+   end Row_Set_Visibility;
+
+   ------------------------------
+   -- Row_Label_Set_Visibility --
+   ------------------------------
+
+   procedure Row_Label_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Row     : Gint;
+      Visible : Boolean := True)
+   is
+      procedure Internal
+        (Sheet   : System.Address;
+         Row     : Gint;
+         Visible : Gint);
+      pragma Import (C, Internal, "gtk_sheet_row_label_set_visibility");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Boolean'Pos (Visible));
+   end Row_Label_Set_Visibility;
+
+   --------------------------------
+   -- Rows_Labels_Set_Visibility --
+   --------------------------------
+
+   procedure Rows_Labels_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Visible : Boolean := True)
+   is
+      procedure Internal (Sheet : System.Address; Visible : Gint);
+      pragma Import (C, Internal, "gtk_sheet_rows_labels_set_visibility");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Visible));
+   end Rows_Labels_Set_Visibility;
+
+   -------------------
+   -- Select_Column --
+   -------------------
+
+   procedure Select_Column
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint)
+   is
+      procedure Internal
+        (Sheet : System.Address; Column : Gint);
+      pragma Import (C, Internal, "gtk_sheet_select_column");
+
+   begin
+      Internal (Get_Object (Sheet), Column);
+   end Select_Column;
+
+   ----------------
+   -- Select_Row --
+   ----------------
+
+   procedure Select_Row
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint)
+   is
+      procedure Internal (Sheet : System.Address; Row : Gint);
+      pragma Import (C, Internal, "gtk_sheet_select_row");
+   begin
+      Internal (Get_Object (Sheet), Row);
+   end Select_Row;
+
+   ----------------
+   -- Clip_Range --
+   ----------------
+
+   procedure Clip_Range
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         The_Range : Gtk_Sheet_Range);
+      pragma Import (C, Internal, "gtk_sheet_clip_range");
+
+   begin
+      Internal (Get_Object (Sheet), The_Range);
+   end Clip_Range;
+
+   ------------------
+   -- Unclip_Range --
+   ------------------
+
+   procedure Unclip_Range (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_unclip_range");
+   begin
+      Internal (Get_Object (Sheet));
+   end Unclip_Range;
+
+   ---------------------
+   -- Get_Vadjustment --
+   ---------------------
+
+   function Get_Vadjustment
+     (Sheet  : access Gtk_Sheet_Record) return Gtk.Adjustment.Gtk_Adjustment
+   is
+      function Internal (Sheet : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_get_vadjustment");
+
+      Stub : Gtk.Adjustment.Gtk_Adjustment_Record;
+
+   begin
+      return Gtk.Adjustment.Gtk_Adjustment
+        (Get_User_Data (Internal (Get_Object (Sheet)), Stub));
+   end Get_Vadjustment;
+
+   ---------------------
+   -- Get_Hadjustment --
+   ---------------------
+
+   function Get_Hadjustment
+     (Sheet  : access Gtk_Sheet_Record) return Gtk.Adjustment.Gtk_Adjustment
+   is
+      function Internal (Sheet : System.Address) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_get_hadjustment");
+
+      Stub : Gtk.Adjustment.Gtk_Adjustment_Record;
+
+   begin
+      return Gtk.Adjustment.Gtk_Adjustment
+        (Get_User_Data (Internal (Get_Object (Sheet)), Stub));
+   end Get_Hadjustment;
+
+   ------------------
+   -- Select_Range --
+   ------------------
+
+   procedure Select_Range
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         The_Range : Gtk_Sheet_Range);
+      pragma Import (C, Internal, "gtk_sheet_select_range");
+
+   begin
+      Internal (Get_Object (Sheet), The_Range);
+   end Select_Range;
+
+   --------------------
+   -- Unselect_Range --
+   --------------------
+
+   procedure Unselect_Range (Sheet : access Gtk_Sheet_Record) is
+      procedure Internal (Sheet : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_unselect_range");
+   begin
+      Internal (Get_Object (Sheet));
+   end Unselect_Range;
+
+   ---------------------
+   -- Set_Active_Cell --
+   ---------------------
+
+   function Set_Active_Cell
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Column : Gint) return Boolean
+   is
+      function Internal
+        (Sheet  : System.Address;
+         Row    : Gint;
+         Column : Gint) return Gint;
+      pragma Import (C, Internal, "gtk_sheet_set_active_cell");
+
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet), Row, Column));
+   end Set_Active_Cell;
+
+   ---------------------
+   -- Get_Active_Cell --
+   ---------------------
+
+   procedure Get_Active_Cell
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : out Gint;
+      Column : out Gint)
+   is
+      procedure Internal
+        (Sheet  : System.Address;
+         Row    : access Gint;
+         Column : access Gint);
+      pragma Import (C, Internal, "gtk_sheet_get_active_cell");
+
+      R, C : aliased Gint;
+
+   begin
+      Internal (Get_Object (Sheet), R'Access, C'Access);
+      Row := R;
+      Column := C;
+   end Get_Active_Cell;
+
+   --------------
+   -- Set_Cell --
+   --------------
+
+   procedure Set_Cell
+     (Sheet         : access Gtk_Sheet_Record;
+      Row           : Gint;
+      Col           : Gint;
+      Justification : Gtk.Enums.Gtk_Justification;
+      Text          : UTF8_String)
+   is
+      procedure Internal
+        (Sheet         : System.Address;
+         Row           : Gint;
+         Col           : Gint;
+         Justification : Gtk.Enums.Gtk_Justification;
+         Text          : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_set_cell");
+
+      T : aliased UTF8_String := Text & ASCII.NUL;
+      Ta : System.Address := T'Address;
+
+   begin
+      if Text = "" then
+         Ta := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Sheet), Row, Col, Justification, Ta);
+   end Set_Cell;
+
+   -------------------
+   -- Set_Cell_Text --
+   -------------------
+
+   procedure Set_Cell_Text
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Col   : Gint;
+      Text  : UTF8_String)
+   is
+      procedure Internal
+        (Sheet : System.Address;
+         Row   : Gint;
+         Col   : Gint;
+         Text  : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_set_cell_text");
+
+      T : aliased UTF8_String := Text & ASCII.NUL;
+      Ta : System.Address := T'Address;
+
+   begin
+      if Text = "" then
+         Ta := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Sheet), Row, Col, Ta);
+   end Set_Cell_Text;
+
+   -------------------
+   -- Cell_Get_Text --
+   -------------------
+
+   function Cell_Get_Text
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Col    : Gint) return UTF8_String
+   is
+      function Internal
+        (Sheet  : System.Address;
+         Row    : Gint;
+         Col    : Gint) return Interfaces.C.Strings.chars_ptr;
+      pragma Import (C, Internal, "gtk_sheet_cell_get_text");
+
+      C : Interfaces.C.Strings.chars_ptr;
+
+   begin
+      C := Internal (Get_Object (Sheet), Row, Col);
+
+      if C = Interfaces.C.Strings.Null_Ptr then
+         return "";
+      else
+         return Interfaces.C.Strings.Value (C);
+      end if;
+   end Cell_Get_Text;
+
+   ----------------
+   -- Cell_Clear --
+   ----------------
+
+   procedure Cell_Clear
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Col   : Gint)
+   is
+      procedure Internal
+        (Sheet : System.Address;
+         Row   : Gint;
+         Col   : Gint);
+      pragma Import (C, Internal, "gtk_sheet_cell_clear");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Col);
+   end Cell_Clear;
+
+   -----------------
+   -- Cell_Delete --
+   -----------------
+
+   procedure Cell_Delete
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Col   : Gint)
+   is
+      procedure Internal
+        (Sheet : System.Address;
+         Row   : Gint;
+         Col   : Gint);
+      pragma Import (C, Internal, "gtk_sheet_cell_delete");
+
+   begin
+      Internal (Get_Object (Sheet), Row, Col);
+   end Cell_Delete;
+
+   -----------------
+   -- Range_Clear --
+   -----------------
+
+   procedure Range_Clear
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         The_Range : Gtk_Sheet_Range);
+      pragma Import (C, Internal, "gtk_sheet_range_clear");
+
+   begin
+      Internal (Get_Object (Sheet), The_Range);
+   end Range_Clear;
+
+   ------------------
+   -- Range_Delete --
+   ------------------
+
+   procedure Range_Delete
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range)
+   is
+      procedure Internal
+        (Sheet     : System.Address;
+         The_Range : Gtk_Sheet_Range);
+      pragma Import (C, Internal, "gtk_sheet_range_delete");
+
+   begin
+      Internal (Get_Object (Sheet), The_Range);
+   end Range_Delete;
+
+   --------------------
+   -- Cell_Get_State --
+   --------------------
+
+   function Cell_Get_State
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Col    : Gint) return Gtk.Enums.Gtk_State_Type
+   is
+      function Internal
+        (Sheet  : System.Address;
+         Row    : Gint;
+         Col    : Gint) return Gint;
+      pragma Import (C, Internal, "gtk_sheet_cell_get_state");
+
+   begin
+      return Gtk.Enums.Gtk_State_Type'Val
+        (Internal (Get_Object (Sheet), Row, Col));
+   end Cell_Get_State;
+
+   -----------
+   -- Links --
+   -----------
+
+   package body Links is
+
+      function Convert is new Unchecked_Conversion
+        (System.Address, Data_Type_Access);
+      function Convert is new Unchecked_Conversion
+        (Data_Type_Access, System.Address);
+
+      ---------------
+      -- Link_Cell --
+      ---------------
+
+      procedure Link_Cell
+        (Sheet : access Gtk_Sheet_Record'Class;
+         Row   : Gint;
+         Col   : Gint;
+         Link  : Data_Type)
+      is
+         procedure Internal
+           (Sheet : System.Address;
+            Row   : Gint;
+            Col   : Gint;
+            Link  : System.Address);
+         pragma Import (C, Internal, "gtk_sheet_link_cell");
+
+         D : constant Data_Type_Access := new Data_Type'(Link);
+
+      begin
+         Internal (Get_Object (Sheet), Row, Col, Convert (D));
+      end Link_Cell;
+
+      --------------
+      -- Get_Link --
+      --------------
+
+      function Get_Link
+        (Sheet  : access Gtk_Sheet_Record'Class;
+         Row    : Gint;
+         Col    : Gint) return Data_Type_Access
+      is
+         function Internal
+           (Sheet : System.Address;
+            Row   : Gint;
+            Col   : Gint) return System.Address;
+         pragma Import (C, Internal, "gtk_sheet_get_link");
+
+      begin
+         return Convert (Internal (Get_Object (Sheet), Row, Col));
+      end Get_Link;
+
+   end Links;
+
+   -----------------
+   -- Remove_Link --
+   -----------------
+
+   procedure Remove_Link (Sheet : access Gtk_Sheet_Record;
+                          Row   : in Gint;
+                          Col   : in Gint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Row   : in Gint;
+                          Col   : in Gint);
+      pragma Import (C, Internal, "gtk_sheet_remove_link");
+   begin
+      Internal (Get_Object (Sheet), Row, Col);
+   end Remove_Link;
+
+   --------------------
+   -- Get_Pixel_Info --
+   --------------------
+
+   procedure Get_Pixel_Info
+     (Sheet  : access Gtk_Sheet_Record;
+      X      : in Gint;
+      Y      : in Gint;
+      Row    : out Gint;
+      Column : out Gint)
+   is
+      function Internal
+        (Sheet  : in System.Address;
+         X      : in Gint;
+         Y      : in Gint;
+         Row    : access Gint;
+         Column : access Gint) return Gint;
+      pragma Import (C, Internal, "gtk_sheet_get_pixel_info");
+
+      R, C : aliased Gint;
+   begin
+      if Internal (Get_Object (Sheet), X, Y, R'Access, C'Access) = 0 then
+         raise Constraint_Error;
+      end if;
+
+      Row := R;
+      Column := C;
+   end Get_Pixel_Info;
+
+   -------------------
+   -- Get_Cell_Area --
+   -------------------
+
+   procedure Get_Cell_Area
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : in Gint;
+      Column : in Gint;
+      Area   : out Gdk.Rectangle.Gdk_Rectangle)
+   is
+      function Internal
+        (Sheet  : in System.Address;
+         Row    : in Gint;
+         Column : in Gint;
+         Area   : access Gdk.Rectangle.Gdk_Rectangle) return Gint;
+      pragma Import (C, Internal, "gtk_sheet_get_cell_area");
+
+      A : aliased Gdk.Rectangle.Gdk_Rectangle;
+   begin
+      if Internal (Get_Object (Sheet), Row, Column, A'Access) = 0 then
+         raise Constraint_Error;
+      end if;
+      Area := A;
+   end Get_Cell_Area;
+
+   ----------------------
+   -- Set_Column_Width --
+   ----------------------
+
+   procedure Set_Column_Width (Sheet  : access Gtk_Sheet_Record;
+                               Column : in Gint;
+                               Width  : in Guint)
+   is
+      procedure Internal (Sheet  : in System.Address;
+                          Column : in Gint;
+                          Width  : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_set_column_width");
+   begin
+      Internal (Get_Object (Sheet), Column, Width);
+   end Set_Column_Width;
+
+   --------------------
+   -- Set_Row_Height --
+   --------------------
+
+   procedure Set_Row_Height (Sheet  : access Gtk_Sheet_Record;
+                             Row    : in Gint;
+                             Height : in Guint)
+   is
+      procedure Internal (Sheet  : in System.Address;
+                          Row    : in Gint;
+                          Height : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_set_row_height");
+   begin
+      Internal (Get_Object (Sheet), Row, Height);
+   end Set_Row_Height;
+
+   ----------------
+   -- Add_Column --
+   ----------------
+
+   procedure Add_Column (Sheet : access Gtk_Sheet_Record;
+                         Ncols : in Guint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Ncols : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_add_column");
+   begin
+      Internal (Get_Object (Sheet), Ncols);
+   end Add_Column;
+
+   -------------
+   -- Add_Row --
+   -------------
+
+   procedure Add_Row (Sheet : access Gtk_Sheet_Record;
+                      Nrows : in Guint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Nrows : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_add_row");
+   begin
+      Internal (Get_Object (Sheet), Nrows);
+   end Add_Row;
+
+   -----------------
+   -- Insert_Rows --
+   -----------------
+
+   procedure Insert_Rows (Sheet : access Gtk_Sheet_Record;
+                          Row   : in Guint;
+                          Nrows : in Guint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Row   : in Guint;
+                          Nrows : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_insert_rows");
+   begin
+      Internal (Get_Object (Sheet), Row, Nrows);
+   end Insert_Rows;
+
+   --------------------
+   -- Insert_Columns --
+   --------------------
+
+   procedure Insert_Columns (Sheet : access Gtk_Sheet_Record;
+                             Col   : in Guint;
+                             Ncols : in Guint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Col   : in Guint;
+                          Ncols : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_insert_columns");
+   begin
+      Internal (Get_Object (Sheet), Col, Ncols);
+   end Insert_Columns;
+
+   -----------------
+   -- Delete_Rows --
+   -----------------
+
+   procedure Delete_Rows (Sheet : access Gtk_Sheet_Record;
+                          Row   : in Guint;
+                          Nrows : in Guint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Row   : in Guint;
+                          Nrows : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_delete_rows");
+   begin
+      Internal (Get_Object (Sheet), Row, Nrows);
+   end Delete_Rows;
+
+   --------------------
+   -- Delete_Columns --
+   --------------------
+
+   procedure Delete_Columns (Sheet : access Gtk_Sheet_Record;
+                             Col   : in Guint;
+                             Ncols : in Guint)
+   is
+      procedure Internal (Sheet : in System.Address;
+                          Col   : in Guint;
+                          Ncols : in Guint);
+      pragma Import (C, Internal, "gtk_sheet_delete_columns");
+   begin
+      Internal (Get_Object (Sheet), Col, Ncols);
+   end Delete_Columns;
+
+   --------------------------
+   -- Range_Set_Background --
+   --------------------------
+
+   procedure Range_Set_Background (Sheet     : access Gtk_Sheet_Record;
+                                   The_Range : in Gtk_Sheet_Range;
+                                   Color     : in Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Sheet     : in System.Address;
+                          The_Range : in Gtk_Sheet_Range;
+                          Color     : in System.Address);
+      pragma Import (C, Internal, "gtk_sheet_range_set_background");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if Color = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Sheet), The_Range, Ca);
+   end Range_Set_Background;
+
+   --------------------------
+   -- Range_Set_Foreground --
+   --------------------------
+
+   procedure Range_Set_Foreground (Sheet     : access Gtk_Sheet_Record;
+                                   The_Range : in Gtk_Sheet_Range;
+                                   Color     : in Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Sheet     : in System.Address;
+                          The_Range : in Gtk_Sheet_Range;
+                          Color     : in System.Address);
+      pragma Import (C, Internal, "gtk_sheet_range_set_foreground");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if Color = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Sheet), The_Range, Ca);
+   end Range_Set_Foreground;
+
+   -----------------------------
+   -- Range_Set_Justification --
+   -----------------------------
+
+   procedure Range_Set_Justification
+      (Sheet         : access Gtk_Sheet_Record;
+       The_Range     : in Gtk_Sheet_Range;
+       Justification : in Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Sheet         : System.Address;
+         The_Range     : Gtk_Sheet_Range;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_sheet_range_set_justification");
+
+   begin
+      Internal (Get_Object (Sheet), The_Range, Justification);
+   end Range_Set_Justification;
+
+   ------------------------------
+   -- Column_Set_Justification --
+   ------------------------------
+
+   procedure Column_Set_Justification
+      (Sheet         : access Gtk_Sheet_Record;
+       Column        : in Gint;
+       Justification : in Gtk.Enums.Gtk_Justification)
+   is
+      procedure Internal
+        (Sheet         : System.Address;
+         Column        : Gint;
+         Justification : Gtk.Enums.Gtk_Justification);
+      pragma Import (C, Internal, "gtk_sheet_column_set_justification");
+
+   begin
+      Internal (Get_Object (Sheet), Column, Justification);
+   end Column_Set_Justification;
+
+   ------------------------
+   -- Range_Set_Editable --
+   ------------------------
+
+   procedure Range_Set_Editable (Sheet     : access Gtk_Sheet_Record;
+                                 The_Range : in Gtk_Sheet_Range;
+                                 Editable  : in Boolean)
+   is
+      procedure Internal (Sheet     : in System.Address;
+                          The_Range : in Gtk_Sheet_Range;
+                          Editable  : in Gint);
+      pragma Import (C, Internal, "gtk_sheet_range_set_editable");
+   begin
+      Internal (Get_Object (Sheet), The_Range, Boolean'Pos (Editable));
+   end Range_Set_Editable;
+
+   -----------------------
+   -- Range_Set_Visible --
+   -----------------------
+
+   procedure Range_Set_Visible (Sheet     : access Gtk_Sheet_Record;
+                                The_Range : in Gtk_Sheet_Range;
+                                Visible   : in Boolean)
+   is
+      procedure Internal (Sheet     : in System.Address;
+                          The_Range : in Gtk_Sheet_Range;
+                          Visible   : in Gint);
+      pragma Import (C, Internal, "gtk_sheet_range_set_visible");
+   begin
+      Internal (Get_Object (Sheet), The_Range, Boolean'Pos (Visible));
+   end Range_Set_Visible;
+
+   ----------------------
+   -- Range_Set_Border --
+   ----------------------
+
+   procedure Range_Set_Border (Sheet      : access Gtk_Sheet_Record;
+                               The_Range  : in Gtk_Sheet_Range;
+                               Mask       : in Gtk_Sheet_Border;
+                               Width      : in Guint;
+                               Line_Style : in Gdk.GC.Gdk_Line_Style)
+   is
+      procedure Internal
+        (Sheet      : System.Address;
+         The_Range  : Gtk_Sheet_Range;
+         Mask       : Gtk_Sheet_Border;
+         Width      : Guint;
+         Line_Style : Gdk.GC.Gdk_Line_Style);
+      pragma Import (C, Internal, "gtk_sheet_range_set_border");
+
+   begin
+      Internal (Get_Object (Sheet), The_Range, Mask, Width, Line_Style);
+   end Range_Set_Border;
+
+   ----------------------------
+   -- Range_Set_Border_Color --
+   ----------------------------
+
+   procedure Range_Set_Border_Color (Sheet     : access Gtk_Sheet_Record;
+                                     The_Range : in Gtk_Sheet_Range;
+                                     Color     : in Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Sheet     : in System.Address;
+                          The_Range : in Gtk_Sheet_Range;
+                          Color     : in System.Address);
+      pragma Import (C, Internal, "gtk_sheet_range_set_border_color");
+
+      C : aliased Gdk.Color.Gdk_Color := Color;
+      Ca : System.Address := C'Address;
+
+   begin
+      if Color = Gdk.Color.Null_Color then
+         Ca := System.Null_Address;
+      end if;
+
+      Internal (Get_Object (Sheet), The_Range, Ca);
+   end Range_Set_Border_Color;
+
+   --------------------
+   -- Range_Set_Font --
+   --------------------
+
+   procedure Range_Set_Font (Sheet     : access Gtk_Sheet_Record;
+                             The_Range : in Gtk_Sheet_Range;
+                             Font      : Pango.Font.Pango_Font_Description)
+   is
+      procedure Internal (Sheet     : System.Address;
+                          The_Range : Gtk_Sheet_Range;
+                          Font      : Pango_Font_Description);
+      pragma Import (C, Internal, "gtk_sheet_range_set_font");
+   begin
+      Internal (Get_Object (Sheet), The_Range, Font);
+   end Range_Set_Font;
+
+   ---------
+   -- Put --
+   ---------
+
+   procedure Put
+     (Sheet  : access Gtk_Sheet_Record;
+      Widget : access Gtk.Widget.Gtk_Widget_Record'Class;
+      X      : Gint;
+      Y      : Gint)
+   is
+      function Internal
+        (Sheet  : System.Address;
+         Widget : System.Address;
+         X      : Gint;
+         Y      : Gint) return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_put");
+
+      S : System.Address;
+      pragma Unreferenced (S);
+
+   begin
+      S := Internal (Get_Object (Sheet), Get_Object (Widget), X, Y);
+   end Put;
+
+   ------------
+   -- Attach --
+   ------------
+
+   procedure Attach
+      (Sheet    : access Gtk_Sheet_Record;
+       Widget   : access Gtk.Widget.Gtk_Widget_Record'Class;
+       Row      : Gint;
+       Col      : Gint;
+       Xoptions : Gtk.Enums.Gtk_Attach_Options := Expand or Fill;
+       Yoptions : Gtk.Enums.Gtk_Attach_Options := Expand or Fill;
+       Xpadding : Gint := 0;
+       Ypadding : Gint := 0)
+   is
+      procedure Internal (Sheet   : System.Address;
+                          Widget  : System.Address;
+                          Row, Col : Gint;
+                          Xoptions, Yoptions : Gtk_Attach_Options;
+                          Xpadding, Ypadding : Gint);
+      pragma Import (C, Internal, "gtk_sheet_attach");
+   begin
+      Internal (Get_Object (Sheet), Get_Object (Widget), Row,  Col,
+                Xoptions, Yoptions, Xpadding, Ypadding);
+   end Attach;
+
+   ----------------
+   -- Move_Child --
+   ----------------
+
+   procedure Move_Child (Sheet  : access Gtk_Sheet_Record;
+                         Widget : access Gtk.Widget.Gtk_Widget_Record'Class;
+                         X      : in Gint;
+                         Y      : in Gint)
+   is
+      procedure Internal (Sheet  : in System.Address;
+                          Widget : in System.Address;
+                          X      : in Gint;
+                          Y      : in Gint);
+      pragma Import (C, Internal, "gtk_sheet_move_child");
+   begin
+      Internal (Get_Object (Sheet), Get_Object (Widget), X, Y);
+   end Move_Child;
+
+   ------------------
+   -- Get_Child_At --
+   ------------------
+
+   function Get_Child_At (Sheet  : access Gtk_Sheet_Record;
+                          Row    : in Gint;
+                          Col    : in Gint)
+                         return      Gtk_Sheet_Child
+   is
+      function Internal (Sheet  : in System.Address;
+                         Row    : in Gint;
+                         Col    : in Gint)
+                        return System.Address;
+      pragma Import (C, Internal, "gtk_sheet_get_child_at");
+      Stub : Gtk_Sheet_Child_Record;
+   begin
+      return Gtk_Sheet_Child
+        (Get_User_Data (Internal (Get_Object (Sheet), Row, Col), Stub));
+   end Get_Child_At;
+
+   ----------------
+   -- Get_Widget --
+   ----------------
+
+   function Get_Widget (Child : Gtk_Sheet_Child)
+                       return Gtk.Widget.Gtk_Widget
+   is
+      function Internal (Child : System.Address) return System.Address;
+      pragma Import (C, Internal, "ada_gtk_sheet_get_widget");
+      Stub : Gtk.Widget.Gtk_Widget_Record;
+   begin
+      return Gtk.Widget.Gtk_Widget
+        (Get_User_Data (Internal (Get_Object (Child)), Stub));
+   end Get_Widget;
+
+   ---------------
+   -- Get_Range --
+   ---------------
+
+   function Get_Range
+     (Sheet : access Gtk_Sheet_Record) return Gtk_Sheet_Range
+   is
+      function Internal (Sheet : System.Address) return Gtk_Sheet_Range;
+      pragma Import (C, Internal, "ada_gtk_sheet_get_range");
+   begin
+      return Internal (Get_Object (Sheet));
+   end Get_Range;
+
+   -----------------------
+   -- Get_Columns_Count --
+   -----------------------
+
+   function Get_Columns_Count (Sheet : access Gtk_Sheet_Record) return Guint is
+      function Internal (Sheet : System.Address) return Guint;
+      pragma Import (C, Internal, "gtk_sheet_get_columns_count");
+   begin
+      return Internal (Get_Object (Sheet));
+   end Get_Columns_Count;
+
+   --------------------
+   -- Get_Rows_Count --
+   --------------------
+
+   function Get_Rows_Count (Sheet : access Gtk_Sheet_Record) return Guint is
+      function Internal (Sheet : System.Address) return Guint;
+      pragma Import (C, Internal, "gtk_sheet_get_rows_count");
+   begin
+      return Internal (Get_Object (Sheet));
+   end Get_Rows_Count;
+
+   ----------------------
+   -- Get_Column_Title --
+   ----------------------
+
+   function Get_Column_Title (Sheet  : access Gtk_Sheet_Record;
+                              Column : Gint)
+                             return UTF8_String
+   is
+      function Internal (Sheet : System.Address; Column : Gint)
+                        return Interfaces.C.Strings.chars_ptr;
+      pragma Import (C, Internal, "gtk_sheet_get_column_title");
+      C : Interfaces.C.Strings.chars_ptr;
+   begin
+      C := Internal (Get_Object (Sheet), Column);
+      if C = Interfaces.C.Strings.Null_Ptr then
+         return "";
+      else
+         return Interfaces.C.Strings.Value (C);
+      end if;
+   end Get_Column_Title;
+
+   -------------------
+   -- Get_Row_Title --
+   -------------------
+
+   function Get_Row_Title (Sheet  : access Gtk_Sheet_Record;
+                           Row : Gint)
+                          return UTF8_String
+   is
+      function Internal (Sheet : System.Address; Row : Gint)
+                        return Interfaces.C.Strings.chars_ptr;
+      pragma Import (C, Internal, "gtk_sheet_get_row_title");
+      C : Interfaces.C.Strings.chars_ptr;
+   begin
+      C := Internal (Get_Object (Sheet), Row);
+      if C = Interfaces.C.Strings.Null_Ptr then
+         return "";
+      else
+         return Interfaces.C.Strings.Value (C);
+      end if;
+   end Get_Row_Title;
+
+   ----------------------
+   -- Get_Column_Width --
+   ----------------------
+
+   function Get_Column_Width (Sheet  : access Gtk_Sheet_Record;
+                              Column : in Gint)
+                             return Gint
+   is
+      function Internal (Sheet  : System.Address;
+                         Column : Gint)
+                        return Gint;
+      pragma Import (C, Internal, "ada_gtk_sheet_get_column_width");
+   begin
+      return Internal (Get_Object (Sheet), Column);
+   end Get_Column_Width;
+
+   --------------------
+   -- Get_Row_Height --
+   --------------------
+
+   function Get_Row_Height (Sheet  : access Gtk_Sheet_Record;
+                            Row : in Gint)
+                           return Gint
+   is
+      function Internal (Sheet  : System.Address;
+                         Row : Gint)
+                        return Gint;
+      pragma Import (C, Internal, "ada_gtk_sheet_get_row_height");
+   begin
+      return Internal (Get_Object (Sheet), Row);
+   end Get_Row_Height;
+
+   -------------------
+   -- Button_Attach --
+   -------------------
+
+   procedure Button_Attach
+     (Sheet   : access Gtk_Sheet_Record;
+      Widget  : access Gtk.Widget.Gtk_Widget_Record'Class;
+      Row     : Gint;
+      Col     : Gint)
+   is
+      procedure Internal (Sheet   : System.Address;
+                          Widget  : System.Address;
+                          Row     : Gint;
+                          Col     : Gint);
+      pragma Import (C, Internal, "gtk_sheet_button_attach");
+   begin
+      Internal (Get_Object (Sheet), Get_Object (Widget), Row, Col);
+   end Button_Attach;
+
+   --------------------
+   -- Set_Background --
+   --------------------
+
+   procedure Set_Background
+     (Sheet : access Gtk_Sheet_Record; Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Sheet : System.Address; Color : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_set_background");
+      C : aliased Gdk_Color := Color;
+   begin
+      Internal (Get_Object (Sheet), C'Address);
+   end Set_Background;
+
+   --------------
+   -- Set_Grid --
+   --------------
+
+   procedure Set_Grid
+     (Sheet : access Gtk_Sheet_Record; Color : Gdk.Color.Gdk_Color)
+   is
+      procedure Internal (Sheet : System.Address; Color : System.Address);
+      pragma Import (C, Internal, "gtk_sheet_set_grid");
+      C : aliased Gdk_Color := Color;
+   begin
+      Internal (Get_Object (Sheet), C'Address);
+   end Set_Grid;
+
+   ---------------
+   -- Show_Grid --
+   ---------------
+
+   procedure Show_Grid
+     (Sheet : access Gtk_Sheet_Record; Show : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Show : Integer);
+      pragma Import (C, Internal, "gtk_sheet_show_grid");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Show));
+   end Show_Grid;
+
+   ------------------
+   -- Grid_Visible --
+   ------------------
+
+   function Grid_Visible (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_grid_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Grid_Visible;
+
+   --------------------
+   -- Get_Attributes --
+   --------------------
+
+--     function Get_Attributes (Sheet      : access Gtk_Sheet_Record;
+--                              Row        : in Gint;
+--                              Col        : in Gint;
+--                              Attributes : access Gtk_Sheet_Cell_Attr)
+--                             return      Boolean
+--     is
+--        function Internal (Sheet      : in System.Address;
+--                           Row        : in Gint;
+--                           Col        : in Gint;
+--                           Attributes : access Gtk_Sheet_Cell_Attr)
+--                          return          Gint;
+--        pragma Import (C, Internal, "gtk_sheet_get_attributes");
+--     begin
+--        return Boolean'Val (Internal (Get_Object (Sheet),
+--                                      Row,
+--                                      Col,
+--                                      Attributes));
+--     end Get_Attributes;
+
+   --------------------
+   -- Set_Autoresize --
+   --------------------
+
+   procedure Set_Autoresize
+     (Sheet : access Gtk_Sheet_Record; Autoresize : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Autoresize : Integer);
+      pragma Import (C, Internal, "gtk_sheet_set_autoresize");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Autoresize));
+   end Set_Autoresize;
+
+   ----------------
+   -- Autoresize --
+   ----------------
+
+   function Autoresize (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_autoresize");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Autoresize;
+
+   --------------------
+   -- Set_Autoscroll --
+   --------------------
+
+   procedure Set_Autoscroll
+     (Sheet : access Gtk_Sheet_Record; Autoscroll : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Autoscroll : Integer);
+      pragma Import (C, Internal, "gtk_sheet_set_autoscroll");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Autoscroll));
+   end Set_Autoscroll;
+
+   ----------------
+   -- Autoscroll --
+   ----------------
+
+   function Autoscroll (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_autoscroll");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Autoscroll;
+
+   -------------------
+   -- Set_Clip_Text --
+   -------------------
+
+   procedure Set_Clip_Text
+     (Sheet : access Gtk_Sheet_Record; Clip : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Clip : Integer);
+      pragma Import (C, Internal, "gtk_sheet_set_clip_text");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Clip));
+   end Set_Clip_Text;
+
+   ---------------
+   -- Clip_Text --
+   ---------------
+
+   function Clip_Text (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_clip_text");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Clip_Text;
+
+   -----------------------
+   -- Set_Justify_Entry --
+   -----------------------
+
+   procedure Set_Justify_Entry
+     (Sheet : access Gtk_Sheet_Record; Justify_Entry : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Justify : Integer);
+      pragma Import (C, Internal, "gtk_sheet_set_justify_entry");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Justify_Entry));
+   end Set_Justify_Entry;
+
+   -------------------
+   -- Justify_Entry --
+   -------------------
+
+   function Justify_Entry (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_justify_entry");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Justify_Entry;
+
+   ----------------
+   -- Set_Locked --
+   ----------------
+
+   procedure Set_Locked
+     (Sheet : access Gtk_Sheet_Record; Locked : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Justify : Integer);
+      pragma Import (C, Internal, "gtk_sheet_set_locked");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Locked));
+   end Set_Locked;
+
+   ------------
+   -- Locked --
+   ------------
+
+   function Locked (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_locked");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Locked;
+
+   -------------
+   -- In_Clip --
+   -------------
+
+   function In_Clip (Sheet : access Gtk_Sheet_Record) return Boolean is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_in_clip");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end In_Clip;
+
+   -----------------------------
+   -- Column_Button_Get_Label --
+   -----------------------------
+
+   function Column_Button_Get_Label
+     (Sheet : access Gtk_Sheet_Record; Column : Gint) return UTF8_String
+   is
+      function Internal (S : System.Address; Column : Gint) return chars_ptr;
+      pragma Import (C, Internal, "gtk_sheet_column_button_get_label");
+      S : constant chars_ptr := Internal (Get_Object (Sheet), Column);
+   begin
+      --  Do not free S, this references internal values
+      return Value (S);
+   end Column_Button_Get_Label;
+
+   ---------------------------
+   -- Column_Titles_Visible --
+   ---------------------------
+
+   function Column_Titles_Visible
+     (Sheet : access Gtk_Sheet_Record) return Boolean
+   is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_column_titles_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Column_Titles_Visible;
+
+   ---------------------------
+   -- Columns_Set_Resizable --
+   ---------------------------
+
+   procedure Columns_Set_Resizable
+     (Sheet : access Gtk_Sheet_Record; Resizable : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Resizable : Integer);
+      pragma Import (C, Internal, "gtk_sheet_columns_set_resizable");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Resizable));
+   end Columns_Set_Resizable;
+
+   -----------------------
+   -- Columns_Resizable --
+   -----------------------
+
+   function Columns_Resizable (Sheet : access Gtk_Sheet_Record)
+      return Boolean
+   is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_columns_resizable");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Columns_Resizable;
+
+   --------------------------
+   -- Row_Button_Get_Label --
+   --------------------------
+
+   function Row_Button_Get_Label
+     (Sheet : access Gtk_Sheet_Record; Row : Gint) return UTF8_String
+   is
+      function Internal (S : System.Address; Row : Gint) return chars_ptr;
+      pragma Import (C, Internal, "gtk_sheet_row_button_get_label");
+      S : constant chars_ptr := Internal (Get_Object (Sheet), Row);
+   begin
+      --  Do not free S, this references internal values
+      return Value (S);
+   end Row_Button_Get_Label;
+
+   ------------------------
+   -- Row_Titles_Visible --
+   ------------------------
+
+   function Row_Titles_Visible
+     (Sheet : access Gtk_Sheet_Record) return Boolean
+   is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_row_titles_visible");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Row_Titles_Visible;
+
+   ------------------------
+   -- Rows_Set_Resizable --
+   ------------------------
+
+   procedure Rows_Set_Resizable
+     (Sheet : access Gtk_Sheet_Record; Resizable : Boolean)
+   is
+      procedure Internal (Sheet : System.Address; Resizable : Integer);
+      pragma Import (C, Internal, "gtk_sheet_rows_set_resizable");
+   begin
+      Internal (Get_Object (Sheet), Boolean'Pos (Resizable));
+   end Rows_Set_Resizable;
+
+   --------------------
+   -- Rows_Resizable --
+   --------------------
+
+   function Rows_Resizable (Sheet : access Gtk_Sheet_Record)
+      return Boolean
+   is
+      function Internal (Sheet : System.Address) return Integer;
+      pragma Import (C, Internal, "gtk_sheet_rows_resizable");
+   begin
+      return Boolean'Val (Internal (Get_Object (Sheet)));
+   end Rows_Resizable;
+
+   ---------------------
+   -- Attach_Floating --
+   ---------------------
+
+   procedure Attach_Floating
+      (Sheet    : access Gtk_Sheet_Record;
+       Widget   : access Gtk.Widget.Gtk_Widget_Record'Class;
+       Row      : Gint;
+       Col      : Gint)
+   is
+      procedure Internal (Sheet, Widget : System.Address; R, C : Gint);
+      pragma Import (C, Internal, "gtk_sheet_attach_floating");
+   begin
+      Internal (Get_Object (Sheet), Get_Object (Widget), Row, Col);
+   end Attach_Floating;
+
+end Gtk.Extra.Sheet;
============================================================
--- src/gtk-extra-sheet.ads	cbca264d5a5f4fda4c40c27164767d2e37b012c6
+++ src/gtk-extra-sheet.ads	cbca264d5a5f4fda4c40c27164767d2e37b012c6
@@ -0,0 +1,967 @@
+-----------------------------------------------------------------------
+--               GtkAda - Ada95 binding for Gtk+/Gnome               --
+--                                                                   --
+--      Copyright (C) 2000 E. Briot, J. Brobecker and A. Charlet     --
+--                Copyright (C) 2000-2006 AdaCore                    --
+--                                                                   --
+-- This library is free software; you can redistribute it and/or     --
+-- modify it under the terms of the GNU General Public               --
+-- License as published by the Free Software Foundation; either      --
+-- version 2 of the License, or (at your option) any later version.  --
+--                                                                   --
+-- This library is distributed in the hope that it will be useful,   --
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of    --
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU --
+-- General Public License for more details.                          --
+--                                                                   --
+-- You should have received a copy of the GNU General Public         --
+-- License along with this library; if not, write to the             --
+-- Free Software Foundation, Inc., 59 Temple Place - Suite 330,      --
+-- Boston, MA 02111-1307, USA.                                       --
+--                                                                   --
+-----------------------------------------------------------------------
+
+--  <description>
+--  A Gtk_Sheet is a table like the one you can find in most spreadsheets.
+--  Each cell can contain some text or any kind of widgets.
+--  </description>
+--  <c_version>gtkextra 2.1.1</c_version>
+--  <group>GtkExtra, additional widgets</group>
+--  <testgtk>create_sheet.adb</testgtk>
+--  <screenshot>gtk-sheet</screenshot>
+
+with Gtk.Adjustment;  use Gtk.Adjustment;
+with Gtk.Container;
+with Gtk.Enums;       use Gtk.Enums;
+with Gtk.GEntry;
+with Gdk.Rectangle;
+with Gdk.Color;
+with Gdk.GC;
+with Pango.Font;
+with Gtk.Widget;
+
+package Gtk.Extra.Sheet is
+
+   type Gtk_Sheet_Record is new Gtk.Container.Gtk_Container_Record
+     with private;
+   type Gtk_Sheet is access all Gtk_Sheet_Record'Class;
+
+   type Gtk_Sheet_Range_Record is record
+      Row0, Col0 : Gint;  --  Upper-left cell
+      Rowi, Coli : Gint;  --  Lower-Right cell
+   end record;
+
+   type Gtk_Sheet_Range is access all Gtk_Sheet_Range_Record;
+   --  A range in the sheet.
+   --  This is a part of the sheet represented by its upper-left cell and
+   --  its lower-right cell.
+   --  Most operations below apply to such ranges.
+
+   type Gtk_Sheet_Child_Record is
+     new Gtk.Widget.Gtk_Widget_Record with private;
+   type Gtk_Sheet_Child is access all Gtk_Sheet_Child_Record'Class;
+   --  A widget insert in the sheet.
+   --  This structure includes both a widget pointer and the position in the
+   --  table in which it is put.
+
+   ----------------
+   -- Enum types --
+   ----------------
+
+   --  <doc_ignore>
+   type Sheet_Attr_Type is
+     (Sheet_Foreground,
+      Sheet_Background,
+      Sheet_Font,
+      Sheet_Justification,
+      Sheet_Border,
+      Sheet_Border_Color,
+      Sheet_Is_Editable,
+      Sheet_Is_Visible);
+   --  Attributes that can be set for the sheet.
+   --  No function is provided at the Ada level to modify these attributes
+   --  directly.
+   pragma Convention (C, Sheet_Attr_Type);
+   --  </doc_ignore>
+
+   type Sheet_State is
+     (Sheet_Normal,
+      Sheet_Row_Selected,
+      Sheet_Column_Selected,
+      Sheet_Range_Selected);
+   --  The state of the selection.
+   pragma Convention (C, Sheet_State);
+
+   type Gtk_Sheet_Border is new Integer;
+   --  Mask that indicates which borders should be visible in a cell.
+
+   No_Border     : constant Gtk_Sheet_Border;
+   Left_Border   : constant Gtk_Sheet_Border;
+   Right_Border  : constant Gtk_Sheet_Border;
+   Top_Border    : constant Gtk_Sheet_Border;
+   Bottom_Border : constant Gtk_Sheet_Border;
+   All_Borders   : constant Gtk_Sheet_Border;
+
+   -------------------------------
+   -- Creation and modification --
+   -------------------------------
+
+   procedure Gtk_New
+     (Sheet      : out Gtk_Sheet;
+      Rows       : Guint;
+      Columns    : Guint;
+      Title      : UTF8_String := "";
+      Entry_Type : Gtk_Type := GType_Invalid);
+   --  Create a new sheet with a specific number of rows and columns.
+   --  You can fully specify which type the entry used to modify the value of
+   --  cells should have. The value of Entry_Type can be found by using one
+   --  of the Get_Type subprograms in the GtkAda packages.
+   --  The Title is internal, and does not appear on the screen.
+
+   procedure Initialize
+     (Sheet      : access Gtk_Sheet_Record'Class;
+      Rows       : Guint;
+      Columns    : Guint;
+      Title      : UTF8_String := "";
+      Entry_Type : Gtk_Type := GType_Invalid);
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   procedure Gtk_New_Browser
+     (Sheet   : out Gtk_Sheet;
+      Rows    : Guint;
+      Columns : Guint;
+      Title   : UTF8_String := "");
+   --  Create a new sheet browser with a specific number of rows and columns.
+   --  This is a standard Gtk_Sheet, except that it is read-only and that its
+   --  cells will automatically resize themselves depending on their contents.
+
+   procedure Initialize_Browser (Sheet   : access Gtk_Sheet_Record'Class;
+                                 Rows    : in Guint;
+                                 Columns : in Guint;
+                                 Title   : in UTF8_String := "");
+   --  Internal initialization function.
+   --  See the section "Creating your own widgets" in the documentation.
+
+   function Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associated with a Gtk_Sheet.
+
+   procedure Set_Hadjustment
+     (Sheet      : access Gtk_Sheet_Record;
+      Adjustment : access Gtk_Adjustment_Record'Class);
+   --  Change the horizontal adjustment.
+   --  It indicates what range of columns is visible.
+
+   procedure Set_Vadjustment
+      (Sheet      : access Gtk_Sheet_Record;
+       Adjustment : access Gtk_Adjustment_Record'Class);
+   --  Change the vertical adjustment.
+   --  It indicates what range of rows is visible.
+
+   function Get_Vadjustment
+     (Sheet  : access Gtk_Sheet_Record)
+      return      Gtk.Adjustment.Gtk_Adjustment;
+   --  Return the adjustment used to indicate the range of visible rows.
+
+   function Get_Hadjustment
+     (Sheet  : access Gtk_Sheet_Record)
+      return      Gtk.Adjustment.Gtk_Adjustment;
+   --  Return the adjustment used to indicate the range of visible columns.
+
+   procedure Change_Entry
+     (Sheet      : access Gtk_Sheet_Record;
+      Entry_Type : Gtk_Type);
+   --  Change the type of widget used to interactively modify the value of
+   --  the cells.
+
+   function Get_Entry
+     (Sheet : access Gtk_Sheet_Record) return Gtk.GEntry.Gtk_Entry;
+   --  Return the entry used to modify the content of the cells.
+   --  This can be the same widget as Get_Entry_Widget, if set, or some default
+   --  widget associated with the specific child otherwise
+
+   function Get_Entry_Widget
+     (Sheet : access Gtk_Sheet_Record) return Gtk.Widget.Gtk_Widget;
+   --  Return the entry used to modify the content of the cells.
+
+   procedure Set_Title
+     (Sheet : access Gtk_Sheet_Record;
+      Title : UTF8_String);
+   --  Change the title of the sheet.
+
+   procedure Freeze (Sheet : access Gtk_Sheet_Record);
+   --  Freeze all visual updates of the sheet, until you thaw it.
+   --  The update will occur in a more efficient way.
+
+   procedure Thaw (Sheet : access Gtk_Sheet_Record);
+   --  Thaw the sheet, so that visual updates occur again.
+   --  Note that you have to call Thaw as many times as you have called
+   --  Freeze to actually thaw the widget.
+
+   procedure Moveto
+     (Sheet     : access Gtk_Sheet_Record;
+      Row       : Gint;
+      Column    : Gint;
+      Row_Align : Gfloat;
+      Col_Align : Gfloat);
+   --  Scroll the viewing area to (Row, Column).
+   --  (Row_Align, Col_Align) represent the location on the screen that the
+   --  cell should appear at. (0.0, 0.0) is at the top-left of the screen,
+   --  whereas (1.0, 1.0) is at the bottom-right corner.
+   --  If Row or Column is negative, there is no change.
+
+   procedure Set_Background
+     (Sheet : access Gtk_Sheet_Record; Color : Gdk.Color.Gdk_Color);
+   --  Change the background color of the cells.
+
+   procedure Set_Grid
+     (Sheet : access Gtk_Sheet_Record; Color : Gdk.Color.Gdk_Color);
+   --  Set the color to use for the grid.
+
+   procedure Show_Grid
+     (Sheet : access Gtk_Sheet_Record; Show : Boolean);
+   --  Whether the grid should be made visible
+
+   function Grid_Visible (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether the grid is currently visible
+
+   ----------------------------
+   -- Selection and Clipping --
+   ----------------------------
+
+   function Get_State (Sheet : access Gtk_Sheet_Record) return Sheet_State;
+   --  Return the status of the selection in the sheet.
+
+   function Get_Range (Sheet : access Gtk_Sheet_Record) return Gtk_Sheet_Range;
+   --  Return the selected range.
+
+   procedure Get_Visible_Range
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : out Gtk_Sheet_Range);
+   --  Return the range visible on the screen.
+
+   procedure Set_Selection_Mode
+     (Sheet : access Gtk_Sheet_Record;
+      Mode  : Gtk.Enums.Gtk_Selection_Mode);
+   --  Change the selection mode.
+
+   procedure Select_Column
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint);
+   --  Replace the current selection with a specific column.
+   --  The range is highlighted.
+
+   procedure Select_Row
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint);
+   --  Replace the current selection with a specific row.
+   --  The range is highlighted.
+
+   procedure Set_Autoresize
+     (Sheet : access Gtk_Sheet_Record; Autoresize : Boolean);
+   --  Whether cells should automatically resize to fit their contents
+
+   function Autoresize (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether cells automatically resize to fit their contents
+
+   procedure Set_Autoscroll
+     (Sheet : access Gtk_Sheet_Record; Autoscroll : Boolean);
+   --  Whether the sheet should automatically scroll to show the active cell at
+   --  all times.
+
+   function Autoscroll (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether the sheet automatically scrolls to show the active cell at all
+   --  times.
+
+   procedure Set_Clip_Text
+     (Sheet : access Gtk_Sheet_Record; Clip : Boolean);
+   --  Set when the text contained in the cells is automatically clipped to
+   --  their width.
+
+   function Clip_Text (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether the text contained in the cells is automatically clipped to
+   --  their width.
+
+   procedure Set_Justify_Entry
+     (Sheet : access Gtk_Sheet_Record; Justify_Entry : Boolean);
+   --  Set when the justification attribute for entries should be taken into
+   --  account
+
+   function Justify_Entry (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether the justification attribute is used for entries
+
+   procedure Set_Locked
+     (Sheet : access Gtk_Sheet_Record; Locked : Boolean);
+   --  If Locked is true, the cells are no longer editable
+
+   function Locked (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether cells are currently read-only
+
+   procedure Select_Range
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range);
+   --  Select a new range of cells.
+
+   procedure Unselect_Range (Sheet : access Gtk_Sheet_Record);
+   --  Unselect a specific range of cells.
+   --  If null is passed, the current selected range is used.
+
+   procedure Clip_Range (Sheet     : access Gtk_Sheet_Record;
+                         The_Range : in Gtk_Sheet_Range);
+   --  Create a new clip range, which is copied to the clipboard
+   --  That range is flashed on the screen.
+
+   procedure Unclip_Range (Sheet : access Gtk_Sheet_Record);
+   --  Destroy the clip area.
+
+   function In_Clip (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether a range was copied to the clipboard
+
+   function Set_Active_Cell
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Column : Gint)
+      return Boolean;
+   --  Set active cell where the entry will be displayed.
+   --  Returns FALSE if the current cell can not be deactivated or if the
+   --  requested cell can't be activated.
+   --  Depending on the value passed to Set_Autoscroll, the sheet might be
+   --  scrolled.
+
+   procedure Get_Active_Cell
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : out Gint;
+      Column : out Gint);
+   --  Return the coordinates of the active cell.
+   --  This is the cell that the user is currently editing.
+
+   -------------
+   -- Columns --
+   -------------
+
+   procedure Set_Column_Title
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint;
+      Title  : UTF8_String);
+   --  Modify the title of a column.
+   --  The first column on the left has the number 0.
+   --  Note that this title does not appear on the screen, and can only be
+   --  used internally to find a specific column.
+
+   function Get_Column_Title
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint) return UTF8_String;
+   --  Return the title of a specific column.
+
+   procedure Set_Column_Titles_Height
+     (Sheet  : access Gtk_Sheet_Record; Height : Guint);
+   --  Modify the height of the row in which the column titles appear.
+
+   procedure Column_Button_Add_Label
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint;
+      Label  : UTF8_String);
+   --  Modify the label of the button that appears at the top of each column.
+
+   function Column_Button_Get_Label
+     (Sheet : access Gtk_Sheet_Record; Column : Gint) return UTF8_String;
+   --  Return the label for the button that appears at the top of each column
+
+   procedure Column_Button_Justify
+      (Sheet         : access Gtk_Sheet_Record;
+       Column        : Gint;
+       Justification : Gtk.Enums.Gtk_Justification);
+   --  Modify the justification for the label in the column button.
+
+   procedure Show_Column_Titles (Sheet : access Gtk_Sheet_Record);
+   --  Show the row in which the column titles appear.
+
+   procedure Hide_Column_Titles (Sheet : access Gtk_Sheet_Record);
+   --  Hide the row in which the column titles appear.
+
+   function Column_Titles_Visible
+     (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether a special row is added at the top to show the title of the
+   --  columns.
+
+   procedure Columns_Set_Sensitivity
+     (Sheet     : access Gtk_Sheet_Record;
+      Sensitive : Boolean);
+   --  Modify the sensitivity of all the columns.
+   --  If Sensitive is False, the columns can not be resized dynamically.
+   --  This also modifies the sensitivity of the button at the top of the
+   --  columns.
+
+   procedure Column_Set_Sensitivity
+     (Sheet     : access Gtk_Sheet_Record;
+      Column    : Gint;
+      Sensitive : Boolean);
+   --  Modify the sensitivity of a specific column and its title button.
+   --  If Sensitive if False, the column can not be dynamically resized.
+
+   procedure Column_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Column  : Gint;
+      Visible : Boolean);
+   --  Change the visibility of a column.
+
+   procedure Columns_Set_Resizable
+     (Sheet : access Gtk_Sheet_Record; Resizable : Boolean);
+   --  Whether columns are resizable
+
+   function Columns_Resizable (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether columns are resizable
+
+   procedure Column_Label_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Column  : Gint;
+      Visible : Boolean := True);
+   --  Change the visibility of the label in a given column.
+
+   procedure Columns_Labels_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Visible : Boolean := True);
+   --  Change the visibility for all the column labels.
+
+   procedure Set_Column_Width
+     (Sheet  : access Gtk_Sheet_Record;
+      Column : Gint;
+      Width  : Guint);
+   --  Modify the width in pixels of a specific column.
+
+   function Get_Column_Width (Sheet  : access Gtk_Sheet_Record;
+                              Column : in Gint)
+                             return Gint;
+   --  Return the width in pixels of the Column-nth in Sheet.
+
+   procedure Add_Column
+     (Sheet : access Gtk_Sheet_Record;
+      Ncols : Guint);
+   --  Add some empty columns at the end of the sheet.
+
+   procedure Insert_Columns
+     (Sheet : access Gtk_Sheet_Record;
+      Col   : Guint;
+      Ncols : Guint);
+   --  Add Ncols empty columns just before the columns number Col.
+
+   procedure Delete_Columns
+     (Sheet : access Gtk_Sheet_Record;
+      Col   : Guint;
+      Ncols : Guint);
+   --  Delete Ncols columns starting from Col.
+
+   procedure Column_Set_Justification
+     (Sheet         : access Gtk_Sheet_Record;
+      Column        : Gint;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Set the default justification for the cells in the specific column.
+
+   function Get_Columns_Count (Sheet : access Gtk_Sheet_Record) return Guint;
+   --  Return the maximum column number of the displayed cells.
+
+   ----------
+   -- Rows --
+   ----------
+
+   procedure Set_Row_Title
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Title : UTF8_String);
+   --  Modify the title of a row.
+   --  The first row at the top has the number 0.
+   --  Note that this title does not appear on the screen, and can only be
+   --  used internally to find a specific row.
+
+   function Get_Row_Title
+     (Sheet  : access Gtk_Sheet_Record; Row : Gint) return UTF8_String;
+   --  Return the title of a specific row.
+
+   procedure Set_Row_Titles_Width
+     (Sheet : access Gtk_Sheet_Record; Width : Guint);
+   --  Modify the width of the column that has the row titles.
+
+   procedure Row_Button_Add_Label
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Label : UTF8_String);
+   --  Modify the label of the button that appears on the left of each row.
+
+   function Row_Button_Get_Label
+     (Sheet : access Gtk_Sheet_Record; Row : Gint) return UTF8_String;
+   --  Return the label for the button that appears on the left of each row.
+
+   procedure Row_Button_Justify
+      (Sheet         : access Gtk_Sheet_Record;
+       Row           : Gint;
+       Justification : Gtk.Enums.Gtk_Justification);
+   --  Modify the justification for the label of the row button.
+
+   procedure Show_Row_Titles (Sheet : access Gtk_Sheet_Record);
+   --  Show the column in which the row titles appear.
+
+   procedure Hide_Row_Titles (Sheet : access Gtk_Sheet_Record);
+   --  Hide the column in which the row titles appear.
+
+   function Row_Titles_Visible
+     (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether a special column is added to the left to show the title of the
+   --  rows.
+
+   procedure Rows_Set_Sensitivity (Sheet     : access Gtk_Sheet_Record;
+                                   Sensitive : in Boolean);
+   --  Modify the sensitivity of all the rows.
+   --  If Sensitive is False, the rows can not be resized dynamically.
+   --  This also modifies the sensitivity of the button at the left of the
+   --  row.
+
+   procedure Row_Set_Sensitivity (Sheet     : access Gtk_Sheet_Record;
+                                  Row       : in Gint;
+                                  Sensitive : in Boolean);
+   --  Modify the sensitivity of a specific row and its title button.
+   --  If Sensitive if False, the row can not be dynamically resized.
+
+   procedure Row_Set_Visibility (Sheet   : access Gtk_Sheet_Record;
+                                 Row     : in Gint;
+                                 Visible : in Boolean);
+   --  Modify the visibility of a specific row
+
+   procedure Row_Label_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Row    : in Gint;
+      Visible : in Boolean := True);
+   --  Change the visibility of the label in a given Row.
+
+   procedure Rows_Labels_Set_Visibility
+     (Sheet   : access Gtk_Sheet_Record;
+      Visible : Boolean := True);
+   --  Change the visibility for all the row labels.
+
+   procedure Rows_Set_Resizable
+     (Sheet : access Gtk_Sheet_Record; Resizable : Boolean);
+   --  Whether rows are resizable
+
+   function Rows_Resizable (Sheet : access Gtk_Sheet_Record) return Boolean;
+   --  Whether rows are resizable
+
+   procedure Set_Row_Height
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Height : Guint);
+   --  Set the height in pixels of a specific row.
+
+   function Get_Row_Height (Sheet   : access Gtk_Sheet_Record;
+                            Row     : in Gint)
+                           return Gint;
+   --  Return the height in pixels of the Row-th row in Sheet.
+
+   procedure Add_Row
+     (Sheet : access Gtk_Sheet_Record;
+      Nrows : Guint);
+   --  Append Nrows row at the end of the sheet.
+
+   procedure Insert_Rows
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Guint;
+      Nrows : Guint);
+   --  Add Nrows empty rows just before the row number Row.
+
+   procedure Delete_Rows
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Guint;
+      Nrows : Guint);
+   --  Delete Nrows rows starting from Row.
+
+   function Get_Rows_Count (Sheet : access Gtk_Sheet_Record) return Guint;
+   --  Return the maximum row number of displayed cells.
+
+   -----------
+   -- Range --
+   -----------
+
+   function Range_Get_Type return Gtk.Gtk_Type;
+   --  Return the internal value associate with a Gtk_Sheet_Range
+
+   procedure Range_Clear
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range);
+   --  Clear the content of the range.
+
+   procedure Range_Delete
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range);
+   --  Clear the content of the range and delete all the links (user_data)
+
+   procedure Range_Set_Background
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range;
+      Color     : Gdk.Color.Gdk_Color);
+   --  Set the background color for the cells in a specific range.
+
+   procedure Range_Set_Foreground
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range;
+      Color     : Gdk.Color.Gdk_Color);
+   --  Set the foreground color for the cells in a specific range.
+
+   procedure Range_Set_Justification
+     (Sheet         : access Gtk_Sheet_Record;
+      The_Range     : Gtk_Sheet_Range;
+      Justification : Gtk.Enums.Gtk_Justification);
+   --  Set the text justification for the cells in the range.
+
+   procedure Range_Set_Editable
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range;
+      Editable  : Boolean);
+   --  Set whether the cells in the range are editable.
+
+   procedure Range_Set_Visible (Sheet     : access Gtk_Sheet_Record;
+                                The_Range : in Gtk_Sheet_Range;
+                                Visible   : in Boolean);
+   --  Set whether the cells in the range are visible.
+
+   procedure Range_Set_Border
+     (Sheet      : access Gtk_Sheet_Record;
+      The_Range  : Gtk_Sheet_Range;
+      Mask       : Gtk_Sheet_Border;
+      Width      : Guint;
+      Line_Style : Gdk.GC.Gdk_Line_Style);
+   --  Set the style of the border for the cells in the range.
+
+   procedure Range_Set_Border_Color
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range;
+      Color     : Gdk.Color.Gdk_Color);
+   --  Change the color for the borders of the cells in the range.
+
+   procedure Range_Set_Font
+     (Sheet     : access Gtk_Sheet_Record;
+      The_Range : Gtk_Sheet_Range;
+      Font      : Pango.Font.Pango_Font_Description);
+   --  Change the font of the cells in the range.
+
+   -----------
+   -- Cells --
+   -----------
+
+   procedure Set_Cell
+     (Sheet         : access Gtk_Sheet_Record;
+      Row           : Gint;
+      Col           : Gint;
+      Justification : Gtk.Enums.Gtk_Justification;
+      Text          : UTF8_String);
+   --  Set the cell contents.
+   --  Set Text to the empty string to delete the content of the cell.
+
+   procedure Set_Cell_Text
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Col   : Gint;
+      Text  : UTF8_String);
+   --  Set the cell contents.
+   --  The justification used is the previous one used in that cell.
+
+   function Cell_Get_Text
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Col    : Gint)
+      return UTF8_String;
+   --  Return the text put in a specific cell.
+   --  The empty string is returned if there is no text in that cell.
+
+   procedure Cell_Clear
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Col   : Gint);
+   --  Clear the contents of the cell.
+
+   procedure Cell_Delete
+     (Sheet : access Gtk_Sheet_Record;
+      Row   : Gint;
+      Col   : Gint);
+   --  Clear the contents of the cell and remove the user data associated
+   --  with it.
+
+   function Cell_Get_State (Sheet  : access Gtk_Sheet_Record;
+                            Row    : in Gint;
+                            Col    : in Gint)
+                           return  Gtk.Enums.Gtk_State_Type;
+   --  Return the state of the cell (normal or selected).
+
+   procedure Get_Pixel_Info
+     (Sheet  : access Gtk_Sheet_Record;
+      X      : Gint;
+      Y      : Gint;
+      Row    : out Gint;
+      Column : out Gint);
+   --  Return the row and column matching a given pixel on the screen.
+   --  Constraint_Error is raised if no such cell exists.
+
+   procedure Get_Cell_Area
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Column : Gint;
+      Area   : out Gdk.Rectangle.Gdk_Rectangle);
+   --  Get the area of the screen that a cell is mapped to.
+   --  Constraint_Error is raised if no such cell exists;
+
+   --------------
+   -- Children --
+   --------------
+   --  A Gtk_Sheet can contain some children, attached to some specific
+   --  cells.
+
+   procedure Put
+     (Sheet  : access Gtk_Sheet_Record;
+      Widget : access Gtk.Widget.Gtk_Widget_Record'Class;
+      X      : Gint;
+      Y      : Gint);
+   --  Put a new child at a specific location (in pixels) in the sheet.
+
+   procedure Attach
+      (Sheet    : access Gtk_Sheet_Record;
+       Widget   : access Gtk.Widget.Gtk_Widget_Record'Class;
+       Row      : Gint;
+       Col      : Gint;
+       Xoptions : Gtk.Enums.Gtk_Attach_Options := Expand or Fill;
+       Yoptions : Gtk.Enums.Gtk_Attach_Options := Expand or Fill;
+       Xpadding : Gint := 0;
+       Ypadding : Gint := 0);
+   --  Attach a child to a specific Cell in the sheet.
+   --  X_Align and Y_Align should be between 0.0 and 1.0, indicating that
+   --  the child should be aligned from the Left (resp. Top) to the Right
+   --  (resp. Bottom) of the cell.
+   --  If Row or Col is negative, the widget is attached to the row buttons or
+   --  column buttons.
+   --  Widget will not be moved if the cell is moved.
+
+   procedure Attach_Floating
+      (Sheet    : access Gtk_Sheet_Record;
+       Widget   : access Gtk.Widget.Gtk_Widget_Record'Class;
+       Row      : Gint;
+       Col      : Gint);
+   --  Attach a child at the current location or (Row, Col).
+   --  If the cell is moved because of resizing or other reasons, Widget will
+   --  be moved as well.
+
+   procedure Move_Child
+      (Sheet  : access Gtk_Sheet_Record;
+       Widget : access Gtk.Widget.Gtk_Widget_Record'Class;
+       X      : Gint;
+       Y      : Gint);
+   --  Move a child of the table to a specific location in pixels.
+   --  A warning is printed if Widget is not already a child of Sheet.
+
+   function Get_Child_At
+     (Sheet  : access Gtk_Sheet_Record;
+      Row    : Gint;
+      Col    : Gint)
+      return Gtk_Sheet_Child;
+   --  Return the widget associated with the cell.
+
+   function Get_Widget (Child : Gtk_Sheet_Child) return Gtk.Widget.Gtk_Widget;
+   --  Return the widget in the child.
+
+   procedure Button_Attach
+     (Sheet   : access Gtk_Sheet_Record;
+      Widget  : access Gtk.Widget.Gtk_Widget_Record'Class;
+      Row     : Gint;
+      Col     : Gint);
+   --  Attach a new button in the row or column title.
+   --  One of Row or Col must be negative (but only one).
+   --  This can be used to modify the standard buttons that appear at the top
+   --  of each column, or on the left of each row.
+
+   -----------------------
+