help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help with Octave standalone


From: Ian McCallion
Subject: Re: Help with Octave standalone
Date: Sun, 15 Mar 2020 14:28:54 +0000

On Sun, 15 Mar 2020 at 12:36, "Markus Mützel" <address@hidden> wrote:
>
> Am 15. März 2020 um 13:00 Uhr schrieb "Ian McCallion":
> > On Fri, 13 Mar 2020 at 16:37, Ian McCallion <address@hidden> wrote:
> >
> > I am having great difficulty with this and I think there is a bug in
> > Octave 5.2 although I'd be happy to be proved wrong.
> >
> > The script below demonstrates the problem:
> > ----------------------------
> >  graphics_toolkit('qt');
> > myfont={'fontsize',25,'fontweight','bold'};
> > mygraphs={'-dpng','-S800,800'};
> > mywidegraphs={'-dpng','-S1800,800'};
> > set(0, 'defaulttextfontsize', 15)
> > figure(1, 'visible', 'off')
> >         xrange = 1:10;
> > ssd=xrange.+rand(1,10);
> > plot(xrange, [ssd; mean(ssd)*ones(1,10)], 'Linewidth',2);
> > legend('Actual','Average over touch')
> > axis([0, xrange(end)+2, min(ssd)-5, 5+max(10,max(ssd))])
> > xlabel('Row number', myfont{:})
> > ylabel('Milliseconds', myfont{:})
> > title('Standard Deviation (Touch only)', myfont{:})
> > grid ('on')
> > print (1, [graphics_toolkit, '1.png'], mywidegraphs{:})
> > ------------------------
> > It runs fine when launching Octave from a commandline using the command
> > - c:\octave\octave-5.2.0\octave.vbs
> > - C:\octave\octave-5.2.0\octave.vbs --no-gui
> > - C:\octave\octave-5.2.0\mingw64\bin\octave.bat --gui
> > It fails when when launching Octave from a commandline using the command
> > - C:\octave\octave-5.2.0\mingw64\bin\octave.bat --no-gui
> > and the resulting output is given below.
> > --------------------------
> > octave:6> plottest
> >    *** Building graphs
> > error: graphics_toolkit: qt toolkit is not available
> > error: called from
> >     graphics_toolkit at line 81 column 5
> >     plottest at line 2 column 3
> > octave:6>
> > --------------------------------
> >
> > The common property of the situations in which it works is that a new
> > window is launched for all of them, and in the case where it does not
> > work Octave "borrows" the commandline window it was launched from.
> >
> > Unfortunately for me this is a show-stopper for use of 5.2.0 so I will
> > be happy to run other tests as needed to help track down the problem.
> >
> > Cheers... Ian
>
> "octave.bat --no-gui" runs octave-cli.exe which isn't linked against Qt. So 
> you won't be able to use "graphics_toolkit ('qt')" with it.

Hi Markus, Thanks for the clear definitive answer.

> Use one of the other ways you've shown to start Octave to use 
> "graphics_toolkit ('qt')".

Unfortunately, as the other ways produce a second window when launched
from and existing commandline window they are not a solution for me
because my user workflow runs in a windows commandline window, and the
user needs to see the output of his commands (some of which use
Octave) in the window.

I switched to qt from gnuplot as recommended a few months ago on this
list because in 5.2.0, gnuplot and fltk both produce warning messages
as shown in the following output:
--------------------------
octave:4> plottest
Plot a graph using gnuplot
DEBUG: FC_WEIGHT didn't match
Elapsed time is 1.02322 seconds.
Graph plotted
octave:5> plottest
Plot a graph using fltk
DEBUG: FC_WEIGHT didn't match
Elapsed time is 1.0631 seconds.
Graph plotted
--------------------------

Given the choice between staying on 4.4.1 and using Qt vs moving to
5.2.0 and getting spurious DEBUG: messages I will go with the second
choice and tell users to ignore the messages.

Will octave-cli.exe at some point be linked against Qt?

Cheers... Ian



reply via email to

[Prev in Thread] Current Thread [Next in Thread]