with GNATCOM.IInterface;

with GNATCOM.Errors;

package body MSHTML.IHTMLRect2_Interface is

   procedure Initialize (This : in out IHTMLRect2_Type) is
   begin
      Set_IID (This, IID_IHTMLRect2);
   end Initialize;

   function Pointer (This : IHTMLRect2_Type)
     return Pointer_To_IHTMLRect2
   is
   begin
      return To_Pointer_To_IHTMLRect2 (Address (This));
   end Pointer;

   procedure Attach (This    : in out IHTMLRect2_Type;
                     Pointer : in     Pointer_To_IHTMLRect2)
   is
   begin
      Attach (This, GNATCOM.IInterface.To_Pointer_To_IUnknown
              (Pointer.all'Address));
   end Attach;

   function Get_width
     (This : IHTMLRect2_Type)
     return Interfaces.C.C_float
   is
       RetVal : aliased Interfaces.C.C_float;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_width
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_width;

   function Get_height
     (This : IHTMLRect2_Type)
     return Interfaces.C.C_float
   is
       RetVal : aliased Interfaces.C.C_float;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_height
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_height;

end MSHTML.IHTMLRect2_Interface;

