Index: tmp/org.txm.analec.rcp/src/org/txm/annotation/urs/toolbar/UnitConcordanceToolbar.java
===================================================================
--- tmp/org.txm.analec.rcp/src/org/txm/annotation/urs/toolbar/UnitConcordanceToolbar.java	(revision 3094)
+++ tmp/org.txm.analec.rcp/src/org/txm/annotation/urs/toolbar/UnitConcordanceToolbar.java	(revision 3095)
@@ -1,14 +1,20 @@
 package org.txm.annotation.urs.toolbar;
 
+import java.text.Collator;
 import java.util.ArrayList;
+import java.util.Arrays;
 import java.util.HashMap;
 import java.util.List;
+import java.util.Locale;
 import java.util.Vector;
 
 import org.eclipse.core.runtime.IProgressMonitor;
 import org.eclipse.core.runtime.IStatus;
 import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.bindings.keys.KeyStroke;
 import org.eclipse.jface.dialogs.InputDialog;
+import org.eclipse.jface.fieldassist.ComboContentAdapter;
+import org.eclipse.jface.fieldassist.TXMAutoCompleteField;
 import org.eclipse.jface.viewers.ArrayContentProvider;
 import org.eclipse.jface.viewers.ColumnLabelProvider;
 import org.eclipse.jface.viewers.ComboViewer;
@@ -30,6 +36,7 @@
 import org.eclipse.swt.graphics.FontData;
 import org.eclipse.swt.layout.GridData;
 import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Combo;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Display;
 import org.eclipse.swt.widgets.Label;
@@ -54,6 +61,7 @@
 
 import visuAnalec.donnees.Corpus;
 import visuAnalec.elements.Unite;
+import visuAnalec.vue.Vue;
 
 public class UnitConcordanceToolbar extends AnnotationArea {
 	
@@ -83,7 +91,7 @@
 	
 	protected Label equalLabel;
 	
-	protected Text annotationValuesText;
+	protected Combo annotationValuesText;
 	
 	protected Button affectAnnotationButton;
 	
@@ -113,6 +121,8 @@
 	
 	private ComboViewer annotationPropertiesCombo;
 	
+	private Vue vue;
+	
 	@Override
 	public String getName() {
 		return "Unit (URS)";
@@ -134,6 +144,7 @@
 		this.corpus = concordance.getCorpus();
 		this.annotations = new HashMap<>();
 		this.annotManager = URSCorpora.getCorpus(corpus);
+		this.vue = URSCorpora.getVue(corpus);
 		
 		TableViewer viewer = this.editor.getLineTableViewer();
 		
@@ -142,6 +153,11 @@
 			position = 3 + extension.getNumberOfAnnotationArea(); // after keyword column and previous annotation columns
 		}
 		
+		if (annotManager.getStructure().isVide()) {
+			annotManager.ajouterType(Unite.class, "Entity");
+			annotManager.ajouterProp(Unite.class, "Entity", "Property");
+		}
+		
 		typesList.clear();
 		
 		for (String type : this.annotManager.getStructure().getUnites()) {
@@ -168,39 +184,55 @@
 			public String getText(Object element) {
 				Line line = (Line) element;
 				ArrayList<Unite> a = annotations.get(line);
-				if (a.size() == 0) return "<none>";
+				if (a == null || a.size() == 0) return "<none>";
 				
 				StringBuffer buffer = new StringBuffer();
 				for (Unite unite : a) {
-					String value = unite.getProp(unitProperty);
-					
-					if (value != null) {
-						if (unite.getDeb() < line.matchGetStart() - line.getLeftContextSize()) {
-							value = "… " + value; //$NON-NLS-1$
-						}
+					if (unitProperty.length() > 0) {
+						String value = unite.getProp(unitProperty);
 						
-						if (unite.getFin() > line.matchGetEnd() + line.getRightContextSize()) {
-							value = value + " …"; //$NON-NLS-1$
+						if (value != null) {
+							if (unite.getDeb() < line.matchGetStart() - line.getLeftContextSize()) {
+								value = "… " + value; //$NON-NLS-1$
+							}
+							
+							if (unite.getFin() > line.matchGetEnd() + line.getRightContextSize()) {
+								value = value + " …"; //$NON-NLS-1$
+							}
+							if (buffer.length() > 0) buffer.append(", ");
+							buffer.append(value);
 						}
-						if (buffer.length() > 0) buffer.append(", ");
-						buffer.append(value);
 					}
 					else {
-						buffer.append("[]");
+						buffer.append(unite.getProps().toString());
 					}
 				}
 				return buffer.toString();
 			}
 		});
 		
-		if (unitType != null) {
-			annotationColumn.setText(unitType);
-		}
-		
 		annotationArea = new GLComposite(parent, SWT.NONE, "Unit URS");
 		annotationArea.getLayout().numColumns = 12;
+		annotationArea.getLayout().horizontalSpacing = 1;
 		annotationArea.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
 		
+		
+		Button closeButton = new Button(annotationArea, SWT.PUSH);
+		closeButton.setToolTipText("End URS annotation");
+		closeButton.setImage(IImageKeys.getImage(IImageKeys.ACTION_DELETE));
+		
+		closeButton.addSelectionListener(new SelectionListener() {
+			
+			@Override
+			public void widgetSelected(SelectionEvent e) {
+				extension.closeArea(UnitConcordanceToolbar.this, true);
+			}
+			
+			@Override
+			public void widgetDefaultSelected(SelectionEvent e) {}
+		});
+		
+		
 		GridData gdata = new GridData(SWT.CENTER, SWT.CENTER, false, false);
 		gdata.widthHint = 90;
 		
@@ -278,7 +310,7 @@
 		
 		annotationPropertiesCombo.getCombo().setLayoutData(gdata);
 		ArrayList<String> properties = new ArrayList<>();
-		properties.add("");
+		properties.add(""); // to manage the unit itself
 		properties.addAll(annotManager.getStructure().getNomsProps(Unite.class, unitType));
 		annotationPropertiesCombo.setInput(properties);
 		annotationPropertiesCombo.getCombo().select(0);
@@ -295,8 +327,8 @@
 		equalLabel.setText("="); //$NON-NLS-1$
 		equalLabel.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false));
 		
