Commit Graph

8 Commits

Author SHA1 Message Date
Jambunathan K 92da128bf9 Pull up ODT files from "maint" to "master" levels
2012-01-17   Jambunathan K   <kjambunathan@gmail.com>

* etc/styles/OrgOdtContentTemplate.xml
(OrgIndentedSection-Level-*): New section styles. These
sections are indented to the same level as the corresponding
list entries.  These sections hold tables that occur within a
list.
(OrgTable): Increased relative width from 90% to 96% for
aesthetic reasons.

* lisp/org-odt.el (org-odt-table-indentedp): New variable
(org-odt-begin-table): Modified.  If the table is within a
list, temporarily leave the list and begin an indented section
before emitting the table.
(org-odt-end-table): Modified.  If the table was within a
list, close the indented section and re-open the list
immediately after ending the table.
(org-odt-continue-list, org-odt-discontinue-list): Helper
routines to temporarily discontinue and continue a list.
(org-odt-list-stack-stashed): New variable to hold the state
of a pending list.
(org-odt-begin-list, org-odt-begin-list-item)
(org-odt-end-list-item): Modified. Handle nitty-gritties for
continuing a list and list item.
(org-odt-section-count): New variable that keeps track of
section count.  Used in conjunction with naming of sections.
(org-odt-begin-section, org-odt-end-section): New defuns.
(org-odt-init-outfile): Initialize
`org-odt-list-stack-stashed' and `org-odt-section-count'.

* lisp/org-lparse.el (org-lparse-list-item-count): Removed. Was a
superfluous variable.
(org-lparse-list-level): Removed.  Now derived from
`org-lparse-list-stack'.
(org-lparse-list-stack): New.  List that records the list
types - ordered, unordered or descriptive - in the following
order: self, parent, grand-parent etc.
(org-do-lparse): Added, removed above let-bound vars.
Disallowed regular tables within list-table block.
(org-lparse-begin-list, org-lparse-end-list)
(org-lparse-begin-list-item, org-lparse-end-list-item):
Propagate above changes.

OpenDocument doesn't permit tables to occur in the middle of a
list.  Use list continuations and indented sections to typeset
indented tables.

Fixes the following bug:
http://lists.gnu.org/archive/html/emacs-orgmode/2012-01/msg00515.html

Add support for indented tables in ODT export

2012-01-20   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-odt-format-textbox): Honor user-specified
width in captioned images.

Fix for bug reported here:
http://lists.gnu.org/archive/html/emacs-orgmode/2012-01/msg00641.html

Honor user-specified width in captioned images

2012-01-23   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-odt-table-style-format): New.  Template for
auto-generated table styles.
(org-odt-automatic-styles, org-odt-object-counters): New
variables.
(org-odt-add-automatic-style): New function.
(org-odt-write-automatic-styles): New function.  Create
automatic styles for tables that have custom :rel-width.
(org-odt-begin-table): Parse attributes specified with
"#+ATTR_ODT: " option and use it to create an automatic table
style.
(org-odt-save-as-outfile): Call
`org-odt-add-write-automatic-styles'.
(org-odt-init-outfile): Init newly add variables.
(org-odt-section-count): Remove it.
(org-odt-begin-section): Use `org-odt-add-automatic-style' to
generate an automatic section name.

Customize table width using :rel-width option.  For example,
to create a table of width 60% use:

    #+attr_odt: :rel-width 60
    | A | B |
    |---+---|
    |   |   |

org-odt.el: Put table width under user-control

2012-01-23   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-odt-label-styles): Add a new style.
(org-odt-category-map-alist):  Use it.

Andreas Leha writes:

The following snippet exports correctly to LaTeX and to html, but
produces the text "Figure Figure" in odt.

Could the behaviour be synchronized?

=== example.org ==========================
* Test ref
  plot(1:10, 1:10)

Here is a reference to Figure \ref{fig:bar}
=== example.org ==========================

org-odt.el: Make label references consistent with LaTeX export

2012-01-24   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-odt-entity-frame-styles): Add frame params
for images that are anchored as character.
(org-export-odt-format-image): Handle new anchor type
"as-char".
(org-export-odt-default-image-sizes-alist): Misc. change.
(org-export-odt-format-formula): Misc. change.

With this change, one can use the below snippet to produce
images that are laid out side-by-side.
    #+ATTR_ODT: :width 7 :height 7 :anchor as-char
    #+header: :file foo.png
    [[./foo.png]]
    #+caption: bar
    #+ATTR_ODT: :width 7 :height 7 :anchor as-char
    #+header: :file bar.png
    [[./bar.png]]

See http://lists.gnu.org/archive/html/emacs-orgmode/2012-01/msg00677.html.

org-odt.el: Allow images to be anchored as characters

2012-01-24   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-export-odt-format-formula): Use :style
property to specify custom table styles.

Continuation of the earlier commit titled: "Put table width
under user-control".

org-odt.el: Fix regression in typesetting of MathML formulae

2012-01-27   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-odt-format-preamble): Don't insert TOC here.
Delay it till the end of export.
(org-odt-begin-document-body): Make a note of the default
position of TOC in `org-lparse-dyn-first-heading-pos'.
(org-odt-insert-toc): Insert TOC as directed by
[TABLE-OF-CONTENTS] line or at the default position.
(org-odt-end-export): Call `org-odt-insert-toc'.

Fix for the following bug:
http://lists.gnu.org/archive/html/emacs-orgmode/2012-01/msg00974.html

org-odt.el: Honor "[TABLE-OF-CONTENTS]" directive

2012-01-27   Jambunathan K   <kjambunathan@gmail.com>

org-odt.el: Fix earlier commit

2012-01-30   Jambunathan K   <kjambunathan@gmail.com>

* OrgOdtStyles.xml (OrgTitlePage): New page style.  Include no
footer.  Use "OrgFrontMatterPage" for the following page.
(OrgFrontMatterPage): New page style.  Include a footer that
displays page numbers in Roman style.  Use mirrored pages.
Use "OrgFrontMatterPage" for the following page.
(OrgPage): New page style.  Include a footer that displays
page numbers.  Use mirrored pages.  Use "OrgPage" for the
following page.
(OrgFirstPage): New page style.  Include a footer that
displays page numbers.  Right page only.  Use "OrgPage" for
the following page.
(Standard): Modify to include a footer that displays page
numbers.  Use mirrored pages.  Use "Standard" for the
following page.

None of the above page styles have a header.

The newly added page styles are not used as yet.

org-odt.el: By default, include page numbers in the page footer

2012-01-31   Jambunathan K   <kjambunathan@gmail.com>

org-odt.el: Do `clear-image-cache' before `create-image'

