Index: tmp/org.txm.lexicaltable.rcp/src/org/txm/lexicaltable/rcp/editors/LexicalTableEditor.java
===================================================================
--- tmp/org.txm.lexicaltable.rcp/src/org/txm/lexicaltable/rcp/editors/LexicalTableEditor.java	(revision 565)
+++ tmp/org.txm.lexicaltable.rcp/src/org/txm/lexicaltable/rcp/editors/LexicalTableEditor.java	(revision 566)
@@ -398,7 +398,7 @@
 		viewer.getTable().setSortColumn(formColumn.getColumn());
 		viewer.getTable().setSortDirection(SWT.UP);
 
-		this.refresh(false);
+		this.updateEditorFromResult(false);
 		
 		this.createContextMenu(viewer);
 		
@@ -448,7 +448,7 @@
 		// Refresh and pack the columns
 		TXMEditorPart.packColumns(this.viewer);
 		
-		updateEditorFromResult(false);
+//		updateEditorFromResult(false);
 		
 		this.viewer.getTable().deselectAll();
 		this.viewer.getTable().setFocus();
@@ -623,10 +623,11 @@
 		
 		this.refreshTable();
 		this.refreshInfos();
-		super.refresh(update);
+		//super.refresh(update);
 		
 		QueriesView.refresh();
 		RVariablesView.refresh();
+
 	}
 
 	 
Index: tmp/org.txm.internalview.rcp/src/org/txm/internal/rcp/editors/InternalViewEditor.java
===================================================================
--- tmp/org.txm.internalview.rcp/src/org/txm/internal/rcp/editors/InternalViewEditor.java	(revision 565)
+++ tmp/org.txm.internalview.rcp/src/org/txm/internal/rcp/editors/InternalViewEditor.java	(revision 566)
@@ -261,7 +261,7 @@
 			@Override
 			public void widgetSelected(SelectionEvent e) {
 				internalView.setParameters(null,  null, null, 0);
-				TXMEditorPart.compute(getResultData(), true, InternalViewEditor.this);
+				compute(true);
 			}
 
 			@Override
@@ -424,7 +424,6 @@
 		
 		createContextMenu();
 		
-		TXMEditorPart.compute(getResultData(), true, InternalViewEditor.this);
 	}
 
 	protected boolean goToPage(int next) throws CqiClientException {
Index: tmp/org.txm.partition.core/src/org/txm/partition/core/functions/PartitionDimensions.java
===================================================================
--- tmp/org.txm.partition.core/src/org/txm/partition/core/functions/PartitionDimensions.java	(revision 565)
+++ tmp/org.txm.partition.core/src/org/txm/partition/core/functions/PartitionDimensions.java	(revision 566)
@@ -28,22 +28,62 @@
  */
 public class PartitionDimensions extends ChartResult {
 
-	/** if true the part bars are sorted by size. */
-	@Parameter
-	protected Boolean pSortBySize;
+	/**
+	 * Parent partition parts caching.
+	 */
+	protected List<Part> parts = null;
 	
 	/**
+	 * Parent partition parts sorted by size caching.
+	 */
+	protected List<Part> partsSortedBySize = null;
+	
+	
+	
+	@Parameter(type=Parameter.RENDERING)
+	protected boolean displayPartCountInTitle;
+
+	@Parameter(type=Parameter.RENDERING)
+	protected boolean sortBySize;
+
+	
+	/**
 	 * Creates a partition dimensions result from the specified <link>Partition</link>.
 	 */
 	public PartitionDimensions(Partition partition) {
 		super(partition);
+		this.loadParameters();
 	}
 
 
 
 	@Override
+	public boolean loadParameters() {
+		this.displayPartCountInTitle = this.getBooleanParameterValue(PartitionDimensionsPreferences.CHART_DIMENSIONS_DISPLAY_PARTS_COUNT_IN_TITLE);
+		this.sortBySize = this.getBooleanParameterValue(PartitionDimensionsPreferences.CHART_DIMENSIONS_SORT_BY_SIZE);
+		return true;
+	}
+
+	
+	@Override
 	protected boolean _compute(boolean update) throws Exception {
-		// does nothing
+		// parts
+		this.parts = this.getPartition().getParts();
+		
+		// parts sorted by size 
+		List<Part> sortedParts = new ArrayList<Part>(this.parts);
+		Collections.sort(sortedParts, new Comparator<Part>() {
+			@Override
+			public int compare(Part arg0, Part arg1) {
+				try {
+					return arg1.getSize() - arg0.getSize();
+				} catch (CqiClientException e) {
+					return 0;
+				}
+			}
+		});
+		this.partsSortedBySize = sortedParts;
+		
 		return true;
 	}
 
@@ -62,7 +102,7 @@
 	@Override
 	public boolean setParameters(TXMParameters parameters) {
 		try {
-			this.setParameters((boolean)parameters.get(PartitionDimensionsPreferences.SORTED_BY_SIZE));
+			this.setSortBySize((boolean)parameters.get(PartitionDimensionsPreferences.CHART_DIMENSIONS_SORT_BY_SIZE));
 			return true;
 		}
 		catch(Exception e) {
@@ -72,29 +112,8 @@
 		return false;
 	}
 
-	/**
-	 * 
-	 * @param sortByPartSize
-	 */
-	public void setParameters(boolean sortByPartSize)	{
-		pSortBySize = sortByPartSize;
-		this.setDirty();
-		this.setChartDirty();
-	}
 
-	@Override
-	public boolean loadParameters() {
-		pSortBySize = getBooleanParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE);
-		return true;
-	}
 	
-	@Override
-	public boolean saveParameters() {
-		if (pSortBySize != null) setParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE, pSortBySize);
-		return true;
-	}
-
-	
 	/**
 	 * Convenience method.
 	 */
@@ -108,27 +127,6 @@
 		}
 	}
 	
-	/**
-	 * Gets a copy of the parts sorted by descendant size order.
-	 * @return
-	 */
-	public List<Part> getPartsSortedBySize()	{
-		
-		List<Part> sortedParts = new ArrayList<Part>(this.getPartition().getParts());
-		
-		Collections.sort(sortedParts, new Comparator<Part>() {
-			@Override
-			public int compare(Part arg0, Part arg1) {
-				try {
-					return arg1.getSize() - arg0.getSize();
-				} catch (CqiClientException e) {
-					return 0;
-				}
-			}
-		});
-		
-		return sortedParts;
-	}
 	
 
 	/**
@@ -136,7 +134,7 @@
 	 * @return
 	 */
 	public int getPartsCount()	{
-		return this.getPartition().getNPart();
+		return this.parts.size();
 	}
 	
 	/**
@@ -146,10 +144,10 @@
 	 */
 	public List<Part> getParts(boolean sortedBySize) {
 		if(sortedBySize)	{
-			return this.getPartsSortedBySize();
+			return this.partsSortedBySize;
 		}
 		else	{
-			return this.getPartition().getParts();
+			return this.parts;
 		}
 	}
 	
@@ -193,4 +191,31 @@
 		return false;
 	}
 
+
+
+	/**
+	 * @return the sortBySize
+	 */
+	public boolean isSortingBySize() {
+		return sortBySize;
+	}
+
+
+
+	/**
+	 * @param sortBySize the sortBySize to set
+	 */
+	public void setSortBySize(boolean sortBySize) {
+		this.sortBySize = sortBySize;
+	}
+
+
+
+	/**
+	 * @return the displayPartCountInTitle
+	 */
+	public boolean isDisplayingPartCountInTitle() {
+		return displayPartCountInTitle;
+	}
+
 }
Index: tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/jfreechart/JFCPartitionDimensionsPieChartCreator.java
===================================================================
--- tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/jfreechart/JFCPartitionDimensionsPieChartCreator.java	(revision 565)
+++ tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/jfreechart/JFCPartitionDimensionsPieChartCreator.java	(revision 566)
@@ -3,12 +3,10 @@
 
 import org.jfree.chart.JFreeChart;
 import org.jfree.data.general.DefaultPieDataset;
-import org.txm.core.preferences.TXMPreferences;
-import org.txm.core.results.TXMResult;
 import org.txm.chartsengine.jfreechart.core.JFCChartCreator;
+import org.txm.core.results.TXMResult;
 import org.txm.partition.core.chartsengine.base.Utils;
 import org.txm.partition.core.functions.PartitionDimensions;
-import org.txm.partition.core.preferences.PartitionDimensionsPreferences;
 import org.txm.searchengine.cqp.clientExceptions.CqiClientException;
 import org.txm.searchengine.cqp.corpus.Part;
 