-		annotationValuesText = new Text(annotationArea, SWT.BORDER);
-		annotationValuesText.setToolTipText("value");
+		annotationValuesText = new Combo(annotationArea, SWT.BORDER);
+		annotationValuesText.setToolTipText("available values");
 		GridData gdata2 = new GridData(SWT.FILL, SWT.CENTER, false, false);
 		gdata2.widthHint = 200;
 		annotationValuesText.setLayoutData(gdata2);
@@ -313,8 +345,9 @@
 			public void keyPressed(KeyEvent e) {}
 		});
 		
+		
 		affectAnnotationButton = new Button(annotationArea, SWT.PUSH);
-		affectAnnotationButton.setText("Create");
+		affectAnnotationButton.setText("OK");
 		affectAnnotationButton.setToolTipText("Create unit for each selected line.");
 		affectAnnotationButton.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false));
 		affectAnnotationButton.addSelectionListener(new SelectionListener() {
@@ -343,57 +376,43 @@
 			public void widgetDefaultSelected(SelectionEvent e) {}
 		});
 		
-		affectAllAnnotationButton = new Button(annotationArea, SWT.PUSH);
-		affectAllAnnotationButton.setText("All");
-		affectAllAnnotationButton.setToolTipText("Create unit for all lines");
-		affectAllAnnotationButton.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false));
-		affectAllAnnotationButton.addSelectionListener(new SelectionListener() {
-			
-			@Override
-			public void widgetSelected(SelectionEvent e) {
-				
-				try {
-					List<? extends Match> matches = concordance.getMatches();
-					affectMatchesToSelection(matches);
-				}
-				catch (Exception e1) {
-					Log.severe(NLS.bind("** Error: {0}", e1.getLocalizedMessage()));
-					Log.printStackTrace(e1);
-					return;
-				}
-			}
-			
-			@Override
-			public void widgetDefaultSelected(SelectionEvent e) {}
-		});
+		// affectAllAnnotationButton = new Button(annotationArea, SWT.PUSH);
+		// affectAllAnnotationButton.setText("All");
+		// affectAllAnnotationButton.setToolTipText("Create unit for all lines");
+		// affectAllAnnotationButton.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false));
+		// affectAllAnnotationButton.addSelectionListener(new SelectionListener() {
+		//
+		// @Override
+		// public void widgetSelected(SelectionEvent e) {
+		//
+		// try {
+		// // List<? extends Match> matches = concordance.getMatches();
+		// affectMatchesToLines(concordance.getLines());
+		// }
+		// catch (Exception e1) {
+		// Log.severe(NLS.bind("** Error: {0}", e1.getLocalizedMessage()));
+		// Log.printStackTrace(e1);
+		// return;
+		// }
+		// }
+		//
+		// @Override
+		// public void widgetDefaultSelected(SelectionEvent e) {}
+		// });
 		
