I have built gnuplot v5.0.5 from source on Linux Min 17.3. I used ./configure --with-qt5 --with-wx-single-thread. (Not wholly sure about the 'single thread' bit. Unable to find any documentation so trawled this option off the net. The build does not complain.)
The qt terminal works fine. The wxt terminal also seems to work fine in interactive mode. But when I try running a script from the command line with the wxt terminal (first script line 'set term wxt' to reset from the qt default), the plot area of the terminal is black. It does not appear to be painted on first presentation.
If I resize using the menu item in the icon, I get the graph I expect and it sort of works. If I do the initial resize by dragging the bottom right corner of the terminal's window, sometimes it repaints properly. Sometimes one of the plots (always the last plotted) is double drawn and badly messed up - this persists no matter what else I do until closing. In addition, when I resize and things look fine, if I hit "Autoscale" in the toolbar, the same double drawing usually occurs... but not always. All this behaviour is really weird, especially the intermittent nature of the problems!!
I have built against both libwxgtk2.8-dev and libwxgtk3.0-dev, and I get the same behaviour.
I do not recognize those symptoms and I have no explanation or fix.
If you reported your configuration command accurately, I think you did not end up with a single-threaded wxt build because the option was not specified correctly. You need to say
(note "threaded" rather than "thread"). So I suppose you can try that first and see if it makes a difference. The terminal section of the configure script output should list
My recommendation would be that if the qt terminal works, use it and forget about wxt. That's what I do for ordinary purposes :-) The wxt terminal has no advantage over qt that I know of.
On 05/03/17 23:12, Ethan Merritt wrote:
Well that was what I was trying to evaluate!
Also, from http://gnuplot.sourceforge.net/docs_4.2/node441.html, "When
you resize a window, the plot is immediately scaled to fit in the new
size of the window. . Unlike other interactive terminals, the wxt
terminal scales the whole plot, including fonts and linewidths, and
keeps its global aspect ratio constant, leaving an empty space painted
in gray." That seems potentially useful to me!
OK. I have built this on a second machine with the same outcome. However, I have tracked down the issue of the blank initial screen + double-drawing to the 'set multiplot' command. The minimal script to reproduce is:
set term wxt title "wxt terminal"
set multiplot
plot cos(x)
pause -1 "Hit return to continue"
Comment out "set multiplot" and it works fine. BTW: This works as expected with the qt terminal so I am thinking bug.
Any comments before I file a ticket?
I suppose it shows a bug somewhere, or at least an inconsistency since I don't see the same thing here. But multiplot is not guaranteed to display anything prior to the final "unset multiplot". What happens if you add "unset multiplot" before the pause statement?
Ah-hah! Adding "unset multiplot" and it works correctly! (I remember reading in the manual that this was required for some terminals but didn't join the dots. Doh!) Thanks!
However, the 'autoscale' feature still messes up multiplots
FWIW: The wxt terminal looks pretty good to me. I like the feature that retains the page's aspect ratio on resize.
Just as a tailpiece to this, if you include "unset multiplot" in a script, this screws up the qt terminal! The multiplot displays correctly initially, but either resizing the window or hitting the 'Replot' button causes only part of the page to be redrawn. (Seemingly, the last-drawn graph.)
Aaaaargh!!
That is an intrinsic limitation of multiplot. You cannot redraw plots that are not current, and only the most recent plot in a multiplot is current. For the same reason mouse feedback from a multiplot is only valid for the most recent component. This is true for all output modes, not just qt.