Re: [O] Org without Emacs?

2019-01-29 Thread nly
btw, you can run emacs on android, and use org from there.

You can install termux from fdroid
and then, at a termux shell, enter:
$ pkg install emacs

I use emacs for org and matrix because matrix clients on android are not as 
nice.

Cheers,
Amar 

On January 29, 2019 3:46:43 PM UTC, Scott Randby  wrote:
>On 1/28/19 11:42 PM, Tim Cross wrote:
>> Of course, this says nothing about the ethical position associated
>with re-implementing functionality from a GPL'd sysem under a non-free
>license. We can hope people do the right thing, but have no control to
>enforce it. I also doubt it will cause any fracture in the org user
>community - the bottom line is most of use came to org because of
>Emacs. These other systems don't have Emacs and therefore are really
>only a pale imitation.
>
>I'm one of those who came to Emacs because of Org. I read an article in
>some magazine (Linux Journal?) about Org and knew I had to try it out.
>Once I was into using Org, Emacs took over more and more of my
>computing life. People who use a non-free semi-implementation of Org
>may not even realize Emacs is the software that made Org possible and
>that Emacs is so great, and I think that is sad.
>
>Scott

-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.

Re: [O] [PATCH] Add feature to org-drill to auto pronounce word

2019-01-29 Thread stardiviner

Nicolas Goaziou  writes:

> Hello,
>
> stardiviner  writes:
>
>> Nicolas Goaziou  writes:
>>
>>> Hello,
>>>
>>> stardiviner  writes:
>>>
 A gentle ping..
>>>
>>> I'm not sure "org-drill.el" is still actively maintained. I'm Cc'ing
>>> Paul Sexton. In the long run, I think this package could be packaged
>>> through ELPA instead.
>>
>> It is indeed not actively maintained. But still has some user are using
>> it. I found some recently used in Org Mode ML mentioned it.
>>
>> I will ping the author Paul Sexton, I would like to particited in
>> maintain it. If he agree to publish it to MELPA, I could help.
>
> Did you forget to add the new patch? Or is it intentional?
>
>
> Regards,

Oh, sorry, seems yes.

>From b95a90cbecdf4fa2f47079eed08d2395f2700d41 Mon Sep 17 00:00:00 2001
From: stardiviner 
Date: Sun, 27 Jan 2019 10:43:37 +0800
Subject: [PATCH] org-drill.el: Add feature let org-drill auto pronounce

* contrib/lisp/org-drill.el (org-drill-entry,
  org-drill-entry-before-hook, org-drill-entry-after-hook): Add two
  hooks around ~org-drill-entry~.
  (org-drill-auto-pronounce): option to toggle this functionality.
  (org-drill-pronounce-command,org-drill-pronounce-command-args): option
  to specify the pronounce command and arguments.
  (org-drill-pronounce-word): The real function to pronounce word.
  (org-drill-hide-subheadings-if): fix issue in Org 9.2 version.
---
 contrib/lisp/org-drill.el | 45 +--
 1 file changed, 43 insertions(+), 2 deletions(-)

diff --git a/contrib/lisp/org-drill.el b/contrib/lisp/org-drill.el
index c7f509bff..39785e7e3 100644
--- a/contrib/lisp/org-drill.el
+++ b/contrib/lisp/org-drill.el
@@ -532,6 +532,35 @@ exponential effect on inter-repetition spacing."
   :type 'float)
 
 
