Copyright | Will Thompson and Iñaki García Etxebarria |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
- Exported types
- Methods
- addChildAtAnchor
- addOverlay
- backwardDisplayLine
- backwardDisplayLineStart
- bufferToWindowCoords
- forwardDisplayLine
- forwardDisplayLineEnd
- getAcceptsTab
- getBottomMargin
- getBuffer
- getCursorLocations
- getCursorVisible
- getEditable
- getExtraMenu
- getGutter
- getIndent
- getInputHints
- getInputPurpose
- getIterAtLocation
- getIterAtPosition
- getIterLocation
- getJustification
- getLeftMargin
- getLineAtY
- getLineYrange
- getLtrContext
- getMonospace
- getOverwrite
- getPixelsAboveLines
- getPixelsBelowLines
- getPixelsInsideWrap
- getRightMargin
- getRtlContext
- getTabs
- getTopMargin
- getVisibleRect
- getWrapMode
- imContextFilterKeypress
- moveMarkOnscreen
- moveOverlay
- moveVisually
- new
- newWithBuffer
- placeCursorOnscreen
- remove
- resetCursorBlink
- resetImContext
- scrollMarkOnscreen
- scrollToIter
- scrollToMark
- setAcceptsTab
- setBottomMargin
- setBuffer
- setCursorVisible
- setEditable
- setExtraMenu
- setGutter
- setIndent
- setInputHints
- setInputPurpose
- setJustification
- setLeftMargin
- setMonospace
- setOverwrite
- setPixelsAboveLines
- setPixelsBelowLines
- setPixelsInsideWrap
- setRightMargin
- setTabs
- setTopMargin
- setWrapMode
- startsDisplayLine
- windowToBufferCoords
- Properties
- Signals
A widget that displays the contents of a TextBuffer
.
You may wish to begin by reading the conceptual overview, which gives an overview of all the objects and data types related to the text widget and how they work together.
CSS nodes
textview.view ├── border.top ├── border.left ├── text │ ╰── [selection] ├── border.right ├── border.bottom ╰── [window.popup]
GtkTextView
has a main css node with name textview and style class .view,
and subnodes for each of the border windows, and the main text area,
with names border and text, respectively. The border nodes each get
one of the style classes .left, .right, .top or .bottom.
A node representing the selection will appear below the text node.
If a context menu is opened, the window node will appear as a subnode of the main node.
Accessibility
GtkTextView
uses the AccessibleRoleTextBox
role.
Synopsis
- newtype TextView = TextView (ManagedPtr TextView)
- class (GObject o, IsDescendantOf TextView o) => IsTextView o
- toTextView :: (MonadIO m, IsTextView o) => o -> m TextView
- textViewAddChildAtAnchor :: (HasCallStack, MonadIO m, IsTextView a, IsWidget b, IsTextChildAnchor c) => a -> b -> c -> m ()
- textViewAddOverlay :: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) => a -> b -> Int32 -> Int32 -> m ()
- textViewBackwardDisplayLine :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m Bool
- textViewBackwardDisplayLineStart :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m Bool
- textViewBufferToWindowCoords :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextWindowType -> Int32 -> Int32 -> m (Int32, Int32)
- textViewForwardDisplayLine :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m Bool
- textViewForwardDisplayLineEnd :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m Bool
- textViewGetAcceptsTab :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Bool
- textViewGetBottomMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetBuffer :: (HasCallStack, MonadIO m, IsTextView a) => a -> m TextBuffer
- textViewGetCursorLocations :: (HasCallStack, MonadIO m, IsTextView a) => a -> Maybe TextIter -> m (Rectangle, Rectangle)
- textViewGetCursorVisible :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Bool
- textViewGetEditable :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Bool
- textViewGetExtraMenu :: (HasCallStack, MonadIO m, IsTextView a) => a -> m MenuModel
- textViewGetGutter :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextWindowType -> m (Maybe Widget)
- textViewGetIndent :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetInputHints :: (HasCallStack, MonadIO m, IsTextView a) => a -> m [InputHints]
- textViewGetInputPurpose :: (HasCallStack, MonadIO m, IsTextView a) => a -> m InputPurpose
- textViewGetIterAtLocation :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> Int32 -> m (Bool, TextIter)
- textViewGetIterAtPosition :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> Int32 -> m (Bool, TextIter, Int32)
- textViewGetIterLocation :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m Rectangle
- textViewGetJustification :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Justification
- textViewGetLeftMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetLineAtY :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m (TextIter, Int32)
- textViewGetLineYrange :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m (Int32, Int32)
- textViewGetLtrContext :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Context
- textViewGetMonospace :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Bool
- textViewGetOverwrite :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Bool
- textViewGetPixelsAboveLines :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetPixelsBelowLines :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetPixelsInsideWrap :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetRightMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetRtlContext :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Context
- textViewGetTabs :: (HasCallStack, MonadIO m, IsTextView a) => a -> m (Maybe TabArray)
- textViewGetTopMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Int32
- textViewGetVisibleRect :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Rectangle
- textViewGetWrapMode :: (HasCallStack, MonadIO m, IsTextView a) => a -> m WrapMode
- textViewImContextFilterKeypress :: (HasCallStack, MonadIO m, IsTextView a, IsEvent b) => a -> b -> m Bool
- textViewMoveMarkOnscreen :: (HasCallStack, MonadIO m, IsTextView a, IsTextMark b) => a -> b -> m Bool
- textViewMoveOverlay :: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) => a -> b -> Int32 -> Int32 -> m ()
- textViewMoveVisually :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> Int32 -> m Bool
- textViewNew :: (HasCallStack, MonadIO m) => m TextView
- textViewNewWithBuffer :: (HasCallStack, MonadIO m, IsTextBuffer a) => a -> m TextView
- textViewPlaceCursorOnscreen :: (HasCallStack, MonadIO m, IsTextView a) => a -> m Bool
- textViewRemove :: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) => a -> b -> m ()
- textViewResetCursorBlink :: (HasCallStack, MonadIO m, IsTextView a) => a -> m ()
- textViewResetImContext :: (HasCallStack, MonadIO m, IsTextView a) => a -> m ()
- textViewScrollMarkOnscreen :: (HasCallStack, MonadIO m, IsTextView a, IsTextMark b) => a -> b -> m ()
- textViewScrollToIter :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> Double -> Bool -> Double -> Double -> m Bool
- textViewScrollToMark :: (HasCallStack, MonadIO m, IsTextView a, IsTextMark b) => a -> b -> Double -> Bool -> Double -> Double -> m ()
- textViewSetAcceptsTab :: (HasCallStack, MonadIO m, IsTextView a) => a -> Bool -> m ()
- textViewSetBottomMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetBuffer :: (HasCallStack, MonadIO m, IsTextView a, IsTextBuffer b) => a -> Maybe b -> m ()
- textViewSetCursorVisible :: (HasCallStack, MonadIO m, IsTextView a) => a -> Bool -> m ()
- textViewSetEditable :: (HasCallStack, MonadIO m, IsTextView a) => a -> Bool -> m ()
- textViewSetExtraMenu :: (HasCallStack, MonadIO m, IsTextView a, IsMenuModel b) => a -> Maybe b -> m ()
- textViewSetGutter :: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) => a -> TextWindowType -> Maybe b -> m ()
- textViewSetIndent :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetInputHints :: (HasCallStack, MonadIO m, IsTextView a) => a -> [InputHints] -> m ()
- textViewSetInputPurpose :: (HasCallStack, MonadIO m, IsTextView a) => a -> InputPurpose -> m ()
- textViewSetJustification :: (HasCallStack, MonadIO m, IsTextView a) => a -> Justification -> m ()
- textViewSetLeftMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetMonospace :: (HasCallStack, MonadIO m, IsTextView a) => a -> Bool -> m ()
- textViewSetOverwrite :: (HasCallStack, MonadIO m, IsTextView a) => a -> Bool -> m ()
- textViewSetPixelsAboveLines :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetPixelsBelowLines :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetPixelsInsideWrap :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetRightMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetTabs :: (HasCallStack, MonadIO m, IsTextView a) => a -> TabArray -> m ()
- textViewSetTopMargin :: (HasCallStack, MonadIO m, IsTextView a) => a -> Int32 -> m ()
- textViewSetWrapMode :: (HasCallStack, MonadIO m, IsTextView a) => a -> WrapMode -> m ()
- textViewStartsDisplayLine :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextIter -> m Bool
- textViewWindowToBufferCoords :: (HasCallStack, MonadIO m, IsTextView a) => a -> TextWindowType -> Int32 -> Int32 -> m (Int32, Int32)
- constructTextViewAcceptsTab :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o)
- getTextViewAcceptsTab :: (MonadIO m, IsTextView o) => o -> m Bool
- setTextViewAcceptsTab :: (MonadIO m, IsTextView o) => o -> Bool -> m ()
- constructTextViewBottomMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewBottomMargin :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewBottomMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- clearTextViewBuffer :: (MonadIO m, IsTextView o) => o -> m ()
- constructTextViewBuffer :: (IsTextView o, MonadIO m, IsTextBuffer a) => a -> m (GValueConstruct o)
- getTextViewBuffer :: (MonadIO m, IsTextView o) => o -> m TextBuffer
- setTextViewBuffer :: (MonadIO m, IsTextView o, IsTextBuffer a) => o -> a -> m ()
- constructTextViewCursorVisible :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o)
- getTextViewCursorVisible :: (MonadIO m, IsTextView o) => o -> m Bool
- setTextViewCursorVisible :: (MonadIO m, IsTextView o) => o -> Bool -> m ()
- constructTextViewEditable :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o)
- getTextViewEditable :: (MonadIO m, IsTextView o) => o -> m Bool
- setTextViewEditable :: (MonadIO m, IsTextView o) => o -> Bool -> m ()
- clearTextViewExtraMenu :: (MonadIO m, IsTextView o) => o -> m ()
- constructTextViewExtraMenu :: (IsTextView o, MonadIO m, IsMenuModel a) => a -> m (GValueConstruct o)
- getTextViewExtraMenu :: (MonadIO m, IsTextView o) => o -> m MenuModel
- setTextViewExtraMenu :: (MonadIO m, IsTextView o, IsMenuModel a) => o -> a -> m ()
- clearTextViewImModule :: (MonadIO m, IsTextView o) => o -> m ()
- constructTextViewImModule :: (IsTextView o, MonadIO m) => Text -> m (GValueConstruct o)
- getTextViewImModule :: (MonadIO m, IsTextView o) => o -> m (Maybe Text)
- setTextViewImModule :: (MonadIO m, IsTextView o) => o -> Text -> m ()
- constructTextViewIndent :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewIndent :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewIndent :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewInputHints :: (IsTextView o, MonadIO m) => [InputHints] -> m (GValueConstruct o)
- getTextViewInputHints :: (MonadIO m, IsTextView o) => o -> m [InputHints]
- setTextViewInputHints :: (MonadIO m, IsTextView o) => o -> [InputHints] -> m ()
- constructTextViewInputPurpose :: (IsTextView o, MonadIO m) => InputPurpose -> m (GValueConstruct o)
- getTextViewInputPurpose :: (MonadIO m, IsTextView o) => o -> m InputPurpose
- setTextViewInputPurpose :: (MonadIO m, IsTextView o) => o -> InputPurpose -> m ()
- constructTextViewJustification :: (IsTextView o, MonadIO m) => Justification -> m (GValueConstruct o)
- getTextViewJustification :: (MonadIO m, IsTextView o) => o -> m Justification
- setTextViewJustification :: (MonadIO m, IsTextView o) => o -> Justification -> m ()
- constructTextViewLeftMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewLeftMargin :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewLeftMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewMonospace :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o)
- getTextViewMonospace :: (MonadIO m, IsTextView o) => o -> m Bool
- setTextViewMonospace :: (MonadIO m, IsTextView o) => o -> Bool -> m ()
- constructTextViewOverwrite :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o)
- getTextViewOverwrite :: (MonadIO m, IsTextView o) => o -> m Bool
- setTextViewOverwrite :: (MonadIO m, IsTextView o) => o -> Bool -> m ()
- constructTextViewPixelsAboveLines :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewPixelsAboveLines :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewPixelsAboveLines :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewPixelsBelowLines :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewPixelsBelowLines :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewPixelsBelowLines :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewPixelsInsideWrap :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewPixelsInsideWrap :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewPixelsInsideWrap :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewRightMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewRightMargin :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewRightMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewTabs :: (IsTextView o, MonadIO m) => TabArray -> m (GValueConstruct o)
- getTextViewTabs :: (MonadIO m, IsTextView o) => o -> m (Maybe TabArray)
- setTextViewTabs :: (MonadIO m, IsTextView o) => o -> TabArray -> m ()
- constructTextViewTopMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o)
- getTextViewTopMargin :: (MonadIO m, IsTextView o) => o -> m Int32
- setTextViewTopMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m ()
- constructTextViewWrapMode :: (IsTextView o, MonadIO m) => WrapMode -> m (GValueConstruct o)
- getTextViewWrapMode :: (MonadIO m, IsTextView o) => o -> m WrapMode
- setTextViewWrapMode :: (MonadIO m, IsTextView o) => o -> WrapMode -> m ()
- type TextViewBackspaceCallback = IO ()
- afterTextViewBackspace :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewBackspaceCallback) -> m SignalHandlerId
- onTextViewBackspace :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewBackspaceCallback) -> m SignalHandlerId
- type TextViewCopyClipboardCallback = IO ()
- afterTextViewCopyClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCopyClipboardCallback) -> m SignalHandlerId
- onTextViewCopyClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCopyClipboardCallback) -> m SignalHandlerId
- type TextViewCutClipboardCallback = IO ()
- afterTextViewCutClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCutClipboardCallback) -> m SignalHandlerId
- onTextViewCutClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCutClipboardCallback) -> m SignalHandlerId
- type TextViewDeleteFromCursorCallback = DeleteType -> Int32 -> IO ()
- afterTextViewDeleteFromCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewDeleteFromCursorCallback) -> m SignalHandlerId
- onTextViewDeleteFromCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewDeleteFromCursorCallback) -> m SignalHandlerId
- type TextViewExtendSelectionCallback = TextExtendSelection -> TextIter -> TextIter -> TextIter -> IO Bool
- afterTextViewExtendSelection :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewExtendSelectionCallback) -> m SignalHandlerId
- onTextViewExtendSelection :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewExtendSelectionCallback) -> m SignalHandlerId
- type TextViewInsertAtCursorCallback = Text -> IO ()
- afterTextViewInsertAtCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertAtCursorCallback) -> m SignalHandlerId
- onTextViewInsertAtCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertAtCursorCallback) -> m SignalHandlerId
- type TextViewInsertEmojiCallback = IO ()
- afterTextViewInsertEmoji :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertEmojiCallback) -> m SignalHandlerId
- onTextViewInsertEmoji :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertEmojiCallback) -> m SignalHandlerId
- type TextViewMoveCursorCallback = MovementStep -> Int32 -> Bool -> IO ()
- afterTextViewMoveCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveCursorCallback) -> m SignalHandlerId
- onTextViewMoveCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveCursorCallback) -> m SignalHandlerId
- type TextViewMoveViewportCallback = ScrollStep -> Int32 -> IO ()
- afterTextViewMoveViewport :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveViewportCallback) -> m SignalHandlerId
- onTextViewMoveViewport :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveViewportCallback) -> m SignalHandlerId
- type TextViewPasteClipboardCallback = IO ()
- afterTextViewPasteClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPasteClipboardCallback) -> m SignalHandlerId
- onTextViewPasteClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPasteClipboardCallback) -> m SignalHandlerId
- type TextViewPreeditChangedCallback = Text -> IO ()
- afterTextViewPreeditChanged :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPreeditChangedCallback) -> m SignalHandlerId
- onTextViewPreeditChanged :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPreeditChangedCallback) -> m SignalHandlerId
- type TextViewSelectAllCallback = Bool -> IO ()
- afterTextViewSelectAll :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSelectAllCallback) -> m SignalHandlerId
- onTextViewSelectAll :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSelectAllCallback) -> m SignalHandlerId
- type TextViewSetAnchorCallback = IO ()
- afterTextViewSetAnchor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSetAnchorCallback) -> m SignalHandlerId
- onTextViewSetAnchor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSetAnchorCallback) -> m SignalHandlerId
- type TextViewToggleCursorVisibleCallback = IO ()
- afterTextViewToggleCursorVisible :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleCursorVisibleCallback) -> m SignalHandlerId
- onTextViewToggleCursorVisible :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleCursorVisibleCallback) -> m SignalHandlerId
- type TextViewToggleOverwriteCallback = IO ()
- afterTextViewToggleOverwrite :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleOverwriteCallback) -> m SignalHandlerId
- onTextViewToggleOverwrite :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleOverwriteCallback) -> m SignalHandlerId
Exported types
Memory-managed wrapper type.
Instances
Eq TextView Source # | |
GObject TextView Source # | |
Defined in GI.Gtk.Objects.TextView | |
ManagedPtrNewtype TextView Source # | |
Defined in GI.Gtk.Objects.TextView toManagedPtr :: TextView -> ManagedPtr TextView | |
TypedObject TextView Source # | |
Defined in GI.Gtk.Objects.TextView | |
HasParentTypes TextView Source # | |
Defined in GI.Gtk.Objects.TextView | |
IsGValue (Maybe TextView) Source # | Convert |
Defined in GI.Gtk.Objects.TextView gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe TextView -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe TextView) | |
type ParentTypes TextView Source # | |
Defined in GI.Gtk.Objects.TextView |
class (GObject o, IsDescendantOf TextView o) => IsTextView o Source #
Type class for types which can be safely cast to TextView
, for instance with toTextView
.
Instances
(GObject o, IsDescendantOf TextView o) => IsTextView o Source # | |
Defined in GI.Gtk.Objects.TextView |
toTextView :: (MonadIO m, IsTextView o) => o -> m TextView Source #
Methods
Click to display all available methods, including inherited ones
Methods
actionSetEnabled, activate, activateAction, activateDefault, addChildAtAnchor, addController, addCssClass, addMnemonicLabel, addOverlay, addTickCallback, allocate, backwardDisplayLine, backwardDisplayLineStart, bindProperty, bindPropertyFull, bufferToWindowCoords, childFocus, computeBounds, computeExpand, computePoint, computeTransform, contains, createPangoContext, createPangoLayout, disposeTemplate, dragCheckThreshold, errorBell, forceFloating, forwardDisplayLine, forwardDisplayLineEnd, freezeNotify, getv, grabFocus, hasCssClass, hasDefault, hasFocus, hasVisibleFocus, hide, imContextFilterKeypress, inDestruction, initTemplate, insertActionGroup, insertAfter, insertBefore, isAncestor, isDrawable, isFloating, isFocus, isSensitive, isVisible, keynavFailed, listMnemonicLabels, map, measure, mnemonicActivate, moveMarkOnscreen, moveOverlay, moveVisually, notify, notifyByPspec, observeChildren, observeControllers, pick, placeCursorOnscreen, queueAllocate, queueDraw, queueResize, realize, ref, refSink, remove, removeController, removeCssClass, removeMnemonicLabel, removeTickCallback, resetCursorBlink, resetImContext, resetProperty, resetRelation, resetState, runDispose, scrollMarkOnscreen, scrollToIter, scrollToMark, shouldLayout, show, sizeAllocate, snapshotChild, startsDisplayLine, stealData, stealQdata, thawNotify, translateCoordinates, triggerTooltipQuery, unmap, unparent, unrealize, unref, unsetStateFlags, updateNextAccessibleSibling, updateProperty, updateRelation, updateState, watchClosure, windowToBufferCoords.
Getters
getAcceptsTab, getAccessibleParent, getAccessibleRole, getAllocatedBaseline, getAllocatedHeight, getAllocatedWidth, getAllocation, getAncestor, getAtContext, getBorder, getBottomMargin, getBounds, getBuffer, getBuildableId, getCanFocus, getCanTarget, getChildVisible, getClipboard, getColor, getCssClasses, getCssName, getCursor, getCursorLocations, getCursorVisible, getData, getDirection, getDisplay, getEditable, getExtraMenu, getFirstAccessibleChild, getFirstChild, getFocusChild, getFocusOnClick, getFocusable, getFontMap, getFontOptions, getFrameClock, getGutter, getHadjustment, getHalign, getHasTooltip, getHeight, getHexpand, getHexpandSet, getHscrollPolicy, getIndent, getInputHints, getInputPurpose, getIterAtLocation, getIterAtPosition, getIterLocation, getJustification, getLastChild, getLayoutManager, getLeftMargin, getLineAtY, getLineYrange, getLtrContext, getMapped, getMarginBottom, getMarginEnd, getMarginStart, getMarginTop, getMonospace, getName, getNative, getNextAccessibleSibling, getNextSibling, getOpacity, getOverflow, getOverwrite, getPangoContext, getParent, getPixelsAboveLines, getPixelsBelowLines, getPixelsInsideWrap, getPlatformState, getPreferredSize, getPrevSibling, getPrimaryClipboard, getProperty, getQdata, getRealized, getReceivesDefault, getRequestMode, getRightMargin, getRoot, getRtlContext, getScaleFactor, getSensitive, getSettings, getSize, getSizeRequest, getStateFlags, getStyleContext, getTabs, getTemplateChild, getTooltipMarkup, getTooltipText, getTopMargin, getVadjustment, getValign, getVexpand, getVexpandSet, getVisible, getVisibleRect, getVscrollPolicy, getWidth, getWrapMode.
Setters
setAcceptsTab, setAccessibleParent, setBottomMargin, setBuffer, setCanFocus, setCanTarget, setChildVisible, setCssClasses, setCursor, setCursorFromName, setCursorVisible, setData, setDataFull, setDirection, setEditable, setExtraMenu, setFocusChild, setFocusOnClick, setFocusable, setFontMap, setFontOptions, setGutter, setHadjustment, setHalign, setHasTooltip, setHexpand, setHexpandSet, setHscrollPolicy, setIndent, setInputHints, setInputPurpose, setJustification, setLayoutManager, setLeftMargin, setMarginBottom, setMarginEnd, setMarginStart, setMarginTop, setMonospace, setName, setOpacity, setOverflow, setOverwrite, setParent, setPixelsAboveLines, setPixelsBelowLines, setPixelsInsideWrap, setProperty, setReceivesDefault, setRightMargin, setSensitive, setSizeRequest, setStateFlags, setTabs, setTooltipMarkup, setTooltipText, setTopMargin, setVadjustment, setValign, setVexpand, setVexpandSet, setVisible, setVscrollPolicy, setWrapMode.
addChildAtAnchor
textViewAddChildAtAnchor Source #
:: (HasCallStack, MonadIO m, IsTextView a, IsWidget b, IsTextChildAnchor c) | |
=> a |
|
-> b |
|
-> c |
|
-> m () |
Adds a child widget in the text buffer, at the given anchor
.
addOverlay
:: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) | |
=> a |
|
-> b |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Adds child
at a fixed coordinate in the GtkTextView
's text window.
The xpos
and ypos
must be in buffer coordinates (see
textViewGetIterLocation
to convert to
buffer coordinates).
child
will scroll with the text view.
If instead you want a widget that will not move with the
GtkTextView
contents see GtkOverlay
.
backwardDisplayLine
textViewBackwardDisplayLine Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m Bool | Returns: |
Moves the given iter
backward by one display (wrapped) line.
A display line is different from a paragraph. Paragraphs are
separated by newlines or other paragraph separator characters.
Display lines are created by line-wrapping a paragraph. If
wrapping is turned off, display lines and paragraphs will be the
same. Display lines are divided differently for each view, since
they depend on the view’s width; paragraphs are the same in all
views, since they depend on the contents of the GtkTextBuffer
.
backwardDisplayLineStart
textViewBackwardDisplayLineStart Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m Bool | Returns: |
Moves the given iter
backward to the next display line start.
A display line is different from a paragraph. Paragraphs are
separated by newlines or other paragraph separator characters.
Display lines are created by line-wrapping a paragraph. If
wrapping is turned off, display lines and paragraphs will be the
same. Display lines are divided differently for each view, since
they depend on the view’s width; paragraphs are the same in all
views, since they depend on the contents of the GtkTextBuffer
.
bufferToWindowCoords
textViewBufferToWindowCoords Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextWindowType |
|
-> Int32 |
|
-> Int32 |
|
-> m (Int32, Int32) |
Converts buffer coordinates to window coordinates.
forwardDisplayLine
textViewForwardDisplayLine Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m Bool | Returns: |
Moves the given iter
forward by one display (wrapped) line.
A display line is different from a paragraph. Paragraphs are
separated by newlines or other paragraph separator characters.
Display lines are created by line-wrapping a paragraph. If
wrapping is turned off, display lines and paragraphs will be the
same. Display lines are divided differently for each view, since
they depend on the view’s width; paragraphs are the same in all
views, since they depend on the contents of the GtkTextBuffer
.
forwardDisplayLineEnd
textViewForwardDisplayLineEnd Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m Bool | Returns: |
Moves the given iter
forward to the next display line end.
A display line is different from a paragraph. Paragraphs are
separated by newlines or other paragraph separator characters.
Display lines are created by line-wrapping a paragraph. If
wrapping is turned off, display lines and paragraphs will be the
same. Display lines are divided differently for each view, since
they depend on the view’s width; paragraphs are the same in all
views, since they depend on the contents of the GtkTextBuffer
.
getAcceptsTab
textViewGetAcceptsTab Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Bool | Returns: |
Returns whether pressing the <kbd>Tab</kbd> key inserts a tab characters.
getBottomMargin
textViewGetBottomMargin Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: bottom margin in pixels |
Gets the bottom margin for text in the textView
.
getBuffer
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m TextBuffer | Returns: a |
Returns the GtkTextBuffer
being displayed by this text view.
The reference count on the buffer is not incremented; the caller of this function won’t own a new reference.
getCursorLocations
textViewGetCursorLocations Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Maybe TextIter |
|
-> m (Rectangle, Rectangle) |
Determine the positions of the strong and weak cursors if the
insertion point is at iter
.
The position of each cursor is stored as a zero-width rectangle. The strong cursor location is the location where characters of the directionality equal to the base direction of the paragraph are inserted. The weak cursor location is the location where characters of the directionality opposite to the base direction of the paragraph are inserted.
If iter
is Nothing
, the actual cursor position is used.
Note that if iter
happens to be the actual cursor position, and
there is currently an IM preedit sequence being entered, the
returned locations will be adjusted to account for the preedit
cursor’s offset within the preedit sequence.
The rectangle position is in buffer coordinates; use
textViewBufferToWindowCoords
to convert these
coordinates to coordinates for one of the windows in the text view.
getCursorVisible
textViewGetCursorVisible Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Bool | Returns: whether the insertion mark is visible |
Find out whether the cursor should be displayed.
getEditable
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Bool | Returns: whether text is editable by default |
Returns the default editability of the GtkTextView
.
Tags in the buffer may override this setting for some ranges of text.
getExtraMenu
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m MenuModel | Returns: the menu model |
Gets the menu model that gets added to the context menu
or Nothing
if none has been set.
getGutter
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextWindowType |
|
-> m (Maybe Widget) | Returns: a |
Gets a GtkWidget
that has previously been set as gutter.
See textViewSetGutter
.
win
must be one of TextWindowTypeLeft
, TextWindowTypeRight
,
TextWindowTypeTop
, or TextWindowTypeBottom
.
getIndent
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: number of pixels of indentation |
Gets the default indentation of paragraphs in textView
.
Tags in the view’s buffer may override the default. The indentation may be negative.
getInputHints
textViewGetInputHints Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m [InputHints] |
Gets the input-hints
of the GtkTextView
.
getInputPurpose
textViewGetInputPurpose Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m InputPurpose |
Gets the input-purpose
of the GtkTextView
.
getIterAtLocation
textViewGetIterAtLocation Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m (Bool, TextIter) | Returns: |
Retrieves the iterator at buffer coordinates x
and y
.
Buffer coordinates are coordinates for the entire buffer, not just
the currently-displayed portion. If you have coordinates from an
event, you have to convert those to buffer coordinates with
textViewWindowToBufferCoords
.
getIterAtPosition
textViewGetIterAtPosition Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m (Bool, TextIter, Int32) | Returns: |
Retrieves the iterator pointing to the character at buffer
coordinates x
and y
.
Buffer coordinates are coordinates for the entire buffer, not just
the currently-displayed portion. If you have coordinates from an event,
you have to convert those to buffer coordinates with
textViewWindowToBufferCoords
.
Note that this is different from textViewGetIterAtLocation
,
which returns cursor locations, i.e. positions between characters.
getIterLocation
textViewGetIterLocation Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m Rectangle |
Gets a rectangle which roughly contains the character at iter
.
The rectangle position is in buffer coordinates; use
textViewBufferToWindowCoords
to convert these
coordinates to coordinates for one of the windows in the text view.
getJustification
textViewGetJustification Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Justification | Returns: default justification |
Gets the default justification of paragraphs in textView
.
Tags in the buffer may override the default.
getLeftMargin
textViewGetLeftMargin Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: left margin in pixels |
Gets the default left margin size of paragraphs in the textView
.
Tags in the buffer may override the default.
getLineAtY
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m (TextIter, Int32) |
Gets the GtkTextIter
at the start of the line containing
the coordinate y
.
y
is in buffer coordinates, convert from window coordinates with
textViewWindowToBufferCoords
. If non-Nothing
,
lineTop
will be filled with the coordinate of the top edge
of the line.
getLineYrange
textViewGetLineYrange Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m (Int32, Int32) |
Gets the y coordinate of the top of the line containing iter
,
and the height of the line.
The coordinate is a buffer coordinate; convert to window
coordinates with textViewBufferToWindowCoords
.
getLtrContext
textViewGetLtrContext Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Context | Returns: a |
Gets the PangoContext
that is used for rendering LTR directed
text layouts.
The context may be replaced when CSS changes occur.
Since: 4.4
getMonospace
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Bool | Returns: |
Gets whether the GtkTextView
uses monospace styling.
getOverwrite
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Bool | Returns: whether |
Returns whether the GtkTextView
is in overwrite mode or not.
getPixelsAboveLines
textViewGetPixelsAboveLines Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: default number of pixels above paragraphs |
Gets the default number of pixels to put above paragraphs.
Adding this function with textViewGetPixelsBelowLines
is equal to the line space between each paragraph.
getPixelsBelowLines
textViewGetPixelsBelowLines Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: default number of blank pixels below paragraphs |
Gets the default number of pixels to put below paragraphs.
The line space is the sum of the value returned by this function and
the value returned by textViewGetPixelsAboveLines
.
getPixelsInsideWrap
textViewGetPixelsInsideWrap Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: default number of pixels of blank space between wrapped lines |
Gets the default number of pixels to put between wrapped lines inside a paragraph.
getRightMargin
textViewGetRightMargin Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: right margin in pixels |
Gets the default right margin for text in textView
.
Tags in the buffer may override the default.
getRtlContext
textViewGetRtlContext Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Context | Returns: a |
Gets the PangoContext
that is used for rendering RTL directed
text layouts.
The context may be replaced when CSS changes occur.
Since: 4.4
getTabs
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m (Maybe TabArray) | Returns: copy of default tab array,
or |
Gets the default tabs for textView
.
Tags in the buffer may override the defaults. The returned array
will be Nothing
if “standard” (8-space) tabs are used. Free the
return value with tabArrayFree
.
getTopMargin
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Int32 | Returns: top margin in pixels |
Gets the top margin for text in the textView
.
getVisibleRect
textViewGetVisibleRect Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Rectangle |
Fills visibleRect
with the currently-visible
region of the buffer, in buffer coordinates.
Convert to window coordinates with
textViewBufferToWindowCoords
.
getWrapMode
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m WrapMode | Returns: the line wrap setting |
Gets the line wrapping for the view.
imContextFilterKeypress
textViewImContextFilterKeypress Source #
:: (HasCallStack, MonadIO m, IsTextView a, IsEvent b) | |
=> a |
|
-> b |
|
-> m Bool | Returns: |
Allow the GtkTextView
input method to internally handle key press
and release events.
If this function returns True
, then no further processing should be
done for this key event. See iMContextFilterKeypress
.
Note that you are expected to call this function from your handler
when overriding key event handling. This is needed in the case when
you need to insert your own key handling between the input method
and the default key event handling of the GtkTextView
.
c code
static gboolean gtk_foo_bar_key_press_event (GtkWidget *widget, GdkEvent *event) { guint keyval; gdk_event_get_keyval ((GdkEvent*)event, &keyval); if (keyval == GDK_KEY_Return || keyval == GDK_KEY_KP_Enter) { if (gtk_text_view_im_context_filter_keypress (GTK_TEXT_VIEW (widget), event)) return TRUE; } // Do some stuff return GTK_WIDGET_CLASS (gtk_foo_bar_parent_class)->key_press_event (widget, event); }
moveMarkOnscreen
textViewMoveMarkOnscreen Source #
:: (HasCallStack, MonadIO m, IsTextView a, IsTextMark b) | |
=> a |
|
-> b |
|
-> m Bool | Returns: |
Moves a mark within the buffer so that it's located within the currently-visible text area.
moveOverlay
:: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) | |
=> a |
|
-> b |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Updates the position of a child.
See textViewAddOverlay
.
moveVisually
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> Int32 |
|
-> m Bool | Returns: |
Move the iterator a given number of characters visually, treating it as the strong cursor position.
If count
is positive, then the new strong cursor position will
be count
positions to the right of the old cursor position.
If count
is negative then the new strong cursor position will
be count
positions to the left of the old cursor position.
In the presence of bi-directional text, the correspondence between logical and visual order will depend on the direction of the current run, and there may be jumps when the cursor is moved off of the end of a run.
new
:: (HasCallStack, MonadIO m) | |
=> m TextView | Returns: a new |
Creates a new GtkTextView
.
If you don’t call textViewSetBuffer
before using the
text view, an empty default buffer will be created for you. Get the
buffer with textViewGetBuffer
. If you want to specify
your own buffer, consider textViewNewWithBuffer
.
newWithBuffer
textViewNewWithBuffer Source #
:: (HasCallStack, MonadIO m, IsTextBuffer a) | |
=> a |
|
-> m TextView | Returns: a new |
Creates a new GtkTextView
widget displaying the buffer buffer
.
One buffer can be shared among many widgets. buffer
may be Nothing
to create a default buffer, in which case this function is equivalent
to textViewNew
. The text view adds its own reference count
to the buffer; it does not take over an existing reference.
placeCursorOnscreen
textViewPlaceCursorOnscreen Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m Bool | Returns: |
Moves the cursor to the currently visible region of the buffer.
remove
:: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) | |
=> a |
|
-> b |
|
-> m () |
Removes a child widget from textView
.
resetCursorBlink
textViewResetCursorBlink Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m () |
Ensures that the cursor is shown.
This also resets the time that it will stay blinking (or visible, in case blinking is disabled).
This function should be called in response to user input (e.g. from derived classes that override the textview's event handlers).
resetImContext
textViewResetImContext Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> m () |
Reset the input method context of the text view if needed.
This can be necessary in the case where modifying the buffer would confuse on-going input method behavior.
scrollMarkOnscreen
textViewScrollMarkOnscreen Source #
:: (HasCallStack, MonadIO m, IsTextView a, IsTextMark b) | |
=> a |
|
-> b |
|
-> m () |
Scrolls textView
the minimum distance such that mark
is contained
within the visible area of the widget.
scrollToIter
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> Double |
|
-> Bool |
|
-> Double |
|
-> Double |
|
-> m Bool | Returns: |
Scrolls textView
so that iter
is on the screen in the position
indicated by xalign
and yalign
.
An alignment of 0.0 indicates left or top, 1.0 indicates right or
bottom, 0.5 means center. If useAlign
is False
, the text scrolls
the minimal distance to get the mark onscreen, possibly not scrolling
at all. The effective screen for purposes of this function is reduced
by a margin of size withinMargin
.
Note that this function uses the currently-computed height of the
lines in the text buffer. Line heights are computed in an idle
handler; so this function may not have the desired effect if it’s
called before the height computations. To avoid oddness, consider
using textViewScrollToMark
which saves a point to be
scrolled to after line validation.
scrollToMark
:: (HasCallStack, MonadIO m, IsTextView a, IsTextMark b) | |
=> a |
|
-> b |
|
-> Double |
|
-> Bool |
|
-> Double |
|
-> Double |
|
-> m () |
Scrolls textView
so that mark
is on the screen in the position
indicated by xalign
and yalign
.
An alignment of 0.0 indicates left or top, 1.0 indicates right or
bottom, 0.5 means center. If useAlign
is False
, the text scrolls
the minimal distance to get the mark onscreen, possibly not scrolling
at all. The effective screen for purposes of this function is reduced
by a margin of size withinMargin
.
setAcceptsTab
textViewSetAcceptsTab Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Bool |
|
-> m () |
setBottomMargin
textViewSetBottomMargin Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the bottom margin for text in textView
.
Note that this function is confusingly named. In CSS terms, the value set here is padding.
setBuffer
:: (HasCallStack, MonadIO m, IsTextView a, IsTextBuffer b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets buffer
as the buffer being displayed by textView
.
The previous buffer displayed by the text view is unreferenced, and
a reference is added to buffer
. If you owned a reference to buffer
before passing it to this function, you must remove that reference
yourself; GtkTextView
will not “adopt” it.
setCursorVisible
textViewSetCursorVisible Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Bool |
|
-> m () |
Toggles whether the insertion point should be displayed.
A buffer with no editable text probably shouldn’t have a visible cursor, so you may want to turn the cursor off.
Note that this property may be overridden by the Settings:gtkKeynavUseCaret setting.
setEditable
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets the default editability of the GtkTextView
.
You can override this default setting with tags in the buffer, using the “editable” attribute of tags.
setExtraMenu
:: (HasCallStack, MonadIO m, IsTextView a, IsMenuModel b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets a menu model to add when constructing the context
menu for textView
.
You can pass Nothing
to remove a previously set extra menu.
setGutter
:: (HasCallStack, MonadIO m, IsTextView a, IsWidget b) | |
=> a |
|
-> TextWindowType |
|
-> Maybe b |
|
-> m () |
Places widget
into the gutter specified by win
.
win
must be one of TextWindowTypeLeft
, TextWindowTypeRight
,
TextWindowTypeTop
, or TextWindowTypeBottom
.
setIndent
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the default indentation for paragraphs in textView
.
Tags in the buffer may override the default.
setInputHints
textViewSetInputHints Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> [InputHints] |
|
-> m () |
Sets the input-hints
of the GtkTextView
.
The input-hints
allow input methods to fine-tune
their behaviour.
setInputPurpose
textViewSetInputPurpose Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> InputPurpose |
|
-> m () |
Sets the input-purpose
of the GtkTextView
.
The input-purpose
can be used by on-screen keyboards
and other input methods to adjust their behaviour.
setJustification
textViewSetJustification Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Justification |
|
-> m () |
Sets the default justification of text in textView
.
Tags in the view’s buffer may override the default.
setLeftMargin
textViewSetLeftMargin Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the default left margin for text in textView
.
Tags in the buffer may override the default.
Note that this function is confusingly named. In CSS terms, the value set here is padding.
setMonospace
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether the GtkTextView
should display text in
monospace styling.
setOverwrite
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Bool |
|
-> m () |
Changes the GtkTextView
overwrite mode.
setPixelsAboveLines
textViewSetPixelsAboveLines Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the default number of blank pixels above paragraphs in textView
.
Tags in the buffer for textView
may override the defaults.
setPixelsBelowLines
textViewSetPixelsBelowLines Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the default number of pixels of blank space
to put below paragraphs in textView
.
May be overridden by tags applied to textView
’s buffer.
setPixelsInsideWrap
textViewSetPixelsInsideWrap Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the default number of pixels of blank space to leave between display/wrapped lines within a paragraph.
May be overridden by tags in textView
’s buffer.
setRightMargin
textViewSetRightMargin Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the default right margin for text in the text view.
Tags in the buffer may override the default.
Note that this function is confusingly named. In CSS terms, the value set here is padding.
setTabs
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TabArray |
|
-> m () |
Sets the default tab stops for paragraphs in textView
.
Tags in the buffer may override the default.
setTopMargin
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> Int32 |
|
-> m () |
Sets the top margin for text in textView
.
Note that this function is confusingly named. In CSS terms, the value set here is padding.
setWrapMode
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> WrapMode |
|
-> m () |
Sets the line wrapping for the view.
startsDisplayLine
textViewStartsDisplayLine Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextIter |
|
-> m Bool | Returns: |
Determines whether iter
is at the start of a display line.
See textViewForwardDisplayLine
for an
explanation of display lines vs. paragraphs.
windowToBufferCoords
textViewWindowToBufferCoords Source #
:: (HasCallStack, MonadIO m, IsTextView a) | |
=> a |
|
-> TextWindowType |
|
-> Int32 |
|
-> Int32 |
|
-> m (Int32, Int32) |
Converts coordinates on the window identified by win
to buffer
coordinates.
Properties
acceptsTab
Whether Tab will result in a tab character being entered.
constructTextViewAcceptsTab :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “accepts-tab
” property. This is rarely needed directly, but it is used by new
.
getTextViewAcceptsTab :: (MonadIO m, IsTextView o) => o -> m Bool Source #
Get the value of the “accepts-tab
” property.
When overloading is enabled, this is equivalent to
get
textView #acceptsTab
setTextViewAcceptsTab :: (MonadIO m, IsTextView o) => o -> Bool -> m () Source #
Set the value of the “accepts-tab
” property.
When overloading is enabled, this is equivalent to
set
textView [ #acceptsTab:=
value ]
bottomMargin
The bottom margin for text in the text view.
Note that this property is confusingly named. In CSS terms, the value set here is padding, and it is applied in addition to the padding from the theme.
Don't confuse this property with Widget:marginBottom.
constructTextViewBottomMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “bottom-margin
” property. This is rarely needed directly, but it is used by new
.
getTextViewBottomMargin :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “bottom-margin
” property.
When overloading is enabled, this is equivalent to
get
textView #bottomMargin
setTextViewBottomMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “bottom-margin
” property.
When overloading is enabled, this is equivalent to
set
textView [ #bottomMargin:=
value ]
buffer
The buffer which is displayed.
clearTextViewBuffer :: (MonadIO m, IsTextView o) => o -> m () Source #
Set the value of the “buffer
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#buffer
constructTextViewBuffer :: (IsTextView o, MonadIO m, IsTextBuffer a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “buffer
” property. This is rarely needed directly, but it is used by new
.
getTextViewBuffer :: (MonadIO m, IsTextView o) => o -> m TextBuffer Source #
Get the value of the “buffer
” property.
When overloading is enabled, this is equivalent to
get
textView #buffer
setTextViewBuffer :: (MonadIO m, IsTextView o, IsTextBuffer a) => o -> a -> m () Source #
Set the value of the “buffer
” property.
When overloading is enabled, this is equivalent to
set
textView [ #buffer:=
value ]
cursorVisible
If the insertion cursor is shown.
constructTextViewCursorVisible :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “cursor-visible
” property. This is rarely needed directly, but it is used by new
.
getTextViewCursorVisible :: (MonadIO m, IsTextView o) => o -> m Bool Source #
Get the value of the “cursor-visible
” property.
When overloading is enabled, this is equivalent to
get
textView #cursorVisible
setTextViewCursorVisible :: (MonadIO m, IsTextView o) => o -> Bool -> m () Source #
Set the value of the “cursor-visible
” property.
When overloading is enabled, this is equivalent to
set
textView [ #cursorVisible:=
value ]
editable
No description available in the introspection data.
constructTextViewEditable :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “editable
” property. This is rarely needed directly, but it is used by new
.
getTextViewEditable :: (MonadIO m, IsTextView o) => o -> m Bool Source #
Get the value of the “editable
” property.
When overloading is enabled, this is equivalent to
get
textView #editable
setTextViewEditable :: (MonadIO m, IsTextView o) => o -> Bool -> m () Source #
Set the value of the “editable
” property.
When overloading is enabled, this is equivalent to
set
textView [ #editable:=
value ]
extraMenu
A menu model whose contents will be appended to the context menu.
clearTextViewExtraMenu :: (MonadIO m, IsTextView o) => o -> m () Source #
Set the value of the “extra-menu
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#extraMenu
constructTextViewExtraMenu :: (IsTextView o, MonadIO m, IsMenuModel a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “extra-menu
” property. This is rarely needed directly, but it is used by new
.
getTextViewExtraMenu :: (MonadIO m, IsTextView o) => o -> m MenuModel Source #
Get the value of the “extra-menu
” property.
When overloading is enabled, this is equivalent to
get
textView #extraMenu
setTextViewExtraMenu :: (MonadIO m, IsTextView o, IsMenuModel a) => o -> a -> m () Source #
Set the value of the “extra-menu
” property.
When overloading is enabled, this is equivalent to
set
textView [ #extraMenu:=
value ]
imModule
Which IM (input method) module should be used for this text_view.
See IMMulticontext
.
Setting this to a non-Nothing
value overrides the system-wide IM module
setting. See the GtkSettings Settings:gtkImModule property.
clearTextViewImModule :: (MonadIO m, IsTextView o) => o -> m () Source #
Set the value of the “im-module
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#imModule
constructTextViewImModule :: (IsTextView o, MonadIO m) => Text -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “im-module
” property. This is rarely needed directly, but it is used by new
.
getTextViewImModule :: (MonadIO m, IsTextView o) => o -> m (Maybe Text) Source #
Get the value of the “im-module
” property.
When overloading is enabled, this is equivalent to
get
textView #imModule
setTextViewImModule :: (MonadIO m, IsTextView o) => o -> Text -> m () Source #
Set the value of the “im-module
” property.
When overloading is enabled, this is equivalent to
set
textView [ #imModule:=
value ]
indent
Amount to indent the paragraph, in pixels.
A negative value of indent will produce a hanging indentation. That is, the first line will have the full width, and subsequent lines will be indented by the absolute value of indent.
constructTextViewIndent :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “indent
” property. This is rarely needed directly, but it is used by new
.
getTextViewIndent :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “indent
” property.
When overloading is enabled, this is equivalent to
get
textView #indent
setTextViewIndent :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “indent
” property.
When overloading is enabled, this is equivalent to
set
textView [ #indent:=
value ]
inputHints
Additional hints (beyond TextView:inputPurpose) that allow input methods to fine-tune their behaviour.
constructTextViewInputHints :: (IsTextView o, MonadIO m) => [InputHints] -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “input-hints
” property. This is rarely needed directly, but it is used by new
.
getTextViewInputHints :: (MonadIO m, IsTextView o) => o -> m [InputHints] Source #
Get the value of the “input-hints
” property.
When overloading is enabled, this is equivalent to
get
textView #inputHints
setTextViewInputHints :: (MonadIO m, IsTextView o) => o -> [InputHints] -> m () Source #
Set the value of the “input-hints
” property.
When overloading is enabled, this is equivalent to
set
textView [ #inputHints:=
value ]
inputPurpose
The purpose of this text field.
This property can be used by on-screen keyboards and other input methods to adjust their behaviour.
constructTextViewInputPurpose :: (IsTextView o, MonadIO m) => InputPurpose -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “input-purpose
” property. This is rarely needed directly, but it is used by new
.
getTextViewInputPurpose :: (MonadIO m, IsTextView o) => o -> m InputPurpose Source #
Get the value of the “input-purpose
” property.
When overloading is enabled, this is equivalent to
get
textView #inputPurpose
setTextViewInputPurpose :: (MonadIO m, IsTextView o) => o -> InputPurpose -> m () Source #
Set the value of the “input-purpose
” property.
When overloading is enabled, this is equivalent to
set
textView [ #inputPurpose:=
value ]
justification
No description available in the introspection data.
constructTextViewJustification :: (IsTextView o, MonadIO m) => Justification -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “justification
” property. This is rarely needed directly, but it is used by new
.
getTextViewJustification :: (MonadIO m, IsTextView o) => o -> m Justification Source #
Get the value of the “justification
” property.
When overloading is enabled, this is equivalent to
get
textView #justification
setTextViewJustification :: (MonadIO m, IsTextView o) => o -> Justification -> m () Source #
Set the value of the “justification
” property.
When overloading is enabled, this is equivalent to
set
textView [ #justification:=
value ]
leftMargin
The default left margin for text in the text view.
Tags in the buffer may override the default.
Note that this property is confusingly named. In CSS terms, the value set here is padding, and it is applied in addition to the padding from the theme.
constructTextViewLeftMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “left-margin
” property. This is rarely needed directly, but it is used by new
.
getTextViewLeftMargin :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “left-margin
” property.
When overloading is enabled, this is equivalent to
get
textView #leftMargin
setTextViewLeftMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “left-margin
” property.
When overloading is enabled, this is equivalent to
set
textView [ #leftMargin:=
value ]
monospace
Whether text should be displayed in a monospace font.
If True
, set the .monospace style class on the
text view to indicate that a monospace font is desired.
constructTextViewMonospace :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “monospace
” property. This is rarely needed directly, but it is used by new
.
getTextViewMonospace :: (MonadIO m, IsTextView o) => o -> m Bool Source #
Get the value of the “monospace
” property.
When overloading is enabled, this is equivalent to
get
textView #monospace
setTextViewMonospace :: (MonadIO m, IsTextView o) => o -> Bool -> m () Source #
Set the value of the “monospace
” property.
When overloading is enabled, this is equivalent to
set
textView [ #monospace:=
value ]
overwrite
Whether entered text overwrites existing contents.
constructTextViewOverwrite :: (IsTextView o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “overwrite
” property. This is rarely needed directly, but it is used by new
.
getTextViewOverwrite :: (MonadIO m, IsTextView o) => o -> m Bool Source #
Get the value of the “overwrite
” property.
When overloading is enabled, this is equivalent to
get
textView #overwrite
setTextViewOverwrite :: (MonadIO m, IsTextView o) => o -> Bool -> m () Source #
Set the value of the “overwrite
” property.
When overloading is enabled, this is equivalent to
set
textView [ #overwrite:=
value ]
pixelsAboveLines
No description available in the introspection data.
constructTextViewPixelsAboveLines :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “pixels-above-lines
” property. This is rarely needed directly, but it is used by new
.
getTextViewPixelsAboveLines :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “pixels-above-lines
” property.
When overloading is enabled, this is equivalent to
get
textView #pixelsAboveLines
setTextViewPixelsAboveLines :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “pixels-above-lines
” property.
When overloading is enabled, this is equivalent to
set
textView [ #pixelsAboveLines:=
value ]
pixelsBelowLines
No description available in the introspection data.
constructTextViewPixelsBelowLines :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “pixels-below-lines
” property. This is rarely needed directly, but it is used by new
.
getTextViewPixelsBelowLines :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “pixels-below-lines
” property.
When overloading is enabled, this is equivalent to
get
textView #pixelsBelowLines
setTextViewPixelsBelowLines :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “pixels-below-lines
” property.
When overloading is enabled, this is equivalent to
set
textView [ #pixelsBelowLines:=
value ]
pixelsInsideWrap
No description available in the introspection data.
constructTextViewPixelsInsideWrap :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “pixels-inside-wrap
” property. This is rarely needed directly, but it is used by new
.
getTextViewPixelsInsideWrap :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “pixels-inside-wrap
” property.
When overloading is enabled, this is equivalent to
get
textView #pixelsInsideWrap
setTextViewPixelsInsideWrap :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “pixels-inside-wrap
” property.
When overloading is enabled, this is equivalent to
set
textView [ #pixelsInsideWrap:=
value ]
rightMargin
The default right margin for text in the text view.
Tags in the buffer may override the default.
Note that this property is confusingly named. In CSS terms, the value set here is padding, and it is applied in addition to the padding from the theme.
constructTextViewRightMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “right-margin
” property. This is rarely needed directly, but it is used by new
.
getTextViewRightMargin :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “right-margin
” property.
When overloading is enabled, this is equivalent to
get
textView #rightMargin
setTextViewRightMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “right-margin
” property.
When overloading is enabled, this is equivalent to
set
textView [ #rightMargin:=
value ]
tabs
No description available in the introspection data.
constructTextViewTabs :: (IsTextView o, MonadIO m) => TabArray -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “tabs
” property. This is rarely needed directly, but it is used by new
.
getTextViewTabs :: (MonadIO m, IsTextView o) => o -> m (Maybe TabArray) Source #
Get the value of the “tabs
” property.
When overloading is enabled, this is equivalent to
get
textView #tabs
setTextViewTabs :: (MonadIO m, IsTextView o) => o -> TabArray -> m () Source #
Set the value of the “tabs
” property.
When overloading is enabled, this is equivalent to
set
textView [ #tabs:=
value ]
topMargin
The top margin for text in the text view.
Note that this property is confusingly named. In CSS terms, the value set here is padding, and it is applied in addition to the padding from the theme.
Don't confuse this property with Widget:marginTop.
constructTextViewTopMargin :: (IsTextView o, MonadIO m) => Int32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “top-margin
” property. This is rarely needed directly, but it is used by new
.
getTextViewTopMargin :: (MonadIO m, IsTextView o) => o -> m Int32 Source #
Get the value of the “top-margin
” property.
When overloading is enabled, this is equivalent to
get
textView #topMargin
setTextViewTopMargin :: (MonadIO m, IsTextView o) => o -> Int32 -> m () Source #
Set the value of the “top-margin
” property.
When overloading is enabled, this is equivalent to
set
textView [ #topMargin:=
value ]
wrapMode
No description available in the introspection data.
constructTextViewWrapMode :: (IsTextView o, MonadIO m) => WrapMode -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “wrap-mode
” property. This is rarely needed directly, but it is used by new
.
getTextViewWrapMode :: (MonadIO m, IsTextView o) => o -> m WrapMode Source #
Get the value of the “wrap-mode
” property.
When overloading is enabled, this is equivalent to
get
textView #wrapMode
setTextViewWrapMode :: (MonadIO m, IsTextView o) => o -> WrapMode -> m () Source #
Set the value of the “wrap-mode
” property.
When overloading is enabled, this is equivalent to
set
textView [ #wrapMode:=
value ]
Signals
backspace
type TextViewBackspaceCallback = IO () Source #
Gets emitted when the user asks for it.
The backspace signal is a keybinding signal.
The default bindings for this signal are <kbd>Backspace</kbd> and <kbd>Shift</kbd>+<kbd>Backspace</kbd>.
afterTextViewBackspace :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewBackspaceCallback) -> m SignalHandlerId Source #
Connect a signal handler for the backspace signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #backspace callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewBackspace :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewBackspaceCallback) -> m SignalHandlerId Source #
Connect a signal handler for the backspace signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #backspace callback
copyClipboard
type TextViewCopyClipboardCallback = IO () Source #
Gets emitted to copy the selection to the clipboard.
The copyClipboard signal is a keybinding signal.
The default bindings for this signal are <kbd>Ctrl</kbd>+<kbd>c</kbd> and <kbd>Ctrl</kbd>+<kbd>Insert</kbd>.
afterTextViewCopyClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCopyClipboardCallback) -> m SignalHandlerId Source #
Connect a signal handler for the copyClipboard signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #copyClipboard callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewCopyClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCopyClipboardCallback) -> m SignalHandlerId Source #
Connect a signal handler for the copyClipboard signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #copyClipboard callback
cutClipboard
type TextViewCutClipboardCallback = IO () Source #
Gets emitted to cut the selection to the clipboard.
The cutClipboard signal is a keybinding signal.
The default bindings for this signal are <kbd>Ctrl</kbd>+<kbd>x</kbd> and <kbd>Shift</kbd>+<kbd>Delete</kbd>.
afterTextViewCutClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCutClipboardCallback) -> m SignalHandlerId Source #
Connect a signal handler for the cutClipboard signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #cutClipboard callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewCutClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewCutClipboardCallback) -> m SignalHandlerId Source #
Connect a signal handler for the cutClipboard signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #cutClipboard callback
deleteFromCursor
type TextViewDeleteFromCursorCallback Source #
= DeleteType |
|
-> Int32 |
|
-> IO () |
Gets emitted when the user initiates a text deletion.
The deleteFromCursor signal is a keybinding signal.
If the type
is DeleteTypeChars
, GTK deletes the selection
if there is one, otherwise it deletes the requested number
of characters.
The default bindings for this signal are <kbd>Delete</kbd> for deleting a character, <kbd>Ctrl</kbd>+<kbd>Delete</kbd> for deleting a word and <kbd>Ctrl</kbd>+<kbd>Backspace</kbd> for deleting a word backwards.
afterTextViewDeleteFromCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewDeleteFromCursorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the deleteFromCursor signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #deleteFromCursor callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewDeleteFromCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewDeleteFromCursorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the deleteFromCursor signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #deleteFromCursor callback
extendSelection
type TextViewExtendSelectionCallback Source #
= TextExtendSelection |
|
-> TextIter |
|
-> TextIter |
|
-> TextIter |
|
-> IO Bool | Returns: |
Emitted when the selection needs to be extended at location
.
afterTextViewExtendSelection :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewExtendSelectionCallback) -> m SignalHandlerId Source #
Connect a signal handler for the extendSelection signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #extendSelection callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewExtendSelection :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewExtendSelectionCallback) -> m SignalHandlerId Source #
Connect a signal handler for the extendSelection signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #extendSelection callback
insertAtCursor
type TextViewInsertAtCursorCallback Source #
Gets emitted when the user initiates the insertion of a fixed string at the cursor.
The insertAtCursor signal is a keybinding signal.
This signal has no default bindings.
afterTextViewInsertAtCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertAtCursorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the insertAtCursor signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #insertAtCursor callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewInsertAtCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertAtCursorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the insertAtCursor signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #insertAtCursor callback
insertEmoji
type TextViewInsertEmojiCallback = IO () Source #
Gets emitted to present the Emoji chooser for the textView
.
The insertEmoji signal is a keybinding signal.
The default bindings for this signal are <kbd>Ctrl</kbd>+<kbd>.</kbd> and <kbd>Ctrl</kbd>+<kbd>;</kbd>
afterTextViewInsertEmoji :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertEmojiCallback) -> m SignalHandlerId Source #
Connect a signal handler for the insertEmoji signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #insertEmoji callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewInsertEmoji :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewInsertEmojiCallback) -> m SignalHandlerId Source #
Connect a signal handler for the insertEmoji signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #insertEmoji callback
moveCursor
type TextViewMoveCursorCallback Source #
= MovementStep |
|
-> Int32 |
|
-> Bool |
|
-> IO () |
Gets emitted when the user initiates a cursor movement.
The moveCursor signal is a keybinding signal.
If the cursor is not visible in textView
, this signal causes
the viewport to be moved instead.
Applications should not connect to it, but may emit it with
g_signal_emit_by_name()
if they need to control the cursor
programmatically.
The default bindings for this signal come in two variants, the variant with the <kbd>Shift</kbd> modifier extends the selection, the variant without it does not. There are too many key combinations to list them all here.
- <kbd>←</kbd>, <kbd>→</kbd>, <kbd>↑</kbd>, <kbd>↓</kbd> move by individual characters/lines
- <kbd>Ctrl</kbd>+<kbd>←</kbd>, etc. move by words/paragraphs
- <kbd>Home</kbd> and <kbd>End</kbd> move to the ends of the buffer
- <kbd>PgUp</kbd> and <kbd>PgDn</kbd> move vertically by pages
- <kbd>Ctrl</kbd>+<kbd>PgUp</kbd> and <kbd>Ctrl</kbd>+<kbd>PgDn</kbd> move horizontally by pages
afterTextViewMoveCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveCursorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the moveCursor signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #moveCursor callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewMoveCursor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveCursorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the moveCursor signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #moveCursor callback
moveViewport
type TextViewMoveViewportCallback Source #
= ScrollStep |
|
-> Int32 |
|
-> IO () |
Gets emitted to move the viewport.
The moveViewport signal is a keybinding signal, which can be bound to key combinations to allow the user to move the viewport, i.e. change what part of the text view is visible in a containing scrolled window.
There are no default bindings for this signal.
afterTextViewMoveViewport :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveViewportCallback) -> m SignalHandlerId Source #
Connect a signal handler for the moveViewport signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #moveViewport callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewMoveViewport :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewMoveViewportCallback) -> m SignalHandlerId Source #
Connect a signal handler for the moveViewport signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #moveViewport callback
pasteClipboard
type TextViewPasteClipboardCallback = IO () Source #
Gets emitted to paste the contents of the clipboard into the text view.
The pasteClipboard signal is a keybinding signal.
The default bindings for this signal are <kbd>Ctrl</kbd>+<kbd>v</kbd> and <kbd>Shift</kbd>+<kbd>Insert</kbd>.
afterTextViewPasteClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPasteClipboardCallback) -> m SignalHandlerId Source #
Connect a signal handler for the pasteClipboard signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #pasteClipboard callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewPasteClipboard :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPasteClipboardCallback) -> m SignalHandlerId Source #
Connect a signal handler for the pasteClipboard signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #pasteClipboard callback
preeditChanged
type TextViewPreeditChangedCallback Source #
Emitted when preedit text of the active IM changes.
If an input method is used, the typed text will not immediately be committed to the buffer. So if you are interested in the text, connect to this signal.
This signal is only emitted if the text at the given position is actually editable.
afterTextViewPreeditChanged :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPreeditChangedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the preeditChanged signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #preeditChanged callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewPreeditChanged :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewPreeditChangedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the preeditChanged signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #preeditChanged callback
selectAll
type TextViewSelectAllCallback Source #
Gets emitted to select or unselect the complete contents of the text view.
The selectAll signal is a keybinding signal.
The default bindings for this signal are <kbd>Ctrl</kbd>+<kbd>a</kbd> and <kbd>Ctrl</kbd>+<kbd>/</kbd> for selecting and <kbd>Shift</kbd>+<kbd>Ctrl</kbd>+<kbd>a</kbd> and <kbd>Ctrl</kbd>+<kbd>\</kbd> for unselecting.
afterTextViewSelectAll :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSelectAllCallback) -> m SignalHandlerId Source #
Connect a signal handler for the selectAll signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #selectAll callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewSelectAll :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSelectAllCallback) -> m SignalHandlerId Source #
Connect a signal handler for the selectAll signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #selectAll callback
setAnchor
type TextViewSetAnchorCallback = IO () Source #
Gets emitted when the user initiates settings the "anchor" mark.
The setAnchor signal is a keybinding signal which gets emitted when the user initiates setting the "anchor" mark. The "anchor" mark gets placed at the same position as the "insert" mark.
This signal has no default bindings.
afterTextViewSetAnchor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSetAnchorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the setAnchor signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #setAnchor callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewSetAnchor :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewSetAnchorCallback) -> m SignalHandlerId Source #
Connect a signal handler for the setAnchor signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #setAnchor callback
toggleCursorVisible
type TextViewToggleCursorVisibleCallback = IO () Source #
Gets emitted to toggle the cursor-visible
property.
The toggleCursorVisible signal is a keybinding signal.
The default binding for this signal is <kbd>F7</kbd>.
afterTextViewToggleCursorVisible :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleCursorVisibleCallback) -> m SignalHandlerId Source #
Connect a signal handler for the toggleCursorVisible signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #toggleCursorVisible callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewToggleCursorVisible :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleCursorVisibleCallback) -> m SignalHandlerId Source #
Connect a signal handler for the toggleCursorVisible signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #toggleCursorVisible callback
toggleOverwrite
type TextViewToggleOverwriteCallback = IO () Source #
Gets emitted to toggle the overwrite mode of the text view.
The toggleOverwrite signal is a keybinding signal.
The default binding for this signal is <kbd>Insert</kbd>.
afterTextViewToggleOverwrite :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleOverwriteCallback) -> m SignalHandlerId Source #
Connect a signal handler for the toggleOverwrite signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
textView #toggleOverwrite callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onTextViewToggleOverwrite :: (IsTextView a, MonadIO m) => a -> ((?self :: a) => TextViewToggleOverwriteCallback) -> m SignalHandlerId Source #
Connect a signal handler for the toggleOverwrite signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
textView #toggleOverwrite callback