]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
man/man2const/TIOCLINUX.2const: Document missing TIOCL_SETSEL selection modes: TIOCL_...
authorGünther Noack <gnoack3000@gmail.com>
Sun, 30 Mar 2025 14:30:40 +0000 (16:30 +0200)
committerAlejandro Colomar <alx@kernel.org>
Mon, 31 Mar 2025 08:46:05 +0000 (10:46 +0200)
Documents the following TIOCL_SETSEL sub-operations:

*  TIOCL_SELPOINTER
*  TIOCL_SELCLEAR
*  TIOCL_SELMOUSEREPORT

These previously undocumented selection modes for the Linux console
are implemented in <drivers/tty/vt/selection.c>.  The name "selection
mode" is slightly misleading as not all of them actually manipulate
the kernel's mouse selection buffer.

Includes clarified semantics pointed out by Jared Finder.

Cc: Hanno Böck <hanno@hboeck.de>
Cc: Jann Horn <jannh@google.com>
Cc: Jiri Slaby <jirislaby@kernel.org>
Cc: Jakub Wilk <jwilk@jwilk.net>
Signed-off-by: Günther Noack <gnoack3000@gmail.com>
Message-ID: <20250330143038.4184-5-gnoack3000@gmail.com>
Acked-by: Jared Finder <jared@finder.org>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
man/man2const/TIOCLINUX.2const

index f2c8d0720a00ccd78cb520a83abc3ac6b219f2e5..61f1c596d0497d355a30caa2b480dd5d8e11fb83 100644 (file)
@@ -84,6 +84,40 @@ Select line-by-line,
 expanding the selection outwards to select full lines.
 The indicated screen characters are highlighted
 and saved in a kernel buffer.
+.TP
+.B TIOCL_SELPOINTER
+Show the pointer at position
+.RI ( xs ,\~ ys )
+or
+.RI ( xe ,\~ ye ),
+whichever is later in text flow order.
+.TP
+.B TIOCL_SELCLEAR
+Remove the current selection highlight, if any,
+from the console holding the selection.
+.IP
+This does not affect the stored selected text.
+.TP
+.B TIOCL_SELMOUSEREPORT
+Make the terminal report
+.RI ( xs ,\~ ys )
+as the current mouse location
+using the
+.BR xterm (1)
+mouse tracking protocol
+(see
+.BR console_codes (4)).
+The lower 4 bits of
+.I sel_mode
+.RB ( TIOCL_SELBUTTONMASK )
+indicate the desired button press and
+modifier key information for the mouse event.
+.\" <https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h3-Normal-tracking-mode>
+.IP
+If mouse reporting is not enabled for the terminal,
+this operation yields an
+.B EINVAL
+error.
 .RE
 .IP
 Since Linux 6.7, using this subcode requires the