all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stephen Berman <stephen.berman@gmx.net>
To: Heime <heimeborgia@protonmail.com>
Cc: Heime via Users list for the GNU Emacs text editor
	<help-gnu-emacs@gnu.org>
Subject: Re: Printing \\= in the docstring
Date: Tue, 16 Jul 2024 10:25:36 +0200	[thread overview]
Message-ID: <878qy1920v.fsf@gmx.net> (raw)
In-Reply-To: <HusQp4hGr0jD7gYD-UE1ZvXASRwuLGmbnvusP6cfIIH5ZZB5CKv8oP8Il3B003vs5SGA4z5Q-Cr8XcTmgH6Tq9JgHlTCxqX44icx3k2IPSE=@protonmail.com> (Heime's message of "Tue, 16 Jul 2024 08:20:05 +0000")

On Tue, 16 Jul 2024 08:20:05 +0000 Heime <heimeborgia@protonmail.com> wrote:

> On Tuesday, July 16th, 2024 at 11:10 AM, Stephen Berman
> <stephen.berman@gmx.net> wrote:
>
>> On Mon, 15 Jul 2024 22:43:26 +0000 Heime heimeborgia@protonmail.com wrote:
>>
>> > On Tuesday, July 16th, 2024 at 9:22 AM, Heime heimeborgia@protonmail.com wrote:
>> >
>> > > How can I print \\= in the docstring ?
>> >
>> > When I try \\= the = does not display. Neither does \\\\= or \\\=
>>
>>
>> To print the sequence "\\=" as a string but not as a doc string escape
>> sequence, using "\\\\=" does work. But if you want to print it in the
>> context of a doc string escape sequence, you have to double it, just
>> like you have to double "\" in normal Lisp strings. For example, this
>> in a doc string:
>>
>> "\\\\=\\=\\=`\\\\(\\\\s-\\\\\\\\=\\\\=\\\\=\\\\[\\\\-\\\\]\\\\s-\\\\)\\\\(.*\\\\)
>> uses \\\\\\\\=" appears like this in a "*Help*" buffer:
>> \\\\=`\(\s-\\=\[\-\]\s-\)\(.*\) uses \\=
>>
>> Steve Berman
>
> If I use "\\\\=" the only thing that is displayed is "\" when using "C-h v myvar".

It works in the example I gave just above.  As so often you have not
provided a complete reproducer, so I can only try to guess why what you
did does not work.  But I won't guess now.

Steve Berman



  reply	other threads:[~2024-07-16  8:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <WOGXhoHXi-ghoVidse8cDwgfvmLUKIRqLxBwbF97alGfbnXgAISYEy9GKfzTC6yCqxaCn4Yjks7lzl_bTZyEuhIv91aWowm9r3whjcWlmz0=@protonmail.com>
2024-07-15 22:43 ` Printing \\= in the docstring Heime
2024-07-15 23:10   ` Stephen Berman
2024-07-16  8:20     ` Heime
2024-07-16  8:25       ` Stephen Berman [this message]
2024-07-16  8:32         ` Heime
2024-07-16  8:49           ` Stephen Berman
2024-07-16 10:56             ` Stephen Berman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=878qy1920v.fsf@gmx.net \
    --to=stephen.berman@gmx.net \
    --cc=heimeborgia@protonmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.