Re: [O] ATTR_LATEX :options ignored for source code

2016-05-15 Thread Jeff Trull
Ah, I see...

I was expecting the "option to the environment" to look like:

\begin{lstlisting}[commentstyle=\bfseries]

Though doing it with \lstset will produce the same result if the option is
placed at the end, which it is.

Thanks for your help,
Jeff

On Sun, May 15, 2016 at 12:33 AM, Nicolas Goaziou 
wrote:

> Hello,
>
> Jeff Trull  writes:
>
> > According to the manual users can supply #+ATTR_LATEX: :options ... prior
> > to a source section and the options present will be supplied to the
> > environment (lstlistings in my case).  I find that this does not work -
> > regardless of settings, no options are supplied to the lstlistings
> > environment.  Attached is a test case that demonstrates the problem.  It
> is
> > taken from the manual.
>
> FWIW, I cannot reproduce it. I get
>
>   \lstset{language=C++,label= ,caption=
> ,captionpos=b,numbers=none,commentstyle=\bfseries}
>   \begin{lstlisting}
>   using foo_t = int;
>   struct bar_t {
>   foo_t a; // this comment should be bold
>   };
>   \end{lstlisting}
>
> What Org version are you using?
>
> Regards,
>
> --
> Nicolas Goaziou
>


Re: [O] (version 3) [PATCH] New feature: Use dvisvgm to preview latex formular

2016-05-15 Thread Feng Shu
Nicolas Goaziou  writes:

>> +  :group 'org-latex
>> +  :version "24.1"
>
> :version "25.1"
>
>> +  :type 'alist)

I need to help to deal with it, what about just remove :type?

>




Re: [O] (version 3) [PATCH] New feature: Use dvisvgm to preview latex formular

2016-05-15 Thread Feng Shu
Nicolas Goaziou  writes:


> In any case, I suggest to create a new variable
> `org-latex-preview-process' for that.

`org-latex-preview-process' is a good idea, which make org-latex
beginner easily, i will add it.

>
>> (org-latex-compile): Add a new optional argument: caller-info,
>>  which used to record the caller's info
>
> In the same vein, I suggest to extract it out from ox-latex and use
> a dedicated command for that.
>
> WDYT?

I suggest to add (:generator my-generator-function) style configure
to `org-latex-pdf-process', it is simple and powerful feature, we
can use this feature to switch latex commands dynamicially, for example:

(defun my-latex-pdf-process-generator (texfile snippet extra-info)
  (cond
   (() ()
   (() ()

although we can set org-latex-pdf-process to a function to do the same work,
but this function is hard to write as org-latex-compile, it may only
useful for developer instead of user

caller-info argument is for the above feature.

>
>> (org-create-formula-image): Big refactor, merge dvipng and imagemagick 
>> backend's feature.
>> Add dvisvgm feature.
>
> Good news. This part was begging for a refactor. A couple (or more) of
> tests would be nice too.

yes


>> +
>> +(defalias 'org-latex-preview-ltxpng-directory 
>> 'org-latex-preview-ltximg-directory)
>> +(make-obsolete 'org-latex-preview-ltxpng-directory 
>> 'org-latex-preview-ltximg-directory
>> +   "Org mode version 9.0")
>
> See `make-obsolete-variable'.

Remove the above two and only use the below *one* ?

(make-obsolete-variable
 'org-latex-preview-ltxpng-directory
 "Set `org-latex-preview-ltximg-directory' instead." "25.1")





Re: [O] Bug: Write file while editing babel code block doesn't work as expected [8.3.4 (release_8.3.4-778-g8127b3 @ /usr/local/share/emacs/site-lisp/org/)]

2016-05-15 Thread Vladimir Lomov
Hello,
** Nicolas Goaziou [2016-05-15 19:03:57 +0200]:

> Hello,
> 
> Vladimir Lomov  writes:
> 
>> Correct me if I understand you wrong, but you suggest to bind ~F2~ key
>> to ~org-edit-src-save~. But then this will work only in Org buffer, and
>> how about LaTeX mode then. Or I should bind ~F2~ to something like that:
>> (global-set-key [f2]
>>   (if (functionp org-edit-src-save) org-edit-src-save save-buffer))
> 
> Actually, I meant to bind F2 to `org-edit-src-save' in
> `org-src-mode-map'.

