------------------------------------------------------------------------------
--                                                                          --
--                An Ada2005 binding to the Qt C++ framework                --
--                                                                          --
------------------------------------------------------------------------------
--                                                                          --
-- Copyright © 2008-2010 Vadim Godunko <vgodunko@gmail.com>                 --
--                                                                          --
-- QtAda is free software;  you can  redistribute it and/or modify it under --
-- terms of the  GNU General Public License as published  by the Free Soft- --
-- ware  Foundation;  either version 2,  or (at your option) any later ver- --
-- sion. QtAda is distributed in the hope that it will be useful, but WITH- --
-- OUT 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 distributed with QtAda;  see file COPYING.  If not, write --
-- to  the  Free Software Foundation,  51  Franklin  Street,  Fifth  Floor, --
-- Boston, MA 02110-1301, USA.                                              --
--                                                                          --
-- As a special exception,  if other files  instantiate  generics from this --
-- unit, or you link  this unit with other files  to produce an executable, --
-- this  unit  does not  by itself cause  the resulting  executable  to  be --
-- covered  by the  GNU  General  Public  License.  This exception does not --
-- however invalidate  any other reasons why  the executable file  might be --
-- covered by the  GNU Public License.                                      --
--                                                                          --
------------------------------------------------------------------------------
--    This file has been generated automatically. Please don't edit it.     --
------------------------------------------------------------------------------
with Qt4.Graphics_Ellipse_Items;
with Qt4.Graphics_Items;
with Qt4.Graphics_Items.Directors;
with Qt4.Graphics_Line_Items;
with Qt4.Graphics_Path_Items;
with Qt4.Graphics_Polygon_Items;
with Qt4.Graphics_Rect_Items;
with Qt4.Graphics_Simple_Text_Items;
with Qt4.Graphics_Text_Items;
with Qt_Ada.Internals.Graphics_Item_Registry;
with Qt_Ada.Internals.Graphics_Items;
with Qt_Ada.Internals.Graphics_Items.Graphics_Item_Utilities;
with Qt_Ada.Internals.Object_Registry;
with Qt_Ada.Internals.Objects;

with Qt_Ada.Internals.Objects.Graphics_Scene_Proxies;
pragma Warnings (Off, Qt_Ada.Internals.Objects.Graphics_Scene_Proxies);
--  Elaboration of the proxy tagged type package register proxy object
--  constructor. Bindings must be able to create proxy object of the
--  corresponding tagged type for works properly.

