{-# LANGUAGE ForeignFunctionInterface, TypeFamilies, MultiParamTypeClasses, 
             FlexibleInstances, TypeSynonymInstances, EmptyDataDecls, 
             OverlappingInstances, IncoherentInstances #-}

module HROOT.Class.TGroupButton.Implementation where


import HROOT.TypeCast

import HROOT.Class.TGroupButton.RawType
import HROOT.Class.TGroupButton.FFI
import HROOT.Class.TGroupButton.Interface
import HROOT.Class.TGroupButton.Cast
import HROOT.Class.TFrame.RawType
import HROOT.Class.TFrame.Cast
import HROOT.Class.TFrame.Interface
import HROOT.Class.TClass.RawType
import HROOT.Class.TClass.Cast
import HROOT.Class.TClass.Interface
import HROOT.Class.TButton.RawType
import HROOT.Class.TButton.Cast
import HROOT.Class.TButton.Interface
import HROOT.Class.TPad.RawType
import HROOT.Class.TPad.Cast
import HROOT.Class.TPad.Interface
import HROOT.Class.TAttText.RawType
import HROOT.Class.TAttText.Cast
import HROOT.Class.TAttText.Interface
import HROOT.Class.TVirtualPad.RawType
import HROOT.Class.TVirtualPad.Cast
import HROOT.Class.TVirtualPad.Interface
import HROOT.Class.TObject.RawType
import HROOT.Class.TObject.Cast
import HROOT.Class.TObject.Interface
import HROOT.Class.TAttLine.RawType
import HROOT.Class.TAttLine.Cast
import HROOT.Class.TAttLine.Interface
import HROOT.Class.TAttFill.RawType
import HROOT.Class.TAttFill.Cast
import HROOT.Class.TAttFill.Interface
import HROOT.Class.TAttPad.RawType
import HROOT.Class.TAttPad.Cast
import HROOT.Class.TAttPad.Interface
import HROOT.Class.TQObject.RawType
import HROOT.Class.TQObject.Cast
import HROOT.Class.TQObject.Interface
import HROOT.Class.Deletable.RawType
import HROOT.Class.Deletable.Cast
import HROOT.Class.Deletable.Interface

import Data.Word
-- import Foreign.C            
-- import Foreign.Ptr
import Foreign.ForeignPtr

import System.IO.Unsafe


instance ITGroupButton TGroupButton where
instance ITButton TGroupButton where
instance ITPad TGroupButton where
instance ITAttText TGroupButton where
  getTextAlign = xform0 c_tgroupbutton_gettextalign
  getTextAngle = xform0 c_tgroupbutton_gettextangle
  getTextColor = xform0 c_tgroupbutton_gettextcolor
  getTextFont = xform0 c_tgroupbutton_gettextfont
  getTextSize = xform0 c_tgroupbutton_gettextsize
  resetAttText = xform1 c_tgroupbutton_resetatttext
  setTextAttributes = xform0 c_tgroupbutton_settextattributes
  setTextAlign = xform1 c_tgroupbutton_settextalign
  setTextAngle = xform1 c_tgroupbutton_settextangle
  setTextColor = xform1 c_tgroupbutton_settextcolor
  setTextFont = xform1 c_tgroupbutton_settextfont
  setTextSize = xform1 c_tgroupbutton_settextsize
  setTextSizePixels = xform1 c_tgroupbutton_settextsizepixels
instance ITVirtualPad TGroupButton where
  cd = xform1 c_tgroupbutton_cd
  getFrame = xform0 c_tgroupbutton_getframe
  modified = xform1 c_tgroupbutton_modified
  range = xform4 c_tgroupbutton_range
instance ITObject TGroupButton where
  draw = xform1 c_tgroupbutton_draw
  findObject = xform1 c_tgroupbutton_findobject
  getName = xform0 c_tgroupbutton_getname
  isA = xform0 c_tgroupbutton_isa
  isFolder = xform0 c_tgroupbutton_isfolder
  isEqual = xform1 c_tgroupbutton_isequal
  isSortable = xform0 c_tgroupbutton_issortable
  paint = xform1 c_tgroupbutton_paint
  printObj = xform1 c_tgroupbutton_printobj
  recursiveRemove = xform1 c_tgroupbutton_recursiveremove
  saveAs = xform2 c_tgroupbutton_saveas
  useCurrentStyle = xform0 c_tgroupbutton_usecurrentstyle
  write = xform3 c_tgroupbutton_write
instance ITAttLine TGroupButton where
  getLineColor = xform0 c_tgroupbutton_getlinecolor
  getLineStyle = xform0 c_tgroupbutton_getlinestyle
  getLineWidth = xform0 c_tgroupbutton_getlinewidth
  resetAttLine = xform1 c_tgroupbutton_resetattline
  setLineAttributes = xform0 c_tgroupbutton_setlineattributes
  setLineColor = xform1 c_tgroupbutton_setlinecolor
  setLineStyle = xform1 c_tgroupbutton_setlinestyle
  setLineWidth = xform1 c_tgroupbutton_setlinewidth
instance ITAttFill TGroupButton where
  setFillColor = xform1 c_tgroupbutton_setfillcolor
  setFillStyle = xform1 c_tgroupbutton_setfillstyle
instance ITAttPad TGroupButton where
  resetAttPad = xform1 c_tgroupbutton_resetattpad
  setBottomMargin = xform1 c_tgroupbutton_setbottommargin
  setLeftMargin = xform1 c_tgroupbutton_setleftmargin
  setRightMargin = xform1 c_tgroupbutton_setrightmargin
  setTopMargin = xform1 c_tgroupbutton_settopmargin
  setMargin = xform4 c_tgroupbutton_setmargin
  setAfile = xform1 c_tgroupbutton_setafile
  setXfile = xform1 c_tgroupbutton_setxfile
  setYfile = xform1 c_tgroupbutton_setyfile
  setAstat = xform1 c_tgroupbutton_setastat
  setXstat = xform1 c_tgroupbutton_setxstat
  setYstat = xform1 c_tgroupbutton_setystat
instance ITQObject TGroupButton where
instance IDeletable TGroupButton where
  delete = xform0 c_tgroupbutton_delete

instance ITGroupButton (Exist TGroupButton) where

instance ITButton (Exist TGroupButton) where

instance ITPad (Exist TGroupButton) where

instance ITAttText (Exist TGroupButton) where
  getTextAlign (ETGroupButton x) = getTextAlign x
  getTextAngle (ETGroupButton x) = getTextAngle x
  getTextColor (ETGroupButton x) = getTextColor x
  getTextFont (ETGroupButton x) = getTextFont x
  getTextSize (ETGroupButton x) = getTextSize x
  resetAttText (ETGroupButton x) = resetAttText x
  setTextAttributes (ETGroupButton x) = setTextAttributes x
  setTextAlign (ETGroupButton x) = setTextAlign x
  setTextAngle (ETGroupButton x) = setTextAngle x
  setTextColor (ETGroupButton x) = setTextColor x
  setTextFont (ETGroupButton x) = setTextFont x
  setTextSize (ETGroupButton x) = setTextSize x
  setTextSizePixels (ETGroupButton x) = setTextSizePixels x
instance ITVirtualPad (Exist TGroupButton) where
  cd (ETGroupButton x) = cd x
  getFrame (ETGroupButton x) = getFrame x
  modified (ETGroupButton x) = modified x
  range (ETGroupButton x) = range x
instance ITObject (Exist TGroupButton) where
  draw (ETGroupButton x) = draw x
  findObject (ETGroupButton x) = findObject x
  getName (ETGroupButton x) = getName x
  isA (ETGroupButton x) = isA x
  isFolder (ETGroupButton x) = isFolder x
  isEqual (ETGroupButton x) = isEqual x
  isSortable (ETGroupButton x) = isSortable x
  paint (ETGroupButton x) = paint x
  printObj (ETGroupButton x) = printObj x
  recursiveRemove (ETGroupButton x) = recursiveRemove x
  saveAs (ETGroupButton x) = saveAs x
  useCurrentStyle (ETGroupButton x) = useCurrentStyle x
  write (ETGroupButton x) = write x
instance ITAttLine (Exist TGroupButton) where
  getLineColor (ETGroupButton x) = getLineColor x
  getLineStyle (ETGroupButton x) = getLineStyle x
  getLineWidth (ETGroupButton x) = getLineWidth x
  resetAttLine (ETGroupButton x) = resetAttLine x
  setLineAttributes (ETGroupButton x) = setLineAttributes x
  setLineColor (ETGroupButton x) = setLineColor x
  setLineStyle (ETGroupButton x) = setLineStyle x
  setLineWidth (ETGroupButton x) = setLineWidth x
instance ITAttFill (Exist TGroupButton) where
  setFillColor (ETGroupButton x) = setFillColor x
  setFillStyle (ETGroupButton x) = setFillStyle x
instance ITAttPad (Exist TGroupButton) where
  resetAttPad (ETGroupButton x) = resetAttPad x
  setBottomMargin (ETGroupButton x) = setBottomMargin x
  setLeftMargin (ETGroupButton x) = setLeftMargin x
  setRightMargin (ETGroupButton x) = setRightMargin x
  setTopMargin (ETGroupButton x) = setTopMargin x
  setMargin (ETGroupButton x) = setMargin x
  setAfile (ETGroupButton x) = setAfile x
  setXfile (ETGroupButton x) = setXfile x
  setYfile (ETGroupButton x) = setYfile x
  setAstat (ETGroupButton x) = setAstat x
  setXstat (ETGroupButton x) = setXstat x
  setYstat (ETGroupButton x) = setYstat x
instance ITQObject (Exist TGroupButton) where

instance IDeletable (Exist TGroupButton) where
  delete (ETGroupButton x) = delete x





instance FPtr (Exist TGroupButton) where
  type Raw (Exist TGroupButton) = RawTGroupButton
  get_fptr (ETGroupButton obj) = castForeignPtr (get_fptr obj)
  cast_fptr_to_obj fptr = ETGroupButton (cast_fptr_to_obj (fptr :: ForeignPtr RawTGroupButton) :: TGroupButton)