Documentos de Académico
Documentos de Profesional
Documentos de Cultura
Tarea #1
/**
* Launch the application.
*/
public static void main(String[] args) {
EventQueue.invokeLater(new Runnable() {
public void run() {
try {
EjemploFuentes frame = new EjemploFuentes();
frame.setVisible(true);
} catch (Exception e) {
e.printStackTrace();
}
}
});
}
/**
* Create the frame.
*/
public EjemploFuentes() {
/*--------------------------Fuente Serif-------------------------
------------------------*/
Font fuente1= new Font("Serif",Font.PLAIN,10);//0-0-0
Font fuente1a= new Font("Serif",Font.PLAIN,20);//0-0-1
Font fuente1b= new Font("Serif",Font.PLAIN,30);//0-0-2
/*--------------------------Fuente SansSerif---------------------
----------------------------*/
/*--------------------------Fuente Monospaced--------------------
-----------------------------*/
Font fuente7= new Font("Monospaced",Font.PLAIN,10);//2-0-0
Font fuente7a= new Font("Monospaced",Font.PLAIN,20);//2-0-1
Font fuente7b= new Font("Monospaced",Font.PLAIN,30);//2-0-2
//Componentes
switch(opcion) {
case 0:
opcion2 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono2,Estilos,"Plain");
opcion3 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono3,tamanios,"10");
case 1:
opcion4 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono4,Estilos,"Plain");
opcion5 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono5,tamanios,"10");
case 2:
opcion6 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono6,Estilos,"Plain");
opcion7 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono7,tamanios,"10");
switch(opcion8) {
case 0:
opcion9 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono9,Estilos,"Plain");
opcion10 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono1,tamanios,"10");
case 1:
opcion11 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono3,Estilos,"Plain");
opcion12 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono5,tamanios,"10");
case 2:
opcion15 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono6,Estilos,"Plain");
opcion16 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono2,tamanios,"10");
switch(opcion17) {
case 0:
opcion18 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono8,Estilos,"Plain");
opcion19 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono2,tamanios,"10");
case 1:
opcion20 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono1,Estilos,"Plain");
opcion21 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono2,tamanios,"10");
case 2:
opcion22 =JOptionPane.showOptionDialog(null, "Elige el
estilo","Elige..",
0,JOptionPane.QUESTION_MESSAGE,icono3,Estilos,"Plain");
opcion23 =JOptionPane.showOptionDialog(null, "Elige el
tamanio","Elige..", 0,JOptionPane.QUESTION_MESSAGE,icono9,tamanios,"10");
}
}