TextViewProtocol

public protocol TextViewProtocol : ContainerProtocol, ScrollableProtocol

You may wish to begin by reading the text widget 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

(plain Language Example):

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.

The TextViewProtocol protocol exposes the methods and properties of an underlying GtkTextView instance. The default implementation of these can be found in the protocol extension below. For a concrete class that implements these methods and properties, see TextView. Alternatively, use TextViewRef as a lighweight, unowned reference if you already have an instance you just want to use.

  • ptr

    Untyped pointer to the underlying GtkTextView instance.

    Declaration

    Swift

    var ptr: UnsafeMutableRawPointer! { get }
  • text_view_ptr Default implementation

    Typed pointer to the underlying GtkTextView instance.

    Default Implementation

    Return the stored, untyped pointer as a typed pointer to the GtkTextView instance.

    Declaration

    Swift

    var text_view_ptr: UnsafeMutablePointer<GtkTextView>! { get }
  • Required Initialiser for types conforming to TextViewProtocol

    Declaration

    Swift

    init(raw: UnsafeMutableRawPointer)

TextView Class

  • Bind a TextViewPropertyName source property to a given target object.

    Declaration

    Swift

    @discardableResult
    @inlinable
    func bind<Q, T>(property source_property: TextViewPropertyName, to target: T, _ target_property: Q, flags f: BindingFlags = .default, transformFrom transform_from: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }, transformTo transform_to: @escaping GLibObject.ValueTransformer = { $0.transform(destValue: $1) }) -> BindingRef! where Q : PropertyNameProtocol, T : ObjectProtocol

    Parameters

    source_property

    the source property to bind

    target

    the target object to bind to

    target_property

    the target property to bind to

    flags

    the flags to pass to the Binding

    transform_from

    ValueTransformer to use for forward transformation

    transform_to

    ValueTransformer to use for backwards transformation

    Return Value

    binding reference or nil in case of an error

  • get(property:) Extension method

    Get the value of a TextView property

    Declaration

    Swift

    @inlinable
    func get(property: TextViewPropertyName) -> GLibObject.Value

    Parameters

    property

    the property to get the value for

    Return Value

    the value of the named property

  • set(property:value:) Extension method

    Set the value of a TextView property. Note that this will only have an effect on properties that are writable and not construct-only!

    Declaration

    Swift

    @inlinable
    func set(property: TextViewPropertyName, value v: GLibObject.Value)

    Parameters

    property

    the property to get the value for

    Return Value

    the value of the named property

