Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8234478

Devanagari font (unicode 0900 - 097F) fails for many conjuncts/ligatures

    Details

    • Type: Bug
    • Status: Open
    • Priority: P3
    • Resolution: Unresolved
    • Affects Version/s: 8, 11, 13, 14
    • Fix Version/s: tbd
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
      2d
    • CPU:
      x86_64
    • OS:
      windows_10

      Description

      ADDITIONAL SYSTEM INFORMATION :
      WIN10 Pro vs 1903
      java version "13.0.1" 2019-10-15
      Java(TM) SE Runtime Environment (build 13.0.1+9)
      Java HotSpot(TM) 64-Bit Server VM (build 13.0.1+9, mixed mode, sharing)

      A DESCRIPTION OF THE PROBLEM :
      Bug JDK-8208179 was resolved by using a new font. This font works fine for the
      basic glyphs, but fails for many ligatures (conjuncts). In Hindi and Sanskrit
      these ligatures are not just a writing variety, but signify a different pronun-
      ciation.

      P.S.:
      At the same time the code demonstrates also the unresolved bug 8203470


      REGRESSION : Last worked in version 8u231

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Compile and run the following code both under java 10.0.2 and 13.0.1 and see the
      considerable difference.


      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      As in java 10.0.2
      ACTUAL -
      No conjuncts built.

      ---------- BEGIN SOURCE ----------
      import java.awt.*;
      import javax.swing.*;

      public class ConjunctsBug extends JFrame {
        public static final long serialVersionUID = 8250L;

        final String TEXT= "<html>\u0919: \u0919\u094D\u0915 \u0919\u094D\u0916 "+
      "\u0919\u094D\u0917 \u0919\u094D\u0918 \u0919\u094D\u092E "+
      "\u0919\u094D\u092F \u0919\u094D\u0915\u094D\u0937<br>"+
      "\u091B: All combinations except \u091B\u094D\u0930<br>"+
      "\u091F: \u091F\u094D\u091F \u091F\u094D\u0920 \u091F\u094D\u0926 "+
      "\u091F\u094D\u092F \u091F\u094D\u0935<br>"+
      "\u0920: \u0920\u094D\u0920 \u0920\u094D\u092F \u0920\u094D\u0935<br>"+
      "\u0921: \u0921\u094D\u0917 \u0921\u094D\u0918 \u0921\u094D\u0921 "+
      "\u0921\u094D\u0922 \u0921\u094D\u092E \u0921\u094D\u092F "+
      "\u0921\u094D\u0935<br>"+
      /* java 13.0.1:
      Remove the next four code lines (last line in label) and the undesired
      line break will happen in line 2. If line 2 is removed, too, it will
      happen in line 1.
      For java 10.0.2 there are similar results.
      */
      "\u0922: \u0922\u094D\u0922 \u0922\u094D\u092F \u0922\u094D\u0935<br>"+
      "\u0926: \u0926\u094D\u0917 \u0926\u094D\u0918 \u0926\u094D\u0926 "+
      "\u0926\u094D\u0927 \u0926\u094D\u092C \u0926\u094D\u092D "+
      "\u0926\u094D\u092E \u0926\u094D\u092F \u0926\u094D\u0935";

        public ConjunctsBug() {
          setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
          setSize(500, 500);
          setTitle("Non-working Hindi conjuncts");
          JLabel lb= new JLabel(TEXT);
          lb.setBorder(BorderFactory.createEmptyBorder(0,20,0,0));
          lb.setFont(new Font(Font.DIALOG, Font.PLAIN, 20));
          add(lb);
          setVisible(true);
        }


        public static void main(String args[]) {
          EventQueue.invokeLater(ConjunctsBug::new);
        }

      }

      ---------- END SOURCE ----------

      FREQUENCY : always


        Attachments

          Activity

            People

            • Assignee:
              prr Philip Race
              Reporter:
              webbuggrp Webbug Group
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated: