# HG changeset patch # User Rik # Date 1385443056 28800 # Node ID 6df05f2fd354261ef592a9cc91329640c70cada2 # Parent 2831a949a2199c58142bd43e795c6d7abd0ce97b maint: Back out changeset 25b6fbe82827 and set default to GUI for 4.0 release. diff -r 2831a949a219 -r 6df05f2fd354 NEWS --- a/NEWS Mon Nov 25 22:11:37 2013 -0500 +++ b/NEWS Mon Nov 25 21:17:36 2013 -0800 @@ -1,11 +1,10 @@ Summary of important user-visible changes for version 3.8: --------------------------------------------------------- - ** An experimental GUI is now available with Octave. The GUI works well - on Linux systems, acceptably on Windows, but unsatisfactorily on Mac OS X. - To start a GUI session include the "--force-gui" option when invoking - Octave. The GUI is under continuous improvement and will be the default - interface for the 4.0 release. + ** A GUI is now available with Octave and is the default when starting + an interactive session. The original command line interface is also + available and can be entered by using the "--no-gui" option when + invoking Octave. ** Octave now uses OpenGL graphics by default with FLTK widgets. If OpenGL libraries or FLTK widgets are not available when Octave is diff -r 2831a949a219 -r 6df05f2fd354 src/main.in.cc --- a/src/main.in.cc Mon Nov 25 22:11:37 2013 -0500 +++ b/src/main.in.cc Mon Nov 25 21:17:36 2013 -0800 @@ -585,12 +585,18 @@ { int retval = 0; - bool start_gui = false; - bool gui_libs = false; + bool start_gui = true; + bool gui_libs = true; std::string octave_bindir = get_octave_bindir (); - std::string file = octave_bindir + dir_sep_char + "octave-cli"; + std::string file = octave_bindir + dir_sep_char; + +#if defined (HAVE_OCTAVE_GUI) + file += "octave-gui"; +#else + file += "octave-cli"; +#endif char **new_argv = new char * [argc + 1]; @@ -605,18 +611,7 @@ for (int i = 1; i < argc; i++) { - if (! strcmp (argv[i], "--force-gui")) - { - start_gui = true; - gui_libs = true; - file = octave_bindir + dir_sep_char; - #if defined (HAVE_OCTAVE_GUI) - file += "octave-gui"; - #else - file += "octave-cli"; - #endif - } - else if (! strcmp (argv[i], "--no-gui-libs")) + if (! strcmp (argv[i], "--no-gui-libs")) { // Run the version of Octave that is not linked with any GUI // libraries. It may not be possible to do plotting or any @@ -624,7 +619,9 @@ // require less memory. Don't pass the --no-gui-libs option // on as that option is not recognized by Octave. - // This is the default for 3.8 release. + start_gui = false; + gui_libs = false; + file = octave_bindir + dir_sep_char + "octave-cli"; } else if (! strcmp (argv[i], "--no-gui")) { @@ -634,7 +631,8 @@ // if the --no-gui option is given, we may be asked to do some // plotting or ui* calls. - // This option calls the cli executable for the 3.8 release. + start_gui = false; + new_argv[k++] = argv[i]; } else if (! strcmp (argv[i], "--silent") || ! strcmp (argv[i], "--quiet") || ! strcmp (argv[i], "-q")) @@ -697,7 +695,8 @@ } else { - // Parent. Forward signals to child while waiting for it to exit. + // Parent. Forward signals to the child while waiting for it + // to exit. int status;