1 /****************************************************************************
2 * Copyright (c) 1998 Free Software Foundation, Inc. *
4 * Permission is hereby granted, free of charge, to any person obtaining a *
5 * copy of this software and associated documentation files (the *
6 * "Software"), to deal in the Software without restriction, including *
7 * without limitation the rights to use, copy, modify, merge, publish, *
8 * distribute, distribute with modifications, sublicense, and/or sell *
9 * copies of the Software, and to permit persons to whom the Software is *
10 * furnished to do so, subject to the following conditions: *
12 * The above copyright notice and this permission notice shall be included *
13 * in all copies or substantial portions of the Software. *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS *
16 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF *
17 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. *
18 * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, *
19 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR *
20 * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR *
21 * THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
23 * Except as contained in this notice, the name(s) of the above copyright *
24 * holders shall not be used in advertising or otherwise to promote the *
25 * sale, use or other dealings in this Software without prior written *
27 ****************************************************************************/
29 /****************************************************************************
30 * Author: Juergen Pfeifer <Juergen.Pfeifer@T-Online.de> 1996 *
31 ****************************************************************************/
36 --------------------------------------------------------------------------*/
38 This program generates various record structures and constants from the
39 ncurses header file for the Ada95 packages. Essentially it produces
40 Ada95 source on stdout, which is then merged using m4 into a template
41 to produce the real source.
51 #define RES_NAME "Reserved"
53 static int little_endian = 0;
58 } name_attribute_pair;
60 static int find_pos (char *s, unsigned len, int *low, int *high)
68 for(i=0; i < len; i++,s++)
72 for(j=0;j<8*sizeof(char);j++)
74 if ((( little_endian && ((*s)&0x01)) ||
75 (!little_endian && ((*s)&0x80))) )
92 return (*high >= 0 && (*low <= *high)) ? *low : -1;
96 * This helper routine generates a representation clause for a
97 * record type defined in the binding.
98 * We are only dealing with record types which are of 32 or 16
99 * bit size, i.e. they fit into an (u)int or a (u)short.
102 (const name_attribute_pair *nap, /* array of name_attribute_pair records */
103 const char *name, /* name of the represented record type */
104 int len) /* size of the record in bytes */
106 int i,l,cnt = 0,low,high;
107 int width = strlen(RES_NAME);
110 unsigned int mask = 0;
115 if (len == sizeof(int)/2)
117 bias = little_endian ? 8 * len : 0;
122 assert(len==sizeof(int));
126 for (i=0; nap[i].name != (char *)0; i++)
129 l = strlen(nap[i].name);
135 printf(" type %s is\n",name);
137 for (i=0; nap[i].name != (char *)0; i++)
139 printf(" %-*s : Boolean;\n",width,nap[i].name);
143 printf(" %-*s : Boolean;\n",width,RES_NAME);
145 printf(" end record;\n");
146 printf(" pragma Pack (%s);\n",name);
147 printf(" pragma Convention (C, %s);\n\n",name);
149 printf(" for %s use\n",name);
152 for (i=0; nap[i].name != (char *)0; i++)
156 l = find_pos( (char *)&a,sizeof(a),&low,&high );
158 printf(" %-*s at 0 range %2d .. %2d;\n",width,nap[i].name,low-bias,high-bias);
168 printf(" %-*s at 0 range %2d .. %2d;\n",width,RES_NAME,l,l);
170 printf(" end record;\n");
171 printf(" for %s'Size use Interfaces.C.int'Size%s;\n", name, suffix);
172 printf(" -- Please note: this rep. clause is generated and may be\n");
173 printf(" -- different on your system.");
177 static void chtype_rep (const char *name, int mask)
182 int l = find_pos ((char *)&t, sizeof(t), &low, &high);
184 printf(" %-5s at 0 range %2d .. %2d;\n",name,low,high);
187 static void gen_chtype_rep(const char *name)
189 printf(" for %s use\n record\n",name);
190 chtype_rep("Ch",A_CHARTEXT);
191 chtype_rep("Color",A_COLOR);
192 chtype_rep("Attr",(A_ATTRIBUTES&~A_COLOR));
193 printf(" end record;\n for %s'Size use Interfaces.C.int'Size;\n",name);
194 printf(" -- Please note: this rep. clause is generated and may be\n");
195 printf(" -- different on your system.\n");
199 static void mrep_rep (const char *name, void *rec)
202 int l = find_pos((char *)rec, sizeof(MEVENT), &low, &high);
204 printf(" %-7s at 0 range %3d .. %3d;\n",name,low,high);
208 static void gen_mrep_rep(const char *name)
212 printf(" for %s use\n record\n",name);
214 memset(&x,0,sizeof(x));
218 memset(&x,0,sizeof(x));
222 memset(&x,0,sizeof(x));
226 memset(&x,0,sizeof(x));
230 memset(&x,0,sizeof(x));
232 mrep_rep("Bstate",&x);
234 printf(" end record;\n");
235 printf(" -- Please note: this rep. clause is generated and may be\n");
236 printf(" -- different on your system.\n");
239 static void gen_attr_set( const char *name )
241 static const name_attribute_pair nap[] = {
243 {"Stand_Out", A_STANDOUT},
246 {"Under_Line", A_UNDERLINE},
249 {"Reverse_Video", A_REVERSE},
255 {"Dim_Character", A_DIM},
258 {"Bold_Character", A_BOLD},
261 {"Alternate_Character_Set", A_ALTCHARSET},
264 {"Invisible_Character", A_INVIS},
267 {"Protected_Character", A_PROTECT},
270 {"Horizontal", A_HORIZONTAL},
285 {"Vertical", A_VERTICAL},
289 gen_reps (nap, name, sizeof(int)/2);
292 static void gen_menu_opt_rep(const char *name)
294 static const name_attribute_pair nap[] = {
296 {"One_Valued", O_ONEVALUE},
299 {"Show_Descriptions", O_SHOWDESC},
302 {"Row_Major_Order", O_ROWMAJOR},
305 {"Ignore_Case", O_IGNORECASE},
308 {"Show_Matches", O_SHOWMATCH},
311 {"Non_Cyclic", O_NONCYCLIC},
315 gen_reps (nap, name, sizeof(int));
318 static void gen_item_opt_rep(const char *name)
320 static const name_attribute_pair nap[] = {
322 {"Selectable", O_SELECTABLE},
326 gen_reps (nap, name, sizeof(int));
329 static void gen_form_opt_rep(const char *name)
331 static const name_attribute_pair nap[] = {
333 {"NL_Overload", O_NL_OVERLOAD},
336 {"BS_Overload", O_BS_OVERLOAD},
340 gen_reps (nap, name, sizeof(int));
344 * Generate the representation clause for the Field_Option_Set record
346 static void gen_field_opt_rep(const char *name)
348 static const name_attribute_pair nap[] = {
350 {"Visible",O_VISIBLE},
368 {"Auto_Skip",O_AUTOSKIP},
371 {"Null_Ok",O_NULLOK},
374 {"Pass_Ok",O_PASSOK},
381 gen_reps (nap, name, sizeof(int));
385 * Generate a single key code constant definition.
387 static void keydef(const char *name, const char *old_name, int value, int mode)
389 if (mode==0) /* Generate the new name */
390 printf(" %-30s : constant Special_Key_Code := 8#%3o#;\n",name,value);
392 { /* generate the old name, but only if it doesn't conflict with the old
393 * name (Ada95 isn't case sensitive!)
395 const char *s = old_name; const char *t = name;
396 while ( *s && *t && (toupper(*s++) == toupper(*t++)));
398 printf(" %-16s : Special_Key_Code renames %s;\n",old_name,name);
403 * Generate constants for the key codes. When called with mode==0, a
404 * complete list with nice constant names in proper casing style will
405 * be generated. Otherwise a list of old (i.e. C-style) names will be
406 * generated, given that the name wasn't already defined in the "nice"
409 static void gen_keydefs (int mode)
416 keydef("Key_Code_Yes","KEY_CODE_YES",KEY_CODE_YES,mode);
419 keydef("Key_Min","KEY_MIN",KEY_MIN,mode);
422 keydef("Key_Break","KEY_BREAK",KEY_BREAK,mode);
425 keydef("Key_Cursor_Down","KEY_DOWN",KEY_DOWN,mode);
428 keydef("Key_Cursor_Up","KEY_UP",KEY_UP,mode);
431 keydef("Key_Cursor_Left","KEY_LEFT",KEY_LEFT,mode);
434 keydef("Key_Cursor_Right","KEY_RIGHT",KEY_RIGHT,mode);
437 keydef("Key_Home","KEY_HOME",KEY_HOME,mode);
440 keydef("Key_Backspace","KEY_BACKSPACE",KEY_BACKSPACE,mode);
443 keydef("Key_F0","KEY_F0",KEY_F0,mode);
448 sprintf(buf ,"Key_F%d",i);
449 sprintf(obuf,"KEY_F%d",i);
450 keydef(buf,obuf,KEY_F(i),mode);
454 keydef("Key_Delete_Line","KEY_DL",KEY_DL,mode);
457 keydef("Key_Insert_Line","KEY_IL",KEY_IL,mode);
460 keydef("Key_Delete_Char","KEY_DC",KEY_DC,mode);
463 keydef("Key_Insert_Char","KEY_IC",KEY_IC,mode);
466 keydef("Key_Exit_Insert_Mode","KEY_EIC",KEY_EIC,mode);
469 keydef("Key_Clear_Screen","KEY_CLEAR",KEY_CLEAR,mode);
472 keydef("Key_Clear_End_Of_Screen","KEY_EOS",KEY_EOS,mode);
475 keydef("Key_Clear_End_Of_Line","KEY_EOL",KEY_EOL,mode);
478 keydef("Key_Scroll_1_Forward","KEY_SF",KEY_SF,mode);
481 keydef("Key_Scroll_1_Backward","KEY_SR",KEY_SR,mode);
484 keydef("Key_Next_Page","KEY_NPAGE",KEY_NPAGE,mode);
487 keydef("Key_Previous_Page","KEY_PPAGE",KEY_PPAGE,mode);
490 keydef("Key_Set_Tab","KEY_STAB",KEY_STAB,mode);
493 keydef("Key_Clear_Tab","KEY_CTAB",KEY_CTAB,mode);
496 keydef("Key_Clear_All_Tabs","KEY_CATAB",KEY_CATAB,mode);
499 keydef("Key_Enter_Or_Send","KEY_ENTER",KEY_ENTER,mode);
502 keydef("Key_Soft_Reset","KEY_SRESET",KEY_SRESET,mode);
505 keydef("Key_Reset","KEY_RESET",KEY_RESET,mode);
508 keydef("Key_Print","KEY_PRINT",KEY_PRINT,mode);
511 keydef("Key_Bottom","KEY_LL",KEY_LL,mode);
514 keydef("Key_Upper_Left_Of_Keypad","KEY_A1",KEY_A1,mode);
517 keydef("Key_Upper_Right_Of_Keypad","KEY_A3",KEY_A3,mode);
520 keydef("Key_Center_Of_Keypad","KEY_B2",KEY_B2,mode);
523 keydef("Key_Lower_Left_Of_Keypad","KEY_C1",KEY_C1,mode);
526 keydef("Key_Lower_Right_Of_Keypad","KEY_C3",KEY_C3,mode);
529 keydef("Key_Back_Tab","KEY_BTAB",KEY_BTAB,mode);
532 keydef("Key_Beginning","KEY_BEG",KEY_BEG,mode);
535 keydef("Key_Cancel","KEY_CANCEL",KEY_CANCEL,mode);
538 keydef("Key_Close","KEY_CLOSE",KEY_CLOSE,mode);
541 keydef("Key_Command","KEY_COMMAND",KEY_COMMAND,mode);
544 keydef("Key_Copy","KEY_COPY",KEY_COPY,mode);
547 keydef("Key_Create","KEY_CREATE",KEY_CREATE,mode);
550 keydef("Key_End","KEY_END",KEY_END,mode);
553 keydef("Key_Exit","KEY_EXIT",KEY_EXIT,mode);
556 keydef("Key_Find","KEY_FIND",KEY_FIND,mode);
559 keydef("Key_Help","KEY_HELP",KEY_HELP,mode);
562 keydef("Key_Mark","KEY_MARK",KEY_MARK,mode);
565 keydef("Key_Message","KEY_MESSAGE",KEY_MESSAGE,mode);
568 keydef("Key_Move","KEY_MOVE",KEY_MOVE,mode);
571 keydef("Key_Next","KEY_NEXT",KEY_NEXT,mode);
574 keydef("Key_Open","KEY_OPEN",KEY_OPEN,mode);
577 keydef("Key_Options","KEY_OPTIONS",KEY_OPTIONS,mode);
580 keydef("Key_Previous","KEY_PREVIOUS",KEY_PREVIOUS,mode);
583 keydef("Key_Redo","KEY_REDO",KEY_REDO,mode);
586 keydef("Key_Reference","KEY_REFERENCE",KEY_REFERENCE,mode);
589 keydef("Key_Refresh","KEY_REFRESH",KEY_REFRESH,mode);
592 keydef("Key_Replace","KEY_REPLACE",KEY_REPLACE,mode);
595 keydef("Key_Restart","KEY_RESTART",KEY_RESTART,mode);
598 keydef("Key_Resume","KEY_RESUME",KEY_RESUME,mode);
601 keydef("Key_Save","KEY_SAVE",KEY_SAVE,mode);
604 keydef("Key_Shift_Begin","KEY_SBEG",KEY_SBEG,mode);
607 keydef("Key_Shift_Cancel","KEY_SCANCEL",KEY_SCANCEL,mode);
610 keydef("Key_Shift_Command","KEY_SCOMMAND",KEY_SCOMMAND,mode);
613 keydef("Key_Shift_Copy","KEY_SCOPY",KEY_SCOPY,mode);
616 keydef("Key_Shift_Create","KEY_SCREATE",KEY_SCREATE,mode);
619 keydef("Key_Shift_Delete_Char","KEY_SDC",KEY_SDC,mode);
622 keydef("Key_Shift_Delete_Line","KEY_SDL",KEY_SDL,mode);
625 keydef("Key_Select","KEY_SELECT",KEY_SELECT,mode);
628 keydef("Key_Shift_End","KEY_SEND",KEY_SEND,mode);
631 keydef("Key_Shift_Clear_End_Of_Line","KEY_SEOL",KEY_SEOL,mode);
634 keydef("Key_Shift_Exit","KEY_SEXIT",KEY_SEXIT,mode);
637 keydef("Key_Shift_Find","KEY_SFIND",KEY_SFIND,mode);
640 keydef("Key_Shift_Help","KEY_SHELP",KEY_SHELP,mode);
643 keydef("Key_Shift_Home","KEY_SHOME",KEY_SHOME,mode);
646 keydef("Key_Shift_Insert_Char","KEY_SIC",KEY_SIC,mode);
649 keydef("Key_Shift_Cursor_Left","KEY_SLEFT",KEY_SLEFT,mode);
652 keydef("Key_Shift_Message","KEY_SMESSAGE",KEY_SMESSAGE,mode);
655 keydef("Key_Shift_Move","KEY_SMOVE",KEY_SMOVE,mode);
658 keydef("Key_Shift_Next_Page","KEY_SNEXT",KEY_SNEXT,mode);
661 keydef("Key_Shift_Options","KEY_SOPTIONS",KEY_SOPTIONS,mode);
664 keydef("Key_Shift_Previous_Page","KEY_SPREVIOUS",KEY_SPREVIOUS,mode);
667 keydef("Key_Shift_Print","KEY_SPRINT",KEY_SPRINT,mode);
670 keydef("Key_Shift_Redo","KEY_SREDO",KEY_SREDO,mode);
673 keydef("Key_Shift_Replace","KEY_SREPLACE",KEY_SREPLACE,mode);
676 keydef("Key_Shift_Cursor_Right","KEY_SRIGHT",KEY_SRIGHT,mode);
679 keydef("Key_Shift_Resume","KEY_SRSUME",KEY_SRSUME,mode);
682 keydef("Key_Shift_Save","KEY_SSAVE",KEY_SSAVE,mode);
685 keydef("Key_Shift_Suspend","KEY_SSUSPEND",KEY_SSUSPEND,mode);
688 keydef("Key_Shift_Undo","KEY_SUNDO",KEY_SUNDO,mode);
691 keydef("Key_Suspend","KEY_SUSPEND",KEY_SUSPEND,mode);
694 keydef("Key_Undo","KEY_UNDO",KEY_UNDO,mode);
697 keydef("Key_Mouse","KEY_MOUSE",KEY_MOUSE,mode);
700 keydef("Key_Resize","KEY_RESIZE",KEY_RESIZE,mode);
705 * Generate a constant with the given name. The second parameter
706 * is a reference to the ACS character in the acs_map[] array and
707 * will be translated into an index.
709 static void acs_def (const char *name, chtype *a)
711 int c = a - &acs_map[0];
712 printf(" %-24s : constant Character := ",name);
713 if (isprint(c) && (c!='`'))
716 printf("Character'Val (%d);\n",c);
720 * Generate the constants for the ACS characters
722 static void gen_acs (void)
725 acs_def("ACS_Upper_Left_Corner",&ACS_ULCORNER);
728 acs_def("ACS_Lower_Left_Corner",&ACS_LLCORNER);
731 acs_def("ACS_Upper_Right_Corner",&ACS_URCORNER);
734 acs_def("ACS_Lower_Right_Corner",&ACS_LRCORNER);
737 acs_def("ACS_Left_Tee",&ACS_LTEE);
740 acs_def("ACS_Right_Tee",&ACS_RTEE);
743 acs_def("ACS_Bottom_Tee",&ACS_BTEE);
746 acs_def("ACS_Top_Tee",&ACS_TTEE);
749 acs_def("ACS_Horizontal_Line",&ACS_HLINE);
752 acs_def("ACS_Vertical_Line",&ACS_VLINE);
755 acs_def("ACS_Plus_Symbol",&ACS_PLUS);
758 acs_def("ACS_Scan_Line_1",&ACS_S1);
761 acs_def("ACS_Scan_Line_9",&ACS_S9);
764 acs_def("ACS_Diamond",&ACS_DIAMOND);
767 acs_def("ACS_Checker_Board",&ACS_CKBOARD);
770 acs_def("ACS_Degree",&ACS_DEGREE);
773 acs_def("ACS_Plus_Minus",&ACS_PLMINUS);
776 acs_def("ACS_Bullet",&ACS_BULLET);
779 acs_def("ACS_Left_Arrow",&ACS_LARROW);
782 acs_def("ACS_Right_Arrow",&ACS_RARROW);
785 acs_def("ACS_Down_Arrow",&ACS_DARROW);
788 acs_def("ACS_Up_Arrow",&ACS_UARROW);
791 acs_def("ACS_Board_Of_Squares",&ACS_BOARD);
794 acs_def("ACS_Lantern",&ACS_LANTERN);
797 acs_def("ACS_Solid_Block",&ACS_BLOCK);
800 acs_def("ACS_Scan_Line_3",&ACS_S3);
803 acs_def("ACS_Scan_Line_7",&ACS_S7);
806 acs_def("ACS_Less_Or_Equal",&ACS_LEQUAL);
809 acs_def("ACS_Greater_Or_Equal",&ACS_GEQUAL);
812 acs_def("ACS_PI",&ACS_PI);
815 acs_def("ACS_Not_Equal",&ACS_NEQUAL);
818 acs_def("ACS_Sterling",&ACS_STERLING);
823 * Output some comment lines indicating that the file is generated.
824 * The name parameter is the name of the facility to be used in
827 static void prologue(const char *name)
829 printf("-- %s binding.\n",name);
830 printf("-- This module is generated. Please don't change it manually!\n");
831 printf("-- Run the generator instead.\n-- |");
833 printf("define(`M4_BIT_ORDER',`%s_Order_First')",little_endian ? "Low":"High");
837 * Write the prologue for the curses facility and make sure that
838 * KEY_MIN and KEY_MAX are defined for the rest of this source.
840 static void basedefs (void)
844 # define KEY_MAX 0777
846 printf("define(`M4_KEY_MAX',`8#%o#')",KEY_MAX);
848 # define KEY_MIN 0401
850 if (KEY_MIN == 256) {
851 fprintf(stderr,"Unexpected value for KEY_MIN: %d\n",KEY_MIN);
854 printf("define(`M4_SPECIAL_FIRST',`8#%o#')",KEY_MIN - 1);
858 * Write out the comment lines for the menu facility
860 static void menu_basedefs (void)
866 * Write out the comment lines for the form facility
868 static void form_basedefs (void)
874 * Write out the comment lines for the mouse facility
876 static void mouse_basedefs(void)
882 * Write the definition of a single color
884 static void color_def (const char *name, int value)
886 printf(" %-8s : constant Color_Number := %d;\n",name,value);
890 * Generate all color definitions
892 static void gen_color (void)
895 color_def ("Black",COLOR_BLACK);
898 color_def ("Red",COLOR_RED);
901 color_def ("Green",COLOR_GREEN);
904 color_def ("Yellow",COLOR_YELLOW);
907 color_def ("Blue",COLOR_BLUE);
910 color_def ("Magenta",COLOR_MAGENTA);
913 color_def ("Cyan",COLOR_CYAN);
916 color_def ("White",COLOR_WHITE);
921 * Generate the linker options for the base facility
923 static void gen_linkopts (void)
925 printf(" pragma Linker_Options (\"-lncurses\");\n");
929 * Generate the linker options for the menu facility
931 static void gen_menu_linkopts (void)
933 printf(" pragma Linker_Options (\"-lmenu\");\n");
937 * Generate the linker options for the form facility
939 static void gen_form_linkopts (void)
941 printf(" pragma Linker_Options (\"-lform\");\n");
945 * Generate the linker options for the panel facility
947 static void gen_panel_linkopts (void)
949 printf(" pragma Linker_Options (\"-lpanel\");\n");
952 static void gen_version_info (void)
954 printf(" NC_Major_Version : constant := %d; -- Major version of ncurses library\n", NCURSES_VERSION_MAJOR);
955 printf(" NC_Minor_Version : constant := %d; -- Minor version of ncurses library\n", NCURSES_VERSION_MINOR);
956 printf(" NC_Version : constant String := %c%d.%d%c; -- Version of ncurses library\n", '"',NCURSES_VERSION_MAJOR,NCURSES_VERSION_MINOR,'"');
960 * main() expects two arguments on the commandline, both single characters.
961 * The first character denotes the facility for which we generate output.
962 * Possible values are
966 * P - Pointer Device (Mouse)
968 * The second character then denotes the specific output that should be
969 * generated for the selected facility.
971 int main(int argc, char *argv[])
974 char *s = (char *)&x;
984 case 'B': /* The Base facility */
987 case 'A': /* chtype translation into Ada95 record type */
988 gen_attr_set("Character_Attribute_Set");
990 case 'K': /* translation of keycodes */
993 case 'B': /* write some initial comment lines */
996 case 'C': /* generate color constants */
999 case 'M': /* generate constants for the ACS characters */
1002 case 'L': /* generate the Linker_Options pragma */
1005 case 'O': /* generate definitions of the old key code names */
1008 case 'R': /* generate representation clause for Attributed character */
1009 gen_chtype_rep("Attributed_Character");
1011 case 'V': /* generate version info */
1018 case 'M': /* The Menu facility */
1021 case 'R': /* generate representation clause for Menu_Option_Set */
1022 gen_menu_opt_rep("Menu_Option_Set");
1024 case 'B': /* write some initial comment lines */
1027 case 'L': /* generate the Linker_Options pragma */
1028 gen_menu_linkopts();
1030 case 'I': /* generate representation clause for Item_Option_Set */
1031 gen_item_opt_rep("Item_Option_Set");
1037 case 'F': /* The Form facility */
1040 case 'R': /* generate representation clause for Form_Option_Set */
1041 gen_form_opt_rep("Form_Option_Set");
1043 case 'B': /* write some initial comment lines */
1046 case 'L': /* generate the Linker_Options pragma */
1047 gen_form_linkopts();
1049 case 'I': /* generate representation clause for Field_Option_Set */
1050 gen_field_opt_rep("Field_Option_Set");
1056 case 'P': /* The Pointer(=Mouse) facility */
1059 case 'B': /* write some initial comment lines */
1062 case 'M': /* generate representation clause for Mouse_Event */
1063 gen_mrep_rep("Mouse_Event");
1065 case 'L': /* generate the Linker_Options pragma */
1066 gen_panel_linkopts();