emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Drag images from Firefox to org-mode


From: Nicolas Richard
Subject: Re: [O] Drag images from Firefox to org-mode
Date: Sun, 20 Oct 2013 22:42:27 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Oleh <address@hidden> writes:
> This can be fixed with a platform-aware function that checks both the
> clipboard and the cut-buffer.

I suggest to ask for a string with (read-string "URL: " nil nil default),
offering the content of the clipboard/kill ring/selections as the DEFAULT.
I think it's better to be explicit when downloading content, and there
isn't much overhead in asking for a confirmation.

> This can be fixed by adding `org-download-max-filename-length`. When
> it 
> overflows, just resort to `default-directory' and provide a
> message/option to fix.

I suggest that the right place for those files is as attachment, and
that's where customization should happen. The function choosing the
right place (i.e. org-download--dir) could be turned into a defvar or
defcustom which could then be set either to #'org-download--dir or
#'org-attach-dir.

> By the way, which system doesn't allow for spaces in directory names?

ISTR that MSDOS (except the latest versions) didn't allow spaces in
filenames :) Anyway, I tend to avoid spaces as much as I can in
filenames (including dirs)

>     If you want the ability to create arbitrary output directories
>     based
>     on document context, the customization can be made to accept a
>     function (lambda) as a value, which could then return a directory
>     prefix.
> This isn't an option for users with no elisp skills.

It is an option if there are enough examples/built-ins that can be used.
e.g. message-send-mail-function can be customized in this way, its
docstring gives a list of meaningful values.

-- 
Nico.



reply via email to

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