Lines Matching +full:- +full:n
1 // SPDX-License-Identifier: GPL-2.0
3 * Copyright (C) 2002 Roman Zippel <zippel@linux-m68k.org>
5 * Introduced single menu mode (show all sub-menus in one large tree).
6 * 2002-11-06 Petr Baudis <pasky@ucw.cz>
26 #include "mnconf-common.h"
29 "Overview\n"
30 "--------\n"
31 "This interface lets you select features and parameters for the build.\n"
32 "Features can either be built-in, modularized, or ignored. Parameters\n"
33 "must be entered in as decimal or hexadecimal numbers or text.\n"
34 "\n"
35 "Menu items beginning with following braces represent features that\n"
36 " [ ] can be built in or removed\n"
37 " < > can be built in, modularized or removed\n"
38 " { } can be built in or modularized (selected by other feature)\n"
39 " - - are selected by other feature,\n"
40 "while *, M or whitespace inside braces means to build in, build as\n"
41 "a module or to exclude the feature respectively.\n"
42 "\n"
43 "To change any of these features, highlight it with the cursor\n"
44 "keys and press <Y> to build it in, <M> to make it a module or\n"
45 "<N> to remove it. You may also press the <Space Bar> to cycle\n"
46 "through the available options (i.e. Y->N->M->Y).\n"
47 "\n"
48 "Some additional keyboard hints:\n"
49 "\n"
50 "Menus\n"
51 "----------\n"
52 "o Use the Up/Down arrow keys (cursor keys) to highlight the item you\n"
53 " wish to change or the submenu you wish to select and press <Enter>.\n"
54 " Submenus are designated by \"--->\", empty ones by \"----\".\n"
55 "\n"
56 " Shortcut: Press the option's highlighted letter (hotkey).\n"
57 " Pressing a hotkey more than once will sequence\n"
58 " through all visible items which use that hotkey.\n"
59 "\n"
60 " You may also use the <PAGE UP> and <PAGE DOWN> keys to scroll\n"
61 " unseen options into view.\n"
62 "\n"
63 "o To exit a menu use the cursor keys to highlight the <Exit> button\n"
64 " and press <ENTER>.\n"
65 "\n"
66 " Shortcut: Press <ESC><ESC> or <E> or <X> if there is no hotkey\n"
67 " using those letters. You may press a single <ESC>, but\n"
68 " there is a delayed response which you may find annoying.\n"
69 "\n"
70 " Also, the <TAB> and cursor keys will cycle between <Select>,\n"
71 " <Exit>, <Help>, <Save>, and <Load>.\n"
72 "\n"
73 "o To get help with an item, use the cursor keys to highlight <Help>\n"
74 " and press <ENTER>.\n"
75 "\n"
76 " Shortcut: Press <H> or <?>.\n"
77 "\n"
78 "o To toggle the display of hidden options, press <Z>.\n"
79 "\n"
80 "\n"
81 "Radiolists (Choice lists)\n"
82 "-----------\n"
83 "o Use the cursor keys to select the option you wish to set and press\n"
84 " <S> or the <SPACE BAR>.\n"
85 "\n"
86 " Shortcut: Press the first letter of the option you wish to set then\n"
87 " press <S> or <SPACE BAR>.\n"
88 "\n"
89 "o To see available help for the item, use the cursor keys to highlight\n"
90 " <Help> and Press <ENTER>.\n"
91 "\n"
92 " Shortcut: Press <H> or <?>.\n"
93 "\n"
94 " Also, the <TAB> and cursor keys will cycle between <Select> and\n"
95 " <Help>\n"
96 "\n"
97 "\n"
98 "Data Entry\n"
99 "-----------\n"
100 "o Enter the requested information and press <ENTER>\n"
101 " If you are entering hexadecimal values, it is not necessary to\n"
102 " add the '0x' prefix to the entry.\n"
103 "\n"
104 "o For help, use the <TAB> or cursor keys to highlight the help option\n"
105 " and press <ENTER>. You can try <TAB><H> as well.\n"
106 "\n"
107 "\n"
108 "Text Box (Help Window)\n"
109 "--------\n"
110 "o Use the cursor keys to scroll up/down/left/right. The VI editor\n"
111 " keys h,j,k,l function here as do <u>, <d>, <SPACE BAR> and <B> for\n"
112 " those who are familiar with less and lynx.\n"
113 "\n"
114 "o Press <E>, <X>, <q>, <Enter> or <Esc><Esc> to exit.\n"
115 "\n"
116 "\n"
117 "Alternate Configuration Files\n"
118 "-----------------------------\n"
119 "Menuconfig supports the use of alternate configuration files for\n"
120 "those who, for various reasons, find it necessary to switch\n"
121 "between different configurations.\n"
122 "\n"
123 "The <Save> button will let you save the current configuration to\n"
124 "a file of your choosing. Use the <Load> button to load a previously\n"
125 "saved alternate configuration.\n"
126 "\n"
127 "Even if you don't use alternate configuration files, but you find\n"
128 "during a Menuconfig session that you have completely messed up your\n"
129 "settings, you may use the <Load> button to restore your previously\n"
130 "saved settings from \".config\" without restarting Menuconfig.\n"
131 "\n"
132 "Other information\n"
133 "-----------------\n"
134 "If you use Menuconfig in an XTERM window, make sure you have your\n"
135 "$TERM variable set to point to an xterm definition which supports\n"
136 "color. Otherwise, Menuconfig will look rather bad. Menuconfig will\n"
137 "not display correctly in an RXVT window because rxvt displays only one\n"
138 "intensity of color, bright.\n"
139 "\n"
140 "Menuconfig will display larger menus on screens or xterms which are\n"
141 "set to display more than the standard 25 row by 80 column geometry.\n"
142 "In order for this to work, the \"stty size\" command must be able to\n"
143 "display the screen's current row and column geometry. I STRONGLY\n"
144 "RECOMMEND that you make sure you do NOT have the shell variables\n"
145 "LINES and COLUMNS exported into your environment. Some distributions\n"
146 "export those variables via /etc/profile. Some ncurses programs can\n"
147 "become confused when those variables (LINES & COLUMNS) don't reflect\n"
148 "the true screen size.\n"
149 "\n"
150 "Optional personality available\n"
151 "------------------------------\n"
152 "If you prefer to have all of the options listed in a single menu,\n"
153 "rather than the default multimenu hierarchy, run the menuconfig with\n"
154 "MENUCONFIG_MODE environment variable set to single_menu. Example:\n"
155 "\n"
156 "make MENUCONFIG_MODE=single_menu menuconfig\n"
157 "\n"
158 "<Enter> will then unroll the appropriate category, or enfold it if it\n"
159 "is already unrolled.\n"
160 "\n"
161 "Note that this mode can eventually be a little more CPU expensive\n"
162 "(especially with a larger number of unrolled categories) than the\n"
163 "default mode.\n"
164 "\n"
166 "Search\n"
167 "-------\n"
168 "Pressing the forward-slash (/) anywhere brings up a search dialog box.\n"
169 "\n"
171 "Different color themes available\n"
172 "--------------------------------\n"
173 "It is possible to select different color themes using the variable\n"
174 "MENUCONFIG_COLOR. To select a theme use:\n"
175 "\n"
176 "make MENUCONFIG_COLOR=<theme> menuconfig\n"
177 "\n"
178 "Available themes are\n"
179 " mono => selects colors suitable for monochrome displays\n"
180 " blackbg => selects a color scheme with black background\n"
181 " classic => theme with blue background. The classic look\n"
182 " bluetitle => an LCD friendly version of classic. (default)\n"
183 "\n",
186 "<Enter> selects submenus ---> (or empty submenus ----). "
188 "Pressing <Y> includes, <N> excludes, <M> modularizes features. "
190 "Legend: [*] built-in [ ] excluded <M> module < > module capable",
207 "This feature depends on another which has been configured as a module.\n"
214 "\n"
215 "For various reasons, one may wish to keep several different\n"
216 "configurations available on a single machine.\n"
217 "\n"
218 "If you have saved a previous configuration in a file other than the\n"
219 "default one, entering its name here will allow you to modify that\n"
220 "configuration.\n"
221 "\n"
222 "If you are uncertain, then you have probably never used alternate\n"
223 "configuration files. You should therefore leave this blank to abort.\n",
228 "\n"
229 "For various reasons, one may wish to keep different configurations\n"
230 "available on a single machine.\n"
231 "\n"
232 "Entering a file name here will allow you to later retrieve, modify\n"
233 "and use the current configuration as an alternate to whatever\n"
234 "configuration options you have selected at that time.\n"
235 "\n"
236 "If you are uncertain what all this means then you should probably\n"
237 "leave this blank.\n",
239 "\n"
240 "Search for symbols and display their relations.\n"
241 "Regular expressions are allowed.\n"
242 "Example: search for \"^FOO\"\n"
243 "Result:\n"
244 "-----------------------------------------------------------------\n"
245 "Symbol: FOO [=m]\n"
246 "Type : tristate\n"
247 "Prompt: Foo bus is used to drive the bar HW\n"
248 " Location:\n"
249 " -> Bus options (PCI, PCMCIA, EISA, ISA)\n"
250 " -> PCI support (PCI [=y])\n"
251 "(1) -> PCI access mode (<choice> [=y])\n"
252 " Defined at drivers/pci/Kconfig:47\n"
253 " Depends on: X86_LOCAL_APIC && X86_IO_APIC\n"
254 " Selects: LIBCRC32\n"
255 " Selected by: BAR [=n]\n"
256 "-----------------------------------------------------------------\n"
257 "o The line 'Type:' shows the type of the configuration option for\n"
258 " this symbol (bool, tristate, string, ...)\n"
259 "o The line 'Prompt:' shows the text used in the menu structure for\n"
260 " this symbol\n"
261 "o The 'Defined at' line tells at what file / line number the symbol\n"
262 " is defined\n"
263 "o The 'Depends on:' line tells what symbols need to be defined for\n"
264 " this symbol to be visible in the menu (selectable)\n"
265 "o The 'Location:' lines tells where in the menu structure this symbol\n"
266 " is located\n"
267 " A location followed by a [=y] indicates that this is a\n"
268 " selectable menu item - and the current value is displayed inside\n"
269 " brackets.\n"
270 " Press the key in the (#) prefix to jump directly to that\n"
271 " location. You will be returned to the current search results\n"
272 " after exiting this new menu.\n"
273 "o The 'Selects:' line tells what symbols will be automatically\n"
274 " selected if this symbol is selected (y or m)\n"
275 "o The 'Selected by' line tells what symbol has selected this symbol\n"
276 "\n"
277 "Only relevant lines are shown.\n"
278 "\n\n"
279 "Search examples:\n"
280 "Examples: USB => find all symbols containing USB\n"
281 " ^USB => find all symbols starting with USB\n"
282 " USB$ => find all symbols ending with USB\n"
283 "\n";
300 snprintf(menu_backtitle, sizeof(menu_backtitle), "%s - %s", in set_config_filename()
301 config_filename, rootmenu.prompt->text); in set_config_filename()
320 tmp = pos->next; in set_subtitle()
326 if (sp->text) { in set_subtitle()
328 pos->next = xcalloc(1, sizeof(*pos)); in set_subtitle()
329 pos = pos->next; in set_subtitle()
333 pos->text = sp->text; in set_subtitle()
345 tmp = pos->next; in reset_subtitle()
376 help.max_width = getmaxx(stdscr) - 10; in show_help()
441 conf(data.target->parent, data.target); in search_conf()
474 sym = menu->sym; in build_conf()
475 prop = menu->prompt; in build_conf()
479 switch (prop->type) { in build_conf()
484 menu->data ? "-->" : "++>", in build_conf()
489 menu_is_empty(menu) ? "----" : "--->"); in build_conf()
492 if (single_menu_mode && menu->data) in build_conf()
506 item_make("---%*c%s", indent + 1, ' ', prompt); in build_conf()
522 for (child = menu->list; child; child = child->next) { in build_conf()
523 if (menu_is_visible(child) && child->sym == def_sym) in build_conf()
533 item_add_str(" (%s) --->", menu_get_prompt(def_menu)); in build_conf()
537 item_make("---%*c%s", indent + 1, ' ', menu_get_prompt(menu)); in build_conf()
549 item_make("-%c-", val == no ? ' ' : '*'); in build_conf()
560 if (sym->rev_dep.tri == mod) in build_conf()
565 item_make("-%c-", ch); in build_conf()
572 tmp = indent - tmp + 4; in build_conf()
585 if (menu->prompt->type == P_MENU) { in build_conf()
586 item_add_str(" %s", menu_is_empty(menu) ? "----" : "--->"); in build_conf()
593 for (child = menu->list; child; child = child->next) in build_conf()
595 indent -= doint; in build_conf()
611 for (child = menu->list; child; child = child->next) { in conf_choice()
614 if (child->sym) in conf_choice()
621 if (child->sym == active) in conf_choice()
623 if (child->sym == sym_calc_choice(menu)) in conf_choice()
637 if (!child->sym) in conf_choice()
640 choice_set_value(menu, child->sym); in conf_choice()
647 active = child->sym; in conf_choice()
653 case -ERRDISPLAYTOOSMALL: in conf_choice()
667 switch (sym_get_type(menu->sym)) { in conf_string()
683 sym_get_string_value(menu->sym)); in conf_string()
686 if (sym_set_string_value(menu->sym, dialog_input_result)) in conf_string()
779 if (res == 1 || res == KEY_ESC || res == -ERRDISPLAYTOOSMALL) in conf()
790 sym = submenu->sym; in conf()
799 submenu->data = (void *) (long) !submenu->data; in conf()
806 else if (submenu->prompt->type == P_MENU) in conf()
883 "Do you wish to save your new configuration?\n" in handle_exit()
887 res = -1; in handle_exit()
894 fprintf(stderr, "\n\n" in handle_exit()
895 "Error while writing of the configuration.\n" in handle_exit()
897 "\n\n"); in handle_exit()
902 case -1: in handle_exit()
904 printf("\n\n" in handle_exit()
905 "*** End of the configuration.\n" in handle_exit()
907 "\n\n"); in handle_exit()
912 fprintf(stderr, "\n\n" in handle_exit()
914 "\n\n"); in handle_exit()
934 if (ac > 1 && strcmp(av[1], "-s") == 0) { in main()
950 fprintf(stderr, "Your display is too small to run Menuconfig!\n"); in main()
951 fprintf(stderr, "It must be at least 19 lines by 80 columns.\n"); in main()