Bug 6092 JavaEditor should honor the tab width setting of the JavaFormatter
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
PREF_STYLE_COMPACT_ASSIGNEMENT, PREF_TAB_CHAR, PREF_TAB_SIZE
		};	
	}
	
	/**
	 * Gets the currently configured tab size
	 */
	public static int getTabSize() {
		String string= (String) JavaCore.getOptions().get(PREF_TAB_SIZE);
		return getIntValue(string, 4);
	}
	
	/**
	 * Gets the current compating assignement configuration
	 */	
	public static boolean isCompactingAssignment() {
		return COMPACT.equals(JavaCore.getOptions().get(PREF_STYLE_COMPACT_ASSIGNEMENT));
	}
	
	/**
	 * Gets the current compating assignement configuration
	 */	
	public static boolean useSpaces() {
		return SPACE.equals(JavaCore.getOptions().get(PREF_TAB_CHAR));
	}	
	
	
	private static int getIntValue(String string, int dflt) {
		try {
			return Integer.parseInt(string);