2012-02-03   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-lparse.el (org-lparse-do-convert): Replace
`call-process' with `shell-command-to-string'.

* lisp/org-odt.el (org-export-odt-convert-processes): Add a new
converter which depends solely on LibreOffice and nothing
else.
(org-export-odt-convert-process): Make the above native
converter the default.

Thanks to Giles for introducing the "--convert-to" option of
soffice.exe.  The option seems to be a fairly recent
development.

http://imperfectsoftware.blogspot.in/2012/01/one-of-my-less-enjoyable-tasks-is-to.html

With this change, one can export to pdf via odt by a simple
  (setq org-export-odt-preferred-output-format "pdf")
There is no need to install additional converters.

org-odt.el: Make LibreOffice the default converter

2012-02-09   Jambunathan K   <kjambunathan@gmail.com>

* org-odt.el (org-export-odt-convert-capabilities): Change the
default value.

See http://lists.gnu.org/archive/html/emacs-orgmode/2012-02/msg00293.html.

Offer "docx" as an option in `org-export-odt-preferred-output-format'

2012-02-12   Jambunathan K   <kjambunathan@gmail.com>

org-odt.el: Fix indentation

2012-02-12   Jambunathan K   <kjambunathan@gmail.com>

org-odt.el: Tag all custom variables with Emacs version

2012-02-12   Jambunathan K   <kjambunathan@gmail.com>

* lisp/org-odt.el (org-export-odt-convert-processes): Re-define
(org-export-odt-convert-capabilities): Fix an accidental
regression.

* lisp/org-lparse.el (org-lparse-do-convert): Related change.

Simplify definition of `org-export-odt-convert-processes'

2012-02-12   Jambunathan K   <kjambunathan@gmail.com>

Retire support for BasicODConverter

2012-02-14   Jambunathan K   <kjambunathan@gmail.com>

* org-odt.el (org-export-as-odt-to-buffer)
(org-replace-region-by-odt, org-export-region-as-odt): Remove
these interactive functions.  They are of questionable value.

org-odt.el: Remove interactive functions of questionable value

2012-02-15   Jambunathan K   <kjambunathan@gmail.com>

Improve converting from ODT to other formats

2012-02-15   Jambunathan K   <kjambunathan@gmail.com>

* org-odt.el (org-export-odt-image-size-probe-method)
(org-odt-do-image-size): Use imagemagick preferentially to
determine image sizes.

See http://lists.gnu.org/archive/html/emacs-orgmode/2012-02/msg00288.html

org-odt.el: Use imagemagick to determine image sizes

2012-02-16   Jambunathan K   <kjambunathan@gmail.com>

* org.texi (Top, OpenDocument Text export)
(ODT export commands, Extending ODT export)
(Images in ODT export, Tables in ODT export)
(Configuring a document converter): Add or Update.

org.texi: Update ODT section
2012-02-20 10:25:31 +05:30
Jambunathan K e9fd334eb4 Add support for indented tables in ODT export
* etc/styles/OrgOdtContentTemplate.xml
(OrgIndentedSection-Level-*): New section styles. These
sections are indented to the same level as the corresponding
list entries.  These sections hold tables that occur within a
list.
(OrgTable): Increased relative width from 90% to 96% for
aesthetic reasons.

