Index: trunk/org.txm.texts.core/src/org/txm/texts/core/TextsSelection.java
===================================================================
--- trunk/org.txm.texts.core/src/org/txm/texts/core/TextsSelection.java	(revision 0)
+++ trunk/org.txm.texts.core/src/org/txm/texts/core/TextsSelection.java	(revision 3477)
@@ -0,0 +1,22 @@
+package org.txm.texts.core;
+
+import org.txm.searchengine.cqp.corpus.CQPCorpus;
+import org.txm.searchengine.cqp.corpus.Subcorpus;
+
+public class TextsSelection extends Subcorpus {
+
+	public TextsSelection(CQPCorpus corpus) {
+		
+		super(corpus);
+	}
+	
+	/**
+	 * 
+	 * @param parametersNodePath
+	 */
+	public TextsSelection(String parametersNodePath) {
+		super(parametersNodePath);
+	}
+	
+	
+}

Property changes on: trunk/org.txm.texts.core/src/org/txm/texts/core/TextsSelection.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: TXM/trunk/org.txm.groovy.core/src/groovy/org/txm/macro/transcription/Vocapia2Transcriber.groovy
===================================================================
--- TXM/trunk/org.txm.groovy.core/src/groovy/org/txm/macro/transcription/Vocapia2Transcriber.groovy	(revision 3476)
+++ TXM/trunk/org.txm.groovy.core/src/groovy/org/txm/macro/transcription/Vocapia2Transcriber.groovy	(revision 3477)
@@ -81,9 +81,11 @@
 								break;
 							case "Speaker": // <Speaker ch="1" dur="531.38" gender="X" spkid="Enquêtrice" lang="fre" lconf="1.00" nw="1586" tconf="0.95"/> -> <Speaker id="spk1" name="enq4" check="no" dialect="native" accent="" scope="local"/>
 							
+								String spkid = parser.getAttributeValue(null, "spkid").trim().replaceAll("[\\s()]", "")
+								
 								writer.writeStartElement("Speaker")
-								writer.writeAttribute("id", parser.getAttributeValue(null, "spkid").trim())
-								writer.writeAttribute("name", parser.getAttributeValue(null, "spkid").trim())
+								writer.writeAttribute("id", spkid)
+								writer.writeAttribute("name", spkid)
 								writer.writeAttribute("check", "")
 								writer.writeAttribute("dialect", parser.getAttributeValue(null, "lang"))
 								writer.writeAttribute("accent", parser.getAttributeValue(null, "gender"))
@@ -94,8 +96,8 @@
 								/**
 								 * remove the additional speaker if already written
 								 */
-								if (additionalSpeakers.containsKey(parser.getAttributeValue(null, "spkid").trim())) {
-									additionalSpeakers.remove(parser.getAttributeValue(null, "spkid").trim())
+								if (additionalSpeakers.containsKey(spkid)) {
+									additionalSpeakers.remove(spkid)
 								}
 								break;
 								
@@ -124,7 +126,7 @@
 									else if (name == "etime") name = "endTime"
 									else if (name == "spkid") {
 										name = "speaker"
-										value = value.trim()
+										value = value.trim().replaceAll("[\\s()]", "")
 									}
 									writer.writeAttribute(name, value)
 								}
