Commit Graph

1772 Commits

Author SHA1 Message Date
Øyvind Stegard cc74ae8b7a org-contacts: Ensure contacts cache is updated if it contains markers with no buffer
* contrib/lisp/org-contacts.el (org-contacts-db-need-update-p):
Check if org-contacts-db cache contains markers with no buffer as well, when
determining if cache should be updated from files.

The function `org-contacts-db-need-update-p' does two checks to determine if the
contacts cache should be updated:
1. If the variable `org-contacts-last-update' is nil.
2. If modification time of any file containing contacts is more recent than
   timestamp recorded in `org-contacts-last-update'.

There is another case where an update is required: when marker objects contained
in the contact cache `org-contacts-db' suddenly point to no buffer. If a buffer
containing contacts is killed, but underlying file is not modified, org-contacts
will not detect this, and cached markers that pointed to the now killed buffer
will become "dead" (e.g. have no buffer associated with them). This seems to cause
problems for instance in `org-contacts-anniversaries', which if used as diary
sexp in agenda file, will cause "Bad sexp" errors.
2013-07-20 17:21:37 +02:00
Nicolas Goaziou fb0f806299 ox-freemind: Fix code typo
* contrib/lisp/ox-freemind.el (org-freemind--build-node-contents): Fix
  code typo.
2013-07-19 23:13:57 +02:00
Nicolas Goaziou 0cdf2eb7ce Merge branch 'maint'
Conflicts:
	contrib/lisp/ox-koma-letter.el
2013-07-12 09:10:26 +02:00
Nicolas Goaziou a2a5c8fd5b ox-beamer/latex/koma-letter: Fix missing newlines in header
* contrib/lisp/ox-koma-letter.el (org-koma-letter-template): Fix
  missing newlines in header.
* lisp/ox-beamer.el (org-beamer-template): Fix missing newlines in
  header.
* lisp/ox-latex.el (org-latex-template): Fix missing newlines in
  header.
2013-07-12 09:07:23 +02:00
Bastien Guerry e29a4703c7 Merge branch 'master' of orgmode.org:org-mode 2013-07-10 12:11:32 +02:00
Bastien Guerry 642bd253d0 Merge branch 'maint' 2013-07-10 11:53:22 +02:00
Bastien Guerry 8eb8082b64 contrib/lisp/ox-rss.el: Mention that Emacs 24.1 at least is required 2013-07-10 11:53:14 +02:00
Nicolas Goaziou 325e40d378 ox-bibtex: Add [[cite:...]] links support
* contrib/lisp/ox-bibtex.el (org-latex-link, org-html-link): New
  functions.
(org-bibtex-citation-p, org-bibtex-get-citation-key): Update function
to support "cite" links.
(org-bibtex-process-bib-files): Also look after "cite" links when
building citation list.
2013-07-10 11:03:39 +02:00
Bastien Guerry 5aad4a8932 ox-rss.el (org-rss-publish-to-rss): Fix code typo
* ox-rss.el (org-rss-publish-to-rss): Fix code typo.
2013-07-04 18:37:55 +02:00
Nicolas Goaziou 758a545fb6 Export back-ends: Apply changes to back-end structure
* lisp/ox-html.el (org-html--format-toc-headline): Make use of
  anonymous back-ends.
* lisp/ox-odt.el (org-odt-footnote-reference): Make use of anonymous
  back-ends.
(org-odt-format-label, org-odt-toc, org-odt-format-headline--wrap):
  Use `org-export-with-backend' instead of
  `org-export-with-translations'.
* contrib/lisp/ox-freemind.el (org-freemind--build-node-contents): Use
  `org-export-with-backend' instead of `org-export-with-translations'.
2013-07-04 14:17:49 +02:00
Bastien Guerry 330eb689cd contrib/lisp/ox-rss.el (org-rss-publish-to-rss): Add the PUBDATE property when publishing
* contrib/lisp/ox-rss.el (org-rss-publish-to-rss): Add the PUBDATE property
when publishing.

