1\function{enable_top_status_line} 2\synopsis{Set the top_status_line: 1 enabled, 0 hidden} 3\usage{Void enable_top_status_line (Integer x);} 4\description 5 If x is non-zero, the top status line is enabled. If x is zero, the 6 top status line is disabled and hidden. 7\seealso{set_top_status_line} 8\done 9 10\function{menu_append_item} 11\synopsis{Append an entry to a menu} 12\usage{menu_append_item (menu, name, fun [,client_data])} 13#v+ 14 String_Type menu, name; 15 String_Type or Ref_Type fun; 16 Any_Type client_data 17#v- 18\description 19 The \var{menu_append_item} function appends a menu item called 20 \var{name} to the menu \var{menu}. If called with \3 arguments, 21 the third argument must be a string that will get executed or 22 called when the menu item is selected. 23 24 When called with \4 arguments, the \var{fun} argument may be either 25 a string or a reference to a function. When the item is selected, 26 the function will be called and \var{client_data} will be passed to 27 it. 28\seealso{menu_append_popup} 29\done 30 31\function{menu_append_popup} 32\synopsis{Append a popup menu to a menu} 33\usage{menu_append_popup (String_Type parent_menu, String_Type popup_name)} 34\description 35 The \var{menu_append_popup} function may be used to append a new 36 popup menu with name \var{popup_name} to the menu \var{parent_menu}, 37 which may either be another popup menu or a menu bar. 38\seealso{menu_append_item, menu_append_separator} 39\done 40 41\function{menu_append_separator} 42\synopsis{Append a separator to a menu} 43\usage{menu_append_separator (String_Type menu)} 44\description 45 The \var{menu_append_separator} function appends a menu item 46 separator to the menu \var{menu}. 47\seealso{menu_append_item, menu_append_popup} 48\done 49 50\function{menu_copy_menu} 51\synopsis{Copy a menu to another} 52\usage{menu_copy_menu (String_Type dest, String_Type src)} 53\description 54 Then \var{menu_copy_menu} function copies the menu item, which may 55 be another popup menu, to another popup menu. 56\seealso{menu_append_popup, menu_append_item} 57\done 58 59\function{menu_create_menu_bar} 60\synopsis{Create a menu bar} 61\usage{menu_create_menu_bar (String_Type name)} 62\description 63 The \var{menu_create_menu_bar} function may be used to create a new 64 menu bar called \var{name}. The new menu bar may be associated with 65 a buffer via the \var{menu_use_menu_bar} function. 66\seealso{menu_use_menu_bar, menu_append_popup} 67\done 68 69\function{menu_delete_item} 70\synopsis{Delete a menu item} 71\usage{menu_delete_item (String_Type name)} 72\description 73 The \var{menu_delete_item} function deletes the menu called 74 \var{name} and all of its submenus. 75\example 76 To delete the \exmp{System} menu from the global menu bar, use 77#v+ 78 menu_delete_item ("Global.S&ystem"); 79#v- 80\seealso{menu_delete_items} 81\done 82 83\function{menu_delete_items} 84\synopsis{Delete the items from a menu} 85\usage{menu_delete_items (String_Type menu)} 86\description 87 The \var{menu_delete_items} function deletes all the menu items 88 attached to a specified popup menu. However, unlike the related 89 function \var{menu_delete_item}, the popup menu itself will not be 90 removed. 91\seealso{menu_delete_item, menu_append_popup} 92\done 93 94\function{menu_insert_item} 95\synopsis{Insert an entry into a menu at a specified position} 96\usage{menu_insert_item (position, menu, name, fun [,client_data])} 97#v+ 98 Int_Type/String_Type position; 99 String_Type menu, name; 100 String_Type or Ref_Type fun; 101 Any_Type client_data; 102#v- 103\description 104 The \var{menu_insert_item} function inserts a menu item called 105 \var{name} to the menu \var{menu} at a specified position. 106 107 The insertion position may be specified as an integer, or as the 108 name of a menu item within \var{parent_menu}. When specified as an 109 integer, the insertion will take place at the corresponding 110 position of the menu, where zero denotes the first item. If the 111 position specifier is the name of a menu item, the the insertion 112 will take place before that item. 113 114 If called with \4 arguments, the third argument must be a string 115 that will get executed or called when the menu item is selected. 116 117 When called with \5 arguments, the \var{fun} argument may be either 118 a string or a reference to a function. When the item is selected, 119 the function will be called and \var{client_data} will be passed to 120 it. 121\seealso{menu_append_item, menu_insert_popup, menu_insert_separator} 122\done 123 124\function{menu_insert_popup} 125\synopsis{Inserts a popup menu into a menu at a specified position} 126\usage{menu_insert_popup (position, parent_menu, popup_name)} 127#v+ 128 Int_Type/String_Type position; 129 String_Type parent_menu, popup_name; 130#v- 131\description 132 The \var{menu_insert_popup} function will insert a popup menu with 133 name \var{popup_name} into a pre-existing popup menu or menu bar 134 with name given by {parent_menu}. 135 136 The insertion position may be specified as an integer, or as the 137 name of a menu item within \var{parent_menu}. When specified as an 138 integer, the insertion will take place at the corresponding 139 position of the menu, where zero denotes the first item. If the 140 position specifier is the name of a menu item, the the insertion 141 will take place before that item. 142\seealso{menu_append_popup, menu_insert_item, menu_insert_separator} 143\done 144 145\function{menu_insert_separator} 146\synopsis{Inserts a separator into a menu at a specified position} 147\usage{menu_insert_separator (position, parent_menu)} 148#v+ 149 Int_Type/String_Type position; 150 String_Type parent_menu; 151#v- 152\description 153 The \var{menu_insert_separator} function inserts a separator 154 into a pre-existing popup menu or menu bar with name given 155 by \var{parent_menu}. 156 157 The insertion position may be specified as an integer, or as the 158 name of a menu item within \var{parent_menu}. When specified as an 159 integer, the insertion will take place at the corresponding 160 position of the menu, where zero denotes the first item. If the 161 position specifier is the name of a menu item, the the insertion 162 will take place before that item. 163\seealso{menu_append_separator, menu_insert_item, menu_insert_popup} 164\done 165 166\function{menu_select_menu} 167\synopsis{Select a menu item} 168\usage{menu_select_menu (String_Type menu)} 169\description 170 This function allows interpreter access to a specified menu it. If 171 the parameter specifies a popup menu, then the corresponding menu 172 will be invoked. Otherwise the function bound to the specified menu 173 will be called. 174\example 175 menu_select_menu ("Global.&File"); 176 menu_select_menu ("Global.&File.Save &Buffers"); 177\seealso{menu_insert_item} 178\done 179 180\function{menu_set_init_menubar_callback} 181\synopsis{Set the initialize menu bar callback} 182\usage{menu_set_init_menubar_callback (Ref_Type cb)} 183\description 184 The \var{menu_set_init_menubar_callback} may be used to specify the 185 function that is to be called whenever a menu bar may need to be 186 updated. This may be necessary when the user switches buffers or 187 modes. The callback function must accept a single argument which is 188 the name of the menubar. 189\seealso{menu_set_select_menubar_callback, menu_create_menu_bar} 190\done 191 192\function{menu_set_menu_bar_prefix} 193\synopsis{Set the prefix string to be displayed on the menu bar} 194\usage{menu_set_menu_bar_prefix (String_Type menubar, String_Type prefix)} 195\description 196 The \var{menu_set_menu_bar_prefix} specifies the string that is to 197 be displayed on the specified menu bar. The default prefix is 198 \exmp{"F10 key ==> "}. 199\seealso{menu_create_menu_bar} 200\done 201 202\function{menu_set_object_available} 203\synopsis{Set the availablity of a menu item} 204\usage{menu_set_object_available (String_Type menuitem, Int_Type flag)} 205\description 206 The \var{menu_set_object_available} function may be used to activate 207 or inactivate the specified menu item, depending upon whether 208 \var{flag} is non-zero or zero, respectively. 209\seealso{menu_append_item} 210\done 211 212\function{menu_set_select_menubar_callback} 213\synopsis{Set the function to be called when the menu bar is activated} 214\usage{menu_set_select_menubar_callback (String_Type menubar, Ref_Type f)} 215\description 216 The \var{menu_set_select_menubar_callback} function is used to 217 indicate that the function whose reference is \var{f} should be 218 called whenever the menu bar is selected. The callback function is 219 called with one argument: the name of the menu bar. 220\seealso{menu_set_init_menubar_callback, menu_set_select_popup_callback} 221\done 222 223\function{menu_set_select_popup_callback} 224\synopsis{Specify the function to be called prior to a popup} 225\usage{menu_set_select_popup_callback (String_Type popup, Ref_Type f} 226\description 227 The \var{menu_set_select_popup_callback} function may be used to 228 specify a function that should be called just before a popup menu is 229 displayed. The callback function must be defined to take a single 230 argument, namely the name of the popup menu. 231 232 The basic purpose of this function is to allow the creation of a 233 dynamic popup menu. For this reason, the popup menu will have its 234 items deleted before the callback function is executed. 235\seealso{menu_set_select_menubar_callback, menu_append_item} 236\done 237 238\function{menu_use_menu_bar} 239\synopsis{Associate a menu bar with the current buffer} 240\usage{menu_use_menu_bar (String_Type menubar)} 241\description 242 The \var{menu_use_menu_bar} function may be used to associate a 243 specified menu bar with the current buffer. If no menu bar has been 244 associated with a buffer, the \exmp{"Global"} menu bar will be used. 245\seealso{menu_create_menu_bar} 246\done 247 248\function{set_top_status_line} 249\synopsis{Set the string to be displayed at the top of the display} 250\usage{String set_top_status_line (String str);} 251\description 252 This functions sets the string to be displayed at the top of the 253 display. It returns the value of the line that was previously 254 displayed. 255\seealso{enable_top_status_line} 256\done 257 258