When getting a location on the map, and using a key to cycle through
next and previous targets, use a menu instead to pick a target.
(default off)
+.lp whatis_moveskip
+When getting a location on the map, and using shifted movement keys or
+meta-digit keys to fast-move, instead of moving 8 units at a time,
+move by skipping the same glyphs.
+(default off)
.lp windowtype
Select which windowing system to use, such as ``tty'' or ``X11''
(default depends on version).
When asked for a location, the key to go to previous closest object. Default is 'O'.
.lp getpos.menu
When asked for a location, and using one of the next or previous keys to cycle through targets, toggle showing a menu instead. Default is '!'.
+.lp getpos.moveskip
+When asked for a location, and using the shifted movement keys or meta-digit keys to fast-move around, move by skipping the same glyphs instead of by 8 units. Default is '*'.
.lp getpos.filter
When asked for a location, change the filtering mode when using one of the next
or previous keys to cycle through targets. Toggles between no filtering, in view
.lp whatis_filter:area
When targeting with cursor, filter possible locations so only those in
the same area (eg. same room, or same corridor) are considered.
+.lp whatis_moveskip
+When targeting with cursor and using fast-move, skip the same glyphs instead
+of moving 8 units at a time.
.lp nostatus_updates
Prevent updates to the status lines at the bottom of the screen, if
your screen-reader reads those lines. The same information can be
next and previous targets, use a menu instead to pick a target.
(default off)
%.lp
+\item[\ib{whatis\verb+_+moveskip}]
+When getting a location on the map, and using shifted movement keys or
+meta-digit keys to fast-move, instead of moving 8 units at a time,
+move by skipping the same glyphs.
+(default off)
+%.lp
\item[\ib{windowtype}]
Select which windowing system to use, such as ``{\tt tty}'' or ``{\tt X11}''
(default depends on version).
\item{\bb{getpos.menu}}
When asked for a location, and using one of the next or previous keys to cycle through targets, toggle showing a menu instead. Default is '{\tt !}'.
%.lp
+\item{\bb{getpos.moveskip}}
+When asked for a location, and using the shifted movement keys or meta-digit keys to fast-move around, move by skipping the same glyphs instead of by 8 units. Default is ``{\tt *}''.
+%.lp
\item{\bb{getpos.filter}}
When asked for a location, change the filtering mode when using one of the next or previous keys to cycle through targets. Toggles between no filtering, in view only, and in the same area only. Default is '{\tt "}'.
%.lp
When targeting with cursor, filter possible locations so only those in
the same area (eg. same room, or same corridor) are considered.
%.lp
+\item[\ib{whatis\verb+_+moveskip}]
+When targeting with cursor and using fast-move, skip the same glyphs instead
+of moving 8 units at a time.
+%.lp
\item[\ib{nostatus\verb+_+updates}]
Prevent updates to the status lines at the bottom of the screen, if
your screen-reader reads those lines. The same information can be
boolean getloc_travelmode;
int getloc_filter; /* GFILTER_foo */
boolean getloc_usemenu;
+ boolean getloc_moveskip;
coord travelcc; /* coordinates for travel_cache */
boolean window_inited; /* true if init_nhwindows() completed */
boolean vision_inited; /* true if vision is ready */
NHKF_GETPOS_HELP,
NHKF_GETPOS_MENU,
NHKF_GETPOS_LIMITVIEW,
+ NHKF_GETPOS_MOVESKIP,
NUM_NHKF
};
{ NHKF_GETPOS_INTERESTING_PREV, 'A', "getpos.all.prev" },
{ NHKF_GETPOS_HELP, '?', "getpos.help" },
{ NHKF_GETPOS_LIMITVIEW, '"', "getpos.filter" },
+ { NHKF_GETPOS_MOVESKIP, '*', "getpos.moveskip" },
{ NHKF_GETPOS_MENU, '!', "getpos.menu" }
};
char sbuf[BUFSZ];
boolean doing_what_is;
winid tmpwin = create_nhwindow(NHW_MENU);
+ const char *const fastmovemode[2] = { "8 units at a time",
+ "skipping same glyphs" };
Sprintf(sbuf,
"Use '%c', '%c', '%c', '%c' to move the cursor to %s.", /* hjkl */
Cmd.move_W, Cmd.move_S, Cmd.move_N, Cmd.move_E, goal);
putstr(tmpwin, 0, sbuf);
- putstr(tmpwin, 0,
- "Use 'H', 'J', 'K', 'L' to move the cursor 8 units at a time.");
+ Sprintf(sbuf,
+ "Use 'H', 'J', 'K', 'L' to fast-move the cursor, %s.",
+ fastmovemode[iflags.getloc_moveskip]);
+ putstr(tmpwin, 0, sbuf);
putstr(tmpwin, 0, "Or enter a background symbol (ex. '<').");
Sprintf(sbuf, "Use '%s' to move the cursor on yourself.",
visctrl(Cmd.spkeys[NHKF_GETPOS_SELF]));
visctrl(Cmd.spkeys[NHKF_GETPOS_INTERESTING_PREV]),
GLOC_INTERESTING);
}
+ Sprintf(sbuf, "Use '%s' to change fast-move mode to %s.",
+ visctrl(Cmd.spkeys[NHKF_GETPOS_MOVESKIP]),
+ fastmovemode[!iflags.getloc_moveskip]);
+ putstr(tmpwin, 0, sbuf);
+
Sprintf(sbuf, "Use '%s' to toggle menu listing for possible targets.",
visctrl(Cmd.spkeys[NHKF_GETPOS_MENU]));
putstr(tmpwin, 0, sbuf);
} else if (Cmd.alphadirchars[i] == lowc((char) c)
|| (Cmd.num_pad && Cmd.dirchars[i] == (c & 0177))) {
/* a shifted movement letter or Meta-digit */
- dx = 8 * xdir[i];
- dy = 8 * ydir[i];
+ if (iflags.getloc_moveskip) {
+ /* skip same glyphs */
+ int glyph = glyph_at(cx, cy);
+
+ dx = xdir[i];
+ dy = ydir[i];
+ while (isok(cx + dx, cy + dy)
+ && glyph == glyph_at(cx + dx, cy + dy)
+ && isok(cx + dx+xdir[i], cy+dy+ydir[i])
+ && glyph == glyph_at(cx + dx+xdir[i], cy + dy+ydir[i])) {
+ dx += xdir[i];
+ dy += ydir[i];
+ }
+ } else {
+ dx = 8 * xdir[i];
+ dy = 8 * ydir[i];
+ }
} else
continue;
cx = u.ux;
cy = u.uy;
goto nxtc;
+ } else if (c == Cmd.spkeys[NHKF_GETPOS_MOVESKIP]) {
+ iflags.getloc_moveskip = !iflags.getloc_moveskip;
+ pline("%skipping over similar terrain when fastmoving the cursor.",
+ iflags.getloc_moveskip ? "S" : "Not s");
} else if ((cp = index(mMoOdDxX, c)) != 0) { /* 'm|M', 'o|O', &c */
/* nearest or farthest monster or object or door or unexplored */
int gtmp = (int) (cp - mMoOdDxX), /* 0..7 */
{ "vt_tiledata", (boolean *) 0, FALSE, SET_IN_FILE },
#endif
{ "whatis_menu", &iflags.getloc_usemenu, FALSE, SET_IN_GAME },
+ { "whatis_moveskip", &iflags.getloc_moveskip, FALSE, SET_IN_GAME },
{ "wizweight", &iflags.wizweight, FALSE, SET_IN_WIZGAME },
{ "wraptext", &iflags.wc2_wraptext, FALSE, SET_IN_GAME },
#ifdef ZEROCOMP