Commit Graph

210 Commits

Author SHA1 Message Date
Nicolas Goaziou 8112629d37 ox-texinfo: Fix code typo
* lisp/ox-texinfo.el (org-texinfo--menu-entries): Only collect direct
  children.

The regression was introduced in
1b415735ea.
2017-07-25 19:24:47 +02:00
Nicolas Goaziou 379a22c9c6 Revert "ox-texinfo: Move menu handling from sections to headlines"
This reverts commit 988e8802a6.
2017-06-28 22:51:26 +02:00
Nicolas Goaziou 1b415735ea ox-texinfo: Small menu refactoring
* lisp/ox-texinfo.el (org-texinfo--menu-entries): Use
  `org-export-collect-headlines'.
2017-06-22 19:01:28 +02:00
Nicolas Goaziou 988e8802a6 ox-texinfo: Move menu handling from sections to headlines
* lisp/ox-texinfo.el (org-texinfo-headline): Move menu handling from
  sections to headlines.
2017-06-22 19:01:23 +02:00
Nicolas Goaziou 20795aae27 ox-texinfo: Change Texinfo class definition
* lisp/ox-texinfo.el (org-texinfo-classes): Change default value and
  structure.
(org-texinfo--structuring-command): New function.
(org-texinfo-headline): Use new function.

The new structure handles properly appendices at sub-levels.
2017-06-22 18:46:44 +02:00
Nicolas Goaziou 03d43ee6c6 Merge branch 'maint' 2017-06-20 09:30:25 +02:00
Nicolas Goaziou 5d6325ffa3 ox-texinfo: Remove spurious "@insertcopying"
* lisp/ox-texinfo.el (org-texinfo-template): Remove "@insertcopying"
  command outside title page.

See (info "(texinfo) Copyright") for details.
2017-06-20 09:28:40 +02:00
Nicolas Goaziou 5e439d41f8 Merge branch 'maint' 2017-06-20 09:25:05 +02:00
Nicolas Goaziou fa6b7bf25c ox-texinfo: Fix location of text before first headline
* doc/org.texi (Info directory file): Fix node name.
(Headings and sectioning structure): Document location of text before
  first headline.
(A Texinfo example): Update example.

* lisp/ox-texinfo.el (org-texinfo-template): Handle contents of very
  first section.
(org-texinfo-section): Ignore very first section.

According to Texinfo specifications, Top node contents should not
appear in printed output.  Move it near "@top" command, within
"@ifnottex".
2017-06-20 09:24:34 +02:00
Nicolas Goaziou 1a6bf9c5f9 Merge branch 'maint' 2017-06-18 11:03:43 +02:00
Nicolas Goaziou 8769cfc91c Revert "ox-texinfo: Escape @ { } in index"
* lisp/ox-texinfo.el (org-texinfo-keyword): Index keywords are
  specific to Texinfo back-end, so they expect regular Texinfo code.
* doc/org.texi (Indices): Update documentation.
2017-06-18 11:00:56 +02:00
Nicolas Goaziou 4295d1b949 Merge branch 'maint' 2017-06-17 12:07:09 +02:00
Nicolas Goaziou 39351d0d14 ox-texinfo: Add missing entities
* lisp/ox-texinfo.el (org-texinfo-entity): Add "@textdegree{}" and
  "@registeredsymbol".
2017-06-17 12:04:36 +02:00
Nicolas Goaziou ad0312cde2 Merge branch 'maint' 2017-06-14 23:07:44 +02:00
Nicolas Goaziou 17382722db ox-texinfo: Fix last commit
* lisp/ox-texinfo.el (org-texinfo-keyword): Fix last commit.

Do not escape raw #+TEXINFO value.
2017-06-14 23:07:04 +02:00
Nicolas Goaziou e5396c189a Merge branch 'maint' 2017-06-14 21:27:37 +02:00
Nicolas Goaziou a621289953 ox-texinfo: Escape @ { } in index
* lisp/ox-texinfo.el (org-texinfo-keyword): Escape @ { } in index.
2017-06-14 21:27:02 +02:00
Nicolas Goaziou be30c8b126 ox-texinfo: Change default table markup
* lisp/ox-texinfo.el (org-texinfo-table-default-markup): Rename from
  `org-texinfo-def-table-markup'.  Set default value to the neutral
  "@asis".
(org-texinfo-plain-list): Use new name.
* lisp/org-compat.el (org-texinfo-def-table-markup): Mark as obsolete.
* doc/org.texi (Publishing options): Document change.
2017-06-14 19:11:33 +02:00
Nicolas Goaziou 5e35bc1807 Merge branch 'maint' 2017-06-11 11:39:37 +02:00
Nicolas Goaziou 62dc27dc75 ox-texinfo: Fix spurious "nil" in "special block export
* lisp/ox-texinfo.el (org-texinfo-special-block): Remove spurious
  "nil" when no option is defined.
