-
Bug
-
Resolution: Fixed
-
P4
-
6
-
b22
-
x86
-
windows_xp
-
Not verified
FULL PRODUCT VERSION :
java version "1.6.0"
Java(TM) SE Runtime Environment (build 1.6.0-b105)
Java HotSpot(TM) Client VM (build 1.6.0-b105, mixed mode, sharing)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows XP [Version 5.1.2600]
A DESCRIPTION OF THE PROBLEM :
The JColorChooser will not use the default locale when doing some Swing work before setting the Default Locale. See Steps to reproduce for a test program.
The problem is that different users can log into the system, each with their own locale. We already need to do some swing to give them a dialog to log in.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Run the test program
2) You will see that the color chooser is in English Locale
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
A JColorChooser in French locale.
ACTUAL -
A JColorChooser in English locale
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import javax.swing.*;
import java.util.Locale;
import java.awt.*;
public class LocaleTest
{
public static void main( String[] args )
{
Locale.setDefault( Locale.ENGLISH );
JFrame frame = new JFrame();
frame.setVisible( true );
Locale.setDefault( Locale.FRENCH );
// Uncomment to following line to see the 'preview' change to 'apercu', however,
// the rest is not translated
// JComponent.setDefaultLocale( Locale.FRENCH );
JColorChooser.showDialog( frame, "Testje", Color.WHITE );
}
}
---------- END SOURCE ----------
java version "1.6.0"
Java(TM) SE Runtime Environment (build 1.6.0-b105)
Java HotSpot(TM) Client VM (build 1.6.0-b105, mixed mode, sharing)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows XP [Version 5.1.2600]
A DESCRIPTION OF THE PROBLEM :
The JColorChooser will not use the default locale when doing some Swing work before setting the Default Locale. See Steps to reproduce for a test program.
The problem is that different users can log into the system, each with their own locale. We already need to do some swing to give them a dialog to log in.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Run the test program
2) You will see that the color chooser is in English Locale
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
A JColorChooser in French locale.
ACTUAL -
A JColorChooser in English locale
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import javax.swing.*;
import java.util.Locale;
import java.awt.*;
public class LocaleTest
{
public static void main( String[] args )
{
Locale.setDefault( Locale.ENGLISH );
JFrame frame = new JFrame();
frame.setVisible( true );
Locale.setDefault( Locale.FRENCH );
// Uncomment to following line to see the 'preview' change to 'apercu', however,
// the rest is not translated
// JComponent.setDefaultLocale( Locale.FRENCH );
JColorChooser.showDialog( frame, "Testje", Color.WHITE );
}
}
---------- END SOURCE ----------