emacs-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] nextstep: Emacs can be used to edit PDF files


From: Alan Third
Subject: Re: [PATCH] nextstep: Emacs can be used to edit PDF files
Date: Sat, 20 Nov 2021 19:51:26 +0000

On Sat, Nov 20, 2021 at 08:06:20AM -0500, Stefan Monnier wrote:
> Stefan Kangas [2021-11-20 04:55:17] wrote:
> 
> > Stefan Monnier <monnier@iro.umontreal.ca> writes:
> >
> >> Any chance we could change doc-view so it works without `gs` (nor
> >> `mupdf`) using one of the tools pre-installed in macOS?
> >
> > It seems like we could, from searching the web there's apparently a tool
> > called "sips" that is pre-installed on macOS.  I just checked my machine
> > and I have it there.
> >
> > AFAICT, you can't convert only one page with it, only the full page.
> > But it seems to be a hard requirement of a
> > `doc-view-pdf->png-converter-function' that we can specify a page number
> > to it, so I'm not sure how tricky it is to fit into what we have now.
> >
> > Maybe someone more familiar with doc-view could take a look.
> 
> Apparently it might also be possible to do it via AppleScript
> (according to 
> http://preserve.mactech.com/articles/mactech/Vol.21/21.03/BasicImageManipulation/index.html)

NSImage supports loading of PDF files natively. In fact, as I
understand it the entire NEXTstep API is built on some sort of PDF
technology. (Or is it PostScript? It only supports EPS natively, not
standard PostScript...)

I've yet to work out how to teach Emacs to open files using the native
support. It can obviously do it because it manages it for PNG, JPEG,
etc., I just need to work it out for HEIC and PDF.
-- 
Alan Third



reply via email to

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