Skip to content

Locate program: where an edit lands in the output, and back - #4

Open
thomasjm wants to merge 4 commits into
masterfrom
synctex
Open

thomasjm wants to merge 4 commits into
masterfrom
synctex

Conversation

@thomasjm

Copy link
Copy Markdown
Contributor

Adds an optional --locate EXE program that maps between source positions and places in the output (for LaTeX, a SyncTeX lookup). Render programs are unchanged.

  • Each output that answers an edit carries position: the page box the edit landed in. The settle pass locates the same edit again.
  • codedown.render.locate (file, line, character → page box) and codedown.render.sourceAt (page, x, y → file, line, character) answer the same queries from the last render.
  • Queries name the copy the programs compiled (src/, overlay/), and answers under RENDER_WORK are mapped back to the documents they stand for, as with RENDER_DEPS.

Version 0.1.1.0; the protocol change is additive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant