sombok
2.3.0
|
Functions | ||||||||||||||||
Preprocessing callback | ||||||||||||||||
gcstring_t *callback(linebreak_t *lbobj, void *data, unistr_t *str, unistr_t *text) Preprocessing behaviors specified by item of
On the first pass, when text is not NULL, it should return the first occurrance in substr matching its criteria, update substr->str to be matching position and substr->len to be length. Otherwise, should set NULL to substr->str. Return value shall be discarded. On the second pass, when text is NULL, it should return new grapheme cluster string created from substr. Return value should not share Unicode buffer with substr (i.e. use gcstring_newcopy()). If error occurred, callback must set lbobj->errnum nonzero then return NULL. | ||||||||||||||||
gcstring_t * | linebreak_prep_URIBREAK (linebreak_t *lbobj, void *data, unistr_t *str, unistr_t *text) | |||||||||||||||
Sizing callback | ||||||||||||||||
double callback(linebreak_t *obj, double len, gcstring_t *pre, gcstring_t *spc, gcstring_t *str) Sizing behavior specified by
| ||||||||||||||||
double | linebreak_sizing_UAX11 (linebreak_t *obj, double len, gcstring_t *pre, gcstring_t *spc, gcstring_t *str) | |||||||||||||||
Formatting callback | ||||||||||||||||
gcstring_t *callback(linebreak_t *lbobj, linebreak_state_t state, gcstring_t *gcstr) Formatting behaviors specified by
Following table describes behavior of built-in format callbacks. * state| SIMPLE | NEWLINE | TRIM * -----+-----------------+-------------------+------------------- * SOT | * SOP | not modify * SOL | * LINE | * EOL | append newline | replace by newline| replace by newline * EOP | not modify | replace by newline| remove SPACEs * EOT | not modify | replace by newline| remove SPACEs * ---------------------------------------------------------------- * | ||||||||||||||||
gcstring_t * | linebreak_format_SIMPLE (linebreak_t *lbobj, linebreak_state_t state, gcstring_t *gcstr) | |||||||||||||||
gcstring_t * | linebreak_format_NEWLINE (linebreak_t *lbobj, linebreak_state_t state, gcstring_t *gcstr) | |||||||||||||||
gcstring_t * | linebreak_format_TRIM (linebreak_t *lbobj, linebreak_state_t state, gcstring_t *gcstr) | |||||||||||||||
Urgent breaking callbacks | ||||||||||||||||
gcstring_t *callback(linebreak_t *lbobj, gcstring_t *str) Urgent breaking behaviors specified by
There are two built-in urgent breaking callbacks. | ||||||||||||||||
gcstring_t * | linebreak_urgent_ABORT (linebreak_t *lbobj, gcstring_t *str) | |||||||||||||||
gcstring_t * | linebreak_urgent_FORCE (linebreak_t *lbobj, gcstring_t *str) | |||||||||||||||