* lisp/org.el (org-insert-heading): Fix bug when inserting a
heading before the first headline.
Reported-by: Gustavo Barros <gusbrs.2016@gmail.com>
Link: https://orgmode.org/list/875z73br32.fsf@gmail.com/
* lisp/org.el (org-read-date-analyze): Add support for HHhMM time
input, in similar way as for am/pm times.
* doc/org-manual.org (The date/time prompt): Add example to illustrate
the feature.
TINYCHANGE
* etc/ORG-NEWS: New entry announcing clocktable calculation and
display of per-file time percentages, when ':formula %' is used.
TINYCHANGE
Signed-off-by: Alan D. Salewski <ads@salewski.email>
* lisp/ob-core.el (org-babel-result-end): Alloow the result to end
into a LaTeX environment.
By adding latex-enviroment to the possible results types, a much
richer experience is possible for backends that can produce
LaTeX-formatted maths as their results (for example: Calc, Julia with
Latexify, Python with SymPy, Octave with symbolic). This is superior
to a LaTeX export block as LaTeX environments can be (1) rendered
inline, and (2) better used in non-LaTeX export formats (e.g. HTML
with MathJax). Without this, backends can output a LaTeX environment,
but new results will be added in front instead of replacing the
environment.
* lisp/org-src.el (org-src--coordinates)
(org-src--goto-coordinates): Use point instead of column.
Using a column-based approach fails to account for invisible regions
or display overlays that change the number of columns: for example,
showing a LaTeX \alpha as α. In src edits which involve such
structures, this causes the point to be shifted undesirably. By using
a point-based approach this issue does not occur.
* lisp/org-clock.el (org-clocktable-write-default): When ':formula %'
is in-effect, show the per-file time percentage in the '%' column.
TINYCHANGE
This change only has an effect when multiple files are contributing to
a given clocktable (such as when ':scope agenda' has been specified).
The existing behavior is that such tables have an extra 'File' column,
and each individual file that contributes has its own summary line
with the headline value '*File time*'. Those summary rows also
produce a rollup time value for the file in the 'Time' column.
Prior to this change, the built-in '%' formula does not produce a
calculation for those per-file times in the '%' column (the relevant
cells in the '%' column were blank). With this change, the percentage
contribution of each individual file time to the total time is shown.
The more agenda files you have, the more useful this behavior becomes.
Signed-off-by: Alan D. Salewski <ads@salewski.email>
* lisp/ob-plantuml.el (org-babel-plantuml-svg-text-to-path): New option.
(org-babel-execute:plantuml): Use the new option to add a SVG-specific
post-export step that runs inkscape text-to-path replacement over
the output file.
TINYCHANGE
* lisp/org.el (org-ctrl-c-ctrl-c): Fix bug.
Commit aea31b065 introduced a bug: C-c C-c on a row of a table that
has no #+plot line, (org-element-property :post-affiliated context)
would return nil, so we first need to check whether we are on a #+plot
line.
* lisp/org-agenda.el (org-agenda-filter)
(org-agenda-get-represented-tags)
(org-agenda-filter-make-matcher-tag-exp): Make tags filtering
case-sensitive.
This fixes a bug introduced in commit 13a1a4fb9.
* lisp/ox-html.el (org-html-standalone-image-p): Remove quote which
causes `org-html-standalone-image-p' to not check if
`org-html-standalone-image-predicate' is fbound and see if it's
initialized.
TINYCHANGE
* lisp/org.el (org-display-inline-images): Guard image-map use with
boundp check rather than version check.
Guarding with a boundp will pacify the byte-compiler and is a direct
check that the thing we care about is available, so there's no need to
rely on the version check.
Reported-by: Ihor Radchenko <yantar92@gmail.com>
Link: https://orgmode.org/list/87y2d2mqik.fsf@localhost
* lisp/org.el (org-open-file): Select a pipe connection type with
process-connection-type rather than make-process, which isn't
available until Emacs 25.
This uses the alternative approach suggested by Eli Zaretskii in the
thread that led to 5db61eb0f (org.el: Avoid xdg-open silent failure,
2021-03-21): https://orgmode.org/list/83y2g96ta6.fsf@gnu.org
Reported-by: Ihor Radchenko <yantar92@gmail.com>
Link: https://orgmode.org/list/87y2d2mqik.fsf@localhost
* ob-eval.el (org-babel-eval): Improve documentation and rename local
variables to be consistent with `org-babel--shell-command-on-region'
* (org-babel--shell-command-on-region): Remove START and END as
parameters.
* (org-babel--shell-command-on-region): Refactored out parts of
function to `org-babel--write-temp-buffer-input-file' and `org-babel--get-shell-file-name'.
This removes two parameters from
`org-babel--shell-command-on-region'. It appears that START and END
were parameters only because shell-command-on-region has them. This
function is only called by org-babel-eval so it looks safe to remove
those parameters, since they are always (point-min) and (point-max)
and are never changed. Given the way the function works and that it
is, it is unlikely that any user code relies on it.
* ob-C.el (org-babel-C-expand-C, org-babel-C-header-to-C,
org-babel-C-expand-D): Add a `TYPE' parameter to
`org-babel-C-header-to-C' so that the helper functions return the
correct type. Previoulsy for tables of non-strings the helper
functions would attempt to return a string, leading to compilation
errors.
* ob-C.el (org-babel-C-header-to-C): Correctly quote header elements.
Before, if the elisp value was not a string, it would not quote it,
leading to a syntax error.
* ob-C.el (org-babel-C-utility-header-to-C): Include `string.h' in
header `get_column_num' requires `strcmp', leading to compilation
errors.
* ob-C.el (org-babel-C-var-to-C): prefered declaration of a table in D
differs from C and C++. Example in C: `int table[2][3] = ...;'. In D:
`int[3][2] table=...;'
This patch is mainly based on Asa Zeren <asaizeren@gmail.com> patch of
Nov 5 2020, which was not commited at that time.