Thanks to Mikko Kouhia for reporting this bug.
2013-07-03 11:32:13 +02:00
Bastien Guerry 2ccd6d9887 Merge branch 'maint' 2013-07-01 00:36:17 +02:00
Eric Abrahamsen cc7d54515b * contrib/lisp/orgtbl-sqlinsert.el (orgtbl-to-sqlinsert): Bugfixes regarding header line formatting 2013-07-01 00:30:39 +02:00
Bastien Guerry aa500b1eaa Merge branch 'maint' 2013-06-27 19:01:21 +02:00
Bastien Guerry 21d1d4d137 ox-rss.el (org-rss-build-channel-info): Don't export the title
* ox-rss.el (org-rss-build-channel-info): Don't export the
title of the RSS channel, as it produce invalid RSS 2.0.
2013-06-27 18:57:09 +02:00
Bastien Guerry 370a2bfb4f Merge branch 'maint' 2013-06-27 17:02:50 +02:00
Bastien Guerry 3118565905 ox-rss.el (org-rss-headline): Various fixes.
* contrib/lisp/ox-rss.el (org-rss-headline): Fix the date and title
formats.
(org-rss-build-channel-info): Fix the date format.  Add the
author's name after her email.
2013-06-27 16:39:37 +02:00
Eric Schulte d316ecab0e missing argument to error message
* contrib/lisp/ox-koma-letter.el (org-koma-letter-template): Missing
  argument to error message.
2013-06-13 09:44:49 -06:00
rasmus a9c044a648 Possible to set default class for ox koma letters.
* ox-koma-letter.el (org-koma-letter-default-class): default class for
=ox-koma-letter=. Default is nil.
* ox-koma-letter.el (org-koma-letter-plug-into-ox): add a sparse
letter class to =`org-latex-class'= and set it to default.

By default it will use =`org-latex-default-class'=.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-06-12 13:38:48 +02:00
rasmus 878ff19f35 Added support for to and from heading.
* ox-koma-letter.el: documentation.
(org-koma-letter-special-tags-in-letter): list of tags that
are typeset as part of the letter.
(org-koma-letter--determine-special-value): determine which
value to use (for to and from currentlly) if more than
candidate is available.  Which value is selected depends on
`org-koma-letter-prefer-special-headings'.
(org-koma-letter-prefer-special-headings): a boolean stating
whether to prefer headings with to/from or the #+X_ADDRESS.

The following letter now exports "as expected".  In particular when
special-headings is t heading values have presedence so the
from address would be ="Rasmus\nEmacs\nOrg-mode"= where the
=\n=s would be escaped.  If specia-headings is nil (default)
the from would be my-adr.  The same is true for TO address.

Here's the contents

* from :from:

   Rasmus
   Emacs
   Org-mode

On a technical note, note that the default value will be used if
neither #+X_ADDRESS or a heading is given.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-06-12 13:38:31 +02:00
rasmus.pank 8dd2aa4041 Bug fixes for ox-koma-letter.el
* ox-koma-letter.el: updated documentation and improved defcustoms.
(org-koma-letter-special-tags-after-letter)
(org-koma-letter-special-tags-after-closing): now symbol.
(org-koma-letter--get-custom): falls back to value
(org-koma-letter--prepare-special-contents-as-macro): let
newlines be handled outside of the function
(org-koma-letter--remove-offending-new-lines): function to add
new lines.
(org-koma-letter-headline): updated to work with symbols and
made more robust.
(org-koma-letter-export-to-latex): reset
=`org-koma-letter-special-contents'= to nil

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-06-12 13:37:56 +02:00
Øyvind Stegard d3fb1812fa org-contacts: Provide ordering when using cycle completion
* contrib/lisp/org-contacts.el (org-contacts-metadata-prefix):
Provide same function for cycle ordering as is used for display ordering
in completion metadata.

