emacs-devel
[Top][All Lists]
Advanced

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

Re: Drawing to cairo context from within emacs module?


From: Stefan Monnier
Subject: Re: Drawing to cairo context from within emacs module?
Date: Thu, 05 Dec 2019 09:11:11 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> A related but different question. Would it be possible to get access to
> the raw buffer data from dynamic modules? (That is, pointer to the start,
> length and gap information.)

You might like to talk with Stephen Leake
<address@hidden>.
IIUC he wrote a dynamic module which parses the buffer.  AFAICT he
didn't use such a "raw" access, so it'd be interesting to hear about
his experience.

> I'm only interested in read-only access, and I'd be happy to patch it
> in myself if it's deemed generally acceptable.

It would tend to expose internal data subject to change (and offer the
ability to change this data in a way that can break some invariants), so
it's definitely not in the style of the current module interface.

But we may be able to provide a slightly less "raw" access that doesn't
suffer in the same way.  So details about your particular needs would be
helpful to try and figure out what we can do (i.e. tell us the problems
you face when using `char-after` or `buffer-substring`, which would be
the main ways I can think of to access the buffer's content with the
current module API).


        Stefan




reply via email to

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