Uploaded image for project: 'Tika'
  1. Tika
  2. TIKA-2257

Arabic vowel marks displaced when reading from PDF

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.14
    • None
    • parser
    • None

    Description

      The attached file, in its second line, contains “العَرَبِيَّة”. It was created on Mac OS X 10.11.6 by selecting “Save As PDF” from the system print dialog started from Microsoft Word.

      Reading the text from the PDF file, the short a vowel marks are displaced, returning
      U+0627 U+0644 U+064E U+0639 U+064E U+0631 U+0628 U+0650 U+06CC U+0651 U+064E U+0629 instead of the expected
      U+0627 U+0644 U+0639 U+064E U+0631 U+064E U+0628 U+0650 U+064A U+064E U+0651 U+0629 (الَعَربِیَّة instead of العَرَبِيَّة).

      Here is the (MATLAB) code used for reading:

      handler = org.apache.tika.sax.ToXMLContentHandler;
      parser = org.apache.tika.parser.AutoDetectParser;
      metadata = org.apache.tika.metadata.Metadata;
      fh = java.io.FileInputStream(fullname);
      parser.parse(fh, handler, metadata);
      s = string(handler.toString);
      fh.close;

      Attachments

        1. mixed-fonts.pdf
          17 kB
          Christopher Creutzig

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ccreutzig Christopher Creutzig
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: