Index: applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java
===================================================================
--- applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java	(revision 27094)
+++ applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java	(revision 27095)
@@ -23,5 +23,6 @@
 	}
 
-	public static final EnumMap<Reg, String> RegSTR = new EnumMap<Reg, String>(Reg.class);
+	public static final EnumMap<Reg, String> RegSTR = new EnumMap<Reg, String>(
+			Reg.class);
 	static {
 		RegSTR.put(Reg.A, "iala-a");
@@ -31,5 +32,5 @@
 		RegSTR.put(Reg.X, "other");
 	}
-	
+
 	private Reg region = Reg.A;
 
@@ -53,10 +54,9 @@
 
 	public enum Obj {
-		UNKNOWN, BCNCAR, BCNISD, BCNLAT, BCNSAW, BCNSPP, BOYCAR, BOYISD, BOYLAT, BOYSAW, BOYSPP,
-		FLTCAR, FLTISD, FLTLAT, FLTSAW, FLTSPP, LITMAJ, LITMIN, LITFLT, LITVES,
-		LITHSE, LNDMRK, MORFAC, SISTAW, SISTAT
-	}
-
-	public static final EnumMap<Obj, String> ObjSTR = new EnumMap<Obj, String>(Obj.class);
+		UNKNOWN, BCNCAR, BCNISD, BCNLAT, BCNSAW, BCNSPP, BOYCAR, BOYISD, BOYLAT, BOYSAW, BOYSPP, FLTCAR, FLTISD, FLTLAT, FLTSAW, FLTSPP, LITMAJ, LITMIN, LITFLT, LITVES, LITHSE, LNDMRK, MORFAC, SISTAW, SISTAT
+	}
+
+	public static final EnumMap<Obj, String> ObjSTR = new EnumMap<Obj, String>(
+			Obj.class);
 	static {
 		ObjSTR.put(Obj.BCNCAR, "beacon_cardinal");
@@ -100,5 +100,6 @@
 	}
 
-	public static final EnumMap<Obj, Ent> EntMAP = new EnumMap<Obj, Ent>(Obj.class);
+	public static final EnumMap<Obj, Ent> EntMAP = new EnumMap<Obj, Ent>(
+			Obj.class);
 	static {
 		EntMAP.put(Obj.BCNCAR, Ent.BEACON);
@@ -132,5 +133,6 @@
 	}
 
-	public static final EnumMap<Obj, Grp> GrpMAP = new EnumMap<Obj, Grp>(Obj.class);
+	public static final EnumMap<Obj, Grp> GrpMAP = new EnumMap<Obj, Grp>(
+			Obj.class);
 	static {
 		GrpMAP.put(Obj.UNKNOWN, Grp.NUL);
@@ -162,16 +164,9 @@
 
 	public enum Cat {
-		NONE, LAM_PORT, LAM_STBD, LAM_PPORT, LAM_PSTBD, CAM_NORTH, CAM_EAST, CAM_SOUTH, CAM_WEST,
-		ACH_URST, ACH_DEEP, ACH_TANK, ACH_EXPL, ACH_QUAR, ACH_SPLN, ACH_SCAN, ACH_SCMO, ACH_T24H, ACH_TLIM,
-		SPM_UNKN, SPM_WARN, SPM_CHBF, SPM_YCHT, SPM_CABL, SPM_OFAL, SPM_ODAS, SPM_RECN, SPM_MOOR, SPM_LNBY,
-		SPM_LDNG, SPM_NOTC, SPM_TSS, SPM_FOUL, SPM_DIVE, SPM_FRRY,
-		SPM_ANCH, MOR_DLPN, MOR_DDPN, MOR_BLRD, MOR_WALL, MOR_POST, MOR_CHWR, MOR_BUOY,
-		SIS_PTCL, SIS_PTED, SIS_IPT, SIS_BRTH, SIS_DOCK, SIS_LOCK, SIS_FBAR, SIS_BRDG, SIS_DRDG, SIS_TRFC,
-		SIS_DNGR, SIS_OBST, SIS_CABL, SIS_MILY, SIS_DSTR, SIS_WTHR, SIS_STRM, SIS_ICE, SIS_TIME, SIS_TIDE,
-		SIS_TSTM, SIS_TGAG, SIS_TSCL, SIS_DIVE, SIS_LGAG, LIT_DIRF, LIT_LEDG,
-		LMK_CHMY, LMK_CARN, LMK_DSHA, LMK_FLGS, LMK_FLRS, LMK_MNMT, LMK_RADM, LMK_TOWR, LMK_WNDM, LMK_WTRT
-	}
-
-	public static final EnumMap<Cat, String> CatSTR = new EnumMap<Cat, String>(Cat.class);
+		NONE, LAM_PORT, LAM_STBD, LAM_PPORT, LAM_PSTBD, CAM_NORTH, CAM_EAST, CAM_SOUTH, CAM_WEST, ACH_URST, ACH_DEEP, ACH_TANK, ACH_EXPL, ACH_QUAR, ACH_SPLN, ACH_SCAN, ACH_SCMO, ACH_T24H, ACH_TLIM, SPM_UNKN, SPM_WARN, SPM_CHBF, SPM_YCHT, SPM_CABL, SPM_OFAL, SPM_ODAS, SPM_RECN, SPM_MOOR, SPM_LNBY, SPM_LDNG, SPM_NOTC, SPM_TSS, SPM_FOUL, SPM_DIVE, SPM_FRRY, SPM_ANCH, MOR_DLPN, MOR_DDPN, MOR_BLRD, MOR_WALL, MOR_POST, MOR_CHWR, MOR_BUOY, SIS_PTCL, SIS_PTED, SIS_IPT, SIS_BRTH, SIS_DOCK, SIS_LOCK, SIS_FBAR, SIS_BRDG, SIS_DRDG, SIS_TRFC, SIS_DNGR, SIS_OBST, SIS_CABL, SIS_MILY, SIS_DSTR, SIS_WTHR, SIS_STRM, SIS_ICE, SIS_TIME, SIS_TIDE, SIS_TSTM, SIS_TGAG, SIS_TSCL, SIS_DIVE, SIS_LGAG, LIT_DIRF, LIT_LEDG, LMK_CHMY, LMK_CARN, LMK_DSHA, LMK_FLGS, LMK_FLRS, LMK_MNMT, LMK_RADM, LMK_TOWR, LMK_WNDM, LMK_WTRT
+	}
+
+	public static final EnumMap<Cat, String> CatSTR = new EnumMap<Cat, String>(
+			Cat.class);
 	static {
 		CatSTR.put(Cat.LAM_PORT, "port");
@@ -255,9 +250,9 @@
 
 	public enum Shp {
-		UNKNOWN, PILLAR, SPAR, CAN, CONE, SPHERE, BARREL, FLOAT, SUPER,
-		BUOYANT, CAIRN, PILE, LATTICE, TOWER, STAKE, POLE, POST, PERCH, BUOY, BEACON
-	}
-
-	public static final EnumMap<Shp, String> ShpSTR = new EnumMap<Shp, String>(Shp.class);
+		UNKNOWN, PILLAR, SPAR, CAN, CONE, SPHERE, BARREL, FLOAT, SUPER, BUOYANT, CAIRN, PILE, LATTICE, TOWER, STAKE, POLE, POST, PERCH, BUOY, BEACON
+	}
+
+	public static final EnumMap<Shp, String> ShpSTR = new EnumMap<Shp, String>(
+			Shp.class);
 	static {
 		ShpSTR.put(Shp.PILLAR, "pillar");
@@ -292,5 +287,6 @@
 	}
 
-	public static final EnumMap<Col, Color> ColMAP = new EnumMap<Col, Color>(Col.class);
+	public static final EnumMap<Col, Color> ColMAP = new EnumMap<Col, Color>(
+			Col.class);
 	static {
 		ColMAP.put(Col.UNKNOWN, new Color(0xc0c0c0));
@@ -310,5 +306,6 @@
 	}
 
-	public static final EnumMap<Col, String> ColSTR = new EnumMap<Col, String>(Col.class);
+	public static final EnumMap<Col, String> ColSTR = new EnumMap<Col, String>(
+			Col.class);
 	static {
 		ColSTR.put(Col.WHITE, "white");
@@ -333,5 +330,5 @@
 			return getTopColour(idx);
 	}
-	
+
 	public void setColour(Ent ent, Col col) {
 		if (ent == Ent.BODY)
@@ -340,5 +337,5 @@
 			setTopColour(col);
 	}
-	
+
 	public void setColour(Ent ent, int idx, Col col) {
 		if (ent == Ent.BODY)
@@ -347,5 +344,5 @@
 			setTopColour(idx, col);
 	}
-	
+
 	public void addColour(Ent ent, int idx, Col col) {
 		if (ent == Ent.BODY)
@@ -354,5 +351,5 @@
 			addTopColour(idx, col);
 	}
-	
+
 	public void subColour(Ent ent, int idx) {
 		if (ent == Ent.BODY)
@@ -361,7 +358,7 @@
 			subTopColour(idx);
 	}
-	
+
 	private ArrayList<Col> bodyColour = new ArrayList<Col>();
-	
+
 	public Col getObjColour(int i) {
 		if (i < bodyColour.size())
@@ -394,7 +391,7 @@
 			bodyColour.remove(i);
 	}
-		
+
 	private ArrayList<Col> topmarkColour = new ArrayList<Col>();
-	
+
 	public Col getTopColour(int i) {
 		if (i < topmarkColour.size())
@@ -427,8 +424,7 @@
 			topmarkColour.remove(i);
 	}