With your advice I came to following code for my init file:
#+BEGIN_SRC emacs-lisp
  (add-hook 'org-src-mode-hook
(lambda ()
  (define-key org-src-mode-map [f2] 'org-edit-src-save)
)
  )
#+END_SRC

This works fine, though at first I thought it would be enough to add
only following code
#+BEGIN_SRC emacs-lisp
  (define-key org-src-mode-map [f2] 'org-edit-src-save)
#+END_SRC
into emacs init file. Of course, this don't work and emacs complains about
~org-src-mode-map~. Only one thing bother me: is it normal to add such
hook into ~org-src-mode-hook~ ?

>> On second thought, I considered org-src buffer as auxiliary buffer,
>> depending on (main) Org document buffer, so saving org-src buffer should
>> save Org document buffer.
> 
> This is the case already with C-x C-s, not for `save-buffer'.
> 
> Regards,
> 
> -- 
> Nicolas Goaziou

-- 
"If you can, help others.  If you can't, at least don't hurt others."
-- the Dalai Lama



[O] Hope to tag a new relase in Org-mode ELPA repo

2016-05-15 Thread numbch...@gmail.com
I'm waiting for new fix in org-mode.
But org-mode is still in version 8.3.4.
I use org-mode elpa repo. (latest version)
and my ob-lisp.el SLY support is newer than the latest tag and is in new
version (9.0)
Or is there some reasons that I don't know which makes the new release late?

[stardiviner] GPG key ID: 47C32433
IRC(freeenode): stardiviner Twitter:  @numbchild
Key fingerprint = 9BAA 92BC CDDD B9EF 3B36  CB99 B8C4 B8E5 47C3 2433
Blog: http://stardiviner.github.io/


Re: [O] [BUG] Noweb reference eval syntax does not work

2016-05-15 Thread Nicolas Goaziou
Hello,

Aaron Ecay  writes:

> I think that we can provide a replacement to noweb-ref as follows:
>
> * Code blocks
> :PROPERTIES:
> :header-args: :noweb-ref foo
> :END:
>
> #+begin_src python
> block 1
> #+end_src
> #+begin_src python
> block 2
> #+end_src
>
> * Concat
>
> The old way
>
> #+begin_src python
> <>
> #+end_src
>
> The new way:
>
> #+begin_src python
> <>
> #+end_src
>
> concat-blocks-of-lang-in-headline would have to be an elisp source block
> implementing the appropriate behavior which is present in the document
> or in the library of babel.

[...]

> To put it another way: it seems to me that the functionality of
> :noweb-ref can be reimplemented in terms of other primitives.  And given
> Nicolas’s comments about the complications and bugs it introduces, I’d
> be in favor of deprecating and eventually removing it.

I like the idea of separating block chaining and basic block syntax.
That way, you don't need to pay the full price of the former if you only
use the latter.

However, filtering per language and headline header may be a burden. For
example, this ignores blocks before first heading, and forces user to
store them under the same headline. We could also keep :noweb-ref
references and chain all blocks with a given :noweb-ref, with a special
command. What about <> ?

Eventually we could add into the manual how a chained block can be
evaluated, since <> is not meaningful.

WDYT?

Regards,

-- 
Nicolas Goaziou



Re: [O] (version 3) [PATCH] New feature: Use dvisvgm to preview latex formular

2016-05-15 Thread Nicolas Goaziou
Hello,

"Feng Shu"  writes:

Thank you for this work. This looks interesting. Some comments follow.

> * ox-latex.el (org-latex-pdf-process): Add a new config
> method, :fetcher.

At this point, I think we should instead separate compiler for LaTeX
preview from compiler for full LaTeX export. It probably makes sense to
have a full fledged compile process for the export back-end possibly
with multiple passes to get cross-references right, and a quick process
for previews.

In any case, I suggest to create a new variable
`org-latex-preview-process' for that.

> (org-latex-compile): Add a new optional argument: caller-info,
>  which used to record the caller's info

In the same vein, I suggest to extract it out from ox-latex and use
a dedicated command for that.

WDYT?

> (org-create-formula-image): Big refactor, merge dvipng and imagemagick 
> backend's feature.
> Add dvisvgm feature.

Good news. This part was begging for a refactor. A couple (or more) of
tests would be nice too.

> -(defcustom org-latex-preview-ltxpng-directory "ltxpng/"
> +(defcustom org-latex-to-image-backends
> +  '((dvipng
> + :class snippet
> + :name dvipng
> + :programs ("dvipng" "gs")
> + :message "you need to install dvipng and ghostscript."
> + :input dvi
> + :output png
> + :color dvipng
> + :scale-adjust 2.0
> + :org-latex-compile nil
> + :need-clean (".dvi" ".tex" ".aux" ".log" ".png" ".out")
> + :commands (("latex" "-interaction" "nonstopmode" "-output-directory" 
> "%temp-dir%" "%tex-file%")
> + ("dvipng" "-fg" "%fg%" "-bg" "%bg%" "-D" "%dpi%" "-T" "tight" 
> "-o" "%output-file%" "%input-file%")))
> +(dvisvgm
> + :class snippet
> + :name dvisvgm
> + :programs ("dvisvgm" "gs")
> + :message "you needed to install dvisvgm and ghostscript."
> + :input dvi
> + :output svg
> + :color latex
> + :scal-adjust 2.0

Typo. :scale-adjust

> + :org-latex-compile t
> + :post-clean (".dvi" ".xdv" ".tex" ".aux" ".log" ".svg" ".out")
> + :commands (("dvisvgm" "%input-file%" "-n" "-b" "min" "-c" "%scale%" 
> "-o" "%output-file%")))
> +(imagemagick
> + :class snippet
> + :name imagemagick
> + :programs ("convert" "gs")
> + :message "you need to install imagemagick and ghostscript."
> + :input pdf
> + :output png
> + :color latex
> + :scale-adjust 2.0
> + :org-latex-compile t
> + :post-clean (".pdf" ".tex" ".aux" ".log" ".png" ".out")
> + :commands (("convert" "-density" "%dpi%" "-trim" "-antialias" 
> "%input-file%" "-quality" "100" "%output-file%"
> +  "Org mode can use some external commands to generate TeX snippet's image 
> for

The first line needs to be a sentence on its own. Perhaps:

  "List definitions of external processes for LaTeX previewing.
Org can use some external commands to generate LaTeX snippet' images for
..."

> +proviewing or inserting to html file, for example: dvipng, dvisvgm or 
> imagemagick

previewing or inserting into HTML files, e.g.,

> +this variable tell `org-create-formula-image' how to use the above command.

tells

> +  :class  symbol, this setting may useful in future.

may be useful

> +  :name   string, the backend's name.
> +  :programs   string-list, required programs.

list of strings

> +  :messagestring, message it when required program can't be 
> found.
> +  :input  symbol, input file type, for example: dvi.
> +  :output symbol, output file type, for example: png.
> +  :color  symbol, if it set to 'latex, latex xcolor macro will 
> be used

if set to `latex', LaTeX "xcolor" macro is used

> +  to deal with background and fontground color of image, 
> 'divpng

if set to `dvipng'

> +  is only useful to dvipng backend.
> +  :scale-adjust   number, adjust image's size, only useful for backend 
> developers.
> +  :org-latex-compile  boolean, if set it to t, `org-create-formula-image' 
> will use

when non-nil `org-create-formula-image' uses...

> +  `org-latex-compile' to compile tex file, when set it 
> to nil,

otherwise, you need to

> +  user need to set latex command in `:commands'.
> +  :need-clean string-list, the files matched its elements will be 
> cleaned up
> +  after image generated.

list of strings, files matched are to be cleaned up once the image is
generated

> +  :commands   list, the commands setting, the following special 
> strings,
> +  will be replaced to according value before command 
> called.
> +
> +   1. %fg%fontground

foreground

> +  For example, %tmpdir% may be replaced to /tmp in 
> linux."

may be replaced with "/tmp".

> +  :group 'org-latex
> +  :version "24.1"

:version "25.1"

> +  :type 'alist)

Re: [O] Bug: Write file while editing babel code block doesn't work as expected [8.3.4 (release_8.3.4-778-g8127b3 @ /usr/local/share/emacs/site-lisp/org/)]

2016-05-15 Thread Nicolas Goaziou
Hello,

Vladimir Lomov  writes:

> Correct me if I understand you wrong, but you suggest to bind ~F2~ key
> to ~org-edit-src-save~. But then this will work only in Org buffer, and
> how about LaTeX mode then. Or I should bind ~F2~ to something like that:
> (global-set-key [f2]
>   (if (functionp org-edit-src-save) org-edit-src-save save-buffer))

Actually, I meant to bind F2 to `org-edit-src-save' in
`org-src-mode-map'.

> On second thought, I considered org-src buffer as auxiliary buffer,
> depending on (main) Org document buffer, so saving org-src buffer should
> save Org document buffer.

This is the case already with C-x C-s, not for `save-buffer'.

Regards,

-- 
Nicolas Goaziou



Re: [O] (version 4) [PATCH] New feature: Use dvisvgm to preview latex formular

2016-05-15 Thread Feng Shu
"Feng Shu"  writes:

v4 patch, add some minor change based v3

>From 010baf028bb6dbb706f5abb9f99de0552235f2af Mon Sep 17 00:00:00 2001
From: Feng Shu 
Date: Sat, 14 May 2016 22:42:53 +0800
Subject: [PATCH] New feature: Use dvisvgm to preview latex formular

Tester should set like below:

(setq org-latex-create-formula-image-program 'dvisvgm)

(setq org-latex-pdf-process
  '(:fetcher my-org-latex-pdf-process-format))

(defun my-org-latex-pdf-process-format (&optional texfile snippet caller-info)
  (princ (format "The caller's info: %s" caller-info))
  (cond
   (snippet '("latex -interaction nonstopmode -output-directory %o %f"))
   (t '("%latex -interaction nonstopmode -output-directory %o %f"
"%latex -interaction nonstopmode -output-directory %o %f"
"%latex -interaction nonstopmode -output-directory %o %f"

* ox-latex.el (org-latex-pdf-process): Add a new config method, :fetcher.
(org-latex-compile): Add a new optional argument: caller-info,
 which used to record the caller's info

* ox-html.el (org-html-with-latex): Add dvisvgm support.
(org-html-with-latex): Add dvisvgm support.
(org-html-format-latex): "ltxpng" -> "ltximg".
(org-html-latex-environment): Add dvisvgm support.
(org-html-latex-fragment): Add dvisvgm support.

* org.el (org-latex-create-formula-image-program): Add dvisvgm.
(org-latex-preview-ltximg-directory): Rename from `org-latex-preview-ltximg-directory'.
(org--format-latex-make-overlay): Add optional image-type, which used to deal with svg.
(org-toggle-latex-fragment): "org-ltxpng" -> "org-ltximg".
(org-format-latex): Add dvisvgm support.
(org-create-formula-image): Big refactor, merge dvipng and imagemagick backend's feature.
Add dvisvgm feature.
(org-latex-to-image-backends): Add new variable, which used to set latex2image program.
(org-create-formula-image-with-dvipng): Useless, removed.
(org-create-formula-image-with-imagemagick): Useless, removed.

* org.texi (@LaTeX{} fragments): Add dvisvgm information.
(Previewing @LaTeX{} fragments): Add dvisvgm information.
(Math formatting in HTML export): Add dvisvgm information.
(Working with @LaTeX{} math snippets): Add dvisvgm information.
---
 doc/org.texi |  39 +++---
 lisp/org.el  | 366 +++
 lisp/ox-html.el  |  28 +++--
 lisp/ox-latex.el | 161 +++-
 4 files changed, 354 insertions(+), 240 deletions(-)

diff --git a/doc/org.texi b/doc/org.texi
index 17b01c2..286fabb 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -10393,10 +10393,10 @@ snippets will be identified as @LaTeX{} source code:
 @item
 Environments of any kind@footnote{When MathJax is used, only the
 environments recognized by MathJax will be processed.  When
-@file{dvipng} program or @file{imagemagick} suite is used to create images,
-any @LaTeX{} environment will be handled.}.  The only requirement is that the
-@code{\begin} statement appears on a new line, at the beginning of the line
-or after whitespaces only.
+@file{dvipng} program, @file{dvisvgm} program or @file{imagemagick} suite is
+used to create images, any @LaTeX{} environment will be handled.}.  The only
+requirement is that the @code{\begin} statement appears on a new line, at the
+beginning of the line or after whitespaces only.
 @item
 Text within the usual @LaTeX{} math delimiters.  To avoid conflicts with
 currency specifications, single @samp{$} characters are only recognized as
@@ -10444,10 +10444,10 @@ lines:
 @cindex @LaTeX{} fragments, preview
 
 @vindex org-latex-create-formula-image-program
-If you have a working @LaTeX{} installation and either @file{dvipng} or
-@file{convert} installed@footnote{These are respectively available at
-@url{http://sourceforge.net/projects/dvipng/} and from the @file{imagemagick}
-suite. Choose the converter by setting the variable
+If you have a working @LaTeX{} installation and @file{dvipng}, @file{dvisvgm}
+or @file{convert} installed@footnote{These are respectively available at
+@url{http://sourceforge.net/projects/dvipng/}, @url{http://dvisvgm.bplaced.net/}
+and from the @file{imagemagick} suite. Choose the converter by setting the variable
 @code{org-latex-create-formula-image-program} accordingly.}, @LaTeX{}
 fragments can be processed to produce images of the typeset expressions to be
 used for inclusion while exporting to HTML (see @pxref{@LaTeX{} fragments}),
@@ -11713,6 +11713,7 @@ You could use @code{http} addresses just as well.
 @subsection Math formatting in HTML export
 @cindex MathJax
 @cindex dvipng
+@cindex dvisvgm
 @cindex imagemagick
 
 @LaTeX{} math snippets (@pxref{@LaTeX{} fragments}) can be displayed in two
@@ -11737,13 +11738,18 @@ template can be configure via @code{org-html-mathjax-template}.
 If you prefer, you can also request that @LaTeX{} fragments are processed
 into small images that will be inserted into the browser page.  Before the
 availability o

Re: [O] (version 3) [PATCH] New feature: Use dvisvgm to preview latex formular

2016-05-15 Thread Feng Shu
"Feng Shu"  writes:

Version 4 patch, minor change based v3

>From 010baf028bb6dbb706f5abb9f99de0552235f2af Mon Sep 17 00:00:00 2001
From: Feng Shu 
Date: Sat, 14 May 2016 22:42:53 +0800
Subject: [PATCH] New feature: Use dvisvgm to preview latex formular

Tester should set like below:

(setq org-latex-create-formula-image-program 'dvisvgm)

(setq org-latex-pdf-process
  '(:fetcher my-org-latex-pdf-process-format))

(defun my-org-latex-pdf-process-format (&optional texfile snippet caller-info)
  (princ (format "The caller's info: %s" caller-info))
  (cond
   (snippet '("latex -interaction nonstopmode -output-directory %o %f"))
   (t '("%latex -interaction nonstopmode -output-directory %o %f"
"%latex -interaction nonstopmode -output-directory %o %f"
"%latex -interaction nonstopmode -output-directory %o %f"

* ox-latex.el (org-latex-pdf-process): Add a new config method, :fetcher.
(org-latex-compile): Add a new optional argument: caller-info,
 which used to record the caller's info

* ox-html.el (org-html-with-latex): Add dvisvgm support.
(org-html-with-latex): Add dvisvgm support.
(org-html-format-latex): "ltxpng" -> "ltximg".
(org-html-latex-environment): Add dvisvgm support.
(org-html-latex-fragment): Add dvisvgm support.

* org.el (org-latex-create-formula-image-program): Add dvisvgm.
(org-latex-preview-ltximg-directory): Rename from `org-latex-preview-ltximg-directory'.
(org--format-latex-make-overlay): Add optional image-type, which used to deal with svg.
(org-toggle-latex-fragment): "org-ltxpng" -> "org-ltximg".
(org-format-latex): Add dvisvgm support.
(org-create-formula-image): Big refactor, merge dvipng and imagemagick backend's feature.
Add dvisvgm feature.
(org-latex-to-image-backends): Add new variable, which used to set latex2image program.
(org-create-formula-image-with-dvipng): Useless, removed.
(org-create-formula-image-with-imagemagick): Useless, removed.

* org.texi (@LaTeX{} fragments): Add dvisvgm information.
(Previewing @LaTeX{} fragments): Add dvisvgm information.
(Math formatting in HTML export): Add dvisvgm information.
(Working with @LaTeX{} math snippets): Add dvisvgm information.
---
 doc/org.texi |  39 +++---
 lisp/org.el  | 366 +++
 lisp/ox-html.el  |  28 +++--
 lisp/ox-latex.el | 161 +++-
 4 files changed, 354 insertions(+), 240 deletions(-)

diff --git a/doc/org.texi b/doc/org.texi
index 17b01c2..286fabb 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -10393,10 +10393,10 @@ snippets will be identified as @LaTeX{} source code:
 @item
 Environments of any kind@footnote{When MathJax is used, only the
 environments recognized by MathJax will be processed.  When
-@file{dvipng} program or @file{imagemagick} suite is used to create images,
-any @LaTeX{} environment will be handled.}.  The only requirement is that the
-@code{\begin} statement appears on a new line, at the beginning of the line
-or after whitespaces only.
+@file{dvipng} program, @file{dvisvgm} program or @file{imagemagick} suite is
+used to create images, any @LaTeX{} environment will be handled.}.  The only
+requirement is that the @code{\begin} statement appears on a new line, at the
+beginning of the line or after whitespaces only.
 @item
 Text within the usual @LaTeX{} math delimiters.  To avoid conflicts with
 currency specifications, single @samp{$} characters are only recognized as
@@ -10444,10 +10444,10 @@ lines:
 @cindex @LaTeX{} fragments, preview
 
 @vindex org-latex-create-formula-image-program
-If you have a working @LaTeX{} installation and either @file{dvipng} or
-@file{convert} installed@footnote{These are respectively available at
-@url{http://sourceforge.net/projects/dvipng/} and from the @file{imagemagick}
-suite. Choose the converter by setting the variable
+If you have a working @LaTeX{} installation and @file{dvipng}, @file{dvisvgm}
+or @file{convert} installed@footnote{These are respectively available at
+@url{http://sourceforge.net/projects/dvipng/}, @url{http://dvisvgm.bplaced.net/}
+and from the @file{imagemagick} suite. Choose the converter by setting the variable
 @code{org-latex-create-formula-image-program} accordingly.}, @LaTeX{}
 fragments can be processed to produce images of the typeset expressions to be
 used for inclusion while exporting to HTML (see @pxref{@LaTeX{} fragments}),
@@ -11713,6 +11713,7 @@ You could use @code{http} addresses just as well.
 @subsection Math formatting in HTML export
 @cindex MathJax
 @cindex dvipng
+@cindex dvisvgm
 @cindex imagemagick
 
 @LaTeX{} math snippets (@pxref{@LaTeX{} fragments}) can be displayed in two
@@ -11737,13 +11738,18 @@ template can be configure via @code{org-html-mathjax-template}.
 If you prefer, you can also request that @LaTeX{} fragments are processed
 into small images that will be inserted into the browser page.  Before the
 availability of 

Re: [O] Bug: Write file while editing babel code block doesn't work as expected [8.3.4 (release_8.3.4-778-g8127b3 @ /usr/local/share/emacs/site-lisp/org/)]

2016-05-15 Thread Vladimir Lomov
Hello,
** Nicolas Goaziou [2016-05-15 09:40:03 +0200]:

> Hello,
> 
> Vladimir Lomov  writes:
> 
>> I have small example that worked before the commit, please see attached
>> Org document.
> 
> While it's true this worked before, I don't consider it to be
> a regression. There was no guarantee that `save-buffer' would save the
> source buffer. In fact, I think instrumenting `save-buffer' is not
> a good idea, because it is surprising. Usually, minor modes change
> bindings instead of altering functions.
> 
> You can bind `org-edit-src-save' to F2 in this case.

Correct me if I understand you wrong, but you suggest to bind ~F2~ key
to ~org-edit-src-save~. But then this will work only in Org buffer, and
how about LaTeX mode then. Or I should bind ~F2~ to something like that:
(global-set-key [f2]
  (if (functionp org-edit-src-save) org-edit-src-save save-buffer))

(don't test this code, just idea, may be this code won't work or even
there is more elegant code and idea).

On second thought, I considered org-src buffer as auxiliary buffer,
depending on (main) Org document buffer, so saving org-src buffer should
save Org document buffer. I agree that there should be possibility to
save org-src buffer and if ~write-buffer~ works it is Ok and it is Ok to
call it manually. This is just my thoughts.

> 
> Regards,
> 
> -- 
> Nicolas Goaziou

---
WBR, Vladimir Lomov

-- 
Q:  Why does Washington have the most lawyers per capita and
New Jersey the most toxic waste dumps?
A:  God gave New Jersey first choice.



Re: [O] Bug: Write file while editing babel code block doesn't work as expected [8.3.4 (release_8.3.4-778-g8127b3 @ /usr/local/share/emacs/site-lisp/org/)]

2016-05-15 Thread Nicolas Goaziou
Hello,

Vladimir Lomov  writes:

> I have small example that worked before the commit, please see attached
> Org document.

While it's true this worked before, I don't consider it to be
a regression. There was no guarantee that `save-buffer' would save the
source buffer. In fact, I think instrumenting `save-buffer' is not
a good idea, because it is surprising. Usually, minor modes change
bindings instead of altering functions.

You can bind `org-edit-src-save' to F2 in this case.

Regards,

-- 
Nicolas Goaziou



[O] org-agenda repeated tasks showing multiple times

2016-05-15 Thread Paul Harper
Hello,

I am getting the following in my org-agenda everyday with repeated
tasks.

"Sunday 15 May 2016
  schedule:   Sched.16x:  Backup KeepassX Local
  schedule:   Sched.16x:  PC Backup to External Drive
  schedule:   Sched.16x:  Review Weekly
  schedule:   Sched.16x:  Backup KeepassX Local
 Sunday 15 May 2016
  schedule:   Sched.16x:  Backup KeepassX Local
  schedule:   Sched.16x:  PC Backup to External Drive
  schedule:   Sched.16x:  Review Weekly
  schedule:   Sched.16x:  Backup KeepassX Local
  schedule:   Sched.16x:  PC Backup to External Drive
  schedule:   Sched.16x:  Review Weekly
And so on

How do I stop that and only see the task for one particular day in my
agenda?

Regards,

Paul




Re: [O] ATTR_LATEX :options ignored for source code

2016-05-15 Thread Nicolas Goaziou
Hello,

Jeff Trull  writes:

> According to the manual users can supply #+ATTR_LATEX: :options ... prior
> to a source section and the options present will be supplied to the
> environment (lstlistings in my case).  I find that this does not work -
> regardless of settings, no options are supplied to the lstlistings
> environment.  Attached is a test case that demonstrates the problem.  It is
> taken from the manual.

FWIW, I cannot reproduce it. I get

  \lstset{language=C++,label= ,caption= 
,captionpos=b,numbers=none,commentstyle=\bfseries}
  \begin{lstlisting}
  using foo_t = int;
  struct bar_t {
  foo_t a; // this comment should be bold
  };
  \end{lstlisting}

What Org version are you using?

Regards,

-- 
Nicolas Goaziou