View Full Version : [JAVA/Swing] JFileChooser e testo Cancel
Esiste un modo per settare il testo e il tooltip del pulsante Cancel di un JFileChooser?
Grazie.
cuoricinoblu
23-02-2007, 13:37
Potresti usare UIManager, un esempio veloce:
import javax.swing.*;
public class TestClass extends JFrame
{
public TestClass()
{
UIManager.put("FileChooser.cancelButtonText", "Scancella");
UIManager.put("FileChooser.cancelButtonToolTipText", "Questo bottone scancella la tua azione");
JFileChooser fc = new JFileChooser();
fc.showOpenDialog(this);
System.exit(0);
}
public static void main(String[] args) {
TestClass tc = new TestClass();
}
}
Ciao :D
Grazie, funziona.
Certo che potevano pure mettere due metodini nella classe JFileChooser!
Ciao.
cuoricinoblu
23-02-2007, 13:52
Uh.... troppo difficile ;)
poverini, si sarebbero potuti sbucciare i polpastrelli aggiungendo 2 metodi :)
vBulletin® v3.6.4, Copyright ©2000-2025, Jelsoft Enterprises Ltd.