*/
struct term_data
{
- term t;
+ term_type t;
infofnt *fnt;
infowin *win;
#ifndef USE_XFT
{
bool select; /* The selection is currently in use. */
bool drawn; /* The selection is currently displayed. */
- term *t; /* The window where the selection is found. */
+ term_type *t; /* The window where the selection is found. */
co_ord init; /* The starting co-ordinates. */
co_ord cur; /* The end co-ordinates (the current ones if still copying). */
co_ord old; /* The previous end co-ordinates. */
#ifdef USE_XIM
if(!valid_keysym){
- for (i = 0; buf[i]; i++) Term_keypress(buf[i]);
+ for (i = 0; buf[i]; i++) term_key_push(buf[i]);
return;
}
mx = (ev->state & Mod2Mask) ? TRUE : FALSE;
if (n && !mo && !mx && !IsSpecialKey(ks))
{
- for (i = 0; buf[i]; i++) Term_keypress(buf[i]);
+ for (i = 0; buf[i]; i++) term_key_push(buf[i]);
return;
}
{
case XK_Escape:
{
- Term_keypress(ESCAPE);
+ term_key_push(ESCAPE);
return;
}
case XK_Return:
{
- Term_keypress('\r');
+ term_key_push('\r');
return;
}
case XK_Tab:
{
- Term_keypress('\t');
+ term_key_push('\t');
return;
}
case XK_Delete:
{
- Term_keypress(0x7f);
+ term_key_push(0x7f);
return;
}
case XK_BackSpace:
{
- Term_keypress('\010');
+ term_key_push('\010');
return;
}
}
ev->keycode, 13);
}
- for (i = 0; msg[i]; i++) Term_keypress(msg[i]);
+ for (i = 0; msg[i]; i++) term_key_push(msg[i]);
if (n && (macro_find_exact(msg) < 0))
{
*/
static void mark_selection_clear(int x1, int y1, int x2, int y2)
{
- Term_redraw_section(x1,y1,x2,y2);
+ term_redraw_section(x1,y1,x2,y2);
}
/*
static void mark_selection(void)
{
co_ord min, max;
- term *old = Term;
+ term_type *old = Term;
bool draw = s_ptr->select;
bool clear = s_ptr->drawn;
- if (s_ptr->t != old) Term_activate(s_ptr->t);
+ if (s_ptr->t != old) term_activate(s_ptr->t);
if (clear)
{
mark_selection_mark(min.x, min.y, max.x, max.y);
}
- if (s_ptr->t != old) Term_activate(old);
+ if (s_ptr->t != old) term_activate(old);
s_ptr->old.x = s_ptr->cur.x;
s_ptr->old.y = s_ptr->cur.y;
#ifdef JP
if (x > max.x) break;
- Term_what(x, y, &a, &c);
+ term_what(x, y, &a, &c);
if (1 == kanji) kanji = 2;
else if (iskanji(c)) kanji = 1;
else kanji = 0;
if (x > max.x) break;
if (x < min.x) continue;
- Term_what(x, y, &a, &c);
+ term_what(x, y, &a, &c);
#endif
buf[l] = c;
if (!td || !iwin) return (0);
- Term_activate(&td->t);
+ term_activate(&td->t);
Infowin_set(iwin);
switch (xev->type)
{
}
case KeyPress:
{
- Term_activate(&old_td->t);
+ term_activate(&old_td->t);
react_keypress(&(xev->xkey));
break;
}
y2 = (xev->xexpose.y + xev->xexpose.height -
Infowin->oy)/Infofnt->hgt;
- Term_redraw_section(x1, y1, x2, y2);
+ term_redraw_section(x1, y1, x2, y2);
break;
}
case MapNotify:
wid = cols * td->fnt->wid + (ox + ox);
hgt = rows * td->fnt->hgt + (oy + oy);
- Term_resize(cols, rows);
+ term_resize(cols, rows);
if ((Infowin->w != wid) || (Infowin->h != hgt))
{
Infowin_set(td->win);
#endif
}
- Term_activate(&old_td->t);
+ term_activate(&old_td->t);
Infowin_set(old_td->win);
return (0);
}
*/
static errr term_data_init(term_data *td, int i)
{
- term *t = &td->t;
+ term_type *t = &td->t;
concptr name = angband_term_name[i];
t->wipe_hook = Term_wipe_x11;
t->text_hook = Term_text_x11;
t->data = td;
- Term_activate(t);
+ term_activate(t);
return (0);
}
Infowin_set(data[0].win);
Infowin_raise();
- Term_activate(&data[0].t);
+ term_activate(&data[0].t);
#ifdef USE_XIM
{
for (i = 0; i < num_term; i++)
{
term_data *td = &data[i];
- term *t = &td->t;
+ term_type *t = &td->t;
t->pict_hook = Term_pict_x11;
t->higher_pict = TRUE;
td->tiles =