if (defaultPrinter.isSelected()) { changes.firePropertyChange("defaultPrinter", getStringProperty("defaultPrinter"), "Yes"); setProperty("defaultPrinter","Yes"); } else { changes.firePropertyChange("defaultPrinter", getStringProperty("defaultPrinter"), "No"); setProperty("defaultPrinter","No"); }
   private void applyAttributes() {      if (!getStringProperty("font").equals(               (String)fontsList.getSelectedItem())         ) {         changes.firePropertyChange("font",                           getStringProperty("font"),                           (String)fontsList.getSelectedItem());         setProperty("font",(String)fontsList.getSelectedItem());      }      String newSelection = (String)colorList.getSelectedItem();      if (colorSchema != null) {         if (!getColorProperty("colorBg").equals(colorSchema.getColorBg())) {            changes.firePropertyChange("colorBg",                           getColorProperty("colorBg"),                           colorSchema.getColorBg());            setProperty("colorBg",Integer.toString(colorSchema.getColorBg().getRGB()));         }         if (!getColorProperty("colorBlue").equals(colorSchema.getColorBlue())) {            changes.firePropertyChange("colorBlue",                           getColorProperty("colorBlue"),                           colorSchema.getColorBlue());            setProperty("colorBlue",Integer.toString(colorSchema.getColorBlue().getRGB()));         }         if (!getColorProperty("colorRed").equals(colorSchema.getColorRed())) {            changes.firePropertyChange("colorRed",                           getColorProperty("colorRed"),                           colorSchema.getColorRed());            setProperty("colorRed",Integer.toString(colorSchema.getColorRed().getRGB()));         }         if (!getColorProperty("colorPink").equals(colorSchema.getColorPink())) {            changes.firePropertyChange("colorPink",                           getColorProperty("colorPink"),                           colorSchema.getColorPink());            setProperty("colorPink",Integer.toString(colorSchema.getColorPink().getRGB()));         }         if (!getColorProperty("colorGreen").equals(colorSchema.getColorGreen())) {            changes.firePropertyChange("colorGreen",                           getColorProperty("colorGreen"),                           colorSchema.getColorGreen());            setProperty("colorGreen",Integer.toString(colorSchema.getColorGreen().getRGB()));         }         if (!getColorProperty("colorTurq").equals(colorSchema.getColorTurq())) {            changes.firePropertyChange("colorTurq",                           getColorProperty("colorTurq"),                           colorSchema.getColorTurq());            setProperty("colorTurq",Integer.toString(colorSchema.getColorTurq().getRGB()));         }         if (!getColorProperty("colorYellow").equals(colorSchema.getColorYellow())) {            changes.firePropertyChange("colorYellow",                           getColorProperty("colorYellow"),                           colorSchema.getColorYellow());            setProperty("colorYellow",Integer.toString(colorSchema.getColorYellow().getRGB()));         }         if (!getColorProperty("colorWhite").equals(colorSchema.getColorWhite())) {            changes.firePropertyChange("colorWhite",                           getColorProperty("colorWhite"),                           colorSchema.getColorWhite());            setProperty("colorWhite",Integer.toString(colorSchema.getColorWhite().getRGB()));         }         if (!getColorProperty("colorGUIField").equals(colorSchema.getColorGuiField())) {            changes.firePropertyChange("colorGUIField",                           getColorProperty("colorGUIField"),                           colorSchema.getColorGuiField());            setProperty("colorGUIField",Integer.toString(colorSchema.getColorGuiField().getRGB()));         }         if (!getColorProperty("colorCursor").equals(colorSchema.getColorCursor())) {            changes.firePropertyChange("colorCursor",                           getColorProperty("colorCursor"),                           colorSchema.getColorCursor());            setProperty("colorCursor",Integer.toString(colorSchema.getColorCursor().getRGB()));         }         if (!getColorProperty("colorSep").equals(colorSchema.getColorSeparator())) {            changes.firePropertyChange("colorSep",                           getColorProperty("colorSep"),                           colorSchema.getColorSeparator());            setProperty("colorSep",                     Integer.toString(colorSchema.getColorSeparator().getRGB()));         }         if (!getColorProperty("colorHexAttr").equals(colorSchema.getColorHexAttr())) {            changes.firePropertyChange("colorHexAttr",                           getColorProperty("colorHexAttr"),                           colorSchema.getColorHexAttr());            setProperty("colorHexAttr",                     Integer.toString(colorSchema.getColorHexAttr().getRGB()));         }         updateColorSelection(newSelection);      }      else {         Color nc = jcc.getColor();         if (newSelection.equals(LangTool.getString("sa.bg"))) {            if (!getColorProperty("colorBg").equals(nc)) {               changes.firePropertyChange("colorBg",                              getColorProperty("colorBg"),                              nc);               setProperty("colorBg",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.blue"))) {            if (!getColorProperty("colorBlue").equals(nc)) {               changes.firePropertyChange("colorBlue",                              getColorProperty("colorBlue"),                              nc);               setProperty("colorBlue",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.red"))) {            if (!getColorProperty("colorRed").equals(nc)) {               changes.firePropertyChange("colorRed",                              getColorProperty("colorRed"),                              nc);               setProperty("colorRed",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.pink"))) {            if (!getColorProperty("colorPink").equals(nc)) {               changes.firePropertyChange("colorPink",                              getColorProperty("colorPink"),                              nc);               setProperty("colorPink",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.green"))) {            if (!getColorProperty("colorGreen").equals(nc)) {               changes.firePropertyChange("colorGreen",                              getColorProperty("colorGreen"),                              nc);               setProperty("colorGreen",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.turq"))) {            if (!getColorProperty("colorTurq").equals(nc)) {               changes.firePropertyChange("colorTurq",                              getColorProperty("colorTurq"),                              nc);               setProperty("colorTurq",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.yellow"))) {            if (!getColorProperty("colorYellow").equals(nc)) {               changes.firePropertyChange("colorYellow",                              getColorProperty("colorYellow"),                              nc);               setProperty("colorYellow",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.white"))) {            if (!getColorProperty("colorWhite").equals(nc)) {               changes.firePropertyChange("colorWhite",                              getColorProperty("colorWhite"),                              nc);               setProperty("colorWhite",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.guiField"))) {            if (!getColorProperty("colorGUIField").equals(nc)) {               changes.firePropertyChange("colorGUIField",                              getColorProperty("colorGUIField"),                              nc);               setProperty("colorGUIField",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.cursorColor"))) {            if (!getColorProperty("colorCursor").equals(nc)) {               changes.firePropertyChange("colorCursor",                              getColorProperty("colorCursor"),                              nc);               setProperty("colorCursor",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.columnSep"))) {            if (!getColorProperty("colorSep").equals(nc)) {               changes.firePropertyChange("colorSep",                              getColorProperty("colorSep"),                              nc);               setProperty("colorSep",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.cursorColor"))) {            if (!getColorProperty("colorCursor").equals(nc)) {               changes.firePropertyChange("colorCursor",                              getColorProperty("colorCursor"),                              nc);               setProperty("colorCursor",Integer.toString(nc.getRGB()));            }         }         if (newSelection.equals(LangTool.getString("sa.hexAttrColor"))) {            if (!getColorProperty("colorHexAttr").equals(nc)) {               changes.firePropertyChange("colorHexAttr",                              getColorProperty("colorHexAttr"),                              nc);               setProperty("colorHexAttr",Integer.toString(nc.getRGB()));            }         }      }      if (csLine.isSelected()) {         changes.firePropertyChange("colSeparator",                           getStringProperty("colSeparator"),                           "Line");         setProperty("colSeparator","Line");      }      else if (csShortLine.isSelected()) {         changes.firePropertyChange("colSeparator",                           getStringProperty("colSeparator"),                           "ShortLine");         setProperty("colSeparator","ShortLine");      }      else {         changes.firePropertyChange("colSeparator",                           getStringProperty("colSeparator"),                           "Dot");         setProperty("colSeparator","Dot");      }      if (cFull.isSelected()) {         changes.firePropertyChange("cursorSize",                           getStringProperty("cursorSize"),                           "Full");         setProperty("cursorSize","Full");      }      if (cHalf.isSelected()) {         changes.firePropertyChange("cursorSize",                           getStringProperty("cursorSize"),                           "Half");         setProperty("cursorSize","Half");      }      if (cLine.isSelected()) {         changes.firePropertyChange("cursorSize",                           getStringProperty("cursorSize"),                           "Line");         setProperty("cursorSize","Line");      }      if (chNone.isSelected()) {         changes.firePropertyChange("crossHair",                           getStringProperty("crossHair"),                           "None");         setProperty("crossHair","None");      }      if (chHorz.isSelected()) {         changes.firePropertyChange("crossHair",                           getStringProperty("crossHair"),                           "Horz");         setProperty("crossHair","Horz");      }      if (chVert.isSelected()) {         changes.firePropertyChange("crossHair",                           getStringProperty("crossHair"),                           "Vert");         setProperty("crossHair","Vert");      }      if (chCross.isSelected()) {         changes.firePropertyChange("crossHair",                           getStringProperty("crossHair"),                           "Both");         setProperty("crossHair","Both");      }      if (rulerFixed.isSelected()) {         changes.firePropertyChange("rulerFixed",                           getStringProperty("rulerFixed"),                           "Yes");         setProperty("rulerFixed","Yes");      }      else {         changes.firePropertyChange("rulerFixed",                           getStringProperty("rulerFixed"),                           "No");         setProperty("rulerFixed","No");      }      if (saNormal.isSelected()) {         changes.firePropertyChange("showAttr",                           getStringProperty("showAttr"),                           "Normal");         setProperty("showAttr","Normal");      }      else {         changes.firePropertyChange("showAttr",                           getStringProperty("showAttr"),                           "Hex");         setProperty("showAttr","Hex");      }      if (dceCheck.isSelected()) {         changes.firePropertyChange("doubleClick",                           getStringProperty("doubleClick"),                           "Yes");         setProperty("doubleClick","Yes");      }      else {         changes.firePropertyChange("doubleClick",                           getStringProperty("doubleClick"),                           "No");         setProperty("doubleClick","No");      }      if (guiCheck.isSelected()) {         changes.firePropertyChange("guiInterface",                           getStringProperty("guiInterface"),                           "Yes");         setProperty("guiInterface","Yes");      }      else {         changes.firePropertyChange("guiInterface",                           getStringProperty("guiInterface"),                           "No");         setProperty("guiInterface","No");      }      if (guiShowUnderline.isSelected()) {         changes.firePropertyChange("guiShowUnderline",                           getStringProperty("guiShowUnderline"),                           "Yes");         setProperty("guiShowUnderline","Yes");      }      else {         changes.firePropertyChange("guiShowUnderline",                           getStringProperty("guiShowUnderline"),                           "No");         setProperty("guiShowUnderline","No");      }      if (hsCheck.isSelected()) {         changes.firePropertyChange("hotspots",                           getStringProperty("hotspots"),                           "Yes");         setProperty("hotspots","Yes");      }      else {         changes.firePropertyChange("hotspots",                           getStringProperty("hotspots"),                           "No");         setProperty("hotspots","No");      }      if (kpCheck.isSelected()) {         changes.firePropertyChange("keypad",                           getStringProperty("keypad"),                           "Yes");         setProperty("keypad","Yes");      }      else {         changes.firePropertyChange("keypad",                           getStringProperty("keypad"),                           "No");         setProperty("keypad","No");      }      changes.firePropertyChange("hsMore",                        getStringProperty("hsMore"),                        hsMore.getText());      setProperty("hsMore",hsMore.getText());      changes.firePropertyChange("connectMacro",                        getStringProperty("connectMacro"),                        connectMacro.getText());      setProperty("connectMacro",connectMacro.getText());      changes.firePropertyChange("hsBottom",                        getStringProperty("hsBottom"),                        hsBottom.getText());      setProperty("hsBottom",hsBottom.getText());      changes.firePropertyChange("fontScaleHeight",                        getStringProperty("fontScaleHeight"),                        verticalScale.getText());      setProperty("fontScaleHeight",verticalScale.getText());      changes.firePropertyChange("fontScaleWidth",                        getStringProperty("fontScaleWidth"),                        horizontalScale.getText());      setProperty("fontScaleWidth",horizontalScale.getText());      changes.firePropertyChange("fontPointSize",                        getStringProperty("fontPointSize"),                        pointSize.getText());      setProperty("fontPointSize",pointSize.getText());      changes.firePropertyChange("cursorBottOffset",                        getStringProperty("cursorBottOffset"),                        cursorBottOffset.getText());      setProperty("cursorBottOffset",cursorBottOffset.getText());      setProperty("saveme","yes");   }