+(defcustom org-drill-entry-before-hook nil
+  "A hook to run functions when every org-drill entry."
+  :type 'hook
+  :group 'org-drill)
+
+(defcustom org-drill-entry-after-hook nil
+  "A hook to run functions when every org-drill entry."
+  :type 'hook
+  :group 'org-drill)
+
+(defcustom org-drill-auto-pronounce t
+  "Auto pronounce org-drill word if non-nil."
+  :type 'boolean
+  :safe #'booleanp
+  :group 'org-drill)
+
+(defcustom org-drill-pronounce-command ""
+  "Org-drill pronounce command."
+  :type 'string
+  :safe #'stringp
+  :group 'org-drill)
+
+(defcustom org-drill-pronounce-command-args ""
+  "Org-drill pronounce command arguments."
+  :type 'string
+  :safe #'stringp
+  :group 'org-drill)
+
+
 (defvar drill-answer nil
   "Global variable that can be bound to a correct answer when an
 item is being presented. If this variable is non-nil, the default
@@ -1486,7 +1515,7 @@ the current topic."
 (funcall test))
  (hide-subtree))
(push (point) drill-sections)))
-   "" 'tree))
+   nil 'tree))
 (reverse drill-sections)))
 
 
@@ -2163,6 +2192,15 @@ If ANSWER is supplied, set the global variable `drill-answer' to its value."
 (prog1 (org-drill-presentation-prompt)
   (org-drill-hide-subheadings-if 'org-drill-entry-p)
 
+(defun org-drill-pronounce-word ()
+  "Pronounce word after querying."
+  (when org-drill-auto-pronounce
+(shell-command-to-string
+ (format "%s %s %s &"
+	 org-drill-pronounce-command org-drill-pronounce-command-args
+	 (shell-quote-argument
+	  (substring-no-properties
+	   (org-get-heading 'no-tags 'no-todo 'no-priority 'no-comment)))
 
 (defun org-drill-entry ()
   "Present the current topic for interactive review, as in `org-drill'.
