]> git.ozlabs.org Git - petitboot/blobdiff - ui/ncurses/nc-widgets.c
ui/ncurses: Use a fixed-sized for small, known-length fields
[petitboot] / ui / ncurses / nc-widgets.c
index 2829040b46ba236a7ad01e9e1dd828d0199ac7d9..bd78927781f2c6dc830dd514bd5d97a9128b5c1f 100644 (file)
@@ -353,6 +353,11 @@ struct nc_widget_textbox *widget_new_textbox(struct nc_widgetset *set,
        return textbox;
 }
 
+void widget_textbox_set_fixed_size(struct nc_widget_textbox *textbox)
+{
+       field_opts_on(textbox->widget.field, O_STATIC);
+}
+
 void widget_textbox_set_validator_integer(struct nc_widget_textbox *textbox,
                long min, long max)
 {