bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#39181: 27.0.50; [PATCH] Allow users to store & restore gdb-mi layout


From: Štěpán Němec
Subject: bug#39181: 27.0.50; [PATCH] Allow users to store & restore gdb-mi layout
Date: Fri, 20 Mar 2020 21:58:34 +0100
User-agent: Notmuch/0.29.3 (https://notmuchmail.org) Emacs/28.0.50 (x86_64-pc-linux-gnu)

On Fri, 20 Mar 2020 16:03:45 -0400
Yuan Fu wrote:

> Here it is.

Thank you! A few comments:

> diff --git a/doc/emacs/building.texi b/doc/emacs/building.texi
> index 38963f225c..130abc41e8 100644
> --- a/doc/emacs/building.texi
> +++ b/doc/emacs/building.texi
> @@ -568,7 +568,7 @@ Starting GUD
>  
>  @item M-x gud-gdb
>  @findex gud-gdb
> -Run GDB, using a GUD interaction buffer for input and output to the
> +Run GDB, using a GUD action buffer for input and output to the
                        ^^^^^^
Is there really any reason for this change? If the buffer is "for
input and output", isn't "interaction" more fitting than "action"?

[...]

> +  You can customize the window layout bese on the one above, and save
                                         ^^^^
"based"?

> +the custom layout to a file by @code{gdb-save-window-configuration}.
                               ^^
I think "using" would be better here.

> +Then you can later load this layout back by
                                            ^^
same here

> +@code{gdb-load-window-configuration}.  (Simply put, window

[...]

> +@code{gdb-default-window-configuration-file}.  If it is not an
> +absolute path, GDB looks under
> +@code{gdb-window-configuration-directory} (default to
> +@file{~/.emacs.d}) for the file.

"(which defaults to user-emacs-directory)" (ideally with a proper
reference to that variable).

[...]

> +premium.  If you choose to start GDB in the same frame, consider
> +setting @code{gdb-restore-window-configuration-after-quit} to
> +non-@code{nil}.  Then GDB restores your original window layout after

"to a non-nil value.  Your original window layout will then be restored
after GDB quits."

> +it quits.  Set to @code{t} to always restore; set to
              ^^^^^^
"Set it to" or "Use", similarly for the following ones.

> +@code{if-gdb-many-windows} to restore only when
> +@code{gdb-many-windows} is @code{t}; set to @code{if-gdb-show-main} to
> +restore only when @code{gdb-show-main} is @code{t}.

IIUC, these two `t's for gdb-show-main and gdb-many-windows should
really be "non-nil"s, i.e., there is no special treatment of the symbol
`t' as opposed to generalized boolean.

> diff --git a/etc/NEWS b/etc/NEWS
> index 87e634f2c1..692ecf7f0a 100644
> --- a/etc/NEWS
> +++ b/etc/NEWS
> @@ -174,6 +174,22 @@ key             binding
>  / v             package-menu-filter-by-version
>  / /             package-menu-filter-clear
>  
> +** gdb-mi
> +
> +*** gdb-mi can now store and restore window configurations.
> +Use 'gdb-save-window-configuration' to save window configuration to a
> +file, and 'gdb-load-window-configuration' to load from a file.  They
                                                                   ^^^^
"These commands"?

> +can also be accessed through menu bar under Gud -- GDB-Windows.

[...]

> +*** gdb-mi can now restore window configuration after finished.
                                                   ^^^^^^^^^^^^^^
"when finished" or "after quit"

> +Set 'gdb-restore-window-configuration-after-quit' to non-nil and GDB
                                                                    ^^^
Better say "Emacs": at that point GDB is gone. :-)

-- 
Štěpán





reply via email to

[Prev in Thread] Current Thread [Next in Thread]