On Wed, Jun 25, 2025 at 03:01:39PM +0200, [email protected] wrote:
> > We call "octave -q 2>&1". I see on my commandline that there exists
> > octave-cli.
> > iDo you see it on mac as well? Should we call that instead?
>
> According to octave.org <http://octave.org/>, Starting with version 4, the
> default behavior of the ???octave??? command has been changed to launch the
> GUI: https://octave.org/NEWS-4.0.html. Previous versions would launch in a
> terminal widow instead.
Ok, thanks for clarification.
> When I invoke octave from LyX, an iconized window appears briefly and
> disappears on the Dock, which looks like a terminal icon but is titled
> ???octave-gui???. So, it may indeed be worthwhile to change the command to
> "octave-cli??? when calling from LyX (the file also exists on mac), or use
> one of the command-line options --no-window-system, -W, --no-gui, etc. Or
> perhaps Stephan???s idea is the right way to go about it.
I am not sure why mac needs the special treatment. When I simply change octave
to octave-cli on linux (see attached patch), "rand(2,2)" in mathed works as
expected for octave.
Stephan, is this enough?
> Unfortunately, I was unable to test how any of these affects the speed. I
> made the alias octave='octave-cli??? as well as with command-line options in
> my Z-shell but it did not change the behavior in LyX: the icon on the Dock is
> always titled ???octave-gui??? and alway takes a few seconds to appear and
> disappear before the answer is shown in LyX. If you have any other
> suggestions, I would be happy to try and run a speed test.
octave call is hardoced in lyx sources no outside alias would help (except of
makeing octave to be link to octave-cli, but I don't think you want to mess
with your system that badly).
Pavel
diff --git a/src/mathed/MathExtern.cpp b/src/mathed/MathExtern.cpp
index 7f05a5a529..10fa72847e 100644
--- a/src/mathed/MathExtern.cpp
+++ b/src/mathed/MathExtern.cpp
@@ -1411,7 +1411,7 @@ namespace {
//
string full = comm_left + expr + comm_right;
lyxerr << "checking input: '" << full << "'" << endl;
- out = captureOutput("octave -q 2>&1", full);
+ out = captureOutput("octave-cli -q 2>&1", full);
lyxerr << "output: '" << out << "'" << endl;
// leave loop if expression syntax is probably ok
--
lyx-devel mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-devel