From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Hannon Subject: monospace (=) and quotes not getting along Date: Thu, 25 Aug 2011 15:02:33 -0700 (PDT) Message-ID: <1314309753.93337.YahooMailNeo@web161917.mail.bf1.yahoo.com> Reply-To: Michael Hannon Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0-678613661-1314309753=:93337" Return-path: Received: from eggs.gnu.org ([140.186.70.92]:59327) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qwi0R-0004ar-MQ for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 18:02:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qwi0Q-0003yO-9d for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 18:02:35 -0400 Received: from nm29.bullet.mail.bf1.yahoo.com ([98.139.212.188]:22149) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1Qwi0Q-0003yJ-6U for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 18:02:34 -0400 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: Org-Mode List --0-678613661-1314309753=:93337 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Greetings.=A0 I have another dumb question related to HTML export.=A0 In th= e=0Adocument I'm revising I have some R code and some references to R varia= bles.=0AI'd like the R code and variables to appear in monospaced font.=A0 = This seems=0Aeasy enough.=A0 Here's an example that works as I want it to w= ork:=0A=0A=A0=A0=A0 To define =3Dmy_foobar=3D in this model, we issue the c= ommand:=0A=0A=A0=A0=A0=A0=A0=A0=A0 =3D> my_foobar =3D dataset$foobar=3D=0A= =0AI've got a whole series of similar expressions, and they mostly do work,= but=0Ahere's one that doesn't:=0A=0A=A0=A0=A0 To define =3Dmy_frabbitz=3D = in this model, we issue the command:=0A=0A=A0=A0=A0=A0=A0=A0=A0 =3D> my_fra= bbitz =3D "someRandomWord"=3D=0A=0AThe "my_frabbitz" in the sentence comes = out in monospace, but the R code=0Adoesn't.=A0 It seems that the quotation = marks are killing the process.=0A=0AI've tried a number of stupid quoting t= ricks, such as using:=0A=0A=A0=A0=A0 ...\"someRandomWord\"=3D=0A=A0=A0=A0 .= ..""someRandomWord""=3D=0A=0Aetc., but they typically make things worse.=0A= =0ABTW, using the begin/end_example construct does more or less what I want= , but=0Ait breaks the flow of the document, and there are many places in th= e document=0Awhere the =3D...=3D construct works just fine and gives the lo= ok I need.=0A=0AAny suggestions?=0A=0AThanks,=0A=0A-- Mike --0-678613661-1314309753=:93337 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable
Greetings.  I have anoth= er dumb question related to HTML export.  In the
document I'm revis= ing I have some R code and some references to R variables.
I'd like the = R code and variables to appear in monospaced font.  This seems
easy= enough.  Here's an example that works as I want it to work:

&n= bsp;   To define =3Dmy_foobar=3D in this model, we issue the comm= and:

        =3D> my_foobar = =3D dataset$foobar=3D

I've got a whole series of similar expressions= , and they mostly do work, but
here's one that doesn't:

 &nb= sp;  To define =3Dmy_frabbitz=3D in this model, we issue the command:<= br>
        =3D> my_frabbitz =3D "= someRandomWord"=3D

The "my_frabbitz" in the sentence comes out in mo= nospace, but the R code
doesn't.  It seems that the quotation marks are killing the= process.

I've tried a number of stupid quoting tricks, such as usin= g:

    ...\"someRandomWord\"=3D
   = ...""someRandomWord""=3D

etc., but they typically make things worse= .

BTW, using the begin/end_example construct does more or less what = I want, but
it breaks the flow of the document, and there are many place= s in the document
where the =3D...=3D construct works just fine and give= s the look I need.

Any suggestions?

Thanks,