@@ -20,8 +18,6 @@
 
 public class JFCPartitionDimensionsPieChartCreator extends JFCChartCreator {
 
-	public JFCPartitionDimensionsPieChartCreator() {
-	}
 
 	@Override
 	public Object createChart(TXMResult result) {
@@ -29,8 +25,8 @@
 		PartitionDimensions partitionDimensions = (PartitionDimensions) result;
 		
 		// parameters
-		boolean sortPartsBySize = result.getBooleanParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE);
-		boolean displayPartsCountInTitle = result.getBooleanParameterValue(PartitionDimensionsPreferences.DISPLAY_PARTS_COUNT_IN_TITLE);
+		boolean sortPartsBySize = partitionDimensions.isSortingBySize();
+		boolean displayPartsCountInTitle = partitionDimensions.isDisplayingPartCountInTitle();
 
 		
 		JFreeChart chart = null;
Index: tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/jfreechart/JFCPartitionDimensionsBarChartCreator.java
===================================================================
--- tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/jfreechart/JFCPartitionDimensionsBarChartCreator.java	(revision 565)
+++ tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/jfreechart/JFCPartitionDimensionsBarChartCreator.java	(revision 566)
@@ -5,6 +5,7 @@
 
 import org.jfree.chart.JFreeChart;
 import org.jfree.chart.axis.NumberAxis;
+import org.jfree.chart.axis.SymbolAxis;
 import org.jfree.chart.title.TextTitle;
 import org.jfree.chart.title.Title;
 import org.jfree.data.general.DatasetUtilities;
@@ -19,7 +20,6 @@
 import org.txm.partition.core.chartsengine.base.Utils;
 import org.txm.partition.core.functions.PartitionDimensions;
 import org.txm.partition.core.messages.PartitionCoreMessages;
-import org.txm.partition.core.preferences.PartitionDimensionsPreferences;
 import org.txm.searchengine.cqp.clientExceptions.CqiClientException;
 import org.txm.searchengine.cqp.corpus.Part;
 
@@ -30,8 +30,6 @@
  */
 public class JFCPartitionDimensionsBarChartCreator extends JFCChartCreator {
 
-	public JFCPartitionDimensionsBarChartCreator() {
-	}
 
 	@Override
 	public JFreeChart createChart(TXMResult result) {
@@ -63,8 +61,8 @@
 		
 		
 		// parameters
-		boolean sortPartsBySize = result.getBooleanParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE);
-		boolean displayPartsCountInTitle = result.getBooleanParameterValue(PartitionDimensionsPreferences.DISPLAY_PARTS_COUNT_IN_TITLE);
+		boolean sortPartsBySize = partitionDimensions.isSortingBySize();
+		boolean displayPartsCountInTitle = partitionDimensions.isDisplayingPartCountInTitle();
 		
 		// Fill the data set
 		XYSeriesCollection dataset = (XYSeriesCollection) jfcChart.getXYPlot().getDataset();
@@ -91,7 +89,7 @@
 		}
 
 		jfcChart.getXYPlot().setDomainAxis(new SymbolAxisBetweenTicks(jfcChart.getXYPlot().getDomainAxis().getLabel(), xAxisSymbols));
-
+		
 		// Create chart title
 		jfcChart.setTitle(Utils.createPartitionDimensionsChartTitle(partitionDimensions, sortPartsBySize, displayPartsCountInTitle));
 		
Index: tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/r/RPartitionDimensionsBarChartCreator.java
===================================================================
--- tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/r/RPartitionDimensionsBarChartCreator.java	(revision 565)
+++ tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/r/RPartitionDimensionsBarChartCreator.java	(revision 566)
@@ -10,7 +10,6 @@
 import org.txm.partition.core.chartsengine.base.Utils;
 import org.txm.partition.core.functions.PartitionDimensions;
 import org.txm.partition.core.messages.PartitionCoreMessages;
-import org.txm.partition.core.preferences.PartitionDimensionsPreferences;
 import org.txm.searchengine.cqp.corpus.Part;
 import org.txm.utils.logger.Log;
 
@@ -30,8 +29,8 @@
 			PartitionDimensions partitionDimensions = (PartitionDimensions) result;
 			
 			// parameters
-			boolean sortPartsBySize = result.getBooleanParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE);
-			boolean displayPartsCountInTitle = result.getBooleanParameterValue(PartitionDimensionsPreferences.DISPLAY_PARTS_COUNT_IN_TITLE);
+			boolean sortPartsBySize = partitionDimensions.isSortingBySize();
+			boolean displayPartsCountInTitle = partitionDimensions.isDisplayingPartCountInTitle();
 			
 			List<Part> parts = partitionDimensions.getParts(sortPartsBySize);
 			
Index: tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/r/RPartitionDimensionsPieChartCreator.java
===================================================================
--- tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/r/RPartitionDimensionsPieChartCreator.java	(revision 565)
+++ tmp/org.txm.partition.core/src/org/txm/partition/core/chartsengine/r/RPartitionDimensionsPieChartCreator.java	(revision 566)
@@ -4,14 +4,12 @@
 import java.util.List;
 
 import org.txm.chartsengine.core.preferences.ChartsEnginePreferences;
-import org.txm.core.preferences.TXMPreferences;
-import org.txm.core.results.TXMResult;
 import org.txm.chartsengine.r.core.RChartCreator;
 import org.txm.chartsengine.r.core.RChartsEngine;
+import org.txm.core.results.TXMResult;
 import org.txm.partition.core.chartsengine.base.Utils;
 import org.txm.partition.core.functions.PartitionDimensions;
 import org.txm.partition.core.messages.PartitionCoreMessages;
-import org.txm.partition.core.preferences.PartitionDimensionsPreferences;
 import org.txm.searchengine.cqp.corpus.Part;
 import org.txm.utils.logger.Log;
 
@@ -31,8 +29,8 @@
 			PartitionDimensions partitionDimensions = (PartitionDimensions) result;
 
 			// parameters
-			boolean sortPartsBySize = result.getBooleanParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE);
-			boolean displayPartsCountInTitle = result.getBooleanParameterValue(PartitionDimensionsPreferences.DISPLAY_PARTS_COUNT_IN_TITLE);
+			boolean sortPartsBySize = partitionDimensions.isSortingBySize();
+			boolean displayPartsCountInTitle = partitionDimensions.isDisplayingPartCountInTitle();
 			
 			List<Part> parts = partitionDimensions.getParts(sortPartsBySize);
 			
Index: tmp/org.txm.partition.core/src/org/txm/partition/core/preferences/PartitionDimensionsPreferences.java
===================================================================
--- tmp/org.txm.partition.core/src/org/txm/partition/core/preferences/PartitionDimensionsPreferences.java	(revision 565)
+++ tmp/org.txm.partition.core/src/org/txm/partition/core/preferences/PartitionDimensionsPreferences.java	(revision 566)
@@ -19,14 +19,14 @@
 	
 	public static final String PREFERENCES_PREFIX = "partition_"; //$NON-NLS-1$
 	
-	public static final String DISPLAY_PARTS_COUNT_IN_TITLE = PREFERENCES_PREFIX + "chart_dimensions_display_parts_count_in_title"; //$NON-NLS-1$
-	public static final String SORTED_BY_SIZE = PREFERENCES_PREFIX + "chart_dimensions_sort_by_parts_size"; //$NON-NLS-1$
+	public static final String CHART_DIMENSIONS_DISPLAY_PARTS_COUNT_IN_TITLE = PREFERENCES_PREFIX + "chart_dimensions_display_parts_count_in_title"; //$NON-NLS-1$
+	public static final String CHART_DIMENSIONS_SORT_BY_SIZE = PREFERENCES_PREFIX + "chart_dimensions_sort_by_parts_size"; //$NON-NLS-1$
 	
 	@Override
 	public void initializeDefaultPreferences() {
 		Preferences preferences = DefaultScope.INSTANCE.getNode(PREFERENCES_NODE);
-		preferences.putBoolean(DISPLAY_PARTS_COUNT_IN_TITLE, true);
-		preferences.putBoolean(SORTED_BY_SIZE, false);
+		preferences.putBoolean(CHART_DIMENSIONS_DISPLAY_PARTS_COUNT_IN_TITLE, true);
+		preferences.putBoolean(CHART_DIMENSIONS_SORT_BY_SIZE, false);
 		
 		// shared charts rendering preferences
 		ChartsEnginePreferences.initializeChartsEngineSharedPreferences(preferences);
Index: tmp/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesSelectionEditor.java
===================================================================
--- tmp/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesSelectionEditor.java	(revision 565)
+++ tmp/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesSelectionEditor.java	(revision 566)
@@ -4,11 +4,12 @@
 import org.eclipse.swt.events.SelectionEvent;
 import org.eclipse.swt.events.SelectionListener;
 import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Spinner;
 import org.eclipse.swt.widgets.ToolItem;
 import org.txm.chartsengine.rcp.editors.ChartEditorPart;
-import org.txm.core.preferences.TXMPreferences;
 import org.txm.rcp.IImageKeys;
-import org.txm.specificities.core.preferences.SpecificitiesPreferences;
+import org.txm.specificities.core.functions.SpecificitiesSelection;
 import org.txm.specificities.rcp.handlers.ComputeSpecifities;
 import org.txm.specificities.rcp.messages.SpecificitiesUIMessages;
 
@@ -30,14 +31,12 @@
 		final ToolItem groupBarsByLines = new ToolItem(this.getToolBar(), SWT.CHECK);
 		groupBarsByLines.setToolTipText(SpecificitiesUIMessages.SpecificitiesPreferencePage_4);
 		groupBarsByLines.setImage(IImageKeys.getImage(ComputeSpecifities.class, "icons/silk_group_bars_by_lines.png"));
-		groupBarsByLines.setSelection(getResultData().getBooleanParameterValue(SpecificitiesPreferences.CHART_TRANSPOSE));
+		groupBarsByLines.setSelection(this.getResultData().isGroupingByLines());
 		groupBarsByLines.addSelectionListener(new SelectionListener() {
 			
 			@Override
 			public void widgetSelected(SelectionEvent e) {
-				getResultData().saveParameter(SpecificitiesPreferences.CHART_TRANSPOSE, groupBarsByLines.getSelection());
-				getResultData().setDirty();
-				getResultData().setNeedsToResetView(true);
+				getResultData().setGroupByLines(groupBarsByLines.getSelection());
 				compute(true);
 			}
 			
@@ -46,7 +45,44 @@
 				// does nothing
 			}
 		});
+
 		
+		
+		// Banality
+        Label label = new Label(this.getCommandParametersGroup(), SWT.NONE);
+        label.setText("Banality:");
+		
+		final Spinner banality = new Spinner(this.getCommandParametersGroup(), SWT.BORDER);
+		int nbDigits = 1;
+		banality.setToolTipText("Banality threshold");
+		banality.setDigits(nbDigits);
+		banality.setIncrement(1);
+		banality.setMinimum(0);
+		banality.setMaximum(200);
+		banality.setSelection(((int) (getResultData().getBanality() * Math.pow(10, nbDigits))));
+		banality.addSelectionListener(new SelectionListener() {
+			
+			@Override
+			public void widgetSelected(SelectionEvent e) {
+				getResultData().setBanality(getSpinnerFloatSelection(banality));
+				compute(true);
+			}
+			
+			@Override
+			public void widgetDefaultSelected(SelectionEvent e) {
+				// does nothing
+			}
+		});
+		
+		
+		
+		
+		
 	}
 	
+	
+	@Override
+	public SpecificitiesSelection getResultData() {
+		return (SpecificitiesSelection) super.getResultData();
+	}
 }
Index: tmp/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesEditor.java
===================================================================
--- tmp/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesEditor.java	(revision 565)
+++ tmp/org.txm.specificities.rcp/src/org/txm/specificities/rcp/editors/SpecificitiesEditor.java	(revision 566)
@@ -50,7 +50,6 @@
 import org.txm.rcp.editors.TXMEditorPart;
 import org.txm.rcp.editors.TableKeyListener;
 import org.txm.specificities.core.functions.Specificities;
-import org.txm.specificities.core.preferences.SpecificitiesPreferences;
 import org.txm.specificities.rcp.messages.SpecificitiesUIMessages;
 import org.txm.statsengine.core.StatException;
 import org.txm.utils.logger.Log;
@@ -59,13 +58,13 @@
  * Displays a table editor with specificities index.
  * 
  * @author mdecorde
- * @author sjaquot
+ * @author sjacquot
  * @author sloiseau 
  * 
  */
 public class SpecificitiesEditor extends TXMEditorPart {
 
-	public static String ID = SpecificitiesEditor.class.getName();
+	public final static String ID = SpecificitiesEditor.class.getName();
 
 	/** The specificities table. */
 	private Table specificitesTable;
@@ -77,12 +76,16 @@
 	/** Column for table typeFrequencyColumn. */
 	private TableColumn typeFrequencyColumn;
 
+	protected Spinner maxScore;
+	
 	/**
 	 * Viewer comparator for sorting.
 	 */
 	protected SpecificitiesLinesViewerComparator viewerComparator;
 	
 	
+	
+	
 	@Override
 	public void createPartControl(Composite parent) {
 		super.createPartControl(parent);
@@ -91,10 +94,10 @@
 		Composite parametersArea = this.getCommandParametersGroup();
 		new Label(parametersArea, SWT.NONE).setText("Maximum score");
 
-		final Spinner maxScore = new Spinner(parametersArea, SWT.BORDER);
-		maxScore.setToolTipText("The maximum score to show");
-		maxScore.setMinimum(0);
-		maxScore.setSelection(SpecificitiesPreferences.getInt(SpecificitiesPreferences.MAX_SCORE, SpecificitiesPreferences.PREFERENCES_NODE));
+		this.maxScore = new Spinner(parametersArea, SWT.BORDER);
+		this.maxScore.setToolTipText("The maximum score to show");
+		this.maxScore.setMinimum(0);
+		this.maxScore.setSelection(this.getResultData().getMaxScore());
 		try {
 			composeDisplayArea();
 			this.refresh(false);
@@ -391,7 +394,6 @@
 	@Override
 	public void updateEditorFromResult(boolean update) {
 		this.fillDisplay();
-		super.refresh(update);
 	}
 
 	
@@ -461,14 +463,13 @@
 	
 	@Override
 	public Specificities getResultData()	{
-		return (Specificities) this.getResultData();
+		return (Specificities) super.getResultData();
 	}
 
 
 	@Override
 	public void updateResultFromEditor() {
-		// TODO Auto-generated method stub
-		
+		this.getResultData().setMaxScore(this.maxScore.getSelection());
 	}
 
 
Index: tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/preferences/PartitionPreferencePage.java
===================================================================
--- tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/preferences/PartitionPreferencePage.java	(revision 565)
+++ tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/preferences/PartitionPreferencePage.java	(revision 566)
@@ -56,8 +56,8 @@
 		// Charts rendering
 		Composite chartsTab = SWTChartsComponentsProvider.createChartsRenderingPreferencesTabFolderComposite(this.getFieldEditorParent(), "Dimensions chart rendering");
 		
-		this.addField(new BooleanFieldEditor(PartitionDimensionsPreferences.SORTED_BY_SIZE, PartitionUIMessages.PreferencesPage_DIMENSIONS_SORT_BY_PARTS_SIZE, chartsTab));
-		this.addField(new BooleanFieldEditor(PartitionDimensionsPreferences.DISPLAY_PARTS_COUNT_IN_TITLE, PartitionUIMessages.PreferencesPage_DIMENSIONS_DISPLAY_PARTS_COUNT_IN_TITLE, chartsTab));
+		this.addField(new BooleanFieldEditor(PartitionDimensionsPreferences.CHART_DIMENSIONS_SORT_BY_SIZE, PartitionUIMessages.PreferencesPage_DIMENSIONS_SORT_BY_PARTS_SIZE, chartsTab));
+		this.addField(new BooleanFieldEditor(PartitionDimensionsPreferences.CHART_DIMENSIONS_DISPLAY_PARTS_COUNT_IN_TITLE, PartitionUIMessages.PreferencesPage_DIMENSIONS_DISPLAY_PARTS_COUNT_IN_TITLE, chartsTab));
 		
 		// other shared preferences
 		SWTChartsComponentsProvider.createChartsRenderingPreferencesFields(this, chartsTab);
Index: tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/editors/PartitionDimensionsEditor.java
===================================================================
--- tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/editors/PartitionDimensionsEditor.java	(revision 565)
+++ tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/editors/PartitionDimensionsEditor.java	(revision 566)
@@ -10,7 +10,6 @@
 import org.eclipse.swt.widgets.ToolItem;
 import org.txm.chartsengine.rcp.editors.ChartEditorPart;
 import org.txm.partition.core.functions.PartitionDimensions;
-import org.txm.partition.core.preferences.PartitionDimensionsPreferences;
 import org.txm.partition.rcp.messages.PartitionUIMessages;
 import org.txm.rcp.IImageKeys;
 
@@ -34,13 +33,13 @@
 		final ToolItem sortByPartSize = new ToolItem(this.getToolBar(), SWT.CHECK);
 		sortByPartSize.setImage(IImageKeys.getImage(this.getClass(), "icons/silk_sort_by_size.png"));
 		sortByPartSize.setToolTipText(PartitionUIMessages.PreferencesPage_DIMENSIONS_SORT_BY_PARTS_SIZE);
-		sortByPartSize.setSelection(this.getBooleanParameterValue(PartitionDimensionsPreferences.SORTED_BY_SIZE));
+		sortByPartSize.setSelection(this.getResultData().isSortingBySize());
 		
 		sortByPartSize.addSelectionListener(new SelectionListener() {
 			
 			@Override
 			public void widgetSelected(SelectionEvent e) {
-				((PartitionDimensions)getResultData()).setParameters(sortByPartSize.getSelection());
+				getResultData().setSortBySize(sortByPartSize.getSelection());
 				compute(true);
 			}
 			
@@ -50,6 +49,13 @@
 				
 			}
 		});
-		
 	}
+	
+	
+	@Override
+	public PartitionDimensions getResultData() {
+		// TODO Auto-generated method stub
+		return (PartitionDimensions) super.getResultData();
+	}
+	
 }
