#1867 "pause" command fails in "windows terminal" in 5.x.x versions

None
pending-fixed
nobody
windows (8)
2016-10-15
2016-10-13
Anonymous
No

Type commands:
set term windows
pause 2

The pause command does not wait at all.
This fails for versions >= 5.0.0 and <= 5.0.4.
I did not test 5.0.5

Discussion

  • Bastian Märkisch

    • labels: --> Windows
    • Group: -->
    • Priority: -->
     
  • Bastian Märkisch

    Confirmed. Also applies to current CVS.

     
  • Bastian Märkisch

    The problem originates in the definition of HAVE_USLEEP in config.mgw. Albeit this is correct, usleep() does not seem to work correctly. In any case we should use win_sleep() at this correctly handles all interactive terminals (win, wxt, qt, caca) on Windows, not just the currently active one.

     
  • Bastian Märkisch

    usleep() only seems to work with values < 1s. This only causes a problem when using the windows, terminal, but not for wxt or qt. So here are two work-arounds to wait for 2 seconds:

    do for [i=1:20] { pause 0.1 }
    

    or

    set term push; set term wxt; pause 2; set term pop;
    
     
  • Bastian Märkisch

    • labels: Windows --> windows
    • status: open --> pending-fixed
     
  • Bastian Märkisch

    Fixed in CVS for version 5.1 and 5.0.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks