{"id":6747,"date":"2022-12-20T19:33:35","date_gmt":"2022-12-20T22:33:35","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/cursesuilistbox-man3\/"},"modified":"2022-12-20T19:33:35","modified_gmt":"2022-12-20T22:33:35","slug":"cursesuilistbox-man3","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/cursesuilistbox-man3\/","title":{"rendered":"Curses::UI::Listbox (man3)"},"content":{"rendered":"<h1 align=\"center\">Curses::UI::Listbox<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#CLASS HIERARCHY\">CLASS HIERARCHY<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#DESCRIPTION\">DESCRIPTION<\/a><br \/> <a href=\"#STANDARD OPTIONS\">STANDARD OPTIONS<\/a><br \/> <a href=\"#WIDGET-SPECIFIC OPTIONS\">WIDGET-SPECIFIC OPTIONS<\/a><br \/> <a href=\"#METHODS\">METHODS<\/a><br \/> <a href=\"#DEFAULT BINDINGS\">DEFAULT BINDINGS<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a><br \/> <a href=\"#AUTHOR\">AUTHOR<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Curses::UI::Listbox \u2212 Create and manipulate listbox widgets<\/p>\n<h2>CLASS HIERARCHY <a name=\"CLASS HIERARCHY\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Curses::UI::Widget <br \/> Curses::UI::Searchable <br \/> | <br \/> +\u2212\u2212\u2212\u2212Curses::UI::Listbox<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">use Curses::UI; <br \/> my $cui = new Curses::UI; <br \/> my $win = $cui\u2212>add(&#8216;window_id&#8217;, &#8216;Window&#8217;); <br \/> my $listbox = $win\u2212>add( <br \/> &#8216;mylistbox&#8217;, &#8216;Listbox&#8217;, <br \/> \u2212values => [1, 2, 3], <br \/> \u2212labels => { 1 => &#8216;One&#8217;, <br \/> 2 => &#8216;Two&#8217;, <br \/> 3 => &#8216;Three&#8217; }, <br \/> \u2212radio => 1, <br \/> ); <br \/> $listbox\u2212>focus(); <br \/> my $selected = $listbox\u2212>get();<\/p>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Curses::UI::Listbox is a widget that can be used to create a couple of different kinds of listboxes. These are:<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"23%\">\n<p><b>default listbox<\/b><\/p>\n<\/td>\n<td width=\"60%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">A list of values through which can be browsed. One of these values can be selected. The selected value will be highlighted. This kind of listbox looks somewhat like this:<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">+\u2212\u2212\u2212\u2212\u2212\u2212+ <br \/> |One | <br \/> |Two | <br \/> |Three | <br \/> +\u2212\u2212\u2212\u2212\u2212\u2212+<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"31%\">\n<p style=\"margin-top: 1em\"><b>multi-select listbox<\/b><\/p>\n<\/td>\n<td width=\"52%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This is also a list of values, but now more than one value can be selected at once. This kind of listbox looks somewhat like this:<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">+\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212+ <br \/> |[X] One | <br \/> |[ ] Two | <br \/> |[X] Three | <br \/> +\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212+<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><b>radiobutton listbox<\/b><\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This looks a lot like the default listbox (only one value can be selected), but now there is clear visual feedback on which value is selected. Before each value &#8220;< >&#8221; is printed. If a value is selected, &#8220;<o>&#8221; is printed instead. This kind of listbox looks somewhat like this:<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">+\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212+ <br \/> |< > One | <br \/> |<o> Two | <br \/> |< > Three | <br \/> +\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212\u2212+<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"21%\">\n<p style=\"margin-top: 1em\"><b>Listbox Markup<\/b><\/p>\n<\/td>\n<td width=\"62%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">The listbox supports a primitive markup language to emphasize entries: <br \/> <reverse>reverse text<\/reverse> <br \/> <bold>bold text<\/bold> <br \/> <underline>underlined text<\/underline> <br \/> <blink>blinking text<\/blink> <br \/> <dim>dim text<\/dim> By using this markup tokens in the values array, you can make the listbox draw the text in the according way. To enable the parser, you have to create the listbox with the \u2212htmltext option.<\/p>\n<h2>STANDARD OPTIONS <a name=\"STANDARD OPTIONS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>\u2212parent<\/b>, <b>\u2212x<\/b>, <b>\u2212y<\/b>, <b>\u2212width<\/b>, <b>\u2212height<\/b>, <b>\u2212pad<\/b>, <b>\u2212padleft<\/b>, <b>\u2212padright<\/b>, <b>\u2212padtop<\/b>, <b>\u2212padbottom<\/b>, <b>\u2212ipad<\/b>, <b>\u2212ipadleft<\/b>, <b>\u2212ipadright<\/b>, <b>\u2212ipadtop<\/b>, <b>\u2212ipadbottom<\/b>, <b>\u2212title<\/b>, <b>\u2212titlefullwidth<\/b>, <b>\u2212titlereverse<\/b>, <b>\u2212onfocus<\/b>, <b>\u2212onblur<\/b><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">For an explanation of these standard options, see Curses::UI::Widget.<\/p>\n<h2>WIDGET-SPECIFIC OPTIONS <a name=\"WIDGET-SPECIFIC OPTIONS\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"31%\">\n<p style=\"margin-top: 1em\"><b>\u2212values<\/b> < <small>ARRAYREF<\/small> ><\/p>\n<\/td>\n<td width=\"52%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This option sets the values to use. Unless a label is set for the value (see <b>\u2212labels<\/b>), this value will be shown in the list.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><b>\u2212labels<\/b> < <small>HASHREF<\/small> ><\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">The keys of this hash reference correspond to the values of the listbox (see <b>\u2212values<\/b>). The values of the hash are the labels to show in the listbox. It\u2019s not obligatory to have a label defined for each value. You may even omit \u2212labels completely.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><b>\u2212selected<\/b> < <small>INDEX<\/small> ><\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">In case the <b>\u2212multi<\/b> option is not set, <small>INDEX<\/small> is the index of the value that should be selected.<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">In case the <b>\u2212multi<\/b> option is set, <small>INDEX<\/small> is a hash reference in which the keys are the indices of the <b>\u2212values<\/b> which are selected and the values are any true value.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"28%\">\n<p style=\"margin-top: 1em\"><b>\u2212multi<\/b> < <small>BOOLEAN<\/small> ><\/p>\n<\/td>\n<td width=\"55%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">If <small>BOOLEAN<\/small> has a true value, the listbox will be a multi-select listbox (see <small>DESCRIPTION<\/small> ).<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"28%\">\n<p style=\"margin-top: 1em\"><b>\u2212radio<\/b> < <small>BOOLEAN<\/small> ><\/p>\n<\/td>\n<td width=\"55%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">If <small>BOOLEAN<\/small> has a true value, the listbox will be a radiobutton listbox (see <small>DESCRIPTION<\/small> ).<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"35%\">\n<p style=\"margin-top: 1em\"><b>\u2212wraparound<\/b> < <small>BOOLEAN<\/small> ><\/p>\n<\/td>\n<td width=\"48%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">If <small>BOOLEAN<\/small> has a true value, wraparound is enabled. This means that if the listbox is on its last value and a key is pressed to go to the next value, the first value will be selected. Also the last value will be selected if this first value is selected and &#8220;goto previous value&#8221; is pressed.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"32%\">\n<p style=\"margin-top: 1em\"><b>\u2212onchange<\/b> < <small>CODEREF<\/small> ><\/p>\n<\/td>\n<td width=\"51%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This sets the onChange event handler for the listbox widget. If a new item is selected, the code in <small>CODEREF<\/small> will be executed. It will get the widget reference as its argument.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"37%\">\n<p style=\"margin-top: 1em\"><b>\u2212onselchange<\/b> < <small>CODEREF<\/small> ><\/p>\n<\/td>\n<td width=\"46%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This sets the onSelectionChange event handler for the listbox widget. If a new item is marked as active <small>CODEREF<\/small> will be executed. It will get the widget reference as its argument.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"32%\">\n<p style=\"margin-top: 1em\"><b>\u2212htmltext<\/b> < <small>BOOLEAN<\/small> ><\/p>\n<\/td>\n<td width=\"51%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Make the Listbox parse primitive markup to change the items appearance. See above.<\/p>\n<h2>METHODS <a name=\"METHODS\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><b>new<\/b> ( <small>OPTIONS<\/small> )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p><b>layout<\/b> ( )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p><b>draw<\/b> ( <small>BOOLEAN<\/small> )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p><b>intellidraw<\/b> ( )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p><b>focus<\/b> ( )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p><b>onFocus<\/b> ( <small>CODEREF<\/small> )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p>\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p><b>onBlur<\/b> ( <small>CODEREF<\/small> )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">These are standard methods. See Curses::UI::Widget for an explanation of these.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"11%\">\n<p style=\"margin-top: 1em\"><b>get<\/b> ( )<\/p>\n<\/td>\n<td width=\"72%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method will return the values of the currently selected items in the list. If the listbox is not a multi-select listbox only one value will be returned of course.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"9%\">\n<p style=\"margin-top: 1em\"><b>id<\/b> ( )<\/p>\n<\/td>\n<td width=\"74%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method will return the index of the currently selected items in the list. If the listboy is not a multi-select listbox it will only return one value.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"31%\">\n<p style=\"margin-top: 1em\"><b>get_active_value<\/b> ( )<\/p>\n<\/td>\n<td width=\"52%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method will return the value of the currently active (i.e highlighted line).<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"26%\">\n<p style=\"margin-top: 1em\"><b>get_active_id<\/b> ( )<\/p>\n<\/td>\n<td width=\"57%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method will return the index of the currently active (i.e highlighted line).<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"35%\">\n<p style=\"margin-top: 1em\"><b>set_active_id<\/b> ( <small>INDEX<\/small> )<\/p>\n<\/td>\n<td width=\"48%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method will set the currently active (i.e highlighted line).<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"34%\">\n<p style=\"margin-top: 1em\"><b>set_selection<\/b> ( <small>LIST<\/small> )<\/p>\n<\/td>\n<td width=\"49%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method marks the items at the positions specified in <small>LIST<\/small> as selected. In a multi-select listbox you can set multiple items with giving multiple values, in a single-select listbox only the last item in <small>LIST<\/small> will be selected<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><b>clear_selection<\/b> ( )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method clears the selected objects of a multi and radiobutton listbox.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"29%\">\n<p style=\"margin-top: 1em\"><b>values<\/b> ( <small>ARRAYREF<\/small> )<\/p>\n<\/td>\n<td width=\"54%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method sets the values to use.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"52%\">\n<p style=\"margin-top: 1em\"><b>insert_at<\/b> < <small>POS,<\/small> ARRAYREF|SCALAR ><\/p>\n<\/td>\n<td width=\"31%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method adds <small>ARRAYREF<\/small> or <small>SCALAR<\/small> into the list of values at pos.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"28%\">\n<p style=\"margin-top: 1em\"><b>labels<\/b> [ <small>HASHREF<\/small> ]<\/p>\n<\/td>\n<td width=\"55%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method sets the labels to use.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"34%\">\n<p style=\"margin-top: 1em\"><b>add_labels<\/b> [ <small>HASHREF<\/small> ]<\/p>\n<\/td>\n<td width=\"49%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method adds the given labels to the already defined ones.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"31%\">\n<p style=\"margin-top: 1em\"><b>onChange<\/b> ( <small>CODEREF<\/small> )<\/p>\n<\/td>\n<td width=\"52%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method can be used to set the <b>\u2212onchange<\/b> event handler (see above) after initialization of the listbox.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"45%\">\n<p style=\"margin-top: 1em\"><b>onSelectionChange<\/b> ( <small>CODEREF<\/small> )<\/p>\n<\/td>\n<td width=\"38%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">This method can be used to set the <b>\u2212onselchange<\/b> event handler (see above) after initialization of the listbox.<\/p>\n<h2>DEFAULT BINDINGS <a name=\"DEFAULT BINDINGS\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"38%\">\n<p style=\"margin-top: 1em\"><<b>cursor-left<\/b>>, <<b>h<\/b>>, <<b>tab<\/b>><\/p>\n<\/td>\n<td width=\"45%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019loose\u2212focus\u2019 routine. This will have the widget loose its focus.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"55%\">\n<p style=\"margin-top: 1em\"><<b>cursor-right<\/b>, <<b>l<\/b>>, <<b>enter<\/b>>, <<b>space<\/b>><\/p>\n<\/td>\n<td width=\"28%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212select\u2019 routine. This will select the active item in the listbox.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"12%\">\n<p style=\"margin-top: 1em\"><<b>1<\/b>>, <<b>y<\/b>><\/p>\n<\/td>\n<td width=\"71%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212check\u2019 routine. If the listbox is a multi-select listbox, the active item will become checked and the next item will become active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"12%\">\n<p style=\"margin-top: 1em\"><<b>0<\/b>>, <<b>n<\/b>><\/p>\n<\/td>\n<td width=\"71%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212uncheck\u2019 routine. If the listbox is a multi-select listbox, the active item will become unchecked and the next item will become active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"28%\">\n<p style=\"margin-top: 1em\"><<b>cursor-down<\/b>>, <<b>j<\/b>><\/p>\n<\/td>\n<td width=\"55%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212next\u2019 routine. This will make the next item of the list active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"25%\">\n<p style=\"margin-top: 1em\"><<b>cursor-up<\/b>>, <<b>k<\/b>><\/p>\n<\/td>\n<td width=\"58%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212prev\u2019 routine. This will make the previous item of the list active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"14%\">\n<p style=\"margin-top: 1em\"><<b>page-up<\/b>><\/p>\n<\/td>\n<td width=\"69%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212prevpage\u2019 routine. This will make the item on the previous page active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"17%\">\n<p style=\"margin-top: 1em\"><<b>page-down<\/b>><\/p>\n<\/td>\n<td width=\"66%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212nextpage\u2019 routine. This will make the item on the next page active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"25%\">\n<p style=\"margin-top: 1em\"><<b>home<\/b>>, < <b><small>CTRL+A<\/small><\/b> ><\/p>\n<\/td>\n<td width=\"58%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212first\u2019 routine. This will make the first item of the list active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"23%\">\n<p style=\"margin-top: 1em\"><<b>end<\/b>>, < <b><small>CTRL+E<\/small><\/b> ><\/p>\n<\/td>\n<td width=\"60%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019option\u2212last\u2019 routine. This will make the last item of the list active.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"5%\">\n<p style=\"margin-top: 1em\"><<b>\/<\/b>><\/p>\n<\/td>\n<td width=\"78%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019search\u2212forward\u2019 routine. This will make a \u2019less\u2019\u2212like search system appear in the listbox. A searchstring can be entered. After that the user can search for the next occurance using the \u2019n\u2019 key or the previous occurance using the \u2019N\u2019 key.<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"1%\">\n<p style=\"margin-top: 1em\">\u2022<\/p>\n<\/td>\n<td width=\"5%\"><\/td>\n<td width=\"5%\">\n<p style=\"margin-top: 1em\"><<b>?<\/b>><\/p>\n<\/td>\n<td width=\"78%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:17%; margin-top: 1em\">Call the \u2019search\u2212backward\u2019 routine. This will do the same as the \u2019search\u2212forward\u2019 routine, only it will search in the opposite direction.<\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Curses::UI, Curses::UI::Widget, Curses::UI::Common<\/p>\n<h2>AUTHOR <a name=\"AUTHOR\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Copyright (c) 2001\u22122002 Maurice Makaay. All rights reserved.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">Maintained by Marcus Thiesen (marcus@cpan.thiesenweb.de)<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">This package is free software and is provided &#8220;as is&#8221; without express or implied warranty. It may be used, redistributed and\/or modified under the same terms as perl itself.<\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  Curses::UI::Listbox \u2212 Create and manipulate listbox widgets <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[3119,3007],"class_list":["post-6747","post","type-post","status-publish","format-standard","hentry","category-sin-categoria","tag-cursesuilistbox","tag-man3"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/6747","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=6747"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/6747\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=6747"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=6747"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=6747"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}