# HG changeset patch # User John W. Eaton # Date 1386016518 18000 # Node ID 728cb75305388bcacba10c850f09ee6ce60f4d6b # Parent 8e7d2ee1254d05e346fb3441d5cfc9f923b0bc79# Parent c0c61619917ee8eda8fc41a3a4542adbab1717e0 maint: Periodic merge of stable to default. diff -r 8e7d2ee1254d -r 728cb7530538 NEWS --- a/NEWS Mon Dec 02 10:37:48 2013 -0800 +++ b/NEWS Mon Dec 02 15:35:18 2013 -0500 @@ -20,7 +20,7 @@ improvements since the last major release Octave, we also decided against delaying the release of all these new improvements any longer just to perfect the GUI. So please enjoy the 3.8 release of - Octave and the preview of the new GUI. We beleive it is working + Octave and the preview of the new GUI. We believe it is working reasonably well, but we also know that there are some obvious rough spots and many things that could be improved. diff -r 8e7d2ee1254d -r 728cb7530538 configure.ac --- a/configure.ac Mon Dec 02 10:37:48 2013 -0800 +++ b/configure.ac Mon Dec 02 15:35:18 2013 -0500 @@ -2728,6 +2728,7 @@ fi if test $build_gui = yes; then + OCTAVE_CHECK_QFONT_MONOSPACE OCTAVE_CHECK_FUNC_SETPLACEHOLDERTEXT fi diff -r 8e7d2ee1254d -r 728cb7530538 libgui/src/main-window.cc --- a/libgui/src/main-window.cc Mon Dec 02 10:37:48 2013 -0800 +++ b/libgui/src/main-window.cc Mon Dec 02 15:35:18 2013 -0500 @@ -1902,7 +1902,7 @@ "decided against delaying the release of all these new " "improvements any longer just to perfect the GUI. So please " "enjoy the 3.8 release of Octave and the preview of the new GUI. " - "We beleive it is working reasonably well, but we also know that " + "We believe it is working reasonably well, but we also know that " "there are some obvious rough spots and many things that could be " "improved.

" "

We Need Your Help

