0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-09-22 19:10:43 +00:00
Commit graph

355 commits

Author SHA1 Message Date
David Maus 163cd58ffd Handle timestamps after handling links
* org-html.el (org-export-as-html): Handle timestamps after handling
links.

otherwise a link description with an ISO date is handled as an
inactive timestamp and replaced by a timestamp span.

Bug reported by Vincent Belaïche.
2011-01-14 06:37:52 +01:00
Jason Dunsmore e703ea9823 `org-export-htmlize-output-type' docstring patch
I noticed the choices for org-export-htmlize-output-type aren't listed
in its docstring.  I had to load up the customize interface to see what
the choices were.
2011-01-08 19:00:44 +01:00
Bastien Guerry 8d879c3870 org-html.el: add a space before attributes in org-html-make-link. 2011-01-04 17:24:47 +01:00
Łukasz Stelmach 93135fa814 Add displaymath to MathJax setup
* lisp/org-html.el (org-export-html-mathjax-template): displaymath
environment and MathJax

Greetings All.

The following patch makes MathJax consider \begin{displaymath} and
\end{displaymath} as math environmetn boundaries. For someone who, like
me, keeps "The not so short introduction to LaTeX2e" alway around, the
displaymath environment is the default way to introduce a block of math.

In fact '\[' and '\]' are also mentioned there but the environment is
used in every single example so the patch minimizes the surprise.
2010-12-12 13:13:45 +01:00
Carsten Dominik 7666ba421f Version number back to 7.4 2010-12-10 18:49:40 +01:00
Carsten Dominik 76a25715c9 Bump version number to 7.5 2010-12-10 18:43:10 +01:00
Carsten Dominik d637546804 Mark listitifed headings wiht custom id
* lisp/org-html.el (org-html-level-start): Mark listified headings
with a custom id.

Patch by Jambunathan
2010-11-21 09:45:02 +01:00
Carsten Dominik 85e1f9760f Fix partial line protection issue
* lisp/org-html.el (org-export-as-html): Do not treat partially
protected lines as if they were fully protected.

Nicolas Goaziou writes:

> Here is a problem when a latex fragment is split across two lines and
> an emphasize follows. The text won't be italicized upon exporting to
> HTML.
>
> =====
> * latex-fragments bug
>
>  Imagine we have a formula starting here $e^{i\pi} +
>  1 = 0$. Now we have a problem with /emphasize/.
> =====
>
> This is because the line starts with a char with 'org-protected
> property and, thus, get caught by the "Protected HTML" (org-html.el
> l. 1216) part of `org-export-as-html'. In others words, the line is
> inserted as-is in the output buffer, before getting any
> transformation.
>
> I'm not sure how it should be done (I don't get yet the usefulness of
> this "Protected HTML" part), but that piece of code may be moved after
> the `org-html-expand' call, as long as every sub-function in
> `org-html-expand' has a check to prevent modifying protected stuff
> (this not yet the case for `org-export-with-emphasize' and
> `org-html-protect' while others seem ok).
>
> But even in this case, every function getting called after that would
> be ignored. So, for example, links would not be inserted.
>
> Couldn't the "Protected HTML" part be removed altogether?
2010-11-12 07:18:09 -06:00
Bastien Guerry 6630edbd0f Set version number to 7.3 2010-11-07 14:52:14 +01:00
Carsten Dominik 82af72eef7 Push version number to 7.02trans 2010-10-29 09:11:46 +02:00
Carsten Dominik eab8ea9687 Minor fixes 2010-10-26 07:10:48 +02:00
Carsten Dominik 25d365a373 Fix table alignment for the docbook exporter
* lisp/org-html.el (org-format-table-html): New argument DOCBOOK.
(org-format-org-table-html): New argument DOCBOOK.  When set, use
align instead of class to align table fields.
* lisp/org-docbook.el (org-export-as-docbook): Specify the docbook argument
for the table converter.
2010-10-25 15:40:30 +02:00
Carsten Dominik 8bbc3ab3ad HTML Export: Add some default classes for text alignment
Proposal by Sebastian Rose.
2010-10-25 08:41:18 +02:00
Daniel Clemente c486572df0 Append fragment to file: links if present
* org-html.el (org-html-make-link): Append fragment to file: links if
present.

Patch by Daniel Clemente
2010-10-24 20:23:27 +02:00
Carsten Dominik 987beb6277 Use classes to align table data fields 2010-10-23 08:17:29 +02:00
Carsten Dominik ca991d2ad4 HTML export: Improved support for field alignment, including centering
* doc/org.texi: Document the <c> cookie.
* lisp/org-exp.el (org-store-forced-table-alignment):
(org-export-remove-special-table-lines): Allow the "c" cookie for
table alignment.
* lisp/org-html.el (org-export-table-header-tags):
(org-export-table-data-tags): Add another %s format for the alignment.
(org-export-html-table-align-individual-fields): New option.
(org-format-org-table-html): Implement field-by-field alignment and
support centering.
(org-format-table-table-html): Make sure the new table tag formats
don't break this function.
* lisp/org-table.el (org-table-cookie-line-p):
(org-table-align): Allow for the <c> cookie.
* lisp/org.el (org-set-font-lock-defaults): Allow for the <c> cookie.
2010-10-22 09:19:39 +02:00
Carsten Dominik 7712d78ab4 HTML export: Use forced alignment like <l> or <r> in tables
* lisp/org-table.el (org-table-cookie-line-p): Fix indentation.
* lisp/org-exp.el (org-store-forced-table-alignment): New function.
(org-export-preprocess-string): Call `org-store-forced-table-alignment'.
* lisp/org-html.el (org-format-org-table-html): Use stored
alignment information.
2010-10-21 16:28:06 +02:00
Carsten Dominik b7372638bc Add "svg" as allowed files for images in HTML exort
* lisp/org-html.el (org-export-html-inline-image-extensions): Add
"svg" as an allowed extension.
2010-10-04 10:28:53 +02:00
Bastien Guerry 7ec0cceba4 org-export-html-postamble: fix docstring. 2010-09-18 18:10:34 +02:00
Noorul Islam bbac53d7fe org-html.el: Fix exporting link to .org files.
On Wed, Sep 8, 2010 at 2:12 AM, Daniel Clemente <n142857@gmail.com> wrote:

>
> Commit bd1b57f92a broke the exporting
> of [[file:a.org]] links, which now appear as [[http:a.html]]. Try
> C-c C-e H on any .org with such links, even in emacs -Q.
>
> The problem is, I think, that „type“ is actually "http", not "file"
> as the code tries.
>

* lisp/org-html.el (org-html-cvt-org-as-html): Do not convert protocol
from 'file' to 'http'.

TINYCHANGE
2010-09-12 19:54:50 +02:00
Bastien Guerry 330fb5409e Fix handling of absolute filenames' conversion to HTML links. 2010-09-02 17:33:00 +02:00
Noorul Islam bd1b57f92a html-export mangels mailto: links
Achim Gratz <Stromeko@nexgo.de> writes:

> HTML export removes the "mailto:" from a link, which will then be
> interpreted as a local link by the browser.
>
> For an example, see the link to this mailing list in
> ORGWEBPAGE/index.org and the corresponding HTML export on orgmode-org
> (or just the local file).
>

org-html.el : Fix exporting file, mailto, news and ftp protocols.

* lisp/org-html.el (org-html-make-link): (expand-file-name
) removes one "/" from "///path-to-file", so add one. Anything other
than 'file' type should be exported along with the type.

TINYCHANGE

Thanks and Regards
Noorul
2010-09-02 16:56:27 +02:00
Nicolas Goaziou 8e5729c466 Speed optimizations and docstring modifications. 2010-09-01 19:05:56 +02:00
Nicolas Goaziou bfce8dd357 Do not crash when trying to export an ill-formed list in HTML and DocBook. 2010-09-01 19:05:56 +02:00
Nicolas Goaziou 6b2468477e [@num] is valid to enforce a numbering (same as [@start:num]) 2010-09-01 19:05:54 +02:00
Nicolas Goaziou 7ef456426e Fix DocBook and HTML sensitivity about item's body indentation
* org-docbook.el (org-export-as-docbook): Removed check for
  indentation on lines that do not start with a list bullet.
* org-html.el (org-export-as-html): Same thing.
2010-09-01 19:05:53 +02:00
Nicolas Goaziou cb23060a46 HTML and DocBook exporters handle multiple uses of [@start:?].
* org-docbook.el (org-export-as-docbook): Use override="num" in any
  listitem matching [@start:num]
* org-html.el (org-export-as-html): Use value="num" in any li matching
  [@start:num]
2010-09-01 19:05:51 +02:00
Nicolas Goaziou 197ed8b273 Remove useless checks for `org-empty-line-terminates-plain-lists'.
* org-docbook.el (org-export-as-docbook): When we find an empty line,
  we do not need to check for `org-empty-line-terminates-plain-lists'
  because we would have found end-list marker before.
* org-html.el (org-export-as-html): Same.
2010-09-01 19:05:45 +02:00
Nicolas Goaziou 27cfeefc3b Code cleanup.
* org-html.el (org-export-as-html): Code cleanup.
2010-09-01 19:05:45 +02:00
Nicolas Goaziou 4c2bc51c52 Remove the no longer needed didclose variable.
* org-html.el (org-export-as-html): Delete didclose and everything
  related to it, as it is no longer needed.
2010-09-01 19:05:45 +02:00
Nicolas Goaziou 99306969b0 Both latex and html should now export correctly.
* org-html.el (org-export-html-preprocess): Remove unneeded insertion
  of list end marker, as it is now handled by
  `org-export-mark-list-ending'.
* org-html.el (org-export-as-html): Cleaner termination of lists.
* org-exp.el (org-export-mark-list-ending): New function to insert
  specific markers at the end of lists when exporting to a backend not
  using `org-list-parse-list'.
  This function is called early in `org-export-preprocess-string',
  while it is still able to recognize lists.
* org-latex.el (org-export-latex-lists): Better search for lists. It
  now only finds items not enclosed and not protected.
2010-09-01 19:05:45 +02:00
Nicolas Goaziou e3813fcfcb List ending is replaced by a blank line during html export.
* org-html.el (org-export-html-preprocess): Replace `org-list-end-re'
  by a blank line during pre-process.
2010-09-01 19:05:44 +02:00
Nicolas Goaziou 4c0bf39469 Do not delete space between end of list and beginning of the following
* lisp/org-html.el: Do not delete space between end of list and
  beginning of the following.
2010-09-01 19:05:44 +02:00
Nicolas Goaziou 1d99d9ee73 Do not try to guess list ending and let org-list.el do its job.
* lisp/org-html.el: preprocess buffer string and add ORG-LIST-END
  where needed. Lists should not end before seeing this.
2010-09-01 19:05:44 +02:00
Nicolas Goaziou 6167dfa444 Notice end of lists.
* lisp/org-html.el: Notice end of lists.
2010-09-01 19:05:44 +02:00
Manish Sharma 2cf6136523 Allow "#" and "%" in tags
Patch largely from Manish, missing points added by Carsten
2010-08-31 08:25:20 +02:00
Carsten Dominik 999078b0bf Implement MathJax support
* lisp/org-exp.el (org-export-with-LaTeX-fragments): New default t, which
now means to use MathJax processing for HTML.  Also allow new value
`dvipng' to force the old image processing.
(org-infile-export-plist): Parse for MATHJAX setup line.
* lisp/org-html.el (org-export-html-mathjax-options): New option.
(org-export-html-mathjax-config): New function.
(org-export-html-mathjax-template): New option.
(org-export-html-preprocess): Call the LaTeX snippet processor with an
additional argument to declare special ways of processing.
(org-export-as-html): Bind the dynamical variable
`org-export-have-math'.  Insert the MathJax script template when it is
needed by the document.
* lisp/org.el (org-preview-latex-fragment): Call `org-format-latex' with
the additional processing argument.
(org-export-have-math): New variable, for dynamic scoping.
(org-format-latex): Implement specific ways of processing.  New
function argument for processing type.
(org-org-menu): Remove the entry to configure LaTeX snippet
processing.

MathJax is now the default for displaying math in a browser.
2010-08-13 14:22:16 +02:00
Carsten Dominik 682b275615 HTML export: Fix inlining images
* lisp/org-html.el (org-html-should-inline-p): Only inline images
if they should be.
2010-07-21 16:04:33 +02:00
Carsten Dominik 6268cceec3 Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
Philip Rooke 07cacd881d Correct some docstrings [part 2]
This is a second patch in a series that makes some straightforward
corrections to a number of docstrings.  Each change is normally to:

- correct a typo, or
- fix up hyperlinks to function or variable names, or
- ensure slightly better conformance with the documentation guidelines
  and tips given in the Elisp manual

No attempt is made to provide missing docstrings or document arguments.

Cheers,

Phil
2010-07-15 20:27:12 +02:00
Carsten Dominik 90afd8b797 Introduce new option for exporting LaTeX code to HTML
* lisp/org-html.el (org-export-html-preprocess): Call org-format-latex,
possibly with a protect-only argument.
* lisp/org.el (org-format-latex): New argument PROTECT-ONLY.

with the switch #+OPTIONS: LaTeX:verbatim ,
LaTeX code will be exported verbatim to HTML, so that jsmath can grab
and convert it.

Proposed by Christian Moe.
2010-07-01 10:23:33 +02:00
Carsten Dominik c201da51b8 Fix source code example bug with plain list export to HTML
* lisp/org-exp.el (org-export-format-source-code-or-example): Mark examples
by a property. o
* lisp/org-html.el (org-export-html-close-lists-maybe): Check if raw
HTML stuff was actually made from an example

Daniel Mahler writes:

> 2. I would like to embed source blocks in numbered lists, without
> breaking the numbering ie:
>
>    1) get ready
>     #+BEGIN_SRC sh
>    get_ready
>     #+END_SRC
>    2) go
>     #+BEGIN_SRC sh
>    go
>     #+END_SRC
>
>    currently the src blocks cause the numbering to reset, so all
> items in a sequence like this are numbered 1