-		Button closeButton = new Button(annotationArea, SWT.PUSH);
-		closeButton.setToolTipText("End URS annotation");
-		closeButton.setImage(IImageKeys.getImage(IImageKeys.ACTION_REMOVE));
 		
-		closeButton.addSelectionListener(new SelectionListener() {
-			
-			@Override
-			public void widgetSelected(SelectionEvent e) {
-				extension.closeArea(UnitConcordanceToolbar.this, true);
-			}
-			
-			@Override
-			public void widgetDefaultSelected(SelectionEvent e) {}
-		});
+		onAnnotationTypeSelected(null);
 		
-		updateAnnotationWidgetStates();
 		editor.layout(true);
 		ext.getSaveButton().setEnabled(true);
 		return true;
 	}
 	
 	private void updateAnnotationWidgetStates() {
-		// TODO Auto-generated method stub
-		
+		annotationValuesText.setEnabled(unitProperty.length() > 0);
 	}
 	
-	protected void affectMatchesToSelection(final List<? extends Match> matches) {
+	protected void affectMatchesToLines(final List<Line> lines) {
 		
 		final String value = annotationValuesText.getText();
 		
@@ -403,12 +422,41 @@
 			protected IStatus run(IProgressMonitor monitor) {
 				this.runInit(monitor);
 				try {
-					for (Match m : matches) {
-						HashMap<String, String> props = new HashMap<>();
-						props.put(unitProperty, value);
-						Unite u = annotManager.addUniteSaisie(unitType, m.getStart(), m.getEnd(), props);
+					if (lines.size() == 0) return Status.CANCEL_STATUS;
+					
+					for (Line l : lines) {
+						
+						Match m = l.getMatch();
+						if (annotations.containsKey(l)) { // update existing unites
+							
+							if (unitProperty.length() > 0) {
+								ArrayList<Unite> unites = annotations.get(l);
+								for (Unite u : unites) {
+									u.getProps().put(unitProperty, value);
+								}
+							}
+						}
+						else {
+							ArrayList<Unite> lineUnites = new ArrayList<>();
+							annotations.put(l, lineUnites);
+							
+							HashMap<String, String> props = new HashMap<>();
+							if (unitProperty.length() > 0) {
+								props.put(unitProperty, value);
+							}
+							
+							lineUnites.add(annotManager.addUniteSaisie(unitType, m.getStart(), m.getEnd(), props));
+						}
 					}
 					
+					editor.getLineTableViewer().getTable().getDisplay().syncExec(new Runnable() {
+						
+						@Override
+						public void run() {
+							editor.getLineTableViewer().refresh();
+						}
+					});
+					
 				}
 				catch (Exception e) {
 					Log.severe(NLS.bind("** Error: {0}", e));
@@ -429,22 +477,41 @@
 	protected void deleteAnnotationValues(ISelection selection) {
 		final IStructuredSelection lineSelection = (IStructuredSelection) selection;
 		List<Line> lines = lineSelection.toList();
-		ArrayList<Match> matches = new ArrayList<>();
-		for (Line l : lines) {
-			matches.add(l.getMatch());
+		if (lines.size() == 0) return;
+		
+		if (unitProperty.length() > 0) {
+			for (Line l : lines) {
+				if (!annotations.containsKey(l)) continue;
+				
+				for (Unite u : annotations.get(l)) {
+					u.getProps().remove(unitProperty);
+				}
+			}
 		}
+		else { // remove the units
+			for (Line l : lines) {
+				if (!annotations.containsKey(l)) continue;
+				for (Unite u : annotations.get(l)) {
+					annotManager.supUnite(u);
+				}
+				
+				annotations.remove(l);
+			}
+		}
+		
+		editor.getLineTableViewer().refresh();
 	}
 	
 	protected void affectAnnotationToSelection(ISelection selection) {
 		
 		final IStructuredSelection lineSelection = (IStructuredSelection) selection;
 		List<Line> lines = lineSelection.toList();
-		ArrayList<Match> matches = new ArrayList<>();
-		for (Line l : lines) {
-			matches.add(l.getMatch());
-		}
+		// ArrayList<Match> matches = new ArrayList<>();
+		// for (Line l : lines) {
+		// matches.add(l.getMatch());
+		// }
 		
-		affectMatchesToSelection(matches);
+		affectMatchesToLines(lines);
 	}
 	
 	protected void onAnnotationPropertySelected(SelectionChangedEvent event) {
@@ -455,6 +522,15 @@
 		
 		unitProperty = type;
 		
+		if (unitProperty.length() > 0) {
+			annotationColumn.setText(unitType + "@" + unitProperty);
+		}
+		else {
+			annotationColumn.setText(unitType);
+		}
+		
+		setAvailableValues();
+		
 		try {
 			editor.refresh(false);
 		}
@@ -466,6 +542,19 @@
 		updateAnnotationWidgetStates();
 	}
 	
+	private void setAvailableValues() {
+		if (unitType.length() == 0) {
+			annotationValuesText.setItems(new String[0]);
+		}
+		else {
+			String[] items = vue.getValeursChamp(Unite.class, unitType, unitProperty);
+			Arrays.sort(items, Collator.getInstance(Locale.getDefault()));
+			annotationValuesText.setItems(items);
+			KeyStroke keys = KeyStroke.getInstance(SWT.CONTROL, SWT.SPACE);
+			new TXMAutoCompleteField(annotationValuesText, new ComboContentAdapter(), items, keys);
+		}
+	}
+	
 	protected void onAnnotationTypeSelected(SelectionChangedEvent event) {
 		IStructuredSelection sel = (IStructuredSelection) annotationTypesCombo.getSelection();
 		String type = (String) sel.getFirstElement();
@@ -475,20 +564,12 @@
 		annotationColumn.setText(type);
 		
 		ArrayList<String> properties = new ArrayList<>();
-		properties.add("");
+		properties.add(""); // to mange the unit itself
 		properties.addAll(annotManager.getStructure().getNomsProps(Unite.class, unitType));
 		annotationPropertiesCombo.setInput(properties);
 		annotationPropertiesCombo.getCombo().select(0);
 		
-		try {
-			editor.refresh(false);
-		}
-		catch (Exception e) {
-			// TODO Auto-generated catch block
-			e.printStackTrace();
-		}
-		
-		updateAnnotationWidgetStates();
+		onAnnotationPropertySelected(event);
 	}
 	
 	protected void createNewType(TypedEvent e, String typeName) {
@@ -562,7 +643,7 @@
 		// }
 		for (Line line : lines) {
 			ArrayList<Unite> lineUnites = new ArrayList<>();
-			annotations.put(line, lineUnites); // ok test next one
+			
 			for (int iUnit = 0; iUnit < units.size(); iUnit++) {
 				
 				Unite unite = units.get(iUnit);
@@ -576,6 +657,9 @@
 					lineUnites.add(unite);
 				}
 			}
+			if (lineUnites.size() > 0) {
+				annotations.put(line, lineUnites);
+			}
 		}
 		
 		updateAnnotationWidgetStates();
@@ -629,7 +713,7 @@
 	
 	@Override
 	public boolean needToUpdateIndexes() {
-		return true;
+		return false;
 	}
 	
 	@Override
Index: tmp/org.txm.analec.rcp/plugin.xml
===================================================================
--- tmp/org.txm.analec.rcp/plugin.xml	(revision 3094)
+++ tmp/org.txm.analec.rcp/plugin.xml	(revision 3095)
@@ -431,6 +431,10 @@
             class="org.txm.annotation.urs.toolbar.SchemaToolbar"
             position="2">
       </annotationtoolbar>
+      <annotationtoolbar
+            class="org.txm.annotation.urs.toolbar.UnitConcordanceToolbar"
+            position="4">
+      </annotationtoolbar>
    </extension>
    <extension
          point="org.txm.PostTXMHOMEInstallationStep">
