Debian Codegraph @

upstream/debian-trixie/man3/delch.3ncurses

raw
1 .\"***************************************************************************
2 .\" Copyright 2018-2024,2025 Thomas E. Dickey *
3 .\" Copyright 1998-2006,2010 Free Software Foundation, Inc. *
4 .\" *
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: *
12 .\" *
13 .\" The above copyright notice and this permission notice shall be included *
14 .\" in all copies or substantial portions of the Software. *
15 .\" *
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. *
23 .\" *
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 *
27 .\" authorization. *
28 .\"***************************************************************************
29 .\"
30 .\" $Id: curs_delch.3x,v 1.47 2025/01/19 00:49:39 tom Exp $
31 .TH delch 3NCURSES 2025-01-18 "ncurses 6.5" "Library calls"
32 .ie \n(.g \{\
33 .ds `` \(lq
34 .ds '' \(rq
35 .\}
36 .el \{\
37 .ie t .ds `` ``
38 .el .ds `` ""
39 .ie t .ds '' ''
40 .el .ds '' ""
41 .\}
42 .SH NAME
43 \fB\%delch\fP,
44 \fB\%wdelch\fP,
45 \fB\%mvdelch\fP,
46 \fB\%mvwdelch\fP \-
47 delete a character from a \fIcurses\fR window
48 .SH SYNOPSIS
49 .nf
50 \fB#include <curses.h>
51 .PP
52 \fBint delch(void);
53 \fBint wdelch(WINDOW * \fIwin\fP);
54 \fBint mvdelch(int \fIy\fP, int \fIx\fP);
55 \fBint mvwdelch(WINDOW * \fIwin\fP, int \fIy\fP, int \fIx\fP);
56 .fi
57 .SH DESCRIPTION
58 .B \%wdelch
59 deletes the character at the cursor position in
60 .IR win .
61 It moves all characters to the right of the cursor on the same line to
62 the left one position and replaces the contents of the rightmost
63 position on the line with the window's background character;
64 see \fB\%bkgd\fP(3NCURSES)
65 (wide-character API users: \fB\%bkgrnd\fP(3NCURSES)).
66 The cursor position does not change
67 (after moving to
68 .RI ( y ,
69 .IR x ),
70 if specified).
71 \fB\%ncurses\fP(3NCURSES) describes the variants of this function.
72 .SH RETURN VALUE
73 These functions return
74 .B OK
75 on success and
76 .B ERR
77 on failure.
78 .PP
79 In
80 .IR \%ncurses ,
81 they return
82 .B ERR
83 if
84 .I win
85 is
86 .IR NULL "."
87 .PP
88 Functions prefixed with \*(``mv\*('' first perform cursor movement and
89 fail if the position
90 .RI ( y ,
91 .IR x )
92 is outside the window boundaries.
93 .SH NOTES
94 .BR \%delch ,
95 .BR \%mvdelch ,
96 and
97 .B \%mvwdelch
98 may be implemented as macros.
99 .PP
100 A terminal's
101 .B \%delete_character
102 .RB ( dch1 )
103 capability
104 is not necessarily employed.
105 .SH PORTABILITY
106 X/Open Curses Issue\ 4 describes these functions.
107 It specifies no error conditions for them.
108 .PP
109 SVr4 describes a successful return value only as
110 \*(``an integer value other than
111 .IR ERR \*(''. \" Courier roman in source; SVID 4, vol. 3, p. 489
112 .SH HISTORY
113 SVr2 (1984) introduced
114 .IR \%wdelch "."
115 .SH SEE ALSO
116 \fB\%ncurses\fP(3NCURSES)