This patch fixes this issue - but I cannot say anymore why the code in
org-export-html-close-lists-maybe does in fact work.  The code looks
wrong, but it seems to work.  What looks wrong is that i does not
check for the true indentation in the case when the line is not
protected.  It must be that this case is covered by some other code
further down in the exporter.
2010-06-18 08:49:25 +02:00
Carsten Dominik b27c1c5113 Fix whitespace problems 2010-06-07 08:35:10 +02:00
Bernt Hansen dc602f3b2e Emacs 22 support - use org-string-match-p
* contrib/lisp/org-special-blocks.el (org-special-blocks-make-special-cookies):
Emacs 22 doesn't have string-match-p
* lisp/org-freemind.el (org-freemind-write-mm-buffer):
(org-freemind-get-node-style):
Emacs 22 doesn't have string-match-p
* lisp/org-html.el (org-html-make-link):
Use new org-string-match-p for compatibility
2010-06-04 21:01:29 +02:00
Carsten Dominik 73f04ce48e Fix clickable images in HTML export
* lisp/org-html.el (org-export-as-html): Add the code to create
clickable images.
2010-06-03 10:27:58 +02:00
Carsten Dominik 31a9b70dfb Fix indentation 2010-06-02 15:02:36 +02:00
Sebastian Rose af080027fc file protocol in HTML links
The appended patch removes the protocol part from link URIs, if the
protocol is file. Neccessary, to show images again and make links work.
2010-05-26 22:48:06 -06:00
Julien Danjou 8c5f8a4d25 Do not expand title in <title> markups
If we expand `title', we may have HTML markup between the <title>
markups, which is not valid.

Signed-off-by: Julien Danjou <julien@danjou.info>
2010-05-26 14:10:28 -06:00
Julien Danjou a153f5a31d Fix docstring for org-export-html-{pre, post}amble
Signed-off-by: Julien Danjou <julien@danjou.info>
2010-05-26 14:09:13 -06:00
Carsten Dominik 8dd4bafd8e Restore Emacs 22 compability
* org-html.el (org-html-make-link): Use string-match,
string-match-p is not compatible with Emacs 22.
2010-05-25 13:49:45 +02:00
Carsten Dominik 7831cb7885 Don't add url type if link is relative.
* org-html.el (org-html-make-link): Don't add url type if link
is relative.
2010-05-23 11:59:27 +02:00
Tom Breton (Tehom) 459d99c44c Moved to new branch 2010-05-17 18:17:38 -04:00
Carsten Dominik c86a3fc4aa Push version number to 6.36trans 2010-05-09 06:24:20 +02:00
Carsten Dominik 88100d1580 Release 6.36a 2010-05-09 06:13:54 +02:00
Carsten Dominik ef51006a8f HTML export: Fix alignment bug
Patch by Stephen Peters.

Stephen writes:

> When creating a table, I was noticing that the
> <colgroup><col>... provides useful alignment information based on
> whether or not the column has numbers in it.  I think, however, that
> there is a mistake in this routine.  Take, for example, the following
> table:
>
> |  Id | Task         | Developer | Estimate | Spent | Remaining | Comp.% | Updated         |
> |-----+--------------+-----------+----------+-------+-----------+--------+-----------------|
> |   1 | Task One     | SLP       |        1 |     0 |         1 |      0 | SLP, 2010-04-27 |
> |   2 | Task Two     | SLP       |        1 |     0 |         1 |      0 | SLP, 2010-04-27 |
> |   3 | Task Three   | SLP       |        2 |     0 |         2 |      0 | SLP, 2010-04-27 |
> |   4 | Task Four    | SLP       |        2 |     0 |         2 |      0 | SLP, 2010-04-27 |
> |   5 | Task Five    | SLP       |      .25 |     0 |      0.25 |      0 | SLP, 2010-04-27 |
> | 5.1 | Another Task | XML team  |        0 |     1 |         0 |      0 | SLP, 2010-04-27 |
> |   6 | Task Six     | SLP       |      .25 |     0 |      0.25 |      0 | SLP, 2010-04-27 |
> | 6.1 | More Tasks   | DB team   |        3 |     0 |         3 |      0 | SLP, 2010-04-27 |
> |   7 | Task Seven   | SLP       |        3 |     0 |         3 |      0 | SLP, 2010-04-27 |
>
> When the colgroup list is created for this table, it reads:
>
> <colgroup><col align="right" /><col align="left" /><col align="left" /><col align="right" /><col align="right" /><col align="left" /><col align="left" /><col align="left" />
> </colgroup>
>
> Note that the first columns are correct, but the last few are not.  It
> should read right, left, left, right, right, right, right, left.
>
> I believe that this is due to the (< i nline) comparison within
> org-format-org-table-html, which is nonsensical because it's trying to
> compare a column number with a number of rows.  I've attached a patch
> for the problem.
2010-04-29 15:01:10 +02:00
Carsten Dominik b82652d90c Implement offsets for ordered lists
1. [@start:12] will star a lit a number 12
2010-04-26 14:29:17 +02:00
Carsten Dominik c370a5300b Modify xhtml IDs to comply with CSS standards 2010-04-25 13:44:50 +02:00
Carsten Dominik 816ff72306 Terminating lists by indentation of #+SPECIALS too
Sebastien Rose writes:

> there was much discussion about a terminator and I ran into a problem,
> that made me think we need one. But then I found we had one --- it's
> just not used on HTML export.
>
>
> Below is a little file I wrote. Thanks to the `- __' items, it results
> in the XHTML closely to what I wanted it to.
> But only as long as I use those _undocumented_ `- __' items. Once you
> remove them, you'll see, that the `#+html: </div...' stuff ends up
> inside the last list item and the XHTML will not validate.
>
>
> As I looked at it, I found the most natural solution would be, to
> terminate the list by regarding the indentation of `#+WHATEVER' and
> `#+BEGIN_WHATEVER' if inside lists [fn:1].
>
>
>
> The patch below (diffed against `remove-compatibility-code') makes
> XHTML-export honor the indentation of `#+SPECIALS'.
>
>
>
> Here's the Org-file I wrote (remove and add the `- __' list items to see
> the effect):
>
> #+OPTIONS: toc:nil
> #+STYLE: <style type="text/css">
> #+STYLE: body,p,div,td{font-size:13px;font-family:sans-serif;}
> #+STYLE: div { text-align:left; }
> #+STYLE: #content {width:550px;
> #+STYLE:     margin-left:auto;margin-right:auto;text-align:center; }
> #+STYLE: #postamble { width:550px;clear:both;border-top:1px solid black;
> #+STYLE:      margin-left:auto;margin-right:auto;text-align:center; }
> #+STYLE: </style>
>
> * List of design patterns
>
>  #+HTML: <div style="width:48%;float:left;">
>  *Behavioural Patterns*
>    - [[file:BatchCommand][BatchCommand]]
>    - [[file:ChainOfResponsibility.org][Chain Of Responsibility]]
>    - [[file:Command.org][Command]], UndoableCommand and BatchCommand
>    - [[file:Interpreter.org][Interpreter]]
>    - [[file:Iterator.org][Iterator]]
>    - [[file:Mediator.org][Mediator]]
>    - [[file:Memento.org][Memento]]
>    - [[file:NullObject][NullObject]]
>    - [[file:Observer.org][Observer]]
>    - [[file:State.org][State]]
>    - [[file:Strategy.org][Strategy]]
>    - [[file:TemplateMethod.org][Template Method]]
>    - [[file:Visitor.org][Visitor]]
>  *Creational Patterns*
>    - [[file:AbstractFactory.org][Abstract Factory]]
>    - [[file:Builder.org][Builder]]
>    - [[file:Factory.org][Factory]]
>    - [[file:FactoryMethod.org][Factory Method]]
>    - [[file:Prototype.org][Prototype]]
>    - [[file:Singleton.org][Singleton]]
>    - __
>  #+html: </div>
>  #+html: <div style="width:48%;float:right;">
>  *Structural Patterns*
>    - [[file:Adapter.org][Adapter]]
>    - [[file:Composite.org][Composite]]
>    - [[file::Bridge.org][Bridge]]
>    - [[file:Decorator.org][Decorator]]
>    - [[file:Facade.org][Facade]]
>    - [[file:Flyweight.org][Flyweight]]
>    - [[file:Proxy.org][Proxy]]
>  *Unsorted*
>    - [[file:BusinessDelegate.org][Business Delegate]]
>    - [[file:DataAccessObject.org][Data Access Object]]
>    - [[file:DataTransferObject.org][Data Transfer Object]]
>    - [[file:DependencyInjection.org][Dependency Injection]]
>    - [[file:FluentInterface.org][Fluent Interface]]
>    - [[file:InversionOfControl.org][Inversion Of Control]]
>    - [[file:ModelViewControler.org][Model View Controler]]
>    - [[file:ModelViewPresenter.org][Model View Presenter]]
>    - [[file:Plugin.org][Plugin]]
>    - __
>  #+HTML: </div>
2010-04-22 08:41:09 +02:00
Carsten Dominik 3672a495e1 Fix minor bug with call to kill-buffer 2010-04-18 16:54:19 +02:00
Carsten Dominik 43bf1bbbd7 Push version number to 6.35trans 2010-04-15 12:24:55 +02:00
Carsten Dominik 6f3026edf1 Release 6.35g 2010-04-08 20:15:15 +02:00
Carsten Dominik a589c7a22e Release 6.35f 2010-04-08 10:36:32 +02:00
Carsten Dominik 50e5924d8a Release 6.35e 2010-04-07 16:33:52 +02:00
Carsten Dominik f722763f8a Release 6.35d 2010-04-07 16:26:42 +02:00
Carsten Dominik d65ed03be6 Update copyright notices and fix wrong version tags 2010-04-07 16:26:10 +02:00
Carsten Dominik cafbe1d038 Release 6.35c 2010-04-07 08:58:25 +02:00
Carsten Dominik b213c0f31e Release 6.35b 2010-04-07 07:54:14 +02:00
Carsten Dominik 08d0d2fa20 Release 6.35 2010-04-06 09:16:36 +02:00
Carsten Dominik 8fdf80bb5b Fix whitespace and compiler wanings 2010-04-01 13:11:54 +02:00
Carsten Dominik aa220a1e6a More fixes 2010-04-01 12:44:02 +02:00
Carsten Dominik da556cee82 Implement new and better support for entities 2010-04-01 12:44:01 +02:00
Carsten Dominik 31b19b1afc Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
Conflicts:
	lisp/ChangeLog
