From 020f40693a08b836abdea74f3823a0bce0378ec5 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Sun, 17 May 2009 16:44:54 +0200 Subject: line editing: add an option to emit ESC [ 6 n and use results This makes line editing able to recognize case when cursor was not at the beginning of the line. It may also be adapted later to find out display size (serial line users would love it). Signed-off-by: Denys Vlasenko --- libbb/Config.in | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'libbb/Config.in') diff --git a/libbb/Config.in b/libbb/Config.in index f5b804ff8..7ced387a9 100644 --- a/libbb/Config.in +++ b/libbb/Config.in @@ -102,6 +102,18 @@ config FEATURE_EDITING_FANCY_PROMPT Setting this option allows for prompts to use things like \w and \$ and escape codes. +config FEATURE_EDITING_ASK_TERMINAL + bool "Query cursor position from terminal" + default n + depends on FEATURE_EDITING + help + Allow usage of "ESC [ 6 n" sequence. Terminal answers back with + current cursor position. This information is used to make line + editing more robust in some cases. + If you are not sure whether your terminals respond to this code + correctly, or want to save on code size (about 300 bytes), + then do not turn this option on. + config FEATURE_VERBOSE_CP_MESSAGE bool "Give more precise messages when copy fails (cp, mv etc)" default n -- cgit v1.2.3