Re: [PATCHv3 1/2] Initial TUI mouse support

Pedro Alves
2021-06-04T16:24:16Z

On 2021-06-04 5:06 p.m., Hannes Domani wrote:
> Am Freitag, 4. Juni 2021, 17:20:44 MESZ hat Pedro Alves <pedro@palves.net> Folgendes geschrieben:

>>
>> Don't we need a NEWS entry, though?
>
> I never think of NEWS.
>
> See at the end what I came up with, maybe the phrasing could need some
> improvement.
>

>
> From 95c7890b45cbfb80682451962f5e57f3eef95a03 Mon Sep 17 00:00:00 2001
> From: Hannes Domani <ssbssa@yahoo.de>
> Date: Fri, 4 Jun 2021 17:58:15 +0200
> Subject: [PATCH] Mention mouse support in NEWS
>
> gdb/ChangeLog:
>
> 2021-06-04  Hannes Domani  <ssbssa@yahoo.de>
>
>     * NEWS: Mention mouse support.
> ---
>  gdb/NEWS | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/gdb/NEWS b/gdb/NEWS
> index ab678acec8b..8c876e71e63 100644
> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -75,6 +75,9 @@
>    and "-eiex" that allow options (that would normally appear in a
>    gdbearlyinit file) to be passed on the command line.
>
> +* TUI windows now support mouse actions.  The mouse wheel scrolls the
> +  appropriate window, and Python TUI windows can receive mouse click events.
> +

I think you should (also or in alternative) mention the Python bits in the "Python API" section.

It would be nice if we had a section in the manual for the TUI mouse too. I suspect we'll end up
with some settings/knobs to configure mouse support, and that'd be the place to add them.

We can start small, IMO. How about this?

From: Pedro Alves <pedro@palves.net>
Date: 2021-06-04 17:12:41 +0100

Document TUI mouse support in the manual

gdb/doc/ChangeLog:
yyyy-mm-dd Pedro Alves <pedro@palves.net>

* gdb.texinfo (TUI): <TUI Mouse Support>: New node/section.

---

gdb/doc/gdb.texinfo | 8 ++++++++
1 file changed, 8 insertions(+)

diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 90d827a50e7..486df2ec5f4 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -28372,6 +28372,7 @@ enable} or @kbd{C-x C-a}. @xref{TUI Commands, ,TUI Commands}, and
* TUI Overview:: TUI overview
* TUI Keys:: TUI key bindings
* TUI Single Key Mode:: TUI single key mode
+* TUI Mouse Support:: TUI mouse support
* TUI Commands:: TUI-specific commands
* TUI Configuration:: TUI configuration variables
@end menu
@@ -28661,6 +28662,13 @@ If @value{GDBN} was built with Readline 8.0 or later, the TUI
SingleKey keymap will be named @samp{SingleKey}. This can be used in
@file{.inputrc} to add additional bindings to this keymap.

+@node TUI Mouse Support
+@section TUI Mouse Support
+@cindex TUI mouse support
+
+The TUI supports mouse actions. You can click on TUI windows to
+select them, and the mouse wheel scrolls the appropriate window.
+
@node TUI Commands
@section TUI-specific Commands
@cindex TUI commands