When using cycle completion style for contacts, by setting
`completion-cycle-threshold' to some value, the ordering was not consistent
with order of email addresses in contact definition, nor the order
which was used for regular display completion. Fix that by also
supplying sort function for cycle completion in metadata.
2013-06-11 20:43:19 +02:00
Feng Shu e3cc1ca792 contrib/lisp/org-contacts.el: Add a complex org-contacts template to the file header
* contrib/lisp/org-contacts.el: Add a complex org-contacts template to
the file header, which can help users to know all the org-contacts
properties quickly.
2013-06-04 00:35:28 +02:00
Nicolas Goaziou 6e059f228f ox-bibtex: Fix compilation warnings
* contrib/lisp/ox-bibtex.el (org-bibtex-html-entries-alist,
  org-bibtex-html-keywords-alist): Fix compilation warnings.
2013-06-02 09:33:57 +02:00
Grégoire Jadi 1399c34e2a contrib/lisp/org-contacts.el: Various formatting improvements and bug fixes
* contrib/lisp/org-contacts.el (org-contacts-ignore-property): Improve
formatting and spelling.
(org-contacts-complete-name): Improve formatting.
(org-contacts-vcard-format): Improve formatting and silent byte compiler.
(org-contacts-split-property): Fix a bug where `omit-nulls' were not
forced to `t' when `separators' was nil.
2013-05-31 01:54:19 +02:00
Feng Shu c81b905f44 contrib/lisp/org-contacts.el: Add a feature, which can ignore emails or phones with property
* contrib/lisp/org-contacts.el (org-contacts-ignore-property): New variable.
(org-contacts-remove-ignored-property-values): New function, which
remove all ignore-list's elements from list.
(org-contacts-complete-name): When completing, ignore the
values which has been included into the ignore property.
(org-contacts-vcard-format): Don't export the values which has
been included into the ignore property.

If emails or phones is included into the ignore property, they will
not show in complete buffer. When the contact is exported to vcard,
they will be ignored too.
2013-05-31 01:17:58 +02:00
Nicolas Goaziou 94c48111c9 Merge branch 'maint'
Conflicts:
	lisp/ox-html.el
2013-05-30 21:51:00 +02:00
Nicolas Goaziou 0f2ba793aa Fix commit 0018428c25
* contrib/lisp/ox-groff.el (org-groff-compile): Use appropriate
  argument.
* lisp/ox-man.el (org-man-compile): Use appropriate argument.
* lisp/ox-texinfo.el (org-texinfo-compile): Use appropriate argument.
2013-05-30 21:48:48 +02:00
Nicolas Goaziou de0fcdf3b8 Merge branch 'maint' 2013-05-30 20:33:24 +02:00
Nicolas Goaziou 0018428c25 export back-ends: Fix subtree export with a relative path
* lisp/ox-latex.el (org-latex-compile): Properly set working
  directory.
* lisp/ox-man.el (org-man-compile): Properly set working directory.
* lisp/ox-texinfo.el (org-texinfo-compile): Properly set working
  directory.
* contrib/lisp/ox-groff.el (org-groff-compile): Properly set working
  directory.
2013-05-30 20:30:14 +02:00
Nicolas Goaziou 9cc1718dc7 Revert "export backends: Fix "PDF file ... wasn't produced" error with relative paths"
This reverts commit 752a4eb49d.
2013-05-30 20:30:08 +02:00
Nicolas Goaziou 6a788618e3 Merge branch 'maint'
Conflicts:
	contrib/lisp/ox-deck.el
2013-05-30 14:33:47 +02:00
Nicolas Goaziou 752a4eb49d export backends: Fix "PDF file ... wasn't produced" error with relative paths
* lisp/ox-latex.el (org-latex-compile): Make sure generated file can
  be found by `file-exists-p'.
* contrib/lisp/ox-groff.el (org-groff-compile): Make sure generated
  file can be found by `file-exists-p'.