2017-06-11 11:38:45 +02:00
Nicolas Goaziou cf505d2ebb ox-texinfo: Export example blocks as @example
* lisp/ox-texinfo.el (org-texinfo-example-block): Export as @example.

Escape @, {, }, however, so as to get proper verbatim contents.
2017-06-09 22:03:08 +02:00
Nicolas Goaziou c24c07c810 Merge branch 'maint' 2017-06-08 23:28:03 +02:00
Nicolas Goaziou 9fdc77a3cd ox-texinfo: Improve entities handling
* lisp/ox-texinfo.el (org-texinfo-entity): Use Texinfo specific
  commands whenever possible.
2017-06-08 23:26:26 +02:00
Nicolas Goaziou feb34a1fbf Merge branch 'maint' 2017-06-08 21:17:09 +02:00
Nicolas Goaziou a138fedfd2 ox-texinfo: Use UTF-8 instead of LaTeX for entities
* lisp/ox-texinfo.el (org-texinfo-entity): Use UTF-8 instead of LaTeX
  for entities.
2017-06-08 21:16:43 +02:00
Nicolas Goaziou ddc80b628a Merge branch 'maint' 2017-06-08 15:16:20 +02:00
Nicolas Goaziou f03387ef90 ox-texinfo: Fix special characters in plain text
* lisp/ox-texinfo.el (org-texinfo-plain-text): Add missing
  discretionary hyphenation point.  Tiny refactoring.
2017-06-08 15:14:48 +02:00
Nicolas Goaziou c5bb67ef60 ox-texinfo: Do not consider :sep value as a regexp
* lisp/ox-texinfo.el (org-texinfo-item): Do not consider :sep value as
  a regexp.
2017-06-08 09:04:31 +02:00
Nicolas Goaziou a2c13a31bb Merge branch 'maint' 2017-06-07 22:39:03 +02:00
Nicolas Goaziou 1c71172c54 ox-texinfo: Tolerate indicating commands without @-sign
* lisp/ox-texinfo.el (org-texinfo-def-table-markup): Improve
  docstring.
(org-texinfo-plain-list): Tolerate indicating commands without @-sign.
2017-06-07 22:38:02 +02:00
Nicolas Goaziou 8dc31ed680 ox-texinfo: Implement the :sep attribute in plain lists
* lisp/ox-texinfo.el (org-texinfo-item):
* doc/org.texi (Plain lists in Texinfo export):
2017-06-07 22:17:08 +02:00
Nicolas Goaziou 16f735f1cb Merge branch 'maint' 2017-06-07 12:23:56 +02:00
Nicolas Goaziou 8305c9381e ox-texinfo: Remove spurious blank line in fixed width areas
* lisp/ox-texinfo.el (org-texinfo-fixed-width): Remove spurious blank
  line.
2017-06-07 12:23:20 +02:00
Nicolas Goaziou 0ff8ba5907 ox-texinfo: Use @code instead of @verb for inline src blocks
* lisp/ox-texinfo.el (org-texinfo-inline-src-block): Use @code.
2017-06-07 00:16:35 +02:00
Nicolas Goaziou fdac3c0140 ox-texinfo: By default, use @samp instead of @verb for =...=
* lisp/ox-texinfo.el (org-texinfo-text-markup-alist): Change default
  value.
(org-texinfo--text-markup): Handle protected @samp{...} command.

@samp{} is more versatile than @verb{} as it can belong to more
commands.  So, it makes more sense as a default value.
2017-06-07 00:00:31 +02:00
Nicolas Goaziou f0f8ca730e Merge branch 'maint' 2017-06-06 23:51:57 +02:00
Nicolas Goaziou b13e672977 ox-texinfo: More fixes to cross-referencing
* lisp/ox-texinfo.el (org-texinfo--sanitize-title): New function.
(org-texinfo--get-node): Use new function.  Tiny improvement over
aesthetics of duplicate node names.
(org-texinfo--sanitize-node): Fix docstring.
(org-texinfo-headline): Use new function
(org-texinfo--@ref): Remove colons and protect commas in description.
(org-texinfo-link): Use new function.  Better handling of targets
within headings.
(org-texinfo--format-entries): Use new function.  Remove colons from
menu entries.
2017-06-06 23:48:33 +02:00
Nicolas Goaziou 53011308a5 Merge branch 'maint' 2017-06-06 02:20:51 +02:00
Nicolas Goaziou 93bc1b7c7e ox-texinfo: Improve algorithm to make node names unique
* lisp/ox-texinfo.el (org-texinfo--get-node): Use numbers to
  differentiate between common base node names instead of "x".
