Ticket #2164: clarify cursor position in mcviewer.

When viewing a file, the cursor's position is different in the slang
and ncurses builds.

With slang, the cursor is in the upper right corner, on the percent sign.

With ncurses, the cursor wraps around to the beginning of the next line,
that is, the top left corner of the actual file contents viewing area.

In this commit, cursor is moved to upper right corner unconditionally
after print of percentage value.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2013-06-17 10:11:08 +04:00
parent 805bb61c2a
commit e066a25cc5

View File

@ -420,6 +420,8 @@ mcview_percent (mcview_t * view, off_t p)
widget_move (view, top, right - 4);
tty_printf ("%3d%%", percent);
/* avoid cursor wrapping in NCurses-base MC */
widget_move (view, top, right - 1);
}
/* --------------------------------------------------------------------------------------------- */