-		
+
 	public enum Chr {
-		UNKNOWN, FIXED, FLASH, LFLASH, QUICK, VQUICK, UQUICK, ISOPHASED, OCCULTING,
-		MORSE, ALTERNATING, IQUICK, IVQUICK, IUQUICK
+		UNKNOWN, FIXED, FLASH, LFLASH, QUICK, VQUICK, UQUICK, ISOPHASED, OCCULTING, MORSE, ALTERNATING, IQUICK, IVQUICK, IUQUICK
 	}
 
@@ -469,5 +465,6 @@
 	}
 
-	public static final EnumMap<Vis, String> VisSTR = new EnumMap<Vis, String>(Vis.class);
+	public static final EnumMap<Vis, String> VisSTR = new EnumMap<Vis, String>(
+			Vis.class);
 	static {
 		VisSTR.put(Vis.UNKNOWN, "");
@@ -481,11 +478,11 @@
 		VisSTR.put(Vis.PARTOBS, "part_obscured");
 	}
-	
+
 	public enum Lit {
-		UNKNOWN, VERT, HORIZ, DIR, UPPER, LOWER, LEAD, REAR, FRONT,
-		AERO, AIROBS, FOGDET, FLOOD, STRIP, SUBS, SPOT, MOIRE, EMERG, BEAR
-	}
-
-	public static final EnumMap<Lit, String> LitSTR = new EnumMap<Lit, String>(Lit.class);
+		UNKNOWN, VERT, HORIZ, DIR, UPPER, LOWER, LEAD, REAR, FRONT, AERO, AIROBS, FOGDET, FLOOD, STRIP, SUBS, SPOT, MOIRE, EMERG, BEAR
+	}
+
+	public static final EnumMap<Lit, String> LitSTR = new EnumMap<Lit, String>(
+			Lit.class);
 	static {
 		LitSTR.put(Lit.UNKNOWN, "");
@@ -510,7 +507,10 @@
 	}
 
-	public enum Exh { UNKNOWN, H24, DAY, NIGHT, FOG }
-	
-	public static final EnumMap<Exh, String> ExhSTR = new EnumMap<Exh, String>(Exh.class);
+	public enum Exh {
+		UNKNOWN, H24, DAY, NIGHT, FOG
+	}
+
+	public static final EnumMap<Exh, String> ExhSTR = new EnumMap<Exh, String>(
+			Exh.class);
 	static {
 		ExhSTR.put(Exh.UNKNOWN, "");
@@ -520,18 +520,22 @@
 		ExhSTR.put(Exh.FOG, "fog");
 	}
-	
-	public enum Att { COL, CHR, GRP, SEQ, PER, LIT, BEG, END, RAD, HGT, RNG, VIS, EXH, ORT, MLT }
-	
-	public Object[] sector = {Col.UNKNOWN, "", "", "", "", Lit.UNKNOWN, "", "", "", "", "", Vis.UNKNOWN, Exh.UNKNOWN, "", "" };
-	
+
+	public enum Att {
+		COL, CHR, GRP, SEQ, PER, LIT, BEG, END, RAD, HGT, RNG, VIS, EXH, ORT, MLT
+	}
+
+	public Object[] sector = { Col.UNKNOWN, "", "", "", "", Lit.UNKNOWN, "", "",
+			"", "", "", Vis.UNKNOWN, Exh.UNKNOWN, "", "" };
+
 	private ArrayList<Object[]> sectors = new ArrayList<Object[]>();
-	
+
 	public int getSectorCount() {
 		return sectors.size();
 	}
-	
+
 	public Object getLightAtt(Att att, int i) {
 		return getLightAtt(att.ordinal(), i);
 	}
+
 	public Object getLightAtt(int att, int i) {
 		if (i < sectors.size())
@@ -577,5 +581,6 @@
 	}
 
-	public static final EnumMap<Pat, String> PatSTR = new EnumMap<Pat, String>(Pat.class);
+	public static final EnumMap<Pat, String> PatSTR = new EnumMap<Pat, String>(
+			Pat.class);
 	static {
 		PatSTR.put(Pat.HORIZ, "horizontal");
@@ -592,5 +597,5 @@
 			return getTopPattern();
 	}
-	
+
 	public void setPattern(Ent ent, Pat pat) {
 		if (ent == Ent.BODY)
@@ -599,5 +604,5 @@
 			setTopPattern(pat);
 	}
-	
+
 	private Pat bodyPattern = Pat.NONE;
 
@@ -624,5 +629,6 @@
 	}
 
-	public static final EnumMap<Top, String> TopSTR = new EnumMap<Top, String>(Top.class);
+	public static final EnumMap<Top, String> TopSTR = new EnumMap<Top, String>(
+			Top.class);
 	static {
 		TopSTR.put(Top.CAN, "cylinder");
@@ -657,5 +663,6 @@
 	}
 
