summaryrefslogtreecommitdiffstats
path: root/scripts/kconfig/nconf.h
diff options
context:
space:
mode:
authorJesse Taube <mr.bossman075@gmail.com>2023-08-08 20:42:20 -0400
committerMasahiro Yamada <masahiroy@kernel.org>2023-08-13 21:29:41 +0900
commit1ba67cd3281e50a965c5b519f946b14a1c4620a7 (patch)
treef7bf4f8f939416d93e60f44714bf3cc5405f266e /scripts/kconfig/nconf.h
parent01e89a4acefc9d8356e91dde310da11e5b97d22d (diff)
downloadlinux-1ba67cd3281e50a965c5b519f946b14a1c4620a7.tar.gz
linux-1ba67cd3281e50a965c5b519f946b14a1c4620a7.tar.bz2
linux-1ba67cd3281e50a965c5b519f946b14a1c4620a7.zip
kconfig: nconf: Add search jump feature
Menuconfig has a feature where you can "press the key in the (#) prefix to jump directly to that location. You will be returned to the current search results after exiting this new menu." This commit adds this feature to nconfig, with almost identical code. Signed-off-by: Jesse Taube <Mr.Bossman075@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Tested-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Diffstat (limited to 'scripts/kconfig/nconf.h')
-rw-r--r--scripts/kconfig/nconf.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/kconfig/nconf.h b/scripts/kconfig/nconf.h
index 6f925bc74eb3..ab836d582664 100644
--- a/scripts/kconfig/nconf.h
+++ b/scripts/kconfig/nconf.h
@@ -67,6 +67,8 @@ typedef enum {
void set_colors(void);
+typedef int (*extra_key_cb_fn)(int, size_t, size_t, void *);
+
/* this changes the windows attributes !!! */
void print_in_middle(WINDOW *win, int y, int width, const char *str, int attrs);
int get_line_length(const char *line);
@@ -78,6 +80,9 @@ int dialog_inputbox(WINDOW *main_window,
const char *title, const char *prompt,
const char *init, char **resultp, int *result_len);
void refresh_all_windows(WINDOW *main_window);
+int show_scroll_win_ext(WINDOW *main_window, const char *title, char *text,
+ int *vscroll, int *hscroll,
+ extra_key_cb_fn extra_key_cb, void *data);
void show_scroll_win(WINDOW *main_window,
const char *title,
const char *text);