emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* setting org-export-latex-image-default-option on a per file basis?
@ 2010-02-09 20:41 Lee Hinman
  2010-02-10  2:01 ` Dan Davison
  0 siblings, 1 reply; 4+ messages in thread
From: Lee Hinman @ 2010-02-09 20:41 UTC (permalink / raw)
  To: emacs-orgmode

Hi all,

I'm using org-babel-ditaa to insert a picture into a document I am
writing. This works great, except the inserted image is too small.  By
changing the -s option to ditaa I was able to modify the size of the
image for the HTML export but not for the LaTeX.  I did a little looking
at the .tex file and found this:

\includegraphics[width=10em]{before1.png}

the width=10em is controlled by org-export-latex-image-default-option.
Ideally I'd like to change this value for this file only, something
like an entry in the #+OPTIONS line.  But org-export-plist-vars has that
element set to nil so it isn't configurable via that method.  Does
anyone have a suggestion of how I could tweak this variable on a per
file basis?

Thanks for any suggestions.

-- 
Lee Hinman
hinman@gmail.com

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

* Re: setting org-export-latex-image-default-option on a per file basis?
  2010-02-09 20:41 setting org-export-latex-image-default-option on a per file basis? Lee Hinman
@ 2010-02-10  2:01 ` Dan Davison
  2010-02-10  2:23   ` Nick Dokos
  0 siblings, 1 reply; 4+ messages in thread
From: Dan Davison @ 2010-02-10  2:01 UTC (permalink / raw)
  To: Lee Hinman; +Cc: emacs-orgmode

Lee Hinman <hinman@gmail.com> writes:

> Hi all,
>
> I'm using org-babel-ditaa to insert a picture into a document I am
> writing. This works great, except the inserted image is too small.  By
> changing the -s option to ditaa I was able to modify the size of the
> image for the HTML export but not for the LaTeX.  I did a little looking
> at the .tex file and found this:
>
> \includegraphics[width=10em]{before1.png}
>
> the width=10em is controlled by org-export-latex-image-default-option.
> Ideally I'd like to change this value for this file only, something
> like an entry in the #+OPTIONS line.  But org-export-plist-vars has that
> element set to nil so it isn't configurable via that method.  Does
> anyone have a suggestion of how I could tweak this variable on a per
> file basis?

Hi Lee,

I was just having the same problem. We can use a file-local variable,
for now. 

# Local Variables:
# org-export-latex-image-default-option: "width=30em"
# End:

This goes "near the end of the file" according to 
http://www.gnu.org/software/emacs/manual/html_node/emacs/Specifying-File-Variables.html#Specifying-File-Variables.

Dan

>
> Thanks for any suggestions.

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

* Re: setting org-export-latex-image-default-option on a per file basis?
  2010-02-10  2:01 ` Dan Davison
@ 2010-02-10  2:23   ` Nick Dokos
  2010-02-10  8:00     ` Carsten Dominik
  0 siblings, 1 reply; 4+ messages in thread
From: Nick Dokos @ 2010-02-10  2:23 UTC (permalink / raw)
  To: Dan Davison; +Cc: emacs-orgmode

Dan Davison <davison@stats.ox.ac.uk> wrote:

> Lee Hinman <hinman@gmail.com> writes:
> 
> > Hi all,
> >
> > I'm using org-babel-ditaa to insert a picture into a document I am
> > writing. This works great, except the inserted image is too small.  By
> > changing the -s option to ditaa I was able to modify the size of the
> > image for the HTML export but not for the LaTeX.  I did a little looking
> > at the .tex file and found this:
> >
> > \includegraphics[width=10em]{before1.png}
> >
> > the width=10em is controlled by org-export-latex-image-default-option.
> > Ideally I'd like to change this value for this file only, something
> > like an entry in the #+OPTIONS line.  But org-export-plist-vars has that
> > element set to nil so it isn't configurable via that method.  Does
> > anyone have a suggestion of how I could tweak this variable on a per
> > file basis?
> 
> Hi Lee,
> 
> I was just having the same problem. We can use a file-local variable,
> for now. 
> 
> # Local Variables:
> # org-export-latex-image-default-option: "width=30em"
> # End:
> 
> This goes "near the end of the file" according to 
> http://www.gnu.org/software/emacs/manual/html_node/emacs/Specifying-File-Variables.html#Specifying-File-Variables.
> 
> Dan
> 

You should also be able to use BIND for this:

#+BIND: org-export-latex-image-default-option "width=30em"

should do it. I think this should work but I have not tested it.

HTH,
Nick

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

* Re: setting org-export-latex-image-default-option on a per file basis?
  2010-02-10  2:23   ` Nick Dokos
@ 2010-02-10  8:00     ` Carsten Dominik
  0 siblings, 0 replies; 4+ messages in thread
From: Carsten Dominik @ 2010-02-10  8:00 UTC (permalink / raw)
  To: nicholas.dokos; +Cc: Dan Davison, emacs-orgmode


On Feb 10, 2010, at 3:23 AM, Nick Dokos wrote:

> Dan Davison <davison@stats.ox.ac.uk> wrote:
>
>> Lee Hinman <hinman@gmail.com> writes:
>>
>>> Hi all,
>>>
>>> I'm using org-babel-ditaa to insert a picture into a document I am
>>> writing. This works great, except the inserted image is too  
>>> small.  By
>>> changing the -s option to ditaa I was able to modify the size of the
>>> image for the HTML export but not for the LaTeX.  I did a little  
>>> looking
>>> at the .tex file and found this:
>>>
>>> \includegraphics[width=10em]{before1.png}
>>>
>>> the width=10em is controlled by org-export-latex-image-default- 
>>> option.
>>> Ideally I'd like to change this value for this file only, something
>>> like an entry in the #+OPTIONS line.  But org-export-plist-vars  
>>> has that
>>> element set to nil so it isn't configurable via that method.  Does
>>> anyone have a suggestion of how I could tweak this variable on a per
>>> file basis?
>>
>> Hi Lee,
>>
>> I was just having the same problem. We can use a file-local variable,
>> for now.
>>
>> # Local Variables:
>> # org-export-latex-image-default-option: "width=30em"
>> # End:
>>
>> This goes "near the end of the file" according to
>> http://www.gnu.org/software/emacs/manual/html_node/emacs/Specifying-File-Variables.html#Specifying-File-Variables 
>> .
>>
>> Dan
>>
>
> You should also be able to use BIND for this:
>
> #+BIND: org-export-latex-image-default-option "width=30em"
>
> should do it. I think this should work but I have not tested it.

You can also, on a per image basis, use

     #+ATTR_LaTeX: width=30em

just before the ditaa block.

HTH

- Carsten

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

end of thread, other threads:[~2010-02-10 10:35 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-09 20:41 setting org-export-latex-image-default-option on a per file basis? Lee Hinman
2010-02-10  2:01 ` Dan Davison
2010-02-10  2:23   ` Nick Dokos
2010-02-10  8:00     ` Carsten Dominik

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).