-	public static final EnumMap<Rtb, String> RtbSTR = new EnumMap<Rtb, String>(Rtb.class);
+	public static final EnumMap<Rtb, String> RtbSTR = new EnumMap<Rtb, String>(
+			Rtb.class);
 	static {
 		RtbSTR.put(Rtb.RACON, "racon");
@@ -738,5 +745,6 @@
 	}
 
-	public static final EnumMap<Fog, String> FogSTR = new EnumMap<Fog, String>(Fog.class);
+	public static final EnumMap<Fog, String> FogSTR = new EnumMap<Fog, String>(
+			Fog.class);
 	static {
 		FogSTR.put(Fog.UNKNOWN, "yes");
@@ -804,5 +812,6 @@
 	}
 
-	public static final EnumMap<Sts, String> StsSTR = new EnumMap<Sts, String>(Sts.class);
+	public static final EnumMap<Sts, String> StsSTR = new EnumMap<Sts, String>(
+			Sts.class);
 	static {
 		StsSTR.put(Sts.PERM, "permanent");
@@ -840,5 +849,6 @@
 	}
 
-	public static final EnumMap<Cns, String> CnsSTR = new EnumMap<Cns, String>(Cns.class);
+	public static final EnumMap<Cns, String> CnsSTR = new EnumMap<Cns, String>(
+			Cns.class);
 	static {
 		CnsSTR.put(Cns.BRICK, "masonry");
@@ -867,5 +877,6 @@
 	}
 
-	public static final EnumMap<Con, String> ConSTR = new EnumMap<Con, String>(Con.class);
+	public static final EnumMap<Con, String> ConSTR = new EnumMap<Con, String>(
+			Con.class);
 	static {
 		ConSTR.put(Con.CONSP, "conspicuous");
@@ -1011,5 +1022,6 @@
 			dlg.panelMain.saveButton.setEnabled(true);
 			Ent ent = EntMAP.get(getObject());
-			dlg.panelMain.topButton.setEnabled((ent == Ent.BUOY) || (ent == Ent.BEACON) || (ent == Ent.FLOAT));
+			dlg.panelMain.topButton.setEnabled((ent == Ent.BUOY)
+					|| (ent == Ent.BEACON) || (ent == Ent.FLOAT));
 			dlg.panelMain.fogButton.setEnabled(true);
 			dlg.panelMain.radButton.setEnabled(true);
@@ -1047,5 +1059,5 @@
 		paintSign();
 	}
-	
+
 	public String validDecimal(String str) {
 		str = str.trim().replace(',', '.');
@@ -1169,5 +1181,5 @@
 				}
 			}
-			
+
 			if (keys.containsKey("seamark:" + ObjSTR.get(obj) + ":height")) {
 				setHeight(keys.get("seamark:" + ObjSTR.get(obj) + ":height"));
@@ -1195,5 +1207,6 @@
 						setCategory(Cat.LAM_PORT);
 					}
-				} else if ((getObjColour(1) == Col.GREEN) && (getObjColour(2) == Col.RED)) {
+				} else if ((getObjColour(1) == Col.GREEN)
+						&& (getObjColour(2) == Col.RED)) {
 					setObject(Obj.FLTLAT);
 					if (getRegion() == Reg.B) {
@@ -1202,5 +1215,6 @@
 						setCategory(Cat.LAM_PPORT);
 					}
-				} else if ((getObjColour(1) == Col.WHITE) && (getObjColour(2) == Col.RED)) {
+				} else if ((getObjColour(1) == Col.WHITE)
+						&& (getObjColour(2) == Col.RED)) {
 					setObject(Obj.FLTLAT);
 					setCategory(Cat.LAM_PORT);
@@ -1218,5 +1232,6 @@
 						setCategory(Cat.LAM_STBD);
 					}
-				} else if ((getObjColour(1) == Col.RED) && (getObjColour(2) == Col.GREEN)) {
+				} else if ((getObjColour(1) == Col.RED)
+						&& (getObjColour(2) == Col.GREEN)) {
 					setObject(Obj.FLTLAT);
 					if (getRegion() == Reg.B) {
@@ -1225,5 +1240,6 @@
 						setCategory(Cat.LAM_PSTBD);
 					}
-				} else if ((getObjColour(1) == Col.WHITE) && (getObjColour(2) == Col.GREEN)) {
+				} else if ((getObjColour(1) == Col.WHITE)
+						&& (getObjColour(2) == Col.GREEN)) {
 					setObject(Obj.FLTLAT);
 					setCategory(Cat.LAM_STBD);
@@ -1349,5 +1365,5 @@
 			}
 		}
-		
+
 		sectors.clear();
 		sectors.add(sector.clone());
@@ -1361,9 +1377,11 @@
 			}
 			if (keys.containsKey("seamark:light" + secStr + ":character"))
