4 @SuppressWarnings public class QTextEdit : QAbstractScrollArea{
10 WrapAtWordBoundaryOrAnywhere
12 public enum LineWrapMode {
18 public enum AutoFormatting {
20 AutoBulletList = 0x00000001,
32 nativehandle = QtXnl.createQObject(QType.qtTextEdit,
this, 0);
33 if (nativehandle == 0){
39 public bool create(@NotNilptr QWidget parent)
override {
40 nativehandle = QtXnl.createQObject(QType.qtTextEdit,
this, parent.nativehandle);
41 if (nativehandle == 0){
47 public static class onChangeListener{
62 onChangeListener lis = nilptr;
69 lis.onTextChanged(
this);
75 lis.onCursorPositionChanged(
this);
81 lis.onSelectionChanged(
this);
86 QtXnl.widget_set_bool_value(nativehandle, Constant.TESETREADONLY, breadOnly);
90 return QtXnl.widget_get_bool_value(nativehandle, Constant.TEGETREADONLY);
94 return QtXnl.widget_get_int_value(nativehandle, Constant.TEGETALIGNMENT);
98 return (WrapMode)QtXnl.widget_get_int_value(nativehandle, Constant.TEGETWRAPMODE);
102 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETWORDWRAPMODE, policy);
106 return (
String)QtXnl.core_getString(nativehandle, Constant.TETOHTML);
110 return (
String)QtXnl.core_getString(nativehandle, Constant.TETOPLAINTEXT);
114 QtXnl.widget_set_double_value(nativehandle, Constant.TESETFONTPOINTSIZE, s);
117 QtXnl.widget_slot_string(nativehandle, Constant.TESETFONTFAMILY, fontFamily);
120 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETFONTWEIGHT, w);
123 QtXnl.widget_set_bool_value(nativehandle, Constant.TESETFONTUNDERLINE, b);
126 QtXnl.widget_set_bool_value(nativehandle, Constant.TESETFONTITALIC, b);
129 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETTEXTCOLOR, c);
132 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETTEXTBACKGROUNDCOLOR, c);
135 QtXnl.widget_set_native_value(nativehandle, Constant.TESETCURRENTFONT, f.nativehandle);
138 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETALIGNMENT, a);
142 QtXnl.widget_slot_string(nativehandle, Constant.TESETPLAINTEXT, text);
146 QtXnl.widget_slot_string(nativehandle, Constant.TESETHTML, text);
150 QtXnl.widget_slot_string(nativehandle, Constant.TESETTEXT, text);
155 QtXnl.widget_slot(nativehandle, Constant.TECUT);
158 QtXnl.widget_slot(nativehandle, Constant.TECOPY);
161 QtXnl.widget_slot(nativehandle,Constant. TEPASTE);
165 return (AutoFormatting)QtXnl.widget_get_int_value(nativehandle, Constant.TEGETAUTOFORMATTING);
168 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETAUTOFORMATTING, features);
171 return QtXnl.widget_get_bool_value(nativehandle, Constant.TETABCHANGESFOCUS);
174 QtXnl.widget_set_bool_value(nativehandle, Constant.TESETTABCHANGESFOCUS, b);
177 QtXnl.widget_slot_string(nativehandle, Constant.TESETPLACEHOLDERTEXT, placeholderText);
180 return (
String)QtXnl.core_getString(nativehandle, Constant.TEGETPLACEHOLDERTEXT);
183 QtXnl.widget_slot(nativehandle, Constant.TEUNDO);
186 QtXnl.widget_slot(nativehandle, Constant.TEREDO);
190 QtXnl.widget_slot(nativehandle, Constant.TECLEAR);
193 QtXnl.widget_slot(nativehandle, Constant.TESELECTALL);
197 QtXnl.widget_slot_string(nativehandle, Constant.TEINSERTPLAINTEXT, text);
201 QtXnl.widget_slot_string(nativehandle, Constant.TEINSERTHTML, text);
206 QtXnl.widget_slot_string(nativehandle, Constant.TEAPPEND, text);
210 QtXnl.widget_slot_string(nativehandle, Constant.TESCROLLTOANCHOR, name);
214 QtXnl.widget_set_vint_value(nativehandle, Constant.TEZOOMIN, range);
217 QtXnl.widget_set_vint_value(nativehandle, Constant.TEZOOMOUT, range);
220 QtXnl.widget_set_vint_value(nativehandle, Constant.TESETLINEWRAPMODE, mode);
void onTextChanged(QTextEdit obj)
void onSelectionChanged(QTextEdit obj)
void onCursorPositionChanged(QTextEdit obj)
void onSelectionChanged() override
void setText(String text)
void setFontPointSize(double s)
void setAutoFormatting(AutoFormatting features)
void insertHtml(String text)
void onCursorPositionChanged()
void setOnChangeListener(onChangeListener l)
void setPlaceholderText(String placeholderText)
void insertPlainText(String text)
bool create(@NotNilptr QWidget parent) override
void setTextBackgroundColor(int c)
void scrollToAnchor(String name)
void setTabChangesFocus(bool b)
void setCurrentFont(@NotNilptr QFont f)
void setFontWeight(int w)
void setHtml(String text)
void setLineWrapMode(LineWrapMode mode)
void setPlainText(String text)
void setFontFamily(String fontFamily)
void setReadOnly(bool breadOnly)
AutoFormatting autoFormatting()
void setFontItalic(bool b)
void setWordWrapMode(WrapMode policy)
void setFontUnderline(bool b)