[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] [ox-latex] Bad default value for image width?
From: |
Rasmus |
Subject: |
[O] [ox-latex] Bad default value for image width? |
Date: |
Sun, 07 Apr 2013 22:17:04 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Hi,
I don't like that tikz figures are wrapped in a resize box. In
particular this plain example is wrapped in a resize box:
#+BEGIN_SRC Org
* tikz test
[[file:test.tikz]]
#+ATTR_LATEX: :width ""
[[file:test.tikz]]
#+END_SRC
Produces:
#+BEGIN_SRC latex
[...]
\resizebox{.9\linewidth}{!}{\input{test.tikz}}
[...]
#+END_SRC
Default behavior should be to not wrap it in a resize box as most tikz
users will set the width appropriately in their code. The reason is
the variable org-latex-image-default-width which is .9\linewidth by
default. And I can't seem to set width to nothing. . . The problem
is that resize box insertion depends on the following test
#+BEGINS_SRC emacs-lisp
(when (or (org-string-nw-p width) (org-string-nw-p height))
...)
#+END_SRC
which is always true due to the default meaning that I can't escape
the resize box. . .
Potential resolutions:
1. change the default of org-latex-image-default-width
2. allow for a non-width (:width nil)
3. make a better test for the resize box.
Let me know and I might be able to look into it.
–Rasmus
--
A clever person solves a problem. A wise person avoids it
- [O] [ox-latex] Bad default value for image width?,
Rasmus <=