package body Qt4.Graphics_Scenes is

   function addEllipse_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Rect : not null access constant Qt4.Rect_Fs.Internals.QRectF;
     Pen : not null access constant Qt4.Pens.Internals.QPen;
     Brush : not null access constant Qt4.Brushes.Internals.QBrush)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, addEllipse_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addEllipse_0_wrapper");

   procedure addItem_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Item : not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem);
   pragma Import (C, addItem_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addItem_0_wrapper");

   function addLine_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Line : not null access constant Qt4.Line_Fs.Internals.QLineF;
     Pen : not null access constant Qt4.Pens.Internals.QPen)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, addLine_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addLine_0_wrapper");

   function addPath_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Path : not null access constant Qt4.Painter_Paths.Internals.QPainterPath;
     Pen : not null access constant Qt4.Pens.Internals.QPen;
     Brush : not null access constant Qt4.Brushes.Internals.QBrush)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, addPath_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addPath_0_wrapper");

   function addPolygon_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Path : not null access constant Qt4.Polygon_Fs.Internals.QPolygonF;
     Pen : not null access constant Qt4.Pens.Internals.QPen;
     Brush : not null access constant Qt4.Brushes.Internals.QBrush)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, addPolygon_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addPolygon_0_wrapper");

   function addRect_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Path : not null access constant Qt4.Rect_Fs.Internals.QRectF;
     Pen : not null access constant Qt4.Pens.Internals.QPen;
     Brush : not null access constant Qt4.Brushes.Internals.QBrush)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, addRect_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addRect_0_wrapper");

   function addSimpleText_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Text : not null access constant Qt4.Strings.Internals.QString;
     Font : not null access constant Qt4.Fonts.Internals.QFont)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, addSimpleText_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addSimpleText_0_wrapper");

   function addText_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Text : not null access constant Qt4.Strings.Internals.QString;
     Font : not null access constant Qt4.Fonts.Internals.QFont)
       return not null access Qt_Ada.Internals.Objects.QObject;
   pragma Import (C, addText_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_addText_0_wrapper");

   procedure backgroundBrush_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Returns : not null access Qt4.Brushes.Internals.QBrush);
   pragma Import (C, backgroundBrush_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_backgroundBrush_0_wrapper");

   procedure clearFocus_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject);
   pragma Import (C, clearFocus_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_clearFocus_0_wrapper");

   procedure clearSelection_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject);
   pragma Import (C, clearSelection_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_clearSelection_0_wrapper");

   function focusItem_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, focusItem_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_focusItem_0_wrapper");

   procedure foregroundBrush_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Returns : not null access Qt4.Brushes.Internals.QBrush);
   pragma Import (C, foregroundBrush_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_foregroundBrush_0_wrapper");

   function hasFocus_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject)
       return Qt4.bool;
   pragma Import (C, hasFocus_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_hasFocus_0_wrapper");

   function height_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject)
       return Qt4.Q_Real;
   pragma Import (C, height_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_height_0_wrapper");

   function itemAt_1_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Pos : not null access constant Qt4.Point_Fs.Internals.QPointF)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, itemAt_1_wrapper,
                     "__Qt4Ada_QGraphicsScene_itemAt_1_wrapper");

   function itemAt_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     X : Qt4.Q_Real;
     Y : Qt4.Q_Real)
       return not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, itemAt_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_itemAt_0_wrapper");

   function itemIndexMethod_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject)
       return Qt4.Graphics_Scenes.Graphics_Scene_Item_Index_Method;
   pragma Import (C, itemIndexMethod_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_itemIndexMethod_0_wrapper");

   procedure itemsBoundingRect_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Returns : not null access Qt4.Rect_Fs.Internals.QRectF);
   pragma Import (C, itemsBoundingRect_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_itemsBoundingRect_0_wrapper");

   function mouseGrabberItem_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject)
       return access Qt_Ada.Internals.Graphics_Items.QGraphicsItem;
   pragma Import (C, mouseGrabberItem_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_mouseGrabberItem_0_wrapper");

   procedure removeItem_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Item : not null access Qt_Ada.Internals.Graphics_Items.QGraphicsItem);
   pragma Import (C, removeItem_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_removeItem_0_wrapper");

   procedure sceneRect_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Returns : not null access Qt4.Rect_Fs.Internals.QRectF);
   pragma Import (C, sceneRect_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_sceneRect_0_wrapper");

   procedure setBackgroundBrush_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Brush : not null access constant Qt4.Brushes.Internals.QBrush);
   pragma Import (C, setBackgroundBrush_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_setBackgroundBrush_0_wrapper");

   procedure setForegroundBrush_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Brush : not null access constant Qt4.Brushes.Internals.QBrush);
   pragma Import (C, setForegroundBrush_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_setForegroundBrush_0_wrapper");

   procedure setItemIndexMethod_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Method : Qt4.Graphics_Scenes.Graphics_Scene_Item_Index_Method);
   pragma Import (C, setItemIndexMethod_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_setItemIndexMethod_0_wrapper");

   procedure setSceneRect_1_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Rect : not null access constant Qt4.Rect_Fs.Internals.QRectF);
   pragma Import (C, setSceneRect_1_wrapper,
                     "__Qt4Ada_QGraphicsScene_setSceneRect_1_wrapper");

   procedure setSceneRect_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     X : Qt4.Q_Real;
     Y : Qt4.Q_Real;
     W : Qt4.Q_Real;
     H : Qt4.Q_Real);
   pragma Import (C, setSceneRect_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_setSceneRect_0_wrapper");

   procedure setSelectionArea_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Path : not null access constant Qt4.Painter_Paths.Internals.QPainterPath);
   pragma Import (C, setSelectionArea_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_setSelectionArea_0_wrapper");

   function width_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject)
       return Qt4.Q_Real;
   pragma Import (C, width_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_width_0_wrapper");

   procedure advance_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject);
   pragma Import (C, advance_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_advance_0_wrapper");

   procedure update_0_wrapper
    (Self : not null access Qt_Ada.Internals.Objects.QObject;
     Rect : not null access constant Qt4.Rect_Fs.Internals.QRectF);
   pragma Import (C, update_0_wrapper,
                     "__Qt4Ada_QGraphicsScene_update_0_wrapper");

   procedure items_wrapper
    (Self    : not null access Qt_Ada.Internals.Objects.QObject;
     Returns : not null access
       Qt4.List_Of_Graphics_Items.Thin.QListOfQGraphicsItem);
   pragma Import
    (C, items_wrapper, "__Qt4Ada_QGraphicsScene_items_wrapper");

   -----------
   -- Items --
   -----------

   function Items (Self : not null access constant Q_Graphics_Scene'Class)
     return Qt4.List_Of_Graphics_Items.Q_List_Of_Q_Graphics_Item
   is
      Returns : Qt4.List_Of_Graphics_Items.Q_List_Of_Q_Graphics_Item;

   begin
      items_wrapper
       (Self.QObject_View,
        Qt4.List_Of_Graphics_Items.Internals.QListOfQGraphicsItem_View
         (Returns));
      return Returns;
   end Items;

   -----------------
   -- Add_Polygon --
   -----------------

   procedure Add_Polygon
    (Self  : not null access Q_Graphics_Scene'Class;
     Path  : Qt4.Polygon_Fs.Q_Polygon_F;
     Pen   : Qt4.Pens.Q_Pen := Qt4.Pens.Create;
     Brush : Qt4.Brushes.Q_Brush := Qt4.Brushes.Create)
   is
      Item : constant not null access
         Qt4.Graphics_Polygon_Items.Q_Graphics_Polygon_Item'Class
           := Self.Add_Polygon (Path, Pen, Brush);
      pragma Unreferenced (Item);

   begin
      null;
   end Add_Polygon;

   pragma Style_Checks ("N");

   -----------------
   -- Add_Ellipse --
   -----------------

   function Add_Ellipse
    (Self : not null access Q_Graphics_Scene'Class;
     Rect : Qt4.Rect_Fs.Q_Rect_F;
     Pen : Qt4.Pens.Q_Pen
       := Qt4.Pens.Create;
     Brush : Qt4.Brushes.Q_Brush
       := Qt4.Brushes.Create)
       return not null access Qt4.Graphics_Ellipse_Items.Q_Graphics_Ellipse_Item'Class
   is
   begin
      return
        Qt4.Graphics_Ellipse_Items.Q_Graphics_Ellipse_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (addEllipse_0_wrapper
             (Self.QObject_View,
              Qt4.Rect_Fs.Internals.QRectF_View (Rect),
              Qt4.Pens.Internals.QPen_View (Pen),
              Qt4.Brushes.Internals.QBrush_View (Brush))).all)'Access;
   end Add_Ellipse;

   --------------
   -- Add_Item --
   --------------

   procedure Add_Item
    (Self : not null access Q_Graphics_Scene'Class;
     Item : not null access Qt4.Graphics_Items.Q_Graphics_Item'Class)
   is
   begin
      addItem_0_wrapper
       (Self.QObject_View,
        Item.QGraphicsItem_View);
   end Add_Item;

   --------------
   -- Add_Line --
   --------------

   function Add_Line
    (Self : not null access Q_Graphics_Scene'Class;
     Line : Qt4.Line_Fs.Q_Line_F;
     Pen : Qt4.Pens.Q_Pen
       := Qt4.Pens.Create)
       return not null access Qt4.Graphics_Line_Items.Q_Graphics_Line_Item'Class
   is
   begin
      return
        Qt4.Graphics_Line_Items.Q_Graphics_Line_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (addLine_0_wrapper
             (Self.QObject_View,
              Qt4.Line_Fs.Internals.QLineF_View (Line),
              Qt4.Pens.Internals.QPen_View (Pen))).all)'Access;
   end Add_Line;

   --------------
   -- Add_Path --
   --------------

   function Add_Path
    (Self : not null access Q_Graphics_Scene'Class;
     Path : Qt4.Painter_Paths.Q_Painter_Path;
     Pen : Qt4.Pens.Q_Pen
       := Qt4.Pens.Create;
     Brush : Qt4.Brushes.Q_Brush
       := Qt4.Brushes.Create)
       return not null access Qt4.Graphics_Path_Items.Q_Graphics_Path_Item'Class
   is
   begin
      return
        Qt4.Graphics_Path_Items.Q_Graphics_Path_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (addPath_0_wrapper
             (Self.QObject_View,
              Qt4.Painter_Paths.Internals.QPainterPath_View (Path),
              Qt4.Pens.Internals.QPen_View (Pen),
              Qt4.Brushes.Internals.QBrush_View (Brush))).all)'Access;
   end Add_Path;

   -----------------
   -- Add_Polygon --
   -----------------

   function Add_Polygon
    (Self : not null access Q_Graphics_Scene'Class;
     Path : Qt4.Polygon_Fs.Q_Polygon_F;
     Pen : Qt4.Pens.Q_Pen
       := Qt4.Pens.Create;
     Brush : Qt4.Brushes.Q_Brush
       := Qt4.Brushes.Create)
       return not null access Qt4.Graphics_Polygon_Items.Q_Graphics_Polygon_Item'Class
   is
   begin
      return
        Qt4.Graphics_Polygon_Items.Q_Graphics_Polygon_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (addPolygon_0_wrapper
             (Self.QObject_View,
              Qt4.Polygon_Fs.Internals.QPolygonF_View (Path),
              Qt4.Pens.Internals.QPen_View (Pen),
              Qt4.Brushes.Internals.QBrush_View (Brush))).all)'Access;
   end Add_Polygon;

   --------------
   -- Add_Rect --
   --------------

   function Add_Rect
    (Self : not null access Q_Graphics_Scene'Class;
     Path : Qt4.Rect_Fs.Q_Rect_F;
     Pen : Qt4.Pens.Q_Pen
       := Qt4.Pens.Create;
     Brush : Qt4.Brushes.Q_Brush
       := Qt4.Brushes.Create)
       return not null access Qt4.Graphics_Rect_Items.Q_Graphics_Rect_Item'Class
   is
   begin
      return
        Qt4.Graphics_Rect_Items.Q_Graphics_Rect_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (addRect_0_wrapper
             (Self.QObject_View,
              Qt4.Rect_Fs.Internals.QRectF_View (Path),
              Qt4.Pens.Internals.QPen_View (Pen),
              Qt4.Brushes.Internals.QBrush_View (Brush))).all)'Access;
   end Add_Rect;

   ---------------------
   -- Add_Simple_Text --
   ---------------------

   function Add_Simple_Text
    (Self : not null access Q_Graphics_Scene'Class;
     Text : Qt4.Strings.Q_String;
     Font : Qt4.Fonts.Q_Font
       := Qt4.Fonts.Create)
       return not null access Qt4.Graphics_Simple_Text_Items.Q_Graphics_Simple_Text_Item'Class
   is
   begin
      return
        Qt4.Graphics_Simple_Text_Items.Q_Graphics_Simple_Text_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (addSimpleText_0_wrapper
             (Self.QObject_View,
              Qt4.Strings.Internals.QString_View (Text),
              Qt4.Fonts.Internals.QFont_View (Font))).all)'Access;
   end Add_Simple_Text;

   --------------
   -- Add_Text --
   --------------

   function Add_Text
    (Self : not null access Q_Graphics_Scene'Class;
     Text : Qt4.Strings.Q_String;
     Font : Qt4.Fonts.Q_Font
       := Qt4.Fonts.Create)
       return not null access Qt4.Graphics_Text_Items.Q_Graphics_Text_Item'Class
   is
   begin
      return
        Qt4.Graphics_Text_Items.Q_Graphics_Text_Item'Class
         (Qt_Ada.Internals.Object_Registry.To_Q_Object
           (addText_0_wrapper
             (Self.QObject_View,
              Qt4.Strings.Internals.QString_View (Text),
              Qt4.Fonts.Internals.QFont_View (Font))).all)'Access;
   end Add_Text;

   ----------------------
   -- Background_Brush --
   ----------------------

   function Background_Brush
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Brushes.Q_Brush
   is
      Returns : Qt4.Brushes.Q_Brush;

   begin
      backgroundBrush_0_wrapper
       (Self.QObject_View,
        Qt4.Brushes.Internals.QBrush_View (Returns));

      return Returns;
   end Background_Brush;

   -----------------
   -- Clear_Focus --
   -----------------

   procedure Clear_Focus
    (Self : not null access Q_Graphics_Scene'Class)
   is
   begin
      clearFocus_0_wrapper
       (Self.QObject_View);
   end Clear_Focus;

   ---------------------
   -- Clear_Selection --
   ---------------------

   procedure Clear_Selection
    (Self : not null access Q_Graphics_Scene'Class)
   is
   begin
      clearSelection_0_wrapper
       (Self.QObject_View);
   end Clear_Selection;

   ----------------
   -- Focus_Item --
   ----------------

   function Focus_Item
    (Self : not null access constant Q_Graphics_Scene'Class)
       return not null access Qt4.Graphics_Items.Q_Graphics_Item'Class
   is
   begin
      return
        Qt4.Graphics_Items.Q_Graphics_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (focusItem_0_wrapper
             (Self.QObject_View)).all)'Access;
   end Focus_Item;

   ----------------------
   -- Foreground_Brush --
   ----------------------

   function Foreground_Brush
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Brushes.Q_Brush
   is
      Returns : Qt4.Brushes.Q_Brush;

   begin
      foregroundBrush_0_wrapper
       (Self.QObject_View,
        Qt4.Brushes.Internals.QBrush_View (Returns));

      return Returns;
   end Foreground_Brush;

   ---------------
   -- Has_Focus --
   ---------------

   function Has_Focus
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Standard.Boolean
   is
   begin
      return
        Qt4.To_Boolean
         (hasFocus_0_wrapper
           (Self.QObject_View));
   end Has_Focus;

   ------------
   -- Height --
   ------------

   function Height
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Q_Real
   is
   begin
      return
        height_0_wrapper
         (Self.QObject_View);
   end Height;

   -------------
   -- Item_At --
   -------------

   function Item_At
    (Self : not null access constant Q_Graphics_Scene'Class;
     Pos : Qt4.Point_Fs.Q_Point_F)
       return not null access Qt4.Graphics_Items.Q_Graphics_Item'Class
   is
   begin
      return
        Qt4.Graphics_Items.Q_Graphics_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (itemAt_1_wrapper
             (Self.QObject_View,
              Qt4.Point_Fs.Internals.QPointF_View (Pos))).all)'Access;
   end Item_At;

   -------------
   -- Item_At --
   -------------

   function Item_At
    (Self : not null access constant Q_Graphics_Scene'Class;
     X : Qt4.Q_Real;
     Y : Qt4.Q_Real)
       return not null access Qt4.Graphics_Items.Q_Graphics_Item'Class
   is
   begin
      return
        Qt4.Graphics_Items.Q_Graphics_Item'Class
         (Qt_Ada.Internals.Graphics_Item_Registry.To_Q_Graphics_Item
           (itemAt_0_wrapper
             (Self.QObject_View,
              X,
              Y)).all)'Access;
   end Item_At;

   -----------------------
   -- Item_Index_Method --
   -----------------------

   function Item_Index_Method
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Graphics_Scenes.Graphics_Scene_Item_Index_Method
   is
   begin
      return
        itemIndexMethod_0_wrapper
         (Self.QObject_View);
   end Item_Index_Method;

   -------------------------
   -- Items_Bounding_Rect --
   -------------------------

   function Items_Bounding_Rect
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Rect_Fs.Q_Rect_F
   is
      Returns : Qt4.Rect_Fs.Q_Rect_F;

   begin
      itemsBoundingRect_0_wrapper
       (Self.QObject_View,
        Qt4.Rect_Fs.Internals.QRectF_View (Returns));

      return Returns;
   end Items_Bounding_Rect;

   ------------------------
   -- Mouse_Grabber_Item --
   ------------------------

   function Mouse_Grabber_Item
    (Self : not null access constant Q_Graphics_Scene'Class)
       return access Qt4.Graphics_Items.Q_Graphics_Item'Class
   is
   begin
      return
        Qt_Ada.Internals.Graphics_Items.Graphics_Item_Utilities.Corresponding_Q_Graphics_Item
         (mouseGrabberItem_0_wrapper
           (Self.QObject_View));
   end Mouse_Grabber_Item;

   -----------------
   -- Remove_Item --
   -----------------

   procedure Remove_Item
    (Self : not null access Q_Graphics_Scene'Class;
     Item : not null access Qt4.Graphics_Items.Q_Graphics_Item'Class)
   is
   begin
      removeItem_0_wrapper
       (Self.QObject_View,
        Item.QGraphicsItem_View);
   end Remove_Item;

   ----------------
   -- Scene_Rect --
   ----------------

   function Scene_Rect
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Rect_Fs.Q_Rect_F
   is
      Returns : Qt4.Rect_Fs.Q_Rect_F;

   begin
      sceneRect_0_wrapper
       (Self.QObject_View,
        Qt4.Rect_Fs.Internals.QRectF_View (Returns));

      return Returns;
   end Scene_Rect;

   --------------------------
   -- Set_Background_Brush --
   --------------------------

   procedure Set_Background_Brush
    (Self : not null access Q_Graphics_Scene'Class;
     Brush : Qt4.Brushes.Q_Brush)
   is
   begin
      setBackgroundBrush_0_wrapper
       (Self.QObject_View,
        Qt4.Brushes.Internals.QBrush_View (Brush));
   end Set_Background_Brush;

   --------------------------
   -- Set_Foreground_Brush --
   --------------------------

   procedure Set_Foreground_Brush
    (Self : not null access Q_Graphics_Scene'Class;
     Brush : Qt4.Brushes.Q_Brush)
   is
   begin
      setForegroundBrush_0_wrapper
       (Self.QObject_View,
        Qt4.Brushes.Internals.QBrush_View (Brush));
   end Set_Foreground_Brush;

   ---------------------------
   -- Set_Item_Index_Method --
   ---------------------------

   procedure Set_Item_Index_Method
    (Self : not null access Q_Graphics_Scene'Class;
     Method : Qt4.Graphics_Scenes.Graphics_Scene_Item_Index_Method)
   is
   begin
      setItemIndexMethod_0_wrapper
       (Self.QObject_View,
        Method);
   end Set_Item_Index_Method;

   --------------------
   -- Set_Scene_Rect --
   --------------------

   procedure Set_Scene_Rect
    (Self : not null access Q_Graphics_Scene'Class;
     Rect : Qt4.Rect_Fs.Q_Rect_F)
   is
   begin
      setSceneRect_1_wrapper
       (Self.QObject_View,
        Qt4.Rect_Fs.Internals.QRectF_View (Rect));
   end Set_Scene_Rect;

   --------------------
   -- Set_Scene_Rect --
   --------------------

   procedure Set_Scene_Rect
    (Self : not null access Q_Graphics_Scene'Class;
     X : Qt4.Q_Real;
     Y : Qt4.Q_Real;
     W : Qt4.Q_Real;
     H : Qt4.Q_Real)
   is
   begin
      setSceneRect_0_wrapper
       (Self.QObject_View,
        X,
        Y,
        W,
        H);
   end Set_Scene_Rect;

   ------------------------
   -- Set_Selection_Area --
   ------------------------

   procedure Set_Selection_Area
    (Self : not null access Q_Graphics_Scene'Class;
     Path : Qt4.Painter_Paths.Q_Painter_Path)
   is
   begin
      setSelectionArea_0_wrapper
       (Self.QObject_View,
        Qt4.Painter_Paths.Internals.QPainterPath_View (Path));
   end Set_Selection_Area;

   -----------
   -- Width --
   -----------

   function Width
    (Self : not null access constant Q_Graphics_Scene'Class)
       return Qt4.Q_Real
   is
   begin
      return
        width_0_wrapper
         (Self.QObject_View);
   end Width;

   -------------
   -- Advance --
   -------------

   procedure Advance
    (Self : not null access Q_Graphics_Scene'Class)
   is
   begin
      advance_0_wrapper
       (Self.QObject_View);
   end Advance;

   ------------
   -- Update --
   ------------

   procedure Update
    (Self : not null access Q_Graphics_Scene'Class;
     Rect : Qt4.Rect_Fs.Q_Rect_F
       := Qt4.Rect_Fs.Create)
   is
   begin
      update_0_wrapper
       (Self.QObject_View,
        Qt4.Rect_Fs.Internals.QRectF_View (Rect));
   end Update;

end Qt4.Graphics_Scenes;