* lisp/org-odt.el (org-odt-table-indentedp): New variable
(org-odt-begin-table): Modified.  If the table is within a
list, temporarily leave the list and begin an indented section
before emitting the table.
(org-odt-end-table): Modified.  If the table was within a
list, close the indented section and re-open the list
immediately after ending the table.
(org-odt-continue-list, org-odt-discontinue-list): Helper
routines to temporarily discontinue and continue a list.
(org-odt-list-stack-stashed): New variable to hold the state
of a pending list.
(org-odt-begin-list, org-odt-begin-list-item)
(org-odt-end-list-item): Modified. Handle nitty-gritties for
continuing a list and list item.
(org-odt-section-count): New variable that keeps track of
section count.  Used in conjunction with naming of sections.
(org-odt-begin-section, org-odt-end-section): New defuns.
(org-odt-init-outfile): Initialize
`org-odt-list-stack-stashed' and `org-odt-section-count'.

* lisp/org-lparse.el (org-lparse-list-item-count): Removed. Was a
superfluous variable.
(org-lparse-list-level): Removed.  Now derived from
`org-lparse-list-stack'.
(org-lparse-list-stack): New.  List that records the list
types - ordered, unordered or descriptive - in the following
order: self, parent, grand-parent etc.
(org-do-lparse): Added, removed above let-bound vars.
Disallowed regular tables within list-table block.
(org-lparse-begin-list, org-lparse-end-list)
(org-lparse-begin-list-item, org-lparse-end-list-item):
Propagate above changes.

OpenDocument doesn't permit tables to occur in the middle of a
list.  Use list continuations and indented sections to typeset
indented tables.

Fixes the following bug:
http://lists.gnu.org/archive/html/emacs-orgmode/2012-01/msg00515.html
2012-02-19 08:03:39 -07:00
Jambunathan K 966d1e2b93 OrgOdtContentTemplate.xml: table-cells are now top aligned by default
* etc/styles/OrgOdtContentTemplate.xml (OrgTblCell): Modify
style:vertical-align attribute to top.
(OrgTblCell*): Inherit from OrgTblCell.
(Custom*TableCell): Force style:vertical-align to top.

See http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00780.html
2011-12-29 16:30:24 +05:30
Jambunathan K 2512637fce org-odt.el: Support for anchoring an image to a page
* etc/styles/OrgOdtStyles.xml(OrgPageImage)
(OrgPageImageCaptionFrame): New styles for anchoring an image
centrally on a page.

* lisp/org-odt.el (org-odt-entity-frame-styles): Accommodate new
frame styles: \"OrgPageImage\" and \"OrgPageImageCaptionFrame\".
(org-export-odt-format-image): Handle frame-related :anchor,
:style and :attributes options attached to images as shown
below:
		[[./image.png]]
(org-odt-merge-frame-params): New. Auxiliary routine to merge
the default frame params and user-specified frame params.
(org-odt-format-entity): Use the above
`org-odt-merge-frame-params'.

Jérémy Compostella <jeremy.compostella@gmail.com> writes:
  I need to add pictures that are anchored to the \"page\" and not
  to the \"paragraph\". This is very useful to get a \"floating
  picture\" on an entire page without text breaks.

He also adds:
  Sometimes, you want to add a picture but you don't want a page
  break. For example, you want to add a big illustration. To
  render correctly, the picture needs its own page but you don't
  want to break the page. In this case you need to anchor the
  picture to the \"page\".

http://lists.gnu.org/archive/html/emacs-orgmode/2011-11/msg00869.html
2011-12-26 16:03:25 +05:30
Jambunathan K f5add81f4b org-odt.el: Include author and date in the title
* lisp/org-odt.el (org-export-odt-default-org-styles-alist):
Add styles for title and subtitle.
(org-odt-format-toc): New.
(org-odt-format-preamble): New.  Users can redefine this to
customize what goes before the document body.  Currently it
outputs title, author and email, date and toc.
(org-odt-begin-document-body): Use `org-odt-format-preamble'.
(org-odt-format-date): Renamed from
`org-odt-iso-date-from-org-timestamp'.  Also added an
additional param for format string.
(org-odt-begin-annotation, org-odt-update-meta-file): Use
`org-odt-format-date'.

* etc/styles/OrgOdtStyles.xml (Title, OrgTitle, Subtitle)
(OrgSubtitle): New styles for formatting title.
2011-12-15 12:25:35 +05:30
Jambunathan K ff99056baf Makefile (PKG_FILES) : Include etc/
Also fix all byte-compiler warnings in org-lparse.el and org-odt.el.
2011-12-11 02:02:33 +05:30
Jambunathan K 23358285a4 Add copyright and license info for files in etc/styles/ 2011-12-10 18:13:14 +01:00
Jambunathan K 9c14e3d95e Move contrib/odt/styles/*.xml to etc/styles 2011-12-10 18:12:48 +01:00