Reputation: 141
I am a Windows user, I want to use octave in the terminal of vscode.
I have put octave to the environment variable, but when I type octave
in the terminal, it pop out the gui version.
I have tried to type octave --no-gui
, it pop out the octave-cli window (Please refer to the image attached).
Here are the questions:
octave
or I can only type octave --no-gui
to use cli version?Upvotes: 1
Views: 1752
Reputation: 11
You can change line octave-cli.exe %
to octave-gui.exe --no-gui %
in file octave.bat
:
Rem Start Octave (this detaches and immediately returns).
if %GUI_MODE%==1 (
start octave-gui.exe --gui %*
) else (
octave-gui.exe --no-gui %*
Rem octave-cli.exe %*
)
Instead of starting octave-cli.exe you are starting GUI octave-gui.exe --no-gui
without graphical use interface.
Check available graphics toolkits in octave:
octave> available_graphics_toolkits()
Answer should be
ans = {
[1,1] = fltk
[1,2] = gnuplot
[1,3] = qt
}
Check which graphics toolkit is used
graphics_toolkit()
ans = qt
Answer should be qt. Benefit of the change is that now you can use best inline graphics in Jupyter Notebooks and also in VSCode Jupyter Notebooks.
John
Upvotes: 1
Reputation: 1665
In addition to the octave.vbs file that most people use to start octave, there is also an octave.bat file located under %OCTAVE-HOME%/mingw64/bin
.
I'm not familiar with vscode, but if I open a Windows command prompt, navigate to c:\Octave\octave-6.4.0-w64\mingw64
, and type octave.bat
(no options used), it opens octave in the existing window.
Upvotes: 1