Index: tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/handlers/ComputePartitionDimensionsBarChart.java
===================================================================
--- tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/handlers/ComputePartitionDimensionsBarChart.java	(revision 565)
+++ tmp/org.txm.partition.rcp/src/org/txm/partition/rcp/handlers/ComputePartitionDimensionsBarChart.java	(revision 566)
@@ -31,6 +31,7 @@
 import org.eclipse.core.commands.ExecutionException;
 import org.txm.chartsengine.rcp.editors.ChartEditorPart;
 import org.txm.partition.core.functions.PartitionDimensions;
+import org.txm.rcp.editors.TXMEditorPart;
 import org.txm.rcp.handlers.BaseAbstractHandler;
 import org.txm.rcp.views.corpora.CorporaView;
 import org.txm.searchengine.cqp.corpus.Partition;
@@ -90,7 +91,7 @@
 		// FIXME: Pie chart tests
 //		partitionDimensions.setChartType("Partition Dimensions Pie Chart"); //$NON-NLS-1$
 		
-		ChartEditorPart.openEditor(partitionDimensions);
+		ChartEditorPart.openEditor(partitionDimensions, partitionDimensions.getClass().getName());
 
 		return null;
 	}
Index: tmp/org.txm.cooccurrence.rcp/src/org/txm/cooccurrence/rcp/handlers/ComputeCooccurrences.java
===================================================================
--- tmp/org.txm.cooccurrence.rcp/src/org/txm/cooccurrence/rcp/handlers/ComputeCooccurrences.java	(revision 565)
+++ tmp/org.txm.cooccurrence.rcp/src/org/txm/cooccurrence/rcp/handlers/ComputeCooccurrences.java	(revision 566)
@@ -79,8 +79,6 @@
 		}
 		
 		Object selection = this.getSelection(event);
-		TXMResultEditorInput editorInput = null;
-		
 		Cooccurrence cooc = null;
 		
 		if (selection instanceof Concordance) {
@@ -130,14 +128,12 @@
 			StatusLine.setMessage(RCPMessages.ComputeCooccurrences_0);
 
 			//System.out.println("DEBUG: opening cooc: "+cooc+" corpus="+cooc.getCorpus());
-			editorInput = new TXMResultEditorInput(cooc);
+			TXMEditorPart.openEditor(cooc, CooccurrencesEditor.ID);
 			
-			TXMEditorPart editor = TXMEditorPart.openEditor(editorInput, CooccurrencesEditor.ID);
-			
-			return editor;
+			return true;
 		} catch (Exception e) {
 			Log.printStackTrace(e);
-			return null;
+			return false;
 		}
 	}
 }
Index: tmp/org.txm.ca.rcp/src/org/txm/ca/rcp/handlers/ComputeCA.java
===================================================================
--- tmp/org.txm.ca.rcp/src/org/txm/ca/rcp/handlers/ComputeCA.java	(revision 565)
+++ tmp/org.txm.ca.rcp/src/org/txm/ca/rcp/handlers/ComputeCA.java	(revision 566)
@@ -149,7 +149,10 @@
 				return null;
 			}
 
-			ChartEditorPart.compute(ca);
+			// FIXME: old code
+			//ChartEditorPart.compute(ca);
+			// FIXME: new code
+			ca.compute(false);
 
 			try {
 
Index: tmp/org.txm.specificities.core/src/org/txm/specificities/core/functions/Specificities.java
===================================================================
--- tmp/org.txm.specificities.core/src/org/txm/specificities/core/functions/Specificities.java	(revision 565)
+++ tmp/org.txm.specificities.core/src/org/txm/specificities/core/functions/Specificities.java	(revision 566)
@@ -110,8 +110,11 @@
 	
 	
 	@Parameter
-	protected int pMaxScore;
+	protected int maxScore;
 	
+	
+	
+	
 	/**
 	 * Specificities.
 	 *
@@ -123,7 +126,7 @@
 	public Specificities(LexicalTable lexicalTable, int maxScore)	throws CqiClientException, StatException {
 		super(lexicalTable);
 		this.lexicalTable = lexicalTable;
-		this.pMaxScore = maxScore;
+		this.maxScore = maxScore;
 	}
 	
 	@Override
@@ -147,12 +150,12 @@
 //			System.out.println("cols="+table.getColNames());
 //			System.out.println("prop="+table.getProperty());
 			init(symbol, specIndex, lexicalTable, Arrays
-					.asList(lexicalTable.getRowNames().asStringsArray()), Arrays.asList(lexicalTable.getColNames().asStringsArray()), lexicalTable.getProperty().getName(), this.pMaxScore); 
+					.asList(lexicalTable.getRowNames().asStringsArray()), Arrays.asList(lexicalTable.getColNames().asStringsArray()), lexicalTable.getProperty().getName(), this.maxScore); 
 		}
 		else {
 			init(si.getSymbol(), specIndex, lexicalTable, Arrays
 					.asList(lexicalTable.getRowNames().asStringsArray()), Arrays.asList(lexicalTable.getColNames().asStringsArray()),
-					"TLNONAME: " + lexicalTable.getProperty().getName(), this.pMaxScore); //$NON-NLS-1$
+					"TLNONAME: " + lexicalTable.getProperty().getName(), this.maxScore); //$NON-NLS-1$
 		}
 		return true;
 	}
@@ -597,7 +600,7 @@
 	 * @param maxScore the pMaxScore to set
 	 */
 	public void setMaxScore(int maxScore) {
-		this.pMaxScore = maxScore;
+		this.maxScore = maxScore;
 	}
 
 	@Override
@@ -614,6 +617,13 @@
 		return true;
 	}
 
+	/**
+	 * @return the maxScore
+	 */
+	public int getMaxScore() {
+		return maxScore;
+	}
+
 	
 
 	
Index: tmp/org.txm.specificities.core/src/org/txm/specificities/core/functions/SpecificitiesSelection.java
===================================================================
--- tmp/org.txm.specificities.core/src/org/txm/specificities/core/functions/SpecificitiesSelection.java	(revision 565)
+++ tmp/org.txm.specificities.core/src/org/txm/specificities/core/functions/SpecificitiesSelection.java	(revision 566)
@@ -6,7 +6,9 @@
 import java.io.File;
 
 import org.txm.chartsengine.core.results.ChartResult;
+import org.txm.core.results.Parameter;
 import org.txm.core.results.TXMParameters;
+import org.txm.specificities.core.preferences.SpecificitiesPreferences;
 
 /**
  * A selection from a Specificities result dedicated to export or chart creation.
@@ -33,17 +35,40 @@
 
 
 	
+	@Parameter(type=Parameter.RENDERING)
+	protected boolean groupByLines;
 	
+	@Parameter(type=Parameter.RENDERING)
+	protected float banality;
+
+	@Parameter(type=Parameter.RENDERING)
+	protected boolean drawBars;
+
+	@Parameter(type=Parameter.RENDERING)
+	protected boolean drawLines;
+
 	/**
 	 * Creates an empty SpecificitiesSelection.
 	 * @param parent
 	 */
 	public SpecificitiesSelection(Specificities parent) {
 		super(parent);
+		this.loadParameters();
 	}
 
 	
+
+	@Override
+	public boolean loadParameters() {
+		this.groupByLines = this.getBooleanParameterValue(SpecificitiesPreferences.CHART_TRANSPOSE);
+		this.banality = this.getFloatParameterValue(SpecificitiesPreferences.CHART_BANALITY);
+		this.drawBars = this.getBooleanParameterValue(SpecificitiesPreferences.CHART_DRAW_BARS);
+		this.drawLines = this.getBooleanParameterValue(SpecificitiesPreferences.CHART_DRAW_LINES);
+		return true;
+	}
+
 	
+	
 	/**
 	 * @return the selectedTypeNames
 	 */
@@ -150,14 +175,7 @@
 		return true;
 	}
 
-	@Override
-	public boolean loadParameters() {
-		// TODO Auto-generated method stub
-		System.err.println("SpecificitiesSelection.loadParameters(): not yet implemented.");
-		return true;
-	}
 
-
 	
 	/* (non-Javadoc)
 	 * @see org.txm.core.results.TXMResult#toTxt(java.io.File, java.lang.String, java.lang.String, java.lang.String)
@@ -168,4 +186,58 @@
 		return false;
 	}
 
+
+
+	/**
+	 * @return the groupByLines
+	 */
+	public boolean isGroupingByLines() {
+		return groupByLines;
+	}
+
+
+
+	/**
+	 * @param groupByLines the groupByLines to set
+	 */
+	public void setGroupByLines(boolean groupByLines) {
+		this.groupByLines = groupByLines;
+	}
+
+
+
+	/**
+	 * @return the banality
+	 */
+	public float getBanality() {
+		return banality;
+	}
+
+
+
+	/**
+	 * @param banality the banality to set
+	 */
+	public void setBanality(float banality) {
+		this.banality = banality;
+	}
+
+
+
+	/**
+	 * @return the drawBars
+	 */
+	public boolean isDrawingBars() {
+		return drawBars;
+	}
+
+
+
+	/**
+	 * @return the drawLines
+	 */
+	public boolean isDrawingLines() {
+		return drawLines;
+	}
+
 }
