On 27/08/2025, Arash Esbati wrote:


> Meanwhile, we can wait and see what others say.  One thing occurred to
> me is that whole machinery kicks in once the buffer is changed due to
> this, I think:
>
> --8<---------------cut here---------------start------------->8---
> ;; Enable automatic preview update on change.
> (add-hook 'LaTeX-mode-hook
>           (lambda () (add-hook 'after-change-functions
>                                #'preview-point-buf-change nil t)))
> --8<---------------cut here---------------end--------------->8---
>
> Is there a way to start the generation process upon visiting a file?  Or
> am I missing something?

In theory, one should just add a call to `preview-buffer` in the hook to 
prepare all previews (preferably with some way to silence the preview message). 
However, the preview seems to fail for some reason.
Maybe the `LaTeX-mode-hook` is being called too early? I need to investigate it.

On 27/08/2025, Uwe Brauer wrote:
> BTW have tried it  out together with preview-auto (by Paul
> Nelson)?

I have. I found preview-auto to be overly complicated and too prone to fail in 
my tests, so I implemented my own automatic previewing mechanism which turned 
out to be much simpler. The code above enables this.

Best regards,
-- Al

Reply via email to