![]() |
![]() |
![]() |
Mx Toolkit Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Properties | Signals |
struct MxAction; MxAction * mx_action_new (void
); MxAction * mx_action_new_full (const gchar *name
,const gchar *display_name
,GCallback activated_cb
,gpointer user_data
); const gchar * mx_action_get_name (MxAction *action
); void mx_action_set_name (MxAction *action
,const gchar *name
); const gchar * mx_action_get_display_name (MxAction *action
); void mx_action_set_display_name (MxAction *action
,const gchar *name
); const gchar * mx_action_get_icon (MxAction *action
); void mx_action_set_icon (MxAction *action
,const gchar *name
); gboolean mx_action_get_active (MxAction *action
); void mx_action_set_active (MxAction *action
,gboolean active
);
"active" gboolean : Read / Write "display-name" gchar* : Read / Write "icon" gchar* : Read / Write "name" gchar* : Read / Write
Actions represent operations that the user can perform, such as items in a menu or toolbar.
struct MxAction;
The contents of this structure are private and should only be accessed through the public API.
MxAction * mx_action_new (void
);
Create a new, blank, MxAction
Returns : |
a newly allocated MxAction |
MxAction * mx_action_new_full (const gchar *name
,const gchar *display_name
,GCallback activated_cb
,gpointer user_data
);
Create a new MxAction with the name and callback set
|
name of the action |
|
name of the action to display to the user |
|
callback to connect to the activated signal |
|
user data to be passed to the callback |
Returns : |
a newly allocation MxAction |
const gchar * mx_action_get_name (MxAction *action
);
Get the name of the action
|
A MxAction |
Returns : |
name of the action, owned by MxAction |
void mx_action_set_name (MxAction *action
,const gchar *name
);
Set the name of the action
|
A MxAction |
|
new name to set |
const gchar * mx_action_get_display_name (MxAction *action
);
Get the display name of the action
|
A MxAction |
Returns : |
display-name of the action, owned by MxAction |
void mx_action_set_display_name (MxAction *action
,const gchar *name
);
Set the name of the action to display to the user
|
A MxAction |
|
new display name to set |
const gchar * mx_action_get_icon (MxAction *action
);
Get the icon of the action
|
A MxAction |
Returns : |
icon of the action, owned by MxAction |
void mx_action_set_icon (MxAction *action
,const gchar *name
);
The icon to be used in a visual representation of an action.
|
A MxAction |
|
new icon to set |
gboolean mx_action_get_active (MxAction *action
);
Get the value of the active property
"active"
property"active" gboolean : Read / Write
Whether the action is active.
Default value: TRUE
"display-name"
property"display-name" gchar* : Read / Write
Localised name to use for display.
Default value: NULL
"icon"
property"icon" gchar* : Read / Write
Icon name or path to to be used if this action is displayed.
Default value: NULL