-				setLightAtt(Att.CHR, i, keys.get("seamark:light" + secStr + ":character"));
+				setLightAtt(Att.CHR, i,
+						keys.get("seamark:light" + secStr + ":character"));
 			if (keys.containsKey("seamark:light" + secStr + ":group"))
 				setLightAtt(Att.GRP, i, keys.get("seamark:light" + secStr + ":group"));
 			if (keys.containsKey("seamark:light" + secStr + ":sequence"))
-				setLightAtt(Att.SEQ, i, keys.get("seamark:light" + secStr + ":sequence"));
+				setLightAtt(Att.SEQ, i,
+						keys.get("seamark:light" + secStr + ":sequence"));
 			if (keys.containsKey("seamark:light" + secStr + ":period"))
 				setLightAtt(Att.PER, i, keys.get("seamark:light" + secStr + ":period"));
@@ -1375,7 +1393,9 @@
 			}
 			if (keys.containsKey("seamark:light" + secStr + ":sector_start"))
-				setLightAtt(Att.BEG, i, keys.get("seamark:light" + secStr + ":sector_start"));
+				setLightAtt(Att.BEG, i,
+						keys.get("seamark:light" + secStr + ":sector_start"));
 			if (keys.containsKey("seamark:light" + secStr + ":sector_end"))
-				setLightAtt(Att.END, i, keys.get("seamark:light" + secStr + ":sector_end"));
+				setLightAtt(Att.END, i,
+						keys.get("seamark:light" + secStr + ":sector_end"));
 			if (keys.containsKey("seamark:light" + secStr + ":radius"))
 				setLightAtt(Att.RAD, i, keys.get("seamark:light" + secStr + ":radius"));
@@ -1386,7 +1406,7 @@
 			if (keys.containsKey("seamark:light" + secStr + ":visibility")) {
 				str = keys.get("seamark:light" + secStr + ":visibility");
-			for (Vis vis : VisSTR.keySet())
-				if (VisSTR.get(vis).equals(str))
-					setLightAtt(Att.VIS, i, vis);
+				for (Vis vis : VisSTR.keySet())
+					if (VisSTR.get(vis).equals(str))
+						setLightAtt(Att.VIS, i, vis);
 			}
 			if (keys.containsKey("seamark:light" + secStr + ":exhibition")) {
@@ -1397,7 +1417,9 @@
 			}
 			if (keys.containsKey("seamark:light" + secStr + ":orientation"))
-				setLightAtt(Att.ORT, i, keys.get("seamark:light" + secStr + ":orientation"));
+				setLightAtt(Att.ORT, i,
+						keys.get("seamark:light" + secStr + ":orientation"));
 			if (keys.containsKey("seamark:light" + secStr + ":multiple"))
-				setLightAtt(Att.HGT, i, keys.get("seamark:light" + secStr + ":multiple"));
+				setLightAtt(Att.HGT, i,
+						keys.get("seamark:light" + secStr + ":multiple"));
 			if (sectors.size() == i)
 				break;
@@ -1667,9 +1689,11 @@
 						System.out.println("Missing image: " + imgStr);
 					} else {
-						dlg.panelMain.shapeIcon.setIcon(new ImageIcon(getClass().getResource(imgStr)));
+						dlg.panelMain.shapeIcon.setIcon(new ImageIcon(getClass()
+								.getResource(imgStr)));
 						dlg.panelMain.colLabel.setText(lblStr);
 					}
 				} else {
-					dlg.panelMain.shapeIcon.setIcon(new ImageIcon(getClass().getResource(colStr)));
+					dlg.panelMain.shapeIcon.setIcon(new ImageIcon(getClass().getResource(
+							colStr)));
 				}
 			} else {
@@ -1739,5 +1763,6 @@
 					System.out.println("Missing image: " + imgStr);
 				} else {
-					dlg.panelMain.shapeIcon.setIcon(new ImageIcon(getClass().getResource(imgStr)));
+					dlg.panelMain.shapeIcon.setIcon(new ImageIcon(getClass().getResource(
+							imgStr)));
 				}
 			} else {
@@ -1848,8 +1873,10 @@
 					return;
 				} else {
-					dlg.panelMain.topIcon.setIcon(new ImageIcon(getClass().getResource(imgStr)));
+					dlg.panelMain.topIcon.setIcon(new ImageIcon(getClass().getResource(
+							imgStr)));
 				}
 			} else {
-				dlg.panelMain.topIcon.setIcon(new ImageIcon(getClass().getResource(colStr)));
+				dlg.panelMain.topIcon.setIcon(new ImageIcon(getClass().getResource(
+						colStr)));
 			}
 		} else {
@@ -1858,5 +1885,6 @@
 
 		if (getFogSound() != Fog.NONE) {
-			dlg.panelMain.fogIcon.setIcon(new ImageIcon(getClass().getResource("/images/Fog_Signal.png")));
+			dlg.panelMain.fogIcon.setIcon(new ImageIcon(getClass().getResource(
+					"/images/Fog_Signal.png")));
 			String str = "";
 			if (getFogSound() != Fog.UNKNOWN)
@@ -1892,10 +1920,12 @@
 			dlg.panelMain.fogLabel.setText(str);
 		}
-		
+
 		if (RaType != Rtb.NONE) {
 			if (getRadar() == Rtb.REFLECTOR) {
-				dlg.panelMain.radarIcon.setIcon(new ImageIcon(getClass().getResource("/images/Radar_Reflector_355.png")));
+				dlg.panelMain.radarIcon.setIcon(new ImageIcon(getClass().getResource(
+						"/images/Radar_Reflector_355.png")));
 			} else {
-				dlg.panelMain.radarIcon.setIcon(new ImageIcon(getClass().getResource("/images/Radar_Station.png")));
+				dlg.panelMain.radarIcon.setIcon(new ImageIcon(getClass().getResource(
+						"/images/Radar_Station.png")));
 				String str = "";
 				if (getRadar() == Rtb.RAMARK)
@@ -1912,23 +1942,27 @@
 			}
 		}
-		
+
 		if (getLightAtt(Att.COL, 0) != Col.UNKNOWN) {
 			if (sectors.size() == 1) {
 				switch ((Col) getLightAtt(Att.COL, 0)) {
 				case RED:
-					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource("/images/Light_Red_120.png")));
+					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource(
+							"/images/Light_Red_120.png")));
 					break;
 				case GREEN:
