1*51ffecc1SBen Gras.\" $NetBSD: curses_keyname.3,v 1.5 2008/04/30 13:10:51 martin Exp $ 2*51ffecc1SBen Gras.\" Copyright (c) 2002 The NetBSD Foundation, Inc. 3*51ffecc1SBen Gras.\" All rights reserved. 4*51ffecc1SBen Gras.\" 5*51ffecc1SBen Gras.\" This code is derived from software contributed to The NetBSD Foundation 6*51ffecc1SBen Gras.\" by Julian Coleman. 7*51ffecc1SBen Gras.\" 8*51ffecc1SBen Gras.\" Redistribution and use in source and binary forms, with or without 9*51ffecc1SBen Gras.\" modification, are permitted provided that the following conditions 10*51ffecc1SBen Gras.\" are met: 11*51ffecc1SBen Gras.\" 1. Redistributions of source code must retain the above copyright 12*51ffecc1SBen Gras.\" notice, this list of conditions and the following disclaimer. 13*51ffecc1SBen Gras.\" 2. Redistributions in binary form must reproduce the above copyright 14*51ffecc1SBen Gras.\" notice, this list of conditions and the following disclaimer in the 15*51ffecc1SBen Gras.\" documentation and/or other materials provided with the distribution. 16*51ffecc1SBen Gras.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 17*51ffecc1SBen Gras.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 18*51ffecc1SBen Gras.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 19*51ffecc1SBen Gras.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 20*51ffecc1SBen Gras.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 21*51ffecc1SBen Gras.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 22*51ffecc1SBen Gras.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 23*51ffecc1SBen Gras.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 24*51ffecc1SBen Gras.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 25*51ffecc1SBen Gras.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 26*51ffecc1SBen Gras.\" POSSIBILITY OF SUCH DAMAGE. 27*51ffecc1SBen Gras.\" 28*51ffecc1SBen Gras.Dd October 17, 2007 29*51ffecc1SBen Gras.Dt CURSES_KEYNAME 3 30*51ffecc1SBen Gras.Os 31*51ffecc1SBen Gras.Sh NAME 32*51ffecc1SBen Gras.Nm curses_keyname , 33*51ffecc1SBen Gras.Nm keyname 34*51ffecc1SBen Gras.Nd curses report key name routine 35*51ffecc1SBen Gras.Sh LIBRARY 36*51ffecc1SBen Gras.Lb libcurses 37*51ffecc1SBen Gras.Sh SYNOPSIS 38*51ffecc1SBen Gras.In curses.h 39*51ffecc1SBen Gras.Ft "char *" 40*51ffecc1SBen Gras.Fn keyname "int key" 41*51ffecc1SBen Gras.Sh DESCRIPTION 42*51ffecc1SBen GrasThe function 43*51ffecc1SBen Gras.Fn keyname 44*51ffecc1SBen Grasgenerates a character string containing a description of the key specified in 45*51ffecc1SBen Gras.Fa key . 46*51ffecc1SBen Gras.Pp 47*51ffecc1SBen GrasThe string is formatted according to the following table: 48*51ffecc1SBen Gras.Bl -column "Meta + control character" "KEY_MIN - KEY_MAX" "String format" 49*51ffecc1SBen Gras.It "Description" Ta "Key range" Ta "String format" 50*51ffecc1SBen Gras.It Li "Control character" Ta "0 - 31" Ta "^X" 51*51ffecc1SBen Gras.It Li "Visible character" Ta "32 - 126" Ta "X" 52*51ffecc1SBen Gras.It Li "Delete character" Ta "127" Ta "^?" 53*51ffecc1SBen Gras.It Li "Meta + control character" Ta "128 - 158" Ta "M-^X" 54*51ffecc1SBen Gras.It Li "Meta + visible character" Ta "159 - 254" Ta "M-X" 55*51ffecc1SBen Gras.It Li "Meta + delete character" Ta "255" Ta "M-^?" 56*51ffecc1SBen Gras.It Li "Named key" Ta "KEY_MIN - KEY_MAX" Ta "KEY_EXIT" 57*51ffecc1SBen Gras.It Li "Unknown key" Ta "" Ta "-1" 58*51ffecc1SBen Gras.El 59*51ffecc1SBen Gras.Sh SEE ALSO 60*51ffecc1SBen Gras.Xr curses_input 3 61*51ffecc1SBen Gras.Sh NOTE 62*51ffecc1SBen GrasThe return value of 63*51ffecc1SBen Gras.Fn keyname 64*51ffecc1SBen Grasis a static buffer, which will be overwritten on a subsequent call. 65*51ffecc1SBen Gras.Sh STANDARDS 66*51ffecc1SBen GrasThe 67*51ffecc1SBen Gras.Nx 68*51ffecc1SBen GrasCurses library complies with the X/Open Curses specification, part of the 69*51ffecc1SBen GrasSingle Unix Specification. 70*51ffecc1SBen Gras.Sh HISTORY 71*51ffecc1SBen GrasThese functions first appeared in 72*51ffecc1SBen Gras.Nx 2.0 . 73