Statistics
| Revision:

root / branches / v2_0_0_prep / applications / appgvSIG / src / org / gvsig / app / gui / utils / FontChooser.java @ 38095

History | View | Annotate | Download (428 Bytes)

1

    
2
package org.gvsig.app.gui.utils;
3

    
4
import java.awt.Dialog;
5
import java.awt.Font;
6

    
7
import org.jfree.ui.FontChooserDialog;
8

    
9

    
10

    
11
public class FontChooser {
12
    public static Font showDialog(String title, Font font) {
13
            
14
            FontChooserDialog dlg = new FontChooserDialog((Dialog)null,title, true,font);
15
            dlg.setVisible(true);
16
            if( dlg.isCancelled() ) {
17
                    return null;
18
            }
19
            return dlg.getSelectedFont();
20
    }
21
}