Index: TXM/trunk/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/transcriber/importer.groovy
===================================================================
--- TXM/trunk/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/transcriber/importer.groovy	(revision 3476)
+++ TXM/trunk/org.txm.groovy.core/src/groovy/org/txm/scripts/importer/transcriber/importer.groovy	(revision 3477)
@@ -198,7 +198,7 @@
 			cpb.done()
 		} else {
 			
-			println "Tokenizing "+files.length+" files from $txmDir"
+			println "Tokenizing "+files.length+" files"
 			cpb = new ConsoleProgressBar(files.length)
 			for (File pfile : files) {
 				cpb.tick()
Index: TXM/trunk/org.txm.core/src/java/org/txm/objects/Edition.java
===================================================================
--- TXM/trunk/org.txm.core/src/java/org/txm/objects/Edition.java	(revision 3476)
+++ TXM/trunk/org.txm.core/src/java/org/txm/objects/Edition.java	(revision 3477)
@@ -52,15 +52,15 @@
 	
 	/** The index page path. */
 	@Parameter(key = TBXPreferences.INDEX)
-	String pIndex;
+	protected String pIndex;
 	
 	@Parameter(key = TBXPreferences.NAMES)
-	ArrayList<String> pPageNames;
+	protected ArrayList<String> pPageNames;
 	
 	@Parameter(key = "pages_wordids")
-	ArrayList<String> pPageFirstWordIds;
+	protected ArrayList<String> pPageFirstWordIds;
 	
-	private File defaultHtmlDir;
+	protected File defaultHtmlDir;
 	
 	/**
 	 * Instantiates a new edition.
Index: TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/views/fileexplorer/MacroExplorer.java
===================================================================
--- TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/views/fileexplorer/MacroExplorer.java	(revision 3476)
+++ TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/views/fileexplorer/MacroExplorer.java	(revision 3477)
@@ -300,7 +300,8 @@
 				if (sel instanceof IStructuredSelection) {
 					List<?> objects = ((IStructuredSelection) sel).toList();
 					if (e.keyCode == SWT.DEL) {
-						DeleteFile.delete(objects);
+						boolean definitive = (e.stateMask & SWT.SHIFT) != 0;
+						DeleteFile.delete(objects, definitive);
 					}
 					else if (e.keyCode == SWT.F5) {
 						MacroExplorer.refresh();
@@ -311,7 +312,8 @@
 							if (o instanceof File) {
 								File file = (File) o;
 								if (e.keyCode == SWT.DEL) {
-									DeleteFile.delete(file);
+									boolean definitive = true; // (e.stateMask & SWT.SHIFT) != 0;
+									DeleteFile.delete(file, definitive);
 								}
 								else if ((char) e.keyCode == 'c' & ((e.stateMask & SWT.CTRL) != 0)) {
 									CopyFile.copy(file);
Index: TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/views/fileexplorer/Explorer.java
===================================================================
--- TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/views/fileexplorer/Explorer.java	(revision 3476)
+++ TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/views/fileexplorer/Explorer.java	(revision 3477)
@@ -300,9 +300,10 @@
 			public void keyPressed(KeyEvent e) {
 				ISelection sel = tv.getSelection();
 				if (sel instanceof IStructuredSelection) {
-					List objects = ((IStructuredSelection) sel).toList();
+					List<Object> objects = ((IStructuredSelection) sel).toList();
 					if (e.keyCode == SWT.DEL) {
-						DeleteFile.delete(objects);
+						boolean definitive = true; // (e.stateMask & SWT.SHIFT) != 0;
+						DeleteFile.delete(objects, definitive);
 					}
 					else if (e.keyCode == SWT.F5) {
 						Explorer.refresh();
@@ -313,7 +314,8 @@
 							if (o instanceof File) {
 								File file = (File) o;
 								if (e.keyCode == SWT.DEL) {
-									DeleteFile.delete(file);
+									boolean definitive = true; // (e.stateMask & SWT.SHIFT) != 0;
+									//DeleteFile.delete(file, definitive);
 								}
 								else if ((char) e.keyCode == 'c' & ((e.stateMask & SWT.CTRL) != 0)) {
 									CopyFile.copy(file);
Index: TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/handlers/files/DeleteFile.java
===================================================================
--- TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/handlers/files/DeleteFile.java	(revision 3476)
+++ TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/handlers/files/DeleteFile.java	(revision 3477)
@@ -28,6 +28,7 @@
 package org.txm.rcp.handlers.files;
 
 import java.io.File;
+import java.util.Arrays;
 import java.util.List;
 
 import org.eclipse.core.commands.AbstractHandler;
@@ -66,7 +67,8 @@
 			
 			if (o instanceof File) {
 				File file = (File) o;
-				delete(file);
+				boolean definitive = true; // (event.stateMask & SWT.SHIFT) != 0;
+				delete(file, definitive);
 			}
 		}
 		return null;
@@ -77,39 +79,19 @@
 	 * 
 	 * @param file the file or directory to delete
 	 */
-	public static void delete(File file) {
-		// ask new file name
+	public static void delete(File file, boolean definitive) {
 		
-		Shell shell = new Shell();
-		MessageBox dialog = new MessageBox(shell, SWT.YES | SWT.NO);
-		dialog.setMessage(TXMUIMessages.bind(TXMUIMessages.areYouSureYouWantToDeleteP0Colon, file));
-		
-		int buttonID = dialog.open();
-		switch (buttonID) {
-			case SWT.YES:
-				File parentFile = file.getParentFile();
-				if (file.isFile()) {
-					if (!file.delete()) System.out.println(NLS.bind(TXMUIMessages.failedToDeleteFileP0, file));
-				}
-				else if (file.isDirectory()) {
-					if (!DeleteDir.deleteDirectory(file)) System.out.println(NLS.bind(TXMUIMessages.failedToDeleteFileP0, file));
-				}
-				Explorer.refresh(parentFile);
-				MacroExplorer.refresh(parentFile);
-			case SWT.NO:
-				// exits here ...
-				break;
-			case SWT.CANCEL:
-				// does nothing ...
-		}
+		delete(Arrays.asList(file), definitive);
 	}
 	
 	/**
 	 * open a dialog box to confirm and update views
 	 * 
 	 * @param files the files or directories to delete
+	 * @param definitive definitivelly delete the files FIXME NOT IMPLEMENTED YET
 	 */
-	public static void delete(List files) {
+	public static void delete(List<?> files, boolean definitive) {
+		
 		Shell shell = new Shell();
 		MessageBox dialog = new MessageBox(shell, SWT.YES | SWT.NO);
 		dialog.setMessage(TXMUIMessages.bind(TXMUIMessages.areYouSureYouWantToDeleteP0Colon, files));
@@ -122,12 +104,20 @@
 						File file = (File) o;
 						if (file.exists()) {
 							if (file.isFile()) {
-								if (!file.delete()) {
-									System.out.println(NLS.bind(TXMUIMessages.failedToDeleteFileP0, file));
+								if (definitive) {
+									if (!file.delete()) {
+										System.out.println(NLS.bind(TXMUIMessages.failedToDeleteFileP0, file));
+									}
+								} else {
+									File dest = new File(System.getProperty("java.io.tmpdir"), file.getName());
+									dest.delete();
+									if (!file.renameTo(dest)) {
+										System.out.println(NLS.bind("Fail to move file to the tmp directory: {0}", file));
+									}
 								}
 							}
 							else if (file.isDirectory()) {
-								if (!DeleteDir.deleteDirectory(file)) {
+								if (!DeleteDir.deleteDirectory(file, definitive)) {
 									System.out.println(NLS.bind(TXMUIMessages.failedToDeleteFileP0, file));
 								}
 							}
Index: TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/messages/TXMUIMessages.java
===================================================================
--- TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/messages/TXMUIMessages.java	(revision 3476)
+++ TXM/trunk/org.txm.rcp/src/main/java/org/txm/rcp/messages/TXMUIMessages.java	(revision 3477)
@@ -1480,6 +1480,8 @@
 	public static String YouNeedToSetAsManyPercentSPrintfMarksAsSelectedProperties;
 
 	public static String YouReGoingToLostThoseModificationsIfNotAlreadyExportedContinue;
+
+	public static String defaultReferences;
 	
 	static {
 		// initialize resource bundle
Index: TXM/trunk/org.txm.rcp/plugin.xml
===================================================================
--- TXM/trunk/org.txm.rcp/plugin.xml	(revision 3476)
+++ TXM/trunk/org.txm.rcp/plugin.xml	(revision 3477)
@@ -1966,17 +1966,6 @@
             </visibleWhen>
          </command>
          <command
-               commandId="org.txm.rcp.commands.DeleteFile"
-               style="push"
-               tooltip="%command.tooltip.15">
-            <visibleWhen
-                  checkEnabled="false">
-               <reference
-                     definitionId="OneFileSelected">
-               </reference>
-            </visibleWhen>
-         </command>
-         <command
                commandId="org.txm.rcp.commands.CopyFile"
                style="push"
                tooltip="%command.tooltip.16">
Index: TXM/trunk/org.txm.utils/src/org/txm/utils/DeleteDir.java
===================================================================
--- TXM/trunk/org.txm.utils/src/org/txm/utils/DeleteDir.java	(revision 3476)
+++ TXM/trunk/org.txm.utils/src/org/txm/utils/DeleteDir.java	(revision 3477)
@@ -55,25 +55,33 @@
 		deleteDirectory(new File(args[0]));
 	}
 
+	static public boolean deleteDirectory(File path) {
+		return deleteDirectory(path, false);
+	}
+	
 	/**
 	 * Delete directory.
 	 *
-	 * @param path
-	 *            the path
+	 * @param path the path to the directory to delete
+	 * @param definitive definitivelly delete the directory or move it to trash FIXME NOT IMPLEMENTED YET
 	 * @return true, if successful
 	 */
-	static public boolean deleteDirectory(File path) {
-		if (path == null)
+	static public boolean deleteDirectory(File path, boolean definitive) {
+		if (path == null) {
 			return false;
-		if (!path.exists())
+		}
+		if (!path.exists()) {
 			return false;
-
-		try { // try using system for faster reply
-				// prefer OS-dependent directory removal tool
+		}
+		try { // try using system for faster reply and prefer OS-dependent directory removal tool
 			if (SystemUtils.IS_OS_WINDOWS) {
 				Runtime.getRuntime().exec(new String[] { "%ComSpec%", "/C", "RD /S /Q \"" + path + '"' }).waitFor(); // FIXME: SJ: "%ComSpec%" is not defined, at least on my Win7
 			} else if (SystemUtils.IS_OS_UNIX) {
-				Runtime.getRuntime().exec(new String[] { "/bin/rm", "-rf", path.toString() }).waitFor();
+				if (definitive) {
+					Runtime.getRuntime().exec(new String[] { "/bin/rm", "-rf", path.toString() }).waitFor();
+				} else {
+					Runtime.getRuntime().exec(new String[] { "gio", "trash", path.toString() }).waitFor();
+				}
 			}
 			
 			if (!path.exists()) { // it worked
@@ -89,7 +97,7 @@
 			if (files != null)
 				for (int i = 0; i < files.length; i++) {
 					if (files[i].isDirectory()) {
-						deleteDirectory(files[i]);
+						deleteDirectory(files[i], definitive);
 					} else {
 						files[i].delete();
 					}
Index: TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/CQPEdition.java
===================================================================
--- TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/CQPEdition.java	(revision 0)
+++ TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/CQPEdition.java	(revision 3477)
@@ -0,0 +1,52 @@
+package org.txm.searchengine.cqp.corpus;
+
+import org.txm.objects.Edition;
+import org.txm.objects.Page;
+import org.txm.objects.Text;
+import org.txm.utils.TXMProgressMonitor;
+
+/**
+ * Build onthefly HTML pages from the CQP indexes (words + structures)
+ * 
+ * @author mdecorde
+ *
+ */
+public class CQPEdition extends Edition {
+
+	public CQPEdition(Text text) {
+		
+		super(text);
+	}
+	
+	public CQPEdition(String id) {
+		
+		super(id);
+	}
+	
+	@Override
+	protected boolean _compute(TXMProgressMonitor monitor) throws Exception {
+		// pPageNames.cl
+		// pPageFirstWordIds
+		return true;
+	}
+	
+	/**
+	 * Gets the page.
+	 *
+	 * @param no the no
+	 * @return the page
+	 */
+	public Page getPage(int n) {
+		
+		if (n >= 0 && pPageNames.size() > n) {
+			String wId = "w_0"; // default word id
+			if (pPageFirstWordIds.size() > n) {
+				wId = pPageFirstWordIds.get(n);
+			}
+			return new Page(this, pPageNames.get(n), wId, n);
+		}
+		else {
+			return null;
+		}
+	}
+}

Property changes on: TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/searchengine/cqp/corpus/CQPEdition.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/importer/cwb/CompressCQPIndexes.java
===================================================================
--- TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/importer/cwb/CompressCQPIndexes.java	(revision 3476)
+++ TXM/trunk/org.txm.searchengine.cqp.core/src/org/txm/importer/cwb/CompressCQPIndexes.java	(revision 3477)
@@ -186,9 +186,9 @@
 		try {
 			String userdir = System.getProperty("user.home");
 			File tools = new File(userdir, "SVN/txm-sf/CWB/cwb-lib/src/builds/linux-64"); //$NON-NLS-1$
-			File registry = new File(userdir, "runtime-rcpapplication.product/corpora/NOV13-P1/registry/nov13-p1"); //$NON-NLS-1$
-			File data = new File(userdir, "runtime-rcpapplication.product/corpora/NOV13-P1/data/NOV13-P1"); //$NON-NLS-1$
-			CompressCQPIndexes.compressAll(tools, registry, "NOV13-P1", data, true);
+			File registry = new File(userdir, "runtime-rcpapplication.product/corpora/NOV13-P1-2022-06-15-V1/registry/nov13-p1-2022-06-15-v1"); //$NON-NLS-1$
+			File data = new File(userdir, "runtime-rcpapplication.product/corpora/NOV13-P1-2022-06-15-V1/data/NOV13-P1-2022-06-15-V1"); //$NON-NLS-1$
+			CompressCQPIndexes.compressAll(tools, registry, "NOV13-P1-2022-06-15-V1", data, true);
 			
 		} catch (Exception e) {
 			e.printStackTrace();
Index: TXM/trunk/org.txm.lexicaltable.core/src/org/txm/lexicaltable/core/functions/LexicalTable.java
===================================================================
--- TXM/trunk/org.txm.lexicaltable.core/src/org/txm/lexicaltable/core/functions/LexicalTable.java	(revision 3476)
+++ TXM/trunk/org.txm.lexicaltable.core/src/org/txm/lexicaltable/core/functions/LexicalTable.java	(revision 3477)
@@ -562,10 +562,10 @@
 		else if (this.getPartition() != null) {
 			return NLS.bind(LexicalTableCoreMessages.info_creatingLexicalTableWithTheP0PartitionCommaPropertiesP1, this.getPartition().getName(), this.property.asString());
 		}
-		else if (this.parent instanceof Subcorpus) {
-			return NLS.bind(LexicalTableCoreMessages.info_creatingLexicalTableWithTheP0PartitionCommaPropertiesP1, this.getPartition().getName(), this.property.asString());
+		else if (this.parent instanceof Subcorpus) { // from subcorpus
+			return NLS.bind(LexicalTableCoreMessages.info_creatingLexicalTableWithTheP0CorpusAndTheP1Subcorpus, this.parent.getParent().getName(), this.parent.getName());
 		}
-		// from main corpus and subcorpus
+		// from main corpus 
 		else {
 			return NLS.bind("Computing Lexical table on {0}", this.parent.getName());
 		}