2010-04-01 12:43:34 +02:00
Eric Schulte 18a1f8e98a on HTML export, latex source code added as alternative text to latex images 2010-03-31 10:23:24 -06:00
Carsten Dominik 6a5e18397f Minor fix 2010-03-31 09:26:05 +02:00
Carsten Dominik aed051cf8c HTML export: Make better use of labels 2010-03-29 11:13:16 +02:00
Carsten Dominik 313f01d297 Do some formatting of table and figure captions
Table and figure captions are not fully processed.  Now we at least do
basic formatting, but links and footnotes still do not work.
2010-03-29 07:30:00 +02:00
Carsten Dominik 3f6a52dd8b New option to turn off export of the email address
Default is actually off.
2010-03-26 08:05:14 +01:00
Carsten Dominik 2b14934fe8 HTML export: Fix linking to targets in external files
Dan Davison writes:

> Bug report
> ==========
> If I have this:
>
> A [[file:zz.org::#mytarget][link]] to a target with a custom ID
>
> and export it to HTML, I get
>
> A <a href="zz.html##mytarget">link</a> to a target with a custom ID
>
> which (in firefox on linux) links to the file but does not jump to the
> target. However, if I change the '##' to '#' then firefox jumps to the
> correct location. Is this an org bug?
>
> Very tentatively proposed patch
> ===============================
> I've investigated a bit (notes below), resulting in this proposed patch:
>
> --8<---------------cut here---------------start------------->8---
> diff --git a/lisp/org-html.el b/lisp/org-html.el
> index aa70408..5ee5b19 100644
> --- a/lisp/org-html.el
> +++ b/lisp/org-html.el
> @@ -1110,7 +1110,7 @@ lang=\"%s\" xml:lang=\"%s\">
>                     (abs-p (file-name-absolute-p filename))
>                     thefile file-is-image-p search)
>                (save-match-data
> -                 (if (string-match "::\\(.*\\)" filename)
> +                 (if (string-match "::#?\\(.*\\)" filename)
>                      (setq search (match-string 1 filename)
>                            filename (replace-match "" t nil filename)))
>                  (setq valid
> --8<---------------cut here---------------end--------------->8---
>
> Doc patch
> =========
> The link above (file:zz.org::#mytarget) was created by C-c l on a
> heading with a CUSTOM_ID property. However, I couldn't see where in the
> manual links of this form are documented. Do we need to add this link
> type to section 4.7 "Search options in file links", e.g.
>
> --8<---------------cut here---------------start------------->8---
> diff --git a/doc/org.texi b/doc/org.texi
> index f49f056..c8cc1a5 100644
> --- a/doc/org.texi
> +++ b/doc/org.texi
> @@ -3116,6 +3116,7 @@ link, together with an explanation:
> [[file:~/code/main.c::255]]
> [[file:~/xx.org::My Target]]
> [[file:~/xx.org::*My Target]]
> +[[file:~/xx.org::#my-custom-id]]
> [[file:~/xx.org::/regexp/]]
> @end example
>
> @@ -3130,6 +3131,8 @@ link will become an HTML reference to the corresponding named anchor in
> the linked file.
> @item *My Target
> In an Org file, restrict search to headlines.
> +@item #my-custom-id
> +Link to a heading with a @code{CUSTOM_ID} property
> @item /regexp/
> Do a regular expression search for @code{regexp}.  This uses the Emacs
> command @code{occur} to list all matches in a separate window.  If the
> --8<---------------cut here---------------end--------------->8---
>
> Notes
> =====
> At line 1134 of org-html.el there is
>
> 			(setq thefile (concat thefile "#"
> 					      (org-solidify-link-text
> 					       (org-link-unescape search)))))
>
> during evaluation of which 'search is bound to "#mytarget", which
> suggested that the problem might be in the regexp parsing creating
> 'search.
2010-03-19 18:04:23 +01:00
Carsten Dominik cff060f3ac HTML export: Do not allow protected lines into the TOC
Daniel Clemente writesL

> Hi, I found an HTML export bug with org-mode 6.34c-140-g44c8 and
> older. I used:
>
> --------------------------------------------------------
> * only one section
> #+BEGIN_EXAMPLE:
>
>  We need:
>  ,* pears
>  ,* lettuce
>  ,* watermelons
>
>  Very important!
> #+END_EXAMPLE:
> --------------------------------------------------------
>
>  And the outputed table of contents had this code:
>
> --------------------------------------------------------
> <div id="text-table-of-contents">
> <ul>
> <li><a href="#sec-1">1 only one section </a></li>
> <li><a href="#sec-2">2 pears</a></li>
> <li><a href="#sec-3">3 lettuce</a></li>
> <li><a href="#sec-4">4 watermelons</a></li>
> </ul>
> </div>
> --------------------------------------------------------
>
> This is wrong because the asterisks inside the example don't
> represent headers. There should be only one header.
2010-03-03 14:36:31 +01:00
Carsten Dominik 6d1e30828b Re-install the support for table.el tables again.
This support was totally broken.  It works now again.  Unfortunately
it is not possible to edit the table directly in the org-mode buffer
anymore - to edit such a table, you have to use C-c '
2010-02-26 22:33:49 +01:00
Carsten Dominik 74b2b73e57 Minor fix for previous commit 2010-02-25 15:39:55 +01:00
Carsten Dominik e7f7a82a74 HTML export: Fix textareas
Textareas no longer have an empty line at the beginning, and the
overflow-x stype property has been moved to the CSS section.

Patch by Ulf Stegemann
2010-02-25 12:26:10 +01:00
Carsten Dominik d0b0f776d2 Export: Kill product buffer if it has been displayed directly
Request by Livin Stephen Sharma
2010-02-21 09:19:21 +01:00
Carsten Dominik e853e2d798 HTML export: Add class to outline containers using property
The HTML_CONTAINER_CLASS property can now be used to add a property to
the outline container of a node.
2010-02-01 09:37:35 +01:00
Carsten Dominik 2e53d9b137 Remove comma after means in many docstrings
Stephen Eglen says these commas should not be there.
2010-01-21 16:15:40 +01:00
Carsten Dominik 06e74afce3 Version number to 6.34trans 2010-01-20 10:13:21 +01:00
Carsten Dominik a1709ba641 Release 6.34c 2010-01-18 00:10:11 +01:00
Carsten Dominik 2f2f9441d4 Release 6.34b 2010-01-14 23:06:55 +01:00
Carsten Dominik c077142241 Release 6.34a 2010-01-12 08:53:44 +01:00
Carsten Dominik 288c724335 Release 6.34 2010-01-10 10:57:53 +01:00
Carsten Dominik 275b6627a6 Release 3.34 2010-01-10 10:54:52 +01:00
Carsten Dominik 01b1851f2d Fix bug with display properties in resulting .html buffer 2010-01-04 10:23:15 +01:00
Carsten Dominik 7050ea8d4a Use LATEX_HEADER stuff also when previewing fragments 2010-01-01 11:18:10 +01:00
Carsten Dominik 89276e1982 Make body-only export not take the first buffer line for a title 2009-12-16 20:16:48 +01:00
Carsten Dominik 4d4d3ea745 Incorporate fix from downstream Emacs 2009-12-15 06:11:39 +01:00
Carsten Dominik 2df4c1ca04 New hook org-export-first-hook 2009-12-11 08:40:19 +01:00
Carsten Dominik 178acdac94 HTML export: Avoid empty lines at the beginning
This was a request by Ian Barton, to get Jekyll blogging working.
2009-11-21 20:50:37 +01:00
Carsten Dominik 62a7301a5e Push release number to 6.33trans 2009-11-20 20:20:31 +01:00
Carsten Dominik 24061fddd1 Release 6.33f 2009-11-20 15:15:05 +01:00
Carsten Dominik 37e9b1c51f Release 6.33e 2009-11-20 13:58:31 +01:00
Carsten Dominik 24a49967f1 Release 6.33d 2009-11-20 12:34:50 +01:00
Carsten Dominik 9714678f30 HTML export: Move home/up link div into the content div
Patch by Sebastian Rose
2009-11-17 15:11:28 +01:00
Carsten Dominik 11679eb824 Add an ID to the div surrounding up/home links 2009-11-16 18:08:42 +01:00
Carsten Dominik c7371cc7fe Push version number to 6.33trans 2009-11-15 09:46:43 +01:00
Carsten Dominik 6bc6379dfe Release 6.33c 2009-11-15 08:00:52 +01:00
Carsten Dominik 6c977c41c3 Release 6.33b 2009-11-14 16:25:31 +01:00
Carsten Dominik b8a6721a68 Release 6.33a 2009-11-13 23:22:18 +01:00
Carsten Dominik 5ca6635993 Push version number to 6.33a 2009-11-13 22:54:22 +01:00
Carsten Dominik 82ee0cc583 Release 6.33 2009-11-13 07:10:51 +01:00
Carsten Dominik afc23be5c0 Fix typos 2009-11-12 17:50:31 +01:00
Bernt Hansen 0042080e4c Fix spelling and grammar 2009-11-12 07:39:29 -05:00
Carsten Dominik 2ab5c21f61 Protect target-like strings in verbatim emphasis
Martin G. Skjaeveland writes:

> Then I write
>
> some text some text ~<<some_scr_block_name>>~.
>
> because I want "<<some_scr_block_name>>" written as verbatim in my latex
> export, I get, in latex,
>
> \texttt{\textbackslash{}label\{some\_src\_block\_name\}some\_src\_block\_name}.
>
> which gives me the text
>
> \label{some_src_block_name}some_src_block_name
>
> in verbatim.
2009-11-08 11:24:01 +01:00
Carsten Dominik 58562167b4 Version number to 6.32trans 2009-10-27 18:23:19 +01:00
Carsten Dominik e0949896f7 Release 6.32b 2009-10-27 18:22:28 +01:00
Carsten Dominik 037b685d50 Push version number to 6.32trans 2009-10-27 09:25:30 +01:00
Carsten Dominik fcd2ef541f Release 6.32 2009-10-26 08:57:21 +01:00
Carsten Dominik f026e3a6b8 Don't wrap figures without captions
This is to allow better figure placement.
2009-10-02 08:29:21 +02:00
Carsten Dominik 6b0a251eea Push version number to 6.31trans 2009-10-01 11:57:17 +02:00
Carsten Dominik 1b37d5e07c Release 6.31a 2009-10-01 09:13:58 +02:00
Carsten Dominik c11e0b44ae Release 6.31 2009-09-30 16:03:17 +02:00
Carsten Dominik be78e8e5ad List user-visible changes for release 6.31 2009-09-29 08:02:10 +02:00
Carsten Dominik 38f82c430b Remove final dot from a number of error messages
Downstream Emacs patch.
2009-09-24 09:09:33 +01:00
Carsten Dominik 291a6db848 Release number back to 6.30trans 2009-09-04 10:39:01 +02:00
Carsten Dominik 12ab55ca43 Release 6.30d 2009-09-03 13:53:46 +02:00
Carsten Dominik adfa87282d Push version number to 6.30trans 2009-09-03 08:10:36 +02:00
Carsten Dominik 63e1714288 Release 6.30c 2009-09-02 14:40:56 +02:00
Carsten Dominik fc332703bf Release 6.30b 2009-09-02 11:33:10 +02:00
Carsten Dominik 2daabacc29 Require cl in org-html.el 2009-09-02 10:39:55 +02:00
Carsten Dominik dcd1255762 Avoid using the variable `default-major-mode'. 2009-09-02 09:30:22 +02:00
Carsten Dominik 1d04b205e6 Release 6.30a 2009-09-02 09:00:23 +02:00
Carsten Dominik 24e7c62b84 Some small fixes 2009-09-02 08:53:06 +02:00
Carsten Dominik db70cdb13b Release 6.30 2009-09-01 06:09:23 +02:00
Carsten Dominik 94d91eaf03 HTML export: Fix bugs with footnotes. 2009-08-16 06:41:30 +02:00
Carsten Dominik bd8e816ea0 Move constant definition so that org-html does not have to be loaded just for font-locking 2009-08-10 14:02:24 +02:00
Carsten Dominik 6bd7ffef36 Incorporate Glen Morris' changes in downstream Emacs 2009-08-08 06:34:24 +02:00
Carsten Dominik bfdd3d3fd3 Push version number to 6.29trans 2009-08-06 12:07:20 +02:00
Carsten Dominik 0864163024 Release 6.29c 2009-08-06 06:26:23 +02:00
Carsten Dominik d6b37ddbea Release 6.29b 2009-08-05 12:34:30 +02:00
Carsten Dominik 1c25048e48 Release 6.29a 2009-08-04 23:54:22 +02:00
Carsten Dominik d67a9be8a2 Release 6.29 2009-08-04 23:06:39 +02:00
Carsten Dominik f322206708 Fix parenthesis error in footnote export code 2009-08-04 16:46:34 +02:00
Carsten Dominik 4249cbf454 Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
Conflicts:
	lisp/ChangeLog
2009-08-01 11:44:55 +02:00
Bastien Guerry 01d84ed000 Bugfix: correctly convert the footnote reference. 2009-07-27 17:59:21 +08:00
Carsten Dominik 3788dc336f HTML export: Fix bug with horizontal rules in plain lists.
Brenton Kenkel writes:

> I'm using org-mode 6.28e on Aquamacs (based on GNU Emacs
> 22.3.1) on Mac OS X. I'm having an issue with horizontal
> rules and lists in HTML export. When I export the following
> to HTML, the horizontal rule tag is generated within the
> unordered list, rather than after it ends:
>
> ,-----
> | * test
> |
> | - this is a list
> |
> |
> | -----
> |
> | * next section
> |
> | No list.
> |
> |
> | -----
> |
> `-----
>
> I want the first horizontal rule to be even with the second;
> namely, extending all the way to the left. Any way to do
> this?
2009-07-27 07:06:00 +02:00
Bastien Guerry ed0a91e76f New option org-export-html-footnote-format.
This defines the format for the footnote reference.
This string must contain %s which will be replaced by
the footnote reference.
2009-07-27 11:32:52 +08:00
Carsten Dominik d56f2f4fa5 HTML export: Fix problems with colgroup tags
Special lines with <, >, and <> in tables should trigger colgroup tags.
2009-07-26 08:15:34 +02:00
Bastien Guerry 4c23afccc5 Fix small typo. 2009-07-15 16:59:33 +02:00
Carsten Dominik 636c524df3 HTML export: Show UP and HOME links if defined
org-export-html-link-up and org-export-html-link-home are now also
inserted into normal HTML export, above the page title.
2009-07-07 13:20:25 +02:00
Carsten Dominik 30d448b2e1 HTML export: More flexibility for preamble and postamble
Andreas Rottmann writes:

> Well, the subject says it all -- attached is a rough patch to
> allow more flexibility with the HTML export; I use it like this:
>
>    (defun rotty/homepage-preamble (opt-plist)
>      (insert "<div id=\"header\">")
>      (insert
>       "
>    <div id=\"navbar\">
>    <a class=\"menu\" href=\"/\">Home</a>
>    | <a class=\"menu\" href=\"/Writings.html\">Writings</a>
>    | <a class=\"menu\" href=\"/Software.html\">Software</a>
>    | <a class=\"menu\" href=\"/blog/\">Blog</a>
>    </div>
>    ")
>      (insert (format
>               "<h1 class=\"title\"><a href=\"/\">rotty</a> &gt; %s</h1>\n"
>               (plist-get opt-plist :title)))
>      (insert "</div>\n")
>      (insert "<div id=\"inner\">\n"))
2009-07-06 18:10:26 +02:00
Carsten Dominik c1d00fa463 Export: General mechanism for local settings
Many different people want to set many different variables in a
buffer-local way for export.  This cannot be done with file variables,
because the Org buffer is not current while the exporter is running.

Lots of variables can be set with the #+OPTIONS lines, but finding
abbreviations goes only so far.

Therefore we have now a general mechanism that can be used to bind
variables during export operations.

a line like:   #+BIND: variable value

will bind the variable to value.  For example,
the line

>>      #+OPTIONS: toc:nil

can now equivalently be written as

>>      #+BIND: org-export-with-toc nil
2009-07-06 17:00:03 +02:00
Bastien Guerry 03d147455a Let `org-export-html-xml-declaration' use only double quote char.
Mixing single and double quotes after the "echo" instruction seems
to result in weird display.  Using only double quote char fixes this.
2009-07-02 07:44:01 +02:00
Carsten Dominik 7bc578c6ad HTML export: Fix export bug with ID links 2009-06-27 13:59:59 +02:00
Carsten Dominik f648323253 Push version number to 6.28trans 2009-06-26 17:26:50 +02:00
Carsten Dominik cd4e52a5ef Release 6.28d 2009-06-26 17:23:27 +02:00
Carsten Dominik 00ddc4dba7 Release 6.28c 2009-06-26 09:27:50 +02:00
Carsten Dominik e7ffcc1d4d Release 6.28b 2009-06-25 09:01:20 +02:00
Carsten Dominik 7906427aa6 Release 6.28 2009-06-25 08:59:59 +02:00
Carsten Dominik 6664cc4495 Fix typo 2009-06-18 23:22:08 +02:00
Carsten Dominik 8e34ea7b48 HTML export: Make table row tag customizable
Xin Shi writes:

> Hello Experts,
>
> I use org-mode to produce a lot of big tables with numbers in
> them. When I present these tables by HTML, I found it's hard to
> keep track which row it is. I'm wondering if it's possible to
> implement additional class attribute to the <tr>, such as:
>
> <table class="sample">
> <tr class="d0"><td>One</td><td>Fish</td></tr>
> <tr class="d1"><td>Two</td><td>Fish</td></tr>
>
> <tr class="d0"><td>Red</td><td>Fish</td></tr>
> <tr class="d1"><td>Blue</td><td>Fish</td></tr>
> </table>
>
> So, that in the CSS file, it'll be easier to implement the color:
>
>
> <style type="text/css">
> table.sample {
> 	border: 6px inset #8B8378;
> 	-moz-border-radius: 6px;
> }
> table.sample td {
> 	border: 1px solid black;
> 	padding: 0.2em 2ex 0.2em 2ex;
>
> 	color: black;
> }
> table.sample tr.d0 td {
> 	background-color: #FCF6CF;
> }
> table.sample tr.d1 td {
> 	background-color: #FEFEF2;
> }
> </style>

This commit introduces a new variable `org-export-table-row-tags'
that can be used for this and similar purposes.  For the example
of the poster, one could use:

 (setq org-export-table-row-tags
       (cons '(if head "<tr>"
                (if (= (mod nline 2) 1)
                    "<tr class=\"d1\">"
                  "<tr class=\"d0\">"))
             "</tr>"))
2009-06-18 07:07:22 +02:00
Carsten Dominik 3825cc6bcb Export: Fix bug with empty lines in examples
Patch by Baoqiu Cui.
2009-06-14 18:05:02 +02:00
Carsten Dominik ae16e6ceca More exporter fixes. 2009-06-10 00:38:06 +02:00
Carsten Dominik 342b2d0884 Fix bugs in HTML and DOCBOOK exporters 2009-06-09 23:42:33 +02:00
Carsten Dominik 5c30228ee0 Fix bug with indentation interpretation during export 2009-06-08 19:57:19 +02:00
Carsten Dominik 379b24cc63 Fix whitespace issues 2009-06-08 08:00:46 +02:00
Carsten Dominik 503e571e43 Keep byte compiler happy 2009-06-07 17:07:07 +02:00
Carsten Dominik 8a9e604a7a New indentation treatment for blocks during export
Now we also deal with center, quote, and verse blocks.
2009-06-07 16:11:14 +02:00
Carsten Dominik d8e44c1fa0 Minor fix 2009-06-07 10:14:14 +02:00
Carsten Dominik 75117098f0 HTML export: Respect example indentation when parsing plain lists
Examples and source code blocks that are not sufficiently indented
will now terminate plain lists.
2009-06-07 08:44:50 +02:00
Carsten Dominik 1db461321a Keep compiler happy 2009-06-02 14:49:38 +02:00
Carsten Dominik 99b3b2d261 HTML export: Better defaults for org-export-html-xml-declaration 2009-05-28 13:41:28 +02:00
Carsten Dominik ca79257ca6 HTML export: Better defaults for org-export-html-xml-declaration 2009-05-27 18:16:26 +02:00
Carsten Dominik ae7b8f6b12 Push version number to 6.27trans 2009-05-26 15:41:44 +02:00
Carsten Dominik 0421dead4b Release 6.27a 2009-05-25 16:04:45 +02:00
Carsten Dominik 45c53b2a49 Publishing: Allow :body-only parameter for HTML export
Patch by Richard Klinda
2009-05-25 15:58:16 +02:00
Carsten Dominik b681c7b26e Release 6.27 2009-05-23 08:22:04 +02:00
Carsten Dominik 91f77d7029 Export: Make all export commands push the result to the kill ring
All export commands now push the result to the kill ring by default.
This is subject to the variable `org-export-push-to-kill-ring'.

Also, this commit adds a new variable
`org-export-show-temporary-export-buffer' which can be used to turn
off the display of the temporary buffer containing the exported text.
Since this stuff is now automatically pushed onto the kill ring, some
people might prefer not to see this buffer.
2009-05-21 09:14:33 +02:00
Carsten Dominik 127a339a40 Fix bug, dammit! 2009-05-20 08:51:27 +02:00
Carsten Dominik d62795f8a7 Fix bug 2009-05-20 08:32:13 +02:00
Carsten Dominik f5fc821214 HTML export: Make xml declaration configurable 2009-05-20 08:24:49 +02:00
Carsten Dominik b8a339e96f HTML export: Temporary solution of the php/xml problem on Worg 2009-05-19 09:35:47 +02:00
Carsten Dominik d80faba613 Fix docstring of export functions: HIDDEN parameter is obsolete 2009-05-19 08:09:30 +02:00
Carsten Dominik e96b09edff HTML export: Add the xml declaration again. 2009-05-18 17:15:19 +02:00
Carsten Dominik f6f5e23b0c Fix bug 2009-05-18 15:59:05 +02:00
Carsten Dominik 9c342b61c6 Remove xml declaration until we have a general solution 2009-05-18 15:32:26 +02:00
Carsten Dominik fbe4f09cd8 HTML export: Add XML declaration
Patch by Sebastian Rose
2009-05-15 09:21:46 +02:00
Carsten Dominik 251f82d555 Fix bug. 2009-05-14 10:17:14 +02:00
Carsten Dominik 2e9202362f Publishing: Allow to publish the Org source file
There is now a new export function, `org-export-as-org', which
basically creates a copy of the Org file with things like archived
trees, commented trees, and trees deselected by export tags,
stripped.
2009-05-14 09:33:00 +02:00
Carsten Dominik 8a1e3d0773 HTML export: Specify the scope parameter in table header fields 2009-05-08 06:34:13 +02:00
Carsten Dominik e28c8b7329 New option `org-export-html-table-use-header-tags-for-first-column' 2009-05-07 15:05:41 +02:00
Carsten Dominik a01ae6ee38 Export: Respect the description in a coderef
Shaun Johanson writes:

> Consider the following Org file:
>
>   * Test
>
>    See [[(foo)][FOOBIE]]
>
>    #+BEGIN_EXAMPLE
>    <foo>: blah blah       (ref:foo)
>    #+END_EXAMPLE
>
> Question 1)
>  In Org mode the link displays as FOOBIE, in the exported HTML it
>  displays as (foo). Is there any way to cause the link to use the
>  description (FOOBIE) in HTML? If not would this be a useful option
>  to add?

This was a bug, fixed now.
2009-05-06 12:17:24 +02:00
Carsten Dominik 07aad4eaae HTML export: Fix Safari validation issues 2009-05-04 21:04:38 +02:00
Carsten Dominik 2207baf34c HTML export: Fix col and colgroup tags
Patch by Sebastian Rose
2009-05-04 16:21:59 +02:00
Carsten Dominik abc874cefc Export: New hooks for Chris Gray's LaTeX/HTML blocks
Chris Gray had the idea to have arbitrary blocks turned in LaTeX
environments and HTML divs.  These three new hooks allow
implementation has an add-on rather than a patch.
2009-05-02 09:24:28 +02:00
Carsten Dominik 69e6d249aa Push version number to 6.26trans 2009-04-22 09:08:13 +02:00
Carsten Dominik 73854f435d Release 6.26d 2009-04-22 06:42:17 +02:00
Carsten Dominik 595e9603ac Release 6.26c 2009-04-21 20:26:27 +02:00
Carsten Dominik e0cd12716a Release 6.26b 2009-04-21 10:21:36 +02:00
Carsten Dominik b8a5f1a7fc Release 6.26a 2009-04-19 22:31:36 +02:00
Carsten Dominik 49669d137a HTML export: Fix bugs with IDs 2009-04-19 22:27:27 +02:00
Carsten Dominik ba66d2c8ae Release 6.26 2009-04-19 08:38:49 +02:00