From: Emanuel Berg via Users list for the GNU Emacs text editor <help-gnu-emacs@gnu.org>
To: help-gnu-emacs@gnu.org
Subject: Re: Reading from a buffer
Date: Wed, 01 Jul 2020 21:20:13 +0200 [thread overview]
Message-ID: <87sgebqbyq.fsf@ebih.ebihd> (raw)
In-Reply-To: CADSjfO4qbKCxq9iqvynKxUKmQHBQ=t3oEnwrqFKRXVEApXwYZg@mail.gmail.com
Greg Hill wrote:
> I've pretty well mastered the process of *writing
> to* a buffer using *insert* and *format*, but
> I haven't been able to find any equally easy way to
> read that same information back. I've hacked
> together a workaround using *copy-to-register*,
> *get-register* and *read-from-string*, but surely
> there must be a more straightforward approach than
> that. I've searched and searched through all the
> documentation and have come up with nothing for
> doing a simple formatted read from buffer.
> Any suggestions?
(buffer-substring ...)
(with-current-buffer ".emacs"
(buffer-substring-no-properties (point-min) (point-max)) )
(buffer-string)
--
underground experts united
http://user.it.uu.se/~embe8573
https://dataswamp.org/~incal
next prev parent reply other threads:[~2020-07-01 19:20 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-01 19:12 Reading from a buffer Greg Hill
2020-07-01 19:19 ` Eli Zaretskii
2020-07-01 19:20 ` Emanuel Berg via Users list for the GNU Emacs text editor [this message]
2020-07-01 19:21 ` Jakub Jankiewicz
2020-07-01 19:21 ` Jakub Jankiewicz
-- strict thread matches above, loose matches on Subject: below --
2020-07-01 20:19 Greg Hill
2020-07-01 21:10 ` Stefan Monnier
2020-07-02 0:39 ` Emanuel Berg via Users list for the GNU Emacs text editor
2020-07-03 3:38 ` Jean-Christophe Helary
2020-07-03 6:33 ` Greg Hill
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87sgebqbyq.fsf@ebih.ebihd \
--to=help-gnu-emacs@gnu.org \
--cc=moasenwood@zoho.eu \
/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.
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).