From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: Re: [Patch] org-display-inline-images: Add support for remote images Date: Tue, 25 Nov 2014 16:23:35 +0100 Message-ID: <873897718o.fsf@gmx.us> References: <87vbm3of2o.fsf@selenimh.mobile.lan> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49751) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XtHyA-0004u1-O8 for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 10:24:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XtHy4-00053I-D9 for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 10:23:58 -0500 Received: from plane.gmane.org ([80.91.229.3]:40925) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XtHy4-00053B-5V for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 10:23:52 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XtHy2-0007Rp-Rg for emacs-orgmode@gnu.org; Tue, 25 Nov 2014 16:23:50 +0100 Received: from 109.201.152.230 ([109.201.152.230]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 25 Nov 2014 16:23:50 +0100 Received: from rasmus by 109.201.152.230 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 25 Nov 2014 16:23:50 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Kit-Yan Choi writes: >> Thanks for your patch. However, I wonder if we really want this. Remote >> images could be slow to fetch, and it would make buffer unusable. > > I personally needed this functionality. I have tried to reduce the amount > of time spent on fetching the images by checking whether the images have > been fetched before and whether the remote files are newer. Yes these > communications take time as it should be expected if one opens an org file > remotely (therefore connection should have been made) or when one specifies > a remote image as path and wants to display it inline. > Perhaps I could add an option flag or ask a question before fetching for > user to decide whether to display remote images or not? In case the > behaviour of displaying remote images inline is not desired? One scenario > I can think of is that `org-startup-with-inline-images' is set to true and > the file is sometimes visited remotely. > Any opinion or comment on this, please? I recently worked with remote pictures for html-slides. The slides were stored on my github powered website, and the pictures were hosted on my owncloud. So I definitely see the merits of Kit-Yan's proposal. Also, remote files will work in HTML, but not in latex or odt (I think), so local caching could maybe also be applied, optionally, when exporting documents. org-startup-with-inline-images should have an equivalent file-variable that takes priority, and probably org-startup-with-inline-images should default to nil. The above is of course "IMO". —Rasmus -- Got mashed potatoes. Ain't got no T-Bone. No T-Bone