Exemple #1
0
/*
 *	Do the local initialisations. Notice that many things are already done
 *	in vty_init
 */
void vtemul_init()
{
	char	*c,*id = "pc3n";
	XCHAR	*xc;
	Keycap_def	*kp;
	struct Keycap2	*k2;

	/* fill the cons_capabilities structure
	 * Don't use strcpy here!
	 */
	c = id;
	xc = cons_capabilities.emul_name;
	while (*xc++ = xc_char2xc(*c++)) ;

#define copydef(src,dst)\
	xc_bcopy(src,dst,KBDDEFOVLKEYSIZE)

	/* set the function keys new */
	for (k2 = pc3keys; k2->key; k2++) {
		kp = &kbd_keytab[k2->key];
		kp->type = k2->type;
		kp->ovlptr = 0;
		copydef(k2->unshift,kp->unshift);
		copydef(k2->shift,kp->shift);
		copydef(k2->ctrl,kp->ctrl);
	}
}
Exemple #2
0
setdef(s1,s2) {
	copydef(s1);
	df->dtext = de -df;
	copydef(s2); 
}