aboutsummaryrefslogtreecommitdiff
path: root/scripts/kconfig/lxdialog/util.c
AgeCommit message (Collapse)AuthorFilesLines
2024-05-14kconfig: lxdialog: remove initialization with A_NORMALMasahiro Yamada1-9/+0
A_NORMAL is zero, so the attribute is set to the default A_NORMAL without explicit assignment. Signed-off-by: Masahiro Yamada <[email protected]>
2024-03-31kconfig: Fix typo HEIGTH to HEIGHTIsak Ellmer1-1/+1
Fixed a typo in some variables where height was misspelled as heigth. Signed-off-by: Isak Ellmer <[email protected]> Signed-off-by: Masahiro Yamada <[email protected]>
2024-03-19kconfig: lxdialog: remove unused dialog colorsMasahiro Yamada1-18/+0
Remove inputbox_order, searchbox, searchbox_title, searchbox_border because they are initialized, but not used anywhere. Signed-off-by: Masahiro Yamada <[email protected]>
2024-03-19kconfig: lxdialog: fix button color for blackbg themeMasahiro Yamada1-1/+1
For MENUCONFIG_COLOR=blackbg, the text in inactive buttons is invisible because both the foreground and background are black. Change the foreground color to white and remove the highlighting. Signed-off-by: Masahiro Yamada <[email protected]>
2021-04-14kconfig: lxdialog: A spello fix and a punctuation addedBhaskar Chowdhury1-2/+2
s/propperly/properly/ s/thats/that\'s/ Signed-off-by: Bhaskar Chowdhury <[email protected]> Signed-off-by: Masahiro Yamada <[email protected]>
2018-12-28kconfig: convert to SPDX License IdentifierMasahiro Yamada1-14/+1
All files in lxdialog/ are licensed under GPL-2.0+, and the rest are under GPL-2.0. I added GPL-2.0 tags to test scripts in tests/. Documentation/process/license-rules.rst does not suggest anything about the flex/bison files. Because flex does not accept the C++ comment style at the very top of a file, I used the C style for zconf.l, and so for zconf.y for consistency. Signed-off-by: Masahiro Yamada <[email protected]>
2014-06-10kbuild: trivial - use tabs for code indent where possibleMasahiro Yamada1-1/+1
Signed-off-by: Masahiro Yamada <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2013-06-18mconf: use function calls instead of ncurses' variables LINES and COLSDirk Gouders1-4/+9
According to the documentation [1], LINES and COLS are initialized by initscr(); it does not say anything about the behavior when windows are resized. Do not rely on the current implementation of ncurses that updates these variables on resize, but use the propper function calls to get window dimensions. init_dialog() could make use of the variables, but for the sake of consistency we do not change it's current use of the macro getmaxyx(). [1] ncurses(3X) Signed-off-by: Dirk Gouders <[email protected]> Tested-by: "Yann E. MORIN" <[email protected]> Reviewed-by: "Yann E. MORIN" <[email protected]> Signed-off-by: Yann E. MORIN <[email protected]>
2013-06-18kconfig/lxdialog: handle newline characters in print_autowrap()Dirk Gouders1-14/+17
When exiting menuconfig with unsaved changes, a dialog like the following is shown: Do you wish to save your new configuration ? <ESC><ESC> to continue. The author of the dialog text specified a newline after the '?', and probably expected it to be processed, so let print_autowrap() handle newlines propperly. Also, reword that dialog's second phrase with a real sentence. Signed-off-by: Dirk Gouders <[email protected]> Tested-by: "Yann E. MORIN" <[email protected]> Reviewed-by: "Yann E. MORIN" <[email protected]> [[email protected]: very slightly tweak the commit message] Signed-off-by: Yann E. MORIN <[email protected]>
2013-06-16kconfig/lxdialog: Add definitions for mininimum (re)size valuesSedat Dilek1-1/+1
Commit c8dc68ad0fbd ("kconfig/lxdialog: support resize") added support for resizing, but forgot to collect all hardcoded values at one single place. Also add a definition for the check for a minimum screen/window size of 80x19. [ ChangeLog v3: * Rename MENU_{HEIGTH,WIDTH}_MIN -> MENUBOX_{HEIGTH,WIDTH}_MIN ChangeLog v2: * Rename WIN_{HEIGTH,WIDTH}_MIN -> WINDOW_{HEIGTH,WIDTH}_MIN * Mention the check for a minimum screen/window size in the changelog * Add a comment above the block of new definitions ] Signed-off-by: Sedat Dilek <[email protected]> Acked-by: Wang YanQing <[email protected]> Tested-by: "Yann E. MORIN" <[email protected]> Reviewed-by: "Yann E. MORIN" <[email protected]> Signed-off-by: "Yann E. MORIN" <[email protected]>
2013-04-16menuconfig: Add "breadcrumbs" navigation aidBenjamin Poirier1-2/+43
Displays a trail of the menu entries used to get to the current menu. Signed-off-by: Benjamin Poirier <[email protected]> Tested-by: "Yann E. MORIN" <[email protected]> [[email protected]: small, trivial code re-ordering] Signed-off-by: "Yann E. MORIN" <[email protected]>
2012-08-30kconfig/mconf.c: revision of curses initialization.Dirk Gouders1-0/+7
Since commit d0e1e09568 initscr() is called twice in mconf. Do it only in init_dialog() in util.c and there also save the cursor position for the signal handler in mconf.c. Signed-off-by: Dirk Gouders <[email protected]> Signed-off-by: Michal Marek <[email protected]>
2009-07-17kconfig: variable argument lists needs `stdarg.h'Arnaud Lacombe1-0/+2
Fix build on non GNU based platforms. Cc: Roman Zippel <[email protected]> Signed-off-by: Sam Ravnborg <[email protected]>
2008-01-28kconfig: make kconfig MinGW friendlyLadislav Michl1-11/+21
Kconfig is powerfull tool. So powerfull that more and more software projects are using it for configuration. So instead of fixing some of them one by one, lets fix it in kernel and wait for sync. This work was originaly done for PTXdist - GPL licensed build system for userlands and cross-compilers, but it will not hurt kernel kconfig either. PTXdist menuconfig now works on Windows linked with PDCurses and compiled using MinGW - there is no termios and signals. * Do not include <sys/wait.h> and <signal.h> (comes from times when lxdialog was separate process) * Do not mess with termios directly and let curses tell screen size. Comment to commit c8dc68ad0fbd934e78e913b8a8d7b45945db4930 says check for screen size could be removed later, but because it didn't happen for more than year I left it here as well. * Save cursor position added by Sam Signed-off-by: Ladislav Michl <[email protected]> Signed-off-by: Sam Ravnborg <[email protected]> Cc: Roman Zippel <[email protected]>
2007-05-02menuconfig: remember alternate config filenameSam Ravnborg1-0/+5
When loading an alternate configuration use that file as current configuration filename. Make the filename visible in the dialog. Default continue to be .config. Inspired by patch from: Cyrill Gorcunov <[email protected]> Signed-off-by: Sam Ravnborg <[email protected]> Cc: Cyrill Gorcunov <[email protected]>
2007-05-02menuconfig: dont use obsolete index() function in lxdialogMike Frysinger1-2/+2
The index() function is obsolete, use strchr() instead. Signed-off-by: Mike Frysinger <[email protected]> Signed-off-by: Sam Ravnborg <[email protected]>
2006-11-25[PATCH] fix menuconfig colours with TERM=vt100Roman Zippel1-9/+7
On Mon, 13 Nov 2006, Phil Oester wrote: > In commit 350b5b76384e77bcc58217f00455fdbec5cac594, the default menuconfig > color scheme was changed to bluetitle. This breaks the highlighting > of the selected item for me with TERM=vt100. The only way I can see > which item is selected is via: > > make MENUCONFIG_COLOR=mono menuconfig > > Which restores the pre-2.6.19 white on black highlighting. Fix. Cc: Phil Oester <[email protected]> Signed-off-by: Roman Zippel <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2006-09-30kconfig/lxdialog: support resizeSam Ravnborg1-0/+6
In all dialogs now properly catch KEY_RESIZE and take proper action. In mconf try to behave sensibly when a dialog routine returns -ERRDISPLAYTOOSMALL. The original check for a screnn size of 80x19 is kept for now. It may make sense to remove it later, but thats anyway what much text is adjusted for. Signed-off-by: Sam Ravnborg <[email protected]>
2006-09-30kconfig/lxdialog: let <ESC><ESC> behave as expectedSam Ravnborg1-0/+33
<ESC><ESC> is used to step one back in the dialogs. When lxdialog became built-in pressing <ESC> once would cause one step back and pressing <ESC><ESC> would cause two steps back. This patch - based on concept from Roman Zippel <[email protected]> - makes one <ESC> a noop and pressing <ESC><ESC> will cause one step backward. In addition the final yes/no dialog now has the option to go back to the the kernel configuration. So if you get too far out you can now go back to configuring the kernel without saving and starting all over again. Signed-off-by: Sam Ravnborg <[email protected]>
2006-09-30kconfig/menuconfig: lxdialog is now built-inSam Ravnborg1-2/+132
lxdialog was previously called as an external program causing screen to flicker when used. With this patch lxdialog is now built-in. It is loosly based om previous work by: Petr Baudis <[email protected]> Following is a list of changes: o Moved build of dialog routings to kconfig Makefile o menubox + checklist uses a new item list to hold all menu items o in util.c implmented helper function to deal with item list o menubox now uses parameters to save scroll state (avoids temp file) o textbox now get text to be displayed as parameter and not a file o make sure to properly delete subwin's before main windows o killed unused files: lxdialog.c msgbox.c o modified return value for ESC to match direct calling o in a few places the code has been adjusted to 80 char wide o in textbox a small refactoring was made to make code remotely readable o in mconf removed all unused stuff (functions/variables) Following is a list of know short comings: a) pressing ESC twice will be interpreted as two ESC presses b) resize does not work. menuconfig needs to be restarted to be adjusted Signed-off-by: Sam Ravnborg <[email protected]>
2006-09-30kconfig/lxdialog: add a new theme bluetitle which is now defaultSam Ravnborg1-1/+16
The bluetitle theme is a slightly modified version of the colorscheme that -mm users has been used to. The bluetitle is more readable especially on some LCD screens so it is now default. Anyone that really wants the old color selection can get it by selecting the classic color theme: make MENUCONFIG_COLOR=classic menuconfig The bluetitle theme was modified by Roman Zippel <[email protected]> to further improve readability on LCD screens. Signed-off-by: Sam Ravnborg <[email protected]>
2006-09-30kconfig/lxdialog: add support for color themes and add blackbg themeSam Ravnborg1-6/+67
The blackbg theme was originally made by: Han Boetes It was copied from a patch by "Randy.Dunlap" <[email protected]> which was also the inspiration source for the color theme support. Signed-off-by: Sam Ravnborg <[email protected]>
2006-09-30kconfig/lxdialog: refactor color supportSam Ravnborg1-112/+147
Clean up and refactor color support. All color support are now in util.c including color definitions. In the process introduced a global variable named 'dlg' which is used all over to set color - thats the reason why all files are changed. Signed-off-by: Sam Ravnborg <[email protected]>
2005-12-16kconfig: move lxdialog to scripts/kconfig/lxdialogSam Ravnborg1-0/+362
The only lxdialog user i kconfig - for menuconfig. So move it to reflect this. Signed-off-by: Sam Ravnborg <[email protected]>