23 static void rna_Text_clear(
Text *text)
29 static void rna_Text_write(
Text *text,
const char *
str)
35 static void rna_Text_from_string(
Text *text,
const char *
str)
41 static void rna_Text_as_string(
Text *text,
int *r_result_len,
const char **
result)
45 *r_result_len = result_len;
48 static void rna_Text_select_set(
Text *text,
int startl,
int startc,
int endl,
int endc)
54 static void rna_Text_cursor_set(
Text *text,
int line,
int ch,
bool select)
72 func,
"write text at the cursor location and advance to the end of the text block");
73 parm =
RNA_def_string(func,
"text",
"Text", 0,
"",
"New text for this data-block");
87 srna,
"is_syntax_highlight_supported",
"ED_text_is_syntax_highlight_supported");
91 "Returns True if the editor supports syntax highlighting "
92 "for the current text datablock");
96 parm =
RNA_def_int(func,
"line_start", 0, INT_MIN, INT_MAX,
"Start Line",
"", INT_MIN, INT_MAX);
99 func,
"char_start", 0, INT_MIN, INT_MAX,
"Start Character",
"", INT_MIN, INT_MAX);
101 parm =
RNA_def_int(func,
"line_end", 0, INT_MIN, INT_MAX,
"End Line",
"", INT_MIN, INT_MAX);
103 parm =
RNA_def_int(func,
"char_end", 0, INT_MIN, INT_MAX,
"End Character",
"", INT_MIN, INT_MAX);
108 parm =
RNA_def_int(func,
"line", 0, 0, INT_MAX,
"Line",
"", 0, INT_MAX);
110 parm =
RNA_def_int(func,
"character", 0, 0, INT_MAX,
"Character",
"", 0, INT_MAX);
111 RNA_def_boolean(func,
"select",
false,
"",
"Select when moving the cursor");
void txt_sel_set(struct Text *text, int startl, int startc, int endl, int endc)
struct Text struct Text void BKE_text_clear(struct Text *text) ATTR_NONNULL(1)
char * txt_to_buf(struct Text *text, size_t *r_buf_strlen) ATTR_NONNULL(1
void txt_move_to(struct Text *text, unsigned int line, unsigned int ch, bool sel)
void BKE_text_write(struct Text *text, const char *str, int str_len) ATTR_NONNULL(1
__forceinline const avxb select(const avxb &m, const avxb &t, const avxb &f)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, bool default_value, const char *ui_name, const char *ui_description)
void RNA_def_function_return(FunctionRNA *func, PropertyRNA *ret)
FunctionRNA * RNA_def_function(StructRNA *srna, const char *identifier, const char *call)
void RNA_def_function_ui_description(FunctionRNA *func, const char *description)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, int maxlen, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, int default_value, int hardmin, int hardmax, const char *ui_name, const char *ui_description, int softmin, int softmax)
void RNA_def_parameter_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void RNA_api_text(StructRNA *srna)
void WM_main_add_notifier(unsigned int type, void *reference)