Beispiel #1
0
  private void font_size_listValueChanged(
      javax.swing.event.ListSelectionEvent evt) { // GEN-FIRST:event_font_size_listValueChanged
    int i = font_size_list.getSelectedIndex();

    switch (i) {
      case 0:
        font_size = 11;
        break;
      case 1:
        font_size = 15;
        break;
      case 2:
        font_size = 19;
        break;
      case 3:
        font_size = 21;
        break;
      case 4:
        font_size = 23;
        break;
    }
    font = new Font(font_style, Font.PLAIN, font_size);
    DisplayArea_text.setFont(font);
  } // GEN-LAST:event_font_size_listValueChanged
Beispiel #2
0
 private void font_style_listValueChanged(
     javax.swing.event.ListSelectionEvent evt) { // GEN-FIRST:event_font_style_listValueChanged
   font_style = font_style_list.getSelectedValue().toString();
   font = new Font(font_style, Font.PLAIN, font_size);
   DisplayArea_text.setFont(font);
 } // GEN-LAST:event_font_style_listValueChanged