- May
- 15,047
- 271
This has something to do with the cursor, or with scrolling, or with timing (I have no clue). Here's a simple BTM.
First, make sure TCMD has scrolled and that the cursor is at the bottom (I used DIR). When I run the BTM this is what I see when it's done.
Once I click the mouse anywhere outside TCMD the output changes to what it should have been.
Here's a strange one. If I do either of these, it works correctly.
1. comment echos ^e[?25l
2. comment delay 1
If I put echos ^e[?25h at the end of the BTM I get a different corruption (which goes away as mentioned above).
Code:
@echo off
:: cursor off
echos ^e[?25l
setarray /f n[2]
set n[0]=a
set n[1]=b
do i=0 to 1
delay 1
echo n[%i] = %n[%i]
enddo
unsetarray n
First, make sure TCMD has scrolled and that the cursor is at the bottom (I used DIR). When I run the BTM this is what I see when it's done.
Once I click the mouse anywhere outside TCMD the output changes to what it should have been.
Here's a strange one. If I do either of these, it works correctly.
1. comment echos ^e[?25l
2. comment delay 1
If I put echos ^e[?25h at the end of the BTM I get a different corruption (which goes away as mentioned above).