with GNATCOM.IInterface;

with GNATCOM.Errors;

package body MSHTML.IHTMLStyle5_Interface is

   procedure Initialize (This : in out IHTMLStyle5_Type) is
   begin
      Set_IID (This, IID_IHTMLStyle5);
   end Initialize;

   function Pointer (This : IHTMLStyle5_Type)
     return Pointer_To_IHTMLStyle5
   is
   begin
      return To_Pointer_To_IHTMLStyle5 (Address (This));
   end Pointer;

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

   procedure Put_msInterpolationMode
     (This : IHTMLStyle5_Type;
      p    : GNATCOM.Types.BSTR;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_msInterpolationMode
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_msInterpolationMode;

   function Get_msInterpolationMode
     (This : IHTMLStyle5_Type)
     return GNATCOM.Types.BSTR
   is
       RetVal : aliased GNATCOM.Types.BSTR;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_msInterpolationMode
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_msInterpolationMode;

   procedure Put_maxHeight
     (This : IHTMLStyle5_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_maxHeight
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_maxHeight;

   function Get_maxHeight
     (This : IHTMLStyle5_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_maxHeight
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_maxHeight;

   procedure Put_minWidth
     (This : IHTMLStyle5_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_minWidth
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_minWidth;

   function Get_minWidth
     (This : IHTMLStyle5_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_minWidth
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_minWidth;

   procedure Put_maxWidth
     (This : IHTMLStyle5_Type;
      p    : GNATCOM.Types.VARIANT;
      Free : Boolean := True)
   is
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Put_maxWidth
         (Pointer (This),
          p));

      if Free then
               GNATCOM.IInterface.Free (p);
      
      end if;

   end Put_maxWidth;

   function Get_maxWidth
     (This : IHTMLStyle5_Type)
     return GNATCOM.Types.VARIANT
   is
       RetVal : aliased GNATCOM.Types.VARIANT;
   begin
      GNATCOM.Errors.Error_Check
        (Pointer (This).Vtbl.Get_maxWidth
         (Pointer (This),
          RetVal'Unchecked_Access));

      return RetVal;
   end Get_maxWidth;

end MSHTML.IHTMLStyle5_Interface;