-					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource("/images/Light_Green_120.png")));
+					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource(
+							"/images/Light_Green_120.png")));
 					break;
 				case WHITE:
 				case YELLOW:
-					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource("/images/Light_White_120.png")));
+					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource(
+							"/images/Light_White_120.png")));
 					break;
 				default:
-					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource("/images/Light_Magenta_120.png")));
-				}
-			}
-			String c = (String)getLightAtt(Att.CHR, 0);
+					dlg.panelMain.lightIcon.setIcon(new ImageIcon(getClass().getResource(
+							"/images/Light_Magenta_120.png")));
+				}
+			}
+			String c = (String) getLightAtt(Att.CHR, 0);
 			String tmp = "";
 			if (c.contains("+")) {
@@ -1936,12 +1970,12 @@
 				tmp = c.substring(i1, c.length());
 				c = c.substring(0, i1);
-				if (!((String)getLightAtt(Att.GRP, 0)).isEmpty()) {
-					c += "(" + (String)getLightAtt(Att.GRP, 0) + ")";
+				if (!((String) getLightAtt(Att.GRP, 0)).isEmpty()) {
+					c += "(" + (String) getLightAtt(Att.GRP, 0) + ")";
 				}
 				if (tmp != null)
 					c += tmp;
-			} else if (!((String)getLightAtt(Att.GRP, 0)).isEmpty())
-				c += "(" + (String)getLightAtt(Att.GRP, 0) + ")";
-			switch ((Col)getLightAtt(Att.COL, 0)) {
+			} else if (!((String) getLightAtt(Att.GRP, 0)).isEmpty())
+				c += "(" + (String) getLightAtt(Att.GRP, 0) + ")";
+			switch ((Col) getLightAtt(Att.COL, 0)) {
 			case RED:
 				c += " R";
@@ -1963,10 +1997,10 @@
 				break;
 			}
-			tmp = (String)getLightAtt(Att.PER, 0);
+			tmp = (String) getLightAtt(Att.PER, 0);
 			if (!tmp.isEmpty())
 				c += " " + tmp + "s";
 			dlg.panelMain.litLabel.setText(c);
 		}
-		
+
 		paintlock = false;
 	}
@@ -1976,5 +2010,6 @@
 		if (getObject() != Obj.UNKNOWN) {
 
-			Main.pref.put("smedplugin.IALA", getRegion() == Reg.C ? "C" : (getRegion() == Reg.B ? "B" : "A"));
+			Main.pref.put("smedplugin.IALA", getRegion() == Reg.C ? "C"
+					: (getRegion() == Reg.B ? "B" : "A"));
 
 			for (String str : node.getKeys().keySet()) {
@@ -1984,16 +2019,20 @@
 
 			if (!getName().isEmpty())
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:name", getName()));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:name",
+						getName()));
 
 			String objStr = ObjSTR.get(object);
 			if (objStr != null) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:type", objStr));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:type",
+						objStr));
 
 				if (getShape() != Shp.FLOAT) {
 					String str = CatSTR.get(getCategory());
 					if (str != null)
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":category", str));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+								+ objStr + ":category", str));
 					if ((getShape() != Shp.BUOY) && (getShape() != Shp.BEACON))
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":shape", ShpSTR.get(getShape())));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+								+ objStr + ":shape", ShpSTR.get(getShape())));
 				}
 
@@ -2003,37 +2042,45 @@
 						str += (";" + ColSTR.get(getObjColour(i)));
 					}
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":colour", str));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+							+ objStr + ":colour", str));
 				}
 
 				if (getObjPattern() != Pat.NONE) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":colour_pattern", PatSTR
