From mboxrd@z Thu Jan 1 00:00:00 1970 From: Richard Stanton Subject: Re: Problem exporting to PDF (and viewing) Date: Fri, 18 May 2012 14:45:13 -0700 Message-ID: <40C7B1BFC291ED4E9D10436D07736A33470478BC46@EXMAIL7.haas.uc.berkeley.edu> References: <40C7B1BFC291ED4E9D10436D07736A33470478B315@EXMAIL7.haas.uc.berkeley.edu> <23805.1336833570@alphaville> <40C7B1BFC291ED4E9D10436D07736A33470478B372@EXMAIL7.haas.uc.berkeley.edu> <31430.1336884795@alphaville> <40C7B1BFC291ED4E9D10436D07736A33470478BC1E@EXMAIL7.haas.uc.berkeley.edu> <12464.1337375470@alphaville> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:46286) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SVUzT-0004X6-EP for emacs-orgmode@gnu.org; Fri, 18 May 2012 17:45:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SVUzR-00085b-E0 for emacs-orgmode@gnu.org; Fri, 18 May 2012 17:45:38 -0400 Received: from gateway-b.haas.berkeley.edu ([128.32.222.40]:18595) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SVUzR-00085G-8S for emacs-orgmode@gnu.org; Fri, 18 May 2012 17:45:37 -0400 In-Reply-To: <12464.1337375470@alphaville> Content-Language: en-US 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: "nicholas.dokos@hp.com" Cc: "emacs-orgmode@gnu.org" , Jonathan Leech-Pepin > -----Original Message----- > From: nicholas.dokos@hp.com [mailto:nicholas.dokos@hp.com] > Sent: Friday, May 18, 2012 2:11 PM > To: Richard Stanton > Cc: emacs-orgmode@gnu.org; Jonathan Leech-Pepin > Subject: Re: [O] Problem exporting to PDF (and viewing) >=20 > Richard Stanton wrote: >=20 > > > > 2) If not, where is the code that interprets %s? I can try > > > > stepping through it and see what I can find. > > > > > > > > > > It happens in org.el:org-open-file, specifically this piece of the co= de (I > think): > > > > > > ,---- > > > | (while (string-match "%s" cmd) > > > | (setq cmd (replace-match > > > | (save-match-data > > > | (shell-quote-argument > > > | (convert-standard-filename file))) > > > | t t cmd))) > > > `---- > > > > I did some tracing through, and have found where things go wrong. > > > > At the start of the code listed above, > > > > cmd =3D "c:/progra~1/sumatrapdf/sumatrapdf.exe %s" > > file =3D "c:/dropbox/org/personal.pdf" > > > > (convert-standard-filename file) returns "C:/dropbox/org/personal.pdf" > > > > So far so good... > > > > However, > > > > (shell-quote-argument (convert-standard-filename file)) returns > > "c\\:dropbox/org/personal.pdf" > > >=20 > Does it really drop the slash in front of "dropbox"? When I do that on my > system, the : is quoted, but the slash is left alone: >=20 >=20 > (setq s "C:/dropbox/org/personal.pdf") > "C:/dropbox/org/personal.pdf" > (shell-quote-argument s) > "C\\:/dropbox/org/personal.pdf" > system-type > gnu/linux >=20 > If it does indeed drop the slash, can you try just putting it back and le= aving > the backslashes alone? Oops. I must have deleted it somehow while transcribing. No, the slash is l= eft alone: "c\\:/Dropbox/org/personal.pdf"