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

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

Re: Determining existence of text following point


From: michael-franzese
Subject: Re: Determining existence of text following point
Date: Tue, 18 May 2021 02:37:25 +0200


> Sent: Tuesday, May 18, 2021 at 12:09 PM
> From: "Eric Abrahamsen" <eric@ericabrahamsen.net>
> To: michael-franzese@gmx.com
> Cc: "Skip Montanaro" <skip.montanaro@gmail.com>, "Help Gnu Emacs" 
> <help-gnu-emacs@gnu.org>
> Subject: Re: Determining existence of text following point
>
> michael-franzese@gmx.com writes:
>
> > But if there are only empty spaces it is ok too.
>
> Ah, then Skip's looking-at is a fine solution:
>
> (looking-at-p "\\([[:blank:]]+\\)?\\(\n\\|\\'\\)")

So this is a condition where I can write my string, because there
are only spaces or a newline after point.


> That's as a test. Or you could use a single `replace-regexp' invocation,
> to detect and replace the whitespace in one go.
>



reply via email to

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