From 72a6f6a6903556396c864219f594e57089b3f726 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gunter=20K=C3=B6nigsmann?= Date: Sun, 11 Aug 2024 22:29:11 +0200 Subject: [PATCH] Better log messages for #1934 --- src/wxMaxima.cpp | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/src/wxMaxima.cpp b/src/wxMaxima.cpp index fb81c4605..8739d9b38 100644 --- a/src/wxMaxima.cpp +++ b/src/wxMaxima.cpp @@ -3581,6 +3581,7 @@ void wxMaxima::GnuplotCommandName(wxString gnuplot) { wxString wgnuplot = gnuplot; if(m_configuration.UseWGnuplot()) { + wxLogMessage(_("Instructed to prefer wgnuplot over gnuplot")); long pos = gnuplot.rfind(wxS("gnuplot")); // if pos is not wxNOT_FOUND it is 6 or higher. if(pos != wxNOT_FOUND) @@ -3590,6 +3591,10 @@ void wxMaxima::GnuplotCommandName(wxString gnuplot) { m_gnuplotcommand = pathlist.FindAbsoluteValidPath(wgnuplot); } } + else + { + wxLogMessage(_("Instructed to prefer gnuplot over wgnuplot")); + } #ifdef __WXMSW__ if (m_gnuplotcommand.IsEmpty()) m_gnuplotcommand = pathlist.FindAbsoluteValidPath(gnuplot); @@ -3614,11 +3619,16 @@ void wxMaxima::GnuplotCommandName(wxString gnuplot) { // If not successful, use the original command (better than empty for error // messages) if (m_gnuplotcommand.IsEmpty()) { - wxLogMessage(_("Gnuplot not found, using the default: %s"), gnuplot.mb_str()); if(m_configuration.UseWGnuplot()) - m_gnuplotcommand = wgnuplot; + { + m_gnuplotcommand = wgnuplot; + wxLogMessage(_("Gnuplot not found, using the default: %s"), wgnuplot.mb_str()); + } else - m_gnuplotcommand = gnuplot; + { + m_gnuplotcommand = gnuplot; + wxLogMessage(_("Gnuplot not found, using the default: %s"), gnuplot.mb_str()); + } } else { wxLogMessage(_("Gnuplot found at: %s"), m_gnuplotcommand.mb_str()); }