{-# LANGUAGE TypeApplications #-}
#if (MIN_VERSION_haskell_gi_overloading(1,0,0) && !defined(__HADDOCK_VERSION__))
#define ENABLE_OVERLOADING
#endif
module GI.Gtk.Objects.ScaleAccessible
(
ScaleAccessible(..) ,
IsScaleAccessible ,
toScaleAccessible ,
#if defined(ENABLE_OVERLOADING)
ResolveScaleAccessibleMethod ,
#endif
) where
import Data.GI.Base.ShortPrelude
import qualified Data.GI.Base.ShortPrelude as SP
import qualified Data.GI.Base.Overloading as O
import qualified Prelude as P
import qualified Data.GI.Base.Attributes as GI.Attributes
import qualified Data.GI.Base.BasicTypes as B.Types
import qualified Data.GI.Base.ManagedPtr as B.ManagedPtr
import qualified Data.GI.Base.GArray as B.GArray
import qualified Data.GI.Base.GClosure as B.GClosure
import qualified Data.GI.Base.GError as B.GError
import qualified Data.GI.Base.GHashTable as B.GHT
import qualified Data.GI.Base.GVariant as B.GVariant
import qualified Data.GI.Base.GValue as B.GValue
import qualified Data.GI.Base.GParamSpec as B.GParamSpec
import qualified Data.GI.Base.CallStack as B.CallStack
import qualified Data.GI.Base.Properties as B.Properties
import qualified Data.GI.Base.Signals as B.Signals
import qualified Control.Monad.IO.Class as MIO
import qualified Data.Coerce as Coerce
import qualified Data.Text as T
import qualified Data.Kind as DK
import qualified Data.ByteString.Char8 as B
import qualified Data.Map as Map
import qualified Foreign.Ptr as FP
import qualified GHC.OverloadedLabels as OL
import qualified GHC.Records as R
import qualified GI.Atk.Interfaces.Component as Atk.Component
import qualified GI.Atk.Interfaces.Value as Atk.Value
import qualified GI.Atk.Objects.Object as Atk.Object
import qualified GI.GObject.Objects.Object as GObject.Object
import {-# SOURCE #-} qualified GI.Gtk.Objects.Accessible as Gtk.Accessible
import {-# SOURCE #-} qualified GI.Gtk.Objects.RangeAccessible as Gtk.RangeAccessible
import {-# SOURCE #-} qualified GI.Gtk.Objects.WidgetAccessible as Gtk.WidgetAccessible
newtype ScaleAccessible = ScaleAccessible (SP.ManagedPtr ScaleAccessible)
deriving (ScaleAccessible -> ScaleAccessible -> Bool
(ScaleAccessible -> ScaleAccessible -> Bool)
-> (ScaleAccessible -> ScaleAccessible -> Bool)
-> Eq ScaleAccessible
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ScaleAccessible -> ScaleAccessible -> Bool
== :: ScaleAccessible -> ScaleAccessible -> Bool
$c/= :: ScaleAccessible -> ScaleAccessible -> Bool
/= :: ScaleAccessible -> ScaleAccessible -> Bool
Eq)
instance SP.ManagedPtrNewtype ScaleAccessible where
toManagedPtr :: ScaleAccessible -> ManagedPtr ScaleAccessible
toManagedPtr (ScaleAccessible ManagedPtr ScaleAccessible
p) = ManagedPtr ScaleAccessible
p
foreign import ccall "gtk_scale_accessible_get_type"
c_gtk_scale_accessible_get_type :: IO B.Types.GType
instance B.Types.TypedObject ScaleAccessible where
glibType :: IO GType
glibType = IO GType
c_gtk_scale_accessible_get_type
instance B.Types.GObject ScaleAccessible
class (SP.GObject o, O.IsDescendantOf ScaleAccessible o) => IsScaleAccessible o
instance (SP.GObject o, O.IsDescendantOf ScaleAccessible o) => IsScaleAccessible o
instance O.HasParentTypes ScaleAccessible
type instance O.ParentTypes ScaleAccessible = '[Gtk.RangeAccessible.RangeAccessible, Gtk.WidgetAccessible.WidgetAccessible, Gtk.Accessible.Accessible, Atk.Object.Object, GObject.Object.Object, Atk.Component.Component, Atk.Value.Value]
toScaleAccessible :: (MIO.MonadIO m, IsScaleAccessible o) => o -> m ScaleAccessible
toScaleAccessible :: forall (m :: * -> *) o.
(MonadIO m, IsScaleAccessible o) =>
o -> m ScaleAccessible
toScaleAccessible = IO ScaleAccessible -> m ScaleAccessible
forall a. IO a -> m a
forall (m :: * -> *) a. MonadIO m => IO a -> m a
MIO.liftIO (IO ScaleAccessible -> m ScaleAccessible)
-> (o -> IO ScaleAccessible) -> o -> m ScaleAccessible
forall b c a. (b -> c) -> (a -> b) -> a -> c
. (ManagedPtr ScaleAccessible -> ScaleAccessible)
-> o -> IO ScaleAccessible
forall o o'.
(HasCallStack, ManagedPtrNewtype o, TypedObject o,
ManagedPtrNewtype o', TypedObject o') =>
(ManagedPtr o' -> o') -> o -> IO o'
B.ManagedPtr.unsafeCastTo ManagedPtr ScaleAccessible -> ScaleAccessible
ScaleAccessible
instance B.GValue.IsGValue (Maybe ScaleAccessible) where
gvalueGType_ :: IO GType
gvalueGType_ = IO GType
c_gtk_scale_accessible_get_type
gvalueSet_ :: Ptr GValue -> Maybe ScaleAccessible -> IO ()
gvalueSet_ Ptr GValue
gv Maybe ScaleAccessible
P.Nothing = Ptr GValue -> Ptr ScaleAccessible -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv (Ptr ScaleAccessible
forall a. Ptr a
FP.nullPtr :: FP.Ptr ScaleAccessible)
gvalueSet_ Ptr GValue
gv (P.Just ScaleAccessible
obj) = ScaleAccessible -> (Ptr ScaleAccessible -> IO ()) -> IO ()
forall a c.
(HasCallStack, ManagedPtrNewtype a) =>
a -> (Ptr a -> IO c) -> IO c
B.ManagedPtr.withManagedPtr ScaleAccessible
obj (Ptr GValue -> Ptr ScaleAccessible -> IO ()
forall a. GObject a => Ptr GValue -> Ptr a -> IO ()
B.GValue.set_object Ptr GValue
gv)
gvalueGet_ :: Ptr GValue -> IO (Maybe ScaleAccessible)
gvalueGet_ Ptr GValue
gv = do
Ptr ScaleAccessible
ptr <- Ptr GValue -> IO (Ptr ScaleAccessible)
forall a. GObject a => Ptr GValue -> IO (Ptr a)
B.GValue.get_object Ptr GValue
gv :: IO (FP.Ptr ScaleAccessible)
if Ptr ScaleAccessible
ptr Ptr ScaleAccessible -> Ptr ScaleAccessible -> Bool
forall a. Eq a => a -> a -> Bool
/= Ptr ScaleAccessible
forall a. Ptr a
FP.nullPtr
then ScaleAccessible -> Maybe ScaleAccessible
forall a. a -> Maybe a
P.Just (ScaleAccessible -> Maybe ScaleAccessible)
-> IO ScaleAccessible -> IO (Maybe ScaleAccessible)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
<$> (ManagedPtr ScaleAccessible -> ScaleAccessible)
-> Ptr ScaleAccessible -> IO ScaleAccessible
forall a b.
(HasCallStack, GObject a, GObject b) =>
(ManagedPtr a -> a) -> Ptr b -> IO a
B.ManagedPtr.newObject ManagedPtr ScaleAccessible -> ScaleAccessible
ScaleAccessible Ptr ScaleAccessible
ptr
else Maybe ScaleAccessible -> IO (Maybe ScaleAccessible)
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Maybe ScaleAccessible
forall a. Maybe a
P.Nothing
#if defined(ENABLE_OVERLOADING)
type family ResolveScaleAccessibleMethod (t :: Symbol) (o :: DK.Type) :: DK.Type where
ResolveScaleAccessibleMethod "addRelationship" o = Atk.Object.ObjectAddRelationshipMethodInfo
ResolveScaleAccessibleMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo
ResolveScaleAccessibleMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo
ResolveScaleAccessibleMethod "connectWidgetDestroyed" o = Gtk.Accessible.AccessibleConnectWidgetDestroyedMethodInfo
ResolveScaleAccessibleMethod "contains" o = Atk.Component.ComponentContainsMethodInfo
ResolveScaleAccessibleMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo
ResolveScaleAccessibleMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo
ResolveScaleAccessibleMethod "getv" o = GObject.Object.ObjectGetvMethodInfo
ResolveScaleAccessibleMethod "grabFocus" o = Atk.Component.ComponentGrabFocusMethodInfo
ResolveScaleAccessibleMethod "initialize" o = Atk.Object.ObjectInitializeMethodInfo
ResolveScaleAccessibleMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo
ResolveScaleAccessibleMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo
ResolveScaleAccessibleMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo
ResolveScaleAccessibleMethod "notifyStateChange" o = Atk.Object.ObjectNotifyStateChangeMethodInfo
ResolveScaleAccessibleMethod "peekParent" o = Atk.Object.ObjectPeekParentMethodInfo
ResolveScaleAccessibleMethod "ref" o = GObject.Object.ObjectRefMethodInfo
ResolveScaleAccessibleMethod "refAccessibleAtPoint" o = Atk.Component.ComponentRefAccessibleAtPointMethodInfo
ResolveScaleAccessibleMethod "refAccessibleChild" o = Atk.Object.ObjectRefAccessibleChildMethodInfo
ResolveScaleAccessibleMethod "refRelationSet" o = Atk.Object.ObjectRefRelationSetMethodInfo
ResolveScaleAccessibleMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo
ResolveScaleAccessibleMethod "refStateSet" o = Atk.Object.ObjectRefStateSetMethodInfo
ResolveScaleAccessibleMethod "removeFocusHandler" o = Atk.Component.ComponentRemoveFocusHandlerMethodInfo
ResolveScaleAccessibleMethod "removePropertyChangeHandler" o = Atk.Object.ObjectRemovePropertyChangeHandlerMethodInfo
ResolveScaleAccessibleMethod "removeRelationship" o = Atk.Object.ObjectRemoveRelationshipMethodInfo
ResolveScaleAccessibleMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo
ResolveScaleAccessibleMethod "scrollTo" o = Atk.Component.ComponentScrollToMethodInfo
ResolveScaleAccessibleMethod "scrollToPoint" o = Atk.Component.ComponentScrollToPointMethodInfo
ResolveScaleAccessibleMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo
ResolveScaleAccessibleMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo
ResolveScaleAccessibleMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo
ResolveScaleAccessibleMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo
ResolveScaleAccessibleMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo
ResolveScaleAccessibleMethod "getAccessibleId" o = Atk.Object.ObjectGetAccessibleIdMethodInfo
ResolveScaleAccessibleMethod "getAlpha" o = Atk.Component.ComponentGetAlphaMethodInfo
ResolveScaleAccessibleMethod "getAttributes" o = Atk.Object.ObjectGetAttributesMethodInfo
ResolveScaleAccessibleMethod "getCurrentValue" o = Atk.Value.ValueGetCurrentValueMethodInfo
ResolveScaleAccessibleMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo
ResolveScaleAccessibleMethod "getDescription" o = Atk.Object.ObjectGetDescriptionMethodInfo
ResolveScaleAccessibleMethod "getExtents" o = Atk.Component.ComponentGetExtentsMethodInfo
ResolveScaleAccessibleMethod "getIncrement" o = Atk.Value.ValueGetIncrementMethodInfo
ResolveScaleAccessibleMethod "getIndexInParent" o = Atk.Object.ObjectGetIndexInParentMethodInfo
ResolveScaleAccessibleMethod "getLayer" o = Atk.Object.ObjectGetLayerMethodInfo
ResolveScaleAccessibleMethod "getMaximumValue" o = Atk.Value.ValueGetMaximumValueMethodInfo
ResolveScaleAccessibleMethod "getMdiZorder" o = Atk.Object.ObjectGetMdiZorderMethodInfo
ResolveScaleAccessibleMethod "getMinimumIncrement" o = Atk.Value.ValueGetMinimumIncrementMethodInfo
ResolveScaleAccessibleMethod "getMinimumValue" o = Atk.Value.ValueGetMinimumValueMethodInfo
ResolveScaleAccessibleMethod "getNAccessibleChildren" o = Atk.Object.ObjectGetNAccessibleChildrenMethodInfo
ResolveScaleAccessibleMethod "getName" o = Atk.Object.ObjectGetNameMethodInfo
ResolveScaleAccessibleMethod "getObjectLocale" o = Atk.Object.ObjectGetObjectLocaleMethodInfo
ResolveScaleAccessibleMethod "getParent" o = Atk.Object.ObjectGetParentMethodInfo
ResolveScaleAccessibleMethod "getPosition" o = Atk.Component.ComponentGetPositionMethodInfo
ResolveScaleAccessibleMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo
ResolveScaleAccessibleMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo
ResolveScaleAccessibleMethod "getRange" o = Atk.Value.ValueGetRangeMethodInfo
ResolveScaleAccessibleMethod "getRole" o = Atk.Object.ObjectGetRoleMethodInfo
ResolveScaleAccessibleMethod "getSize" o = Atk.Component.ComponentGetSizeMethodInfo
ResolveScaleAccessibleMethod "getSubRanges" o = Atk.Value.ValueGetSubRangesMethodInfo
ResolveScaleAccessibleMethod "getValueAndText" o = Atk.Value.ValueGetValueAndTextMethodInfo
ResolveScaleAccessibleMethod "getWidget" o = Gtk.Accessible.AccessibleGetWidgetMethodInfo
ResolveScaleAccessibleMethod "setAccessibleId" o = Atk.Object.ObjectSetAccessibleIdMethodInfo
ResolveScaleAccessibleMethod "setCurrentValue" o = Atk.Value.ValueSetCurrentValueMethodInfo
ResolveScaleAccessibleMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo
ResolveScaleAccessibleMethod "setDataFull" o = GObject.Object.ObjectSetDataFullMethodInfo
ResolveScaleAccessibleMethod "setDescription" o = Atk.Object.ObjectSetDescriptionMethodInfo
ResolveScaleAccessibleMethod "setExtents" o = Atk.Component.ComponentSetExtentsMethodInfo
ResolveScaleAccessibleMethod "setName" o = Atk.Object.ObjectSetNameMethodInfo
ResolveScaleAccessibleMethod "setParent" o = Atk.Object.ObjectSetParentMethodInfo
ResolveScaleAccessibleMethod "setPosition" o = Atk.Component.ComponentSetPositionMethodInfo
ResolveScaleAccessibleMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo
ResolveScaleAccessibleMethod "setRole" o = Atk.Object.ObjectSetRoleMethodInfo
ResolveScaleAccessibleMethod "setSize" o = Atk.Component.ComponentSetSizeMethodInfo
ResolveScaleAccessibleMethod "setValue" o = Atk.Value.ValueSetValueMethodInfo
ResolveScaleAccessibleMethod "setWidget" o = Gtk.Accessible.AccessibleSetWidgetMethodInfo
ResolveScaleAccessibleMethod l o = O.MethodResolutionFailed l o
instance (info ~ ResolveScaleAccessibleMethod t ScaleAccessible, O.OverloadedMethod info ScaleAccessible p) => OL.IsLabel t (ScaleAccessible -> p) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.overloadedMethod @info
#else
fromLabel _ = O.overloadedMethod @info
#endif
#if MIN_VERSION_base(4,13,0)
instance (info ~ ResolveScaleAccessibleMethod t ScaleAccessible, O.OverloadedMethod info ScaleAccessible p, R.HasField t ScaleAccessible p) => R.HasField t ScaleAccessible p where
getField = O.overloadedMethod @info
#endif
instance (info ~ ResolveScaleAccessibleMethod t ScaleAccessible, O.OverloadedMethodInfo info ScaleAccessible) => OL.IsLabel t (O.MethodProxy info ScaleAccessible) where
#if MIN_VERSION_base(4,10,0)
fromLabel = O.MethodProxy
#else
fromLabel _ = O.MethodProxy
#endif
#endif
#if defined(ENABLE_OVERLOADING)
instance O.HasAttributeList ScaleAccessible
type instance O.AttributeList ScaleAccessible = ScaleAccessibleAttributeList
type ScaleAccessibleAttributeList = ('[ '("accessibleComponentLayer", Atk.Object.ObjectAccessibleComponentLayerPropertyInfo), '("accessibleComponentMdiZorder", Atk.Object.ObjectAccessibleComponentMdiZorderPropertyInfo), '("accessibleDescription", Atk.Object.ObjectAccessibleDescriptionPropertyInfo), '("accessibleHypertextNlinks", Atk.Object.ObjectAccessibleHypertextNlinksPropertyInfo), '("accessibleName", Atk.Object.ObjectAccessibleNamePropertyInfo), '("accessibleParent", Atk.Object.ObjectAccessibleParentPropertyInfo), '("accessibleRole", Atk.Object.ObjectAccessibleRolePropertyInfo), '("accessibleTableCaption", Atk.Object.ObjectAccessibleTableCaptionPropertyInfo), '("accessibleTableCaptionObject", Atk.Object.ObjectAccessibleTableCaptionObjectPropertyInfo), '("accessibleTableColumnDescription", Atk.Object.ObjectAccessibleTableColumnDescriptionPropertyInfo), '("accessibleTableColumnHeader", Atk.Object.ObjectAccessibleTableColumnHeaderPropertyInfo), '("accessibleTableRowDescription", Atk.Object.ObjectAccessibleTableRowDescriptionPropertyInfo), '("accessibleTableRowHeader", Atk.Object.ObjectAccessibleTableRowHeaderPropertyInfo), '("accessibleTableSummary", Atk.Object.ObjectAccessibleTableSummaryPropertyInfo), '("accessibleValue", Atk.Object.ObjectAccessibleValuePropertyInfo), '("widget", Gtk.Accessible.AccessibleWidgetPropertyInfo)] :: [(Symbol, DK.Type)])
#endif
#if defined(ENABLE_OVERLOADING)
#endif
#if defined(ENABLE_OVERLOADING)
type instance O.SignalList ScaleAccessible = ScaleAccessibleSignalList
type ScaleAccessibleSignalList = ('[ '("activeDescendantChanged", Atk.Object.ObjectActiveDescendantChangedSignalInfo), '("announcement", Atk.Object.ObjectAnnouncementSignalInfo), '("boundsChanged", Atk.Component.ComponentBoundsChangedSignalInfo), '("childrenChanged", Atk.Object.ObjectChildrenChangedSignalInfo), '("focusEvent", Atk.Object.ObjectFocusEventSignalInfo), '("notify", GObject.Object.ObjectNotifySignalInfo), '("propertyChange", Atk.Object.ObjectPropertyChangeSignalInfo), '("stateChange", Atk.Object.ObjectStateChangeSignalInfo), '("valueChanged", Atk.Value.ValueValueChangedSignalInfo), '("visibleDataChanged", Atk.Object.ObjectVisibleDataChangedSignalInfo)] :: [(Symbol, DK.Type)])
#endif