Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Using SysCurPos On Unix

1 view
Skip to first unread message

DocklandsDude

unread,
Dec 31, 2009, 12:04:44 AM12/31/09
to
Hi All,

I am a former long time user of Classic and Object Rexx on OS/2. I
have recently come back to my code after a long time away from it and
realize that the built in function SysCurPos does not work on my
present operating system which is Ubuntu.

Is there an equivalent function available for Unix systems or any
other way around this problem? I would really like to be able to use
my old code!

Thanks in advance,

DocklandsDude.

Bob Martin

unread,
Dec 31, 2009, 3:27:47 AM12/31/09
to

I haven't found a simple (ie rexxutil) way of doing it but you can play
with this code:

#!/usr/bin/env rexx

say '1B'x'[6n'
ans = ''
do until right(ans,1) = 'R'
ch = SysGetKey('noecho')
ans = ans || ch
end
parse var ans 3 rr ';' cc 'R'
say 'row' rr 'col' cc

Mark Hessling

unread,
Jan 4, 2010, 3:02:46 AM1/4/10
to

You don't specify which interpreter you are using.

The SysCurPos() included with Regina 3.5 (just released) does position
the cursor correctly on ubuntu (9.10 at least)

Cheers, Mark

0 new messages