emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Assistance customizing org-format-latex-options
@ 2013-09-18  3:52 John Hendy
  2013-09-18  4:09 ` Carsten Dominik
  2013-09-18  4:15 ` Carsten Dominik
  0 siblings, 2 replies; 5+ messages in thread
From: John Hendy @ 2013-09-18  3:52 UTC (permalink / raw)
  To: emacs-orgmode

Hi,


I'm running into a similar issue as I once did before:
- http://comments.gmane.org/gmane.emacs.orgmode/50452

When I'm writing a paragraph and have a dollar currency amount, Org's
footnote functionality (e.g. =C-x f=) does not work in the region.

The suggestion was to remove "$" from org-format-latex-options.

I've not customized a variable with many "sub-options." Can someone
give me an example of how to directly customize just the :matchers
portion of that variable in .emacs? I prefer to set options directly
vs. having a jumbled list of customizations in custom-set-variables.

I searched around and found this:
- http://stackoverflow.com/questions/11272236/how-to-make-formule-bigger-in-org-mode-of-emacs

It gives instructions on setting the :scale portion, which I tried to
adapt to :matchers like this:

(setq org-format-latex-options (plist-put org-format-latex-options
:matchers ("begin" "$1" "$$" "\\(" "\\[")))

As well as this:

(setq org-format-latex-options (plist-put org-format-latex-options
:matchers "("begin" "$1" "$$" "\\(" "\\[")"))

Both of those aren't parsing correctly. Sorry for my elisp munging ignorance!


Thanks!
John

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Assistance customizing org-format-latex-options
  2013-09-18  3:52 Assistance customizing org-format-latex-options John Hendy
@ 2013-09-18  4:09 ` Carsten Dominik
  2013-09-18  4:13   ` John Hendy
  2013-09-18  4:15 ` Carsten Dominik
  1 sibling, 1 reply; 5+ messages in thread
From: Carsten Dominik @ 2013-09-18  4:09 UTC (permalink / raw)
  To: John Hendy; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1709 bytes --]

Hi John,

don't be afraid of property lists - they are just ordinary
lists with alternating keys and values.

(setq org-format-latex-options
      '(:foreground default
        :background default
	:scale 1.0
	:html-foreground "Black"
	:html-background "Transparent"
	:html-scale 1.0 
        :matchers ("begin" "$1" "$$" "\\(" "\\[")))

HTH

- Carsten

On 18.9.2013, at 05:52, John Hendy <jw.hendy@gmail.com> wrote:

> Hi,
> 
> 
> I'm running into a similar issue as I once did before:
> - http://comments.gmane.org/gmane.emacs.orgmode/50452
> 
> When I'm writing a paragraph and have a dollar currency amount, Org's
> footnote functionality (e.g. =C-x f=) does not work in the region.
> 
> The suggestion was to remove "$" from org-format-latex-options.
> 
> I've not customized a variable with many "sub-options." Can someone
> give me an example of how to directly customize just the :matchers
> portion of that variable in .emacs? I prefer to set options directly
> vs. having a jumbled list of customizations in custom-set-variables.
> 
> I searched around and found this:
> - http://stackoverflow.com/questions/11272236/how-to-make-formule-bigger-in-org-mode-of-emacs
> 
> It gives instructions on setting the :scale portion, which I tried to
> adapt to :matchers like this:
> 
> (setq org-format-latex-options (plist-put org-format-latex-options
> :matchers ("begin" "$1" "$$" "\\(" "\\[")))
> 
> As well as this:
> 
> (setq org-format-latex-options (plist-put org-format-latex-options
> :matchers "("begin" "$1" "$$" "\\(" "\\[")"))
> 
> Both of those aren't parsing correctly. Sorry for my elisp munging ignorance!
> 
> 
> Thanks!
> John
> 


[-- Attachment #2: Message signed with OpenPGP using GPGMail --]
[-- Type: application/pgp-signature, Size: 455 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Assistance customizing org-format-latex-options
  2013-09-18  4:09 ` Carsten Dominik
@ 2013-09-18  4:13   ` John Hendy
  0 siblings, 0 replies; 5+ messages in thread
From: John Hendy @ 2013-09-18  4:13 UTC (permalink / raw)
  To: Carsten Dominik; +Cc: emacs-orgmode

On Tue, Sep 17, 2013 at 11:09 PM, Carsten Dominik
<carsten.dominik@gmail.com> wrote:
> Hi John,
>
> don't be afraid of property lists - they are just ordinary
> lists with alternating keys and values.
>
> (setq org-format-latex-options
>       '(:foreground default
>         :background default
>         :scale 1.0
>         :html-foreground "Black"
>         :html-background "Transparent"
>         :html-scale 1.0
>         :matchers ("begin" "$1" "$$" "\\(" "\\[")))
>

After sending the email, I remembered my typical hack of doing this
and set the value using `M-x customize-variable`, then examining what
it saved to .emacs. The above is, indeed, what it was. How might one
set it via the single property method in the StackOverflow post? I can
certainly do the above, though I only want to customize :matchers, so
perhaps it's a bit unnecessary?

I can't imagine the above biting me, but I could see that someone
might want to just target one property in the event that, say, they
want to override one of the above at buffer level and that somehow
conflicts with the whole set of properties existing in .emacs (just
brainstorming...)?


Thanks,
John


> HTH
>
> - Carsten
>
> On 18.9.2013, at 05:52, John Hendy <jw.hendy@gmail.com> wrote:
>
>> Hi,
>>
>>
>> I'm running into a similar issue as I once did before:
>> - http://comments.gmane.org/gmane.emacs.orgmode/50452
>>
>> When I'm writing a paragraph and have a dollar currency amount, Org's
>> footnote functionality (e.g. =C-x f=) does not work in the region.
>>
>> The suggestion was to remove "$" from org-format-latex-options.
>>
>> I've not customized a variable with many "sub-options." Can someone
>> give me an example of how to directly customize just the :matchers
>> portion of that variable in .emacs? I prefer to set options directly
>> vs. having a jumbled list of customizations in custom-set-variables.
>>
>> I searched around and found this:
>> - http://stackoverflow.com/questions/11272236/how-to-make-formule-bigger-in-org-mode-of-emacs
>>
>> It gives instructions on setting the :scale portion, which I tried to
>> adapt to :matchers like this:
>>
>> (setq org-format-latex-options (plist-put org-format-latex-options
>> :matchers ("begin" "$1" "$$" "\\(" "\\[")))
>>
>> As well as this:
>>
>> (setq org-format-latex-options (plist-put org-format-latex-options
>> :matchers "("begin" "$1" "$$" "\\(" "\\[")"))
>>
>> Both of those aren't parsing correctly. Sorry for my elisp munging ignorance!
>>
>>
>> Thanks!
>> John
>>
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Assistance customizing org-format-latex-options
  2013-09-18  3:52 Assistance customizing org-format-latex-options John Hendy
  2013-09-18  4:09 ` Carsten Dominik
@ 2013-09-18  4:15 ` Carsten Dominik
  2013-09-18  4:38   ` John Hendy
  1 sibling, 1 reply; 5+ messages in thread
From: Carsten Dominik @ 2013-09-18  4:15 UTC (permalink / raw)
  To: John Hendy; +Cc: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1637 bytes --]


On 18.9.2013, at 05:52, John Hendy <jw.hendy@gmail.com> wrote:

> Hi,
> 
> 
> I'm running into a similar issue as I once did before:
> - http://comments.gmane.org/gmane.emacs.orgmode/50452
> 
> When I'm writing a paragraph and have a dollar currency amount, Org's
> footnote functionality (e.g. =C-x f=) does not work in the region.
> 
> The suggestion was to remove "$" from org-format-latex-options.
> 
> I've not customized a variable with many "sub-options." Can someone
> give me an example of how to directly customize just the :matchers
> portion of that variable in .emacs? I prefer to set options directly
> vs. having a jumbled list of customizations in custom-set-variables.
> 
> I searched around and found this:
> - http://stackoverflow.com/questions/11272236/how-to-make-formule-bigger-in-org-mode-of-emacs
> 
> It gives instructions on setting the :scale portion, which I tried to
> adapt to :matchers like this:
> 
> (setq org-format-latex-options (plist-put org-format-latex-options
> :matchers ("begin" "$1" "$$" "\\(" "\\[")))
> 
> As well as this:
> 
> (setq org-format-latex-options (plist-put org-format-latex-options
> :matchers "("begin" "$1" "$$" "\\(" "\\[")"))

Or, if you want to do it like this:

(setq org-format-latex-options
      (plist-put org-format-latex-options
       :matchers '("begin" "$1" "$$" "\\(" "\\[")))

Quoting a list is done with a single ' before the opening parenthesis.
Not by enclosing it in "...".

HTH

- Carsten


> 
> Both of those aren't parsing correctly. Sorry for my elisp munging ignorance!
> 
> 
> Thanks!
> John
> 


[-- Attachment #2: Message signed with OpenPGP using GPGMail --]
[-- Type: application/pgp-signature, Size: 455 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Assistance customizing org-format-latex-options
  2013-09-18  4:15 ` Carsten Dominik
@ 2013-09-18  4:38   ` John Hendy
  0 siblings, 0 replies; 5+ messages in thread
From: John Hendy @ 2013-09-18  4:38 UTC (permalink / raw)
  To: Carsten Dominik; +Cc: emacs-orgmode

On Tue, Sep 17, 2013 at 11:15 PM, Carsten Dominik
<carsten.dominik@gmail.com> wrote:
>
> On 18.9.2013, at 05:52, John Hendy <jw.hendy@gmail.com> wrote:
>
>> Hi,
>>
>>
>> I'm running into a similar issue as I once did before:
>> - http://comments.gmane.org/gmane.emacs.orgmode/50452
>>
>> When I'm writing a paragraph and have a dollar currency amount, Org's
>> footnote functionality (e.g. =C-x f=) does not work in the region.
>>
>> The suggestion was to remove "$" from org-format-latex-options.
>>
>> I've not customized a variable with many "sub-options." Can someone
>> give me an example of how to directly customize just the :matchers
>> portion of that variable in .emacs? I prefer to set options directly
>> vs. having a jumbled list of customizations in custom-set-variables.
>>
>> I searched around and found this:
>> - http://stackoverflow.com/questions/11272236/how-to-make-formule-bigger-in-org-mode-of-emacs
>>
>> It gives instructions on setting the :scale portion, which I tried to
>> adapt to :matchers like this:
>>
>> (setq org-format-latex-options (plist-put org-format-latex-options
>> :matchers ("begin" "$1" "$$" "\\(" "\\[")))
>>
>> As well as this:
>>
>> (setq org-format-latex-options (plist-put org-format-latex-options
>> :matchers "("begin" "$1" "$$" "\\(" "\\[")"))
>
> Or, if you want to do it like this:
>
> (setq org-format-latex-options
>       (plist-put org-format-latex-options
>        :matchers '("begin" "$1" "$$" "\\(" "\\[")))
>
> Quoting a list is done with a single ' before the opening parenthesis.
> Not by enclosing it in "...".
>

Fantastic and exactly what I was looking for! I realize I'm pretty
horrible at following through on my Worg aspirations... but perhaps I
can file this and some other things like this to help others with
customization of variables. Some of these syntax things seem to appear
with reasonable frequency and cause us non-elispers definite
confusion. I could see a page on setting .emacs options as helpful.
Come to think of it, I probably should have googled for more general
Emacs customization information.

Anyway, many thanks for the quick response and assistance!


John

> HTH
>
> - Carsten
>
>
>>
>> Both of those aren't parsing correctly. Sorry for my elisp munging ignorance!
>>
>>
>> Thanks!
>> John
>>
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-09-18  4:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-18  3:52 Assistance customizing org-format-latex-options John Hendy
2013-09-18  4:09 ` Carsten Dominik
2013-09-18  4:13   ` John Hendy
2013-09-18  4:15 ` Carsten Dominik
2013-09-18  4:38   ` John Hendy

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).