On Sat, Mar 15, 2025 at 8:21 AM Eli Zaretskii wrote: > > From: Ship Mints > > Date: Fri, 14 Mar 2025 10:26:28 -0400 > > Cc: 76980@debbugs.gnu.org > > > > +Bind @code{window-state-normalize-buffer-name} to non-@code{nil} to > > +normalize buffer names under @file{uniquify} management by removing its > > +adornments, otherwise using nominal buffer names. This helps restore > ^^^^^^^^^^ > I'd use a simpler "prefixes and suffixes" here. > > And what is the "otherwise using nominal buffer names" part about? > > > ++++ > > +*** New variable 'window-state-normalize-buffer-name'. > > +When bound to non-nil, 'window-state-get' will normalize buffer names by > > +removing 'uniquify' adornments, otherwise using nominal buffer names. > > +This helps restore window buffers across Emacs sessions. > > Same here. > > > +(defun window--state-normalize-buffer-name (buffer) > > + "Normalize BUFFER name, accommodating `uniquify'. > > +If BUFFER is under `uniquify' management, return its `buffer-name' with > > +adornments removed; otherwise return BUFFER `buffer-name'." > > And here. > Refined patch attached.