Index: trunk/src/org/expeditee/gui/AttributeUtils.java
===================================================================
--- trunk/src/org/expeditee/gui/AttributeUtils.java	(revision 1187)
+++ trunk/src/org/expeditee/gui/AttributeUtils.java	(revision 1188)
@@ -392,10 +392,10 @@
 			Attribute a = attribSet.get(prop);
 			// Make sure the classes of the methods match the item
-			if (a != null && a.getter != null && a.getter.getDeclaringClass().isAssignableFrom(toExtract.getClass())) {
-				
+			if (a != null && a.getter != null && a.getter.getDeclaringClass().isAssignableFrom(toExtract.getClass())) {	
 				try {
 					String s = getValue(prop, a, toExtract, true);
-					if (s == null)
+					if (s == null) {
 						continue;
+					}
 					// Append the attributes
 					attributes.append(a.displayName)
@@ -410,9 +410,11 @@
 
 		// if no attributes were extracted
-		if (attributes.length() <= 0)
+		if (attributes.length() <= 0) {
 			return null;
-
-		while (attributes.charAt(attributes.length() - 1) == '\n')
+		}
+
+		while (attributes.charAt(attributes.length() - 1) == '\n') {
 			attributes.delete(attributes.length() - 1, attributes.length());
+		}
 
 		// create the text Item
@@ -450,12 +452,13 @@
 			// are in the AllowNull list
 			if (_AllowNull.contains(a.getter)) {
-				if (name.equals("color"))
+				if (name.equals("color")) {
 					o = "default";
-				else if (name.equals("backgroundcolor"))
+				} else if (name.equals("backgroundcolor")) {
 					o = "transparent";
-				else if (name.equals("foregroundcolor"))
+				} else if (name.equals("foregroundcolor")) {
 					o = "auto";
-				else
+				} else {
 					o = "";
+				}
 			} else {
 				return null;
@@ -469,26 +472,32 @@
 		if (o instanceof Integer) {
 			Integer i = (Integer) o;
-			if (i == Item.DEFAULT_INTEGER)
+			if (i == Item.DEFAULT_INTEGER) {
 				return null;
+			}
 			if (a.getter.getName().endsWith("Justification")
-					&& ((Justification) o).toString() != null)
+					&& ((Justification) o).toString() != null) {
 				o = ((Justification) o).toString();
 			// -1 indicates default value
-			else
+			} else {
 				o = i;
+			}
 		} else if (o instanceof Float) {
 			if (((Float) o) < -0.0001)
+			 {
 				return null;
 			// Null indicates default
 			// o = Math.round((Float) o);
+			}
 		} else if (o instanceof Double) {
 			// -1 indicates default value
-			if (((Double) o) < 0.0001)
+			if (((Double) o) < 0.0001) {
 				return null;
+			}
 		} else if (o instanceof Colour) {
 			// converts the color to the Expeditee code
 			o = Conversion.getExpediteeColorCode((Colour) o);
-			if (o == null)
+			if (o == null) {
 				return null;
+			}
 		} else if (o instanceof Point) {
 			Point p = (Point) o;
@@ -498,12 +507,15 @@
 
 			String s = f.getFamilyName() + "-";
-			if (f.isPlain())
+			if (f.isPlain()) {
 				s += "Plain";
-
-			if (f.isBold())
+			}
+
+			if (f.isBold()) {
 				s += "Bold";
-
-			if (f.isItalic())
+			}
+
+			if (f.isItalic()) {
 				s += "Italic";
+			}
 
 			s += "-" + f.getSize();
@@ -514,5 +526,5 @@
 			List list = (List) o;
 			StringBuffer sb = new StringBuffer();
-			for (Object ob : list)
+			for (Object ob : list) {
 				// TODO check that this works ok
 				if (sb.length() == 0) {
@@ -521,4 +533,5 @@
 					sb.append('\n').append(a.displayName).append(AttributeValuePair.SEPARATOR_STRING).append(ob);
 				}
+			}
 			return sb.toString();
 		} else if (o instanceof int[]) {
@@ -532,6 +545,7 @@
 		} else if (o instanceof Boolean) {
 			// true is the default for boolean values
-			if (((Boolean) o).booleanValue())
+			if (((Boolean) o).booleanValue()) {
 				return null;
+			}
 		}
 		return o.toString();
@@ -557,6 +571,7 @@
 			int minAttributeLength) {
 		// error checking
-		if (toSet == null || attribs == null)
+		if (toSet == null || attribs == null) {
 			return false;
+		}
 
 		ensureReady();
@@ -589,6 +604,7 @@
 			// attribute merging
 			if (!avp.hasAttribute()
-					|| avp.getAttribute().length() < minAttributeLength)
+					|| avp.getAttribute().length() < minAttributeLength) {
 				return false;
+			}
 
 			// check if the next string is another attribute to merge or a
@@ -699,6 +715,7 @@
 		// if there are duplicate methods with the same name
 		List<Method> possibles = new LinkedList<Method>();
-		if (a.setter.getDeclaringClass().isInstance(toSet))
+		if (a.setter.getDeclaringClass().isInstance(toSet)) {
 			possibles.add(a.setter);
+		}
 		int i = 0;
 		while (attribSet.containsKey(attribute + i)) {
@@ -741,6 +758,7 @@
 
 		if(possibles.size() == 0){
-			if(invokeAttributeGetMethod(avp.getAttribute(), toSet) == null)
+			if(invokeAttributeGetMethod(avp.getAttribute(), toSet) == null) {
 				throw new NoSuchAttributeException(avp.getAttribute(), toSet.getClass().getSimpleName());
+			}
 			throw new ReadOnlyAttributeException(avp.getAttribute(), toSet.getClass().getSimpleName());
 		}
Index: trunk/src/org/expeditee/gui/FrameIO.java
===================================================================
--- trunk/src/org/expeditee/gui/FrameIO.java	(revision 1187)
+++ trunk/src/org/expeditee/gui/FrameIO.java	(revision 1188)
@@ -152,10 +152,12 @@
 	public static void Precache(String framename) {
 		// if the cache is turned off, do nothing
-		if (!isCacheOn())
+		if (!isCacheOn()) {
 			return;
+		}
 
 		// if the frame is already in the cache, do nothing
-		if (_Cache.containsKey(framename.toLowerCase()))
+		if (_Cache.containsKey(framename.toLowerCase())) {
 			return;
+		}
 
 		// otherwise, load the frame and put it in the cache
@@ -177,16 +179,20 @@
 	 */
 	public static boolean isPositiveInteger(String s) {
-		if (s == null || s.length() == 0)
+		if (s == null || s.length() == 0) {
 			return false;
+		}
 
 		for (int i = 0; i < s.length(); i++) {
-			if (!Character.isDigit(s.charAt(i)))
+			if (!Character.isDigit(s.charAt(i))) {
 				return false;
+			}
 		}
 		return true;
 	}
+	
+	public static String FRAMESET_CONSULT_PATH = null;
 
 	public static Frame LoadFrame(String frameName) {
-		return LoadFrame(frameName, null, false);
+		return LoadFrame(frameName, FRAMESET_CONSULT_PATH, false);
 	}
 
@@ -197,5 +203,7 @@
 	public static Frame LoadFrame(String frameName, String path, boolean ignoreAnnotations)
 	{
-		if (!isValidFrameName(frameName)) return null;
+		if (!isValidFrameName(frameName)) {
+			return null;
+		}
 
 		String frameNameLower = frameName.toLowerCase();
@@ -261,6 +269,7 @@
 		String fullPath = FrameIO.getFrameFullPathName(PUBLIC_PATH, frameName);
 
-		if (fullPath == null)
+		if (fullPath == null) {
 			return null;
+		}
 
 		File frameFile = new File(fullPath);
@@ -313,6 +322,7 @@
 		for (String path : FolderSettings.FrameDirs.get()) {
 			File files = new File(path);
-			if (!files.exists())
+			if (!files.exists()) {
 				continue;
+			}
 			for (File f : (new File(path)).listFiles()) {
 				if (f.isDirectory()) {
@@ -354,6 +364,7 @@
 
 		File tester = new File(source);
-		if (!tester.exists())
+		if (!tester.exists()) {
 			return null;
+		}
 
 		String fullPath;
@@ -372,6 +383,7 @@
 		tester = new File(fullPath);
 
-		if (tester.exists())
+		if (tester.exists()) {
 			return fullPath;
+		}
 
 		// check for oldfile name format
@@ -380,6 +392,7 @@
 		tester = new File(fullPath);
 
-		if (tester.exists())
+		if (tester.exists()) {
 			return fullPath;
+		}
 
 		return null;
@@ -396,6 +409,7 @@
 
 		for (String path : FolderSettings.FrameDirs.get()) {
-			if (getFrameFullPathName(path, frameName) != null)
+			if (getFrameFullPathName(path, frameName) != null) {
 				return true;
+			}
 		}
 		return false;
@@ -408,6 +422,7 @@
 			for (String possiblePath : FolderSettings.FrameDirs.get()) {
 				fullPath = getFrameFullPathName(possiblePath, frameName);
-				if (fullPath != null)
+				if (fullPath != null) {
 					break;
+				}
 			}
 		} else {
@@ -415,6 +430,7 @@
 		}
 		// If the frame was not located return null
-		if (fullPath == null)
+		if (fullPath == null) {
 			return null;
+		}
 		Collection<String> results = new LinkedList<String>();
 		// Open the file and search the text items
@@ -425,6 +441,7 @@
 				if (next.startsWith("T")) {
 					String toSearch = next.substring(2);
-					if (toSearch.toLowerCase().contains(pattern))
+					if (toSearch.toLowerCase().contains(pattern)) {
 						results.add(toSearch);
+					}
 				}
 			}
@@ -440,6 +457,7 @@
 	private static Frame LoadKnowPath(String path, String frameName) {
 		String fullPath = getFrameFullPathName(path, frameName);
-		if (fullPath == null)
+		if (fullPath == null) {
 			return null;
+		}
 
 		try {
@@ -463,9 +481,11 @@
 			// do not put 0 frames or virtual frames into the cache
 			// Why are zero frames not put in the cache
-			if (_Cache.size() > MAX_CACHE)
+			if (_Cache.size() > MAX_CACHE) {
 				_Cache.clear();
-
-			if (frame.getNumber() > 0 && isCacheOn())
+			}
+
+			if (frame.getNumber() > 0 && isCacheOn()) {
 				_Cache.put(frameName.toLowerCase(), frame);
+			}
 
 			return frame;
@@ -490,6 +510,7 @@
 		Frame fresh = FrameIO.LoadFrame(DisplayController.getCurrentFrame().getName());
 		_UseCache = cache;
-		if (_Cache.containsKey(fresh.getName().toLowerCase()))
+		if (_Cache.containsKey(fresh.getName().toLowerCase())) {
 			addToCache(fresh);
+		}
 		DisplayController.setCurrentFrame(fresh, false);
 	}
@@ -505,6 +526,7 @@
 		for (; num >= 0; num--) {
 			Frame f = LoadFrame(name + num, current.getPath());
-			if (f != null)
+			if (f != null) {
 				return f;
+			}
 		}
 
@@ -543,6 +565,7 @@
 		for (; num <= max; num++) {
 			Frame f = LoadFrame(name + num, current.getPath());
-			if (f != null)
+			if (f != null) {
 				return f;
+			}
 		}
 
@@ -582,6 +605,7 @@
 		for (int num = max; num > 0; num--) {
 			Frame f = LoadFromDisk(framesetName + num, path, false);
-			if (f != null)
+			if (f != null) {
 				return f;
+			}
 		}
 
@@ -625,6 +649,7 @@
 	public static String DeleteFrame(Frame toDelete) throws IOException,
 			SecurityException {
-		if (toDelete == null)
+		if (toDelete == null) {
 			return null;
+		}
 
 		// Dont delete the zero frame
@@ -667,6 +692,7 @@
 		ForceSaveFrame(toDelete);
 
-		if (_Cache.containsKey(oldFrameName))
+		if (_Cache.containsKey(oldFrameName)) {
 			_Cache.remove(oldFrameName);
+		}
 
 		File del = new File(source);
@@ -761,6 +787,7 @@
 
 		for (Item i : template.getItems()) {
-			if (ItemUtils.startsWithTag(i, ItemUtils.TAG_PARENT))
+			if (ItemUtils.startsWithTag(i, ItemUtils.TAG_PARENT)) {
 				i.setLink(null);
+			}
 		}
 
@@ -812,5 +839,7 @@
 	{
 		SuspendCache();
-		for (Frame frame : _Cache.values()) frame.setBuffer(null);
+		for (Frame frame : _Cache.values()) {
+			frame.setBuffer(null);
+		}
 		ResumeCache();
 	}
@@ -842,18 +871,21 @@
 	public static boolean isValidFrameName(String frameName) {
 
-		if (frameName == null || frameName.length() < 2)
+		if (frameName == null || frameName.length() < 2) {
 			return false;
+		}
 
 		int lastCharIndex = frameName.length() - 1;
 		// String must begin with a letter and end with a digit
 		if (!Character.isLetter(frameName.charAt(0))
-				|| !Character.isDigit(frameName.charAt(lastCharIndex)))
+				|| !Character.isDigit(frameName.charAt(lastCharIndex))) {
 			return false;
+		}
 
 		// All the characters between first and last must be letters
 		// or digits
 		for (int i = 1; i < lastCharIndex; i++) {
-			if (!isValidFrameNameChar(frameName.charAt(i)))
+			if (!isValidFrameNameChar(frameName.charAt(i))) {
 				return false;
+			}
 		}
 		return true;
@@ -1011,6 +1043,7 @@
 
 				Frame original = LoadFrame(toSave.getName());
-				if (original == null)
+				if (original == null) {
 					original = toSave;
+				}
 				int orignum = original.getNumber();
 
@@ -1056,6 +1089,7 @@
 
 			// avoid out-of-sync frames (when in TwinFrames mode)
-			if (_Cache.containsKey(toSave.getName().toLowerCase()))
+			if (_Cache.containsKey(toSave.getName().toLowerCase())) {
 				addToCache(toSave);
+			}
 
 			Logger.Log(Logger.SYSTEM, Logger.SAVE, "Saving " + toSave.getName()
@@ -1065,7 +1099,8 @@
 			int last = ReadINF(toSave.getPath(), toSave.getFramesetName(),
 					false);
-			if (last <= toSave.getNumber())
+			if (last <= toSave.getNumber()) {
 				WriteINF(toSave.getPath(), toSave.getFramesetName(), toSave
 						.getName());
+			}
 
 			// check if this was the profile frame (and thus needs
@@ -1152,5 +1187,7 @@
 	public static boolean isProfileFrame(Frame toCheck)
 	{
-		if (toCheck.getNumber() == 0) return false;
+		if (toCheck.getNumber() == 0) {
+			return false;
+		}
 		
 		return toCheck.getPath().equals(PROFILE_PATH);
@@ -1275,6 +1312,7 @@
 					capital = false;
 					result.append(Character.toUpperCase(cur));
-				} else
+				} else {
 					result.append(cur);
+				}
 			} else {
 				capital = true;
@@ -1284,8 +1322,9 @@
 		int lastCharIndex = result.length() - 1;
 		if (!Character.isLetter(result.charAt(lastCharIndex))) {
-			if (lastCharIndex == MAX_NAME_LENGTH - 1)
+			if (lastCharIndex == MAX_NAME_LENGTH - 1) {
 				result.setCharAt(lastCharIndex, FRAME_NAME_LAST_CHAR);
-			else
+			} else {
 				result.append(FRAME_NAME_LAST_CHAR);
+			}
 		}
 
@@ -1308,5 +1347,7 @@
 	public static Frame CreateNewFrame(Item linker, OnNewFrameAction action) throws RuntimeException {
 	    Frame newFrame = FrameIO.CreateNewFrame(linker);
-	    if(action != null) action.exec(linker, newFrame);
+	    if(action != null) {
+			action.exec(linker, newFrame);
+		}
 	    return newFrame;
 	}
@@ -1358,6 +1399,7 @@
 
 		// the frameset does not exist (or has no 0 frame)
-		if (zero == null)
+		if (zero == null) {
 			return -1;
+		}
 
 		try {
@@ -1388,6 +1430,7 @@
 		framesetName = framesetName.toLowerCase();
 		for (String path : FolderSettings.FrameDirs.get()) {
-			if ((new File(path + framesetName)).exists())
+			if ((new File(path + framesetName)).exists()) {
 				return true;
+			}
 		}
 		return false;
@@ -1398,5 +1441,7 @@
 		String conversion = frameset + " --> ";
 
-		if (!isValidFramesetName(frameset)) throw new Exception("Invalid frameset name");
+		if (!isValidFramesetName(frameset)) {
+			throw new Exception("Invalid frameset name");
+		}
 
 		if (!recreate && FrameIO.canAccessFrameset(frameset)) {
@@ -1413,6 +1458,7 @@
 		 */
 		// ignore annotation character
-		if (frameset.startsWith("@"))
+		if (frameset.startsWith("@")) {
 			frameset = frameset.substring(1);
+		}
 
 		conversion += " --> " + frameset;
@@ -1498,6 +1544,7 @@
 
 		if (!Character.isLetter(frameset.charAt(0))
-				|| !Character.isLetter(frameset.charAt(lastCharIndex)))
+				|| !Character.isLetter(frameset.charAt(lastCharIndex))) {
 			return false;
+		}
 
 		for (int i = 1; i < lastCharIndex; i++) {
@@ -1515,6 +1562,7 @@
 	public static boolean moveFrameset(String framesetName,
 			String destinationFolder) {
-		if (!FrameIO.canAccessFrameset(framesetName))
+		if (!FrameIO.canAccessFrameset(framesetName)) {
 			return false;
+		}
 		// Clear the cache
 		_Cache.clear();
@@ -1531,6 +1579,7 @@
 				File dest = new File(destPath + File.separator);
 				// Create the destination folder if it doesnt already exist
-				if (!dest.getParentFile().exists())
+				if (!dest.getParentFile().exists()) {
 					dest.mkdirs();
+				}
 				// If a frameset with the same name is already in the
 				// destination add
@@ -1541,9 +1590,11 @@
 				if (!framesetDirectory.renameTo(dest)) {
 					for (File f : framesetDirectory.listFiles()) {
-						if (!f.delete())
+						if (!f.delete()) {
 							return false;
+						}
 					}
-					if (!framesetDirectory.delete())
+					if (!framesetDirectory.delete()) {
 						return false;
+					}
 				}
 				return true;
@@ -1555,8 +1606,10 @@
 	public static boolean CopyFrameset(String framesetToCopy,
 			String copiedFrameset) throws Exception {
-		if (!FrameIO.canAccessFrameset(framesetToCopy))
+		if (!FrameIO.canAccessFrameset(framesetToCopy)) {
 			return false;
-		if (FrameIO.canAccessFrameset(copiedFrameset))
+		}
+		if (FrameIO.canAccessFrameset(copiedFrameset)) {
 			return false;
+		}
 		// search through all the directories to find the frameset we are
 		// copying
@@ -1569,11 +1622,13 @@
 				File copyFramesetDirectory = new File(path
 						+ copiedFrameset.toLowerCase() + File.separator);
-				if (!copyFramesetDirectory.mkdirs())
+				if (!copyFramesetDirectory.mkdirs()) {
 					return false;
+				}
 				// copy each of the frames
 				for (File f : framesetDirectory.listFiles()) {
 					// Ignore hidden files
-					if (f.getName().charAt(0) == '.')
+					if (f.getName().charAt(0) == '.') {
 						continue;
+					}
 					String copyPath = copyFramesetDirectory.getAbsolutePath()
 							+ File.separator + f.getName();
