X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=man%2Fcurs_delch.3x;h=4062f9ed9d0b1dfac2076f32d841df5c22e52d7b;hp=d7973a98962026df076ee0df9bd3606caadd9903;hb=HEAD;hpb=3a9b6a3bf0269231bef7de74757a910dedd04e0c diff --git a/man/curs_delch.3x b/man/curs_delch.3x index d7973a98..96921587 100644 --- a/man/curs_delch.3x +++ b/man/curs_delch.3x @@ -1,39 +1,112 @@ -.TH curs_delch 3X "" +.\"*************************************************************************** +.\" Copyright 2018-2023,2024 Thomas E. Dickey * +.\" Copyright 1998-2006,2010 Free Software Foundation, Inc. * +.\" * +.\" Permission is hereby granted, free of charge, to any person obtaining a * +.\" copy of this software and associated documentation files (the * +.\" "Software"), to deal in the Software without restriction, including * +.\" without limitation the rights to use, copy, modify, merge, publish, * +.\" distribute, distribute with modifications, sublicense, and/or sell * +.\" copies of the Software, and to permit persons to whom the Software is * +.\" furnished to do so, subject to the following conditions: * +.\" * +.\" The above copyright notice and this permission notice shall be included * +.\" in all copies or substantial portions of the Software. * +.\" * +.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * +.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * +.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * +.\" IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * +.\" DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR * +.\" OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * +.\" THE USE OR OTHER DEALINGS IN THE SOFTWARE. * +.\" * +.\" Except as contained in this notice, the name(s) of the above copyright * +.\" holders shall not be used in advertising or otherwise to promote the * +.\" sale, use or other dealings in this Software without prior written * +.\" authorization. * +.\"*************************************************************************** +.\" +.\" $Id: curs_delch.3x,v 1.35 2024/05/11 20:39:53 tom Exp $ +.TH curs_delch 3X 2024-05-11 "ncurses @NCURSES_MAJOR@.@NCURSES_MINOR@" "Library calls" +.ie \n(.g \{\ +.ds `` \(lq +.ds '' \(rq +.\} +.el \{\ +.ie t .ds `` `` +.el .ds `` "" +.ie t .ds '' '' +.el .ds '' "" +.\} .SH NAME -\fBdelch\fR, \fBwdelch\fR, \fBmvdelch\fR, \fBmvwdelch\fR - -delete character under the cursor in a \fBcurses\fR window +\fB\%delch\fP, +\fB\%wdelch\fP, +\fB\%mvdelch\fP, +\fB\%mvwdelch\fP \- +delete a character from a \fIcurses\fR window .SH SYNOPSIS -\fB#include \fR - -\fBint delch(void);\fR -.br -\fBint wdelch(WINDOW *win);\fR -.br -\fBint mvdelch(int y, int x);\fR -.br -\fBint mvwdelch(WINDOW *win, int y, int x);\fR -.br +.nf +\fB#include +.PP +\fBint delch(void); +\fBint wdelch(WINDOW *\fIwin\fP); +\fBint mvdelch(int \fIy\fP, int \fIx\fP); +\fBint mvwdelch(WINDOW *\fIwin\fP, int \fIy\fP, int \fIx\fP); +.fi .SH DESCRIPTION -These routines delete the character under the cursor; all characters to the -right of the cursor on the same line are moved to the left one position and the -last character on the line is filled with a blank. The cursor position does -not change (after moving to \fIy\fR, \fIx\fR, if specified). (This does not -imply use of the hardware delete character feature.) +.B \%wdelch +deletes the character at the cursor position in +.IR win . +It moves all characters to the right of the cursor on the same line to +the left one position and replaces the contents of the rightmost +position on the line with the window's blank character; +see \fB\%bkgd\fP(3X) +(wide-character API users: \fB\%bkgrnd\fP(3X)). +The cursor position does not change +(after moving to +.RI ( y , +.IR x ), +if specified). +\fB\%ncurses\fP(3X) describes the variants of this function. .SH RETURN VALUE -All routines return the integer \fBERR\fR upon failure and an \fBOK\fR (SVr4 -specifies only "an integer value other than \fBERR\fR") upon successful -completion. +These functions return +.B OK +on success and +.B ERR +on failure. +.PP +Functions taking a +.I \%WINDOW +pointer argument fail if the pointer is +.BR NULL . +.PP +Functions prefixed with \*(``mv\*('' first perform cursor movement and +fail if the position +.RI ( y , +.IR x ) +is outside the window boundaries. .SH NOTES -Note that \fBdelch\fR, \fBmvdelch\fR, and \fBmvwdelch\fR may be macros. +.BR \%delch , +.BR \%mvdelch , +and +.B \%mvwdelch +may be implemented as macros. +.PP +A terminal's +.B \%delete_character +.RB ( dch1 ) +capability +is not necessarily employed. .SH PORTABILITY -These functions are described in the XSI Curses standard, Issue 4. The -standard specifies that they return \fBERR\fR on failure, but specifies no -error conditions. +X/Open Curses, +Issue 4 describes these functions. +It specifies no error conditions for them. +.PP +SVr4 +.I curses +describes a successful return value only as +\*(``an integer value other than +.BR ERR \*(''. .SH SEE ALSO -\fBcurses\fR(3X) -.\"# -.\"# The following sets edit modes for GNU EMACS -.\"# Local Variables: -.\"# mode:nroff -.\"# fill-column:79 -.\"# End: +\fB\%curses\fP(3X)