public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* set width: how to restore to auto
@ 2023-08-23  9:53 Aleksey Midenkov
  2023-08-23 12:14 ` Pedro Alves
  0 siblings, 1 reply; 2+ messages in thread
From: Aleksey Midenkov @ 2023-08-23  9:53 UTC (permalink / raw)
  To: gdb

[-- Attachment #1: Type: text/plain, Size: 314 bytes --]

To avoid line wrapping in backtrace we use:

    set width 0

How to restore it to auto without resizing the terminal?
Why after resizing the terminal defined width is lost?

Looks like there is not enough control over this parameter to implement two
backtrace macros with and without line wrapping.

-- 
@midenok

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: set width: how to restore to auto
  2023-08-23  9:53 set width: how to restore to auto Aleksey Midenkov
@ 2023-08-23 12:14 ` Pedro Alves
  0 siblings, 0 replies; 2+ messages in thread
From: Pedro Alves @ 2023-08-23 12:14 UTC (permalink / raw)
  To: Aleksey Midenkov, gdb

On 23/08/23 10:53, Aleksey Midenkov via Gdb wrote:
> To avoid line wrapping in backtrace we use:
> 
>     set width 0
> 
> How to restore it to auto without resizing the terminal?

I guess having "set width/height auto" would make sense.

> Why after resizing the terminal defined width is lost?

Indeed, "auto" could fix this, by making anything non-auto stick.

I suggest filing a bug report about this.

> 
> Looks like there is not enough control over this parameter to implement two
> backtrace macros with and without line wrapping.
> 

If it's just the one command you want to wrap, you can do:

 (gdb) alias bt0 = with width 0 -- backtrace
 (gdb) bt0 [ARG...]
 ...


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-08-23 12:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-23  9:53 set width: how to restore to auto Aleksey Midenkov
2023-08-23 12:14 ` Pedro Alves

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).