{-# LINE 2 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
module Graphics.UI.Gtk.Multiline.TextTag (
TextTag,
TextTagClass,
castToTextTag, gTypeTextTag,
toTextTag,
TagName,
textTagNew,
textTagSetPriority,
textTagGetPriority,
TextAttributes(..),
textAttributesNew,
textAttributesCopy,
textAttributesCopyValues,
makeNewTextAttributes,
textTagName,
textTagBackground,
textTagBackgroundSet,
textTagBackgroundFullHeight,
textTagBackgroundFullHeightSet,
textTagBackgroundGdk,
textTagBackgroundStipple,
textTagBackgroundStippleSet,
textTagForeground,
textTagForegroundSet,
textTagForegroundGdk,
textTagForegroundStipple,
textTagForegroundStippleSet,
textTagDirection,
textTagEditable,
textTagEditableSet,
textTagFont,
textTagFontDesc,
textTagFamily,
textTagFamilySet,
textTagStyle,
textTagStyleSet,
textTagTabsSet,
textTagVariant,
textTagVariantSet,
textTagWeight,
textTagWeightSet,
textTagStretch,
textTagStretchSet,
textTagSize,
textTagSizeSet,
textTagScale,
textTagScaleSet,
textTagSizePoints,
textTagJustification,
textTagJustificationSet,
textTagLanguage,
textTagLanguageSet,
textTagLeftMargin,
textTagLeftMarginSet,
textTagRightMargin,
textTagRightMarginSet,
textTagIndent,
textTagIndentSet,
textTagRise,
textTagRiseSet,
textTagPixelsAboveLines,
textTagPixelsAboveLinesSet,
textTagPixelsBelowLines,
textTagPixelsBelowLinesSet,
textTagPixelsInsideWrap,
textTagPixelsInsideWrapSet,
textTagStrikethrough,
textTagStrikethroughSet,
textTagUnderline,
textTagUnderlineSet,
textTagWrapMode,
textTagWrapModeSet,
textTagInvisible,
textTagInvisibleSet,
textTagParagraphBackground,
textTagParagraphBackgroundSet,
textTagParagraphBackgroundGdk,
textTagPriority,
textTagEvent,
onTextTagEvent
) where
import Control.Monad (liftM)
import System.Glib.FFI
import System.Glib.UTFString
import System.Glib.Attributes
import System.Glib.Properties
import Graphics.UI.Gtk.Types
{-# LINE 164 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
import Graphics.UI.Gtk.Signals
{-# LINE 165 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
import Graphics.Rendering.Pango.Font
import Graphics.Rendering.Pango.BasicTypes (FontDescription (..), makeNewFontDescription)
import Graphics.Rendering.Pango.Enums (FontStyle(..), Variant(..),
Stretch(..), Underline(..))
import Graphics.UI.Gtk.General.Enums (TextDirection(..),
Justification(..), WrapMode(..))
import Graphics.UI.Gtk.General.Structs (Color(..))
import Graphics.UI.Gtk.Multiline.Types ( TextIter, mkTextIterCopy )
import Graphics.UI.Gtk.Gdk.Events (Event, marshalEvent)
import Graphics.UI.Gtk.Gdk.EventM (EventM, EAny)
import Control.Monad.Reader ( runReaderT )
{-# LINE 180 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
type TagName = DefaultGlibString
textTagNew :: Maybe TagName -> IO TextTag
textTagNew :: Maybe TagName -> IO TextTag
textTagNew (Just TagName
name) =
(ForeignPtr TextTag -> TextTag, FinalizerPtr TextTag)
-> IO (Ptr TextTag) -> IO TextTag
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
wrapNewGObject (ForeignPtr TextTag -> TextTag, FinalizerPtr TextTag)
forall {a}. (ForeignPtr TextTag -> TextTag, FinalizerPtr a)
mkTextTag (IO (Ptr TextTag) -> IO TextTag) -> IO (Ptr TextTag) -> IO TextTag
forall a b. (a -> b) -> a -> b
$
TagName -> (CString -> IO (Ptr TextTag)) -> IO (Ptr TextTag)
forall a. TagName -> (CString -> IO a) -> IO a
forall s a. GlibString s => s -> (CString -> IO a) -> IO a
withUTFString TagName
name ((CString -> IO (Ptr TextTag)) -> IO (Ptr TextTag))
-> (CString -> IO (Ptr TextTag)) -> IO (Ptr TextTag)
forall a b. (a -> b) -> a -> b
$ \CString
namePtr ->
CString -> IO (Ptr TextTag)
gtk_text_tag_new
{-# LINE 195 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
namePtr
textTagNew Maybe TagName
Nothing =
(ForeignPtr TextTag -> TextTag, FinalizerPtr TextTag)
-> IO (Ptr TextTag) -> IO TextTag
forall obj.
GObjectClass obj =>
(ForeignPtr obj -> obj, FinalizerPtr obj) -> IO (Ptr obj) -> IO obj
wrapNewGObject (ForeignPtr TextTag -> TextTag, FinalizerPtr TextTag)
forall {a}. (ForeignPtr TextTag -> TextTag, FinalizerPtr a)
mkTextTag (IO (Ptr TextTag) -> IO TextTag) -> IO (Ptr TextTag) -> IO TextTag
forall a b. (a -> b) -> a -> b
$ CString -> IO (Ptr TextTag)
gtk_text_tag_new CString
forall a. Ptr a
nullPtr
textTagGetPriority :: TextTagClass self => self -> IO Int
textTagGetPriority :: forall self. TextTagClass self => self -> IO Int
textTagGetPriority self
self =
(CInt -> Int) -> IO CInt -> IO Int
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM CInt -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral (IO CInt -> IO Int) -> IO CInt -> IO Int
forall a b. (a -> b) -> a -> b
$
(\(TextTag ForeignPtr TextTag
arg1) -> ForeignPtr TextTag -> (Ptr TextTag -> IO CInt) -> IO CInt
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr TextTag
arg1 ((Ptr TextTag -> IO CInt) -> IO CInt)
-> (Ptr TextTag -> IO CInt) -> IO CInt
forall a b. (a -> b) -> a -> b
$ \Ptr TextTag
argPtr1 ->Ptr TextTag -> IO CInt
gtk_text_tag_get_priority Ptr TextTag
argPtr1)
{-# LINE 209 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
(toTextTag self)
textTagSetPriority :: TextTagClass self => self -> Int -> IO ()
textTagSetPriority :: forall self. TextTagClass self => self -> Int -> IO ()
textTagSetPriority self
self Int
priority =
(\(TextTag ForeignPtr TextTag
arg1) CInt
arg2 -> ForeignPtr TextTag -> (Ptr TextTag -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr TextTag
arg1 ((Ptr TextTag -> IO ()) -> IO ())
-> (Ptr TextTag -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr TextTag
argPtr1 ->Ptr TextTag -> CInt -> IO ()
gtk_text_tag_set_priority Ptr TextTag
argPtr1 CInt
arg2)
{-# LINE 227 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
(toTextTag self)
(Int -> CInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral Int
priority)
newtype TextAttributes = TextAttributes (ForeignPtr (TextAttributes))
{-# LINE 233 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textAttributesNew :: IO TextAttributes
textAttributesNew :: IO TextAttributes
textAttributesNew =
IO (Ptr TextAttributes)
gtk_text_attributes_new IO (Ptr TextAttributes)
-> (Ptr TextAttributes -> IO TextAttributes) -> IO TextAttributes
forall a b. IO a -> (a -> IO b) -> IO b
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= Ptr TextAttributes -> IO TextAttributes
makeNewTextAttributes
textAttributesCopy ::
TextAttributes
-> IO TextAttributes
textAttributesCopy :: TextAttributes -> IO TextAttributes
textAttributesCopy TextAttributes
src =
(\(TextAttributes ForeignPtr TextAttributes
arg1) -> ForeignPtr TextAttributes
-> (Ptr TextAttributes -> IO (Ptr TextAttributes))
-> IO (Ptr TextAttributes)
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr TextAttributes
arg1 ((Ptr TextAttributes -> IO (Ptr TextAttributes))
-> IO (Ptr TextAttributes))
-> (Ptr TextAttributes -> IO (Ptr TextAttributes))
-> IO (Ptr TextAttributes)
forall a b. (a -> b) -> a -> b
$ \Ptr TextAttributes
argPtr1 ->Ptr TextAttributes -> IO (Ptr TextAttributes)
gtk_text_attributes_copy Ptr TextAttributes
argPtr1) TextAttributes
src IO (Ptr TextAttributes)
-> (Ptr TextAttributes -> IO TextAttributes) -> IO TextAttributes
forall a b. IO a -> (a -> IO b) -> IO b
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= Ptr TextAttributes -> IO TextAttributes
makeNewTextAttributes
textAttributesCopyValues :: TextAttributes -> TextAttributes -> IO ()
textAttributesCopyValues :: TextAttributes -> TextAttributes -> IO ()
textAttributesCopyValues TextAttributes
src TextAttributes
dest =
(\(TextAttributes ForeignPtr TextAttributes
arg1) (TextAttributes ForeignPtr TextAttributes
arg2) -> ForeignPtr TextAttributes -> (Ptr TextAttributes -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr TextAttributes
arg1 ((Ptr TextAttributes -> IO ()) -> IO ())
-> (Ptr TextAttributes -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr TextAttributes
argPtr1 ->ForeignPtr TextAttributes -> (Ptr TextAttributes -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr TextAttributes
arg2 ((Ptr TextAttributes -> IO ()) -> IO ())
-> (Ptr TextAttributes -> IO ()) -> IO ()
forall a b. (a -> b) -> a -> b
$ \Ptr TextAttributes
argPtr2 ->Ptr TextAttributes -> Ptr TextAttributes -> IO ()
gtk_text_attributes_copy_values Ptr TextAttributes
argPtr1 Ptr TextAttributes
argPtr2) TextAttributes
src TextAttributes
dest
makeNewTextAttributes :: Ptr TextAttributes -> IO TextAttributes
makeNewTextAttributes :: Ptr TextAttributes -> IO TextAttributes
makeNewTextAttributes Ptr TextAttributes
ptr =
(ForeignPtr TextAttributes -> TextAttributes)
-> IO (ForeignPtr TextAttributes) -> IO TextAttributes
forall (m :: * -> *) a1 r. Monad m => (a1 -> r) -> m a1 -> m r
liftM ForeignPtr TextAttributes -> TextAttributes
TextAttributes (IO (ForeignPtr TextAttributes) -> IO TextAttributes)
-> IO (ForeignPtr TextAttributes) -> IO TextAttributes
forall a b. (a -> b) -> a -> b
$ Ptr TextAttributes
-> FinalizerPtr TextAttributes -> IO (ForeignPtr TextAttributes)
forall a. Ptr a -> FinalizerPtr a -> IO (ForeignPtr a)
newForeignPtr Ptr TextAttributes
ptr FinalizerPtr TextAttributes
text_attributes_unref
foreign import ccall unsafe ">k_text_attributes_unref"
text_attributes_unref :: FinalizerPtr TextAttributes
textTagName :: (TextTagClass self, GlibString string) => Attr self (Maybe string)
textTagName :: forall self string.
(TextTagClass self, GlibString string) =>
Attr self (Maybe string)
textTagName = String -> Attr self (Maybe string)
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> Attr gobj (Maybe string)
newAttrFromMaybeStringProperty String
"name"
textTagBackground :: (TextTagClass self, GlibString string) => WriteAttr self string
textTagBackground :: forall self string.
(TextTagClass self, GlibString string) =>
WriteAttr self string
textTagBackground = String -> WriteAttr self string
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> WriteAttr gobj string
writeAttrFromStringProperty String
"background"
textTagBackgroundSet :: TextTagClass self => Attr self Bool
textTagBackgroundSet :: forall self. TextTagClass self => Attr self Bool
textTagBackgroundSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"background-set"
textTagBackgroundFullHeight :: TextTagClass self => Attr self Bool
textTagBackgroundFullHeight :: forall self. TextTagClass self => Attr self Bool
textTagBackgroundFullHeight = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"background-full-height"
textTagBackgroundFullHeightSet :: TextTagClass self => Attr self Bool
textTagBackgroundFullHeightSet :: forall self. TextTagClass self => Attr self Bool
textTagBackgroundFullHeightSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"background-full-height-set"
textTagBackgroundGdk :: TextTagClass self => Attr self Color
textTagBackgroundGdk :: forall self. TextTagClass self => Attr self Color
textTagBackgroundGdk =
String -> GType -> Attr self Color
forall gobj boxed.
(GObjectClass gobj, Storable boxed) =>
String -> GType -> Attr gobj boxed
newAttrFromBoxedStorableProperty String
"background-gdk"
GType
gdk_color_get_type
{-# LINE 309 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagBackgroundStipple :: (TextTagClass self, PixmapClass pixmap) => ReadWriteAttr self Pixmap pixmap
textTagBackgroundStipple :: forall self pixmap.
(TextTagClass self, PixmapClass pixmap) =>
ReadWriteAttr self Pixmap pixmap
textTagBackgroundStipple = String -> GType -> ReadWriteAttr self Pixmap pixmap
forall gobj gobj' gobj''.
(GObjectClass gobj, GObjectClass gobj', GObjectClass gobj'') =>
String -> GType -> ReadWriteAttr gobj gobj' gobj''
newAttrFromObjectProperty String
"background-stipple"
GType
gdk_pixmap_get_type
{-# LINE 317 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagBackgroundStippleSet :: TextTagClass self => Attr self Bool
textTagBackgroundStippleSet :: forall self. TextTagClass self => Attr self Bool
textTagBackgroundStippleSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"background-stipple-set"
textTagForeground :: (TextTagClass self, GlibString string) => WriteAttr self string
textTagForeground :: forall self string.
(TextTagClass self, GlibString string) =>
WriteAttr self string
textTagForeground = String -> WriteAttr self string
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> WriteAttr gobj string
writeAttrFromStringProperty String
"foreground"
textTagForegroundSet :: TextTagClass self => Attr self Bool
textTagForegroundSet :: forall self. TextTagClass self => Attr self Bool
textTagForegroundSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"foreground-set"
textTagForegroundGdk :: TextTagClass self => Attr self Color
textTagForegroundGdk :: forall self. TextTagClass self => Attr self Color
textTagForegroundGdk =
String -> GType -> Attr self Color
forall gobj boxed.
(GObjectClass gobj, Storable boxed) =>
String -> GType -> Attr gobj boxed
newAttrFromBoxedStorableProperty String
"foreground-gdk"
GType
gdk_color_get_type
{-# LINE 347 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagForegroundStipple :: (TextTagClass self, PixmapClass pixmap) => ReadWriteAttr self Pixmap pixmap
textTagForegroundStipple :: forall self pixmap.
(TextTagClass self, PixmapClass pixmap) =>
ReadWriteAttr self Pixmap pixmap
textTagForegroundStipple = String -> GType -> ReadWriteAttr self Pixmap pixmap
forall gobj gobj' gobj''.
(GObjectClass gobj, GObjectClass gobj', GObjectClass gobj'') =>
String -> GType -> ReadWriteAttr gobj gobj' gobj''
newAttrFromObjectProperty String
"foreground-stipple"
GType
gdk_pixmap_get_type
{-# LINE 355 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagForegroundStippleSet :: TextTagClass self => Attr self Bool
textTagForegroundStippleSet :: forall self. TextTagClass self => Attr self Bool
textTagForegroundStippleSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"foreground-stipple-set"
textTagDirection :: TextTagClass self => Attr self TextDirection
textTagDirection :: forall self. TextTagClass self => Attr self TextDirection
textTagDirection = String -> GType -> Attr self TextDirection
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"direction"
GType
gtk_text_direction_get_type
{-# LINE 372 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagEditable :: TextTagClass self => Attr self Bool
textTagEditable :: forall self. TextTagClass self => Attr self Bool
textTagEditable = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"editable"
textTagEditableSet :: TextTagClass self => Attr self Bool
textTagEditableSet :: forall self. TextTagClass self => Attr self Bool
textTagEditableSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"editable-set"
textTagFont :: (TextTagClass self, GlibString string) => Attr self string
textTagFont :: forall self string.
(TextTagClass self, GlibString string) =>
Attr self string
textTagFont = String -> Attr self string
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> Attr gobj string
newAttrFromStringProperty String
"font"
textTagFontDesc :: TextTagClass self => Attr self FontDescription
textTagFontDesc :: forall self. TextTagClass self => Attr self FontDescription
textTagFontDesc = (Ptr FontDescription -> IO FontDescription)
-> (FontDescription -> (Ptr FontDescription -> IO ()) -> IO ())
-> String
-> GType
-> Attr self FontDescription
forall gobj boxed.
GObjectClass gobj =>
(Ptr boxed -> IO boxed)
-> (boxed -> (Ptr boxed -> IO ()) -> IO ())
-> String
-> GType
-> Attr gobj boxed
newAttrFromBoxedOpaqueProperty Ptr FontDescription -> IO FontDescription
makeNewFontDescription
(\(FontDescription ForeignPtr FontDescription
fd) Ptr FontDescription -> IO ()
act -> ForeignPtr FontDescription
-> (Ptr FontDescription -> IO ()) -> IO ()
forall a b. ForeignPtr a -> (Ptr a -> IO b) -> IO b
withForeignPtr ForeignPtr FontDescription
fd Ptr FontDescription -> IO ()
act) String
"font-desc"
GType
pango_font_description_get_type
{-# LINE 400 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagFamily :: (TextTagClass self, GlibString string) => Attr self string
textTagFamily :: forall self string.
(TextTagClass self, GlibString string) =>
Attr self string
textTagFamily = String -> Attr self string
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> Attr gobj string
newAttrFromStringProperty String
"family"
textTagFamilySet :: TextTagClass self => Attr self Bool
textTagFamilySet :: forall self. TextTagClass self => Attr self Bool
textTagFamilySet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"family-set"
textTagStyle :: TextTagClass self => Attr self FontStyle
textTagStyle :: forall self. TextTagClass self => Attr self FontStyle
textTagStyle = String -> GType -> Attr self FontStyle
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"style"
GType
pango_style_get_type
{-# LINE 422 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagStyleSet :: TextTagClass self => Attr self Bool
textTagStyleSet :: forall self. TextTagClass self => Attr self Bool
textTagStyleSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"style-set"
textTagTabsSet :: TextTagClass self => Attr self Bool
textTagTabsSet :: forall self. TextTagClass self => Attr self Bool
textTagTabsSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"tabs-set"
textTagVariant :: TextTagClass self => Attr self Variant
textTagVariant :: forall self. TextTagClass self => Attr self Variant
textTagVariant = String -> GType -> Attr self Variant
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"variant"
GType
pango_variant_get_type
{-# LINE 447 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagVariantSet :: TextTagClass self => Attr self Bool
textTagVariantSet :: forall self. TextTagClass self => Attr self Bool
textTagVariantSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"variant-set"
textTagWeight :: TextTagClass self => Attr self Int
textTagWeight :: forall self. TextTagClass self => Attr self Int
textTagWeight = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"weight"
textTagWeightSet :: TextTagClass self => Attr self Bool
textTagWeightSet :: forall self. TextTagClass self => Attr self Bool
textTagWeightSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"weight-set"
textTagStretch :: TextTagClass self => Attr self Stretch
textTagStretch :: forall self. TextTagClass self => Attr self Stretch
textTagStretch = String -> GType -> Attr self Stretch
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"stretch"
GType
pango_stretch_get_type
{-# LINE 479 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagStretchSet :: TextTagClass self => Attr self Bool
textTagStretchSet :: forall self. TextTagClass self => Attr self Bool
textTagStretchSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"stretch-set"
textTagSize :: TextTagClass self => Attr self Int
textTagSize :: forall self. TextTagClass self => Attr self Int
textTagSize = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"size"
textTagSizeSet :: TextTagClass self => Attr self Bool
textTagSizeSet :: forall self. TextTagClass self => Attr self Bool
textTagSizeSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"size-set"
textTagScale :: TextTagClass self => Attr self Double
textTagScale :: forall self. TextTagClass self => Attr self Double
textTagScale = String -> Attr self Double
forall gobj. GObjectClass gobj => String -> Attr gobj Double
newAttrFromDoubleProperty String
"scale"
textTagScaleSet :: TextTagClass self => Attr self Bool
textTagScaleSet :: forall self. TextTagClass self => Attr self Bool
textTagScaleSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"scale-set"
textTagSizePoints :: TextTagClass self => Attr self Double
textTagSizePoints :: forall self. TextTagClass self => Attr self Double
textTagSizePoints = String -> Attr self Double
forall gobj. GObjectClass gobj => String -> Attr gobj Double
newAttrFromDoubleProperty String
"size-points"
textTagJustification :: TextTagClass self => Attr self Justification
textTagJustification :: forall self. TextTagClass self => Attr self Justification
textTagJustification = String -> GType -> Attr self Justification
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"justification"
GType
gtk_justification_get_type
{-# LINE 533 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagJustificationSet :: TextTagClass self => Attr self Bool
textTagJustificationSet :: forall self. TextTagClass self => Attr self Bool
textTagJustificationSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"justification-set"
textTagLanguage :: (TextTagClass self, GlibString string) => Attr self string
textTagLanguage :: forall self string.
(TextTagClass self, GlibString string) =>
Attr self string
textTagLanguage = String -> Attr self string
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> Attr gobj string
newAttrFromStringProperty String
"language"
textTagLanguageSet :: TextTagClass self => Attr self Bool
textTagLanguageSet :: forall self. TextTagClass self => Attr self Bool
textTagLanguageSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"language-set"
textTagLeftMargin :: TextTagClass self => Attr self Int
textTagLeftMargin :: forall self. TextTagClass self => Attr self Int
textTagLeftMargin = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"left-margin"
textTagLeftMarginSet :: TextTagClass self => Attr self Bool
textTagLeftMarginSet :: forall self. TextTagClass self => Attr self Bool
textTagLeftMarginSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"left-margin-set"
textTagRightMargin :: TextTagClass self => Attr self Int
textTagRightMargin :: forall self. TextTagClass self => Attr self Int
textTagRightMargin = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"right-margin"
textTagRightMarginSet :: TextTagClass self => Attr self Bool
textTagRightMarginSet :: forall self. TextTagClass self => Attr self Bool
textTagRightMarginSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"right-margin-set"
textTagIndent :: TextTagClass self => Attr self Int
textTagIndent :: forall self. TextTagClass self => Attr self Int
textTagIndent = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"indent"
textTagIndentSet :: TextTagClass self => Attr self Bool
textTagIndentSet :: forall self. TextTagClass self => Attr self Bool
textTagIndentSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"indent-set"
textTagRise :: TextTagClass self => Attr self Int
textTagRise :: forall self. TextTagClass self => Attr self Int
textTagRise = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"rise"
textTagRiseSet :: TextTagClass self => Attr self Bool
textTagRiseSet :: forall self. TextTagClass self => Attr self Bool
textTagRiseSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"rise-set"
textTagPixelsAboveLines :: TextTagClass self => Attr self Int
textTagPixelsAboveLines :: forall self. TextTagClass self => Attr self Int
textTagPixelsAboveLines = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"pixels-above-lines"
textTagPixelsAboveLinesSet :: TextTagClass self => Attr self Bool
textTagPixelsAboveLinesSet :: forall self. TextTagClass self => Attr self Bool
textTagPixelsAboveLinesSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"pixels-above-lines-set"
textTagPixelsBelowLines :: TextTagClass self => Attr self Int
textTagPixelsBelowLines :: forall self. TextTagClass self => Attr self Int
textTagPixelsBelowLines = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"pixels-below-lines"
textTagPixelsBelowLinesSet :: TextTagClass self => Attr self Bool
textTagPixelsBelowLinesSet :: forall self. TextTagClass self => Attr self Bool
textTagPixelsBelowLinesSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"pixels-below-lines-set"
textTagPixelsInsideWrap :: TextTagClass self => Attr self Int
textTagPixelsInsideWrap :: forall self. TextTagClass self => Attr self Int
textTagPixelsInsideWrap = String -> Attr self Int
forall gobj. GObjectClass gobj => String -> Attr gobj Int
newAttrFromIntProperty String
"pixels-inside-wrap"
textTagPixelsInsideWrapSet :: TextTagClass self => Attr self Bool
textTagPixelsInsideWrapSet :: forall self. TextTagClass self => Attr self Bool
textTagPixelsInsideWrapSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"pixels-inside-wrap-set"
textTagStrikethrough :: TextTagClass self => Attr self Bool
textTagStrikethrough :: forall self. TextTagClass self => Attr self Bool
textTagStrikethrough = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"strikethrough"
textTagStrikethroughSet :: TextTagClass self => Attr self Bool
textTagStrikethroughSet :: forall self. TextTagClass self => Attr self Bool
textTagStrikethroughSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"strikethrough-set"
textTagUnderline :: TextTagClass self => Attr self Underline
textTagUnderline :: forall self. TextTagClass self => Attr self Underline
textTagUnderline = String -> GType -> Attr self Underline
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"underline"
GType
pango_underline_get_type
{-# LINE 684 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagUnderlineSet :: TextTagClass self => Attr self Bool
textTagUnderlineSet :: forall self. TextTagClass self => Attr self Bool
textTagUnderlineSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"underline-set"
textTagWrapMode :: TextTagClass self => Attr self WrapMode
textTagWrapMode :: forall self. TextTagClass self => Attr self WrapMode
textTagWrapMode = String -> GType -> Attr self WrapMode
forall gobj enum.
(GObjectClass gobj, Enum enum) =>
String -> GType -> Attr gobj enum
newAttrFromEnumProperty String
"wrap-mode"
GType
gtk_wrap_mode_get_type
{-# LINE 700 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagWrapModeSet :: TextTagClass self => Attr self Bool
textTagWrapModeSet :: forall self. TextTagClass self => Attr self Bool
textTagWrapModeSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"wrap-mode-set"
textTagInvisible :: TextTagClass self => Attr self Bool
textTagInvisible :: forall self. TextTagClass self => Attr self Bool
textTagInvisible = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"invisible"
textTagInvisibleSet :: TextTagClass self => Attr self Bool
textTagInvisibleSet :: forall self. TextTagClass self => Attr self Bool
textTagInvisibleSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"invisible-set"
textTagParagraphBackground :: (TextTagClass self, GlibString string) => WriteAttr self string
textTagParagraphBackground :: forall self string.
(TextTagClass self, GlibString string) =>
WriteAttr self string
textTagParagraphBackground = String -> WriteAttr self string
forall gobj string.
(GObjectClass gobj, GlibString string) =>
String -> WriteAttr gobj string
writeAttrFromStringProperty String
"paragraph-background"
textTagParagraphBackgroundSet :: TextTagClass self => Attr self Bool
textTagParagraphBackgroundSet :: forall self. TextTagClass self => Attr self Bool
textTagParagraphBackgroundSet = String -> Attr self Bool
forall gobj. GObjectClass gobj => String -> Attr gobj Bool
newAttrFromBoolProperty String
"paragraph-background-set"
textTagParagraphBackgroundGdk :: TextTagClass self => Attr self Color
textTagParagraphBackgroundGdk :: forall self. TextTagClass self => Attr self Color
textTagParagraphBackgroundGdk =
String -> GType -> Attr self Color
forall gobj boxed.
(GObjectClass gobj, Storable boxed) =>
String -> GType -> Attr gobj boxed
newAttrFromBoxedStorableProperty String
"paragraph-background-gdk"
GType
gdk_color_get_type
{-# LINE 747 "./Graphics/UI/Gtk/Multiline/TextTag.chs" #-}
textTagPriority :: TextTagClass self => Attr self Int
textTagPriority :: forall self. TextTagClass self => Attr self Int
textTagPriority = (self -> IO Int)
-> (self -> Int -> IO ()) -> ReadWriteAttr self Int Int
forall o a b.
(o -> IO a) -> (o -> b -> IO ()) -> ReadWriteAttr o a b
newAttr
self -> IO Int
forall self. TextTagClass self => self -> IO Int
textTagGetPriority
self -> Int -> IO ()
forall self. TextTagClass self => self -> Int -> IO ()
textTagSetPriority
textTagEvent :: TextTagClass self => Signal self (GObject -> TextIter -> EventM EAny Bool)
textTagEvent :: forall self.
TextTagClass self =>
Signal self (GObject -> TextIter -> EventM EAny Bool)
textTagEvent = (Bool
-> self
-> (GObject -> TextIter -> EventM EAny Bool)
-> IO (ConnectId self))
-> Signal self (GObject -> TextIter -> EventM EAny Bool)
forall object handler.
(Bool -> object -> handler -> IO (ConnectId object))
-> Signal object handler
Signal (\Bool
after self
obj GObject -> TextIter -> EventM EAny Bool
fun ->
String
-> (Ptr TextIter -> IO TextIter)
-> Bool
-> self
-> (GObject -> Ptr EAny -> TextIter -> IO Bool)
-> IO (ConnectId self)
forall a' obj c' c b.
(GObjectClass a', GObjectClass obj) =>
String
-> (Ptr c' -> IO c)
-> Bool
-> obj
-> (a' -> Ptr b -> c -> IO Bool)
-> IO (ConnectId obj)
connect_OBJECT_PTR_BOXED__BOOL String
"event" Ptr TextIter -> IO TextIter
mkTextIterCopy Bool
after self
obj
(\GObject
tv Ptr EAny
eventPtr TextIter
iter -> EventM EAny Bool -> Ptr EAny -> IO Bool
forall r (m :: * -> *) a. ReaderT r m a -> r -> m a
runReaderT (GObject -> TextIter -> EventM EAny Bool
fun GObject
tv TextIter
iter) Ptr EAny
eventPtr)
)
onTextTagEvent :: TextTagClass t => t -> (Event -> TextIter -> IO ()) ->
IO (ConnectId t)
onTextTagEvent :: forall t.
TextTagClass t =>
t -> (Event -> TextIter -> IO ()) -> IO (ConnectId t)
onTextTagEvent t
tt Event -> TextIter -> IO ()
act =
String
-> (Ptr Event -> IO Event)
-> (Ptr TextIter -> IO TextIter)
-> Bool
-> t
-> (Ptr Any -> Event -> TextIter -> IO Bool)
-> IO (ConnectId t)
forall obj b' b c' c a.
GObjectClass obj =>
String
-> (Ptr b' -> IO b)
-> (Ptr c' -> IO c)
-> Bool
-> obj
-> (Ptr a -> b -> c -> IO Bool)
-> IO (ConnectId obj)
connect_PTR_BOXED_BOXED__BOOL String
"event" Ptr Event -> IO Event
marshalEvent Ptr TextIter -> IO TextIter
mkTextIterCopy Bool
False t
tt
(\Ptr Any
_ Event
event TextIter
iter -> Event -> TextIter -> IO ()
act Event
event TextIter
iter IO () -> IO Bool -> IO Bool
forall a b. IO a -> IO b -> IO b
forall (m :: * -> *) a b. Monad m => m a -> m b -> m b
>> Bool -> IO Bool
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return Bool
False)
foreign import ccall unsafe "gtk_text_tag_new"
gtk_text_tag_new :: ((Ptr CChar) -> (IO (Ptr TextTag)))
foreign import ccall unsafe "gtk_text_tag_get_priority"
gtk_text_tag_get_priority :: ((Ptr TextTag) -> (IO CInt))
foreign import ccall safe "gtk_text_tag_set_priority"
gtk_text_tag_set_priority :: ((Ptr TextTag) -> (CInt -> (IO ())))
foreign import ccall unsafe "gtk_text_attributes_new"
gtk_text_attributes_new :: (IO (Ptr TextAttributes))
foreign import ccall safe "gtk_text_attributes_copy"
gtk_text_attributes_copy :: ((Ptr TextAttributes) -> (IO (Ptr TextAttributes)))
foreign import ccall safe "gtk_text_attributes_copy_values"
gtk_text_attributes_copy_values :: ((Ptr TextAttributes) -> ((Ptr TextAttributes) -> (IO ())))
foreign import ccall unsafe "gdk_color_get_type"
gdk_color_get_type :: CULong
foreign import ccall unsafe "gdk_pixmap_get_type"
gdk_pixmap_get_type :: CULong
foreign import ccall unsafe "gtk_text_direction_get_type"
gtk_text_direction_get_type :: CULong
foreign import ccall unsafe "pango_font_description_get_type"
pango_font_description_get_type :: CULong
foreign import ccall unsafe "pango_style_get_type"
pango_style_get_type :: CULong
foreign import ccall unsafe "pango_variant_get_type"
pango_variant_get_type :: CULong
foreign import ccall unsafe "pango_stretch_get_type"
pango_stretch_get_type :: CULong
foreign import ccall unsafe "gtk_justification_get_type"
gtk_justification_get_type :: CULong
foreign import ccall unsafe "pango_underline_get_type"
pango_underline_get_type :: CULong
foreign import ccall unsafe "gtk_wrap_mode_get_type"
gtk_wrap_mode_get_type :: CULong