@@ -2202,6 +2240,7 @@ See `org-drill' for more details."
'org-drill-present-default-answer)
  present-empty-cards (third presentation-fn)
  presentation-fn (first presentation-fn)))
+	  (run-hook-with-args 'org-drill-entry-before-hook)
   (prog1
   (cond
((null presentation-fn)
@@ -2223,7 +2262,9 @@ See `org-drill' for more details."
   (save-excursion
 (funcall answer-fn
  (lambda () (org-drill-reschedule
-(org-remove-latex-fragment-image-overlays)))
+	(when org-drill-auto-pronounce org-drill-pronounce-word)
+	(run-hook-with-args 'org-drill-entry-after-hook)
+	(org-remove-latex-fragment-image-overlays)))
 
 
 (defun org-drill-entries-pending-p ()
-- 
2.20.1



-- 
[ stardiviner ]
   I try to make every word tell the meaning what I want to express.

   Blog: https://stardiviner.github.io/
   IRC(freenode): stardiviner, Matrix: stardiviner
   GPG: F09F650D7D674819892591401B5DF1C95AE89AC3
  


Re: [O] Definitive answer to org-mode export HTML versus LaTeX

2019-01-29 Thread Nick Dokos
Lawrence Bottorff  writes:

> 
>
> My educated guess is that the org-mode HTML export processes is
> handled by MathJax, which is a subset of LaTeX. But then I'd like to
> know definitively what can be done and what cannot be done
> LaTeX-wise for the HTML export.
>

I think you are basically correct: see

http://docs.mathjax.org/en/latest/tex.html

-- 
Nick

"There are only two hard problems in computer science: cache
invalidation, naming things, and off-by-one errors." -Martin Fowler




Re: [O] Org without Emacs?

2019-01-29 Thread Amin Bandali
Hi Scott,

On 2019-01-28 10:51 PM, Scott Randby wrote:

[...]

> I was under the mistaken impression that Orgzly was proprietary
> software. Since it is free software, I'm going to start using it.
>

You weren’t wrong; it did use to be proprietary before, but the author
GPL’ed it about a year or so ago :) As a consequence, it has been
available on F-Droid as well since then.

>
> Scott
>

Best,
amin



Re: [O] Bug: `comment-line` within a SRC block moves point to beginning of block [9.2 (9.2-43-gf9a8cc-elpaplus)]

2019-01-29 Thread Nicolas Goaziou
Hello,

Spencer Russell  writes:

> I've been trying to troubleshoot an issue where running `comment-line`
> within a SRC block moves point to the beginning of the block, rather
> than after the commented line.
> I've boiled it down to a reproduction that duplicates the root cause.
> Open an org document, put point in a SRC block on some line besides the
> first, and run the following:
> ```
> (save-excursion
>   (org-babel-do-in-edit-buffer
> (insert "FOO")))
> ```
>
> This duplicates what happens in `org-comment-or-uncomment-region`
> in `org.el`.
> This will add "FOO" to point, as expected, but point jumps to the
> beginning of the block (at least on my setup). According to the docs of
> `org-edit-src-code`, which is used by `org-babel-do-in-edit-buffer`, it
> removes the original code and replaces it with the edited code. That
> seems like the source of the problem, because the marker saved by `save-
> excursion` is lost.

FWIW, I cannot reproduce it.

Regards,
-- 
Nicolas Goaziou



[O] an org-mode linking question

2019-01-29 Thread Jude DaShiell
I have two files one with notes in it and another containing a table.  I'd
like to keep the notes out of the file with the table in it and like to
keep the table out of the notes file.  Though these two files mostly have
the same names I'm wondering if putting the notes file in a drawer
contained in the table file would be the best way to link these two files
so they stay together.  The notes file is accessed rarely with the table
file having more frequent accesses to update if that helps.



--




[O] latest org-mode ignores visibility property selectively

2019-01-29 Thread Michael Maurer
I'm currently using org-mode version 9.1.14, where everything
seemingly works fine.

The problem is, when I upgrade to the latest version via the packaging
system, one particular headline no longer folds and hides its
children, although the visiblity properties are identical to other
headlines, and the way its children are structured as well.

On startup the custom property gets ignored, it's not folded, and all
its children are visible. I've upgraded to the latest emacs version,
to see if that makes a difference, but the problem persists. Not sure
where or how I should start to track this problem down.

Here's the offending headline.

* DONE 2017 [462/462] abc,cde, efg, hij, klm
:PROPERTIES:
:VISIBILITY: folded
:END:
** DONE Dezember [34/34] abc, eds
:PROPERTIES:
:VISIBILITY: folded
:END:
   CLOSED: [2017-12-31 So 00:19]
   - CLOSING NOTE [2017-12-31 So 00:19]



Re: [O] please read: bug when marking tasks done

2019-01-29 Thread Robert Horn


Nicolas Goaziou writes:

> However, I also suggest to add a new hook, run after repeating
> timestamps. With this hook, and a proper, user-specific, markup, it
> should be possible to pick inactive timestamps in the section and
> "repeat" them manually, i.e., on a case-by-case basis.
>
> WDYT?
>

I like this solution.  I've got several repeating tasks that do not have
simple rules.  (For example, alternating Monday morning/Thursday evening
and adjusting for local holidays, but different rules in July and
August.)  No simple syntax will ever handle these, but I can easily
write an elisp hook to capture the rules.

--
Robert Horn
rjh...@alum.mit.edu



Re: [O] best suited latex document class for html export ?

2019-01-29 Thread John Kitchin
unless you are going to html/odt/etc. through latex (e.g. pandoc or latex2html)
you don't need a latex class to for the other backends.

Joseph Vidal-Rosset  writes:

> Hello,
>
> A question that I had maybe asked (I apologize): is there a best suited
> style (document class for latex) for org-export in html, odt, etc. ? I
> would be happy to get the more convient setup in org-mode for multiple
> exports.
>
> If my question does not make sense, please, forget it.
>
> Best wishes,
>
> Jo.


--
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu



[O] Definitive answer to org-mode export HTML versus LaTeX

2019-01-29 Thread Lawrence Bottorff
I keep being stymied by the apparent incompatibility of HTML and LaTeX
export. Here's what I have in my .org file header:

#+LATEX_CLASS: article
#+LATEX_CLASS_OPTIONS: [american]
#+LATEX_HEADER: \usepackage{tikz}
#+LATEX_HEADER: \usepackage{commath}
#+LATEX_HEADER: \usepackage{stackengine}
#+LaTeX_HEADER: \usepackage{pgfplots}
#+LaTeX_HEADER: \usepackage{sansmath}
#+LATEX_HEADER: \usepackage{mathtools}
#+LaTeX_HEADER: \usepackage{amsmath}

In reality, I don't know if this gets seen by org-mode export to HTML,
perhaps by export to LaTeX? So to start, here is working piece of markup
that displays great in both HTML and LaTeX:

#+begin_src latex :packages '(("" "tikz")) :exports results :results output
raw :file other12.png :imagemagick yes :iminoptions -density 600
:imoutoptions -geometry 500

\usetikzlibrary{decorations.pathreplacing}

  \begin{tikzpicture}[scale=1]
\draw[step=1cm,thin,gray!60] (-6,-6) grid (6,6);
\draw[<->] (-6,0)--(6,0) node[right]{$x$};
\draw[<->] (0,-6)--(0,6) node[above]{$y$};
\draw[line width=2pt,blue,-stealth](0,0)--(4,-3) node[anchor=south
west]{$\boldsymbol{(4,-3)}$};
\draw[line width=2pt,gray,-stealth](2,3)--(6,0) node[anchor=south west];
\draw[line width=2pt,gray,-stealth](-5,4)--(-1,1) node[anchor=south
west];
\draw[line width=2pt,gray,-stealth](-3,-1)--(1,-4) node[anchor=south
west];
\draw
[decorate,color=red,decoration={brace,amplitude=10pt},xshift=-0pt,yshift=0pt]
(-5.0,1.0) -- (-5.0,4.0) node [red,midway,xshift=-0.65cm]
{\footnotesize $-3$};
\draw
[decorate,color=red,decoration={brace,amplitude=10pt,mirror,raise=1pt},xshift=-0pt,yshift=0pt]
(-5,1) -- (-1,1) node [red,midway,yshift=-0.6cm] {\footnotesize $4$};
  \end{tikzpicture}

#+end_src

The following also displays in both HTML and LaTeX correctly:

\begin{align*}
\|x\|&=\sqrt{4^2+(-3)^2} \\
&= \sqrt{25} \\
&= 5
\end{align*}
as well as this:

\begin{equation*}
x = \begin{pmatrix}
\phantom{-} 4 \\
   -3 \\
\end{pmatrix}
 \end{equation*}

but this on the HTML side

\setstackEOL{\\}
\begin{equation*}
x=\parenVectorstack[r]{4\\-3\\2}
\end{equation*}

doesn't know what \setstackEOL{\\} is, nor \parenVectorstack[r] and
displays mangled. The LaTeX export looks fine, though. And if I put it in a
LaTeX babel code block, it disappears from the HTML entirely, while, again,
the LaTeX export displays just fine. Confusing is how the Tikz code block
is displayed in both HTML and LaTeX, but any other attempt at a LaTeX code
block is ignored and left completely out of the HTML export.

My educated guess is that the org-mode HTML export processes is handled by
MathJax, which is a subset of LaTeX. But then I'd like to know definitively
what can be done and what cannot be done LaTeX-wise for the HTML export.

LB


Re: [O] Org Elpa deployment failing for past 2 weeks

2019-01-29 Thread Detlef Steuer
Am Tue, 22 Jan 2019 18:26:54 +
schrieb Sharon Kimble :

> Kaushal Modi  writes:
> 
> > Hello,
> >
> > The Org Elpa deploys a new release every week on Mondays.
> >
> > But it looks like that release has been failing for past 2 weeks.
> >
> > Here's the log file from yesterday that shows the error during make
> > cleanall: https://orgmode.org/elpa/build-org-pkg.txt
> >
> > --
> > Kaushal Modi
> >  
> 
> And I confirm that it is still failing, with the last update
> available of 2018-12-30.

Just to give another confirmation. Still failing, still 2018-12-30.

Would be great if that service was reestablished.

Thx
Detlef


> 
> Can someone fix it please, so that we can stay up to date?
> 
> Thanks
> Sharon.



-- 
The biggest difference between time and space is that you can’t reuse
time. (Merrick Furst)





Re: [O] Org without Emacs?

2019-01-29 Thread Scott Randby
On 1/28/19 11:42 PM, Tim Cross wrote:
> Of course, this says nothing about the ethical position associated with 
> re-implementing functionality from a GPL'd sysem under a non-free license. We 
> can hope people do the right thing, but have no control to enforce it. I also 
> doubt it will cause any fracture in the org user community - the bottom line 
> is most of use came to org because of Emacs. These other systems don't have 
> Emacs and therefore are really only a pale imitation.

I'm one of those who came to Emacs because of Org. I read an article in some 
magazine (Linux Journal?) about Org and knew I had to try it out. Once I was 
into using Org, Emacs took over more and more of my computing life. People who 
use a non-free semi-implementation of Org may not even realize Emacs is the 
software that made Org possible and that Emacs is so great, and I think that is 
sad.

Scott



Re: [O] best suited latex document class for html export ?

2019-01-29 Thread Joseph Vidal-Rosset
Many thanks John, your reply is helpful. Precisely, I used recently pandoc
and tried also to export to html an org file. That explains my question.

Best wishes,

Jo.

Le mar. 29 janv. 2019 à 15:07, John Kitchin  a
écrit :

> unless you are going to html/odt/etc. through latex (e.g. pandoc or
> latex2html)
> you don't need a latex class to for the other backends.
>
> Joseph Vidal-Rosset  writes:
>
> > Hello,
> >
> > A question that I had maybe asked (I apologize): is there a best suited
> > style (document class for latex) for org-export in html, odt, etc. ? I
> > would be happy to get the more convient setup in org-mode for multiple
> > exports.
> >
> > If my question does not make sense, please, forget it.
> >
> > Best wishes,
> >
> > Jo.
>
>
> --
> Professor John Kitchin
> Doherty Hall A207F
> Department of Chemical Engineering
> Carnegie Mellon University
> Pittsburgh, PA 15213
> 412-268-7803
> @johnkitchin
> http://kitchingroup.cheme.cmu.edu
>


Re: [O] Bind pcomplete to C-M-i

2019-01-29 Thread Nicolas Goaziou
Hello,

Johannes Altmanninger  writes:

> Hi Nicolas,
>
> On Sun, Jan 27, 2019 at 10:01 PM Nicolas Goaziou  
> wrote:
>>
>> Hello,
>>
>> Johannes Altmanninger  writes:
>>
>> > However, I want to use org-plus-contrib from the Org ELPA repository.
>> > which uses a slightly different definition:
>> >
>> > (org-defkey org-mode-map (kbd "M-") #'pcomplete)
>> > (org-defkey org-mode-map (kbd "ESC ") #'pcomplete)
>>
>> Would (kbd "M-TAB") and (kbd "ESC TAB") work?
>
> Yes, either of them works!
> They appear to behave the same as (kbd "\M-\t").

Done. Thank you.

Regards,

-- 
Nicolas Goaziou



[O] best suited latex document class for html export ?

2019-01-29 Thread Joseph Vidal-Rosset
Hello,

A question that I had maybe asked (I apologize): is there a best suited
style (document class for latex) for org-export in html, odt, etc. ? I
would be happy to get the more convient setup in org-mode for multiple
exports.

If my question does not make sense, please, forget it.

Best wishes,

Jo.


[O] floatp test in babel

2019-01-29 Thread cédric ody
Hello,


I am trying to understand why the floatp lisp function does not seem to
detect exponential scientific notation in babel octave mode.


If I do


#+BEGIN_SRC emacs-lisp

(floatp 1e4)

#+END_SRC


#+RESULTS:

: t


whereas in the following table is converted into char due to the presence
of the third column.


#+RESULTS: variables

| 1 | 1 | 1e-05 |


#+HEADERS: :var a=variables

#+BEGIN_SRC octave :results output replace

whos a

#+END_SRC


#+RESULTS:

: Variables in the current scope:

: Attr Name Size Bytes Class
:    = =
: a 1x7 7 char

:


Can we modify something so that exponential notation is supported?


Cédric