InfTextGtk.Viewport¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
|---|---|---|---|
r/w |
The user for which to show the viewport |
||
r/w/co |
The underlying |
||
r/w |
Whether to indicate the position of non-local user’s cursors in the scrollbar |
||
r/w/co |
The user table containing the users of the session shown in the viewport |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
|---|---|---|---|
parent |
r |
Class Details¶
- class InfTextGtk.Viewport(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
InfTextGtk.Viewportis an opaque data type. You should only access it via the public API functions.- classmethod new(scroll, user_table)¶
- Parameters:
scroll (
Gtk.ScrolledWindow) – AGtk.ScrolledWindow.user_table (
Infinity.UserTable) – TheInfinity.UserTablefor the text session displayed in viewport.
- Returns:
A new
InfTextGtk.Viewport.- Return type:
Creates a new
InfTextGtk.Viewportfor scroll. This draws the position of remote user’s cursors into the scrollbars of scroll.
- get_active_user()¶
- Returns:
The active user of self.
- Return type:
InfText.UserorNone
Returns the active user of self. See
InfTextGtk.Viewport.set_active_user().
- get_scrolled_window()¶
- Returns:
- Return type:
Returns the underlying
Gtk.ScrolledWindow.
- get_user_table()¶
- Returns:
- Return type:
Returns the
Infinity.UserTablecontaining the users of the session theInfTextGtk.Viewport'sGtk.ScrolledWindowis displaying.
- set_active_user(user)¶
- Parameters:
user (
InfText.UserorNone) – A user from self's user table, orNone.
Sets the user for which perspective to draw the viewport. The cursor position for teh active user is not draws since it is assumed that the viewport’s “real” scrollbars match the active user’s position.
- set_show_user_markers(show)¶
- Parameters:
show (
bool) – Whether to show the position of non-local users.
If show is
Truethen draw a marker indicating the cursor position of all non-local users with statusInfinity.UserStatus.ACTIVEin the scrollbar of the scrolled window. If show isFalsethen do not draw user markers into the scrollbar.
Property Details¶
- InfTextGtk.Viewport.props.active_user¶
- Name:
active-user- Type:
- Default Value:
- Flags:
The user for which to show the viewport
- InfTextGtk.Viewport.props.scrolled_window¶
- Name:
scrolled-window- Type:
- Default Value:
- Flags:
The underlying
Gtk.ScrolledWindow
- InfTextGtk.Viewport.props.show_user_markers¶
-
Whether to indicate the position of non-local user’s cursors in the scrollbar
- InfTextGtk.Viewport.props.user_table¶
- Name:
user-table- Type:
- Default Value:
- Flags:
The user table containing the users of the session shown in the viewport