From 026fbfa60eb7e94b4c7a6f340d433acb1eb7b7ad Mon Sep 17 00:00:00 2001 From: Andrew Burgess Date: Fri, 28 Jan 2022 11:49:54 +0000 Subject: [PATCH] gdb/doc: update docs for 'info win' and 'winheight' commands This started by noticing that the docs for 'winheight' are out of date, the docs currently give a specific list of possible window names. However, now that windows can be implemented in Python, it is not possible to list all possible names. I now link the user to a mechanism by which they can discover the valid names for themselves at run time (by using 'info win'). That, and the fact that gdb provides tab-completion of the name at the command line, feels good enough. Finally, I noticed that the docs for 'win info' don't explicitly say that the name of the window is given in the output. This could probably have been inferred, but given I'm now linking to this as a mechanism to find the window name, I'd prefer to mention that the name can be found in the output. --- gdb/doc/gdb.texinfo | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index fe81687a66c..2073d929099 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -28812,9 +28812,10 @@ otherwise a default layout is used. @kindex tui disable Disable TUI mode, returning to the console interpreter. +@anchor{info_win_command} @item info win @kindex info win -List and give the size of all displayed windows. +List the names and sizes of all currently displayed windows. @item tui new-layout @var{name} @var{window} @var{weight} @r{[}@var{window} @var{weight}@dots{}@r{]} @kindex tui new-layout @@ -28961,11 +28962,11 @@ Update the source window and the current execution point. @item winheight @var{name} +@var{count} @itemx winheight @var{name} -@var{count} @kindex winheight -Change the height of the window @var{name} by @var{count} -lines. Positive counts increase the height, while negative counts -decrease it. The @var{name} parameter can be one of @code{src} (the -source window), @code{cmd} (the command window), @code{asm} (the -disassembly window), or @code{regs} (the register display window). +Change the height of the window @var{name} by @var{count} lines. +Positive counts increase the height, while negative counts decrease +it. The @var{name} parameter can be the name of any currently visible +window. The names of the currently visible windows can be discovered +using @kbd{info win} (@pxref{info_win_command,,info win}). @end table @node TUI Configuration -- 2.30.2