Index: tmp/org.txm.specificities.core/src/org/txm/specificities/core/chartsengine/jfreechart/JFCSpecificitiesBarChartCreator.java
===================================================================
--- tmp/org.txm.specificities.core/src/org/txm/specificities/core/chartsengine/jfreechart/JFCSpecificitiesBarChartCreator.java	(revision 565)
+++ tmp/org.txm.specificities.core/src/org/txm/specificities/core/chartsengine/jfreechart/JFCSpecificitiesBarChartCreator.java	(revision 566)
@@ -35,9 +35,8 @@
 		SpecificitiesSelection specificitiesSelection = (SpecificitiesSelection) result;
 
 		// parameters
-		boolean drawBars = result.getBooleanParameterValue(SpecificitiesPreferences.CHART_DRAW_BARS);
-		boolean drawLines = result.getBooleanParameterValue(SpecificitiesPreferences.CHART_DRAW_LINES);
-		float banality = result.getFloatParameterValue(SpecificitiesPreferences.CHART_BANALITY);
+		boolean drawBars = specificitiesSelection.isDrawingBars();
+		boolean drawLines = specificitiesSelection.isDrawingLines();
 		
 		JFreeChart chart = null;
 
@@ -59,23 +58,7 @@
 
 
 
-        // Add positive banality marker
-        Marker marker = new ValueMarker(banality);
-        marker.setPaint(Color.RED);
-        marker.setLabel(SpecificitiesCoreMessages.bind(SpecificitiesCoreMessages.Charts_BANALITY_MARKER_LABEL, banality));
-        marker.setLabelAnchor(RectangleAnchor.TOP_RIGHT);
-        marker.setLabelTextAnchor(TextAnchor.BOTTOM_RIGHT);
-        chart.getXYPlot().addRangeMarker(marker);
 
-
-        // Add negative banality marker
-        marker = new ValueMarker(-banality);
-        marker.setPaint(Color.RED);
-        marker.setLabel(SpecificitiesCoreMessages.bind(SpecificitiesCoreMessages.Charts_BANALITY_MARKER_LABEL, -banality));
-        marker.setLabelAnchor(RectangleAnchor.TOP_RIGHT);
-        marker.setLabelTextAnchor(TextAnchor.BOTTOM_RIGHT);
-        chart.getXYPlot().addRangeMarker(marker);
-
 		return chart;
 		
 	}
@@ -86,6 +69,9 @@
 		SpecificitiesSelection specificitiesSelection = (SpecificitiesSelection) result;
 		JFreeChart jfcChart = (JFreeChart) chart;
 		
+		float banality = specificitiesSelection.getBanality();
+
+		
 		// freeze rendering
 		jfcChart.setNotify(false);
 
@@ -96,7 +82,7 @@
 		String[] xAxisSymbols;
 
 		// Transpose the data set
-		if(result.getBooleanParameterValue(SpecificitiesPreferences.CHART_TRANSPOSE))	{
+		if(specificitiesSelection.isGroupingByLines())	{
 	        xAxisSymbols = new String[specificitiesSelection.getSelectedTypeNames().length];
 
 			for(int i = 0; i < specificitiesSelection.getSelectedPartNames().length; i++) {
@@ -127,6 +113,28 @@
 			}
 		}
 		
+		// removes all existing range marker
+		jfcChart.getXYPlot().clearRangeMarkers();
+		
+        // Add positive banality marker
+        Marker marker = new ValueMarker(banality);
+        marker.setPaint(Color.RED);
+        marker.setLabel(SpecificitiesCoreMessages.bind(SpecificitiesCoreMessages.Charts_BANALITY_MARKER_LABEL, banality));
+        marker.setLabelAnchor(RectangleAnchor.TOP_RIGHT);
+        marker.setLabelTextAnchor(TextAnchor.BOTTOM_RIGHT);
+        jfcChart.getXYPlot().addRangeMarker(marker);
+
+
+        // Add negative banality marker
+        marker = new ValueMarker(-banality);
+        marker.setPaint(Color.RED);
+        marker.setLabel(SpecificitiesCoreMessages.bind(SpecificitiesCoreMessages.Charts_BANALITY_MARKER_LABEL, -banality));
+        marker.setLabelAnchor(RectangleAnchor.TOP_RIGHT);
+        marker.setLabelTextAnchor(TextAnchor.BOTTOM_RIGHT);
+        jfcChart.getXYPlot().addRangeMarker(marker);
+
+		
+		
         // Custom range axis for ticks drawing options
         double minimumValue = DatasetUtilities.findMinimumRangeValue(jfcChart.getXYPlot().getDataset()).doubleValue();
         double maximumValue = DatasetUtilities.findMaximumRangeValue(jfcChart.getXYPlot().getDataset()).doubleValue();
@@ -135,7 +143,7 @@
         	minimumValue = 0;
         }
         if(maximumValue < 0)	{
-        	maximumValue = result.getFloatParameterValue(SpecificitiesPreferences.CHART_BANALITY);
+        	maximumValue = specificitiesSelection.getBanality();
         }
         // Custom range axis to cut the values to minimum and maximum values
         jfcChart.getXYPlot().setRangeAxis(new ExtendedNumberAxis((NumberAxis) jfcChart.getXYPlot().getRangeAxis(), true, true, minimumValue, maximumValue));
Index: tmp/org.txm.specificities.core/src/org/txm/specificities/core/chartsengine/r/RSpecificitiesBarChartCreator.java
===================================================================
--- tmp/org.txm.specificities.core/src/org/txm/specificities/core/chartsengine/r/RSpecificitiesBarChartCreator.java	(revision 565)
+++ tmp/org.txm.specificities.core/src/org/txm/specificities/core/chartsengine/r/RSpecificitiesBarChartCreator.java	(revision 566)
@@ -7,7 +7,6 @@
 import org.txm.core.results.TXMResult;
 import org.txm.specificities.core.functions.SpecificitiesSelection;
 import org.txm.specificities.core.messages.SpecificitiesCoreMessages;
-import org.txm.specificities.core.preferences.SpecificitiesPreferences;
 import org.txm.statsengine.core.data.Matrix;
 import org.txm.statsengine.core.data.Vector;
 import org.txm.statsengine.r.core.RWorkspace;
@@ -32,10 +31,10 @@
 			SpecificitiesSelection specificitiesSelection = (SpecificitiesSelection) result;
 
 			// parameters
-			boolean transpose = result.getBooleanParameterValue(SpecificitiesPreferences.CHART_TRANSPOSE);
-			boolean drawBars = result.getBooleanParameterValue(SpecificitiesPreferences.CHART_DRAW_BARS);
-			boolean drawLines = result.getBooleanParameterValue(SpecificitiesPreferences.CHART_DRAW_LINES);
-			float banality = result.getFloatParameterValue(SpecificitiesPreferences.CHART_BANALITY);
+			boolean transpose = specificitiesSelection.isGroupingByLines();
+			boolean drawBars = specificitiesSelection.isDrawingBars();
+			boolean drawLines = specificitiesSelection.isDrawingLines();
+			float banality = specificitiesSelection.getBanality();
 			int renderingColorMode = result.getIntParameterValue(ChartsEnginePreferences.RENDERING_COLORS_MODE);
 			
 			//boolean grayscale = (renderingColorMode == ChartsEngine.RENDERING_GRAYSCALE_MODE);
Index: tmp/org.txm.core/src/java/org/txm/core/results/Parameter.java
===================================================================
--- tmp/org.txm.core/src/java/org/txm/core/results/Parameter.java	(revision 565)
+++ tmp/org.txm.core/src/java/org/txm/core/results/Parameter.java	(revision 566)
@@ -18,6 +18,11 @@
 @Target({FIELD,METHOD,PARAMETER})
 public @interface Parameter {
 	
+	public final int COMPUTING = 0, RENDERING = 1;  
+	
 	// FIXME: could be used to automate saveParameters(), loadParameters(), etc. for accessing the preferences node value of a key in TXMResult class
 	//public String preferenceName() default "";
+	
+	
+	public int type() default Parameter.COMPUTING;
 }
\ No newline at end of file
Index: tmp/org.txm.core/src/java/org/txm/core/results/TXMResult.java
===================================================================
--- tmp/org.txm.core/src/java/org/txm/core/results/TXMResult.java	(revision 565)
+++ tmp/org.txm.core/src/java/org/txm/core/results/TXMResult.java	(revision 566)
@@ -91,7 +91,7 @@
 	/**
 	 * To keep track of the parameters used for the last computing and to determine if the result is dirty. 
 	 */
-	protected HashMap<String, Object> lastComputeParameters = new HashMap<String, Object>();
+	protected HashMap<String, Object> lastComputingParameters = new HashMap<String, Object>();
 	
 	
 	/**
@@ -152,16 +152,16 @@
 	 * Updates the last parameters used for computing.
 	 * @throws Exception
 	 */
