Detection of right-to-left text direction, left-to-right text direction, ligatures and diacritics in fixed format documents for reconstruction of fixed format documents into flow format documents is provided. Each text run of a fixed format document is analyzed for directionality. If text runs contain ligatures, the ligatures are mapped to corresponding characters for proper reading order of the ligatures in context with other characters comprising a text run in which the ligatures are situated or neighboring the ligature. Each text run is collected based on determined text directionality for reconstruction in a flow format document. Proper text directionality for columns of text is determined in the same manner as proper text directionality for text runs in paragraphs of text. If diacritics are present in association with one or more characters or glyphs, a determination may be made as to a carrier character or glyph associated with each diacritic.
展开▼