emacs-devel
[Top][All Lists]
Advanced

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

Re: best way to display alternate view of file


From: Stefan Monnier
Subject: Re: best way to display alternate view of file
Date: Wed, 19 Apr 2017 11:01:11 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

> What's the idiomatic way to do a mode like this in Elisp?

I don't think there's one idiomatic way to do this.
- For HTML and Info we have commands that create (and display) a separate
  buffer containing the rendering.
- For doc-view-mode and hexl-mode we have commands we swap between the
  two views within the same buffer (usually using C-c C-c to go back to
  the "source", but it could probably be used more generally as "swap").
- In nhexl-mode, the user-view is similar to hexl-mode, but the buffer
  is not modified (the rendering is done via overlays and `display`
  text properties).
The first option is usually easier.


        Stefan




reply via email to

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