I have a problem with numbers when writing them, their place changes from the text when using the Arabic language Note that in the case of writing in English, no error occurs
TextPaint mTextPaint = new TextPaint();
StaticLayout mTextLayout = new StaticLayout( textToSave ,mTextPaint, canvas.getWidth() - 100,
Layout.Alignment.ALIGN_NORMAL, 1.0f, 0.0f, false);
canvas.save();
int textX = 50;
int textY = 50;
canvas.translate(textX, textY);
mTextLayout.draw(canvas);
canvas.restore();
make sure you have written it well formatted in your xml string