use getTextIndexDir