2017-06-06 02:18:40 +02:00
Nicolas Goaziou d44cadbe3e ox-texinfo: Fix conflicts between @node and @anchor names
* lisp/ox-texinfo.el (org-texinfo--get-node): Prevent using reserved
  "Top" node.
(org-texinfo-radio-target):
(org-texinfo-src-block):
(org-texinfo-table):
(org-texinfo-target): Use `org-texinfo--get-node' instead of
`org-export-get-reference'.
2017-06-06 02:18:40 +02:00
Nicolas Goaziou c822329faf ox-texinfo: Additional fix to @ref commands
* lisp/ox-texinfo.el (org-texinfo--@ref): New function.
(org-texinfo-link): Use new function.

When node name doesn't correspond to actual title, use the third @ref
argument to ensure the node name is not printed nor displayed.
2017-06-06 02:18:40 +02:00
Nicolas Goaziou bffe447778 Merge branch 'maint' 2017-06-06 00:23:13 +02:00
Nicolas Goaziou 6f12dfbcb0 ox-texinfo: Fix @ref{...} handling
* lisp/ox-texinfo.el (org-texinfo-link): Fix @ref{...} handling.  Use
  third argument as description.  Without description, use
  one-argument @ref.
2017-06-06 00:21:53 +02:00
Kyle Meyer 7278899697 Merge branch 'maint' 2017-01-26 00:05:29 -05:00
Kyle Meyer 7c710f6f57 Change :version in defcustoms from "25.2" to "26.1"
* lisp/ob-J.el (org-babel-J-command):
* lisp/ob-core.el (org-babel-hash-show-time):
* lisp/ob-exp.el (org-babel-exp-inline-code-template):
* lisp/ob-lisp.el (org-babel-lisp-eval-fn):
* lisp/org-agenda.el (org-agenda-view-columns-initially):
* lisp/org-attach.el (org-attach-commit):
(org-attach-archive-delete):
(org-attach-annex-auto-get):
* lisp/org-bibtex.el (org-bibtex-inherit-tags):
* lisp/org-clock.el (org-clock-into-drawer):
* lisp/org-colview.el (org-columns-summary-types):
* lisp/org-faces.el (org-block):
* lisp/org-src.el (org-src-block-faces):
* lisp/org-table.el (org-table-copy-increment):
(org-table-formula-create-columns):
(org-table-convert-region-max-lines):
* lisp/org-timer.el (org-timer-default-timer):
* lisp/org.el (org-export-backends):
(org-show-context-detail):
(org-cycle-hook):
(org-occur-case-fold-search):
(org-preview-latex-default-process):
(org-preview-latex-process-alist):
(org-preview-latex-image-directory):
(org-latex-default-packages-alist):
(org-sparse-tree-default-date-type):
(org-structure-template-alist):
(org-effort-durations):
(org-agenda-ignore-properties): Change :version from "25.2" to "26.1".
(customize-package-emacs-version-alist): Fix associations between Org
and Emacs releases.
* lisp/ox-ascii.el (org-ascii-list-margin):
* lisp/ox-beamer.el (org-beamer-subtitle-format):
* lisp/ox-html.el (org-html-format-headline-function):
(org-html-format-inlinetask-function):
(org-html-viewport):
* lisp/ox-latex.el (org-latex-caption-above):
(org-latex-prefer-user-labels):
(org-latex-subtitle-format):
(org-latex-hyperref-template):
(org-latex-footnote-defined-format):
(org-latex-images-centered):
(org-latex-default-figure-position):
(org-latex-text-markup-alist):
(org-latex-format-inlinetask-function):
(org-latex-custom-lang-environments):
(org-latex-compiler-file-string):
(org-latex-compiler):
(org-latex-bib-compiler):
(org-latex-logfiles-extensions):
(org-latex-known-warnings):
* lisp/ox-md.el (org-md-footnotes-section):
(org-md-footnote-format):
* lisp/ox-odt.el (org-odt-format-headline-function):
(org-odt-format-inlinetask-function):
(org-odt-inline-image-rules):
* lisp/ox-texinfo.el (org-texinfo-format-headline-function):
* lisp/ox.el (org-export-with-creator):
(org-export-with-title):
(org-export-with-broken-links):
(org-export-copy-to-kill-ring): Change :version from "25.2" to "26.1".

It looks like the goal is to sync Org 9.0.* (maint) with the Emacs
master branch (what will be version 26.1):
https://lists.gnu.org/archive/html/emacs-orgmode/2017-01/msg00558.html
2017-01-26 00:02:03 -05:00
Nicolas Goaziou 7289293e4e ox-texinfo: Delegate "info" links handling to "org-info.el"
* lisp/org-info.el (org-info-export): Handle links when exporting to
  "texinfo" back-end.