-	protected void updateLastComputeParameters() throws Exception {
+	protected void updateLastComputingParameters() throws Exception {
 		Field[] fields = this.getClass().getDeclaredFields();
 		for (Field f : fields) {
 			String name = f.getName();
-			Parameter annotations = f.getAnnotation(Parameter.class);
-			if (annotations == null){
+			Parameter parameter = f.getAnnotation(Parameter.class);
+			if (parameter == null || parameter.type() != Parameter.COMPUTING) {
 				continue;
 			}
 			f.setAccessible(true);
-			lastComputeParameters.put(name, f.get(this));
+			lastComputingParameters.put(name, f.get(this));
 		}
 	}
 	
@@ -184,12 +184,12 @@
 		Field[] fields = clazz.getDeclaredFields();
 		for (Field f : fields) {
 			String name = f.getName();
-			Parameter annotation = f.getAnnotation(Parameter.class);
-			if (annotation == null) {
+			Parameter parameter = f.getAnnotation(Parameter.class);
+			if (parameter == null || parameter.type() != Parameter.COMPUTING) {
 				continue;
 			}
 			f.setAccessible(true); // not to set accessible to test the field values
-			Object previousValue = lastComputeParameters.get(name);
+			Object previousValue = lastComputingParameters.get(name);
 			Object newValue = f.get(this);
 			updateDirty(previousValue, newValue);
 			if (dirty) {
@@ -919,7 +919,7 @@
 		if (!this.isDirtyFromHistory()) {
 
 			// FIXME: Debug
-			System.err.println("TXMResult.compute(): parameters have not changed since last computing, computing skipped.");
+			System.err.println("TXMResult.compute(): result parameters have not changed since last computing, computing skipped.");
 
 			return true;
 		}
@@ -942,10 +942,12 @@
 //		// TODO THIS IS FUCKING LAZY LINE CODES OH YEAH YOU MAD BRO
 		// TODO where do we put this parent compute ? :o
 		//		if (parent != null && !parent.getHasBeenComputedOnce()) { // parent must be computed at least one time
+		// SJ: other way, test the object itself
+		// 		if (parent != null && !this.getHasBeenComputedOnce()) { 
 		//			this.parent.compute(update, monitor);
 		//		}
-
 		
+		
 		if (!this._compute(update)) {
 
 			// FIXME: Debug
@@ -954,7 +956,7 @@
 			return false;
 		}
 
-		this.updateLastComputeParameters(); // store last used parameters
+		this.updateLastComputingParameters(); // store last used parameters
 
 		if (!this.saveParameters()) {
 			System.out.println("Warning: " + this.getName() + " parameters are not saved.");
Index: tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/SWTChartsComponentsProvider.java
===================================================================
--- tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/SWTChartsComponentsProvider.java	(revision 565)
+++ tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/SWTChartsComponentsProvider.java	(revision 566)
@@ -588,6 +588,8 @@
 	 * @return
 	 */
 	// FIXME: this method have some trouble when calling through a progress dialog
+	// FIXME: this method is not in use anymore since the editor opening is now down in TXMEditorPart so the code for ChartEngine downgrading is not 
+	// active anymore. Try to use again this code
 	public ChartEditorPart openEditor(ChartEditorInput chartEditorInput, String editorPartId)	{
 
 		ChartEditorPart openedChartEditorPart = null;
Index: tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/editors/ChartEditorPart.java
===================================================================
--- tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/editors/ChartEditorPart.java	(revision 565)
+++ tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/editors/ChartEditorPart.java	(revision 566)
@@ -26,8 +26,10 @@
 import org.txm.chartsengine.rcp.swt.AdvancedChartEditorToolBar;
 import org.txm.chartsengine.rcp.swt.ChartComposite;
 import org.txm.chartsengine.rcp.swt.ChartEditorToolBar;
+import org.txm.core.results.TXMResult;
 import org.txm.rcp.editors.TXMEditorPart;
 import org.txm.rcp.editors.TXMEditorToolBar;
+import org.txm.rcp.editors.TXMResultEditorInput;
 import org.txm.utils.logger.Log;
 
 /**
@@ -174,19 +176,29 @@
 	 * @param result
 	 * @return
 	 */
-	public static ChartEditorPart openEditor(ChartResult result) {
-		return openEditor(result, SWTChartsComponentsProvider.getCurrent());
+//	public static ChartEditorPart openEditor(ChartResult result) {
+//		return openEditor(result, SWTChartsComponentsProvider.getCurrent());
+//	}
+
+	public static void openEditor(ChartResult result) {
+		openEditor(result, result.getClass().getName());
 	}
+
 	
+	public static void openEditor(ChartResult result, String editorPartId)	{
+		compute(new ChartEditorInput(result), editorPartId, false, null);
+	}
+
+	
 	/**
 	 * 
 	 * @param result
 	 * @param chartsComponentsProvider
 	 * @return
 	 */
-	public static ChartEditorPart openEditor(ChartResult result, SWTChartsComponentsProvider chartsComponentsProvider) {
-		compute(result);
-		return chartsComponentsProvider.openEditor(result);
+	public static void openEditor(ChartResult result, SWTChartsComponentsProvider chartsComponentsProvider) {
+		compute(new ChartEditorInput(result), result.getClass().getName(), false, null);
+		//return chartsComponentsProvider.openEditor(result);
 	}
 
 	
Index: tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/swt/ChartComposite.java
===================================================================
--- tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/swt/ChartComposite.java	(revision 565)
+++ tmp/org.txm.chartsengine.rcp/src/org/txm/chartsengine/rcp/swt/ChartComposite.java	(revision 566)
@@ -4,13 +4,10 @@
 import java.util.ArrayList;
 import java.util.EventListener;
 
-import org.eclipse.jface.action.MenuManager;
 import org.eclipse.swt.SWT;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Menu;
 import org.eclipse.swt.widgets.MenuItem;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.menus.IMenuService;
 import org.txm.chartsengine.rcp.IChartComponent;
 import org.txm.chartsengine.rcp.editors.ChartEditorPart;
 import org.txm.chartsengine.rcp.events.EventCallBack;
Index: tmp/org.txm.chartsengine.core/src/org/txm/chartsengine/core/results/ChartResult.java
===================================================================
--- tmp/org.txm.chartsengine.core/src/org/txm/chartsengine/core/results/ChartResult.java	(revision 565)
+++ tmp/org.txm.chartsengine.core/src/org/txm/chartsengine/core/results/ChartResult.java	(revision 566)
@@ -3,10 +3,15 @@
  */
 package org.txm.chartsengine.core.results;
 
+import java.lang.reflect.Field;
+import java.util.HashMap;
+
 import org.eclipse.core.runtime.IProgressMonitor;
 import org.txm.chartsengine.core.ChartCreator;
 import org.txm.chartsengine.core.ChartsEngine;
+import org.txm.core.results.Parameter;
 import org.txm.core.results.TXMResult;
+import org.txm.utils.logger.Log;
 
 /**
  * Chart result.
@@ -30,12 +35,25 @@
 	 */
 	protected boolean chartDirty;
 	
+	/**
+	 * To keep track of the parameters used for the last computing and to determine if the chart result is dirty. 
+	 */
+	protected HashMap<String, Object> lastRenderingParameters = new HashMap<String, Object>();
+
 	
+	/**
+	 * If true, the view will be reset when the chart will be updated.
+	 */
 	protected boolean needsToResetView;
 	
+	/**
+	 * If true, the items selection will cleared when the chart will be updated.
+	 */
 	protected boolean needsToClearItemsSelection;
 	
 	
+	
+	
 	/**
 	 * 
 	 * @param parent
@@ -56,80 +74,39 @@
 	@Override
 	public boolean compute(boolean update, IProgressMonitor monitor) throws Exception {
 
-		this.monitor = monitor;
-
 		// FIXME: Debug
-		System.err.println("ChartResult.compute(): computing result of type " + this.getClass() + "...");
-
-		// TODO uncomment this
-		if (!this.isDirtyFromHistory()) {
-
-			// FIXME: Debug
-			System.err.println("ChartResult.compute(): result parameters have not changed computing skipped.");
-
-//			return true;
+//		System.err.println("ChartResult.compute(): computing result of type " + this.getClass() + "...");
+//
+		// compute the result if needed
+		if(super.compute(update, monitor))	{
+			// compute the chart
+			return renderChart(update);
 		}
-		
-		else if(!this.isDirty())	{
-			
-			// FIXME: Debug
-			System.err.println("ChartResult.compute(): result is not dirty, computing skipped.");
-
-//			return true;
-		}
 		else	{
-		
-			if (!canCompute()) {
-				// FIXME: Debug
-				System.err.println("ChartResult.compute(): missing or wrong parameters, computing aborted.");
-	
-				return false;
-			}
-			
-//			// TODO THIS IS FUCKING LAZY LINE CODES OH YEAH YOU MAD BRO
-			// TODO where do we put this parent compute ? :o
-			//		if (parent != null && !parent.getHasBeenComputedOnce()) { // parent must be computed at least one time
-			//			this.parent.compute(update, monitor);
-			//		}
-	
-			if (!_compute(update)) {
-				
-				// FIXME: Debug
-				System.err.println("ChartResult.compute(): computing failed.");
-				
-				return false;
-			}
-	
-			this.updateLastComputeParameters(); // store last used parameters
-			
-			if (!saveParameters()) {
-				System.out.println("ChartResult.compute(): saving parameters failed.");
-			}
-	
-			this.dirty = false; // the _compute was successful the result is no more dirty
-	
-			// FIXME: Debug
-			System.err.println("ChartResult.compute(): computing done.");
+			return false;
 		}
-
-		return computeChart(update);
-		
-		//return true;
 	}
 	
-	protected boolean computeChart(boolean update) throws Exception {
+	protected boolean renderChart(boolean update) throws Exception {
 
-		this.subTask("computing chart");
+		this.subTask("rendering chart");
 
 		// FIXME: Debug
-		System.err.println("ChartResult.computeChart(): computing chart of type " + this.getClass() + "...");
+		System.err.println("ChartResult.renderChart(): rendering chart of type " + this.getClass() + "...");
 
-		if(!this.chartDirty)	{
+		
+		if (!this.isChartDirtyFromHistory()) {
+
+			// FIXME: Debug
+			System.err.println("ChartResult.renderChart(): chart rendering parameters have not changed since last rendering, rendering skipped.");
+			return true;
+		}
+		else if(!this.chartDirty)	{
 			
 			// FIXME: Debug
-			System.err.println("ChartResult.computeChart(): chart is not dirty, computing aborted.");
+			System.err.println("ChartResult.renderChart(): chart is not dirty, rendering skipped.");
 
-			return false;
+			return true;
 		}
 
 		
@@ -138,18 +115,24 @@
 			
 			if(update)	{
 				// FIXME: debug
-				System.err.println("ChartResult.computeChart(): updating chart.");
+				System.err.println("ChartResult.renderChart(): updating chart.");
 				
 				chartCreator.updateChart(this.chart, this);
 			}
 			else	{
 				
 				// FIXME: debug
-				System.err.println("ChartResult.computeChart(): creating chart.");
+				System.err.println("ChartResult.renderChart(): creating chart.");
 				
 				this.chart =  chartCreator.createChart(this);				
 			}
 			
+			this.updateLastRenderingParameters();
+			
+			
+			this.needsToClearItemsSelection = false;
+			this.needsToResetView = false;
+			
 			this.chartDirty = false;
 			return true;
 			
@@ -157,6 +140,60 @@
 		return false;
 	}
 	
+	
+	/**
+	 * Updates the parameters used for last rendering.
+	 * @throws Exception
+	 */
+	protected void updateLastRenderingParameters() throws Exception {
+		Field[] fields = this.getClass().getDeclaredFields();
+		for (Field f : fields) {
+			String name = f.getName();
+			Parameter parameter = f.getAnnotation(Parameter.class);
+			if (parameter == null || parameter.type() != Parameter.RENDERING) {
+				continue;
+			}
+			f.setAccessible(true);
+			this.lastRenderingParameters.put(name, f.get(this));
+		}
+	}
+	
+	
+	public final boolean isChartDirtyFromHistory() throws Exception {
+		Class clazz = this.getClass();
+
+		Field[] fields = clazz.getDeclaredFields();
+		for (Field f : fields) {
+			String name = f.getName();
+			Parameter annotation = f.getAnnotation(Parameter.class);
+			if (annotation == null || annotation.type() != Parameter.RENDERING) {
+				continue;
+			}
+			f.setAccessible(true); // not to set accessible to test the field values
+			Object previousValue = this.lastRenderingParameters.get(name);
+			Object newValue = f.get(this);
+			this.updateChartDirty(previousValue, newValue);
+			if (this.chartDirty) {
+				return this.chartDirty; // no need to go further
+			}
+		}
+		return this.chartDirty;
+	}
+	
+	
+	/**
+	 * Updates the chart dirty state by comparing an old parameter with a new one.
+	 * 
+	 * @param previousValue may be null
+	 * @param newValue may be null
+	 */
+	protected void updateChartDirty(Object previousValue, Object newValue) {
+		if (previousValue == null || !previousValue.equals(newValue)) {
+			Log.info("Setting chart dirty to true: old = "+ previousValue + " / new = " + newValue);
+			this.chartDirty = true;
+		}
+	}
+	
 	@Override
 	public Object clone() {
 		ChartResult clone = null;
Index: tmp/org.txm.referencer.rcp/src/org/txm/rcp/editors/referencer/ReferencerEditor.java
===================================================================
--- tmp/org.txm.referencer.rcp/src/org/txm/rcp/editors/referencer/ReferencerEditor.java	(revision 565)
+++ tmp/org.txm.referencer.rcp/src/org/txm/rcp/editors/referencer/ReferencerEditor.java	(revision 566)
@@ -457,7 +457,6 @@
 		});
 		
 		initializeFields();
-		TXMEditorPart.compute(referencer, true, ReferencerEditor.this);
 	}
 	
 	/**
Index: tmp/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/Subcorpus.java
===================================================================
--- tmp/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/Subcorpus.java	(revision 565)
+++ tmp/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/Subcorpus.java	(revision 566)
@@ -144,33 +144,35 @@
 	 */
 	@Override
 	public int getSize() throws CqiClientException {
-		Log.finest(TXMCoreMessages.bind(TXMCoreMessages.SUBCORPUS_SIZE, new Object[]{this.name, "N/A"}));
-		long start = System.currentTimeMillis();
 		if (this.size == -1) {
+			Log.finest(TXMCoreMessages.bind(TXMCoreMessages.SUBCORPUS_SIZE, new Object[]{this.name, "N/A"}));
+			long start = System.currentTimeMillis();
+
 			try {
 				AbstractCqiClient cqiClient = CorpusManager.getCorpusManager().getCqiClient();
 				int nMatch = cqiClient.subCorpusSize(getQualifiedCqpId());
 				//System.out.println("n matchs: "+nMatch);
 				if (nMatch == 0) {
 					this.size = 0;
-				} else {
-					int[] match = cqiClient.dumpSubCorpus(getQualifiedCqpId(),
-							NetCqiClient.CQI_CONST_FIELD_MATCH, 0, nMatch - 1);
-					int[] matchend = cqiClient.dumpSubCorpus(getQualifiedCqpId(),
-							NetCqiClient.CQI_CONST_FIELD_MATCHEND, 0, nMatch - 1);
-					if (match.length != matchend.length)
+				}
+				else {
+					int[] match = cqiClient.dumpSubCorpus(getQualifiedCqpId(), NetCqiClient.CQI_CONST_FIELD_MATCH, 0, nMatch - 1);
+					int[] matchend = cqiClient.dumpSubCorpus(getQualifiedCqpId(), NetCqiClient.CQI_CONST_FIELD_MATCHEND, 0, nMatch - 1);
+					if (match.length != matchend.length) {
 						throw new UnexpectedAnswerException();
+					}
 					this.size = 0;
 					
-					for (int i = 0; i < match.length; i++)
+					for (int i = 0; i < match.length; i++) {
 						size += matchend[i] - match[i] + 1;
+					}
 				}
 			} catch (Exception e) {
 				throw new CqiClientException(e);
 			}
+			long end = System.currentTimeMillis();
+			Log.finest(NLS.bind(TXMCoreMessages.END_SUBCORPUS_SIZE, new Object[]{this.name, this.size, (end - start)})); //$NON-NLS-1$
 		}
-		long end = System.currentTimeMillis();
-		Log.finest(NLS.bind(TXMCoreMessages.END_SUBCORPUS_SIZE, new Object[]{this.name, this.size, (end - start)})); //$NON-NLS-1$
 		return this.size;
 	}
 
Index: tmp/org.txm.chartsengine.jfreechart.core/src/org/txm/chartsengine/jfreechart/core/themes/base/SymbolAxisBetweenTicks.java
===================================================================
--- tmp/org.txm.chartsengine.jfreechart.core/src/org/txm/chartsengine/jfreechart/core/themes/base/SymbolAxisBetweenTicks.java	(revision 565)
+++ tmp/org.txm.chartsengine.jfreechart.core/src/org/txm/chartsengine/jfreechart/core/themes/base/SymbolAxisBetweenTicks.java	(revision 566)
@@ -167,23 +167,19 @@
         double used = 0.0;
         if (isTickLabelsVisible()) {
             if (edge == RectangleEdge.LEFT) {
-                used += findMaximumTickLabelWidth(ticks, g2, plotArea,
-                        isVerticalTickLabels());
+                used += findMaximumTickLabelWidth(ticks, g2, plotArea, isVerticalTickLabels());
                 state.cursorLeft(used);
             }
             else if (edge == RectangleEdge.RIGHT) {
-                used = findMaximumTickLabelWidth(ticks, g2, plotArea,
-                        isVerticalTickLabels());
+                used = findMaximumTickLabelWidth(ticks, g2, plotArea, isVerticalTickLabels());
                 state.cursorRight(used);
             }
             else if (edge == RectangleEdge.TOP) {
-                used = findMaximumTickLabelHeight(ticks, g2, plotArea,
-                        isVerticalTickLabels());
+                used = findMaximumTickLabelHeight(ticks, g2, plotArea, isVerticalTickLabels());
                 state.cursorUp(used);
             }
             else if (edge == RectangleEdge.BOTTOM) {
-                used = findMaximumTickLabelHeight(ticks, g2, plotArea,
-                        isVerticalTickLabels());
+                used = findMaximumTickLabelHeight(ticks, g2, plotArea, isVerticalTickLabels());
                 state.cursorDown(used);
             }
         }
@@ -195,8 +191,7 @@
 	
 
     @Override
-    protected List refreshTicksHorizontal(Graphics2D g2, Rectangle2D dataArea,
-            RectangleEdge edge) {
+    protected List refreshTicksHorizontal(Graphics2D g2, Rectangle2D dataArea, RectangleEdge edge) {
 
         List ticks = new java.util.ArrayList();
 
Index: tmp/org.txm.rcp/src/main/java/org/txm/rcp/editors/TXMEditorPart.java
===================================================================
--- tmp/org.txm.rcp/src/main/java/org/txm/rcp/editors/TXMEditorPart.java	(revision 565)
+++ tmp/org.txm.rcp/src/main/java/org/txm/rcp/editors/TXMEditorPart.java	(revision 566)
@@ -17,6 +17,7 @@
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Display;
 import org.eclipse.swt.widgets.Menu;
+import org.eclipse.swt.widgets.Spinner;
 import org.eclipse.swt.widgets.TableColumn;
 import org.eclipse.ui.IEditorInput;
 import org.eclipse.ui.IEditorPart;
@@ -310,12 +311,36 @@
 		return this.getEditorInput().getResult().getStringParameterValue(key);
 	}
 
+	
+	/**
+	 * Computes the result stored in the specified editor input and opens an editor specified by its id.
+	 * @param editorInput
+	 * @param editorPartId
+	 * @return
+	 */
+	public static void openEditor(TXMResultEditorInput editorInput, String editorPartId)	{
+		compute(editorInput, editorPartId, false, null);
+	}
+	
+	/**
+	 * Computes specified result stored, creates an editor input and opens an editor specified by its id.
+	 * @param result
+	 * @param editorPartId
+	 * @return
+	 */
+	public static void openEditor(TXMResult result, String editorPartId)	{
+		openEditor(new TXMResultEditorInput(result), editorPartId);
+	}
+	
+
+	
 	public final void compute(boolean update) {
-		compute(this.getResultData(), update, this);
+		compute(update, this);
 	}
 	
-	public static void compute(final TXMResult result)	{
-		compute(result, false, null);
+	
+	public static void compute(final boolean update, final TXMEditorPart editor)	{
+		compute(editor.getEditorInput(), null, update, editor);
 	}
 	
 	/**
@@ -327,12 +352,14 @@
 	 * @param resetView
 	 * @param clearChartItemsSelection
 	 */
-	public static void compute(final TXMResult result, final boolean update, final TXMEditorPart editor)	{
+	public static void compute(final TXMResultEditorInput editorInput, final String editorId, final boolean update, final TXMEditorPart editor)	{
 		
-		StatusLine.setMessage("Computing " + result.getName());
+		StatusLine.setMessage("Computing " + editorInput.getResult().getName());
 		
 		JobHandler job = new JobHandler("Computing result") {
 
+			TXMEditorPart currentEditor = null;
+			
 		    @Override
 		    protected IStatus run(IProgressMonitor monitor) {
 
@@ -340,38 +367,54 @@
 		    	
 		    	try {
 		    		JobsTimer.start();
+
 		    		
+		    		currentEditor = editor;
+		    		
 		    		// transfer editor parameters to result
-//		    		if (editor != null)	{
-//		    			editor.updateResultFromEditor();
+//		    		if (currentEditor != null)	{
+//		    			currentEditor.updateResultFromEditor();
 //		    		}
 		    		
 		    		
 		    		// computing result
 					monitor.beginTask("Computing", 100);
 
-					// FIXME: to restore when implemented
-//					if(!update)	{
-//						result.loadParameters();
-//					}
-					
-					if (!result.compute(update, monitor))	{
-						return Status.CANCEL_STATUS;
-					}
+					editorInput.getResult().compute(update, monitor);
 
-					monitor.worked(50);
-					
-					// cancel
-//					if(monitor.isCanceled())	{
+//					if (!editorInput.getResult().compute(update, monitor))	{
 //						return Status.CANCEL_STATUS;
 //					}
 
+					monitor.worked(50);
+					
+					// opening an editor if not exists
+					if (currentEditor == null)	{
+						this.syncExec(new Runnable() {
+							@Override
+							public void run() {
+								try {
+									
+									Log.info("TXMEditorPart.compute(): opening editor with id " + editorId);
+									
+									IWorkbenchWindow window =TXMWindows.getActiveWindow();
+									IWorkbenchPage page = window.getActivePage();
+									currentEditor = (TXMEditorPart) page.openEditor(editorInput, editorId, true, IWorkbenchPage.MATCH_INPUT | IWorkbenchPage.MATCH_ID);
+								} catch (Exception e) {
+									System.err.println("TXMEditorPart.compute(): could not open editor: " + e.getLocalizedMessage());
+									org.txm.rcp.utils.Logger.printStackTrace(e);
+								}
+							}
+						});
+					}
+					
+					
 					// refreshing the UI
-					if (editor != null)	{
+					if (currentEditor != null)	{
 						this.syncExec(new Runnable() {
 							@Override
 							public void run() {
-								editor.refresh(update);
+								currentEditor.refresh(update);
 							}
 						});
 					}
@@ -396,13 +439,6 @@
 		job.setPriority(Job.DECORATE);
 		job.setUser(false);
 		job.schedule();
-//		try {
-//			job.join();
-//		}
-//		catch (InterruptedException e) {
-//			// TODO Auto-generated catch block
-//			e.printStackTrace();
-//		}
 	}
 
 // FIXME: old code	
@@ -496,13 +532,13 @@
 	
 	/**
 	 * Synchronizes the result with editor parameters.
-	 * This should be called or called itself in the UI thread when accessing Widget parameters.
+	 * It should be called or called itself in the UI thread when accessing Widget parameters.
 	 */
 	public abstract void updateResultFromEditor();
 	
 	/**
 	 * Synchronizes the editor with the result. 
-	 * Dedicated to dynamically change the editor informations (as the part name) from the stored result.
+	 * Dedicated to dynamically change the editor components from the stored result.
 	 */
 	public abstract void updateEditorFromResult(boolean update);
 	
@@ -578,63 +614,6 @@
 		menuManager.update(true);
 		return menu;
 	}
-	
-	/**
-	 * Computes the result stored in the specified editor input and opens an editor specified by its id.
-	 * @param editorInput
-	 * @param editorPartId
-	 * @param activate
-	 * @param matchFlags
-	 * @return
-	 */
-	public static TXMEditorPart openEditor(final TXMResultEditorInput editorInput, String editorPartId, boolean activate, int matchFlags)	{
-		
-//		Display.getDefault().syncExec(new Runnable() {
-//			
-//			@Override
-//			public void run() {
-				// TODO Auto-generated method stub
-				compute(editorInput.getResult());		
-//			}
-//		});
-		
-		
-		
-		TXMEditorPart editor = null;
-		try {
-			
-			Log.info("TXMEditorPart.openEditor(): opening editor with id " + editorPartId);
-			
-			IWorkbenchWindow window =TXMWindows.getActiveWindow();
-			IWorkbenchPage page = window.getActivePage();
-			editor = (TXMEditorPart) page.openEditor(editorInput, editorPartId, activate, matchFlags);
-		} catch (Exception e) {
-			System.err.println("TXMEditorPart.openEditor(): could not open editor: " + e.getLocalizedMessage());
-			org.txm.rcp.utils.Logger.printStackTrace(e);
-		}
-		return editor;
-	}
-	
-	/**
-	 * Computes the result stored in the specified editor input and opens an editor specified by its id.
-	 * @param editorInput
-	 * @param editorPartId
-	 * @return
-	 */
-	public static TXMEditorPart openEditor(TXMResultEditorInput editorInput, String editorPartId)	{
-		return openEditor(editorInput, editorPartId, true, IWorkbenchPage.MATCH_INPUT | IWorkbenchPage.MATCH_ID);
-	}
-	
-	/**
-	 * Computes specified result stored, creates an editor input and opens an editor specified by its id.
-	 * @param result
-	 * @param editorPartId
-	 * @return
-	 */
-	public static TXMEditorPart openEditor(TXMResult result, String editorPartId)	{
-		return openEditor(new TXMResultEditorInput(result), editorPartId);
-	}
-	
 
 	/**
 	 * Gets the parameters composite.
@@ -658,6 +637,18 @@
 		viewer.getControl().setRedraw(true);
 	}
 
+	/**
+	 * Returns the spinner value as float.
+	 * @param spinner
+	 * @return
+	 */
+	public static float getSpinnerFloatSelection(Spinner spinner)	{
+		return (float) (spinner.getSelection() / Math.pow(10, spinner.getDigits()));
+	}
+
+
+
+	
 	public Composite getToolBarContainer(String toolbarLocalId) {
 		if ("top".equals(toolbarLocalId)) {
 			return this.getTopToolBarContainer();
