This function allows you to define actions directly in the CSS, rather than referencing them from the associated framework.
The oxy_action() function is frequently used from the oxy_button() function that provides a graphical
button for invoking a custom action. The action is normally defined in the associated Document
Type (framework configuration) but the oxy_action() function
allows you to define it directly in the CSS instead of the framework
configuration.
The arguments received by the oxy_action() function are a list of properties
that define an action. The following properties are supported:
/ (for example, /images/Remove16.png). It can
also be expressed using an editor
variable.arg- prefix are passed to the operation (the string that follows the
arg- prefix is passed). The argument value supports editor variables.oxy_button(
action, oxy_action(
name, 'Insert',
description, 'Insert an element after the current one',
icon, url('insert.png'),
operation,
'InsertFragmentOperation',
arg-fragment, '<element>${caret}</element>',
arg-insertLocation, '.',
arg-insertPosition, 'After'),
showIcon, true)Example: oxy_action Function
oxy_action
function:oxy_action(
name, 'Insert',
description, 'Insert an element after the current one',
operation, 'InsertFragmentOperation',
arg-fragment, '<element>${caret}</element>',
arg-insertLocation, '.',
arg-insertPosition, 'After')oxy_action function with the Content Completion
Assistant by pressing Ctrl +
Space and select the
oxy_action code template.