* lisp/ox-man.el (org-man-compile): Make sure generated file can be
  found by `file-exists-p'.
* lisp/ox-texinfo.el (org-texinfo-compile): Make sure generated file
  can be found by `file-exists-p'.
2013-05-30 14:28:59 +02:00
Rick Frankel 9d22167c68 Refactor fetching html doctype from alist into function so it can be reused in inherited exporters.
* lisp/ox-html.el (org-html-doctype): Add new function `org-html-doctype'.
(org-html-template): Use `org-html-doctype' function instead of inline
code.

* contrib/lisp/ox-deck.el (org-deck-template): Use `org-html-doctype'
  function instead of inline code.

* contrib/lisp/ox-s5.el (org-s5-template): Use `org-html-doctype'
  function instead of inline code.
2013-05-29 15:23:04 -04:00
Rick Frankel 36812e72ac Fix issues with TOC, internal links and html-doctype.
* contrib/lisp/ox-deck.el (deck): add new deck specific link handler.
(org-deck-toc): Add "sec-" to non-custom link ids.
(org-deck-link): New function. Rename internal link to point at
container instead of heading.
(org-deck-template): Use alist doctype instead of string (per changes
to ox-html).
2013-05-28 07:41:30 -04:00
rasmus.pank 26a9b02483 ox-koma-letter: changed handling of subject.
* ox-koma-letter.el: =`org-koma-letter-subject-format'= can now be a list.  Default is t.
   If nil neither subject format nor type is exported.
* ox-koma-letter.el (org-koma-letter-template): better subject handling.
* ox-koma-letter.el (org-koma-letter-template): allow for t value of =#+OPTIONS: subject:VALUE=
* ox-koma-letter.el (org-koma-letter-template): export of subject format is independent
of title, but title is not independent of =:with-subject=.

The issue was with =#+OPTIONS: subject:t= one would get a LaTeX error.

New behavior:

If =#+OPTIONS: subject:(x,y)= then =\KOMAoption{subject}{x, y}=.

If =subject:x= then =\KOMAoption{subject}{x}=.

If =subject:t= then =\KOMAoption{subject}{...}= is not set but
\setkomavar{subject}{...} is set (in the output file)

If =subject:nil= neither are printed.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-05-27 08:38:44 +02:00
rasmus.pank 7542aabb44 Change default of org-koma-letter-signature to nil.
* ox-koma-letter.el(org-koma-letter-signature): set to nil.

The previoues value corresponds to the default value cf. the the koma
manual pp. 183.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-05-27 08:35:35 +02:00
rasmus.pank 3571a852a0 Added support for after closing and after document entities in ox-koma-letter.
* ox-koma-letter.el (org-koma-letter-special-tags-after-closing):
  specials tags inserted after =\end{closing}=.
* ox-koma-letter.el (org-koma-letter-special-tags): collect
  the special lists.
* ox-koma-letter.el (org-koma-letter-headline): stores content
  in of headline if the first tag is special.  Otherwise return content.
* ox-koma-letter.el (org-koma-letter-special-content): holds special
  content temporarily.
* ox-koma-letter.el (org-koma-letter--format-string-as-macro): format a string as
  a macro or don't.
* ox-koma-letter.el (org-koma-letter-template): added support
  for the headings with special tags.

The following example will now export a sensible manner.

* my letter
  here's a letter
* PS :ps:
  it's requires this patch
* CC :cc:
  Nicolas, Viktor and Alan
* ENCL :encl:
  many patches
  1. this patch
  2. another patch.
* include patches :after_letter:
  \myspecialmacro

  \includepdf{pdf}

Namely, content of ps, encl and cc headings will be exported after
\closing{.}  in the order prescribed by
=`org-koma-letter-special-tags-after-closing'= as a (LaTeX) macro
removing trailing and leading newlines.  The macro is the same as the
tag, althogh the case is determined by the special list.

