1'\" t 2 .\" $OpenBSD: menu_mark.3,v 1.9 2023年10月17日 09:52:10 nicm Exp $ 3 .\" 4 .\"*************************************************************************** 5 .\" Copyright 2018-2022,2023 Thomas E. Dickey * 6 .\" Copyright 1998-2010,2015 Free Software Foundation, Inc. * 7 .\" * 8 .\" Permission is hereby granted, free of charge, to any person obtaining a * 9 .\" copy of this software and associated documentation files (the * 10 .\" "Software"), to deal in the Software without restriction, including * 11 .\" without limitation the rights to use, copy, modify, merge, publish, * 12 .\" distribute, distribute with modifications, sublicense, and/or sell * 13 .\" copies of the Software, and to permit persons to whom the Software is * 14 .\" furnished to do so, subject to the following conditions: * 15 .\" * 16 .\" The above copyright notice and this permission notice shall be included * 17 .\" in all copies or substantial portions of the Software. * 18 .\" * 19 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * 20 .\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * 21 .\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * 22 .\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * 23 .\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * 24 .\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * 25 .\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * 26 .\" * 27 .\" Except as contained in this notice, the name(s) of the above copyright * 28 .\" holders shall not be used in advertising or otherwise to promote the * 29 .\" sale, use or other dealings in this Software without prior written * 30 .\" authorization. * 31 .\"*************************************************************************** 32 .\" 33 .\" $Id: menu_mark.3,v 1.9 2023年10月17日 09:52:10 nicm Exp $ 34 .TH menu_mark 3 2023年07月01日 "ncurses 6.4" "Library calls" 35 .SH NAME 36\fBset_menu_mark\fP, 37\fBmenu_mark\fP \- get and set the menu mark string 38 .SH SYNOPSIS 39\fB#include <menu.h>\fP 40 .sp 41\fBint set_menu_mark(MENU *\fImenu\fB, const char *\fImark\fB);\fR 42 .br 43\fBconst char *menu_mark(const MENU *\fImenu\fB);\fR 44 .SH DESCRIPTION 45In order to make menu selections visible on older terminals without 46highlighting or color capability, the menu library marks selected items 47in a menu with a prefix string. 48 .PP 49The function \fBset_menu_mark\fP sets the mark string for the given menu. 50Calling \fBset_menu_mark\fP with a null menu item will abolish the mark string. 51Note that changing the length of the mark string for a menu while the 52menu is posted is likely to produce unhelpful behavior. 53 .PP 54The default string is "\-" (a dash). 55Calling \fBset_menu_mark\fP with 56a non-\fBNULL\fP menu argument will change this default. 57 .PP 58The function \fBmenu_mark\fP returns the menu's mark string (or \fBNULL\fP if 59there is none). 60 .SH RETURN VALUE 61The function \fBmenu_mark\fP returns a pointer (which may be \fBNULL\fP). 62It does not set \fBerrno\fP. 63 .PP 64The function \fBset_menu_mark\fP may return the following error codes: 65 .TP 5 66 .B E_OK 67The routine succeeded. 68 .TP 5 69 .B E_BAD_ARGUMENT 70Routine detected an incorrect or out-of-range argument. 71 .TP 5 72 .B E_SYSTEM_ERROR 73System error occurred (see \fBerrno\fP(3)). 74 .SH SEE ALSO 75\fBcurses\fP(3), \fBmenu\fP(3). 76 .SH NOTES 77The header file \fB<menu.h>\fP automatically includes the header file 78\fB<curses.h>\fP. 79 .SH PORTABILITY 80These routines emulate the System V menu library. 81They were not supported on 82Version 7 or BSD versions. 83 .SH AUTHORS 84Juergen Pfeifer. 85Manual pages and adaptation for new curses by Eric S. Raymond. 86