Commit graph

188 commits

Author SHA1 Message Date
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