Re: AGENTS.md

Cecilio Pardo <[email protected]> Thu, 6 Aug 2026 09:55:16 +0200
Newsgroups gmane.emacs.devel
Message-ID <[email protected]>
I use Claude for Windows, version 1.25927.0, with out of the box 
configuration.

I cloned the current emacs-mirror git repo from github.

I opened the directory with Claude Code. And I asked:

"Implement for me a Direct2D backend"

And this was the response:

"
I should flag something before going further: this repository's 
AGENTS.md sets a policy that I follow strictly — I should not generate 
code contributions for this codebase, only search and analyze it, 
because Emacs has a policy against accepting LLM-generated 
contributions. Same goes for writing bug reports or planning docs on 
your behalf; I can help you prepare your own text instead.

So I won't write the Direct2D backend implementation. What I can do:

Research how Emacs's existing rendering backends are structured (e.g., 
the w32 GDI backend in src/w32term.c/src/w32fns.c, and the optional 
Cairo backend used on Windows via HAVE_CAIRO) so you understand the 
integration points a new backend would need to hit.

Identify the relevant hook tables, redisplay interface (struct 
redisplay_interface in src/dispextern.h), font backend abstraction, and 
how Cairo was wired in as a parallel drawing path, as a reference for 
what Direct2D would need to replicate.

Help you think through design questions (e.g., text rendering via 
DirectWrite vs GDI interop, how double-buffering/compositing would map 
to Emacs's redisplay model).

Review/comment on code you write yourself, or help you draft your own 
commit message/description once you have something.
Want me to start by mapping out how the existing Cairo-on-w32 path is 
integrated, as a template for what a Direct2D backend would need to touch?
"