![]() |
![]() |
![]() |
libfep-glib Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Implemented Interfaces | Properties | Signals |
struct FepGClient; struct FepGClientClass; gboolean fep_g_client_dispatch (FepGClient *client
); gint fep_g_client_get_poll_fd (FepGClient *client
); FepGClient * fep_g_client_new (const char *address
,GCancellable *cancellable
,GError **error
); void fep_g_client_send_data (FepGClient *client
,const char *data
,gsize length
); void fep_g_client_send_text (FepGClient *client
,const char *text
); void fep_g_client_set_cursor_text (FepGClient *client
,const char *text
,FepGAttribute *attr
); void fep_g_client_set_status_text (FepGClient *client
,const char *text
,FepGAttribute *attr
);
struct FepGClientClass { /* signals */ gboolean (*filter_key_event) (FepGClient *client, guint keyval, guint modifiers); void (*resized) (FepGClient *client, guint cols, guint rows); };
class handler for "filter-key-event" | |
class handler for "resized" |
gboolean fep_g_client_dispatch (FepGClient *client
);
Dispatch a key event.
|
a FepGClient |
Returns : |
TRUE if success, FALSE on error. |
gint fep_g_client_get_poll_fd (FepGClient *client
);
Get the file descriptor of the control socket which can be used by poll()
.
|
a FepGClient |
Returns : |
a file descriptor |
FepGClient * fep_g_client_new (const char *address
,GCancellable *cancellable
,GError **error
);
Connect to the FEP server running at address
. If address
is
NULL
, it gets the address from the environment variable
`LIBFEP_CONTROL_SOCK`.
|
socket address of the FEP server. [allow-none] |
|
a GCancellable or NULL
|
|
a pointer to a NULL GError, or NULL
|
Returns : |
a new FepGClient. |
void fep_g_client_send_data (FepGClient *client
,const char *data
,gsize length
);
Request to send data
to the child process of the FEP server.
|
a FepGClient |
|
data to be sent |
|
length of data
|
void fep_g_client_send_text (FepGClient *client
,const char *text
);
Request to send data
to the child process of the FEP server.
text
will be converted from UTF-8 to the local encoding in the
server.
|
a FepGClient |
|
text to be sent |
void fep_g_client_set_cursor_text (FepGClient *client
,const char *text
,FepGAttribute *attr
);
Request to display text
at the cursor position on the terminal.
|
a FepGClient |
|
a cursor text |
|
a FepGAttribute. [allow-none] |
void fep_g_client_set_status_text (FepGClient *client
,const char *text
,FepGAttribute *attr
);
Request to display text
at the bottom of the terminal.
|
a FepGClient |
|
a status text |
|
a FepGAttribute. [allow-none] |
"filter-key-event"
signalgboolean user_function (FepGClient *client,
guint keyval,
guint modifiers,
gpointer user_data) : Run Last
The ::filter-key-event signal is emitted when key event is dispatched.
|
a FepGClient |
|
a keyval |
|
modifier mask |
|
user data set when the signal handler was connected. |
"resized"
signalvoid user_function (FepGClient *client,
guint cols,
guint rows,
gpointer user_data) : Run Last
The ::resized signal is emitted when terminal is resized.
|
a FepGClient |
|
number of columns |
|
number of rows |
|
user data set when the signal handler was connected. |