ide-editor-view

ide-editor-view

Functions

Properties

gboolean auto-hide-map Read / Write
IdeBuffer * buffer Read / Write / Construct Only
IdeEditorSearch * search Read
gboolean show-map Read / Write
IdeSourceView * view Read

Types and Values

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── GtkWidget
            ╰── GtkContainer
                ╰── GtkBox
                    ╰── IdeLayoutView
                        ╰── IdeEditorView

Implemented Interfaces

IdeEditorView implements AtkImplementorIface, GtkBuildable and GtkOrientable.

Description

Functions

ide_editor_view_get_buffer ()

IdeBuffer *
ide_editor_view_get_buffer (IdeEditorView *self);

Gets the underlying buffer for the view.

Parameters

self

a IdeEditorView

 

Returns

An IdeBuffer.

[transfer none]

Since: 3.26


ide_editor_view_get_view ()

IdeSourceView *
ide_editor_view_get_view (IdeEditorView *self);

Gets the IdeSourceView that is part of the IdeEditorView.

Parameters

self

a IdeEditorView

 

Returns

An IdeSourceView.

[transfer none]

Since: 3.26


ide_editor_view_get_search ()

IdeEditorSearch *
ide_editor_view_get_search (IdeEditorView *self);

Gets the IdeEditorSearch used to search within the document.

Parameters

self

a IdeEditorView

 

Returns

An IdeEditorSearch.

[transfer none]


ide_editor_view_get_language_id ()

const gchar *
ide_editor_view_get_language_id (IdeEditorView *self);

This is a helper to get the language-id of the underlying buffer.

Parameters

self

a IdeEditorView

 

Returns

the language-id as a string, or NULL.

[nullable]

Since: 3.26


ide_editor_view_scroll_to_line ()

void
ide_editor_view_scroll_to_line (IdeEditorView *self,
                                guint line);

This is a helper to quickly jump to a given line without all the frills. It will also ensure focus on the editor view, so that refocusing the view afterwards does not cause the view to restore the cursor to the previous location.

This will move the insert cursor.

Lines start from 0.

Parameters

self

a IdeEditorView

 

line

the line to scroll to

 

ide_editor_view_scroll_to_line_offset ()

void
ide_editor_view_scroll_to_line_offset (IdeEditorView *self,
                                       guint line,
                                       guint line_offset);

Like ide_editor_view_scroll_to_line() but allows specifying the line offset (column) to place the cursor on.

This will move the insert cursor.

Lines and offsets start from 0.

If line_offset is zero, the first non-space character of line will be used instead.

Parameters

self

a IdeEditorView

 

line

the line to scroll to

 

line_offset

the line offset

 

ide_editor_view_get_auto_hide_map ()

gboolean
ide_editor_view_get_auto_hide_map (IdeEditorView *self);

ide_editor_view_set_auto_hide_map ()

void
ide_editor_view_set_auto_hide_map (IdeEditorView *self,
                                   gboolean auto_hide_map);

ide_editor_view_get_show_map ()

gboolean
ide_editor_view_get_show_map (IdeEditorView *self);

ide_editor_view_set_show_map ()

void
ide_editor_view_set_show_map (IdeEditorView *self,
                              gboolean show_map);

ide_editor_view_get_language ()

GtkSourceLanguage *
ide_editor_view_get_language (IdeEditorView *self);

Gets the GtkSourceLanguage that is used by the underlying buffer.

Parameters

self

a IdeEditorView

 

Returns

a GtkSourceLanguage or NULL.

[transfer none][nullable]

Since: 3.26


ide_editor_view_set_language ()

void
ide_editor_view_set_language (IdeEditorView *self,
                              GtkSourceLanguage *language);

This is a convenience function to set the language on the underlying IdeBuffer text buffer.

Parameters

self

a IdeEditorView

 

Since: 3.26


ide_editor_view_move_next_error ()

void
ide_editor_view_move_next_error (IdeEditorView *self);

Moves to the next error, if any.

If there is no error, the insertion cursor is not moved.

Parameters

self

a IdeEditorView

 

Since: 3.26


ide_editor_view_move_previous_error ()

void
ide_editor_view_move_previous_error (IdeEditorView *self);

Moves the insertion cursor to the previous error.

If there is no error, the insertion cursor is not moved.

Parameters

self

a IdeEditorView

 

Since: 3.26


ide_editor_view_move_next_search_result ()

void
ide_editor_view_move_next_search_result
                               (IdeEditorView *self);

Moves the insertion cursor to the next search result.

If there is no search result, the insertion cursor is not moved.

Parameters

self

a IdeEditorView

 

Since: 3.26


ide_editor_view_move_previous_search_result ()

void
ide_editor_view_move_previous_search_result
                               (IdeEditorView *self);

Moves the insertion cursor to the previous search result.

If there is no search result, the insertion cursor is not moved.

Parameters

self

a IdeEditorView

 

Since: 3.26

Types and Values

IDE_TYPE_EDITOR_VIEW

#define IDE_TYPE_EDITOR_VIEW (ide_editor_view_get_type())

IdeEditorView

typedef struct _IdeEditorView IdeEditorView;

Property Details

The “auto-hide-map” property

  “auto-hide-map”            gboolean

If the overview map should be auto-hidden.

Flags: Read / Write

Default value: FALSE


The “buffer” property

  “buffer”                   IdeBuffer *

The buffer for the view.

Flags: Read / Write / Construct Only


The “search” property

  “search”                   IdeEditorSearch *

An search helper for the document.

Flags: Read


The “show-map” property

  “show-map”                 gboolean

If the overview map should be shown.

Flags: Read / Write

Default value: FALSE


The “view” property

  “view”                     IdeSourceView *

The view for editing the buffer.

Flags: Read