JDK-4427483 : JTextfield display a squarebox at the end of string in ar locale
  • Type: Bug
  • Component: client-libs
  • Sub-Component: 2d
  • Affected Version: 1.4.0
  • Priority: P2
  • Status: Resolved
  • Resolution: Fixed
  • OS: solaris_8
  • CPU: sparc
  • Submitted: 2001-03-19
  • Updated: 2023-11-14
  • Resolved: 2001-05-07
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
1.4.0 beta2Fixed
Related Reports
Duplicate :  
Duplicate :  
Relates :  
Description
run following test csse in ar locale, a squarebox is displayed at the end
of text.  (the original test case FontTest.java is attached to reproduce the
problem in iw locale)

import java.awt.*;
import javax.swing.*;
import java.util.Locale;

public class Test3 extends JFrame {
    private static String testString = Locale.getDefault().getDisplayLanguage();
    Test3() {
       super("Test3");
       JTextField jtf = new JTextField(testString);

       Container container = getContentPane();
       container.setLayout(new BorderLayout());
       container.add(jtf, BorderLayout.CENTER);
       setSize(getPreferredSize());
       pack();
       setVisible(true);
    }

    public static void main(String[] args) {
System.err.println("Locale: " + Locale.getDefault().toString());
System.err.println("file.encoding: " + System.getProperty("file.encoding"));
       Test3 test3 = new Test3();
    }
}

Comments
CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: merlin-beta2 FIXED IN: merlin-beta2 INTEGRATED IN: merlin-beta2
14-06-2004

PUBLIC COMMENTS control characters following arabic text sometimes display as missing glyphs
10-06-2004

EVALUATION This appears to be happening because TextLayout is now rendering a \n as a box under this locale. I'm reassigning to 2D for further investigation. scott.violet@eng 2001-03-21 This appears to have something to do with layout and composite fonts, lucida doesn't seem to have a problem with it. doug.felt@eng 2001-03-22 A change put back a few weeks ago seems to have made this disappear. I suspect the bug was still there, but hidden. Changes made to the rendering pipeline for 4403152 would fix this bug, I expect, if it was due to the causes described above. I'm closing this as fixed instead of as 'cannot reproduce' since I believe these changes did in fact fix it. doug.felt@eng 2001-04-23
23-04-2001