Sebastian Reuße
89ec5e198b
Fix org-table-sort-lines test
...
* test-org-table.el (test-org-table/sort-lines): Fix and improve
testcase.
Sorting and reversing «a C b» should result in «C b a», not in «b a
C». This test did not fail previously only because
org-table-sort-lines had an issue whereby sorts were always
case-sensitive.
2018-03-13 09:09:41 +01:00
Nicolas Goaziou
8ebf4b7274
Change `org-paste-subtree' behavior
...
* lisp/org.el (org-paste-subtree): Never split a section. Instead
always insert tree before the headline after point. Use `org-yank'
to split the section.
* testing/lisp/test-org.el (test-org/paste-subtree): New test.
2018-02-27 00:03:31 +01:00
Nicolas Goaziou
bbcf2f939c
Merge branch 'maint'
2018-02-15 15:04:59 +01:00
Nicolas Goaziou
df80fde9d0
Fix failing tests
...
Use relative symlinks instead of absolute ones.
Reported-by: Nick Dokos <ndokos@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00241.html >
2018-02-15 15:01:45 +01:00
Nicolas Goaziou
58da7d4d17
org-table: Fix shrunk columns on hlines
...
* lisp/org-table.el (org-table--shrunk-field): Fix function when on
a hline.
* testing/lisp/test-org-table.el (test-org-table/shrunk-columns): Add
tests.
Reported-by: Kaushal Modi <kaushal.modi@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00231.html >
2018-02-14 18:48:48 +01:00
Nicolas Goaziou
2a7a4a65ad
Merge branch 'maint'
2018-02-13 14:10:28 +01:00
Nicolas Goaziou
7c21dfc771
ox-publish: Follow symlink directories
...
* lisp/org-compat.el (directory-files-recursively): Remove
compatibility function, no longer needed.
* lisp/ox-publish.el (org-publish--expand-file-name):
(org-publish-org-to):
(org-publish-collect-index):
(org-publish--store-crossrefs):
(org-publish-resolve-external-link): Preserve symlinks in file name.
(org-publish-get-base-files): Follow symlink directories.
(org-publish-get-project-from-filename): Preserve symlinks in file
name. Do not use `file-in-directory-p', which ignores symlinks.
Reported-by: Michel Damiens <michel.damiens@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00186.html >
2018-02-13 14:06:56 +01:00
Nicolas Goaziou
c29efc8f91
Remove non-functional test
...
* testing/lisp/test-org.el (test-org/sort-entries): Remove a test.
2018-02-12 17:56:46 +01:00
Sebastian Reuße
551d2f1fe7
Fix alphabetic sorting for headlines, tags
...
* org.el (org-sort-entries): Use collated sorting.
(org-tags-sort-function): Use collated sorting.
(org-string-collate-greaterp): Add helper-function to use as defcustom
option, since there is no ‘string-collate-greaterp’ in Emacs.
* org-compat.el (org-string-collate-lessp): Add proxy to fall-back on
string-lessp when string-collate-lessp is missing (Emacs ≤ 24).
* test-org.el (test-org/string-collate-lessp): Add test.
(test-org/sort-entries): Add regression test for non-ASCII inputs.
‘org-sort-entries’ and ‘org-tags-sort-function’ advertise alphabetic
sorting, but actually sort based only on character code. This
produces non-alphabetic orderings of strings in non-ASCII locales.
E. g., German Umlauts “Ä Ü Ö” are alphabetically sorted as if they
were “A U O”, whereas sorting based on character-code will place them
after “Z”, which is unexpected.
2018-02-12 14:57:54 +01:00
Kaushal Modi
b505a5b6ad
Merge branch 'maint'
2018-02-11 15:29:57 -05:00
Kaushal Modi
fe7619cd18
Do not auto-fill when point is in Org property drawer
...
* lisp/org.el (org-return): Set auto-fill-function to nil when point
is in an Org property drawer.
* testing/lisp/test-org.el (test-org/return): Add test.
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00102.html >
2018-02-11 15:19:49 -05:00
Nicolas Goaziou
3558e6e835
Merge branch 'maint'
2018-02-05 15:37:15 +01:00
Tim Landscheidt
61a885a399
Make manual and URL links in docstrings clickable
2018-02-05 15:27:12 +01:00
Marco Wahl
8554aa93a7
test-ob: Fix test case
...
* testing/lisp/test-ob.el (test-ob/org-babel-remove-result--results-list):
Removed the inner list. Expectation "- (quote (4 5))" did not match
the result "- '(4 5)". I think this difference is not worth testing
in this test.
2018-02-05 10:45:12 +01:00
Nicolas Goaziou
f500d7c7f6
org-element: Fix example and src block interpreter.
...
* lisp/org-element.el (org-element-example-block-interpreter):
(org-element-src-block-interpreter): Correctly handle indentation.
* testing/lisp/test-org-element.el (test-org-element/example-block-interpreter):
Add tests.
Reported-by: Yasushi SHOJI <yasushi.shoji@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00006.html >
2018-02-04 10:04:17 +01:00
Nicolas Goaziou
85418667a6
Merge branch 'maint'
2018-02-04 00:31:47 +01:00
Nicolas Goaziou
248bc9631b
org-element: Revert regexp change for inline source blocks and babel calls
...
* lisp/org-element.el (org-element-inline-babel-call-parser):
(org-element-inline-src-block-parser): Revert commit
7efa0f2879
.
* testing/lisp/test-ob-exp.el (ob-exp/exports-inline-code):
* testing/lisp/test-org-element.el (test-org-element/inline-src-block-parser):
Update tests.
Reported-by: Greg Minshall <minshall@acm.org>
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00002.html >
2018-02-04 00:30:00 +01:00
Nicolas Goaziou
892ae3c2e1
Merge branch 'maint'
2018-02-04 00:13:36 +01:00
Nicolas Goaziou
19dcbab6f0
ox: Fix select tags and exclude tags and tags hierarchy
...
* lisp/ox.el (org-export--selected-trees): Expand select tags groups.
(org-export--prune-tree): Expand exclude tags groups.
(org-export--skip-p): Change signature.
* testing/lisp/test-ox.el (test-org-export/handle-options): Add tests.
Reported-by: Pierre-Luc Gauthier <p.luc.gauthier@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-02/msg00039.html >
2018-02-04 00:12:45 +01:00
Nicolas Goaziou
485f218510
Merge branch 'maint'
2018-01-30 10:12:32 +01:00
Nicolas Goaziou
7efa0f2879
Fix inline src and inline babel calls parsing
...
* lisp/org-element.el (org-element-inline-babel-call-parser):
(org-element-inline-src-block-parser): Tolerate any prefix before the objects.
* testing/lisp/test-ob-exp.el (ob-exp/exports-inline-code):
* testing/lisp/test-org-element.el (test-org-element/inline-src-block-parser):
Update tests.
Reported-by: Greg Minshall <minshall@acm.org>
<http://lists.gnu.org/r/emacs-orgmode/2018-01/msg00489.html >
2018-01-30 10:11:02 +01:00
Nicolas Goaziou
8730f80c0d
org-element: Fix failing test
...
* testing/lisp/test-org-element.el (test-org-element/interpret-data):
Fix test.
2018-01-28 15:40:15 +01:00
Nicolas Goaziou
33a9eef11f
Allow editing partially shrunk columns
...
* lisp/org-table.el (org-table-with-shrunk-field): New macro.
(org-table-get-field):
(org-table-toggle-column-width): Use new macro.
(org-table--shrunk-field): Update function.
(org-table--shrink-field): When there is a width cookie, leave first
characters editable.
* lisp/org.el (org-self-insert-command):
(org-delete-backward-char):
(org-delete-char): Small refactoring. Handle shrink overlays.
* testing/lisp/test-org-table.el (test-org-table/toggle-column-width):
Update tests.
2018-01-25 23:57:11 +01:00
Nicolas Goaziou
9cf9f56ff6
org-table: Fix `org-table-current-column' on hlines
...
* lisp/org-table.el (org-table-current-column): Return a meaningful
value also on hlines.
(org-table-toggle-column-width): Use `org-table-current-column'
instead of re-inventing wheel.
* testing/lisp/test-org-table.el (test-org-table/current-column): New
test.
2018-01-25 22:55:53 +01:00
Nicolas Goaziou
13424336a6
org-element: Prefer lower case letters for blocks and keywords
...
* lisp/org-element.el (org-element-center-block-interpreter):
(org-element-dynamic-block-interpreter):
(org-element-inlinetask-interpreter):
(org-element-quote-block-interpreter):
(org-element-special-block-interpreter):
(org-element-babel-call-interpreter):
(org-element-comment-block-interpreter):
(org-element-example-block-interpreter):
(org-element-export-block-interpreter):
(org-element-keyword-interpreter):
(org-element-src-block-interpreter):
(org-element-verse-block-interpreter): Use lower case letters when
interpreting object.
* testing/lisp/test-org-element.el (test-org-element/example-block-parser):
(test-org-element/center-block-interpreter):
(test-org-element/dynamic-block-interpreter):
(test-org-element/inlinetask-interpreter):
(test-org-element/quote-block-interpreter):
(test-org-element/comment-block-interpreter):
(test-org-element/example-block-interpreter):
(test-org-element/keyword-interpreter):
(test-org-element/src-block-interpreter):
(test-org-element/verse-block-interpreter):
* testing/lisp/test-ox.el (test-org-export/handle-options):
(test-org-export/expand-macro):
(test-org-export/before-processing-hook): Update tests.
2018-01-24 12:56:25 +01:00
Nicolas Goaziou
2367e25c6b
Merge branch 'maint'
2018-01-22 19:29:32 +01:00
Nicolas Goaziou
4d46a20ea2
ob-lob: Fix Babel calls with external references
...
* lisp/ob-lob.el (org-babel-lob--src-info):
(org-babel-lob-get-info): Handle calls with external references, i.e.,
FILE:NAME(...) syntax.
* testing/lisp/test-ob-lob.el (test-ob-lob/external-reference-syntax):
(test-ob-lob/call-with-indirection): New tests.
2018-01-22 19:27:13 +01:00
Nicolas Goaziou
929b65533a
Merge branch 'maint'
2018-01-19 18:31:48 +01:00
Tim Landscheidt
63c0266688
Update URLs in source code or tests
...
TINYCHANGE
2018-01-19 18:30:40 +01:00
Nicolas Goaziou
0155441358
Merge branch 'maint'
2018-01-19 18:22:00 +01:00
Tim Landscheidt
b289a65be7
Use https for links to orgmode.org
...
TINYCHANGE
2018-01-19 18:14:58 +01:00
Nicolas Goaziou
fd1b3ad972
Fix failing test
...
* testing/lisp/test-org.el (test-org/timestamp-from-time): Do not
hardcode internal time.
Reported-by: Tim Landscheidt <tim@tim-landscheidt.de>
<http://lists.gnu.org/r/emacs-orgmode/2018-01/msg00297.html >
2018-01-17 22:49:05 +01:00
Marco Wahl
1062c63ee1
test-ob-sed: Activate testing ob-sed
2018-01-14 18:34:49 +01:00
Marco Wahl
75be0362da
test-org-tempo: Fix typo which activates the org-tempo tests
2018-01-14 13:59:24 +01:00
Nicolas Goaziou
4dbb4a76a7
Implement `org-show-all'
...
* lisp/org.el (org-show-all): New function.
(org-cycle):
(org-cycle-internal-global):
(org-global-cycle):
(org-set-startup-visibility):
(org-set-outline-overlay-data):
(org-hide-block-all):
(org-mode-hook):
(org-tree-to-indirect-buffer):
(org-sort-entries):
(org-mode-map):
(org-org-menu):
* lisp/ob-lilypond.el (org-babel-lilypond-mark-error-line):
* lisp/org-archive.el (org-archive-subtree):
* lisp/org-capture.el (org-capture-place-template):
* lisp/org-mouse.el (org-mouse-popup-global-menu):
* lisp/ox-org.el (org-org-publish-to-org):
* testing/org-test.el (org-test-at-id):
(org-test-in-example-file): Use new function.
* lisp/org-compat.el (org-show-block-all): Mark as obsolete.
2018-01-10 15:58:21 +01:00
Nicolas Goaziou
728920a8ed
Rename `org-timestamp--to-internal-time' into `org-timestamp-to-time'
...
* lisp/org.el (org-timestamp-to-time): New function.
(org-timestamp--to-internal-time): Remove function.
(org-timestamp-format): Use new function.
* testing/lisp/test-org.el (test-org/timestamp-to-time): New test.
2018-01-10 15:05:11 +01:00
Nicolas Goaziou
d3cdc35e06
Implement `org-timestamp-from-string', `org-timestamp-from-time'
...
* lisp/org.el (org-timestamp-from-string):
(org-timestamp-from-time): New functions.
* testing/lisp/test-org.el (test-org/timestamp-from-string):
(test-org/timestamp-from-time): New tests.
2018-01-10 14:35:32 +01:00
Nicolas Goaziou
46e24f6830
Merge branch 'maint'
2018-01-09 19:51:17 +01:00
Nicolas Goaziou
8c7a14a850
org-clock: Consider hours when splitting the table with :steps
...
* lisp/org-clock.el (org-clocktable-steps): Check time when :tstart
and :tend are defined.
* testing/lisp/test-org-clock.el (test-org-clock/clocktable/step): Add
tests.
Reported-by: savoie@nsidc.org
<http://lists.gnu.org/r/emacs-orgmode/2018-01/msg00227.html >
2018-01-09 19:47:39 +01:00
Nicolas Goaziou
b65fe0f7a2
Merge branch 'maint'
2018-01-07 10:56:02 +01:00
Nicolas Goaziou
0c93296f83
org-table: Obey to `org-table-formula-create-columns'
...
* lisp/org-table.el (org-table-recalculate): Return an error when the
formula cannot create a necessary column.
(org-table-formula-create-columns): Fix docstring.
* testing/lisp/test-org-table.el (test-org-table/field-formula-outside-table):
Fix tests.
2018-01-07 10:55:30 +01:00
Kyle Meyer
d94f7024bc
Merge branch 'maint'
2018-01-07 00:28:35 -05:00
Kyle Meyer
3e1641ef0a
Update copyright years
2018-01-07 00:27:54 -05:00
Nicolas Goaziou
b030475575
Merge branch 'maint'
2018-01-02 14:14:18 +01:00
Nicolas Goaziou
16c7ae7996
Fix handling nested VISIBILITY properties
...
* lisp/org.el (org-set-visibility-according-to-property): Fix handling
nested VISIBILITY properties.
* testing/lisp/test-org.el (test-org/set-visibility-according-to-property):
New test.
Reported-by: Michael Maurer <maurer.michael@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-01/msg00012.html >
2018-01-02 14:13:46 +01:00
Nicolas Goaziou
e9f30779de
Merge branch 'maint'
2017-12-31 15:49:55 +01:00
Nicolas Goaziou
af58a6dbf7
Change Org-mode into Org mode
...
* lisp/ob-core.el (org-babel-result-to-file):
* lisp/ob-picolisp.el:
* lisp/org-agenda.el (org-check-for-org-mode):
(org-search-view):
(org-tags-view):
(org-agenda-cleanup-fancy-diary):
(org-agenda-get-day-entries):
* lisp/org-table.el (orgtbl-mode):
* lisp/org-w3m.el (org-w3m-copy-for-org-mode):
* lisp/org.el (org-modules):
(org-startup-options):
(org-fontify-meta-lines-and-blocks):
* mk/default.mk:
* mk/manfull.pl:
* mk/org-fixup.el (org-make-org-version):
(org-make-org-loaddefs):
* mk/orgcard2txt.pl (rep_esc):
* mk/targets.mk ($(info):
* testing/README:
(Example):
* testing/examples/no-heading.org:
* testing/examples/normal.org: Change Org-mode into Org mode
2017-12-31 15:48:09 +01:00
Nicolas Goaziou
c5208634ba
Fix failing tests.
...
* testing/lisp/test-org-list.el (test-org-list/send-list): Remove
test.
(test-org-list/to-html):
(test-org-list/to-latex):
(test-org-list/to-texinfo): Update tests.
2017-12-31 15:19:56 +01:00
Nicolas Goaziou
2fb65b73b6
test-org-table: Tiny refactoring
...
* testing/lisp/test-org-table.el (test-org-table/org-table-make-reference/mode-string-EL):
(test-org-table/org-table-make-reference/mode-string-E):
(test-org-table/org-table-make-reference/mode-string-EN):
(test-org-table/org-table-make-reference/mode-string-L):
(test-org-table/org-table-make-reference/mode-string-none):
(test-org-table/org-table-make-reference/mode-string-N): Tiny
refactoring.
2017-12-30 00:24:01 +01:00
Marco Wahl
144451143a
Merge branch 'maint'
2017-12-28 19:15:43 +01:00
Marco Wahl
e401afffde
inlinetask: Fix folding of directly consecutive inlinetask children
2017-12-28 19:12:36 +01:00
Marco Wahl
6311c12556
Merge branch 'maint'
2017-12-28 18:05:54 +01:00
Marco Wahl
b29a972307
org-inlinetask:Fix folding of inline tasks within plain list
...
This is the fix proposed by Nicolas. See
http://lists.gnu.org/archive/html/emacs-orgmode/2017-12/msg00564.html
Add and accommodate some tests.
2017-12-28 17:59:52 +01:00
Marco Wahl
269009d297
Merge branch 'maint'
2017-12-28 15:44:34 +01:00
Marco Wahl
ab61357791
testing/README Document use of regexp filter for testing
2017-12-28 15:35:19 +01:00
Nicolas Goaziou
774e553f11
Merge branch 'maint'
2017-12-23 14:03:47 +01:00
Nicolas Goaziou
d9125e435f
Fix recursive Noweb expansion
...
* lisp/ob-core.el (org-babel-expand-noweb-references): Recursive Noweb
expansion obey to :noweb parameter.
* testing/lisp/test-ob.el (test-ob/noweb-expansion): Add tests.
Fixes: 17523
2017-12-23 13:58:25 +01:00
Nicolas Goaziou
913aad68c3
Merge branch 'maint'
2017-12-20 13:16:28 +01:00
Nicolas Goaziou
3acc212c8f
ob-core: Get :noweb-ref from definition instead of point of call
...
* lisp/ob-core.el (org-babel-expand-noweb-references): Get :noweb-ref
from definition instead of point of call.
* testing/lisp/test-ob.el (test-ob/noweb-expansion-1):
(test-ob/noweb-expansion-2): Merge tests. Add test.
2017-12-20 13:15:08 +01:00
Kyle Meyer
06b49cd837
Merge branch 'maint'
2017-12-19 00:00:49 -05:00
Jack Kamm
b506bb68d0
ob-python: Fix :session :results output multiline behavior
...
* lisp/ob-python.el (orb-babel-python-evaluate-session): When :session
:results output, send multiline code blocks to tmpfile and execute in
Python with exec().
(org-babel-python--exec-tmpfile): New variable.
* testing/lisp/test-ob-python.el (test-ob-python/session-multiline):
Test for :session with multiple lines and indentation.
2017-12-18 23:59:04 -05:00
Nicolas Goaziou
fdb2eb6701
Preserve file local variables during some operations
...
* lisp/org-macs.el (org-preserve-local-variables): New macro.
* lisp/org-footnote.el (org-footnote--clear-footnote-section):
(org-footnote--goto-local-insertion-point):
(org-footnote-create-definition):
(org-footnote-delete):
(org-footnote-renumber-fn:N):
(org-footnote-sort):
(org-footnote-normalize):
* lisp/org.el (org-move-subtree-down):
(org-copy-subtree):
(org-sort-entries):
(org-refile): Use new macro.
* testing/lisp/test-org-footnote.el (test-org-footnote/normalize):
(test-org-footnote/delete):
(test-org-footnote/sort):
(test-org-footnote/normalize):
* testing/lisp/test-org.el (test-org/sort-entries): Add tests.
Operations affected include copying, killing, refiling, archiving and
moving subtrees. It also affects sorting, creating and deleting
footnotes.
2017-12-18 16:01:41 +01:00
Nicolas Goaziou
3ac619c8ac
org-macro: Placeholders in (eval ...) macros are always strings
...
* lisp/org-macro.el (org-macro-initialize-templates): Update
templates.
(org-macro-expand): Ensure placeholders in "eval" macros are strings.
* testing/lisp/test-org-macro.el (test-org/macro-replace-all): Update
tests.
2017-12-17 09:40:56 +01:00
Nicolas Goaziou
6ffcdcbf02
Merge branch 'maint'
2017-12-16 13:45:43 +01:00
Nicolas Goaziou
84cb63a44a
ox: Fix plain text export with `org-export-with-backend'
...
* lisp/ox.el (org-export-with-backend): Handle arity for plain text
transcoder.
* testing/lisp/test-ox.el (test-org-export/with-backend): Add test.
2017-12-16 13:44:56 +01:00
Nicolas Goaziou
5d4691dfbf
Merge branch 'maint'
2017-12-15 00:00:55 +01:00
Nicolas Goaziou
327ca051ae
ob-ref: Fix parsing arguments with a newline character
...
* lisp/ob-ref.el (org-babel-ref-split-regexp): Remove variable.
(org-babel-ref-parse): Handle arguments containing a newline
character (e.g., strings).
* testing/lisp/test-ob-lob.el (test-ob-lob/assignment-with-newline):
New test.
2017-12-15 00:00:30 +01:00
Nicolas Goaziou
6fc4a1c53b
Merge branch 'maint'
2017-12-14 22:40:55 +01:00
Nicolas Goaziou
fe98379fce
Fix fuzzy link escaping
...
* lisp/org.el (org-make-link-string): Properly escape square brackets
and percent sings in fuzzy links.
* testing/lisp/test-org-clock.el (test-org-clock/clocktable/link):
Update tests.
Reported-by: Paulo Matos <paulo@matos-sorge.com>
<http://lists.gnu.org/r/emacs-orgmode/2017-12/msg00269.html >
2017-12-14 22:39:54 +01:00
Nicolas Goaziou
f8849e92e5
org-archive: Add a test
...
* testing/lisp/test-org-archive.el (test-org-archive/to-archive-sibling):
New test.
2017-12-11 23:22:21 +01:00
Nicolas Goaziou
c3c1c52eb8
ox: Fix inline source block evaluation
...
* lisp/ox.el (org-export-as): Specifically expand {{{results}}} macro
after Babel code execution.
* testing/lisp/test-ox.el (test-org-export/expand-macro): Add test.
Reported-by: "Berry, Charles" <ccberry@ucsd.edu>
<http://lists.gnu.org/r/emacs-orgmode/2017-12/msg00202.html >
2017-12-11 14:56:57 +01:00
Nicolas Goaziou
fc5abc2d55
ob-core: Insert lowercase results
...
* lisp/ob-core.el (org-babel-insert-result): Insert lower case blocks
and drawers.
* testing/lisp/test-ob.el (test-ob/org-babel-remove-result--results-wrap):
(test-ob/org-babel-remove-result--results-org):
(test-ob/org-babel-remove-result--results-html):
(test-ob/org-babel-remove-result--results-latex):
(test-ob/org-babel-remove-result--results-code): Update tests.
2017-12-10 23:05:32 +01:00
Rasmus
94f1a58438
org-tempo.el: New file for expansion of templates
...
* lisp/org-tempo.el: New file.
* doc/org.texi (Structure templates):
* lisp/org.el (org-modules): Add org-tempo.
* testing/lisp/test-org-tempo.el: New file.
2017-12-08 00:29:08 +01:00
Nicolas Goaziou
259656a76e
Merge branch 'maint'
2017-12-03 09:03:37 +01:00
Nicolas Goaziou
2faaacfeeb
Revert the whole time zone mess
...
* lisp/org.el (org-time-string-to-time):
(org-time-string-to-seconds): Remove optional ZONE argument.
(org-2ft):
(org-check-before-date):
(org-check-after-date):
(org-check-dates-range):
(org-parse-time-string):
* lisp/org-clock.el (org-clock-get-sum-start):
(org-clock-out):
(org-clock-timestamps-change):
(org-clock-sum):
(org-clock-update-time-maybe):
* lisp/org-colview.el (org-columns--age-to-minutes): Apply change.
* testing/lisp/test-org-clock.el (org-test-clock-create-clock):
(test-org-clock/clocktable/scope):
* testing/lisp/test-org-colview.el (test-org-colview/columns-summary):
Apply change. Simplify tests to avoid daylight saving time issue.
2017-12-03 08:57:37 +01:00
Nicolas Goaziou
bdaf5dacf4
Merge branch 'maint'
2017-12-02 17:27:53 +01:00
Nicolas Goaziou
ca43c1f262
Fix RET past the last column of a table
...
* lisp/org.el (org-return): Split the table before first column or
after last one.
* lisp/org-table.el (org-table-next-row): Remove code handling split.
* testing/lisp/test-org.el (test-org/return): Add test.
2017-12-02 17:23:03 +01:00
Nicolas Goaziou
0ace32b045
Merge branch 'maint'
2017-12-02 12:23:02 +01:00
Nicolas Goaziou
f53d1e2005
Let `or-export-last-sibling-p' handle discontinuous headlines
...
* lisp/ox.el (org-export-last-sibling-p): Handle discontinuous
headlines.
* testing/lisp/test-ox.el (test-org-export/last-sibling-p): Add test.
Fixes: 24836
2017-12-02 12:22:32 +01:00
Alex Branham
ee7ead62aa
Make `org-comment-dwim' check if on a heading
...
* lisp/org.el (org-comment-dwim): If on a heading, comment the
heading.
* testing/lisp/test-org.el: Add test.
TINYCHANGE
2017-11-29 14:41:12 +01:00
Nicolas Goaziou
acfb1ca4b8
Merge branch 'maint'
2017-11-29 14:37:33 +01:00
Nicolas Goaziou
12ea0f08f4
Fix some tests
...
* testing/lisp/test-org.el (test-org/comment-dwim): Fix tests
2017-11-29 14:37:12 +01:00
Nicolas Goaziou
b0ab7008df
Merge branch 'maint'
2017-11-26 10:47:55 +01:00
Nicolas Goaziou
6aac798f25
Fix publishing links to absolute file names belonging to project
...
* lisp/ox-publish.el (org-publish-file-relative-name): New function.
* lisp/ox-html.el (org-html-link): Use new function.
* testing/lisp/test-ox-publish.el (test-org-publish/file-relative-name):
New test.
2017-11-26 10:46:53 +01:00
Nicolas Goaziou
be1e807942
Merge branch 'maint'
2017-11-25 21:13:58 +01:00
Nicolas Goaziou
1d8126385c
ob-core: Fix results removal without blank line between source and results
...
* lisp/ob-core.el (org-babel-remove-result): Delete blank lines before
results.
(org-babel-result-end): Use `org-element-at-point'.
* testing/lisp/test-ob.el (test-ob-verify-result-and-removed-result):
Remove duplicate.
* testing/lisp/test-ob.el (test-ob/org-babel-remove-result--no-blank-line):
New test.
* testing/lisp/test-ob.el (test-ob/results-in-narrowed-buffer): Small
refactoring.
Reported-by: Ken Mankoff <mankoff@gmail.com>
<http://lists.gnu.org/archive/html/emacs-orgmode/2017-11/msg00338.html >
2017-11-25 21:07:52 +01:00
Nicolas Goaziou
51234f9555
org-macro: Implement "keyword" macro
...
* lisp/org-macro.el (org-macro-initialize-templates): Implement
"keyword" macro.
* doc/org.texi (Macro replacement): Document new macro.
* testing/lisp/test-org-macro.el (test-org-macro/keyword): New test.
2017-11-21 23:38:24 +01:00
Nicolas Goaziou
7455f4bf83
ox: Allow a less strict UNNUMBERED inheritance
...
* lisp/ox.el (org-export-collect-headlines):
(org-export-excluded-from-toc-p): Allow to number headlines in the
middle of an otherwise unnumbered tree.
* testing/lisp/test-ox.el (test-org-export/collect-headlines):
(test-org-export/excluded-from-toc-p):
(test-org-export/toc-entry-backend): Update tests. Add more tests.
Reported-by: Akater <nuclearspace@gmail.com>
<http://lists.gnu.org/archive/html/emacs-orgmode/2017-11/msg00219.html >
2017-11-20 14:07:03 +01:00
Nicolas Goaziou
f482cfa785
Merge branch 'maint'
2017-11-20 00:14:05 +01:00
Nicolas Goaziou
82812ff086
ox: Fix UNNUMBERED strict inheritance
...
* lisp/ox.el (org-export-numbered-headline-p): Use a less opinionated
definition of inheritance.
* testing/lisp/test-ox.el (test-org-export/numbered-headline-p):
Update test.
* doc/org.texi (Export settings): Insist on UNNUMBERED inheritance.
It is now possible to number a headline within an unnumbered tree.
2017-11-20 00:09:59 +01:00
Nicolas Goaziou
b8d473a04f
org-table: Insert new column to the right instead of the left
...
* lisp/org-table.el (org-table-insert-column): Insert new column to
the right instead of the left.
* testing/lisp/test-org-table.el (test-org-table/insert-column): New
test.
2017-11-19 23:22:16 +01:00
Nicolas Goaziou
966af419f9
Merge branch 'maint'
2017-11-15 18:14:44 +01:00
Nicolas Goaziou
40f73953f6
Fix `org-string-display'
...
* lisp/org-macs.el (org-string-display): Preserve original string's
display property when computing displayed width.
* testing/lisp/test-org-macs.el (test-org/string-display): Add test.
Reported-by: Ruy Exel <ruyexel@gmail.com>
<http://lists.gnu.org/archive/html/emacs-orgmode/2017-11/msg00160.html >
2017-11-15 18:13:34 +01:00
Nicolas Goaziou
8ff3673dfc
Merge branch 'maint'
2017-11-15 17:41:48 +01:00
Nicolas Goaziou
6059c3a057
org-table: Clean left-over `:org-untouchable' property
...
* lisp/org-table.el (org-table-recalculate): Clean `:org-untouchable'
property once we no longer need it.
* testing/lisp/test-org-table.el (test-org-table/formula-priority):
New test.
Reported-by: Ruy Exel <ruyexel@gmail.com>
<http://lists.gnu.org/archive/html/emacs-orgmode/2017-11/msg00159.html >
2017-11-15 17:40:22 +01:00
Marco Wahl
5c382f2ee2
org-attach,test-org-attach: Refactoring.
...
* lisp/org-attach.el (org-attach-dired-to-subtree): Renamed from
`org-attach-dired-attach-to-next-best-subtree'. Convenience
functions have been dropped.
* testing/lisp/test-org-attach.el: Tests use
`org-test-with-temp-text-in-file' now and are cleaner now.
2017-11-15 14:39:26 +01:00
Marco Wahl
615b147031
org-attach: Attach files specified in a dired buffer.
...
* lisp/org-attach.el (org-attach-attach-files): New.
(org-attach-dired-marked-files-in-dired): New
(org-attach-dired-marked-files-or-file-at-cursor-in-dired): New.
(org-attach-dired-attach-to-next-best-subtree): New command.
(org-attach-dired-attach-to-next-best-subtree-cp): New command.
(org-attach-dired-attach-to-next-best-subtree-mv): New command.
(org-attach-dired-attach-to-next-best-subtree-ln): New command.
(org-attach-dired-attach-to-next-best-subtree-lns): New command.
* testing/lisp/test-org-attach.el: Tests.
2017-11-15 11:25:51 +01:00
Nicolas Goaziou
d07ee7f7f2
Implement :pre-blank property for items and footnotes definitions
...
* lisp/org-element.el (org-element-footnote-definition-parser):
(org-element-item-parser): Add `:pre-blank' property.
(org-element-footnote-definition-interpreter):
(org-element-item-interpreter):
(org-element-interpret-data):
* lisp/ox.el (org-export-data): Use new property.
* testing/lisp/test-org-element.el (test-org-element/footnote-definition-parser):
(test-org-element/item-parser): Add tests.
2017-11-10 00:38:31 +01:00
Eric Abrahamsen
c04e357f3d
Replace easy templates with org-insert-structure-template
...
* lisp/org.el (org-insert-structure-template): New function for
wrapping region (or element at point) in a begin/end block.
(org-structure-predefined-blocks): New option holding predefined
blocks, for completion.
(org-try-structure-completion,
org-complete-expand-structure-template): Remove functions.
* doc/org.texi (Inserting structure templates): Document.
* testing/lisp/test-org.el (test-org/insert-template): New test.
2017-11-05 09:56:26 +01:00
Nicolas Goaziou
7ba058963e
Merge branch 'maint'
2017-11-04 21:51:40 +01:00