@@ -215,7 +215,38 @@ public final class ImDrawList {
215
215
IM_DRAW_LIST->AddText(ImVec2(posX, posY), col, textBegin, textEnd);
216
216
*/
217
217
218
- // TODO add text with font support
218
+ public void addText (ImFont imFont , float fontSize , float posX , float posY , int col , String textBegin ) {
219
+ nAddText (imFont .ptr , fontSize , posX , posY , col , textBegin );
220
+ }
221
+
222
+ private native void nAddText (long imFontPtr , float fontSize , float posX , float posY , int col , String textBegin ); /*
223
+ IM_DRAW_LIST->AddText((ImFont*)imFontPtr, fontSize, ImVec2(posX, posY), col, textBegin);
224
+ */
225
+
226
+ public void addText (ImFont imFont , float fontSize , float posX , float posY , int col , String textBegin , String textEnd ) {
227
+ nAddText (imFont .ptr , fontSize , posX , posY , col , textBegin , textEnd );
228
+ }
229
+
230
+ private native void nAddText (long imFontPtr , float fontSize , float posX , float posY , int col , String textBegin , String textEnd ); /*
231
+ IM_DRAW_LIST->AddText((ImFont*)imFontPtr, fontSize, ImVec2(posX, posY), col, textBegin, textEnd);
232
+ */
233
+
234
+ public void addText (ImFont imFont , float fontSize , float posX , float posY , int col , String textBegin , String textEnd , float wrapWidth ) {
235
+ nAddText (imFont .ptr , fontSize , posX , posY , col , textBegin , textEnd , wrapWidth );
236
+ }
237
+
238
+ private native void nAddText (long imFontPtr , float fontSize , float posX , float posY , int col , String textBegin , String textEnd , float wrapWidth ); /*
239
+ IM_DRAW_LIST->AddText((ImFont*)imFontPtr, fontSize, ImVec2(posX, posY), col, textBegin, textEnd, wrapWidth);
240
+ */
241
+
242
+ public void addText (ImFont imFont , float fontSize , float posX , float posY , int col , String textBegin , String textEnd , float wrapWidth , float cpuFineClipRectX , float cpuFineClipRectY , float cpuFineClipRectZ , float cpuFineClipRectV ) {
243
+ nAddText (imFont .ptr , fontSize , posX , posY , col , textBegin , textEnd , wrapWidth , cpuFineClipRectX , cpuFineClipRectY , cpuFineClipRectZ , cpuFineClipRectV );
244
+ }
245
+
246
+ private native void nAddText (long imFontPtr , float fontSize , float posX , float posY , int col , String textBegin , String textEnd , float wrapWidth , float cpuFineClipRectX , float cpuFineClipRectY , float cpuFineClipRectZ , float cpuFineClipRectV ); /*
247
+ ImVec4 cpuFineClipRect = ImVec4(cpuFineClipRectX, cpuFineClipRectY, cpuFineClipRectZ, cpuFineClipRectV);
248
+ IM_DRAW_LIST->AddText((ImFont*)imFontPtr, fontSize, ImVec2(posX, posY), col, textBegin, textEnd, wrapWidth, &cpuFineClipRect);
249
+ */
219
250
220
251
public native void addPolyline (ImVec2 [] points , int numPoints , int col , boolean closed , float thickness ); /*
221
252
int points_num = env->GetArrayLength(points);
0 commit comments