public int getFontHeight() { FontMetrics fm = mPaint.getFontMetrics(); return (int) (fm.descent - fm.ascent); }
canvas.drawText("hello world", 0, getFontHeight(), new Paint());