1 .\"***************************************************************************
2 .\" Copyright 2018-2022,2023 Thomas E. Dickey *
3 .\" Copyright 1998-2010,2017 Free Software Foundation, Inc. *
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: *
13 .\" The above copyright notice and this permission notice shall be included *
14 .\" in all copies or substantial portions of the Software. *
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. *
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 *
28 .\"***************************************************************************
30 .\" $Id: curs_insch.3x,v 1.36 2023/12/23 16:03:24 tom Exp $
31 .TH curs_insch 3X 2023-12-23 "ncurses 6.4" "Library calls"
47 insert a \fIcurses\fR character in a window
50 \fB#include <curses.h>\fP
52 \fBint insch(chtype \fIch\fP);
53 \fBint winsch(WINDOW *\fIwin\fP, chtype \fIch\fP);
54 \fBint mvinsch(int \fIy\fP, int \fIx\fP, chtype \fIch\fP);
55 \fBint mvwinsch(WINDOW *\fIwin\fP, int \fIy\fP, int \fIx\fP, chtype \fIch\fP);
58 These functions insert the
62 at the cursor in the specified window
66 The character previously at the cursor and any to its right move one
68 the rightmost character on the line is discarded.
69 The cursor does not advance.
71 These functions return \fBOK\fP on success and \fBERR\fP on failure.
75 pointer argument fail if the pointer is
78 Functions prefixed with \*(``mv\*('' first perform cursor movement using
79 \fB\%wmove\fP and fail if the position
82 is outside the window.
88 is not necessarily employed.
94 may be implemented as macros.
96 X/Open Curses, Issue 4, describes these functions.
98 SVr4 describes successful return values only as
99 \*(``an integer value other than \fBERR\fP\*(''.
101 \fB\%curs_ins_wch\fP(3X) describes comparable functions in the