gi-ibus-1.5.5: IBus bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.IBus.Objects.Attribute

Description

An IBusAttribute represents an attribute that associate to IBusText. It decorates preedit buffer and auxiliary text with underline, foreground and background colors.

Synopsis

Exported types

newtype Attribute Source #

Memory-managed wrapper type.

Constructors

Attribute (ManagedPtr Attribute) 

Instances

Instances details
Eq Attribute Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

GObject Attribute Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

ManagedPtrNewtype Attribute Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

Methods

toManagedPtr :: Attribute -> ManagedPtr Attribute

TypedObject Attribute Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

Methods

glibType :: IO GType

HasParentTypes Attribute Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

IsGValue (Maybe Attribute) Source #

Convert Attribute to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.IBus.Objects.Attribute

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe Attribute -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe Attribute)

type ParentTypes Attribute Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

type ParentTypes Attribute = '[Serializable, Object, Object]

class (GObject o, IsDescendantOf Attribute o) => IsAttribute o Source #

Type class for types which can be safely cast to Attribute, for instance with toAttribute.

Instances

Instances details
(GObject o, IsDescendantOf Attribute o) => IsAttribute o Source # 
Instance details

Defined in GI.IBus.Objects.Attribute

toAttribute :: (MonadIO m, IsAttribute o) => o -> m Attribute Source #

Cast to Attribute, for types for which this is known to be safe. For general casts, use castTo.

Methods

getAttrType

attributeGetAttrType Source #

Arguments

:: (HasCallStack, MonadIO m, IsAttribute a) 
=> a

attr: An Attribute

-> m Word32

Returns: An enum of AttrType.

Gets an enum of AttrType.

getEndIndex

attributeGetEndIndex Source #

Arguments

:: (HasCallStack, MonadIO m, IsAttribute a) 
=> a

attr: An Attribute

-> m Word32

Returns: A end unsigned index

Gets an end unsigned index

getStartIndex

attributeGetStartIndex Source #

Arguments

:: (HasCallStack, MonadIO m, IsAttribute a) 
=> a

attr: An Attribute

-> m Word32

Returns: A start unsigned index

Gets a start unsigned index

getValue

attributeGetValue Source #

Arguments

:: (HasCallStack, MonadIO m, IsAttribute a) 
=> a

attr: An Attribute

-> m Word32

Returns: An unsigned int value relative with AttrType.

Gets an unsigned int value relative with AttrType. If the type is AttrTypeUnderline, the return value is AttrUnderline. If the type is AttrTypeForeground, the return value is the color RGB.

new

attributeNew Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Word32

type: Type of the attribute.

-> Word32

value: Value of the attribute.

-> Word32

startIndex: Where attribute starts.

-> Word32

endIndex: Where attribute ends.

-> m Attribute

Returns: A newly allocated IBusAttribute.

Creates a new IBusAttribute.