mirror of
https://github.com/lc-soft/LCUI.git
synced 2026-11-30 16:48:21 +01:00
修改文本框的文本处理
This commit is contained in:
@@ -144,12 +144,28 @@ LCUI_EXPORT(void)
|
||||
TextLayer_Print_Info( LCUI_TextLayer *layer );
|
||||
/* 打印文本图层信息 */
|
||||
|
||||
/*
|
||||
* 功能:设定指定的宽字符串作为文本图层中显示的文本
|
||||
* 说明:文本将被储存至缓冲区,等待绘制文本位图时再处理缓冲区内的文本
|
||||
* */
|
||||
LCUI_EXPORT(void)
|
||||
TextLayer_WText( LCUI_TextLayer *layer, const wchar_t *wchar_text );
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextLayer_Text( LCUI_TextLayer *layer, const char *utf8_text );
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextLayer_AText( LCUI_TextLayer *layer, const char *ascii_text );
|
||||
|
||||
/* 在文本末尾追加文本,不移动光标,不删除原有选中文本 */
|
||||
LCUI_EXPORT(int)
|
||||
TextLayer_WText_Append( LCUI_TextLayer *layer, wchar_t *new_text );
|
||||
|
||||
LCUI_EXPORT(int)
|
||||
TextLayer_AText_Append( LCUI_TextLayer *layer, char *new_text );
|
||||
|
||||
LCUI_EXPORT(int)
|
||||
TextLayer_Text_Append( LCUI_TextLayer *layer, char *new_text );
|
||||
/* 在文本末尾追加文本,不移动光标,不删除原有选中文本 */
|
||||
|
||||
LCUI_EXPORT(int)
|
||||
TextLayer_WText_Add( LCUI_TextLayer *layer, wchar_t *unicode_text );
|
||||
|
||||
@@ -49,9 +49,6 @@
|
||||
|
||||
LCUI_BEGIN_HEADER
|
||||
|
||||
LCUI_EXPORT(LCUI_Widget*)
|
||||
TextBox_GetLabel( LCUI_Widget *widget );
|
||||
/* 获取文本框部件内的label部件指针 */
|
||||
|
||||
LCUI_EXPORT(LCUI_Pos)
|
||||
TextBox_ViewArea_GetPos( LCUI_Widget *widget );
|
||||
@@ -61,45 +58,58 @@ LCUI_EXPORT(int)
|
||||
TextBox_ViewArea_Update( LCUI_Widget *widget );
|
||||
/* 更新文本框的文本显示区域 */
|
||||
|
||||
/* 获取文本框部件内的label部件指针 */
|
||||
LCUI_EXPORT(LCUI_Widget*)
|
||||
TextBox_GetLabel( LCUI_Widget *widget );
|
||||
|
||||
/* 获取文本框部件内的光标 */
|
||||
LCUI_EXPORT(LCUI_Widget*)
|
||||
TextBox_GetCursor( LCUI_Widget *widget );
|
||||
/* 获取文本框部件内的光标 */
|
||||
|
||||
/* 获取文本框内的文本总长度 */
|
||||
LCUI_EXPORT(int)
|
||||
TextBox_Text_GetTotalLength( LCUI_Widget *widget );
|
||||
|
||||
/* 设定文本框显示的文本 */
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_WText( LCUI_Widget *widget, wchar_t *unicode_text );
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_Text(LCUI_Widget *widget, char *new_text);
|
||||
/* 设定文本框显示的文本 */
|
||||
TextBox_Text( LCUI_Widget *widget, char *utf8_text );
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_TextLayer_SetOffset( LCUI_Widget *widget, LCUI_Pos offset_pos );
|
||||
/* 为文本框内的文本图层设置偏移 */
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_Text_Add(LCUI_Widget *widget, char *new_text);
|
||||
/* 在光标处添加文本 */
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_WText_Add( LCUI_Widget *widget, wchar_t *unicode_text );
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_Text_Append(LCUI_Widget *widget, char *new_text);
|
||||
TextBox_AText_Add( LCUI_Widget *widget, char *ascii_text );
|
||||
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_Text_Add( LCUI_Widget *widget, char *utf8_text );
|
||||
|
||||
/* 在文本末尾追加文本 */
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_WText_Append( LCUI_Widget *widget, wchar_t *unicode_text );
|
||||
|
||||
/* 在文本末尾追加文本 */
|
||||
LCUI_EXPORT(void)
|
||||
TextBox_Text_Append( LCUI_Widget *widget, char *utf8_text );
|
||||
|
||||
LCUI_EXPORT(int)
|
||||
TextBox_Text_Backspace(LCUI_Widget *widget, int n);
|
||||
/* 删除光标左边处n个字符 */
|
||||
|
||||
LCUI_EXPORT(int)
|
||||
TextBox_Text_Delete(LCUI_Widget *widget, int n);
|
||||
/* 删除光标右边处n个字符 */
|
||||
|
||||
/* 获取文本框内的文本总长度 */
|
||||
LCUI_EXPORT(int)
|
||||
TextBox_Text_GetTotalLength( LCUI_Widget *widget );
|
||||
|
||||
LCUI_EXPORT(LCUI_Pos)
|
||||
TextBox_Cursor_Update( LCUI_Widget *widget );
|
||||
/* 更新文本框的光标,返回该光标的像素坐标 */
|
||||
|
||||
LCUI_EXPORT(LCUI_Pos)
|
||||
TextBox_Cursor_Move( LCUI_Widget *widget, LCUI_Pos new_pos );
|
||||
/* 移动文本框内的光标,返回该光标的像素坐标 */
|
||||
/* 移动文本框内的光标 */
|
||||
|
||||
LCUI_EXPORT(int)
|
||||
TextBox_GetSelectedText( LCUI_Widget *widget, char *out_text );
|
||||
|
||||
Reference in New Issue
Block a user