Other |
---|
5.0 b45Fixed |
Duplicate :
|
|
Duplicate :
|
|
Duplicate :
|
|
Duplicate :
|
|
Duplicate :
|
|
Relates :
|
Name: dk106046 Date: 04/08/2003 OPERATING SYSTEM(S): Red hat 7.3 & 8 Turbo 7 & 8 Possibly other Linux FULL JDK VERSION(S): 1.4.2-beta-b19 Run the following applet on Linux where acceleration is on ie in XF86Config the device "NoAccel" is commented out DrawTextTest.html ----------------- <body> <applet code="DrawTextTest.class" height=350 width=350> </applet> </body> DrawTextTest.java ----------------- import java.awt.Graphics; import java.awt.Font; public class DrawTextTest extends java.applet.Applet { public void paint(Graphics screen) { Font f = new Font("serif", Font.PLAIN, 48); screen.setFont(f); screen.drawString("Test string", 50, 50); } } The problem is that the text is distorted. The top part of the chars repeats vertically. (FYI It seems that the problem could be in X11TextRenderer_md.c with the way checkPixmap is used. Increasing the value of TEXT_BM_HEIGHT in so that only one pixmap is being used by AWTDrawGlyphList eradicates this problem.) ====================================================================== ###@###.### 2003-10-31 Found also on SuSE 8.2 Pro with GlobalSuite test case font-render/awt/two/CharViewMultiLine.java and promoted J2SE 1.5.0 b25 HW: Ati 3D Rage Pro See attached snapshot ###@###.### 2003-11-12 Another platform RedHat AS 3.0 has the same behaviour with GlobalSuite test cases: font-render/awt/two/CharView font-render/awt/two/CharViewMultiLine HW: Ati 3D Rage Pro ###@###.###: 2003-12-16 Another platform Mercury 12c has the same behaviour with GlobalSuite test cases: font-render/awt/two/CharView font-render/awt/two/CharViewMultiLine video card: ATI Technologies Inc 3D Rage Pro AGP 1X/2X rev 92 Name: pr15447 Date: 01/22/2004 FULL PRODUCT VERSION : 1.4.2_01 FULL OS VERSION : Linux linux 2.4.18-4GB #1 Wed MAr 27 13:57:05 UTC 2002 i686 unknown EXTRA RELEVANT SYSTEM CONFIGURATION : Using SunOne studio 5.0 A DESCRIPTION OF THE PROBLEM : When I try to print text at a 90 degree angle, I get a repeated text occurence. For instance, If I tried the string "Degrees Celcuis", it will print "iusciusciuscius". The frequency of repitition seems random to me. The rotation is successful, but the text is printed incorrectly. When I remove the rotate function, the text is printed properly. STEPS TO FOLLOW TO REPRODUCE THE PROBLEM : //aString is a string //g2 is a Graphics2D object g2.rotate(-Math.PI/2,10,10); g2.drawString(aString,10,10); EXPECTED VERSUS ACTUAL BEHAVIOR : EXPECTED - if aString = "Degrees Celcuis", I expected "Degrees Celcuis" to display on the screen after my Graphics2D object has beenb rotated and I call drawString. ACTUAL - Rather, I get "iusciusciuscius" to display. REPRODUCIBILITY : This bug can be reproduced always. ---------- BEGIN SOURCE ---------- import javax.swing.*; import java.awt.*; public class DrawStringBug extends javax.swing.JFrame { public DrawStringBug() { initComponents(); this.setSize(200,300); } public void paint(Graphics g) { Font axisFont = new Font("Arial",Font.PLAIN,10); Graphics2D g2 = (Graphics2D)g; g2.rotate(-Math.PI/2,100,100); g2.drawString("ABCDEFGHIJKLMNOPQRSTUVWXYZ",-50,100); } private void initComponents() {//GEN-BEGIN:initComponents getContentPane().setLayout(null); addWindowListener(new java.awt.event.WindowAdapter() { public void windowClosing(java.awt.event.WindowEvent evt) { exitForm(evt); } }); pack(); private void exitForm(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_exitForm System.exit(0); } public static void main(String args[]) { new DrawStringBug().show(); } } ---------- END SOURCE ---------- (Review ID: 209907) ======================================================================
|