The concents of the =after_letter= heading will be inserted after
=\end{letter}= and newlines are preserved.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-05-27 08:33:12 +02:00
rasmus.pank ba7a2cc8da Fix handling of author and email in koma exporter.
* ox-koma-letter.el (org-koma-letter-author): defaults to a function
that returns =`user-full-name'=.

Setting the variables `org-koma-letter-author' and
`org-koma-letter-email' to the values of `user-full-name' and
`user-mail-address' respectively, allows the user to skip =#+AUTHOR:=
and =#+EMAIL:= lines when configuring a letter.  However, if the user
wishes to set this information in LCO files, these variables need to
be set to nil.

With the old after-init-hook method my user name was always set to "".
Now org-koma-letter will (i) allow for default nil values (good if you
use LCO files); (ii) default to =`user-full-name'= and
=`user-mail-address'= like =ox-latex.el=.  These values are obtained
on-the-fly.

The two variables in question can also be strings or functions
returning strings.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-05-27 08:29:12 +02:00
Rick Frankel 2347dcf76b Fix handling of internal links and new html doctype option.
* contrib/lisp/ox-deck.el (deck): Add deck specific link function.
(org-deck-toc): Generate correct link to slide for custom ids as well
as default section ids.
(org-deck-link): HTML custom ids link to the headline. deck.js
requires linking to the wrapper (slide) so modify the link to point at
the container instead of the headline.
(org-deck-template): Fix doctype handling to use alist option instead
of literal string.
2013-05-26 19:17:18 -04:00
Rick Frankel 85bd00bae8 Fix TOC link references.
* contrib/lisp/ox-deck.el: TOC link references were being generated as
  "outline-container-{digit}". They need to be
  "outline-container-sec-{digit}".
2013-05-26 18:31:28 -04:00
Nicolas Goaziou 61d8ebd472 ox-taskjuggler: Small fix
* contrib/lisp/ox-taskjuggler.el (org-taskjuggler-assign-task-ids):
  Small fix.
2013-05-24 14:39:06 +02:00
Christian Egli 0de6a339ed ox-taskjuggler.el: Fix byte compiler warnings
* ox-taskjuggler.el (org-taskjuggler-get-project)
(org-taskjuggler-resolve-dependencies): Fix references to free
variables.
2013-05-24 12:14:28 +02:00
Nicolas Goaziou 36848fdec9 ox-bibtex: Port for "org-exp-bibtex.el"
* contrib/lisp/ox-bibtex.el: New file
2013-05-23 21:10:43 +02:00
Eric Schulte 6ebc8c8561 export inline svg images with htmlize 2013-05-21 06:42:14 -06:00
rasmus.pank 832c6fd728 Changed =#+SENDER= to =#+AUTHOR= and removed duplicated email and author variables in =ox-koma-letter.el=.
* ox-koma-letter.el: changed the unorthodox =SENDER= keyword to
  the ordinary =AUTHOR= keyword.
* ox-koma-letter.el: changed email to work as in standard
  latex exporter and dropped dedicated ox-koma-letter variable.

Signed-off-by: Alan Schmitt <alan.schmitt@polytechnique.org>
2013-05-21 13:31:25 +02:00
Max Mikhanosha 0d68eef037 Attempt to M-x org-screenshot-take 'Symbol value as variable is void: return' problem
reported by Brett Viren

* contrib/lisp/org-screenshot.el (org-screenshot-take): Quote the last-input-event
in backquote expansion.
2013-05-17 14:28:11 -04:00
Max Mikhanosha 01db235c4e Remove :tag "Org Startup" tag in definition of org-screenshot
customization group

* contrib/lisp/org-screenshot.el (defgroup) remove :tag

TINYCHANGE
2013-05-17 12:23:37 -04:00
Max Mikhanosha 5cf92f16f7 Merge branch 'master' of orgmode.org:org-mode 2013-05-17 12:13:30 -04:00
Max Mikhanosha 00168dd557 Add new contrib org-screenshot.el 2013-05-17 12:12:16 -04:00