bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#16243: 24.3.50; shr-visit-file doesn't set the buffer's default-dire


From: Eli Zaretskii
Subject: bug#16243: 24.3.50; shr-visit-file doesn't set the buffer's default-directory
Date: Wed, 25 Dec 2013 05:48:24 +0200

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: 16243@debbugs.gnu.org
> Date: Tue, 24 Dec 2013 22:02:46 +0100
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > Not really sure what you meant here.  shr-visit-file is about local
> > files, right?  So what URL and which HTTP are relevant here, and why?
> 
> To make relative URLs expand correctly, file://directory/file/is/in
> should be passed in as the base directory.

I'm not sure such a directory value will do what we want.  The value
should be a local file name.  E.g., on Windows typing RET on a link
will eventually call a function that needs to be able to produce an
absolute file name by calling expand-file-name.

Either that, or change the function invoked by RET to let-bind the
buffer's directory to the right value.

> > Which special mode buffers?  I actually don't quite understand why
> > buffer-file-name isn't set to the name of the file we visit.
> 
> `shr-visit-file' doesn't really visit a file.  It just does a rendering
> based on it.  If `buffer-file-name' is set to the file, and you save
> what you see, you destroy the .html file you see a rendering of.

Then don't allow to save.





reply via email to

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