Index: tmp/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/ExportResult.java
===================================================================
--- tmp/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/ExportResult.java	(revision 435)
+++ tmp/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/ExportResult.java	(revision 436)
@@ -48,7 +48,7 @@
 import org.txm.cooccurrence.core.functions.Cooccurrence;
 import org.txm.core.preferences.TBXPreferences;
 import org.txm.core.preferences.TXMPreferences;
-import org.txm.functions.Function;
+import org.txm.functions.TXMCommand;
 import org.txm.functions.referencer.Referencer;
 import org.txm.index.core.functions.Index;
 import org.txm.lexicaltable.core.functions.LexicalTable;
@@ -94,8 +94,8 @@
 		FileDialog dialog = new FileDialog(shell, SWT.SAVE);
 
 		String extensions[] = {"*.csv"}; //$NON-NLS-1$
-		if (s instanceof Function) {
-			extensions = ((Function)s).getExportTXTExtensions(); //$NON-NLS-1$
+		if (s instanceof TXMCommand) {
+			extensions = ((TXMCommand)s).getExportTXTExtensions(); //$NON-NLS-1$
 		}
 		dialog.setFilterExtensions(extensions);
 
@@ -126,10 +126,10 @@
 				return null;
 			}
 
-			final String encoding = TXMPreferences.getString(TBXPreferences.PREFERENCES_NODE, TBXPreferences.EXPORT_ENCODING); //$NON-NLS-1$
-			String _colseparator = TXMPreferences.getString(TBXPreferences.PREFERENCES_NODE, TBXPreferences.EXPORT_COLSEPARATOR);
+			final String encoding = TXMPreferences.getString(TBXPreferences.EXPORT_ENCODING, TBXPreferences.PREFERENCES_NODE);
+			String _colseparator = TXMPreferences.getString(TBXPreferences.EXPORT_COLSEPARATOR, TBXPreferences.PREFERENCES_NODE);
 			final String colseparator = _colseparator;
-			String _txtseparator = TXMPreferences.getString(TBXPreferences.PREFERENCES_NODE, TBXPreferences.EXPORT_TXTSEPARATOR);
+			String _txtseparator = TXMPreferences.getString(TBXPreferences.EXPORT_TXTSEPARATOR, TBXPreferences.PREFERENCES_NODE);
 			final String txtseparator = _txtseparator;
 
 			JobHandler jobhandler = new JobHandler(Messages.ExportResult_0) {
@@ -139,8 +139,8 @@
 						this.runInit(monitor);
 						monitor.beginTask(Messages.ExportResult_1, 100);
 
-						if (s instanceof Function)
-							((Function)s).setCurrentMonitor(this); // Allows Functions to protect themselves from interruption
+						if (s instanceof TXMCommand)
+							((TXMCommand)s).setCurrentMonitor(this); // Allows Functions to protect themselves from interruption
 
 						if (s instanceof SpecificitesResult)
 							((SpecificitesResult) s).toTxt(outfile, encoding, colseparator, txtseparator);
@@ -164,13 +164,13 @@
 							((CAH) s).toTxt(outfile, encoding);
 						} else if (s instanceof Progression) {
 							((Progression) s).toTxt(outfile, encoding);
-						} else if (s instanceof Function) {
-							((Function)s).toTxt(outfile, encoding, colseparator, txtseparator);
+						} else if (s instanceof TXMCommand) {
+							((TXMCommand)s).toTxt(outfile, encoding, colseparator, txtseparator);
 						}
 
 						if (outfile.exists()) {
 							// Open internal editor in the UI thread
-							if(TXMPreferences.getBoolean(TBXPreferences.PREFERENCES_NODE, TBXPreferences.EXPORT_SHOW))	{
+							if(TXMPreferences.getBoolean(TBXPreferences.EXPORT_SHOW, TBXPreferences.PREFERENCES_NODE))	{
 								this.syncExec(new Runnable() {
 									@Override
 									public void run() {
@@ -184,16 +184,16 @@
 							System.out.println(NLS.bind(Messages.ExportResult_6, outfile.getAbsolutePath()));
 						}
 					} catch (ThreadDeath td) {
-						if (s instanceof Function)
-							((Function)s).clean();
+						if (s instanceof TXMCommand)
+							((TXMCommand)s).clean();
 						return Status.CANCEL_STATUS;
 					} catch (Exception e) {
 						System.out.println(NLS.bind(Messages.ExportResult_6, s, e));
 						org.txm.rcp.utils.Logger.printStackTrace(e);
 						return Status.CANCEL_STATUS;
 					} finally {
-						if (s instanceof Function)
-							((Function)s).setCurrentMonitor(null);
+						if (s instanceof TXMCommand)
+							((TXMCommand)s).setCurrentMonitor(null);
 						monitor.done();
 						JobsTimer.stopAndPrint();
 					}
Index: tmp/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/ComputeDiagnostic.java
===================================================================
--- tmp/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/ComputeDiagnostic.java	(revision 435)
+++ tmp/org.txm.rcp/src/main/java/org/txm/rcp/commands/function/ComputeDiagnostic.java	(revision 436)
@@ -119,7 +119,7 @@
 					JobsTimer.start();
 					//this.setCurrentMonitor(monitor);
 					monitor.beginTask(NLS.bind(Messages.Diagnostique_0, corpus.getName()), 100);
-					final int maxvalue = TXMPreferences.getInt(RCPPreferences.PREFERENCES_NODE, RCPPreferences.MAXVALUE);
+					final int maxvalue = TXMPreferences.getInt(RCPPreferences.MAXVALUE, RCPPreferences.PREFERENCES_NODE);
 					diagfile.getParentFile().mkdir();
 					
 					if (monitor.isCanceled())
