xref: /freebsd/contrib/ncurses/form/llib-lformt (revision 3c4ba5f55438f7afd4f4b0b56f88f2bb505fd6a6)
1/****************************************************************************
2 * Copyright 2020 Thomas E. Dickey                                          *
3 * Copyright 2010-2015,2017 Free Software Foundation, Inc.                  *
4 *                                                                          *
5 * Permission is hereby granted, free of charge, to any person obtaining a  *
6 * copy of this software and associated documentation files (the            *
7 * "Software"), to deal in the Software without restriction, including      *
8 * without limitation the rights to use, copy, modify, merge, publish,      *
9 * distribute, distribute with modifications, sublicense, and/or sell       *
10 * copies of the Software, and to permit persons to whom the Software is    *
11 * furnished to do so, subject to the following conditions:                 *
12 *                                                                          *
13 * The above copyright notice and this permission notice shall be included  *
14 * in all copies or substantial portions of the Software.                   *
15 *                                                                          *
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS  *
17 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF               *
18 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.   *
19 * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,   *
20 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR    *
21 * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR    *
22 * THE USE OR OTHER DEALINGS IN THE SOFTWARE.                               *
23 *                                                                          *
24 * Except as contained in this notice, the name(s) of the above copyright   *
25 * holders shall not be used in advertising or otherwise to promote the     *
26 * sale, use or other dealings in this Software without prior written       *
27 * authorization.                                                           *
28 ****************************************************************************/
29
30/****************************************************************************
31 *  Author: Thomas E. Dickey       2010-on                                  *
32 ****************************************************************************/
33/* LINTLIBRARY */
34
35/* ./f_trace.c */
36
37#include <form.priv.h>
38
39#undef _nc_retrace_field_ptr
40FIELD	**_nc_retrace_field_ptr(
41		FIELD	**code)
42		{ return(*(FIELD ***)0); }
43
44#undef _nc_retrace_field
45FIELD	*_nc_retrace_field(
46		FIELD	*code)
47		{ return(*(FIELD **)0); }
48
49#undef _nc_retrace_field_type
50FIELDTYPE *_nc_retrace_field_type(
51		FIELDTYPE *code)
52		{ return(*(FIELDTYPE **)0); }
53
54#undef _nc_retrace_form
55FORM	*_nc_retrace_form(
56		FORM	*code)
57		{ return(*(FORM **)0); }
58
59#undef _nc_retrace_form_hook
60Form_Hook _nc_retrace_form_hook(
61		Form_Hook code)
62		{ return(*(Form_Hook *)0); }
63
64/* ./fld_arg.c */
65
66#undef set_fieldtype_arg
67int	set_fieldtype_arg(
68		FIELDTYPE *typ,
69		void	*(*const make_arg)(
70		va_list	*p1),
71		void	*(*const copy_arg)(
72		const void *p1),
73		void	(*const free_arg)(
74		void	*p1))
75		{ return(*(int *)0); }
76
77#undef field_arg
78void	*field_arg(
79		const FIELD *field)
80		{ return(*(void **)0); }
81
82/* ./fld_attr.c */
83
84#undef set_field_fore
85int	set_field_fore(
86		FIELD	*field,
87		chtype	attr)
88		{ return(*(int *)0); }
89
90#undef field_fore
91chtype	field_fore(
92		const FIELD *field)
93		{ return(*(chtype *)0); }
94
95#undef set_field_back
96int	set_field_back(
97		FIELD	*field,
98		chtype	attr)
99		{ return(*(int *)0); }
100
101#undef field_back
102chtype	field_back(
103		const FIELD *field)
104		{ return(*(chtype *)0); }
105
106/* ./fld_current.c */
107
108#undef set_current_field
109int	set_current_field(
110		FORM	*form,
111		FIELD	*field)
112		{ return(*(int *)0); }
113
114#undef unfocus_current_field
115int	unfocus_current_field(
116		FORM	*const form)
117		{ return(*(int *)0); }
118
119#undef current_field
120FIELD	*current_field(
121		const FORM *form)
122		{ return(*(FIELD **)0); }
123
124#undef field_index
125int	field_index(
126		const FIELD *field)
127		{ return(*(int *)0); }
128
129/* ./fld_def.c */
130
131#undef _nc_Default_Field
132FIELD	*_nc_Default_Field;
133
134#undef _nc_Make_Argument
135TypeArgument *_nc_Make_Argument(
136		const FIELDTYPE *typ,
137		va_list	*ap,
138		int	*err)
139		{ return(*(TypeArgument **)0); }
140
141#undef _nc_Copy_Argument
142TypeArgument *_nc_Copy_Argument(
143		const FIELDTYPE *typ,
144		const TypeArgument *argp,
145		int	*err)
146		{ return(*(TypeArgument **)0); }
147
148#undef _nc_Free_Argument
149void	_nc_Free_Argument(
150		const FIELDTYPE *typ,
151		TypeArgument *argp)
152		{ /* void */ }
153
154#undef _nc_Copy_Type
155NCURSES_BOOL _nc_Copy_Type(
156		FIELD	*dst,
157		FIELD const *src)
158		{ return(*(NCURSES_BOOL *)0); }
159
160#undef _nc_Free_Type
161void	_nc_Free_Type(
162		FIELD	*field)
163		{ /* void */ }
164
165#undef new_field
166FIELD	*new_field(
167		int	rows,
168		int	cols,
169		int	frow,
170		int	fcol,
171		int	nrow,
172		int	nbuf)
173		{ return(*(FIELD **)0); }
174
175#undef free_field
176int	free_field(
177		FIELD	*field)
178		{ return(*(int *)0); }
179
180/* ./fld_dup.c */
181
182#undef dup_field
183FIELD	*dup_field(
184		FIELD	*field,
185		int	frow,
186		int	fcol)
187		{ return(*(FIELD **)0); }
188
189/* ./fld_ftchoice.c */
190
191#undef set_fieldtype_choice
192int	set_fieldtype_choice(
193		FIELDTYPE *typ,
194		NCURSES_BOOL (*const next_choice)(
195		FIELD	*p1,
196		const void *p2),
197		NCURSES_BOOL (*const prev_choice)(
198		FIELD	*p1,
199		const void *p2))
200		{ return(*(int *)0); }
201
202/* ./fld_ftlink.c */
203
204#undef link_fieldtype
205FIELDTYPE *link_fieldtype(
206		FIELDTYPE *type1,
207		FIELDTYPE *type2)
208		{ return(*(FIELDTYPE **)0); }
209
210/* ./fld_info.c */
211
212#undef field_info
213int	field_info(
214		const FIELD *field,
215		int	*rows,
216		int	*cols,
217		int	*frow,
218		int	*fcol,
219		int	*nrow,
220		int	*nbuf)
221		{ return(*(int *)0); }
222
223#undef dynamic_field_info
224int	dynamic_field_info(
225		const FIELD *field,
226		int	*drows,
227		int	*dcols,
228		int	*maxgrow)
229		{ return(*(int *)0); }
230
231/* ./fld_just.c */
232
233#undef set_field_just
234int	set_field_just(
235		FIELD	*field,
236		int	just)
237		{ return(*(int *)0); }
238
239#undef field_just
240int	field_just(
241		const FIELD *field)
242		{ return(*(int *)0); }
243
244/* ./fld_link.c */
245
246#undef link_field
247FIELD	*link_field(
248		FIELD	*field,
249		int	frow,
250		int	fcol)
251		{ return(*(FIELD **)0); }
252
253/* ./fld_max.c */
254
255#undef set_max_field
256int	set_max_field(
257		FIELD	*field,
258		int	maxgrow)
259		{ return(*(int *)0); }
260
261/* ./fld_move.c */
262
263#undef move_field
264int	move_field(
265		FIELD	*field,
266		int	frow,
267		int	fcol)
268		{ return(*(int *)0); }
269
270/* ./fld_newftyp.c */
271
272#undef _nc_Default_FieldType
273FIELDTYPE *_nc_Default_FieldType;
274
275#undef new_fieldtype
276FIELDTYPE *new_fieldtype(
277		NCURSES_BOOL (*const field_check)(
278		FIELD	*p1,
279		const void *p2),
280		NCURSES_BOOL (*const char_check)(
281		int	p1,
282		const void *p2))
283		{ return(*(FIELDTYPE **)0); }
284
285#undef free_fieldtype
286int	free_fieldtype(
287		FIELDTYPE *typ)
288		{ return(*(int *)0); }
289
290/* ./fld_opts.c */
291
292#undef set_field_opts
293int	set_field_opts(
294		FIELD	*field,
295		Field_Options opts)
296		{ return(*(int *)0); }
297
298#undef field_opts
299Field_Options field_opts(
300		const FIELD *field)
301		{ return(*(Field_Options *)0); }
302
303#undef field_opts_on
304int	field_opts_on(
305		FIELD	*field,
306		Field_Options opts)
307		{ return(*(int *)0); }
308
309#undef field_opts_off
310int	field_opts_off(
311		FIELD	*field,
312		Field_Options opts)
313		{ return(*(int *)0); }
314
315/* ./fld_pad.c */
316
317#undef set_field_pad
318int	set_field_pad(
319		FIELD	*field,
320		int	ch)
321		{ return(*(int *)0); }
322
323#undef field_pad
324int	field_pad(
325		const FIELD *field)
326		{ return(*(int *)0); }
327
328/* ./fld_page.c */
329
330#undef set_new_page
331int	set_new_page(
332		FIELD	*field,
333		NCURSES_BOOL new_page_flag)
334		{ return(*(int *)0); }
335
336#undef new_page
337NCURSES_BOOL new_page(
338		const FIELD *field)
339		{ return(*(NCURSES_BOOL *)0); }
340
341/* ./fld_stat.c */
342
343#undef set_field_status
344int	set_field_status(
345		FIELD	*field,
346		NCURSES_BOOL status)
347		{ return(*(int *)0); }
348
349#undef field_status
350NCURSES_BOOL field_status(
351		const FIELD *field)
352		{ return(*(NCURSES_BOOL *)0); }
353
354/* ./fld_type.c */
355
356#undef set_field_type
357int	set_field_type(
358		FIELD	*field,
359		FIELDTYPE *type,
360		...)
361		{ return(*(int *)0); }
362
363#undef field_type
364FIELDTYPE *field_type(
365		const FIELD *field)
366		{ return(*(FIELDTYPE **)0); }
367
368/* ./fld_user.c */
369
370#undef set_field_userptr
371int	set_field_userptr(
372		FIELD	*field,
373		void	*usrptr)
374		{ return(*(int *)0); }
375
376#undef field_userptr
377void	*field_userptr(
378		const FIELD *field)
379		{ return(*(void **)0); }
380
381/* ./frm_cursor.c */
382
383#undef pos_form_cursor
384int	pos_form_cursor(
385		FORM	*form)
386		{ return(*(int *)0); }
387
388/* ./frm_data.c */
389
390#undef data_behind
391NCURSES_BOOL data_behind(
392		const FORM *form)
393		{ return(*(NCURSES_BOOL *)0); }
394
395#undef data_ahead
396NCURSES_BOOL data_ahead(
397		const FORM *form)
398		{ return(*(NCURSES_BOOL *)0); }
399
400/* ./frm_def.c */
401
402#undef _nc_Default_Form
403FORM	*_nc_Default_Form;
404
405#undef new_form_sp
406FORM	*new_form_sp(
407		SCREEN	*sp,
408		FIELD	**fields)
409		{ return(*(FORM **)0); }
410
411#undef new_form
412FORM	*new_form(
413		FIELD	**fields)
414		{ return(*(FORM **)0); }
415
416#undef free_form
417int	free_form(
418		FORM	*form)
419		{ return(*(int *)0); }
420
421#undef set_form_fields
422int	set_form_fields(
423		FORM	*form,
424		FIELD	**fields)
425		{ return(*(int *)0); }
426
427#undef form_fields
428FIELD	**form_fields(
429		const FORM *form)
430		{ return(*(FIELD ***)0); }
431
432#undef field_count
433int	field_count(
434		const FORM *form)
435		{ return(*(int *)0); }
436
437/* ./frm_driver.c */
438
439#undef _nc_get_fieldbuffer
440void	_nc_get_fieldbuffer(
441		FORM	*form,
442		FIELD	*field,
443		char	*buf)
444		{ /* void */ }
445
446#undef _nc_Position_Form_Cursor
447int	_nc_Position_Form_Cursor(
448		FORM	*form)
449		{ return(*(int *)0); }
450
451#undef _nc_Refresh_Current_Field
452int	_nc_Refresh_Current_Field(
453		FORM	*form)
454		{ return(*(int *)0); }
455
456#undef _nc_Synchronize_Attributes
457int	_nc_Synchronize_Attributes(
458		FIELD	*field)
459		{ return(*(int *)0); }
460
461#undef _nc_Synchronize_Options
462int	_nc_Synchronize_Options(
463		FIELD	*field,
464		Field_Options newopts)
465		{ return(*(int *)0); }
466
467#undef _nc_Unset_Current_Field
468void	_nc_Unset_Current_Field(
469		FORM	*form)
470		{ /* void */ }
471
472#undef _nc_Set_Current_Field
473int	_nc_Set_Current_Field(
474		FORM	*form,
475		FIELD	*newfield)
476		{ return(*(int *)0); }
477
478#undef _nc_Internal_Validation
479NCURSES_BOOL _nc_Internal_Validation(
480		FORM	*form)
481		{ return(*(NCURSES_BOOL *)0); }
482
483#undef _nc_First_Active_Field
484FIELD	*_nc_First_Active_Field(
485		FORM	*form)
486		{ return(*(FIELD **)0); }
487
488#undef _nc_Set_Form_Page
489int	_nc_Set_Form_Page(
490		FORM	*form,
491		int	page,
492		FIELD	*field)
493		{ return(*(int *)0); }
494
495typedef struct
496{
497  int keycode;
498  int (*cmd) (FORM *);
499}
500Binding_Info;
501
502#undef form_driver
503int	form_driver(
504		FORM	*form,
505		int	c)
506		{ return(*(int *)0); }
507
508#undef set_field_buffer
509int	set_field_buffer(
510		FIELD	*field,
511		int	buffer,
512		const char *value)
513		{ return(*(int *)0); }
514
515#undef field_buffer
516char	*field_buffer(
517		const FIELD *field,
518		int	buffer)
519		{ return(*(char **)0); }
520
521/* ./frm_hook.c */
522
523#undef set_field_init
524int	set_field_init(
525		FORM	*form,
526		Form_Hook func)
527		{ return(*(int *)0); }
528
529#undef field_init
530Form_Hook field_init(
531		const FORM *form)
532		{ return(*(Form_Hook *)0); }
533
534#undef set_field_term
535int	set_field_term(
536		FORM	*form,
537		Form_Hook func)
538		{ return(*(int *)0); }
539
540#undef field_term
541Form_Hook field_term(
542		const FORM *form)
543		{ return(*(Form_Hook *)0); }
544
545#undef set_form_init
546int	set_form_init(
547		FORM	*form,
548		Form_Hook func)
549		{ return(*(int *)0); }
550
551#undef form_init
552Form_Hook form_init(
553		const FORM *form)
554		{ return(*(Form_Hook *)0); }
555
556#undef set_form_term
557int	set_form_term(
558		FORM	*form,
559		Form_Hook func)
560		{ return(*(int *)0); }
561
562#undef form_term
563Form_Hook form_term(
564		const FORM *form)
565		{ return(*(Form_Hook *)0); }
566
567/* ./frm_opts.c */
568
569#undef set_form_opts
570int	set_form_opts(
571		FORM	*form,
572		Form_Options opts)
573		{ return(*(int *)0); }
574
575#undef form_opts
576Form_Options form_opts(
577		const FORM *form)
578		{ return(*(Form_Options *)0); }
579
580#undef form_opts_on
581int	form_opts_on(
582		FORM	*form,
583		Form_Options opts)
584		{ return(*(int *)0); }
585
586#undef form_opts_off
587int	form_opts_off(
588		FORM	*form,
589		Form_Options opts)
590		{ return(*(int *)0); }
591
592/* ./frm_page.c */
593
594#undef set_form_page
595int	set_form_page(
596		FORM	*form,
597		int	page)
598		{ return(*(int *)0); }
599
600#undef form_page
601int	form_page(
602		const FORM *form)
603		{ return(*(int *)0); }
604
605/* ./frm_post.c */
606
607#undef post_form
608int	post_form(
609		FORM	*form)
610		{ return(*(int *)0); }
611
612#undef unpost_form
613int	unpost_form(
614		FORM	*form)
615		{ return(*(int *)0); }
616
617/* ./frm_req_name.c */
618
619#undef form_request_name
620const char *form_request_name(
621		int	request)
622		{ return(*(const char **)0); }
623
624#undef form_request_by_name
625int	form_request_by_name(
626		const char *str)
627		{ return(*(int *)0); }
628
629/* ./frm_scale.c */
630
631#undef scale_form
632int	scale_form(
633		const FORM *form,
634		int	*rows,
635		int	*cols)
636		{ return(*(int *)0); }
637
638/* ./frm_sub.c */
639
640#undef set_form_sub
641int	set_form_sub(
642		FORM	*form,
643		WINDOW	*win)
644		{ return(*(int *)0); }
645
646#undef form_sub
647WINDOW	*form_sub(
648		const FORM *form)
649		{ return(*(WINDOW **)0); }
650
651/* ./frm_user.c */
652
653#undef set_form_userptr
654int	set_form_userptr(
655		FORM	*form,
656		void	*usrptr)
657		{ return(*(int *)0); }
658
659#undef form_userptr
660void	*form_userptr(
661		const FORM *form)
662		{ return(*(void **)0); }
663
664/* ./frm_win.c */
665
666#undef set_form_win
667int	set_form_win(
668		FORM	*form,
669		WINDOW	*win)
670		{ return(*(int *)0); }
671
672#undef form_win
673WINDOW	*form_win(
674		const FORM *form)
675		{ return(*(WINDOW **)0); }
676
677/* ./fty_alnum.c */
678
679typedef struct
680  {
681    int width;
682  }
683alnumARG;
684
685#undef TYPE_ALNUM
686FIELDTYPE *TYPE_ALNUM;
687
688#undef _nc_TYPE_ALNUM
689FIELDTYPE *_nc_TYPE_ALNUM(void)
690		{ return(*(FIELDTYPE **)0); }
691
692/* ./fty_alpha.c */
693
694typedef struct
695  {
696    int width;
697  }
698alphaARG;
699
700#undef TYPE_ALPHA
701FIELDTYPE *TYPE_ALPHA;
702
703#undef _nc_TYPE_ALPHA
704FIELDTYPE *_nc_TYPE_ALPHA(void)
705		{ return(*(FIELDTYPE **)0); }
706
707/* ./fty_enum.c */
708
709typedef struct
710  {
711    char **kwds;
712    int count;
713    NCURSES_BOOL checkcase;
714    NCURSES_BOOL checkunique;
715  }
716enumARG;
717
718typedef struct
719  {
720    char **kwds;
721    int ccase;
722    int cunique;
723  }
724enumParams;
725
726#undef TYPE_ENUM
727FIELDTYPE *TYPE_ENUM;
728
729#undef _nc_TYPE_ENUM
730FIELDTYPE *_nc_TYPE_ENUM(void)
731		{ return(*(FIELDTYPE **)0); }
732
733/* ./fty_generic.c */
734
735#undef _nc_generic_fieldtype
736FIELDTYPE *_nc_generic_fieldtype(
737		NCURSES_BOOL (*const field_check)(
738		FORM	*p1,
739		FIELD	*p2,
740		const void *p3),
741		NCURSES_BOOL (*const char_check)(
742		int	p1,
743		FORM	*p2,
744		FIELD	*p3,
745		const void *p4),
746		NCURSES_BOOL (*const next)(
747		FORM	*p1,
748		FIELD	*p2,
749		const void *p3),
750		NCURSES_BOOL (*const prev)(
751		FORM	*p1,
752		FIELD	*p2,
753		const void *p3),
754		void	(*freecallback)(
755		void	*p1))
756		{ return(*(FIELDTYPE **)0); }
757
758#undef _nc_set_generic_fieldtype
759int	_nc_set_generic_fieldtype(
760		FIELD	*field,
761		FIELDTYPE *ftyp,
762		int	(*argiterator)(
763		void	**p1))
764		{ return(*(int *)0); }
765
766#undef _nc_form_cursor
767WINDOW	*_nc_form_cursor(
768		const FORM *form,
769		int	*pRow,
770		int	*pCol)
771		{ return(*(WINDOW **)0); }
772
773/* ./fty_int.c */
774
775typedef struct
776  {
777    int precision;
778    long low;
779    long high;
780  }
781integerARG;
782
783typedef struct
784  {
785    int precision;
786    long low;
787    long high;
788  }
789integerPARM;
790
791#undef TYPE_INTEGER
792FIELDTYPE *TYPE_INTEGER;
793
794#undef _nc_TYPE_INTEGER
795FIELDTYPE *_nc_TYPE_INTEGER(void)
796		{ return(*(FIELDTYPE **)0); }
797
798/* ./fty_ipv4.c */
799
800#undef TYPE_IPV4
801FIELDTYPE *TYPE_IPV4;
802
803#undef _nc_TYPE_IPV4
804FIELDTYPE *_nc_TYPE_IPV4(void)
805		{ return(*(FIELDTYPE **)0); }
806
807/* ./fty_num.c */
808
809typedef struct
810  {
811    int precision;
812    double low;
813    double high;
814    struct lconv *L;
815  }
816numericARG;
817
818typedef struct
819  {
820    int precision;
821    double low;
822    double high;
823  }
824thisPARM;
825
826#undef TYPE_NUMERIC
827FIELDTYPE *TYPE_NUMERIC;
828
829#undef _nc_TYPE_NUMERIC
830FIELDTYPE *_nc_TYPE_NUMERIC(void)
831		{ return(*(FIELDTYPE **)0); }
832
833/* ./fty_regex.c */
834
835typedef struct
836  {
837    regex_t *pRegExp;
838    unsigned long *refCount;
839  }
840RegExp_Arg;
841
842#undef TYPE_REGEXP
843FIELDTYPE *TYPE_REGEXP;
844
845#undef _nc_TYPE_REGEXP
846FIELDTYPE *_nc_TYPE_REGEXP(void)
847		{ return(*(FIELDTYPE **)0); }
848