Re: Location of image files in Java SRC
- From: Andrew Thompson <andrewthommo@xxxxxxxxx>
- Date: Tue, 18 Mar 2008 07:53:02 -0700 (PDT)
On Mar 18, 11:25 pm, Chanchal <chanchal.ja...@xxxxxxxxx> wrote:
I think Axel has identified the root answer
to this problem. Try setting the default
locale and using a JOptionPane.
Actually that's exacltly what i have done. But still the button text
seems ..
..seems? How about backing that up with *source*, ..
...to go along with the locale of the OS. :-(
..like
<sscce>
import javax.swing.*;
import java.util.Locale;
class LocaleTest {
public static void main(String[] args) {
Locale.setDefault(Locale.GERMAN); // "Ja/Nein"
//Locale.setDefault(Locale.ITALIAN); // "Si/No"
//Locale.setDefault(Locale.FRENCH); // "Oui/Non"
JOptionPane jop = new JOptionPane(
"Message",
JOptionPane.INFORMATION_MESSAGE,
JOptionPane.YES_NO_OPTION
);
JDialog dialog = jop.createDialog(
null,
"Title");
dialog.setVisible(true);
}
}
</sscce>
What result are you getting for German there?
(Or either of the other two commented locales).
--
Andrew T.
PhySci.org
.
- References:
- Location of image files in Java SRC
- From: Chanchal
- Re: Location of image files in Java SRC
- From: Andrew Thompson
- Re: Location of image files in Java SRC
- From: Chanchal
- Re: Location of image files in Java SRC
- From: Andrew Thompson
- Re: Location of image files in Java SRC
- From: Chanchal
- Re: Location of image files in Java SRC
- From: Andrew Thompson
- Re: Location of image files in Java SRC
- From: Chanchal
- Re: Location of image files in Java SRC
- From: Andrew Thompson
- Re: Location of image files in Java SRC
- From: Chanchal
- Location of image files in Java SRC
- Prev by Date: Re: Location of image files in Java SRC
- Next by Date: JTabbedPane selection changes
- Previous by thread: Re: Location of image files in Java SRC
- Next by thread: Re: Location of image files in Java SRC
- Index(es):