" diff -r 8e7d2ee1254d -r 728cb7530538 libgui/src/resource-manager.cc --- a/libgui/src/resource-manager.cc Mon Dec 02 10:37:48 2013 -0800 +++ b/libgui/src/resource-manager.cc Mon Dec 02 15:35:18 2013 -0500 @@ -192,18 +192,29 @@ qt_settings.close (); // Get the default monospaced font and replace placeholder - QFont fixed_font = QFont (); +#if defined (HAVE_QFONT_MONOSPACE) + QFont fixed_font; fixed_font.setStyleHint (QFont::Monospace); - settings_text.replace("__default_font__",fixed_font.defaultFamily ()); - settings_text.replace("__default_font_size__","10"); + QString default_family = fixed_font.defaultFamily (); +#elif defined (Q_WS_X11) || defined (Q_WS_WIN) + QString default_family = "Courier New"; +#elif defined (Q_WS_MAC) + QString default_family = "Courier"; +#else + QString default_family = "courier"; +#endif + settings_text.replace ("__default_font__", default_family); + settings_text.replace ("__default_font_size__", "10"); QFile user_settings (settings_file); - if (!user_settings.open (QIODevice::WriteOnly)) + + if (! user_settings.open (QIODevice::WriteOnly)) return; QTextStream out (&user_settings); + out << settings_text; - user_settings.flush (); + user_settings.close (); } diff -r 8e7d2ee1254d -r 728cb7530538 libinterp/Makefile.am --- a/libinterp/Makefile.am Mon Dec 02 10:37:48 2013 -0800 +++ b/libinterp/Makefile.am Mon Dec 02 15:35:18 2013 -0500 @@ -187,8 +187,8 @@ $(LIBOCTINTERP_LINK_DEPS) # Increment these as needed and according to the rules in the libtool manual: -liboctinterp_current = 1 -liboctinterp_revision = 1 +liboctinterp_current = 2 +liboctinterp_revision = 0 liboctinterp_age = 0 liboctinterp_version_info = $(liboctinterp_current):$(liboctinterp_revision):$(liboctinterp_age) diff -r 8e7d2ee1254d -r 728cb7530538 libinterp/corefcn/file-io.cc --- a/libinterp/corefcn/file-io.cc Mon Dec 02 10:37:48 2013 -0800 +++ b/libinterp/corefcn/file-io.cc Mon Dec 02 15:35:18 2013 -0500 @@ -2222,7 +2222,7 @@ @deftypefn {Built-in Function} {} SEEK_CUR ()\n\ Return the numerical value to pass to @code{fseek} to\n\ position the file pointer relative to the current position.\n\ -@seealso{SEEK_SET, SEEK_END}.\n\ +@seealso{SEEK_SET, SEEK_END}\n\ @end deftypefn") { return const_value ("SEEK_CUR", args, 0); @@ -2233,7 +2233,7 @@ @deftypefn {Built-in Function} {} SEEK_END ()\n\ Return the numerical value to pass to @code{fseek} to\n\ position the file pointer relative to the end of the file.\n\ -@seealso{SEEK_SET, SEEK_CUR}.\n\ +@seealso{SEEK_SET, SEEK_CUR}\n\ @end deftypefn") { return const_value ("SEEK_END", args, 1); diff -r 8e7d2ee1254d -r 728cb7530538 libinterp/corefcn/input.cc --- a/libinterp/corefcn/input.cc Mon Dec 02 10:37:48 2013 -0800 +++ b/libinterp/corefcn/input.cc Mon Dec 02 15:35:18 2013 -0500 @@ -137,7 +137,10 @@ void set_default_prompts (void) { - VPS1 = "\\s:\\#> "; + // Use literal "octave" instead of "\\s" to avoid setting the prompt + // to "octave.exe" or "octave-gui", etc. + + VPS1 = "octave:\\#> "; VPS2 = "> "; VPS4 = "+ "; @@ -1237,7 +1240,7 @@ Query or set the primary prompt string. When executing interactively,\n\ Octave displays the primary prompt when it is ready to read a command.\n\ \n\ -The default value of the primary prompt string is @qcode{\"\\s:\\#> \"}.\n\ +The default value of the primary prompt string is @qcode{\"octave:\\#> \"}.\n\ To change it, use a command like\n\ \n\ @example\n\ diff -r 8e7d2ee1254d -r 728cb7530538 liboctave/Makefile.am --- a/liboctave/Makefile.am Mon Dec 02 10:37:48 2013 -0800 +++ b/liboctave/Makefile.am Mon Dec 02 15:35:18 2013 -0500 @@ -104,8 +104,8 @@ $(LIBOCTAVE_LINK_DEPS) # Increment these as needed and according to the rules in the libtool manual: -liboctave_current = 1 -liboctave_revision = 1 +liboctave_current = 2 +liboctave_revision = 0 liboctave_age = 0 liboctave_version_info = $(liboctave_current):$(liboctave_revision):$(liboctave_age) diff -r 8e7d2ee1254d -r 728cb7530538 m4/acinclude.m4 --- a/m4/acinclude.m4 Mon Dec 02 10:37:48 2013 -0800 +++ b/m4/acinclude.m4 Mon Dec 02 15:35:18 2013 -0500 @@ -359,6 +359,30 @@ fi ]) dnl +dnl Check whether Qt provides QFont::Monospace +dnl +AC_DEFUN([OCTAVE_CHECK_QFONT_MONOSPACE], [ + AC_CACHE_CHECK([whether Qt provides QFont::Monospace], + [octave_cv_decl_qfont_monospace], + [AC_LANG_PUSH(C++) + ac_octave_save_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$QT_CPPFLAGS $CPPFLAGS" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #include + ]], [[ + QFont::StyleHint hint = QFont::Monospace; + ]])], + octave_cv_decl_qfont_monospace=yes, + octave_cv_decl_qfont_monospace=no) + CPPFLAGS="$ac_octave_save_CPPFLAGS" + AC_LANG_POP(C++) + ]) + if test $octave_cv_decl_qfont_monospace = yes; then + AC_DEFINE(HAVE_QFONT_MONOSPACE, 1, + [Define to 1 if Qt provides QFont::Monospace.]) + fi +]) +dnl dnl Check whether Qscintilla SetPlaceholderText function exists. dnl FIXME: This test uses a version number. It potentially could dnl be re-written to actually call the function, but is it worth it?