TextView signals

  • Connect a Swift signal handler to the given, typed TextViewSignalName signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func connect(signal s: TextViewSignalName, flags f: ConnectFlags = ConnectFlags(0), handler h: @escaping SignalHandler) -> Int

    Parameters

    signal

    The signal to connect

    flags

    The connection flags to use

    data

    A pointer to user data to provide to the callback

    destroyData

    A GClosureNotify C function to destroy the data pointed to by userData

    handler

    The Swift signal handler (function or callback) to invoke on the given signal

    Return Value

    The signal handler ID (always greater than 0 for successful connections)

  • Connect a C signal handler to the given, typed TextViewSignalName signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func connect(signal s: TextViewSignalName, flags f: ConnectFlags = ConnectFlags(0), data userData: gpointer!, destroyData destructor: GClosureNotify? = nil, signalHandler h: @escaping GCallback) -> Int

    Parameters

    signal

    The signal to connect

    flags

    The connection flags to use

    data

    A pointer to user data to provide to the callback

    destroyData

    A GClosureNotify C function to destroy the data pointed to by userData

    signalHandler

    The C function to be called on the given signal

    Return Value

    The signal handler ID (always greater than 0 for successful connections)

  • onBackspace(flags:handler:) Extension method

    The backspace signal is a keybinding signal which gets emitted when the user asks for it.

    The default bindings for this signal are Backspace and Shift-Backspace.

    Note

    This represents the underlying backspace signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onBackspace(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the backspace signal is emitted

  • backspaceSignal Extension method

    Typed backspace signal for using the connect(signal:) methods

    Declaration

    Swift

    static var backspaceSignal: TextViewSignalName { get }
  • The copy-clipboard signal is a keybinding signal which gets emitted to copy the selection to the clipboard.

    The default bindings for this signal are Ctrl-c and Ctrl-Insert.

    Note

    This represents the underlying copy-clipboard signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onCopyClipboard(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the copyClipboard signal is emitted

  • copyClipboardSignal Extension method

    Typed copy-clipboard signal for using the connect(signal:) methods

    Declaration

    Swift

    static var copyClipboardSignal: TextViewSignalName { get }
  • The cut-clipboard signal is a keybinding signal which gets emitted to cut the selection to the clipboard.

    The default bindings for this signal are Ctrl-x and Shift-Delete.

    Note

    This represents the underlying cut-clipboard signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onCutClipboard(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the cutClipboard signal is emitted

  • cutClipboardSignal Extension method

    Typed cut-clipboard signal for using the connect(signal:) methods

    Declaration

    Swift

    static var cutClipboardSignal: TextViewSignalName { get }
  • The delete-from-cursor signal is a keybinding signal which gets emitted when the user initiates a text deletion.

    If the type is GTK_DELETE_CHARS, GTK+ deletes the selection if there is one, otherwise it deletes the requested number of characters.

    The default bindings for this signal are Delete for deleting a character, Ctrl-Delete for deleting a word and Ctrl-Backspace for deleting a word backwords.

    Note

    This represents the underlying delete-from-cursor signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onDeleteFromCursor(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ type: DeleteType, _ count: Int) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    type

    the granularity of the deletion, as a GtkDeleteType

    count

    the number of type units to delete

    handler

    The signal handler to call Run the given callback whenever the deleteFromCursor signal is emitted

  • deleteFromCursorSignal Extension method

    Typed delete-from-cursor signal for using the connect(signal:) methods

    Declaration

    Swift

    static var deleteFromCursorSignal: TextViewSignalName { get }
  • The extend-selection signal is emitted when the selection needs to be extended at location.

    Note

    This represents the underlying extend-selection signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onExtendSelection(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ granularity: TextExtendSelection, _ location: TextIterRef, _ start: TextIterRef, _ end: TextIterRef) -> Bool) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    granularity

    the granularity type

    location

    the location where to extend the selection

    start

    where the selection should start

    end

    where the selection should end

    handler

    GDK_EVENT_STOP to stop other handlers from being invoked for the event. GDK_EVENT_PROPAGATE to propagate the event further. Run the given callback whenever the extendSelection signal is emitted

  • extendSelectionSignal Extension method

    Typed extend-selection signal for using the connect(signal:) methods

    Declaration

    Swift

    static var extendSelectionSignal: TextViewSignalName { get }
  • The insert-at-cursor signal is a keybinding signal which gets emitted when the user initiates the insertion of a fixed string at the cursor.

    This signal has no default bindings.

    Note

    This represents the underlying insert-at-cursor signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onInsertAtCursor(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ string: String) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    string

    the string to insert

    handler

    The signal handler to call Run the given callback whenever the insertAtCursor signal is emitted

  • insertAtCursorSignal Extension method

    Typed insert-at-cursor signal for using the connect(signal:) methods

    Declaration

    Swift

    static var insertAtCursorSignal: TextViewSignalName { get }
  • The insert-emoji signal is a keybinding signal which gets emitted to present the Emoji chooser for the text_view.

    The default bindings for this signal are Ctrl-. and Ctrl-;

    Note

    This represents the underlying insert-emoji signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onInsertEmoji(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the insertEmoji signal is emitted

  • insertEmojiSignal Extension method

    Typed insert-emoji signal for using the connect(signal:) methods

    Declaration

    Swift

    static var insertEmojiSignal: TextViewSignalName { get }
  • onMoveCursor(flags:handler:) Extension method

    The move-cursor signal is a keybinding signal which gets emitted when the user initiates a cursor movement. If the cursor is not visible in text_view, 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 Shift modifier extends the selection, the variant without the Shift modifer does not. There are too many key combinations to list them all here.

    • Arrow keys move by individual characters/lines
    • Ctrl-arrow key combinations move by words/paragraphs
    • Home/End keys move to the ends of the buffer
    • PageUp/PageDown keys move vertically by pages
    • Ctrl-PageUp/PageDown keys move horizontally by pages

    Note

    This represents the underlying move-cursor signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onMoveCursor(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ step: MovementStep, _ count: Int, _ extendSelection: Bool) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    step

    the granularity of the move, as a GtkMovementStep

    count

    the number of step units to move

    extendSelection

    true if the move should extend the selection

    handler

    The signal handler to call Run the given callback whenever the moveCursor signal is emitted

  • moveCursorSignal Extension method

    Typed move-cursor signal for using the connect(signal:) methods

    Declaration

    Swift

    static var moveCursorSignal: TextViewSignalName { get }
  • The move-viewport 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.

    Note

    This represents the underlying move-viewport signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onMoveViewport(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ step: ScrollStep, _ count: Int) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    step

    the granularity of the movement, as a GtkScrollStep

    count

    the number of step units to move

    handler

    The signal handler to call Run the given callback whenever the moveViewport signal is emitted

  • moveViewportSignal Extension method

    Typed move-viewport signal for using the connect(signal:) methods

    Declaration

    Swift

    static var moveViewportSignal: TextViewSignalName { get }
  • The paste-clipboard signal is a keybinding signal which gets emitted to paste the contents of the clipboard into the text view.

    The default bindings for this signal are Ctrl-v and Shift-Insert.

    Note

    This represents the underlying paste-clipboard signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onPasteClipboard(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the pasteClipboard signal is emitted

  • pasteClipboardSignal Extension method

    Typed paste-clipboard signal for using the connect(signal:) methods

    Declaration

    Swift

    static var pasteClipboardSignal: TextViewSignalName { get }
  • The populate-popup signal gets emitted before showing the context menu of the text view.

    If you need to add items to the context menu, connect to this signal and append your items to the popup, which will be a GtkMenu in this case.

    If GtkTextView:populate-all is true, this signal will also be emitted to populate touch popups. In this case, popup will be a different container, e.g. a GtkToolbar.

    The signal handler should not make assumptions about the type of widget, but check whether popup is a GtkMenu or GtkToolbar or another kind of container.

    Note

    This represents the underlying populate-popup signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onPopulatePopup(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ popup: WidgetRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    popup

    the container that is being populated

    handler

    The signal handler to call Run the given callback whenever the populatePopup signal is emitted

  • populatePopupSignal Extension method

    Typed populate-popup signal for using the connect(signal:) methods

    Declaration

    Swift

    static var populatePopupSignal: TextViewSignalName { get }
  • 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.

    Note

    This represents the underlying preedit-changed signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onPreeditChanged(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ preedit: String) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    preedit

    the current preedit string

    handler

    The signal handler to call Run the given callback whenever the preeditChanged signal is emitted

  • preeditChangedSignal Extension method

    Typed preedit-changed signal for using the connect(signal:) methods

    Declaration

    Swift

    static var preeditChangedSignal: TextViewSignalName { get }
  • onSelectAll(flags:handler:) Extension method

    The select-all signal is a keybinding signal which gets emitted to select or unselect the complete contents of the text view.

    The default bindings for this signal are Ctrl-a and Ctrl-/ for selecting and Shift-Ctrl-a and Ctrl-\ for unselecting.

    Note

    This represents the underlying select-all signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onSelectAll(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ select: Bool) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    select

    true to select, false to unselect

    handler

    The signal handler to call Run the given callback whenever the selectAll signal is emitted

  • selectAllSignal Extension method

    Typed select-all signal for using the connect(signal:) methods

    Declaration

    Swift

    static var selectAllSignal: TextViewSignalName { get }
  • onSetAnchor(flags:handler:) Extension method

    The set-anchor 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.

    Note

    This represents the underlying set-anchor signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onSetAnchor(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the setAnchor signal is emitted

  • setAnchorSignal Extension method

    Typed set-anchor signal for using the connect(signal:) methods

    Declaration

    Swift

    static var setAnchorSignal: TextViewSignalName { get }
  • The toggle-cursor-visible signal is a keybinding signal which gets emitted to toggle the GtkTextView:cursor-visible property.

    The default binding for this signal is F7.

    Note

    This represents the underlying toggle-cursor-visible signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onToggleCursorVisible(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the toggleCursorVisible signal is emitted

  • toggleCursorVisibleSignal Extension method

    Typed toggle-cursor-visible signal for using the connect(signal:) methods

    Declaration

    Swift

    static var toggleCursorVisibleSignal: TextViewSignalName { get }
  • The toggle-overwrite signal is a keybinding signal which gets emitted to toggle the overwrite mode of the text view.

    The default bindings for this signal is Insert.

    Note

    This represents the underlying toggle-overwrite signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onToggleOverwrite(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    handler

    The signal handler to call Run the given callback whenever the toggleOverwrite signal is emitted

  • toggleOverwriteSignal Extension method

    Typed toggle-overwrite signal for using the connect(signal:) methods

    Declaration

    Swift

    static var toggleOverwriteSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::accepts-tab signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyAcceptsTab(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyAcceptsTab signal is emitted

  • notifyAcceptsTabSignal Extension method

    Typed notify::accepts-tab signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyAcceptsTabSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::bottom-margin signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyBottomMargin(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyBottomMargin signal is emitted

  • notifyBottomMarginSignal Extension method

    Typed notify::bottom-margin signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyBottomMarginSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::buffer signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyBuffer(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyBuffer signal is emitted

  • notifyBufferSignal Extension method

    Typed notify::buffer signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyBufferSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::cursor-visible signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyCursorVisible(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyCursorVisible signal is emitted

  • notifyCursorVisibleSignal Extension method

    Typed notify::cursor-visible signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyCursorVisibleSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::editable signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyEditable(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyEditable signal is emitted

  • notifyEditableSignal Extension method

    Typed notify::editable signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyEditableSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::im-module signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyImModule(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyImModule signal is emitted

  • notifyImModuleSignal Extension method

    Typed notify::im-module signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyImModuleSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::indent signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyIndent(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyIndent signal is emitted

  • notifyIndentSignal Extension method

    Typed notify::indent signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyIndentSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::input-hints signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyInputHints(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyInputHints signal is emitted

  • notifyInputHintsSignal Extension method

    Typed notify::input-hints signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyInputHintsSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::input-purpose signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyInputPurpose(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyInputPurpose signal is emitted

  • notifyInputPurposeSignal Extension method

    Typed notify::input-purpose signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyInputPurposeSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::justification signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyJustification(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyJustification signal is emitted

  • notifyJustificationSignal Extension method

    Typed notify::justification signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyJustificationSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::left-margin signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyLeftMargin(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyLeftMargin signal is emitted

  • notifyLeftMarginSignal Extension method

    Typed notify::left-margin signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyLeftMarginSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::monospace signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyMonospace(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyMonospace signal is emitted

  • notifyMonospaceSignal Extension method

    Typed notify::monospace signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyMonospaceSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::overwrite signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyOverwrite(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyOverwrite signal is emitted

  • notifyOverwriteSignal Extension method

    Typed notify::overwrite signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyOverwriteSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::pixels-above-lines signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyPixelsAboveLines(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyPixelsAboveLines signal is emitted

  • notifyPixelsAboveLinesSignal Extension method

    Typed notify::pixels-above-lines signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyPixelsAboveLinesSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::pixels-below-lines signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyPixelsBelowLines(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyPixelsBelowLines signal is emitted

  • notifyPixelsBelowLinesSignal Extension method

    Typed notify::pixels-below-lines signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyPixelsBelowLinesSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::pixels-inside-wrap signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyPixelsInsideWrap(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyPixelsInsideWrap signal is emitted

  • notifyPixelsInsideWrapSignal Extension method

    Typed notify::pixels-inside-wrap signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyPixelsInsideWrapSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::populate-all signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyPopulateAll(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyPopulateAll signal is emitted

  • notifyPopulateAllSignal Extension method

    Typed notify::populate-all signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyPopulateAllSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::right-margin signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyRightMargin(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyRightMargin signal is emitted

  • notifyRightMarginSignal Extension method

    Typed notify::right-margin signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyRightMarginSignal: TextViewSignalName { get }
  • onNotifyTabs(flags:handler:) Extension method

    The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::tabs signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyTabs(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyTabs signal is emitted

  • notifyTabsSignal Extension method

    Typed notify::tabs signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyTabsSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::top-margin signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyTopMargin(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyTopMargin signal is emitted

  • notifyTopMarginSignal Extension method

    Typed notify::top-margin signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyTopMarginSignal: TextViewSignalName { get }
  • The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

    Note that getting this signal doesn’t itself guarantee that the value of the property has actually changed. When it is emitted is determined by the derived GObject class. If the implementor did not create the property with G_PARAM_EXPLICIT_NOTIFY, then any call to g_object_set_property() results in notify being emitted, even if the new value is the same as the old. If they did pass G_PARAM_EXPLICIT_NOTIFY, then this signal is emitted only when they explicitly call g_object_notify() or g_object_notify_by_pspec(), and common practice is to do that only when the value has actually changed.

    This signal is typically used to obtain change notification for a single property, by specifying the property name as a detail in the g_signal_connect() call, like this:

    (C Language Example):

    g_signal_connect (text_view->buffer, "notify::paste-target-list",
                      G_CALLBACK (gtk_text_view_target_list_notify),
                      text_view)
    

    It is important to note that you must use canonical parameter names as detail strings for the notify signal.

    Note

    This represents the underlying notify::wrap-mode signal

    Declaration

    Swift

    @discardableResult
    @inlinable
    func onNotifyWrapMode(flags: ConnectFlags = ConnectFlags(0), handler: @escaping (_ unownedSelf: TextViewRef, _ pspec: ParamSpecRef) -> Void) -> Int

    Parameters

    flags

    Flags

    unownedSelf

    Reference to instance of self

    pspec

    the GParamSpec of the property which changed.

    handler

    The signal handler to call Run the given callback whenever the notifyWrapMode signal is emitted

  • notifyWrapModeSignal Extension method

    Typed notify::wrap-mode signal for using the connect(signal:) methods

    Declaration

    Swift

    static var notifyWrapModeSignal: TextViewSignalName { get }

TextView Class: TextViewProtocol extension (methods and fields)

  • Adds a child widget in the text buffer, at the given anchor.

    Declaration

    Swift

    @inlinable
    func addChildAtAnchor<TextChildAnchorT, WidgetT>(child: WidgetT, anchor: TextChildAnchorT) where TextChildAnchorT : TextChildAnchorProtocol, WidgetT : WidgetProtocol
  • Adds a child at fixed coordinates in one of the text widget’s windows.

    The window must have nonzero size (see gtk_text_view_set_border_window_size()). Note that the child coordinates are given relative to scrolling. When placing a child in GTK_TEXT_WINDOW_WIDGET, scrolling is irrelevant, the child floats above all scrollable areas. But when placing a child in one of the scrollable windows (border windows or text window) it will move with the scrolling as needed.

    Declaration

    Swift

    @inlinable
    func addChildInWindow<WidgetT>(child: WidgetT, whichWindow: GtkTextWindowType, xpos: Int, ypos: Int) where WidgetT : WidgetProtocol
  • backwardDisplayLine(iter:) Extension method

    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.

    Declaration

    Swift

    @inlinable
    func backwardDisplayLine<TextIterT>(iter: TextIterT) -> Bool where TextIterT : TextIterProtocol
  • 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.

    Declaration

    Swift

    @inlinable
    func backwardDisplayLineStart<TextIterT>(iter: TextIterT) -> Bool where TextIterT : TextIterProtocol
  • Converts coordinate (buffer_x, buffer_y) to coordinates for the window win, and stores the result in (window_x, window_y).

    Note that you can’t convert coordinates for a nonexisting window (see gtk_text_view_set_border_window_size()).

    Declaration

    Swift

    @inlinable
    func bufferToWindowCoords(win: GtkTextWindowType, bufferX: Int, bufferY: Int, windowX: UnsafeMutablePointer<gint>! = nil, windowY: UnsafeMutablePointer<gint>! = nil)
  • forwardDisplayLine(iter:) Extension method

    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.

    Declaration

    Swift

    @inlinable
    func forwardDisplayLine<TextIterT>(iter: TextIterT) -> Bool where TextIterT : TextIterProtocol
  • forwardDisplayLineEnd(iter:) Extension method

    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.

    Declaration

    Swift

    @inlinable
    func forwardDisplayLineEnd<TextIterT>(iter: TextIterT) -> Bool where TextIterT : TextIterProtocol
  • getAcceptsTab() Extension method

    Returns whether pressing the Tab key inserts a tab characters. gtk_text_view_set_accepts_tab().

    Declaration

    Swift

    @inlinable
    func getAcceptsTab() -> Bool
  • getBorderWindowSize(type:) Extension method

    Gets the width of the specified border window. See gtk_text_view_set_border_window_size().

    Declaration

    Swift

    @inlinable
    func getBorderWindowSize(type: GtkTextWindowType) -> Int
  • getBottomMargin() Extension method

    Gets the bottom margin for text in the text_view.

    Declaration

    Swift

    @inlinable
    func getBottomMargin() -> Int
  • getBuffer() Extension method

    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.

    Declaration

    Swift

    @inlinable
    func getBuffer() -> TextBufferRef!
  • Given an iter within a text layout, determine the positions of the strong and weak cursors if the insertion point is at that iterator. 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 nil, 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 gtk_text_view_buffer_to_window_coords() to convert these coordinates to coordinates for one of the windows in the text view.

    Declaration

    Swift

    @inlinable
    func getCursorLocations(iter: TextIterRef? = nil, strong: Gdk.RectangleRef? = nil, weak: Gdk.RectangleRef? = nil)
  • Given an iter within a text layout, determine the positions of the strong and weak cursors if the insertion point is at that iterator. 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 nil, 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 gtk_text_view_buffer_to_window_coords() to convert these coordinates to coordinates for one of the windows in the text view.

    Declaration

    Swift

    @inlinable
    func getCursorLocations<RectangleT, TextIterT>(iter: TextIterT?, strong: RectangleT?, weak: RectangleT?) where RectangleT : RectangleProtocol, TextIterT : TextIterProtocol
  • getCursorVisible() Extension method

    Find out whether the cursor should be displayed.

    Declaration

    Swift

    @inlinable
    func getCursorVisible() -> Bool
  • getDefaultAttributes() Extension method

    Obtains a copy of the default text attributes. These are the attributes used for text unless a tag overrides them. You’d typically pass the default attributes in to gtk_text_iter_get_attributes() in order to get the attributes in effect at a given text position.

    The return value is a copy owned by the caller of this function, and should be freed with gtk_text_attributes_unref().

    Declaration

    Swift

    @inlinable
    func getDefaultAttributes() -> TextAttributesRef!
  • getEditable() Extension method

    Returns the default editability of the GtkTextView. Tags in the buffer may override this setting for some ranges of text.

    Declaration

    Swift

    @inlinable
    func getEditable() -> Bool
  • getHadjustment() Extension method

    Gets the horizontal-scrolling GtkAdjustment.

    get_hadjustment is deprecated: Use gtk_scrollable_get_hadjustment()

    Declaration

    Swift

    @available(*, deprecated)
    @inlinable
    func getHadjustment() -> AdjustmentRef!
  • getIndent() Extension method

    Gets the default indentation of paragraphs in text_view. Tags in the view’s buffer may override the default. The indentation may be negative.

    Declaration

    Swift

    @inlinable
    func getIndent() -> Int
  • getInputHints() Extension method

    Gets the value of the GtkTextView:input-hints property.

    Declaration

    Swift

    @inlinable
    func getInputHints() -> InputHints
  • getInputPurpose() Extension method

    Gets the value of the GtkTextView:input-purpose property.

    Declaration

    Swift

    @inlinable
    func getInputPurpose() -> GtkInputPurpose
  • getIterAtLocation(iter:x:y:) Extension method

    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 gtk_text_view_window_to_buffer_coords().

    Declaration

    Swift

    @inlinable
    func getIterAtLocation<TextIterT>(iter: TextIterT, x: Int, y: Int) -> Bool where TextIterT : TextIterProtocol
  • 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 gtk_text_view_window_to_buffer_coords().

    Note that this is different from gtk_text_view_get_iter_at_location(), which returns cursor locations, i.e. positions between characters.

    Declaration

    Swift

    @inlinable
    func getIterAtPosition<TextIterT>(iter: TextIterT, trailing: UnsafeMutablePointer<gint>! = nil, x: Int, y: Int) -> Bool where TextIterT : TextIterProtocol
  • Gets a rectangle which roughly contains the character at iter. The rectangle position is in buffer coordinates; use gtk_text_view_buffer_to_window_coords() to convert these coordinates to coordinates for one of the windows in the text view.

    Declaration

    Swift

    @inlinable
    func getIterLocation<RectangleT, TextIterT>(iter: TextIterT, location: RectangleT) where RectangleT : RectangleProtocol, TextIterT : TextIterProtocol
  • getJustification() Extension method

    Gets the default justification of paragraphs in text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    func getJustification() -> GtkJustification
  • getLeftMargin() Extension method

    Gets the default left margin size of paragraphs in the text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    func getLeftMargin() -> Int
  • Gets the GtkTextIter at the start of the line containing the coordinate y. y is in buffer coordinates, convert from window coordinates with gtk_text_view_window_to_buffer_coords(). If non-nil, line_top will be filled with the coordinate of the top edge of the line.

    Declaration

    Swift

    @inlinable
    func getLineAtY<TextIterT>(targetIter: TextIterT, y: Int, lineTop: UnsafeMutablePointer<gint>!) where TextIterT : TextIterProtocol
  • 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 gtk_text_view_buffer_to_window_coords().

    Declaration

    Swift

    @inlinable
    func getLineYrange<TextIterT>(iter: TextIterT, y: UnsafeMutablePointer<gint>!, height: UnsafeMutablePointer<gint>!) where TextIterT : TextIterProtocol
  • getMonospace() Extension method

    Gets the value of the GtkTextView:monospace property.

    Declaration

    Swift

    @inlinable
    func getMonospace() -> Bool
  • getOverwrite() Extension method

    Returns whether the GtkTextView is in overwrite mode or not.

    Declaration

    Swift

    @inlinable
    func getOverwrite() -> Bool
  • getPixelsAboveLines() Extension method

    Gets the default number of pixels to put above paragraphs. Adding this function with gtk_text_view_get_pixels_below_lines() is equal to the line space between each paragraph.

    Declaration

    Swift

    @inlinable
    func getPixelsAboveLines() -> Int
  • getPixelsBelowLines() Extension method

    Gets the value set by gtk_text_view_set_pixels_below_lines().

    The line space is the sum of the value returned by this function and the value returned by gtk_text_view_get_pixels_above_lines().

    Declaration

    Swift

    @inlinable
    func getPixelsBelowLines() -> Int
  • getPixelsInsideWrap() Extension method

    Gets the value set by gtk_text_view_set_pixels_inside_wrap().

    Declaration

    Swift

    @inlinable
    func getPixelsInsideWrap() -> Int
  • getRightMargin() Extension method

    Gets the default right margin for text in text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    func getRightMargin() -> Int
  • getTabs() Extension method

    Gets the default tabs for text_view. Tags in the buffer may override the defaults. The returned array will be nil if “standard” (8-space) tabs are used. Free the return value with pango_tab_array_free().

    Declaration

    Swift

    @inlinable
    func getTabs() -> Pango.TabArrayRef!
  • getTopMargin() Extension method

    Gets the top margin for text in the text_view.

    Declaration

    Swift

    @inlinable
    func getTopMargin() -> Int
  • getVadjustment() Extension method

    Gets the vertical-scrolling GtkAdjustment.

    get_vadjustment is deprecated: Use gtk_scrollable_get_vadjustment()

    Declaration

    Swift

    @available(*, deprecated)
    @inlinable
    func getVadjustment() -> AdjustmentRef!
  • get(visibleRect:) Extension method

    Fills visible_rect with the currently-visible region of the buffer, in buffer coordinates. Convert to window coordinates with gtk_text_view_buffer_to_window_coords().

    Declaration

    Swift

    @inlinable
    func get<RectangleT>(visibleRect: RectangleT) where RectangleT : RectangleProtocol
  • getWindow(win:) Extension method

    Retrieves the GdkWindow corresponding to an area of the text view; possible windows include the overall widget window, child windows on the left, right, top, bottom, and the window that displays the text buffer. Windows are nil and nonexistent if their width or height is 0, and are nonexistent before the widget has been realized.

    Declaration

    Swift

    @inlinable
    func getWindow(win: GtkTextWindowType) -> Gdk.WindowRef!
  • getWindowType(window:) Extension method

    Usually used to find out which window an event corresponds to.

    If you connect to an event signal on text_view, this function should be called on event-&gt;window to see which window it was.

    Declaration

    Swift

    @inlinable
    func getWindowType<WindowT>(window: WindowT) -> GtkTextWindowType where WindowT : WindowProtocol
  • getWrapMode() Extension method

    Gets the line wrapping for the view.

    Declaration

    Swift

    @inlinable
    func getWrapMode() -> GtkWrapMode
  • 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 gtk_im_context_filter_keypress().

    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 Language Example):

    static gboolean
    gtk_foo_bar_key_press_event (GtkWidget   *widget,
                                 GdkEventKey *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);
    }
    

    Declaration

    Swift

    @inlinable
    func imContextFilterKeypress<EventKeyT>(event: EventKeyT) -> Bool where EventKeyT : EventKeyProtocol
  • move(child:xpos:ypos:) Extension method

    Updates the position of a child, as for gtk_text_view_add_child_in_window().

    Declaration

    Swift

    @inlinable
    func move<WidgetT>(child: WidgetT, xpos: Int, ypos: Int) where WidgetT : WidgetProtocol
  • moveMarkOnscreen(mark:) Extension method

    Moves a mark within the buffer so that it’s located within the currently-visible text area.

    Declaration

    Swift

    @inlinable
    func moveMarkOnscreen<TextMarkT>(mark: TextMarkT) -> Bool where TextMarkT : TextMarkProtocol
  • moveVisually(iter:count:) Extension method

    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.

    Declaration

    Swift

    @inlinable
    func moveVisually<TextIterT>(iter: TextIterT, count: Int) -> Bool where TextIterT : TextIterProtocol
  • placeCursorOnscreen() Extension method

    Moves the cursor to the currently visible region of the buffer, it it isn’t there already.

    Declaration

    Swift

    @inlinable
    func placeCursorOnscreen() -> Bool
  • resetCursorBlink() Extension method

    Ensures that the cursor is shown (i.e. not in an ‘off’ blink interval) and 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 GtkWidget::key-press-event handler).

    Declaration

    Swift

    @inlinable
    func resetCursorBlink()
  • resetImContext() Extension method

    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.

    Declaration

    Swift

    @inlinable
    func resetImContext()
  • scrollMarkOnscreen(mark:) Extension method

    Scrolls text_view the minimum distance such that mark is contained within the visible area of the widget.

    Declaration

    Swift

    @inlinable
    func scrollMarkOnscreen<TextMarkT>(mark: TextMarkT) where TextMarkT : TextMarkProtocol
  • Scrolls text_view 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 use_align 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 within_margin.

    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 gtk_text_view_scroll_to_mark() which saves a point to be scrolled to after line validation.

    Declaration

    Swift

    @inlinable
    func scrollTo<TextIterT>(iter: TextIterT, within margin: Double, useAlign: Bool, xalign: Double, yalign: Double) -> Bool where TextIterT : TextIterProtocol
  • Scrolls text_view 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 use_align 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 within_margin.

    Declaration

    Swift

    @inlinable
    func scrollTo<TextMarkT>(mark: TextMarkT, within margin: Double, useAlign: Bool, xalign: Double, yalign: Double) where TextMarkT : TextMarkProtocol
  • set(acceptsTab:) Extension method

    Sets the behavior of the text widget when the Tab key is pressed. If accepts_tab is true, a tab character is inserted. If accepts_tab is false the keyboard focus is moved to the next widget in the focus chain.

    Declaration

    Swift

    @inlinable
    func set(acceptsTab: Bool)
  • Sets the width of GTK_TEXT_WINDOW_LEFT or GTK_TEXT_WINDOW_RIGHT, or the height of GTK_TEXT_WINDOW_TOP or GTK_TEXT_WINDOW_BOTTOM. Automatically destroys the corresponding window if the size is set to 0, and creates the window if the size is set to non-zero. This function can only be used for the “border windows”, and it won’t work with GTK_TEXT_WINDOW_WIDGET, GTK_TEXT_WINDOW_TEXT, or GTK_TEXT_WINDOW_PRIVATE.

    Declaration

    Swift

    @inlinable
    func setBorderWindowSize(type: GtkTextWindowType, size: Int)
  • set(bottomMargin:) Extension method

    Sets the bottom margin for text in text_view.

    Note that this function is confusingly named. In CSS terms, the value set here is padding.

    Declaration

    Swift

    @inlinable
    func set(bottomMargin: Int)
  • set(buffer:) Extension method

    Sets buffer as the buffer being displayed by text_view. 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.

    Declaration

    Swift

    @inlinable
    func set(buffer: TextBufferRef? = nil)
  • set(buffer:) Extension method

    Sets buffer as the buffer being displayed by text_view. 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.

    Declaration

    Swift

    @inlinable
    func set<TextBufferT>(buffer: TextBufferT?) where TextBufferT : TextBufferProtocol
  • setCursorVisible(setting:) Extension method

    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 GtkSettings:gtk-keynave-use-caret settings.

    Declaration

    Swift

    @inlinable
    func setCursorVisible(setting: Bool)
  • setEditable(setting:) Extension method

    Sets the default editability of the GtkTextView. You can override this default setting with tags in the buffer, using the “editable” attribute of tags.

    Declaration

    Swift

    @inlinable
    func setEditable(setting: Bool)
  • set(indent:) Extension method

    Sets the default indentation for paragraphs in text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    func set(indent: Int)
  • setInput(hints:) Extension method

    Sets the GtkTextView:input-hints property, which allows input methods to fine-tune their behaviour.

    Declaration

    Swift

    @inlinable
    func setInput(hints: InputHints)
  • setInput(purpose:) Extension method

    Sets the GtkTextView:input-purpose property which can be used by on-screen keyboards and other input methods to adjust their behaviour.

    Declaration

    Swift

    @inlinable
    func setInput(purpose: GtkInputPurpose)
  • set(justification:) Extension method

    Sets the default justification of text in text_view. Tags in the view’s buffer may override the default.

    Declaration

    Swift

    @inlinable
    func set(justification: GtkJustification)
  • set(leftMargin:) Extension method

    Sets the default left margin for text in 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.

    Declaration

    Swift

    @inlinable
    func set(leftMargin: Int)
  • set(monospace:) Extension method

    Sets the GtkTextView:monospace property, which indicates that the text view should use monospace fonts.

    Declaration

    Swift

    @inlinable
    func set(monospace: Bool)
  • set(overwrite:) Extension method

    Changes the GtkTextView overwrite mode.

    Declaration

    Swift

    @inlinable
    func set(overwrite: Bool)
  • set(pixelsAboveLines:) Extension method

    Sets the default number of blank pixels above paragraphs in text_view. Tags in the buffer for text_view may override the defaults.

    Declaration

    Swift

    @inlinable
    func set(pixelsAboveLines: Int)
  • set(pixelsBelowLines:) Extension method

    Sets the default number of pixels of blank space to put below paragraphs in text_view. May be overridden by tags applied to text_view’s buffer.

    Declaration

    Swift

    @inlinable
    func set(pixelsBelowLines: Int)
  • set(pixelsInsideWrap:) Extension method

    Sets the default number of pixels of blank space to leave between display/wrapped lines within a paragraph. May be overridden by tags in text_view’s buffer.

    Declaration

    Swift

    @inlinable
    func set(pixelsInsideWrap: Int)
  • set(rightMargin:) Extension method

    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.

    Declaration

    Swift

    @inlinable
    func set(rightMargin: Int)
  • set(tabs:) Extension method

    Sets the default tab stops for paragraphs in text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    func set<TabArrayT>(tabs: TabArrayT) where TabArrayT : TabArrayProtocol
  • set(topMargin:) Extension method

    Sets the top margin for text in text_view.

    Note that this function is confusingly named. In CSS terms, the value set here is padding.

    Declaration

    Swift

    @inlinable
    func set(topMargin: Int)
  • set(wrapMode:) Extension method

    Sets the line wrapping for the view.

    Declaration

    Swift

    @inlinable
    func set(wrapMode: GtkWrapMode)
  • startsDisplayLine(iter:) Extension method

    Determines whether iter is at the start of a display line. See gtk_text_view_forward_display_line() for an explanation of display lines vs. paragraphs.

    Declaration

    Swift

    @inlinable
    func startsDisplayLine<TextIterT>(iter: TextIterT) -> Bool where TextIterT : TextIterProtocol
  • Converts coordinates on the window identified by win to buffer coordinates, storing the result in (buffer_x,buffer_y).

    Note that you can’t convert coordinates for a nonexisting window (see gtk_text_view_set_border_window_size()).

    Declaration

    Swift

    @inlinable
    func windowToBufferCoords(win: GtkTextWindowType, windowX: Int, windowY: Int, bufferX: UnsafeMutablePointer<gint>! = nil, bufferY: UnsafeMutablePointer<gint>! = nil)
  • acceptsTab Extension method

    Returns whether pressing the Tab key inserts a tab characters. gtk_text_view_set_accepts_tab().

    Declaration

    Swift

    @inlinable
    var acceptsTab: Bool { get nonmutating set }
  • bottomMargin Extension method

    Gets the bottom margin for text in the text_view.

    Declaration

    Swift

    @inlinable
    var bottomMargin: Int { get nonmutating set }
  • buffer Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var buffer: TextBufferRef! { get nonmutating set }
  • cursorVisible Extension method

    Find out whether the cursor should be displayed.

    Declaration

    Swift

    @inlinable
    var cursorVisible: Bool { get nonmutating set }
  • defaultAttributes Extension method

    Obtains a copy of the default text attributes. These are the attributes used for text unless a tag overrides them. You’d typically pass the default attributes in to gtk_text_iter_get_attributes() in order to get the attributes in effect at a given text position.

    The return value is a copy owned by the caller of this function, and should be freed with gtk_text_attributes_unref().

    Declaration

    Swift

    @inlinable
    var defaultAttributes: TextAttributesRef! { get }
  • editable Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var editable: Bool { get nonmutating set }
  • hadjustment Extension method

    Gets the horizontal-scrolling GtkAdjustment.

    get_hadjustment is deprecated: Use gtk_scrollable_get_hadjustment()

    Declaration

    Swift

    @inlinable
    var hadjustment: AdjustmentRef! { get }
  • indent Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var indent: Int { get nonmutating set }
  • inputHints Extension method

    Gets the value of the GtkTextView:input-hints property.

    Declaration

    Swift

    @inlinable
    var inputHints: InputHints { get nonmutating set }
  • inputPurpose Extension method

    Gets the value of the GtkTextView:input-purpose property.

    Declaration

    Swift

    @inlinable
    var inputPurpose: GtkInputPurpose { get nonmutating set }
  • justification Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var justification: GtkJustification { get nonmutating set }
  • leftMargin Extension method

    Gets the default left margin size of paragraphs in the text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    var leftMargin: Int { get nonmutating set }
  • monospace Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var monospace: Bool { get nonmutating set }
  • overwrite Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var overwrite: Bool { get nonmutating set }
  • pixelsAboveLines Extension method

    Gets the default number of pixels to put above paragraphs. Adding this function with gtk_text_view_get_pixels_below_lines() is equal to the line space between each paragraph.

    Declaration

    Swift

    @inlinable
    var pixelsAboveLines: Int { get nonmutating set }
  • pixelsBelowLines Extension method

    Gets the value set by gtk_text_view_set_pixels_below_lines().

    The line space is the sum of the value returned by this function and the value returned by gtk_text_view_get_pixels_above_lines().

    Declaration

    Swift

    @inlinable
    var pixelsBelowLines: Int { get nonmutating set }
  • pixelsInsideWrap Extension method

    Gets the value set by gtk_text_view_set_pixels_inside_wrap().

    Declaration

    Swift

    @inlinable
    var pixelsInsideWrap: Int { get nonmutating set }
  • rightMargin Extension method

    Gets the default right margin for text in text_view. Tags in the buffer may override the default.

    Declaration

    Swift

    @inlinable
    var rightMargin: Int { get nonmutating set }
  • tabs Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var tabs: Pango.TabArrayRef! { get nonmutating set }
  • topMargin Extension method

    Gets the top margin for text in the text_view.

    Declaration

    Swift

    @inlinable
    var topMargin: Int { get nonmutating set }
  • vadjustment Extension method

    Gets the vertical-scrolling GtkAdjustment.

    get_vadjustment is deprecated: Use gtk_scrollable_get_vadjustment()

    Declaration

    Swift

    @inlinable
    var vadjustment: AdjustmentRef! { get }
  • wrapMode Extension method

    Gets the line wrapping for the view.

    Declaration

    Swift

    @inlinable
    var wrapMode: GtkWrapMode { get nonmutating set }
  • parentInstance Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var parentInstance: GtkContainer { get }
  • text Extension method

    Undocumented

    Declaration

    Swift

    @inlinable
    var text: String { get nonmutating set }