Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | None |
Language | Haskell2010 |
EditableText
should be implemented by UI components which
contain text which the user can edit, via the Object
corresponding to that component (see Object
).
EditableText
is a subclass of Text
, and as such, an object
which implements EditableText
is by definition an Text
implementor as well.
See also: Text
Synopsis
- newtype EditableText = EditableText (ManagedPtr EditableText)
- class (ManagedPtrNewtype o, IsDescendantOf EditableText o) => IsEditableText o
- editableTextCopyText :: (HasCallStack, MonadIO m, IsEditableText a) => a -> Int32 -> Int32 -> m ()
- editableTextCutText :: (HasCallStack, MonadIO m, IsEditableText a) => a -> Int32 -> Int32 -> m ()
- editableTextDeleteText :: (HasCallStack, MonadIO m, IsEditableText a) => a -> Int32 -> Int32 -> m ()
- editableTextInsertText :: (HasCallStack, MonadIO m, IsEditableText a) => a -> Text -> Int32 -> Int32 -> m ()
- editableTextPasteText :: (HasCallStack, MonadIO m, IsEditableText a) => a -> Int32 -> m ()
- editableTextSetRunAttributes :: (HasCallStack, MonadIO m, IsEditableText a) => a -> [Ptr ()] -> Int32 -> Int32 -> m Bool
- editableTextSetTextContents :: (HasCallStack, MonadIO m, IsEditableText a) => a -> Text -> m ()
Exported types
newtype EditableText Source #
Memory-managed wrapper type.
Instances
Eq EditableText Source # | |
Defined in GI.Atk.Interfaces.EditableText (==) :: EditableText -> EditableText -> Bool # (/=) :: EditableText -> EditableText -> Bool # | |
ManagedPtrNewtype EditableText Source # | |
Defined in GI.Atk.Interfaces.EditableText | |
BoxedPtr EditableText Source # | |
Defined in GI.Atk.Interfaces.EditableText boxedPtrCopy :: EditableText -> IO EditableText # boxedPtrFree :: EditableText -> IO () # |
class (ManagedPtrNewtype o, IsDescendantOf EditableText o) => IsEditableText o Source #
Type class for types which implement EditableText
.
Instances
(ManagedPtrNewtype o, IsDescendantOf EditableText o) => IsEditableText o Source # | |
Defined in GI.Atk.Interfaces.EditableText |
Methods
Overloaded methods
copyText
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Copy text from startPos
up to, but not including endPos
to the clipboard.
cutText
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Copy text from startPos
up to, but not including endPos
to the clipboard and then delete from the widget.
deleteText
editableTextDeleteText Source #
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Delete text startPos
up to, but not including endPos
.
insertText
editableTextInsertText Source #
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> Text |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Insert text at a given position.
pasteText
editableTextPasteText Source #
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> Int32 |
|
-> m () |
Paste text from clipboard to specified position
.
setRunAttributes
editableTextSetRunAttributes Source #
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> [Ptr ()] |
|
-> Int32 |
|
-> Int32 |
|
-> m Bool | Returns: |
Sets the attributes for a specified range. See the ATK_ATTRIBUTE
macros (such as ATK_ATTRIBUTE_LEFT_MARGIN
) for examples of attributes
that can be set. Note that other attributes that do not have corresponding
ATK_ATTRIBUTE macros may also be set for certain text widgets.
setTextContents
editableTextSetTextContents Source #
:: (HasCallStack, MonadIO m, IsEditableText a) | |
=> a |
|
-> Text |
|
-> m () |
Set text contents of text
.