Re: [O] org-odt-export-to-odt: hide text

2013-07-06 Thread Suvayu Ali
On Fri, Jul 05, 2013 at 09:26:22PM +0200, Uwe Brauer wrote:
 On 07/05/2013 07:40 PM, Eric S Fraga wrote:
   #+begin_comment ... #+end_comment?
 does not work, the odt file contains
 
 #+begin_comment
 
 my text
 
 #+end_comment ?
 
 the issue is I want to write say one paragraph in Spanish
 and the next in German, again spanish then German, etc
 but the odt file should only display one language.

Why are you not using Org comments?

Visible text, exported

# Org comment, not exported

Hope this helps,

-- 
Suvayu

Open source is the future. It sets us free.



Re: [O] Sitemap for google?

2013-07-06 Thread Vikas Rawal

  When I publish my website, orgmode gives me the sitemap as an html.
  Google requires sitemap as an xml, rss or text file
  (https://support.google.com/webmasters/answer/183668).
 
  Any suggestions on how to get orgmode to create a google-compatible
  sitemap?
 
 You seem to have missed my reply here:
 http://article.gmane.org/gmane.emacs.orgmode/74088

Oops! Sorry and thanks.

Vikas



Re: [O] org-odt-export-to-odt: hide text

2013-07-06 Thread Uwe Brauer
 Suvayu == Suvayu Ali fatkasuvayu+li...@gmail.com writes:

On Fri, Jul 05, 2013 at 09:26:22PM +0200, Uwe Brauer wrote:

the issue is I want to write say one paragraph in Spanish
and the next in German, again spanish then German, etc
but the odt file should only display one language.

Why are you not using Org comments?

Visible text, exported

# Org comment, not exported

Hope this helps,

this works, of course, thanks! The only issue is if I want to export say
either only Spanish or only German, than this approach needs to delete
and replace  the comments manually. But ok, better than nothing. 

That is 

Spanish is exported 
# german is not exported.


# spanish not
German is exported.

While I would like to have some tags which I could toggle on and off,
for example in the example of Eric, I would just substitute 
the tag :noexport: for :export:

However his approach needs to set headers before the text.

Anyhow thanks for you help.

Uwe 


smime.p7s
Description: S/MIME cryptographic signature


Re: [O] tag groups

2013-07-06 Thread Maurice
Hi, Bastien,

Bastien b...@gnu.org écrivit :

 value for : org-tag-alist-for-agenda

  ((:startgroup)
  (prêté . 112)
  (emprunté . 101)
  (:endgroup)
  (note . 110)
  (noexport . 120)
  (lien . 98)
  (crypt . 99)
  (projet . 112)
  (suspendu . 122)
  (:startgroup lieu)
  (@dehors . 100)
  (:grouptags)
  (@lieu1 . 97)
  (@lieu2 . 118))

 You're missing an :endgroup here -- that's weird.

No, this value was the result of the command « describe-variable 
org-tag-alist-for-agenda »

 Can you pull from the git repo and report if you still have the
 issue you reported?  If so, please add an example I can quickly
 use to reproduce the problem.

The problem is still there in the last git repo :
release_8.0.5-314-g0bab94

My minimal emacs :

--8---cut here---start-8---
(add-to-list 'load-path (expand-file-name ~/.emacs.d/vendor/org-mode/lisp))
(add-to-list 'load-path (expand-file-name 
~/.emacs.d/vendor/org-mode/contrib/lisp))
(add-to-list 'auto-mode-alist '(\\.\\(org\\|org_archive\\|txt\\)$ . org-mode))
(setq org-agenda-files '(~/org/temp.org))
(require 'org)

(global-set-key \C-cl 'org-store-link)
(global-set-key \C-ca 'org-agenda)
(global-set-key \C-cb 'org-iswitchb)

(setq org-tag-alist
(quote
 ((projet . 112)
  (suspendu . 122)
  (:startgroup lieu)
  (@dehors . 100)
  (:grouptags)
  (@lieu1 . 97)
  (@lieu2 . 118)
  (:endgroup lieu
--8---cut here---end---8---

My temp.org :

--8---cut here---start-8---
# -*- mode: org ; coding: utf-8 -*-

* Un:@dehors:
test1

* Deux   :@lieu1:
test2

* Trois  :@lieu2:
test3

* Quatre  :@lieu1:
test4
--8---cut here---end---8---

Maybe, I forget something. Anyway thanks for your investigation.

Maurice



Re: [O] org-odt-export-to-odt: hide text

2013-07-06 Thread Christian Moe

Suvayu Ali writes:

 On Fri, Jul 05, 2013 at 09:26:22PM +0200, Uwe Brauer wrote:
 the issue is I want to write say one paragraph in Spanish
 and the next in German, again spanish then German, etc
 but the odt file should only display one language.

Try drawers:

--8---

#+title: Using drawers to display one language at a time
#+drawers: ENGLISH SPANISH GERMAN
#+options: d:(ENGLISH GERMAN)


:ENGLISH: 
We can use drawers to display one language at a time,
paragraph by paragraph. The Spanish is currently hidden in export.
To display it, add SPANISH to the list after the `d:' option.
:END:

:SPANISH:
¿Que tal?
:END:

:GERMAN:
Wie geht es?
:END:

--8---

Yours,
Christian



[O] text before toc in html export

2013-07-06 Thread henry atting
As the export option `#+TEXT:' is completely ignored I assume that
something has changed. What is now the correct way to insert some
descriptive text before the toc?
I'm using org from git:
Org-mode version 8.0.3 (release_8.0.3-324-gb61ef4)

-- 
web: http://literaturlatenight.de
jabberID: att...@jabber.at




Re: [O] text before toc in html export

2013-07-06 Thread Nicolas Goaziou
Hello,

henry atting s...@online.de writes:

 As the export option `#+TEXT:' is completely ignored I assume that
 something has changed. What is now the correct way to insert some
 descriptive text before the toc?

By default (i.e. with :toc option), TOC is included at the beginning of
the document. You just need to move TOC elsewhere. See #+TOC keyword
documentation in the manual.


Regards,

-- 
Nicolas Goaziou



Re: [O] org-odt-export-to-odt: hide text

2013-07-06 Thread Suvayu Ali
Hello Uwe,

On Sat, Jul 06, 2013 at 10:37:07AM +0200, Uwe Brauer wrote:
 
 While I would like to have some tags which I could toggle on and off,
 for example in the example of Eric, I would just substitute 
 the tag :noexport: for :export:

If you want to use tags, but then say you would prefer not to have
headlines, don't you think it is contradictory?

This kind of expectation has come up again and again over the years in
different forms.  To add meta data to a block of text (which is how I
view tagging, or properties) you either need XML like enclosing tags or
a headline (as Org does), bearing in mind it has to be plain text.  I do
not think there is any other clean way to implement this other than the
way it is presently.

To explain with some examples: Org markup syntax like, *bold*,
/italics/, etc, can be considered XML like enclosing tags (simplified to
a great extent), and tags, properties, TODO keywords, priorities, etc
are examples of the headline based division.

If you or any other user wants this kind of feature, you have to come up
with a syntax that is not intrusive and doesn't break basic Org
features.

Hope this helps you, and future users, better understand the relevant
issues.

Cheers,

-- 
Suvayu

Open source is the future. It sets us free.



Re: [O] How do I create an agenda block for entries with a specific tag?

2013-07-06 Thread Alan Schmitt
Hi Bastien,

b...@gnu.org writes:

 Hi Alan,

 Alan Schmitt alan.schm...@polytechnique.org writes:

 I'm trying to find a way to create an agenda bloc (of type agenda) that
 is restricted to a set of tags. I tried using a skip function but (as I
 explained in another mail) I cannot get it to work. If someone has done
 it before, I'd gladly have a look at how to do it.

 You can try `org-agenda-tag-filter-preset' but I noticed some quirks
 with it, so maybe you'll have a change to report more bugs.

I just gave it a try and it seems to work great. I'll keep my eyes
opened for any potential bug. Thanks again for the suggestion!

Alan



Re: [O] tag groups

2013-07-06 Thread Bastien
Hi Maurice,

Maurice za...@aliceadsl.fr writes:

 No, this value was the result of the command « describe-variable
 org-tag-alist-for-agenda »

Yes -- but somehow the value of this variable is not correctly set.

I will try your minimal example and check, thanks for sharing it.

-- 
 Bastien



Re: [O] text before toc in html export

2013-07-06 Thread henry atting
Nicolas Goaziou n.goaz...@gmail.com writes:

 Hello,

 henry atting s...@online.de writes:

 As the export option `#+TEXT:' is completely ignored I assume that
 something has changed. What is now the correct way to insert some
 descriptive text before the toc?

 By default (i.e. with :toc option), TOC is included at the beginning of
 the document. You just need to move TOC elsewhere. See #+TOC keyword
 documentation in the manual.


 Regards,

Thanks;  did search in the wrong place

henry

-- 
web: http://literaturlatenight.de
jabberID: att...@jabber.at



Re: [O] tag groups

2013-07-06 Thread Bastien
Hi Maurice,

Bastien b...@gnu.org writes:

 I will try your minimal example and check, thanks for sharing it.

I pushed a fix.  Please try against the maint or master branch when
you get a chance.  Thanks for reporting this!

-- 
 Bastien



[O] Can `org-element-map' act on secondary-strings?

2013-07-06 Thread Thorsten Jolitz

Hi List, 

when parsing an Org file with org-element-parse-buffer, headline titles
and section contents (e.g.) end up as secondary strings in the
parse-tree that do have a ':parent' attribute.

When I try to modify all :parent attributes inside a parse-tree with
`org-element-map' (by mapping over all element and object types), the
secondary strings in the parse-tree remain untouched.

Is there a way to make `org-element-map' act on these secondary strings
too? 

-- 
cheers,
Thorsten





Re: [O] [babel] feature request: debug messages

2013-07-06 Thread Andreas Leha
Hi Eric,

Eric Schulte schulte.e...@gmail.com writes:

 Andreas Leha andreas.l...@med.uni-goettingen.de writes:

 Hi Eric,


 Eric Schulte schulte.e...@gmail.com writes:

 Hi Andreas,

 This should be easy to turn on or off using the newly introduced
 :prologue and :epilogue header arguments.  See the manual and the
 following example.

 #+Title: debug messages
 #+Property: session *R*
 #+Property: prologue (format print(\entering %s\) (get-current-name))

 An elisp block to simplify the =:prologue= definition.
 #+begin_src emacs-lisp
   (defun get-current-name ()
 (save-excursion
   (goto-char org-babel-current-src-block-location)
   (while (and (forward-line -1)
   (looking-at org-babel-multi-line-header-regexp)))
   (when (looking-at org-babel-src-name-w-name-regexp)
 (org-no-properties (match-string 3)
 #+end_src

 Two blocks with simple assignments.

 #+name: block-1
 #+begin_src R
   x - 2 + 2
 #+end_src

 #+name: block-2
 #+begin_src R
   y - x + x
 #+end_src

 Execute the whole buffer =C-c C-v b= to see the prologue in action.

 Andreas Leha andreas.l...@med.uni-goettingen.de writes:

 Hi all,

 I would love to see messages like 'entering block foo...' and
 '...leaving block foo' printed to my R console.  This would be very
 handy when I evaluate a subtree (C-c C-v s) with a lot of #+call lines
 and some lengthy ones.

 I know that
 (1) I could implement that myself at in the source blocks.  But I would
 love if orgmode did that for me
 (2) Such messages are already printed to the emacs *Messages* buffer.
 But that buffer might not be visible and I can not switch to it,
 without interrupting the evaluation.  Anyway it would be much nicer
 to see that output together with the other output, that my code
 generates.


 In essence it would be very helpful, if there was a variable
 org-babel-print-debug-messages (or org-babel-debug-level...) which if
 non-nil would cause that messages to be printed.  Or is there somewhere
 already?

 Regards,
 Andreas






 thanks for the quick answer!  The :prologue and :epilogue header
 arguments have indeed slipped my attention and they look really
 interesting!  I see, that they are documented, but somehow, they seem to
 not get their headline and TOC entry?

 I have three problems with your example, though:
 1) It does not run
 2) It does not work
 3) It won't be usable for 'my' epilogue, correct?
 ;-)


 Ah! My fault.  I had to add prologue and epilogue support to ob-R.el
 when working through the example I sent, but then I forgot to commit
 that support to Org-mode.  I've just pushed up that commit, and

Indeed, that fixed it, now it works.

 re-worked my example file to avoid the issue of prologue being applied
 to the emacs-lisp code block (using the very nice and also new
 language-specific PROPERTY header arguments).

Thanks.  So, I did the right thing here.


 Finally, I don't use epilogues in the example because (as the last thing
 evaluated) they would override the code block results.

Ok.  As I thought.  No leaving code block message, then.



 Hopefully the following:
 1. will run
 2. will work
 3. will be usable

Yes.
Yes.
Yes.

I still believe, that there is a bug in the manual, where :epilogue
and :prologue are described.

Tanks a lot for your help and that really nice feature!

Cheers,
Andreas




Re: [O] org-odt-export-to-odt: hide text

2013-07-06 Thread Daniel Clemente
El Sat, 6 Jul 2013 13:03:01 +0200 Suvayu Ali va escriure:
 
 If you or any other user wants this kind of feature, you have to come up
 with a syntax that is not intrusive and doesn't break basic Org
 features.
 

  I created such a syntax for normal text files [1] but have been struggling to 
port it to Org, mainly because of the „header“ concept.
  I want translatable content in headers and text inside headers but without 
ever having to distort the outline structure (e.g. duplicate headers, missing 
titles, …).
  I see two solutions:

  1)
  If only we had „part-of-line drawers“ we could annotate titles directly:

* @ENGLISH{Section 1} @SPANISH{Sección 1}
:ENGLISH:
Section 1 is in English
:ENGLISH:

:SPANISH:
La sección 1 está en español
:SPANISH:

** 123
etc. (more translatable content)
** 456

  2)
  We could do the same with a property which means „if drawer X is visible, use 
this property's value as the title of this section“. E.g.:

* the first section (this title isn't used)
  :PROPERTIES:
  :TITLE_ENGLISH: Section 1
  :TITLE_SPANISH: Sección 1
  :END:

:ENGLISH:
Section 1 is in English
:ENGLISH:

:SPANISH:
La sección 1 está en español
:SPANISH:

** 123
etc. (more translatable content)
** 456



  Just some ideas for anyone who has the time to come up with a multilingual 
export engine.


[1]: http://www.danielclemente.com/dislines/syntax.en.html



Re: [O] Can `org-element-map' act on secondary-strings?

2013-07-06 Thread Nicolas Goaziou
Hello,

Thorsten Jolitz tjol...@gmail.com writes:

 when parsing an Org file with org-element-parse-buffer, headline titles
 and section contents (e.g.) end up as secondary strings in the
 parse-tree that do have a ':parent' attribute.

 When I try to modify all :parent attributes inside a parse-tree with
 `org-element-map' (by mapping over all element and object types), the
 secondary strings in the parse-tree remain untouched.

 Is there a way to make `org-element-map' act on these secondary strings
 too? 

I'm not sure to understand your question.

Secondary string is not an object type, so you cannot explicitly
search for them in a parse tree.

Also, secondary strings do not have a :parent property (or any property
whatsoever: they are just lists).

Though, if you map over objects, e.g., bold text, `org-element-map' will
also look for them within secondary lists.


HTH,

-- 
Nicolas Goaziou



Re: [O] org-odt-export-to-odt: hide text

2013-07-06 Thread Eric Abrahamsen
Daniel Clemente n142...@gmail.com writes:

 El Sat, 6 Jul 2013 13:03:01 +0200 Suvayu Ali va escriure:
 
 If you or any other user wants this kind of feature, you have to come up
 with a syntax that is not intrusive and doesn't break basic Org
 features.
 

   I created such a syntax for normal text files [1] but have been
 struggling to port it to Org, mainly because of the „header“ concept.
   I want translatable content in headers and text inside headers but
 without ever having to distort the outline structure (e.g. duplicate
 headers, missing titles, …).
   I see two solutions:

   1)
   If only we had „part-of-line drawers“ we could annotate titles directly:

 * @ENGLISH{Section 1} @SPANISH{Sección 1}
 :ENGLISH:
 Section 1 is in English
 :ENGLISH:

 :SPANISH:
 La sección 1 está en español
 :SPANISH:

 ** 123
 etc. (more translatable content)
 ** 456

   2)
   We could do the same with a property which means „if drawer X is
 visible, use this property's value as the title of this section“.
 E.g.:

 * the first section (this title isn't used)
   :PROPERTIES:
   :TITLE_ENGLISH: Section 1
   :TITLE_SPANISH: Sección 1
   :END:

 :ENGLISH:
 Section 1 is in English
 :ENGLISH:

 :SPANISH:
 La sección 1 está en español
 :SPANISH:

 ** 123
 etc. (more translatable content)
 ** 456



   Just some ideas for anyone who has the time to come up with a multilingual 
 export engine.


 [1]: http://www.danielclemente.com/dislines/syntax.en.html

I came up with the basics of an automated translation system, that could
be turned into this. The problem is that I only work from Chinese to
English, so I never got around to multilingual support, nor does it
support tagging or blocking out specific strings to translate.

You put your translation table in an org table, and there's a command to
slurp that into a hashtable. The translation commands just whizz through
the text and swap strings, basically. You can do subtree/region/file,
tag subtrees to translate or not to translate, and there are interactive
(a la query-replace) and noninteractive (for use as an export hook)
versions.

Work on it stalled because I do less translation these days. The core of
it's fairly solid, though, and I'd be happy to push it in whatever
direction people would find useful. The next step would be settling on
syntax: right now you can just leave arbitrary strings in the text, and
anything that matches a term from the dictionary will get translated.
That's only useful when you're essentially just translating a whole file
from one language into another. I'll take a look at the syntax link
above.

Yours,
Eric




[O] TODO list sorted across categories

2013-07-06 Thread Edward DeMeulle
I'd like to be able to produce a TODO list that is sorted by timestamp
independently of category. I'm still new to elisp and so don't yet
understand all the code involved. What I've been able to do so far is
create a separate version of org-todo-list by changing a single line:

  (org-set-sorting-strategy 'timestamp-up) ; was 'todo

however that appears to sort by timestamp within categories, not
across. Is there a relatively simply way to have org-todo-list ignore
categories?