-							.get(getObjPattern())));
-				}
-
-				if ((GrpMAP.get(object) == Grp.LAT) && (getShape() != Shp.PERCH) || (getObject() == Obj.FLTLAT)) {
+					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+							+ objStr + ":colour_pattern", PatSTR.get(getObjPattern())));
+				}
+
+				if ((GrpMAP.get(object) == Grp.LAT) && (getShape() != Shp.PERCH)
+						|| (getObject() == Obj.FLTLAT)) {
 					switch (region) {
 					case A:
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":system", "iala-a"));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+								+ objStr + ":system", "iala-a"));
 						break;
 					case B:
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":system", "iala-b"));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+								+ objStr + ":system", "iala-b"));
 						break;
 					case C:
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + ":system", "other"));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+								+ objStr + ":system", "other"));
 						break;
 					}
 				}
 				if (!getHeight().isEmpty()) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + "height", getHeight()));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+							+ objStr + "height", getHeight()));
 				}
 				if (!getElevation().isEmpty()) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:" + objStr + "elevation", getElevation()));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:"
+							+ objStr + "elevation", getElevation()));
 				}
 			}
 			if (getTopmark() != Top.NONE) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:topmark:shape", TopSTR.get(getTopmark())));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:topmark:shape", TopSTR.get(getTopmark())));
 				if (getTopPattern() != Pat.NONE)
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:topmark:colour_pattern", PatSTR
-							.get(getTopPattern())));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:topmark:colour_pattern", PatSTR.get(getTopPattern())));
 				if (getTopColour(0) != Col.UNKNOWN) {
 					String str = ColSTR.get(getTopColour(0));
@@ -2041,81 +2088,125 @@
 						str += (";" + ColSTR.get(getTopColour(i)));
 					}
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:topmark:colour", str));
-				}
-			}
-			
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:topmark:colour", str));
+				}
+			}
+
 			for (int i = 0; i < sectors.size(); i++) {
 				String secStr = (i == 0) ? "" : (":" + Integer.toString(i));
 				if (sectors.get(i)[0] != Col.UNKNOWN)
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":colour", ColSTR.get(sectors.get(i)[0])));
-				if (!((String)sectors.get(i)[1]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":character", (String)sectors.get(i)[1]));
-				if (!((String)sectors.get(i)[2]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":group", (String)sectors.get(i)[2]));
-				if (!((String)sectors.get(i)[3]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":sequence", (String)sectors.get(i)[3]));
-				if (!((String)sectors.get(i)[4]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":period", (String)sectors.get(i)[4]));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":colour",
+							ColSTR.get(sectors.get(i)[0])));
+				if (!((String) sectors.get(i)[1]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":character",
+							(String) sectors.get(i)[1]));
+				if (!((String) sectors.get(i)[2]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":group", (String) sectors.get(i)[2]));
+				if (!((String) sectors.get(i)[3]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":sequence",
+							(String) sectors.get(i)[3]));
+				if (!((String) sectors.get(i)[4]).isEmpty())
+					Main.main.undoRedo
+							.add(new ChangePropertyCommand(node, "seamark:light" + secStr
+									+ ":period", (String) sectors.get(i)[4]));
 				if (sectors.get(i)[5] != Lit.UNKNOWN)
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":category", LitSTR.get(sectors.get(i)[5])));
-				if (!((String)sectors.get(i)[6]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":sector_start", (String)sectors.get(i)[6]));
-				if (!((String)sectors.get(i)[7]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":sector_end", (String)sectors.get(i)[7]));
-				if (!((String)sectors.get(i)[8]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":radius", (String)sectors.get(i)[8]));
-				if (!((String)sectors.get(i)[9]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":height", (String)sectors.get(i)[9]));
-				if (!((String)sectors.get(i)[10]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":range", (String)sectors.get(i)[10]));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":category",
+							LitSTR.get(sectors.get(i)[5])));
+				if (!((String) sectors.get(i)[6]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":sector_start", (String) sectors
+									.get(i)[6]));
+				if (!((String) sectors.get(i)[7]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":sector_end",
+							(String) sectors.get(i)[7]));
+				if (!((String) sectors.get(i)[8]).isEmpty())
+					Main.main.undoRedo
+							.add(new ChangePropertyCommand(node, "seamark:light" + secStr
+									+ ":radius", (String) sectors.get(i)[8]));
+				if (!((String) sectors.get(i)[9]).isEmpty())
+					Main.main.undoRedo
+							.add(new ChangePropertyCommand(node, "seamark:light" + secStr
+									+ ":height", (String) sectors.get(i)[9]));
+				if (!((String) sectors.get(i)[10]).isEmpty())
+					Main.main.undoRedo
+							.add(new ChangePropertyCommand(node, "seamark:light" + secStr
+									+ ":range", (String) sectors.get(i)[10]));
 				if (sectors.get(i)[11] != Vis.UNKNOWN)
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":visibility", VisSTR.get(sectors.get(i)[11])));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":visibility", VisSTR.get(sectors
+									.get(i)[11])));
 				if (sectors.get(i)[12] != Exh.UNKNOWN)
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":exhibition", ExhSTR.get(sectors.get(i)[12])));
-				if (!((String)sectors.get(i)[13]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":orientation", (String)sectors.get(i)[13]));
-				if (!((String)sectors.get(i)[14]).isEmpty())
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light" + secStr + ":multiple", (String)sectors.get(i)[14]));
-			}
-			
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":exhibition", ExhSTR.get(sectors
+									.get(i)[12])));
+				if (!((String) sectors.get(i)[13]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":orientation", (String) sectors
+									.get(i)[13]));
+				if (!((String) sectors.get(i)[14]).isEmpty())
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:light" + secStr + ":multiple",
+							(String) sectors.get(i)[14]));
+			}
+
 			if (getFogSound() != Fog.NONE) {
 				if (getFogSound() == Fog.UNKNOWN)
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fog_signal", "yes"));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:fog_signal", "yes"));
 				else
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fog_signal:category", FogSTR.get(getFogSound())));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:fog_signal:category", FogSTR.get(getFogSound())));
 				if (!getFogGroup().isEmpty()) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fog_signal:group", getFogGroup()));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:fog_signal:group", getFogGroup()));
 				}
 				if (!getFogPeriod().isEmpty()) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fog_signal:period", getFogPeriod()));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:fog_signal:period", getFogPeriod()));
 				}
 				if (!getFogSequence().isEmpty()) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fog_signal:sequence", getFogSequence()));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:fog_signal:sequence", getFogSequence()));
 				}
 				if (!getFogRange().isEmpty()) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fog_signal:range", getFogRange()));