-- Mike
--0-678613661-1314309753=:93337-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Gauland Subject: Re: monospace (=) and quotes not getting along Date: Thu, 25 Aug 2011 23:45:02 +0000 (UTC) Message-ID: References: <1314309753.93337.YahooMailNeo@web161917.mail.bf1.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([140.186.70.92]:56714) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qwjbq-0005RU-Gz for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 19:45:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qwjbp-0002iH-M6 for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 19:45:18 -0400 Received: from lo.gmane.org ([80.91.229.12]:52746) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qwjbp-0002i1-Fm for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 19:45:17 -0400 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Qwjbm-0000pY-5U for emacs-orgmode@gnu.org; Fri, 26 Aug 2011 01:45:14 +0200 Received: from 114-134-8-118.rurallink.co.nz ([114.134.8.118]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 26 Aug 2011 01:45:14 +0200 Received: from mikelygee by 114-134-8-118.rurallink.co.nz with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 26 Aug 2011 01:45:14 +0200 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 Michael Hannon yahoo.com> writes: > To define =my_frabbitz= in this model, we issue the command: >    => my_frabbitz = "someRandomWord"= > The "my_frabbitz" in the sentence comes out in monospace, but the > R codedoesn't.  It seems that the quotation marks are killing the process. I don't remember why this happens, but I've dealt with it by inserting a null between the quote and the equals. I use export hooks to remove the null from the exported HTML and LaTeX files: (add-hook 'org-export-latex-final-hook (lambda () (goto-char (point-min)) (while (re-search-forward "^@" nil t) (replace-match "") ) ) ) (add-hook 'org-export-html-final-hook (lambda () (goto-char (point-min)) (while (re-search-forward "^@" nil t) (replace-match "") ) ) ) --(a different) Mike From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Hannon Subject: Re: monospace (=) and quotes not getting along Date: Thu, 25 Aug 2011 20:53:45 -0700 (PDT) Message-ID: <1314330825.88981.YahooMailNeo@web161908.mail.bf1.yahoo.com> References: <1314309753.93337.YahooMailNeo@web161917.mail.bf1.yahoo.com> Reply-To: Michael Hannon Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0-972816286-1314330825=:88981" Return-path: Received: from eggs.gnu.org ([140.186.70.92]:40789) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QwnUK-0003BS-JG for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 23:53:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QwnUJ-0007HA-6a for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 23:53:48 -0400 Received: from nm2.bullet.mail.bf1.yahoo.com ([98.139.212.161]:34213) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1QwnUI-0007Gu-Th for emacs-orgmode@gnu.org; Thu, 25 Aug 2011 23:53:47 -0400 In-Reply-To: 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: Michael Gauland , "emacs-orgmode@gnu.org" --0-972816286-1314330825=:88981 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Michael Gauland wrote:=0A=0A> Michael Hannon = yahoo.com> writes:=0A> =0A> > To define =3Dmy_frabbitz=3D i= n this model, we issue the command:=0A> >=A0=A0=A0 =3D> my_frabbitz =3D "so= meRandomWord"=3D=0A> > The "my_frabbitz" in the sentence comes out in monos= pace, but the=0A> > R codedoesn't.=A0 It seems that the quotation marks are= killing the process.=0A> =0A> I don't remember why this happens, but I've = dealt with it by inserting a null=0A> between the quote and the equals. I u= se export hooks to remove the null from=0A> the=0A> exported HTML and LaTeX= files:=0A> =0A> =0A> (add-hook 'org-export-latex-final-hook=0A>=A0=A0=A0= =A0=A0=A0 (lambda ()=0A>=A0=A0=A0=A0=A0=A0=A0=A0 (goto-char (point-min))=0A= >=A0=A0=A0=A0=A0=A0=A0=A0 (while (re-search-forward "^@" nil t)=0A>=A0=A0= =A0=A0=A0=A0=A0=A0=A0=A0 (replace-match "")=0A>=A0=A0=A0=A0=A0=A0=A0=A0=A0= =A0 )=0A>=A0=A0=A0=A0=A0=A0=A0=A0 )=0A>=A0=A0=A0=A0=A0=A0 )=0A> (add-hook '= org-export-html-final-hook=0A>=A0=A0=A0=A0=A0=A0 (lambda ()=0A>=A0=A0=A0=A0= =A0=A0=A0=A0 (goto-char (point-min))=0A>=A0=A0=A0=A0=A0=A0=A0=A0 (while (re= -search-forward "^@" nil t)=0A>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 (replace-matc= h "")=0A>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 )=0A>=A0=A0=A0=A0=A0=A0=A0=A0 )=0A>= =A0=A0=A0=A0=A0=A0 )=0A=0AHi, Mike.=A0 I was going to object that this was = a dangerous approach in my=0Asituation, as I intend to pass the .org file o= n to someone else after I've=0Arevised it, and there'd be no way to guarant= ee that "future generations" would=0Ahave the same hooks defined.=0A=0ANeve= rtheless, I tried inserting ^@ as you suggested and then exporting to=0AHTM= L, WITHOUT defining the hooks, just to see what would happen.=A0 The answer= =0Ais that the HTML document looked just fine!=A0 (This is with Org-mode ve= rsion=0A7.7 on Emacs 23.2.1 on 64-bit linux.)=0A=0AI don't know if this mat= ters, but I placed the LHS and RHS of the R expression=0Aon different, cons= ecutive lines, as:=0A=0A=A0=A0=A0 =3D> someVar =3D=3D=0A=A0=A0=A0 =3D^@"som= eString"^@=3D=0A=0AIn HTML these are glommed together anyway.=0A=0AI really= appreciate your suggestion.=A0 And, if anybody asks me, I'll be=0Arecommen= ding you for a MacArthur award.=0A=0A-- Mike --0-972816286-1314330825=:88981 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable
Michael Gauland <mikelygee@no8w= ireless.co.nz> wrote:

> Michael Hannon <jm_hannon <at>= ; yahoo.com> writes:
>
> > To define =3Dmy_frabbitz=3D i= n this model, we issue the command:
> >    =3D> = my_frabbitz =3D "someRandomWord"=3D
> > The "my_frabbitz" in the s= entence comes out in monospace, but the
> > R codedoesn't.  I= t seems that the quotation marks are killing the process.
>
> = I don't remember why this happens, but I've dealt with it by inserting a nu= ll
> between the quote and the equals. I use export hooks to remove t= he null from
> the
> exported HTML and LaTeX files:
> >
> (add-hook 'org-export-latex-final-hook
>  &n= bsp;    (lambda ()
>         (goto-char (poi= nt-min))
>         (while (re= -search-forward "^@" nil t)
>      &nbs= p;    (replace-match "")
>    &nbs= p;      )
>     &nb= sp;   )
>       )
> (ad= d-hook 'org-export-html-final-hook
>     &nb= sp; (lambda ()
>         (got= o-char (point-min))
>        = (while (re-search-forward "^@" nil t)
>     = ;      (replace-match "")
>   = ;        )
>   &nbs= p;     )
>       )

Hi, Mike.  I w= as going to object that this was a dangerous approach in my
situation, a= s I intend to pass the .org file on to someone else after I've
revised i= t, and there'd be no way to guarantee that "future generations" would
ha= ve the same hooks defined.

Nevertheless, I tried inserting ^@ as you= suggested and then exporting to
HTML, WITHOUT defining the hooks, just = to see what would happen.  The answer
is that the HTML document loo= ked just fine!  (This is with Org-mode version
7.7 on Emacs 23.2.1 = on 64-bit linux.)

I don't know if this matters, but I placed the LHS= and RHS of the R expression
on different, consecutive lines, as:
    =3D> someVar =3D=3D
    =3D^@"some= String"^@=3D

In HTML these are glommed together anyway.

I rea= lly appreciate your suggestion.  And, if anybody asks me, I'll be
recommending you for a MacArthur award.

-- Mike

=
--0-972816286-1314330825=:88981--