 |
MPLABĀ® Harmony Graphics Suite
|
Go to the documentation of this file.
30 #ifndef LEGATO_FIXEDSTRING_H
31 #define LEGATO_FIXEDSTRING_H
38 #define LE_FIXEDSTRING_VTABLE(THIS_TYPE) \
39 LE_STRING_VTABLE(THIS_TYPE) \
41 leResult (*setBuffer)(THIS_TYPE* str, leChar* buf, uint32_t size); \
43 typedef struct leFixedStringVTable
46 } leFixedStringVTable;
59 const leFixedStringVTable*
fn;
104 #define THIS_TYPE struct leWidget
virtual leResult getCharIndexAtPoint(const leString *_this, const lePoint *pt, uint32_t *idx)
Get character index at point.
virtual leResult setFromString(leString *_this, const struct leString *src)
Set string value from another string.
virtual leResult remove(leString *_this, uint32_t idx, uint32_t count)
Remove substring.
leString base
Definition: legato_fixedstring.h:58
Error functions, macros and definitions.
leResult
This enum represents function call results.
Definition: legato_common.h:134
This struct represents a rectangle.
Definition: legato_common.h:405
virtual leResult getLineIndices(const leString *_this, uint32_t line, uint32_t *start, uint32_t *end)
Get indices of a string line.
struct leFixedString leFixedString
This struct represents a fixed string.
Memory functions and definitions.
leHAlignment
This enum represents the horizontal alignment mode of objects.
Definition: legato_common.h:206
uint32_t getLineCount(const leString *_this)
Get number of lines in the string.
virtual void preinvalidate(leString *_this)
Raise pre-invalidate event.
LIB_EXPORT void leFixedString_Constructor(leFixedString *str, leChar *buf, uint32_t size)
Consructs a fixed string.
Definition: legato_fixedstring.c:42
LIB_EXPORT leFixedString * leFixedString_New(leChar *buf, uint32_t size)
Create a new fixed string.
Definition: legato_fixedstring.c:60
This struct represents a font object.
Definition: legato_font.h:136
Definition: legato_string.h:98
This struct represents a string.
Definition: legato_string.h:108
virtual leResult setFromChar(leString *_this, const leChar *buf, uint32_t size)
Set string value from a leChar buffer.
virtual leChar charAt(const leString *_this, uint32_t idx)
Get codepoint at the given index.
virtual leResult setPreInvalidateCallback(leString *_this, leString_InvalidateCallback, void *userData)
Set string invalidate event.
const leFont * font
Definition: legato_fixedstring.h:63
const leFixedStringVTable * fn
Definition: legato_fixedstring.h:59
leBool
This enum represents booleans.
Definition: legato_common.h:157
uint16_t capacity
Definition: legato_fixedstring.h:61
virtual uint32_t length(const leString *_this)
Get length of the string.
virtual leResult setFont(leString *_this, const leFont *font)
Set font.
virtual leResult insert(leString *_this, const struct leString *val, uint32_t idx)
Insert string at a given index.
virtual leResult setBuffer(leFixedString *_this, leChar *buf, uint32_t size)
Set capacity of the dynamic string.
Fixed string functions and definitions.
virtual int32_t compare(const leString *_this, const struct leString *tgt)
Compare string to another string.
leChar * data
Definition: legato_fixedstring.h:60
This struct represents a fixed string.
Definition: legato_fixedstring.h:57
uint16_t leChar
This typedef represents Legato character.
Definition: legato_common.h:424
virtual uint32_t toChar(const leString *_this, leChar *buf, uint32_t size)
Convert string to a C-style string.
virtual leFont * getFont(const leString *_this)
Get font.
Fixed string functions and definitions.
virtual leBool isEmpty(const leString *_this)
Determine if string is empty.
virtual leResult append(leString *_this, const struct leString *val)
Append string.
virtual void clear(leString *_this)
Clear string.
const leStringVTable * fn
Definition: legato_string.h:109
virtual void destructor(leString *_this)
Destruct string.
uint16_t length
Definition: legato_fixedstring.h:62
virtual leResult setFromCStr(leString *_this, const char *cstr)
Set string value from a C string buffer.
This structure represents a integer Cartesian point.
Definition: legato_common.h:357