diff options
author | Kyle Guinn <elyk03@gmail.com> | 2014-12-06 23:31:04 -0600 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2014-12-13 10:35:41 +0700 |
commit | 158949367c827185ec652cb474a0e3668a716d13 (patch) | |
tree | 161b02625fa4ad256db8e63225a6beb299662a50 /academic/octave/patches | |
parent | fabfddfd81cfc09240ca91bceacd70f098ecc678 (diff) |
academic/octave: Add workarounds for documentation browser bugs.
Thanks to Nikos Giotis for the bug report.
Signed-off-by: Kyle Guinn <elyk03@gmail.com>
Diffstat (limited to 'academic/octave/patches')
-rw-r--r-- | academic/octave/patches/missing-info-error.diff | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/academic/octave/patches/missing-info-error.diff b/academic/octave/patches/missing-info-error.diff new file mode 100644 index 0000000000000..4b681c3d5662e --- /dev/null +++ b/academic/octave/patches/missing-info-error.diff @@ -0,0 +1,38 @@ + +# HG changeset patch +# User Torsten <ttl@justmail.de> +# Date 1388608160 -3600 +# Node ID d03a6d272fee1d167473a2aa25e530443fcbe5cc +# Parent 5f7f5886692263efacc7141f0bbba341ae7804d1 +display error message in document browser when info file is missing + +* webinfo.cc (constructor): display a message if info file does not exist + +diff --git a/libgui/src/qtinfo/webinfo.cc b/libgui/src/qtinfo/webinfo.cc +--- a/libgui/src/qtinfo/webinfo.cc ++++ b/libgui/src/qtinfo/webinfo.cc +@@ -94,8 +94,22 @@ + + resize (500, 300); + +- set_info_path (QString::fromStdString (Vinfo_file)); ++ QFileInfo info_file = QFileInfo (QString::fromStdString (Vinfo_file)); + ++ if (info_file.exists ()) ++ set_info_path (QString::fromStdString (Vinfo_file)); ++ else ++ { // Info file does not exist ++ _search_check_box->setEnabled (false); ++ _search_line_edit->setEnabled (false); ++ ++ QTextBrowser *msg = addNewTab (tr ("Error")); ++ QString msg_text = QString ("<html><body><br><br><center><b>%1" ++ "</b></center></body></html>"). ++ arg (tr ("The info file %1 does not exist"). ++ arg(info_file.absoluteFilePath ())); ++ msg->setHtml (msg_text); ++ } + } + + void + |