Lines Matching refs:form
11 * 2. Redistributions in binary form must reproduce the above copyright
84 wchar_t securewch; /* wide char of conf.form.secure[mb]ch */
115 if (conf->form.securembch != NULL) {
116 mbchsize = mblen(conf->form.securembch, MB_LEN_MAX);
117 if (mbtowc(&f->securewch, conf->form.securembch, mbchsize) < 0)
120 } else if (conf->form.securech != '\0') {
121 f->securewch = btowc(conf->form.securech);
130 RETURN_ERROR("Cannot allocate internal form.pritems");
364 if (conf->form.value_wchar)
476 color = t.form.readonlycolor;
480 color = focus ? t.form.f_fieldcolor : t.form.fieldcolor;
500 attron(t.form.bottomdesccolor);
502 attroff(t.form.bottomdesccolor);
682 struct privateform form;
689 if (build_privateform(conf, nitems, items, &form) != 0)
692 if ((form.box = newwin(1, 1, 1, 1)) == NULL)
693 RETURN_ERROR("Cannot build WINDOW form box");
694 wbkgd(form.box, t.dialog.color);
695 if ((form.pad = newpad(1, 1)) == NULL)
696 RETURN_ERROR("Cannot build WINDOW form pad");
697 wbkgd(form.pad, t.dialog.color);
699 set_first_with_default(&form, focusitem);
700 if (form.sel != -1) {
702 form.y = 0;
703 item = &form.pritems[form.sel];
709 form.formheight = formheight;
710 if (form_redraw(&d, &form, focusinform) != 0)
741 if (form.sel != -1) {
752 DRAWITEM_TRICK(&form, form.sel, true);
757 } else if (form.sel != -1) {
764 DRAWITEM_TRICK(&form, form.sel, true);
769 } else if (form.sel != -1) {
776 next = previtem(form.nitems, form.pritems,
777 form.sel);
778 changeitem = form.sel != next;
779 } else if (form.sel != -1) {
787 if (form.nitems == 1) {
790 next = nextitem(form.nitems, form.pritems,
791 form.sel);
792 changeitem = form.sel != next;
797 next = firstitem(form.nitems, form.pritems);
798 changeitem = form.sel != next;
803 next = lastitem(form.nitems, form.pritems);
804 changeitem = form.sel != next;
813 DRAWITEM_TRICK(&form, form.sel, true);
819 DRAWITEM_TRICK(&form, form.sel, true);
825 DRAWITEM_TRICK(&form, form.sel, true);
831 DRAWITEM_TRICK(&form, form.sel, true);
842 if (form_redraw(&d, &form, focusinform) != 0)
847 if (form_redraw(&d, &form, focusinform) != 0)
861 if (insertch(item, input, form.securewch)) {
867 DRAWITEM_TRICK(&form, form.sel, true);
887 DRAWITEM_TRICK(&form, form.sel, focusinform);
892 DRAWITEM_TRICK(&form, form.sel, false);
893 form.sel = next;
894 item = &form.pritems[form.sel];
895 curriteminview(&form, item);
896 update_formbox(conf, &form);
897 wnoutrefresh(form.box);
898 DRAWITEM_TRICK(&form, form.sel, true);
905 if (return_values(conf, &form, items) == BSDDIALOG_ERROR)
909 *focusitem = form.sel;
911 if (form.hasbottomdesc && conf->clear) {
915 for (i = 0; i < form.nitems; i++) {
916 free(form.pritems[i].privwbuf);
917 free(form.pritems[i].pubwbuf);
919 delwin(form.pad);
920 delwin(form.box);