-				}
-			}
-			
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:fog_signal:range", getFogRange()));
+				}
+			}
+
 			if (RaType != Rtb.NONE) {
 				if (getRadar() == Rtb.REFLECTOR) {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_reflector", "yes"));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:radar_reflector", "yes"));
 				} else {
-					Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:category", RtbSTR.get(getRadar())));
+					Main.main.undoRedo.add(new ChangePropertyCommand(node,
+							"seamark:radar_transponder:category", RtbSTR.get(getRadar())));
 					if (!getRaconGroup().isEmpty()) {
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:group", getRaconGroup()));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node,
+								"seamark:radar_transponder:group", getRaconGroup()));
 					}
 					if (!getRaconPeriod().isEmpty()) {
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:period", getRaconPeriod()));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node,
+								"seamark:radar_transponder:period", getRaconPeriod()));
 					}
 					if (!getRaconSequence().isEmpty()) {
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:sequence", getRaconSequence()));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node,
+								"seamark:radar_transponder:sequence", getRaconSequence()));
 					}
 					if (!getRaconRange().isEmpty()) {
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:range", getRaconRange()));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node,
+								"seamark:radar_transponder:range", getRaconRange()));
 					}
 					if ((!getRaconSector1().isEmpty()) && (!getRaconSector2().isEmpty())) {
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:sector_start", getRaconSector1()));
-						Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:radar_transponder:sector_end", getRaconSector2()));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node,
+								"seamark:radar_transponder:sector_start", getRaconSector1()));
+						Main.main.undoRedo.add(new ChangePropertyCommand(node,
+								"seamark:radar_transponder:sector_end", getRaconSector2()));
 					}
 				}
@@ -2123,29 +2214,38 @@
 
 			if (!getInfo().isEmpty()) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:information", getInfo()));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:information", getInfo()));
 			}
 			if (!getSource().isEmpty()) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:source", getSource()));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:source", getSource()));
 			}
 			if (getStatus() != Sts.UNKNOWN) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:status", StsSTR.get(getStatus())));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:status", StsSTR.get(getStatus())));
 			}
 			if (getConstr() != Cns.UNKNOWN) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:construction", CnsSTR.get(getConstr())));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:construction", CnsSTR.get(getConstr())));
 			}
 			if (getConsp() != Con.UNKNOWN) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:conspicuity", ConSTR.get(getConsp())));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:conspicuity", ConSTR.get(getConsp())));
 			}
 			if (getRefl() != Con.UNKNOWN) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:reflectivity", ConSTR.get(getRefl())));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:reflectivity", ConSTR.get(getRefl())));
 			}
 			if (!getRef().isEmpty()) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:reference", getRef()));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:reference", getRef()));
 			}
 			if (!getLightRef().isEmpty()) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:light:reference", getLightRef()));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node,
+						"seamark:light:reference", getLightRef()));
 			}
 			if (!getFixme().isEmpty()) {
-				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fixme", getFixme()));
+				Main.main.undoRedo.add(new ChangePropertyCommand(node, "seamark:fixme",
+						getFixme()));
 			}
 		}