* lisp/ox-texinfo.el (org-texinfo-link): Delegate "info" links
  handling to the function above.
2017-01-21 14:19:29 +01:00
Kyle Meyer 713f785017 Update copyright years 2017-01-05 20:19:37 -05:00
Nicolas Goaziou 289363d510 Fix LaTeX preview
* lisp/org.el (org-compile-file): Introduce new %O placeholder.
(org-preview-latex-process-alist): Use it.

* lisp/ox-latex.el (org-latex-pdf-process):
* lisp/ox-man.el (org-man-pdf-process):
* lisp/ox-texinfo.el (org-texinfo-info-process): Document it.

Reported-by: Scott Otterson <scotto@sharpleaf.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/110464>
2016-11-27 12:07:11 +01:00
Nicolas Goaziou d907041911 Change :version in defcustoms from "25.1" to "25.2"
* lisp/ob-exp.el (org-babel-exp-inline-code-template):
* lisp/ob-lisp.el (org-babel-lisp-eval-fn):
* lisp/org-agenda.el (org-agenda-view-columns-initially):
* lisp/org-attach.el (org-attach-commit):
(org-attach-archive-delete):
(org-attach-annex-auto-get):
* lisp/org-bibtex.el (org-bibtex-inherit-tags):
* lisp/org-clock.el (org-clock-into-drawer):
* lisp/org-colview.el (org-columns-summary-types):
* lisp/org-table.el (org-table-copy-increment):
(org-table-formula-create-columns):
(org-table-convert-region-max-lines):
* lisp/org-timer.el (org-timer-default-timer):
* lisp/org.el (org-export-backends):
(org-cycle-hook):
(org-occur-case-fold-search):
(org-preview-latex-image-directory):
(org-latex-default-packages-alist):
(org-sparse-tree-default-date-type):
(org-structure-template-alist):
(org-effort-durations):
(org-agenda-ignore-properties): Change :version from "25.1" to "25.2".
(customize-package-emacs-version-alist): Fix associations between Org
and Emacs releases.
* lisp/ox-ascii.el (org-ascii-list-margin):
* lisp/ox-beamer.el (org-beamer-subtitle-format):
* lisp/ox-html.el (org-html-format-headline-function):
(org-html-format-inlinetask-function):
(org-html-viewport):
* lisp/ox-latex.el (org-latex-caption-above):
(org-latex-prefer-user-labels):
(org-latex-subtitle-format):
(org-latex-hyperref-template):
(org-latex-images-centered):
(org-latex-text-markup-alist):
(org-latex-format-inlinetask-function):
(org-latex-custom-lang-environments):
(org-latex-compiler-file-string):
(org-latex-compiler):
(org-latex-bib-compiler):
(org-latex-logfiles-extensions):
(org-latex-known-warnings):
* lisp/ox-md.el (org-md-footnotes-section):
(org-md-footnote-format):
* lisp/ox-odt.el (org-odt-format-headline-function):
(org-odt-format-inlinetask-function):
(org-odt-inline-image-rules):
* lisp/ox-texinfo.el (org-texinfo-format-headline-function):
* lisp/ox.el (org-export-with-creator):
(org-export-with-title):
(org-export-with-broken-links):
(org-export-copy-to-kill-ring): Change :version from "25.1" to "25.2".

Neither Org 8.3 nor Org 9.0 were released with Emacs 25.1.
2016-10-05 11:18:39 +02:00
Aaron Ecay 6b52bc6a21 Clean up string handling.
* lisp/org-compat.el (string-prefix-p, string-suffix-p):
Add compatibility definitions for 24.3.

* lisp/ob-R.el (org-babel-edit-prep:R):
* lisp/ob-core.el (org-babel-demarcate-block):
* lisp/ob-js.el (org-babel-js-read):
* lisp/ob-latex.el (org-babel-execute:latex):
* lisp/ob-ref.el (org-babel-ref-parse):
* lisp/ob-shell.el (org-babel-variable-assignments:shell):
* lisp/org-protocol.el (org-protocol-create):
* lisp/org-table.el (org-table-field-info):
* lisp/org.el (org-get-buffer-for-internal-link):
* lisp/ox-publish.el (org-publish-compare-directory-files):
* lisp/ox-texinfo.el (org-texinfo-template):
Use `string-{suffix,prefix}-p' instead of `string-match(-p)'.

* lisp/ob-python.el (org-babel-python-read-string):
Ditto, also use `substring' rather than `match-string'.

* lisp/org-table.el (org-table-copy-down):
(org-table-insert-hline, org-table-current-field-formula):
(org-table-get-formula): Use `string-match-p' instead of
`string-match'.
2016-08-24 16:05:54 +01:00