{- | Copyright : Will Thompson, Iñaki García Etxebarria and Jonas Platte License : LGPL-2.1 Maintainer : Iñaki García Etxebarria (inaki@blueleaf.cc) /No description available in the introspection data./ -} #define ENABLE_OVERLOADING (MIN_VERSION_haskell_gi_overloading(1,0,0) \ && !defined(__HADDOCK_VERSION__)) module GI.Poppler.Objects.StructureElement ( #if ENABLE_OVERLOADING StructureElementGetBorderColorMethodInfo, #endif -- * Exported types StructureElement(..) , IsStructureElement , toStructureElement , noStructureElement , -- * Methods -- ** getAbbreviation #method:getAbbreviation# #if ENABLE_OVERLOADING StructureElementGetAbbreviationMethodInfo, #endif structureElementGetAbbreviation , -- ** getActualText #method:getActualText# #if ENABLE_OVERLOADING StructureElementGetActualTextMethodInfo , #endif structureElementGetActualText , -- ** getAltText #method:getAltText# #if ENABLE_OVERLOADING StructureElementGetAltTextMethodInfo , #endif structureElementGetAltText , -- ** getBackgroundColor #method:getBackgroundColor# #if ENABLE_OVERLOADING StructureElementGetBackgroundColorMethodInfo, #endif structureElementGetBackgroundColor , -- ** getBaselineShift #method:getBaselineShift# #if ENABLE_OVERLOADING StructureElementGetBaselineShiftMethodInfo, #endif structureElementGetBaselineShift , -- ** getBlockAlign #method:getBlockAlign# #if ENABLE_OVERLOADING StructureElementGetBlockAlignMethodInfo , #endif structureElementGetBlockAlign , -- ** getBorderStyle #method:getBorderStyle# #if ENABLE_OVERLOADING StructureElementGetBorderStyleMethodInfo, #endif structureElementGetBorderStyle , -- ** getBorderThickness #method:getBorderThickness# #if ENABLE_OVERLOADING StructureElementGetBorderThicknessMethodInfo, #endif structureElementGetBorderThickness , -- ** getBoundingBox #method:getBoundingBox# #if ENABLE_OVERLOADING StructureElementGetBoundingBoxMethodInfo, #endif structureElementGetBoundingBox , -- ** getColor #method:getColor# #if ENABLE_OVERLOADING StructureElementGetColorMethodInfo , #endif structureElementGetColor , -- ** getColumnCount #method:getColumnCount# #if ENABLE_OVERLOADING StructureElementGetColumnCountMethodInfo, #endif structureElementGetColumnCount , -- ** getColumnGaps #method:getColumnGaps# #if ENABLE_OVERLOADING StructureElementGetColumnGapsMethodInfo , #endif structureElementGetColumnGaps , -- ** getColumnWidths #method:getColumnWidths# #if ENABLE_OVERLOADING StructureElementGetColumnWidthsMethodInfo, #endif structureElementGetColumnWidths , -- ** getEndIndent #method:getEndIndent# #if ENABLE_OVERLOADING StructureElementGetEndIndentMethodInfo , #endif structureElementGetEndIndent , -- ** getFormDescription #method:getFormDescription# #if ENABLE_OVERLOADING StructureElementGetFormDescriptionMethodInfo, #endif structureElementGetFormDescription , -- ** getFormRole #method:getFormRole# #if ENABLE_OVERLOADING StructureElementGetFormRoleMethodInfo , #endif structureElementGetFormRole , -- ** getFormState #method:getFormState# #if ENABLE_OVERLOADING StructureElementGetFormStateMethodInfo , #endif structureElementGetFormState , -- ** getGlyphOrientation #method:getGlyphOrientation# #if ENABLE_OVERLOADING StructureElementGetGlyphOrientationMethodInfo, #endif structureElementGetGlyphOrientation , -- ** getHeight #method:getHeight# #if ENABLE_OVERLOADING StructureElementGetHeightMethodInfo , #endif structureElementGetHeight , -- ** getId #method:getId# #if ENABLE_OVERLOADING StructureElementGetIdMethodInfo , #endif structureElementGetId , -- ** getInlineAlign #method:getInlineAlign# #if ENABLE_OVERLOADING StructureElementGetInlineAlignMethodInfo, #endif structureElementGetInlineAlign , -- ** getKind #method:getKind# #if ENABLE_OVERLOADING StructureElementGetKindMethodInfo , #endif structureElementGetKind , -- ** getLanguage #method:getLanguage# #if ENABLE_OVERLOADING StructureElementGetLanguageMethodInfo , #endif structureElementGetLanguage , -- ** getLineHeight #method:getLineHeight# #if ENABLE_OVERLOADING StructureElementGetLineHeightMethodInfo , #endif structureElementGetLineHeight , -- ** getListNumbering #method:getListNumbering# #if ENABLE_OVERLOADING StructureElementGetListNumberingMethodInfo, #endif structureElementGetListNumbering , -- ** getPadding #method:getPadding# #if ENABLE_OVERLOADING StructureElementGetPaddingMethodInfo , #endif structureElementGetPadding , -- ** getPage #method:getPage# #if ENABLE_OVERLOADING StructureElementGetPageMethodInfo , #endif structureElementGetPage , -- ** getPlacement #method:getPlacement# #if ENABLE_OVERLOADING StructureElementGetPlacementMethodInfo , #endif structureElementGetPlacement , -- ** getRubyAlign #method:getRubyAlign# #if ENABLE_OVERLOADING StructureElementGetRubyAlignMethodInfo , #endif structureElementGetRubyAlign , -- ** getRubyPosition #method:getRubyPosition# #if ENABLE_OVERLOADING StructureElementGetRubyPositionMethodInfo, #endif structureElementGetRubyPosition , -- ** getSpaceAfter #method:getSpaceAfter# #if ENABLE_OVERLOADING StructureElementGetSpaceAfterMethodInfo , #endif structureElementGetSpaceAfter , -- ** getSpaceBefore #method:getSpaceBefore# #if ENABLE_OVERLOADING StructureElementGetSpaceBeforeMethodInfo, #endif structureElementGetSpaceBefore , -- ** getStartIndent #method:getStartIndent# #if ENABLE_OVERLOADING StructureElementGetStartIndentMethodInfo, #endif structureElementGetStartIndent , -- ** getTableBorderStyle #method:getTableBorderStyle# #if ENABLE_OVERLOADING StructureElementGetTableBorderStyleMethodInfo, #endif structureElementGetTableBorderStyle , -- ** getTableColumnSpan #method:getTableColumnSpan# #if ENABLE_OVERLOADING StructureElementGetTableColumnSpanMethodInfo, #endif structureElementGetTableColumnSpan , -- ** getTableHeaders #method:getTableHeaders# #if ENABLE_OVERLOADING StructureElementGetTableHeadersMethodInfo, #endif structureElementGetTableHeaders , -- ** getTablePadding #method:getTablePadding# #if ENABLE_OVERLOADING StructureElementGetTablePaddingMethodInfo, #endif structureElementGetTablePadding , -- ** getTableRowSpan #method:getTableRowSpan# #if ENABLE_OVERLOADING StructureElementGetTableRowSpanMethodInfo, #endif structureElementGetTableRowSpan , -- ** getTableScope #method:getTableScope# #if ENABLE_OVERLOADING StructureElementGetTableScopeMethodInfo , #endif structureElementGetTableScope , -- ** getTableSummary #method:getTableSummary# #if ENABLE_OVERLOADING StructureElementGetTableSummaryMethodInfo, #endif structureElementGetTableSummary , -- ** getText #method:getText# #if ENABLE_OVERLOADING StructureElementGetTextMethodInfo , #endif structureElementGetText , -- ** getTextAlign #method:getTextAlign# #if ENABLE_OVERLOADING StructureElementGetTextAlignMethodInfo , #endif structureElementGetTextAlign , -- ** getTextDecorationColor #method:getTextDecorationColor# #if ENABLE_OVERLOADING StructureElementGetTextDecorationColorMethodInfo, #endif structureElementGetTextDecorationColor , -- ** getTextDecorationThickness #method:getTextDecorationThickness# #if ENABLE_OVERLOADING StructureElementGetTextDecorationThicknessMethodInfo, #endif structureElementGetTextDecorationThickness, -- ** getTextDecorationType #method:getTextDecorationType# #if ENABLE_OVERLOADING StructureElementGetTextDecorationTypeMethodInfo, #endif structureElementGetTextDecorationType , -- ** getTextIndent #method:getTextIndent# #if ENABLE_OVERLOADING StructureElementGetTextIndentMethodInfo , #endif structureElementGetTextIndent , -- ** getTextSpans #method:getTextSpans# #if ENABLE_OVERLOADING StructureElementGetTextSpansMethodInfo , #endif structureElementGetTextSpans , -- ** getTitle #method:getTitle# #if ENABLE_OVERLOADING StructureElementGetTitleMethodInfo , #endif structureElementGetTitle , -- ** getWidth #method:getWidth# #if ENABLE_OVERLOADING StructureElementGetWidthMethodInfo , #endif structureElementGetWidth , -- ** getWritingMode #method:getWritingMode# #if ENABLE_OVERLOADING StructureElementGetWritingModeMethodInfo, #endif structureElementGetWritingMode , -- ** isBlock #method:isBlock# #if ENABLE_OVERLOADING StructureElementIsBlockMethodInfo , #endif structureElementIsBlock , -- ** isContent #method:isContent# #if ENABLE_OVERLOADING StructureElementIsContentMethodInfo , #endif structureElementIsContent , -- ** isGrouping #method:isGrouping# #if ENABLE_OVERLOADING StructureElementIsGroupingMethodInfo , #endif structureElementIsGrouping , -- ** isInline #method:isInline# #if ENABLE_OVERLOADING StructureElementIsInlineMethodInfo , #endif structureElementIsInline , ) 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.ManagedPtr as B.ManagedPtr import qualified Data.GI.Base.GClosure as B.GClosure import qualified Data.GI.Base.GError as B.GError 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.Text as T 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 GI.GObject.Objects.Object as GObject.Object import {-# SOURCE #-} qualified GI.Poppler.Enums as Poppler.Enums import {-# SOURCE #-} qualified GI.Poppler.Flags as Poppler.Flags import {-# SOURCE #-} qualified GI.Poppler.Structs.Color as Poppler.Color import {-# SOURCE #-} qualified GI.Poppler.Structs.Rectangle as Poppler.Rectangle import {-# SOURCE #-} qualified GI.Poppler.Structs.TextSpan as Poppler.TextSpan -- | Memory-managed wrapper type. newtype StructureElement = StructureElement (ManagedPtr StructureElement) foreign import ccall "poppler_structure_element_get_type" c_poppler_structure_element_get_type :: IO GType instance GObject StructureElement where gobjectType = c_poppler_structure_element_get_type -- | Type class for types which can be safely cast to `StructureElement`, for instance with `toStructureElement`. class (GObject o, O.IsDescendantOf StructureElement o) => IsStructureElement o instance (GObject o, O.IsDescendantOf StructureElement o) => IsStructureElement o instance O.HasParentTypes StructureElement type instance O.ParentTypes StructureElement = '[GObject.Object.Object] -- | Cast to `StructureElement`, for types for which this is known to be safe. For general casts, use `Data.GI.Base.ManagedPtr.castTo`. toStructureElement :: (MonadIO m, IsStructureElement o) => o -> m StructureElement toStructureElement = liftIO . unsafeCastTo StructureElement -- | A convenience alias for `Nothing` :: `Maybe` `StructureElement`. noStructureElement :: Maybe StructureElement noStructureElement = Nothing #if ENABLE_OVERLOADING type family ResolveStructureElementMethod (t :: Symbol) (o :: *) :: * where ResolveStructureElementMethod "bindProperty" o = GObject.Object.ObjectBindPropertyMethodInfo ResolveStructureElementMethod "bindPropertyFull" o = GObject.Object.ObjectBindPropertyFullMethodInfo ResolveStructureElementMethod "forceFloating" o = GObject.Object.ObjectForceFloatingMethodInfo ResolveStructureElementMethod "freezeNotify" o = GObject.Object.ObjectFreezeNotifyMethodInfo ResolveStructureElementMethod "getv" o = GObject.Object.ObjectGetvMethodInfo ResolveStructureElementMethod "isBlock" o = StructureElementIsBlockMethodInfo ResolveStructureElementMethod "isContent" o = StructureElementIsContentMethodInfo ResolveStructureElementMethod "isFloating" o = GObject.Object.ObjectIsFloatingMethodInfo ResolveStructureElementMethod "isGrouping" o = StructureElementIsGroupingMethodInfo ResolveStructureElementMethod "isInline" o = StructureElementIsInlineMethodInfo ResolveStructureElementMethod "notify" o = GObject.Object.ObjectNotifyMethodInfo ResolveStructureElementMethod "notifyByPspec" o = GObject.Object.ObjectNotifyByPspecMethodInfo ResolveStructureElementMethod "ref" o = GObject.Object.ObjectRefMethodInfo ResolveStructureElementMethod "refSink" o = GObject.Object.ObjectRefSinkMethodInfo ResolveStructureElementMethod "runDispose" o = GObject.Object.ObjectRunDisposeMethodInfo ResolveStructureElementMethod "stealData" o = GObject.Object.ObjectStealDataMethodInfo ResolveStructureElementMethod "stealQdata" o = GObject.Object.ObjectStealQdataMethodInfo ResolveStructureElementMethod "thawNotify" o = GObject.Object.ObjectThawNotifyMethodInfo ResolveStructureElementMethod "unref" o = GObject.Object.ObjectUnrefMethodInfo ResolveStructureElementMethod "watchClosure" o = GObject.Object.ObjectWatchClosureMethodInfo ResolveStructureElementMethod "getAbbreviation" o = StructureElementGetAbbreviationMethodInfo ResolveStructureElementMethod "getActualText" o = StructureElementGetActualTextMethodInfo ResolveStructureElementMethod "getAltText" o = StructureElementGetAltTextMethodInfo ResolveStructureElementMethod "getBackgroundColor" o = StructureElementGetBackgroundColorMethodInfo ResolveStructureElementMethod "getBaselineShift" o = StructureElementGetBaselineShiftMethodInfo ResolveStructureElementMethod "getBlockAlign" o = StructureElementGetBlockAlignMethodInfo ResolveStructureElementMethod "getBorderColor" o = StructureElementGetBorderColorMethodInfo ResolveStructureElementMethod "getBorderStyle" o = StructureElementGetBorderStyleMethodInfo ResolveStructureElementMethod "getBorderThickness" o = StructureElementGetBorderThicknessMethodInfo ResolveStructureElementMethod "getBoundingBox" o = StructureElementGetBoundingBoxMethodInfo ResolveStructureElementMethod "getColor" o = StructureElementGetColorMethodInfo ResolveStructureElementMethod "getColumnCount" o = StructureElementGetColumnCountMethodInfo ResolveStructureElementMethod "getColumnGaps" o = StructureElementGetColumnGapsMethodInfo ResolveStructureElementMethod "getColumnWidths" o = StructureElementGetColumnWidthsMethodInfo ResolveStructureElementMethod "getData" o = GObject.Object.ObjectGetDataMethodInfo ResolveStructureElementMethod "getEndIndent" o = StructureElementGetEndIndentMethodInfo ResolveStructureElementMethod "getFormDescription" o = StructureElementGetFormDescriptionMethodInfo ResolveStructureElementMethod "getFormRole" o = StructureElementGetFormRoleMethodInfo ResolveStructureElementMethod "getFormState" o = StructureElementGetFormStateMethodInfo ResolveStructureElementMethod "getGlyphOrientation" o = StructureElementGetGlyphOrientationMethodInfo ResolveStructureElementMethod "getHeight" o = StructureElementGetHeightMethodInfo ResolveStructureElementMethod "getId" o = StructureElementGetIdMethodInfo ResolveStructureElementMethod "getInlineAlign" o = StructureElementGetInlineAlignMethodInfo ResolveStructureElementMethod "getKind" o = StructureElementGetKindMethodInfo ResolveStructureElementMethod "getLanguage" o = StructureElementGetLanguageMethodInfo ResolveStructureElementMethod "getLineHeight" o = StructureElementGetLineHeightMethodInfo ResolveStructureElementMethod "getListNumbering" o = StructureElementGetListNumberingMethodInfo ResolveStructureElementMethod "getPadding" o = StructureElementGetPaddingMethodInfo ResolveStructureElementMethod "getPage" o = StructureElementGetPageMethodInfo ResolveStructureElementMethod "getPlacement" o = StructureElementGetPlacementMethodInfo ResolveStructureElementMethod "getProperty" o = GObject.Object.ObjectGetPropertyMethodInfo ResolveStructureElementMethod "getQdata" o = GObject.Object.ObjectGetQdataMethodInfo ResolveStructureElementMethod "getRubyAlign" o = StructureElementGetRubyAlignMethodInfo ResolveStructureElementMethod "getRubyPosition" o = StructureElementGetRubyPositionMethodInfo ResolveStructureElementMethod "getSpaceAfter" o = StructureElementGetSpaceAfterMethodInfo ResolveStructureElementMethod "getSpaceBefore" o = StructureElementGetSpaceBeforeMethodInfo ResolveStructureElementMethod "getStartIndent" o = StructureElementGetStartIndentMethodInfo ResolveStructureElementMethod "getTableBorderStyle" o = StructureElementGetTableBorderStyleMethodInfo ResolveStructureElementMethod "getTableColumnSpan" o = StructureElementGetTableColumnSpanMethodInfo ResolveStructureElementMethod "getTableHeaders" o = StructureElementGetTableHeadersMethodInfo ResolveStructureElementMethod "getTablePadding" o = StructureElementGetTablePaddingMethodInfo ResolveStructureElementMethod "getTableRowSpan" o = StructureElementGetTableRowSpanMethodInfo ResolveStructureElementMethod "getTableScope" o = StructureElementGetTableScopeMethodInfo ResolveStructureElementMethod "getTableSummary" o = StructureElementGetTableSummaryMethodInfo ResolveStructureElementMethod "getText" o = StructureElementGetTextMethodInfo ResolveStructureElementMethod "getTextAlign" o = StructureElementGetTextAlignMethodInfo ResolveStructureElementMethod "getTextDecorationColor" o = StructureElementGetTextDecorationColorMethodInfo ResolveStructureElementMethod "getTextDecorationThickness" o = StructureElementGetTextDecorationThicknessMethodInfo ResolveStructureElementMethod "getTextDecorationType" o = StructureElementGetTextDecorationTypeMethodInfo ResolveStructureElementMethod "getTextIndent" o = StructureElementGetTextIndentMethodInfo ResolveStructureElementMethod "getTextSpans" o = StructureElementGetTextSpansMethodInfo ResolveStructureElementMethod "getTitle" o = StructureElementGetTitleMethodInfo ResolveStructureElementMethod "getWidth" o = StructureElementGetWidthMethodInfo ResolveStructureElementMethod "getWritingMode" o = StructureElementGetWritingModeMethodInfo ResolveStructureElementMethod "setData" o = GObject.Object.ObjectSetDataMethodInfo ResolveStructureElementMethod "setProperty" o = GObject.Object.ObjectSetPropertyMethodInfo ResolveStructureElementMethod l o = O.MethodResolutionFailed l o instance (info ~ ResolveStructureElementMethod t StructureElement, O.MethodInfo info StructureElement p) => OL.IsLabel t (StructureElement -> p) where #if MIN_VERSION_base(4,10,0) fromLabel = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info) #else fromLabel _ = O.overloadedMethod (O.MethodProxy :: O.MethodProxy info) #endif #endif #if ENABLE_OVERLOADING instance O.HasAttributeList StructureElement type instance O.AttributeList StructureElement = StructureElementAttributeList type StructureElementAttributeList = ('[ ] :: [(Symbol, *)]) #endif #if ENABLE_OVERLOADING #endif #if ENABLE_OVERLOADING type instance O.SignalList StructureElement = StructureElementSignalList type StructureElementSignalList = ('[ '("notify", GObject.Object.ObjectNotifySignalInfo)] :: [(Symbol, *)]) #endif -- method StructureElement::get_abbreviation -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_abbreviation" poppler_structure_element_get_abbreviation :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Acronyms and abbreviations contained in elements of type @/POPPLER_STRUCTURE_ELEMENT_SPAN/@ may have an associated expanded text form, which can be retrieved using this function. /Since: 0.26/ -} structureElementGetAbbreviation :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ Text of the expanded abbreviation if the element text is an abbreviation or acrony, 'Nothing' if not. -} structureElementGetAbbreviation popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_abbreviation popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetAbbreviation" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetAbbreviationMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetAbbreviationMethodInfo a signature where overloadedMethod _ = structureElementGetAbbreviation #endif -- method StructureElement::get_actual_text -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_actual_text" poppler_structure_element_get_actual_text :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the actual text enclosed by the element (and its child elements). The actual text is mostly used for non-text elements like images and figures which \<emphasis>do\<\/emphasis> have the graphical appearance of text, like a logo. For those the actual text is the equivalent text to those graphical elements which look like text when rendered. Note that for elements containing proper text, the function 'GI.Poppler.Objects.StructureElement.structureElementGetText' must be used instead. /Since: 0.26/ -} structureElementGetActualText :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ The actual text for the element, or 'Nothing' if not defined. -} structureElementGetActualText popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_actual_text popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetActualText" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetActualTextMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetActualTextMethodInfo a signature where overloadedMethod _ = structureElementGetActualText #endif -- method StructureElement::get_alt_text -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_alt_text" poppler_structure_element_get_alt_text :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the “alternate” text representation of the element (and its child elements). This is mostly used for non-text elements like images and figures, to specify a textual description of the element. Note that for elements containing proper text, the function 'GI.Poppler.Objects.StructureElement.structureElementGetText' must be used instead. /Since: 0.26/ -} structureElementGetAltText :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ The alternate text representation for the element, or 'Nothing' if not defined. -} structureElementGetAltText popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_alt_text popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetAltText" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetAltTextMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetAltTextMethodInfo a signature where overloadedMethod _ = structureElementGetAltText #endif -- method StructureElement::get_background_color -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "color", argType = TInterface (Name {namespace = "Poppler", name = "Color"}), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerColor.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = True, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_background_color" poppler_structure_element_get_background_color :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Poppler.Color.Color -> -- color : TInterface (Name {namespace = "Poppler", name = "Color"}) IO CInt {- | Obtains the background color of the element. If this attribute is not specified, the element shall be treated as if it were transparent. /Since: 0.26/ -} structureElementGetBackgroundColor :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ((Bool, Poppler.Color.Color)) {- ^ __Returns:__ 'True' if a color is defined for the element, 'False' otherwise. -} structureElementGetBackgroundColor popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement color <- callocBoxedBytes 6 :: IO (Ptr Poppler.Color.Color) result <- poppler_structure_element_get_background_color popplerStructureElement' color let result' = (/= 0) result color' <- (wrapBoxed Poppler.Color.Color) color touchManagedPtr popplerStructureElement return (result', color') #if ENABLE_OVERLOADING data StructureElementGetBackgroundColorMethodInfo instance (signature ~ (m ((Bool, Poppler.Color.Color))), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetBackgroundColorMethodInfo a signature where overloadedMethod _ = structureElementGetBackgroundColor #endif -- method StructureElement::get_baseline_shift -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_baseline_shift" poppler_structure_element_get_baseline_shift :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains how much the text contained in the inline-level structure element should be shifted, measuring from the baseline of the glyphs. /Since: 0.26/ -} structureElementGetBaselineShift :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A numeric value. -} structureElementGetBaselineShift popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_baseline_shift popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetBaselineShiftMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetBaselineShiftMethodInfo a signature where overloadedMethod _ = structureElementGetBaselineShift #endif -- method StructureElement::get_block_align -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureBlockAlign"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_block_align" poppler_structure_element_get_block_align :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the block-alignment mode of the block-level structure element. /Since: 0.26/ -} structureElementGetBlockAlign :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureBlockAlign {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureBlockAlign' value. -} structureElementGetBlockAlign popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_block_align popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetBlockAlignMethodInfo instance (signature ~ (m Poppler.Enums.StructureBlockAlign), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetBlockAlignMethodInfo a signature where overloadedMethod _ = structureElementGetBlockAlign #endif -- XXX Could not generate method StructureElement::get_border_color -- Error was : Not implemented: "Don't know how to allocate \"colors\" of type TCArray False 4 (-1) (TInterface (Name {namespace = \"Poppler\", name = \"Color\"}))" #if ENABLE_OVERLOADING -- XXX: Dummy instance, since code generation failed. -- Please file a bug at http://github.com/haskell-gi/haskell-gi. data StructureElementGetBorderColorMethodInfo instance (p ~ (), o ~ O.MethodResolutionFailed "getBorderColor" StructureElement) => O.MethodInfo StructureElementGetBorderColorMethodInfo o p where overloadedMethod _ = undefined #endif -- method StructureElement::get_border_style -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "border_styles", argType = TCArray False 4 (-1) (TInterface (Name {namespace = "Poppler", name = "StructureBorderStyle"})), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "\n An array of four #PopplerStructureBorderStyle elements.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [] -- returnType : Nothing -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_border_style" poppler_structure_element_get_border_style :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr (Ptr CUInt) -> -- border_styles : TCArray False 4 (-1) (TInterface (Name {namespace = "Poppler", name = "StructureBorderStyle"})) IO () {- | Obtains the border style of a structure element. The result values are in before-after-start-end ordering. For example, using Western left-to-right writing, that is top-bottom-left-right. /Since: 0.26/ -} structureElementGetBorderStyle :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ([Poppler.Enums.StructureBorderStyle]) structureElementGetBorderStyle popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement borderStyles <- allocMem :: IO (Ptr (Ptr CUInt)) poppler_structure_element_get_border_style popplerStructureElement' borderStyles borderStyles' <- peek borderStyles borderStyles'' <- (unpackStorableArrayWithLength 4) borderStyles' let borderStyles''' = map (toEnum . fromIntegral) borderStyles'' freeMem borderStyles' touchManagedPtr popplerStructureElement freeMem borderStyles return borderStyles''' #if ENABLE_OVERLOADING data StructureElementGetBorderStyleMethodInfo instance (signature ~ (m ([Poppler.Enums.StructureBorderStyle])), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetBorderStyleMethodInfo a signature where overloadedMethod _ = structureElementGetBorderStyle #endif -- method StructureElement::get_border_thickness -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "border_thicknesses", argType = TCArray False 4 (-1) (TBasicType TDouble), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "\n Array with the four values of border thicknesses.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_border_thickness" poppler_structure_element_get_border_thickness :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr (Ptr CDouble) -> -- border_thicknesses : TCArray False 4 (-1) (TBasicType TDouble) IO CInt {- | Obtains the thickness of the border of an element. The result values are in before-after-start-end ordering (for the typical Western left-to-right writing, that is top-bottom-left-right). A value of 0 indicates that the border shall not be drawn. /Since: 0.26/ -} structureElementGetBorderThickness :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ((Bool, [Double])) {- ^ __Returns:__ 'True' if the border thickness attribute is defined for the element, 'False' otherwise. -} structureElementGetBorderThickness popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement borderThicknesses <- allocMem :: IO (Ptr (Ptr CDouble)) result <- poppler_structure_element_get_border_thickness popplerStructureElement' borderThicknesses let result' = (/= 0) result borderThicknesses' <- peek borderThicknesses borderThicknesses'' <- (unpackMapStorableArrayWithLength realToFrac 4) borderThicknesses' freeMem borderThicknesses' touchManagedPtr popplerStructureElement freeMem borderThicknesses return (result', borderThicknesses'') #if ENABLE_OVERLOADING data StructureElementGetBorderThicknessMethodInfo instance (signature ~ (m ((Bool, [Double]))), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetBorderThicknessMethodInfo a signature where overloadedMethod _ = structureElementGetBorderThickness #endif -- method StructureElement::get_bounding_box -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "bounding_box", argType = TInterface (Name {namespace = "Poppler", name = "Rectangle"}), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerRectangle.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = True, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_bounding_box" poppler_structure_element_get_bounding_box :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Poppler.Rectangle.Rectangle -> -- bounding_box : TInterface (Name {namespace = "Poppler", name = "Rectangle"}) IO CInt {- | Obtains the size of the bounding box of a block-level structure element. /Since: 0.26/ -} structureElementGetBoundingBox :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ((Bool, Poppler.Rectangle.Rectangle)) {- ^ __Returns:__ 'True' if a bounding box is defined for the element, 'False' otherwise. -} structureElementGetBoundingBox popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement boundingBox <- callocBoxedBytes 32 :: IO (Ptr Poppler.Rectangle.Rectangle) result <- poppler_structure_element_get_bounding_box popplerStructureElement' boundingBox let result' = (/= 0) result boundingBox' <- (wrapBoxed Poppler.Rectangle.Rectangle) boundingBox touchManagedPtr popplerStructureElement return (result', boundingBox') #if ENABLE_OVERLOADING data StructureElementGetBoundingBoxMethodInfo instance (signature ~ (m ((Bool, Poppler.Rectangle.Rectangle))), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetBoundingBoxMethodInfo a signature where overloadedMethod _ = structureElementGetBoundingBox #endif -- method StructureElement::get_color -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "color", argType = TInterface (Name {namespace = "Poppler", name = "Color"}), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerColor.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = True, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_color" poppler_structure_element_get_color :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Poppler.Color.Color -> -- color : TInterface (Name {namespace = "Poppler", name = "Color"}) IO CInt {- | Obtains the color of the content contained in the element. If this attribute is not specified, the color for this element shall be the current text fill color in effect at the start of its associated content. /Since: 0.26/ -} structureElementGetColor :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ((Bool, Poppler.Color.Color)) {- ^ __Returns:__ 'True' if a color is defined for the element, 'False' otherwise. -} structureElementGetColor popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement color <- callocBoxedBytes 6 :: IO (Ptr Poppler.Color.Color) result <- poppler_structure_element_get_color popplerStructureElement' color let result' = (/= 0) result color' <- (wrapBoxed Poppler.Color.Color) color touchManagedPtr popplerStructureElement return (result', color') #if ENABLE_OVERLOADING data StructureElementGetColorMethodInfo instance (signature ~ (m ((Bool, Poppler.Color.Color))), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetColorMethodInfo a signature where overloadedMethod _ = structureElementGetColor #endif -- method StructureElement::get_column_count -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUInt) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_column_count" poppler_structure_element_get_column_count :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO Word32 {- | Obtains the number of columns used to lay out the content contained in the grouping element. /Since: 0.26/ -} structureElementGetColumnCount :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Word32 {- ^ __Returns:__ Number of columns. -} structureElementGetColumnCount popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_column_count popplerStructureElement' touchManagedPtr popplerStructureElement return result #if ENABLE_OVERLOADING data StructureElementGetColumnCountMethodInfo instance (signature ~ (m Word32), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetColumnCountMethodInfo a signature where overloadedMethod _ = structureElementGetColumnCount #endif -- method StructureElement::get_column_gaps -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "n_values", argType = TBasicType TUInt, direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "Size of the returned array.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [Arg {argCName = "n_values", argType = TBasicType TUInt, direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "Size of the returned array.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- returnType : Just (TCArray False (-1) 1 (TBasicType TDouble)) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_column_gaps" poppler_structure_element_get_column_gaps :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Word32 -> -- n_values : TBasicType TUInt IO (Ptr CDouble) {- | Obtains the size of the gaps in between adjacent columns. Returns an array of elements: the first one is the size of the gap in between columns 1 and 2, second is the size between columns 2 and 3, and so on. For elements which use a single column, 'Nothing' is returned and /@nValues@/ is set to zero. If the attribute is undefined, 'Nothing' is returned and /@nValues@/ is set to a non-zero value. The array with the results is allocated by the function. When it is not needed anymore, be sure to call 'GI.GLib.Functions.free' on it. /Since: 0.26/ -} structureElementGetColumnGaps :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m [Double] {- ^ __Returns:__ Array containing the values for the column gaps, or 'Nothing' if the array is empty or the attribute is not defined. -} structureElementGetColumnGaps popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement nValues <- allocMem :: IO (Ptr Word32) result <- poppler_structure_element_get_column_gaps popplerStructureElement' nValues nValues' <- peek nValues checkUnexpectedReturnNULL "structureElementGetColumnGaps" result result' <- (unpackMapStorableArrayWithLength realToFrac nValues') result freeMem result touchManagedPtr popplerStructureElement freeMem nValues return result' #if ENABLE_OVERLOADING data StructureElementGetColumnGapsMethodInfo instance (signature ~ (m [Double]), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetColumnGapsMethodInfo a signature where overloadedMethod _ = structureElementGetColumnGaps #endif -- method StructureElement::get_column_widths -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "n_values", argType = TBasicType TUInt, direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "Size of the returned array.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [Arg {argCName = "n_values", argType = TBasicType TUInt, direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "Size of the returned array.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- returnType : Just (TCArray False (-1) 1 (TBasicType TDouble)) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_column_widths" poppler_structure_element_get_column_widths :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Word32 -> -- n_values : TBasicType TUInt IO (Ptr CDouble) {- | Obtains an array with the widths of the columns. The array with the results is allocated by the function. When it is not needed anymore, be sure to call 'GI.GLib.Functions.free' on it. /Since: 0.26/ -} structureElementGetColumnWidths :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m [Double] {- ^ __Returns:__ Array containing widths of the columns, or 'Nothing' if the attribute is not defined. -} structureElementGetColumnWidths popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement nValues <- allocMem :: IO (Ptr Word32) result <- poppler_structure_element_get_column_widths popplerStructureElement' nValues nValues' <- peek nValues checkUnexpectedReturnNULL "structureElementGetColumnWidths" result result' <- (unpackMapStorableArrayWithLength realToFrac nValues') result freeMem result touchManagedPtr popplerStructureElement freeMem nValues return result' #if ENABLE_OVERLOADING data StructureElementGetColumnWidthsMethodInfo instance (signature ~ (m [Double]), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetColumnWidthsMethodInfo a signature where overloadedMethod _ = structureElementGetColumnWidths #endif -- method StructureElement::get_end_indent -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_end_indent" poppler_structure_element_get_end_indent :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the amount of indentation at the end of the block-level structure element. /Since: 0.26/ -} structureElementGetEndIndent :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A numeric value. -} structureElementGetEndIndent popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_end_indent popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetEndIndentMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetEndIndentMethodInfo a signature where overloadedMethod _ = structureElementGetEndIndent #endif -- method StructureElement::get_form_description -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_form_description" poppler_structure_element_get_form_description :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the textual description of the form element. Note that the description is for informative purposes, and it is not intended to be rendered. For example, assistive technologies may use the description field to provide an alternate way of presenting an element to the user. The returned string is allocated by the function. When it is not needed anymore, be sure to call 'GI.GLib.Functions.free' on it. /Since: 0.26/ -} structureElementGetFormDescription :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ A string, or 'Nothing' if the attribute is not defined. -} structureElementGetFormDescription popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_form_description popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetFormDescription" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetFormDescriptionMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetFormDescriptionMethodInfo a signature where overloadedMethod _ = structureElementGetFormDescription #endif -- method StructureElement::get_form_role -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureFormRole"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_form_role" poppler_structure_element_get_form_role :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the role of a form structure element that is part of a form, or is a form field. This hints how the control for the element is intended to be rendered. /Since: 0.26/ -} structureElementGetFormRole :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureFormRole {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureFormRole' value. -} structureElementGetFormRole popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_form_role popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetFormRoleMethodInfo instance (signature ~ (m Poppler.Enums.StructureFormRole), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetFormRoleMethodInfo a signature where overloadedMethod _ = structureElementGetFormRole #endif -- method StructureElement::get_form_state -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureFormState"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_form_state" poppler_structure_element_get_form_state :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | For a structure element that is a form field, obtains in which state the associated control is expected to be rendered. /Since: 0.26/ -} structureElementGetFormState :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureFormState {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureFormState' value. -} structureElementGetFormState popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_form_state popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetFormStateMethodInfo instance (signature ~ (m Poppler.Enums.StructureFormState), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetFormStateMethodInfo a signature where overloadedMethod _ = structureElementGetFormState #endif -- method StructureElement::get_glyph_orientation -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureGlyphOrientation"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_glyph_orientation" poppler_structure_element_get_glyph_orientation :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the glyph orientation for the text contained in a inline-level structure element. /Since: 0.26/ -} structureElementGetGlyphOrientation :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureGlyphOrientation {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureGlyphOrientation' value. -} structureElementGetGlyphOrientation popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_glyph_orientation popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetGlyphOrientationMethodInfo instance (signature ~ (m Poppler.Enums.StructureGlyphOrientation), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetGlyphOrientationMethodInfo a signature where overloadedMethod _ = structureElementGetGlyphOrientation #endif -- method StructureElement::get_height -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_height" poppler_structure_element_get_height :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the height of the block-level structure element. Note that for elements which do not specify a height, it has to be calculated, and in this case -1 is returned. /Since: 0.26/ -} structureElementGetHeight :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A positive value if a width is defined, or -1 if the height is to be calculated automatically. -} structureElementGetHeight popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_height popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetHeightMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetHeightMethodInfo a signature where overloadedMethod _ = structureElementGetHeight #endif -- method StructureElement::get_id -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_id" poppler_structure_element_get_id :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the identifier of an element. /Since: 0.26/ -} structureElementGetId :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ The identifier of the element (if defined), or 'Nothing'. -} structureElementGetId popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_id popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetId" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetIdMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetIdMethodInfo a signature where overloadedMethod _ = structureElementGetId #endif -- method StructureElement::get_inline_align -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureInlineAlign"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_inline_align" poppler_structure_element_get_inline_align :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the inline-alignment mode of the block-level structure element. /Since: 0.26/ -} structureElementGetInlineAlign :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureInlineAlign {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureInlineAlign' value. -} structureElementGetInlineAlign popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_inline_align popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetInlineAlignMethodInfo instance (signature ~ (m Poppler.Enums.StructureInlineAlign), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetInlineAlignMethodInfo a signature where overloadedMethod _ = structureElementGetInlineAlign #endif -- method StructureElement::get_kind -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureElementKind"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_kind" poppler_structure_element_get_kind :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | /No description available in the introspection data./ /Since: 0.26/ -} structureElementGetKind :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureElementKind {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureElementKind' value. -} structureElementGetKind popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_kind popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetKindMethodInfo instance (signature ~ (m Poppler.Enums.StructureElementKind), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetKindMethodInfo a signature where overloadedMethod _ = structureElementGetKind #endif -- method StructureElement::get_language -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_language" poppler_structure_element_get_language :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the language and country code for the content in an element, in two-letter ISO format, e.g. \<code>en_ES\<\/code>, or 'Nothing' if not defined. /Since: 0.26/ -} structureElementGetLanguage :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ language and country code, or 'Nothing'. -} structureElementGetLanguage popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_language popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetLanguage" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetLanguageMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetLanguageMethodInfo a signature where overloadedMethod _ = structureElementGetLanguage #endif -- method StructureElement::get_line_height -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_line_height" poppler_structure_element_get_line_height :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the line height for the text contained in the inline-level structure element. Note that for elements which do not specify a line height, it has to be calculated, and in this case -1 is returned. /Since: 0.26/ -} structureElementGetLineHeight :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A positive value if a line height is defined, or -1 if the height is to be calculated automatically. -} structureElementGetLineHeight popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_line_height popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetLineHeightMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetLineHeightMethodInfo a signature where overloadedMethod _ = structureElementGetLineHeight #endif -- method StructureElement::get_list_numbering -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureListNumbering"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_list_numbering" poppler_structure_element_get_list_numbering :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the list numbering style for list items. /Since: 0.26/ -} structureElementGetListNumbering :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureListNumbering {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureListNumbering' value. -} structureElementGetListNumbering popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_list_numbering popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetListNumberingMethodInfo instance (signature ~ (m Poppler.Enums.StructureListNumbering), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetListNumberingMethodInfo a signature where overloadedMethod _ = structureElementGetListNumbering #endif -- method StructureElement::get_padding -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "paddings", argType = TCArray False 4 (-1) (TBasicType TDouble), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "\n Padding for the four sides of the element.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [] -- returnType : Nothing -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_padding" poppler_structure_element_get_padding :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr (Ptr CDouble) -> -- paddings : TCArray False 4 (-1) (TBasicType TDouble) IO () {- | Obtains the padding of an element (space around it). The result values are in before-after-start-end ordering. For example using Western left-to-right writing, that is top-bottom-left-right. /Since: 0.26/ -} structureElementGetPadding :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ([Double]) structureElementGetPadding popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement paddings <- allocMem :: IO (Ptr (Ptr CDouble)) poppler_structure_element_get_padding popplerStructureElement' paddings paddings' <- peek paddings paddings'' <- (unpackMapStorableArrayWithLength realToFrac 4) paddings' freeMem paddings' touchManagedPtr popplerStructureElement freeMem paddings return paddings'' #if ENABLE_OVERLOADING data StructureElementGetPaddingMethodInfo instance (signature ~ (m ([Double])), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetPaddingMethodInfo a signature where overloadedMethod _ = structureElementGetPadding #endif -- method StructureElement::get_page -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TInt) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_page" poppler_structure_element_get_page :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO Int32 {- | Obtains the page number in which the element is contained. /Since: 0.26/ -} structureElementGetPage :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Int32 {- ^ __Returns:__ Number of the page that contains the element, of \<code>-1\<\/code> if not defined. -} structureElementGetPage popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_page popplerStructureElement' touchManagedPtr popplerStructureElement return result #if ENABLE_OVERLOADING data StructureElementGetPageMethodInfo instance (signature ~ (m Int32), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetPageMethodInfo a signature where overloadedMethod _ = structureElementGetPage #endif -- method StructureElement::get_placement -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructurePlacement"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_placement" poppler_structure_element_get_placement :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the placement type of the structure element. /Since: 0.26/ -} structureElementGetPlacement :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructurePlacement {- ^ __Returns:__ A 'GI.Poppler.Enums.StructurePlacement' value. -} structureElementGetPlacement popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_placement popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetPlacementMethodInfo instance (signature ~ (m Poppler.Enums.StructurePlacement), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetPlacementMethodInfo a signature where overloadedMethod _ = structureElementGetPlacement #endif -- method StructureElement::get_ruby_align -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureRubyAlign"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_ruby_align" poppler_structure_element_get_ruby_align :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the alignment for the ruby text contained in a inline-level structure element. /Since: 0.26/ -} structureElementGetRubyAlign :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureRubyAlign {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureRubyAlign' value. -} structureElementGetRubyAlign popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_ruby_align popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetRubyAlignMethodInfo instance (signature ~ (m Poppler.Enums.StructureRubyAlign), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetRubyAlignMethodInfo a signature where overloadedMethod _ = structureElementGetRubyAlign #endif -- method StructureElement::get_ruby_position -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureRubyPosition"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_ruby_position" poppler_structure_element_get_ruby_position :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the position for the ruby text contained in a inline-level structure element. /Since: 0.26/ -} structureElementGetRubyPosition :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureRubyPosition {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureRubyPosition' value. -} structureElementGetRubyPosition popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_ruby_position popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetRubyPositionMethodInfo instance (signature ~ (m Poppler.Enums.StructureRubyPosition), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetRubyPositionMethodInfo a signature where overloadedMethod _ = structureElementGetRubyPosition #endif -- method StructureElement::get_space_after -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_space_after" poppler_structure_element_get_space_after :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the amount of empty space after the block-level structure element. /Since: 0.26/ -} structureElementGetSpaceAfter :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A positive value. -} structureElementGetSpaceAfter popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_space_after popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetSpaceAfterMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetSpaceAfterMethodInfo a signature where overloadedMethod _ = structureElementGetSpaceAfter #endif -- method StructureElement::get_space_before -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_space_before" poppler_structure_element_get_space_before :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the amount of empty space before the block-level structure element. /Since: 0.26/ -} structureElementGetSpaceBefore :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A positive value. -} structureElementGetSpaceBefore popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_space_before popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetSpaceBeforeMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetSpaceBeforeMethodInfo a signature where overloadedMethod _ = structureElementGetSpaceBefore #endif -- method StructureElement::get_start_indent -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_start_indent" poppler_structure_element_get_start_indent :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the amount of indentation at the beginning of the block-level structure element. /Since: 0.26/ -} structureElementGetStartIndent :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A numeric value. -} structureElementGetStartIndent popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_start_indent popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetStartIndentMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetStartIndentMethodInfo a signature where overloadedMethod _ = structureElementGetStartIndent #endif -- method StructureElement::get_table_border_style -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "border_styles", argType = TCArray False 4 (-1) (TInterface (Name {namespace = "Poppler", name = "StructureBorderStyle"})), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "\n An array of four #PopplerStructureBorderStyle elements.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [] -- returnType : Nothing -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_border_style" poppler_structure_element_get_table_border_style :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr (Ptr CUInt) -> -- border_styles : TCArray False 4 (-1) (TInterface (Name {namespace = "Poppler", name = "StructureBorderStyle"})) IO () {- | Obtains the table cell border style of a block-level structure element. The result values are in before-after-start-end ordering. For example, using Western left-to-right writing, that is top-bottom-left-right. /Since: 0.26/ -} structureElementGetTableBorderStyle :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ([Poppler.Enums.StructureBorderStyle]) structureElementGetTableBorderStyle popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement borderStyles <- allocMem :: IO (Ptr (Ptr CUInt)) poppler_structure_element_get_table_border_style popplerStructureElement' borderStyles borderStyles' <- peek borderStyles borderStyles'' <- (unpackStorableArrayWithLength 4) borderStyles' let borderStyles''' = map (toEnum . fromIntegral) borderStyles'' freeMem borderStyles' touchManagedPtr popplerStructureElement freeMem borderStyles return borderStyles''' #if ENABLE_OVERLOADING data StructureElementGetTableBorderStyleMethodInfo instance (signature ~ (m ([Poppler.Enums.StructureBorderStyle])), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTableBorderStyleMethodInfo a signature where overloadedMethod _ = structureElementGetTableBorderStyle #endif -- method StructureElement::get_table_column_span -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUInt) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_column_span" poppler_structure_element_get_table_column_span :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO Word32 {- | Obtains the number of columns the table element spans to. /Since: 0.26/ -} structureElementGetTableColumnSpan :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Word32 {- ^ __Returns:__ A positive, non-zero value. -} structureElementGetTableColumnSpan popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_table_column_span popplerStructureElement' touchManagedPtr popplerStructureElement return result #if ENABLE_OVERLOADING data StructureElementGetTableColumnSpanMethodInfo instance (signature ~ (m Word32), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTableColumnSpanMethodInfo a signature where overloadedMethod _ = structureElementGetTableColumnSpan #endif -- method StructureElement::get_table_headers -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TCArray True (-1) (-1) (TBasicType TUTF8)) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_headers" poppler_structure_element_get_table_headers :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO (Ptr CString) {- | Obtains an array with the names of the table column headers. This is only useful for table header row elements. The array with the results is allocated by the function. The number of items in the returned array can be obtained with 'GI.GLib.Functions.strvLength'. The returned value must be freed using 'GI.GLib.Functions.strfreev'. /Since: 0.26/ -} structureElementGetTableHeaders :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m [T.Text] {- ^ __Returns:__ Zero-terminated array of strings with the table header names, or 'Nothing' if the attribute is not defined. -} structureElementGetTableHeaders popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_table_headers popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetTableHeaders" result result' <- unpackZeroTerminatedUTF8CArray result mapZeroTerminatedCArray freeMem result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTableHeadersMethodInfo instance (signature ~ (m [T.Text]), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTableHeadersMethodInfo a signature where overloadedMethod _ = structureElementGetTableHeaders #endif -- method StructureElement::get_table_padding -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "paddings", argType = TCArray False 4 (-1) (TBasicType TDouble), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "\n Padding for the four sides of the element.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [] -- returnType : Nothing -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_padding" poppler_structure_element_get_table_padding :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr (Ptr CDouble) -> -- paddings : TCArray False 4 (-1) (TBasicType TDouble) IO () {- | Obtains the padding between the table cell’s content rectangle and the surrounding border of a block-level structure element. The result values are in before-after-start-end ordering (for the typical Western left-to-right writing, that is top-bottom-left-right). /Since: 0.26/ -} structureElementGetTablePadding :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ([Double]) structureElementGetTablePadding popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement paddings <- allocMem :: IO (Ptr (Ptr CDouble)) poppler_structure_element_get_table_padding popplerStructureElement' paddings paddings' <- peek paddings paddings'' <- (unpackMapStorableArrayWithLength realToFrac 4) paddings' freeMem paddings' touchManagedPtr popplerStructureElement freeMem paddings return paddings'' #if ENABLE_OVERLOADING data StructureElementGetTablePaddingMethodInfo instance (signature ~ (m ([Double])), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTablePaddingMethodInfo a signature where overloadedMethod _ = structureElementGetTablePadding #endif -- method StructureElement::get_table_row_span -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUInt) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_row_span" poppler_structure_element_get_table_row_span :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO Word32 {- | Obtains the number of rows the table element spans to. /Since: 0.26/ -} structureElementGetTableRowSpan :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Word32 {- ^ __Returns:__ A positive, non-zero value. -} structureElementGetTableRowSpan popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_table_row_span popplerStructureElement' touchManagedPtr popplerStructureElement return result #if ENABLE_OVERLOADING data StructureElementGetTableRowSpanMethodInfo instance (signature ~ (m Word32), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTableRowSpanMethodInfo a signature where overloadedMethod _ = structureElementGetTableRowSpan #endif -- method StructureElement::get_table_scope -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureTableScope"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_scope" poppler_structure_element_get_table_scope :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the scope of a table structure element. /Since: 0.26/ -} structureElementGetTableScope :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureTableScope {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureTableScope' value. -} structureElementGetTableScope popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_table_scope popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTableScopeMethodInfo instance (signature ~ (m Poppler.Enums.StructureTableScope), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTableScopeMethodInfo a signature where overloadedMethod _ = structureElementGetTableScope #endif -- method StructureElement::get_table_summary -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_table_summary" poppler_structure_element_get_table_summary :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the textual summary of the contents of the table element. Note that the summary is meant for informative purposes, and it is not intended to be rendered. For example, assistive technologies may use the description field to provide an alternate way of presenting an element to the user, or a document indexer may want to scan it for additional keywords. The returned string is allocated by the function. When it is not needed anymore, be sure to call 'GI.GLib.Functions.free' on it. /Since: 0.26/ -} structureElementGetTableSummary :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ A string, or 'Nothing' if the attribute is not defined. -} structureElementGetTableSummary popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_table_summary popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetTableSummary" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTableSummaryMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTableSummaryMethodInfo a signature where overloadedMethod _ = structureElementGetTableSummary #endif -- method StructureElement::get_text -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "flags", argType = TInterface (Name {namespace = "Poppler", name = "StructureGetTextFlags"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureGetTextFlags value, or\n %POPPLER_STRUCTURE_GET_TEXT_NONE to disable all the flags.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text" poppler_structure_element_get_text :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) CUInt -> -- flags : TInterface (Name {namespace = "Poppler", name = "StructureGetTextFlags"}) IO CString {- | Obtains the text enclosed by an element, or the text enclosed by the elements in the subtree (including the element itself). /Since: 0.26/ -} structureElementGetText :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> [Poppler.Flags.StructureGetTextFlags] {- ^ /@flags@/: A 'GI.Poppler.Flags.StructureGetTextFlags' value, or 'GI.Poppler.Flags.StructureGetTextFlagsNone' to disable all the flags. -} -> m T.Text {- ^ __Returns:__ A string. -} structureElementGetText popplerStructureElement flags = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement let flags' = gflagsToWord flags result <- poppler_structure_element_get_text popplerStructureElement' flags' checkUnexpectedReturnNULL "structureElementGetText" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTextMethodInfo instance (signature ~ ([Poppler.Flags.StructureGetTextFlags] -> m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextMethodInfo a signature where overloadedMethod _ = structureElementGetText #endif -- method StructureElement::get_text_align -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureTextAlign"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text_align" poppler_structure_element_get_text_align :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the text alignment mode of the text contained into a block-level structure element. /Since: 0.26/ -} structureElementGetTextAlign :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureTextAlign {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureTextAlign' value. -} structureElementGetTextAlign popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_text_align popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTextAlignMethodInfo instance (signature ~ (m Poppler.Enums.StructureTextAlign), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextAlignMethodInfo a signature where overloadedMethod _ = structureElementGetTextAlign #endif -- method StructureElement::get_text_decoration_color -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "color", argType = TInterface (Name {namespace = "Poppler", name = "Color"}), direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerColor.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = True, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text_decoration_color" poppler_structure_element_get_text_decoration_color :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Poppler.Color.Color -> -- color : TInterface (Name {namespace = "Poppler", name = "Color"}) IO CInt {- | Obtains the color of the text decoration for the text contained in the inline-level structure element. If this attribute is not specified, the color for this element shall be the current fill color in effect at the start of its associated content. /Since: 0.26/ -} structureElementGetTextDecorationColor :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m ((Bool, Poppler.Color.Color)) {- ^ __Returns:__ 'True' if a color is defined for the element, 'False' otherwise. -} structureElementGetTextDecorationColor popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement color <- callocBoxedBytes 6 :: IO (Ptr Poppler.Color.Color) result <- poppler_structure_element_get_text_decoration_color popplerStructureElement' color let result' = (/= 0) result color' <- (wrapBoxed Poppler.Color.Color) color touchManagedPtr popplerStructureElement return (result', color') #if ENABLE_OVERLOADING data StructureElementGetTextDecorationColorMethodInfo instance (signature ~ (m ((Bool, Poppler.Color.Color))), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextDecorationColorMethodInfo a signature where overloadedMethod _ = structureElementGetTextDecorationColor #endif -- method StructureElement::get_text_decoration_thickness -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text_decoration_thickness" poppler_structure_element_get_text_decoration_thickness :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the thickness of the text decoration for the text contained in the inline-level structure element. If this attribute is not specified, it shall be derived from the current stroke thickness in effect at the start of the element’s associated content. /Since: 0.26/ -} structureElementGetTextDecorationThickness :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ Thickness of the text decoration, or NAN if not defined. -} structureElementGetTextDecorationThickness popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_text_decoration_thickness popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTextDecorationThicknessMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextDecorationThicknessMethodInfo a signature where overloadedMethod _ = structureElementGetTextDecorationThickness #endif -- method StructureElement::get_text_decoration_type -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureTextDecoration"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text_decoration_type" poppler_structure_element_get_text_decoration_type :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the text decoration type of the text contained in the inline-level structure element. /Since: 0.26/ -} structureElementGetTextDecorationType :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureTextDecoration {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureTextDecoration' value. -} structureElementGetTextDecorationType popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_text_decoration_type popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTextDecorationTypeMethodInfo instance (signature ~ (m Poppler.Enums.StructureTextDecoration), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextDecorationTypeMethodInfo a signature where overloadedMethod _ = structureElementGetTextDecorationType #endif -- method StructureElement::get_text_indent -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text_indent" poppler_structure_element_get_text_indent :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the amount of indentation of the text contained in the block-level structure element. /Since: 0.26/ -} structureElementGetTextIndent :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A numeric value. -} structureElementGetTextIndent popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_text_indent popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTextIndentMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextIndentMethodInfo a signature where overloadedMethod _ = structureElementGetTextIndent #endif -- method StructureElement::get_text_spans -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing},Arg {argCName = "n_text_spans", argType = TBasicType TUInt, direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A pointer to the location where the number of elements in\n the returned array will be stored.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- Lengths : [Arg {argCName = "n_text_spans", argType = TBasicType TUInt, direction = DirectionOut, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A pointer to the location where the number of elements in\n the returned array will be stored.", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferEverything}] -- returnType : Just (TCArray False (-1) 1 (TInterface (Name {namespace = "Poppler", name = "TextSpan"}))) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_text_spans" poppler_structure_element_get_text_spans :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) Ptr Word32 -> -- n_text_spans : TBasicType TUInt IO (Ptr (Ptr Poppler.TextSpan.TextSpan)) {- | Obtains the text enclosed by an element, as an array of 'GI.Poppler.Structs.TextSpan.TextSpan' structures. Each item in the list is a piece of text which share the same attributes, plus its attributes. The following example shows how to obtain and free the text spans of an element: \<informalexample>\<programlisting> guint i, n_spans; PopplerTextSpan **text_spans = poppler_structure_element_get_text_spans (element, &n_spans); \/\<!-- -->* Use the text spans *\<!-- -->\/ for (i = 0; i \< n_spans; i++) poppler_text_span_free (text_spans[i]); g_free (text_spans); \<\/programlisting>\<\/informalexample> /Since: 0.26/ -} structureElementGetTextSpans :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m [Poppler.TextSpan.TextSpan] {- ^ __Returns:__ An array of 'GI.Poppler.Structs.TextSpan.TextSpan' elements. -} structureElementGetTextSpans popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement nTextSpans <- allocMem :: IO (Ptr Word32) result <- poppler_structure_element_get_text_spans popplerStructureElement' nTextSpans nTextSpans' <- peek nTextSpans checkUnexpectedReturnNULL "structureElementGetTextSpans" result result' <- (unpackPtrArrayWithLength nTextSpans') result result'' <- mapM (wrapBoxed Poppler.TextSpan.TextSpan) result' freeMem result touchManagedPtr popplerStructureElement freeMem nTextSpans return result'' #if ENABLE_OVERLOADING data StructureElementGetTextSpansMethodInfo instance (signature ~ (m [Poppler.TextSpan.TextSpan]), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTextSpansMethodInfo a signature where overloadedMethod _ = structureElementGetTextSpans #endif -- method StructureElement::get_title -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TUTF8) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_title" poppler_structure_element_get_title :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CString {- | Obtains the title of an element. /Since: 0.26/ -} structureElementGetTitle :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m T.Text {- ^ __Returns:__ The title of the element, or 'Nothing'. -} structureElementGetTitle popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_title popplerStructureElement' checkUnexpectedReturnNULL "structureElementGetTitle" result result' <- cstringToText result freeMem result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetTitleMethodInfo instance (signature ~ (m T.Text), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetTitleMethodInfo a signature where overloadedMethod _ = structureElementGetTitle #endif -- method StructureElement::get_width -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TDouble) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_width" poppler_structure_element_get_width :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CDouble {- | Obtains the width of the block-level structure element. Note that for elements which do not specify a width, it has to be calculated, and in this case -1 is returned. /Since: 0.26/ -} structureElementGetWidth :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Double {- ^ __Returns:__ A positive value if a width is defined, or -1 if the width is to be calculated automatically. -} structureElementGetWidth popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_width popplerStructureElement' let result' = realToFrac result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetWidthMethodInfo instance (signature ~ (m Double), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetWidthMethodInfo a signature where overloadedMethod _ = structureElementGetWidth #endif -- method StructureElement::get_writing_mode -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TInterface (Name {namespace = "Poppler", name = "StructureWritingMode"})) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_get_writing_mode" poppler_structure_element_get_writing_mode :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CUInt {- | Obtains the writing mode (writing direction) of the content associated with a structure element. /Since: 0.26/ -} structureElementGetWritingMode :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Poppler.Enums.StructureWritingMode {- ^ __Returns:__ A 'GI.Poppler.Enums.StructureWritingMode' value. -} structureElementGetWritingMode popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_get_writing_mode popplerStructureElement' let result' = (toEnum . fromIntegral) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementGetWritingModeMethodInfo instance (signature ~ (m Poppler.Enums.StructureWritingMode), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementGetWritingModeMethodInfo a signature where overloadedMethod _ = structureElementGetWritingMode #endif -- method StructureElement::is_block -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_is_block" poppler_structure_element_is_block :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CInt {- | Checks whether an element is a block element. /Since: 0.26/ -} structureElementIsBlock :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Bool {- ^ __Returns:__ 'True' if the element is a block element, or 'False' otherwise. -} structureElementIsBlock popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_is_block popplerStructureElement' let result' = (/= 0) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementIsBlockMethodInfo instance (signature ~ (m Bool), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementIsBlockMethodInfo a signature where overloadedMethod _ = structureElementIsBlock #endif -- method StructureElement::is_content -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_is_content" poppler_structure_element_is_content :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CInt {- | Checks whether an element is actual document content. /Since: 0.26/ -} structureElementIsContent :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Bool {- ^ __Returns:__ 'True' if the element is content, or 'False' otherwise. -} structureElementIsContent popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_is_content popplerStructureElement' let result' = (/= 0) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementIsContentMethodInfo instance (signature ~ (m Bool), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementIsContentMethodInfo a signature where overloadedMethod _ = structureElementIsContent #endif -- method StructureElement::is_grouping -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_is_grouping" poppler_structure_element_is_grouping :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CInt {- | Checks whether an element is a grouping element. /Since: 0.26/ -} structureElementIsGrouping :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Bool {- ^ __Returns:__ 'True' if the element is a grouping element, 'False' otherwise. -} structureElementIsGrouping popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_is_grouping popplerStructureElement' let result' = (/= 0) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementIsGroupingMethodInfo instance (signature ~ (m Bool), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementIsGroupingMethodInfo a signature where overloadedMethod _ = structureElementIsGrouping #endif -- method StructureElement::is_inline -- method type : OrdinaryMethod -- Args : [Arg {argCName = "poppler_structure_element", argType = TInterface (Name {namespace = "Poppler", name = "StructureElement"}), direction = DirectionIn, mayBeNull = False, argDoc = Documentation {rawDocText = Just "A #PopplerStructureElement", sinceVersion = Nothing}, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, argCallerAllocates = False, transfer = TransferNothing}] -- Lengths : [] -- returnType : Just (TBasicType TBoolean) -- throws : False -- Skip return : False foreign import ccall "poppler_structure_element_is_inline" poppler_structure_element_is_inline :: Ptr StructureElement -> -- poppler_structure_element : TInterface (Name {namespace = "Poppler", name = "StructureElement"}) IO CInt {- | Checks whether an element is an inline element. /Since: 0.26/ -} structureElementIsInline :: (B.CallStack.HasCallStack, MonadIO m, IsStructureElement a) => a {- ^ /@popplerStructureElement@/: A 'GI.Poppler.Objects.StructureElement.StructureElement' -} -> m Bool {- ^ __Returns:__ 'True' if the element is an inline element, or 'False' otherwise. -} structureElementIsInline popplerStructureElement = liftIO $ do popplerStructureElement' <- unsafeManagedPtrCastPtr popplerStructureElement result <- poppler_structure_element_is_inline popplerStructureElement' let result' = (/= 0) result touchManagedPtr popplerStructureElement return result' #if ENABLE_OVERLOADING data StructureElementIsInlineMethodInfo instance (signature ~ (m Bool), MonadIO m, IsStructureElement a) => O.MethodInfo StructureElementIsInlineMethodInfo a signature where overloadedMethod _ = structureElementIsInline #endif