# HG changeset patch # User thomas_-_s # Date 1302675135 0 # Node ID cc2ba63d60055f073c99db0e1f0ea4297c53d426 # Parent f9b070eedd40c6e0aec7e113ce45c122d224287f Opening a file via command line call is possible without any parameter prefix now. git-svn-id: svn://svn.code.sf.net/p/universalindent/code/trunk@1042 59b1889a-e5ac-428c-b0c7-476e01d41282 diff -r f9b070eedd40 -r cc2ba63d6005 src/main.cpp --- a/src/main.cpp Wed Apr 13 06:07:18 2011 +0000 +++ b/src/main.cpp Wed Apr 13 06:12:15 2011 +0000 @@ -110,11 +110,11 @@ Evaluates the following parameters: No parameters starts without server and full gui. - -f filename --file filename : Opens the by filename defined file on start. + A string without any parameter prefix will be loaded as file on start. -p --plugin : Run as plugin. Server will be started with a simplified gui. -s --server : Run as server only without gui. If -p and -s are set, -p will be used. - -v --verbose needs a following parameter defining the verbose level as a number from 0 to 3. + -v --verbose needs a following parameter defining the verbose level as a number from 0 to 3. */ int main(int argc, char *argv[]) { QString file2OpenOnStart = ""; @@ -156,7 +156,7 @@ cmd.setExceptionHandling(false); // Define a value argument and add it to the command line. - TCLAP::ValueArg filenameArg("f", "file", "Opens the by filename defined file on start" , false, "", "string"); + TCLAP::UnlabeledValueArg filenameArg("file", "Opens the by filename defined file on start" , false, "", "filename"); cmd.add( filenameArg ); // Define a switch and add it to the command line.