Can anyone help me link this program? I'm using VMS 5.5-2 with the CRT060
installed. Thanks,
Marc
This is a bug in curses.h. Compile your program /DEFINE=__VMS_CURSES
and it should work.
I'll also mail you the new curses.h, if that'll help.
--
Ken Cowan, ZK2-3/Q8 co...@rtl.enet.dec.com
Digital Equipment Corporation decwrl!rtl!cowan
110 Spit Brook Rd,
Nashua, NH 03062
There is no function in the rtl called getch(). You can build your own:
int
getch()
{
unsigned long kbid; /* keyboard var */
unsigned short key; /* key var */
smg$read_keystroke(&kbid,&key);
return(key);
}
int
getint()
{
int c;
do {
c = getch();
} while (c == SS$_NORMAL);
return c;
}
You can put those two functions together, ofcourse. Before you use this
function with smg$read_keystroke, you have to initialize the
keyboard in a int function, or in some fuction, were you make your inits.
Just put in the line:
#include smgdef
.
.
.
main()
{
.
.
.
unsigned long kbid;
smg$create_virtual_keyboard(&kbid);
.
.
.
}
If you dont know the keys Names for smg, just read the smgdef.h in syslib.
There you can see all names of the dec keys...
Andreasw
a...@wnvax.wupper.de
--
Andreas W. Wylach -- a...@ifwb.wupper.de -- IfwB Wuppertal -- Germany
-- Informationsystem from students for students | WupperNet --
-- you don't vax me like you used to **BREAK** --
I think I posted a response a couple of days ago. Maybe it got
lost.
The problem with the original poster was a bug in curses.h.
curses.h defines a macro getch that maps to wgetch(stdscr).
wgetch exists. The code to call SMG directly ought not be
necessary.