![]() |
![]() |
![]() |
libinftext-0.5 Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Properties | Signals |
InfTextUser; InfTextUser * inf_text_user_new (guint id
,const gchar *name
,InfAdoptedStateVector *vector
,double hue
); guint inf_text_user_get_caret_position (InfTextUser *user
); gint inf_text_user_get_selection_length (InfTextUser *user
); void inf_text_user_set_selection (InfTextUser *user
,guint position
,gint length
,gboolean by_request
); gdouble inf_text_user_get_hue (InfTextUser *user
);
"caret-position" guint : Read / Write / Construct "hue" gdouble : Read / Write / Construct "selection-length" gint : Read / Write / Construct
InfTextUser * inf_text_user_new (guint id
,const gchar *name
,InfAdoptedStateVector *vector
,double hue
);
Creates a new InfTextUser. id
should be unique for all users working
together. InfUserTable will refuse to add users with duplicate id. If
vector
is NULL
, then the vector with all components zero is used.
|
The user ID for this user. |
|
The user's name. |
|
The state at which the user is at, or NULL .
|
|
The hue value of the user's color. |
Returns : |
A new InfTextUser. Free with g_object_unref() when no longer
needed.
|
guint inf_text_user_get_caret_position (InfTextUser *user
);
Returns the position of user
's caret.
|
A InfTextUser. |
Returns : |
user 's caret position.
|
gint inf_text_user_get_selection_length (InfTextUser *user
);
Returns the number of characters this user has selected, starting from the caret position. Negative number mean selection towards the beginning of the buffer.
|
A InfTextUser. |
Returns : |
user 's selection length in characters.
|
void inf_text_user_set_selection (InfTextUser *user
,guint position
,gint length
,gboolean by_request
);
Changes user
's selection (i.e. caret position and selection length).
|
A InfTextUser. |
|
The new position for the user's caret. |
|
The number of characters to select. Negative numbers mean selection towards the beginning. |
|
gdouble inf_text_user_get_hue (InfTextUser *user
);
Returns the hue of the user's color as a double ranging from 0 to 1. The other components (saturation and lightness) are not specific to the user and may be chosen indivudually to optimize the actual visual display.
|
A InfTextUser. |
Returns : |
The hue of the user 's color.
|
"caret-position"
property "caret-position" guint : Read / Write / Construct
The position of this user's caret.
Default value: 0
"hue"
property "hue" gdouble : Read / Write / Construct
The hue value of the user's color. saturation and lightness are set by each client individually.
Allowed values: [0,1]
Default value: 0
"selection-changed"
signalvoid user_function (InfTextUser *inftextuser, guint arg1, gint arg2, gboolean arg3, gpointer user_data) : Run Last
|
the object which received the signal. |
|
|
|
|
|
|
|
user data set when the signal handler was connected. |