Sara
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/**
*
* @author Sarahi Saenz Carrizales
*/
public class calculadora extendsjavax.swing.JFrame {
/**
* Creates new form calculadora
*/
public calculadora() {
initComponents();
}
/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOTmodify this code. The content of this method is always
* regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">private void initComponents() {
lOperacion = new javax.swing.JLabel();
tfOperacion = new javax.swing.JTextField();
tfResultado = new javax.swing.JTextField();
lResultado = newjavax.swing.JLabel();
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle("Calculadora");
lOperacion.setFont(new java.awt.Font("Perpetua Titling MT", 1, 18)); // NOI18NlOperacion.setForeground(new java.awt.Color(153, 0, 153));
lOperacion.setText("Operacion");
tfOperacion.addKeyListener(new java.awt.event.KeyAdapter() {
public void keyTyped(java.awt.event.KeyEvent evt){
tfOperacionKeyTyped(evt);
}
});
lResultado.setFont(new java.awt.Font("Perpetua Titling MT", 1, 18)); // NOI18N
lResultado.setForeground(new java.awt.Color(204, 0, 0));lResultado.setText("Resultado");
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
getContentPane().setLayout(layout);
layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addGroup(layout.createSequentialGroup()
.addContainerGap()
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup()
.addComponent(lOperacion)
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
.addComponent(tfOperacion, javax.swing.GroupLayout.PREFERRED_SIZE, 184,...
Regístrate para leer el documento completo.