| Top |
| IBusAttribute * | ibus_attribute_new () |
| guint | ibus_attribute_get_attr_type () |
| guint | ibus_attribute_get_value () |
| guint | ibus_attribute_get_start_index () |
| guint | ibus_attribute_get_end_index () |
| IBusAttribute * | ibus_attr_underline_new () |
| IBusAttribute * | ibus_attr_foreground_new () |
| IBusAttribute * | ibus_attr_background_new () |
| IBusAttribute * | ibus_attr_hint_new () |
GEnum ├── IBusAttrType ╰── IBusAttrUnderline GObject ╰── GInitiallyUnowned ╰── IBusObject ╰── IBusSerializable ╰── IBusAttribute
An IBusAttribute represents an attribute that associate to IBusText. It decorates preedit buffer and auxiliary text with underline, foreground and background colors.
IBusAttribute * ibus_attribute_new (guint type,guint value,guint start_index,guint end_index);
Creates a new IBusAttribute.
guint
ibus_attribute_get_attr_type (IBusAttribute *attr);
Gets an enum of IBusAttrType.
guint
ibus_attribute_get_value (IBusAttribute *attr);
Gets an unsigned int value relative with IBusAttrType.
If the type is IBUS_ATTR_TYPE_UNDERLINE, the return value is
IBusAttrUnderline. If the type is IBUS_ATTR_TYPE_FOREGROUND,
the return value is the color RGB. if the type is IBUS_ATTR_TYPE_HINT,
the return value is the value of IBusAttrPreedit.
guint
ibus_attribute_get_start_index (IBusAttribute *attr);
Gets a start unsigned index
guint
ibus_attribute_get_end_index (IBusAttribute *attr);
Gets an end unsigned index
IBusAttribute * ibus_attr_underline_new (guint underline_type,guint start_index,guint end_index);
ibus_attr_underline_new has been deprecated since version 1.5.33 and should not be used in newly-written code.
Use ibus_attr_hint_new().
Creates a new underline IBusAttribute.
Workaround of "transfer none" for ibus_attr_list_append().
IBusAttribute * ibus_attr_foreground_new (guint color,guint start_index,guint end_index);
ibus_attr_foreground_new has been deprecated since version 1.5.33 and should not be used in newly-written code.
Use ibus_attr_hint_new().
Creates a new foreground IBusAttribute.
Workaround of "transfer none" for ibus_attr_list_append().
IBusAttribute * ibus_attr_background_new (guint color,guint start_index,guint end_index);
ibus_attr_background_new has been deprecated since version 1.5.33 and should not be used in newly-written code.
Use ibus_attr_hint_new().
Creates a new background IBusAttribute.
Workaround of "transfer none" for ibus_attr_list_append().
IBusAttribute * ibus_attr_hint_new (guint hint,guint start_index,guint end_index);
Creates a new hint attribute IBusAttribute.
Workaround of "transfer none" for ibus_attr_list_append().
hint |
Only IBusAttrPreedit is supported at present. |
|
start_index |
Where attribute starts. |
|
end_index |
Where attribute ends. |
Since: 1.5.33
Stability Level: Unstable
Type enumeration of IBusText attribute.
|
Decorate with underline. |
||
|
Foreground color. |
||
|
Background color. |
||
|
Use the preedit hint and each engine does not specify the RGBA values but IBus panel or the Wayland panel decides the actual values. Since: 1.5.33 |
Stability Level: Stable
Type of Pre-edit style as the semantic name. The Wayland specs prefers to express the semantic values rather than RGB values and text-input protocol version 1 defines some values: https://gitlab.freedesktop.org/wayland/wayland-protocols/-/blob/main/unstable/text-input/text-input-unstable-v1.xml?ref_type=headsL251
IBus compiled the values for major input method engines: https://github.com/ibus/ibus/wiki/Wayland-Colors
|
Default style for composing text and used in
the internal logic only with the Wayland
text-input protocol V1. Each IBusEngine
should not use it with |
||
|
Most language engines wish to draw underline in the typed whole preedit string except for the prediction string. (Chinese, Japanese, Typing-booster) |
||
|
Modifying an active segment is distinguished against whole the preedit text. (Hangul, Japanese) |
||
|
A prediction string can be appended after the typed string. (Typing-booster) |
||
|
A prefix string can be an informative color. (Table) |
||
|
A suffix string can be an informative color. (Table) |
||
|
An detected typo could be an error color with a spelling check or the word could not be found in a dictionary. The underline color also might be more visible. (Typing-booster, Table) |
||
|
A wrong compose key could be an error color. (Typing-booster) |
||
|
Designed for non-composing text with the Wayland text-input protocol V1 but this is deprecated. |
Since: 1.5.29
Stability Level: Unstable