emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Aligned glosses in orgmode (for export to odt/doc)


From: Jambunathan K
Subject: Re: [O] Aligned glosses in orgmode (for export to odt/doc)
Date: Wed, 22 Jan 2014 23:46:03 +0530
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Benjamin Slade <address@hidden> writes:

> One potential solution would be an orgmode setup which produces
> borderless tables with an "optimal width" column setting. I don't know
> how to do this in orgmode though (or if it can be done currently).

This feature is available only in my private repo.  

----------------------------------------------------------------

If you are using Git see instructions at:

    http://lists.gnu.org/archive/html/emacs-orgmode/2013-12/msg00522.html

   (Search for "Download")

Once you download and copy the ox-odt.el file, make sure you do

    M-x byte-compile-file

to create .elc file.

----------------------------------------------------------------

If you are using ELPA see instructions at:

    http://lists.gnu.org/archive/html/emacs-orgmode/2014-01/msg00518.html

    (Search for "Untar")

----------------------------------------------------------------

1. Identity where your styles files come from.  Look at the *Messages*
   buffer for clue.

2. Open OrgOdtContentTemplate.xml and find a style named
"CustomTableCell".  Edit it so that it has no borders.

Replace this

    <style:style style:name="CustomTableCell" style:family="table-cell">
      <style:table-cell-properties style:vertical-align="top" 
fo:background-color="#ffffff" fo:padding="0.097cm" fo:border-left="0.002cm 
solid #000000" fo:border-right="0.002cm solid #000000" fo:border-top="0.002cm 
solid #000000" fo:border-bottom="0.002cm solid #000000">

with this:

    <style:style style:name="CustomTableCell" style:family="table-cell">
      <style:table-cell-properties style:vertical-align="top"
      fo:background-color="#ffffff" fo:padding="0.097cm">


3. Create a tables as below.  ("GriddedTable" is part of C-h v
   `org-odt-table-styles').  WARNING: Don't try to understand the
   documentation.  I don't it understand it myself.

--8<---------------cut here---------------start------------->8---

Rows will be in the ratio of 2:3:4

#+ATTR_ODT: :style "GriddedTable"
| <1> | <2> | <3> |
| _a_ | _b_ | _c_ |
| _d_ | _e_ | _f_ |


Rows will be in the ratio of 4:7:10.  Table will occupy 80% of page width.

#+ATTR_ODT: :rel-width 80
#+ATTR_ODT: :widths 3,6,9
#+ATTR_ODT: :style "GriddedTable"
| <1> | <2> | <3> |
| _a_ | _b_ | _c_ |
| _d_ | _e_ | _f_ |

--8<---------------cut here---------------end--------------->8---

4. Export it.  You will get the attached ODT file.

Attachment: test.odt
Description: application/vnd.oasis.opendocument.text


reply via email to

[Prev in Thread] Current Thread [Next in Thread]