Re: [O] Ever used org-mode contrib packages?

2012-04-12 Thread Christian Moe

On 4/11/12 10:46 PM, Martyn Jago wrote:

suvayu alifatkasuvayu+li...@gmail.com  writes:


Hi François,

On Wed, Apr 11, 2012 at 21:22, François Allissonfranc...@allisson.co  wrote:

I'm curious
to know what you are using from org-contrib...


- org-contacts
- org-collector (for some projects)

Yours,
Christian




[O] 403 Forbidden link from FAQ

2012-04-12 Thread Elias Assarsson

Hi

I do not know if this is the appropriate place to report this but at 
http://orgmode.org/worg/org-faq.html#unicorn there is a link to 
http://orgmode.org/img/ which is 403 Forbidden.




Re: [O] var expansion on tangling only once per file

2012-04-12 Thread Rainer M Krug
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 11/04/12 16:15, Eric Schulte wrote:
 This is not currently possible, and any conceivable implementation would be 
 necessarily complex
 requiring a good deal of cross-buffer coordination.

Ok - then I know why I haven't realised this before: I mover the variable 
definition from a header
argument to the #+PROPERTY: as I need the variable throughout the document.

 
 Would it be possible to simply only declare the variable in a header argument 
 applying to the
 first code block?  Using a session would keep that variables state through 
 all subsequent code
 blocks.

Would work - but as I said above, I would have preferred to have the variable 
defined at the top
of the buffer. I could use though the no-expand header argument for the source 
blocks. At the moment,

I am putting them in a subtree and set the property for the subtree.

Thanks,

Rainer

 
 Best,
 
 Rainer M Krug r.m.k...@gmail.com writes:
 
 Hi
 
 I have a file wide variable defined and tangle several source blockd into 
 one file.
 
 BNo the variable is expanded in each block.
 
 Would it be possible to have the expansion at the beginning of the file and 
 nod be repeated,
 as this can cause problems?
 
 The following org code
 
 #+PROPERTY: tangle test.R #+PROPERTY: var TheVar=99
 
 * Part one #+begin_src R :tabgle: x - 1 #+end_src * Problem #+begin_src R y 
 - list( x = 1, 
 #+end_src * Problem continued #+begin_src R x - 3 ) #+end_src
 
 results in an error in R due to the repeated TheVar - 99 in the list 
 definition.
 
 Org-mode version 7.8.08 (release_7.8.07.213.ge6fdf) from git this morning
 
 If I remember correctly, this sneeked in quite recently.
 
 Thanks,
 
 Rainer
 


- -- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
UCT), Dipl. Phys.
(Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :   +33 - (0)9 53 10 27 44
Cell:   +33 - (0)6 85 62 59 98
Fax :   +33 - (0)9 58 10 27 44

Fax (D):+49 - (0)3 21 21 25 22 44

email:  rai...@krugs.de

Skype:  RMkrug
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk+GhxoACgkQoYgNqgF2egrcqQCePx4ZlpftV2beNY7MJzoaRLR4
QzsAnRc8hNF85DIlpETRFIeQWP2aBV0V
=zLBp
-END PGP SIGNATURE-



[O] feature request: re-compute cache without evaluation

2012-04-12 Thread Henning Redestig
Hi,

I write many source blocks that take a fairly long time to execute
(several minutes). Sometimes I find myself wanting to do cosmetic
changes to the code, that I know (for sure) do not change the output,
after the first evaluation. Unfortunately, after having made these
changes the cache obviously does not match the code anymore and I have
to re-evaluate to update the cache. I know it goes against the strict
'reproducible research' idea but still I would like to be able to
re-compute the cache without actually evaluating the block as it is
not efficient to re-evaluate for the sole purpose of updating the
cache.

What do you think?


-- 
/Henning



Re: [O] 403 Forbidden link from FAQ

2012-04-12 Thread Yagnesh Raghava Yakkala

Hello Elias,

Elias Assarsson fte08...@student.lu.se writes:

 Hi

 I do not know if this is the appropriate place to report this but at
 http://orgmode.org/worg/org-faq.html#unicorn there is a link to
 http://orgmode.org/img/ which is 403 Forbidden.

I think directory listing is forbidden on org website.(for security reasons)

if you like to download psd or svg formats, follow the links
http://orgmode.org/img/org-mode-unicorn.psd
http://orgmode.org/img/org-mode-unicorn.svg

that said, it would be good to have direct links

Thanks.,
-- 
YYR



Re: [O] several sub-TODOs with shifted date possible with a single custom-command?

2012-04-12 Thread Markus Hetzmannseder
Hi, 

for the 2nd part I found already a usable solution. Its working by setting a 
top-level tag with the name of the cow. That gets displayed at the Android-App 
agenda view as well, just hat to shift the whole task tree to get a new single 
top-level one for each cow.

Markus

 Markus Hetzmannseder  04/11/12 12:46 PM 
snip

2) I would really like to use the MobileOrg app on my android phone with this. 
But on the phone i can't see the context of a todo-task. In the normal emacs 
agenda i see the filename (=name of the cow) and the days I am past of some 
schedule-start. Any hints how i could get that context visible at the MobileOrg 
agenda-view too?

thx a lot
Markus








Re: [O] table of contents and numbers

2012-04-12 Thread Julian Burgos
Thanks for the answer Nick.  So to get a TOC without numbers I would 
need to edit the TEX file directly, right?


On mið 11.apr 2012 19:00, John Hendy wrote:

On Wed, Apr 11, 2012 at 12:12 PM, Nick Dokosnicholas.do...@hp.com  wrote:

Julian Burgosjul...@hafro.is  wrote:


Dear list,

My apologies for another very basic question.  I'm wondering why I do
not get a table of contents when exporting the following file as pdf

---start org file ---
#+TITLE: Test
#+OPTIONS:  toc:t num:nil

* Part 1
Some text

* Part 2
Some more text
---end org file ---

I do get the TOC when exporting as hmtl, though.


I believe it's because of a rather technical latex limitation: latex
writes TOC entries into a .toc file, which is then read back in when the
\tableofcontents macro is expanded. When you specify num:nil asking for
unnumbered sections, the latex exporter produces \section* markers,
instead of the standard \section markers. But when latex processes
those, it does not add anything to the .toc file. If org added a
\tableofcontents, you would get just the title and an empty TOC. In
order to prevent that, the latex exporter requires that both toc and num
be non-nil - see l.1487 ff in lisp/org-latex.el:

,
|  ...
|  ;; table of contents
|  (when (and org-export-with-toc
|   (plist-get opt-plist :section-numbers))
|(funcall org-export-latex-format-toc-function
| ...))
`

One can work around this by manually adding sections under each headline.

-
#+options: num:nil toc:t

#+text: \tableofcontents

* Introduction
\addcontentsline{toc}{section}{Introduction}
-

Tedious for long documents, but does work.


John


The HTML exporter does this by hand, so to speak, so it is not as
constrained and can do the right thing.

Nick






--
Julian Mariano Burgos, PhD
Hafrannsóknastofnunin/Marine Research Institute
Skúlagata 4, 121 Reykjavík, Iceland
Sími/Telephone : +354-5752037
Bréfsími/Telefax:  +354-5752001
Netfang/Email: jul...@hafro.is




Re: [O] [babel] Literate Programming for publication

2012-04-12 Thread Olaf.Hamann

Torsten Wagnertorsten.wag...@gmail.com  writes:


How can I manage to use different code blocks (latex and python) but
still be able to inject results from python into the latex code
blocks? noweb and vars looked good but it did not work for me.


Hi Torsten,
chapter 14.8.2.1 of the Org Mode Manual shows in detail how one can use 
result output from one src block as header argument :var  input (input 
may be a org table, list, codeblock with arguments (!) , literal or even 
emacs lisp).

Does that fit your needs?
Could you give a concrete example with your requirements, that I could 
play with, say over weekend?
I'm just a beginner with org-babel, but very interested in using LP in 
real project stuff.


Greetings, Olaf









Re: [O] [babel] would like to to do simple text block expansion with parameters or multiline macro replacement text

2012-04-12 Thread Olaf.Hamann

Am 07.04.2012 19:22, schrieb Olaf.Hamann:

Hello all,

Is there an easy way to do a simple text block expansion with
parameters, I mean sth like this:

#+begin_src xsl :tangle outputfile :noweb tangle
{{{gCV(argument1,param2)}}}
#+end_src

#+MACRO: gCV replacement text...
...spread over different...
...multiple lines with arguments like $1 ...
...and $2 and so on...
...
#+end_macro



I think I will try to adapt m4 as org-language so that it can be used 
for executing src-blocks.

That may fit my needs and #+MACRO stays good for oneline replacement



Re: [O] var expansion on tangling only once per file

2012-04-12 Thread Olaf.Hamann

Am 12.04.2012 09:41, schrieb Rainer M Krug:


On 11/04/12 16:15, Eric Schulte wrote:

Would it be possible to simply only declare the variable in a header argument 
applying to the
first code block?  Using a session would keep that variables state through all 
subsequent code
blocks.


Would work - but as I said above, I would have preferred to have the variable 
defined at the top
of the buffer. I could use though the no-expand header argument for the source 
blocks. At the moment,


What about :

#+NAME var-as-literal-block
#+BEGIN_EXAMPLE
99
#+END_EXAMPLE


#+begin_src ...  :var TheVar=var-as-literal-block
...using TheVar in code
#+end_src


I would prefer using Macros in this case :

#+MACRO: TheVar 99

#+begin_src ... :var TheVar={{{TheVar}}}
...using TheVar in code
#+end_src


But looks like that macros do not expand in src_block header arguments.

Regards, Olaf



Re: [O] org-mime-htmlize: visual representation (thunderbird)

2012-04-12 Thread Uwe Brauer
 On Wed, 11 Apr 2012 09:38:46 -0400, Eric Schulte eric.schu...@gmx.com 
 wrote:

Hi Uwe,
Uwe Brauer o...@mat.ucm.es writes:


OK, for my own edification I had changed the message body from
(I'm hoping these are sufficiently quoted to survive mailing)

,[original]
| 
| 
|   text alternative...
| 
| html alternative... |

|   images for html...
`

to

,[revised (and more broken in TB)]
| 
| 
|   text alternative...
| 
|

|   html alternative...
|   images for html...
| 
| 
`

which wraps the html and images into a multipart/related type.

Why is this later structure illegal?  Are nested multi type parts not
allowed?  Also, it seems that everything I've tried works in gnus and in
most web user agents.  Is thunderbird simply a stickler for the letter
of the RFC law?


I cannot answer this. However I rechecked everything and the
issue is the following.

Which brings me to the good news. After I wrote to you
I received a message from the TB developers which
emphasised that, besides the information I have gave
you, the main point is the header, which should be

Content-type: multipart/related; boundary==-=-=
and the thunderbird developers insist that this is the 
RFC 2387 standard.

Gnus actually generate  via the mml-generate-mime function
the header 
Content-type: multipart/mixed; boundary==-=-=
which is wrong.


OK, I've just reverted my change, but I'm keeping the change of image
disposition to inline.


I own you an apology!  If I leave mml-generate-mime
untouched, that is I neither use my modification nor do I
use  use Lars new code, but  I use your *new* code then the
generated and sent message is displayed *correctly* in
thunderbird.

The resulting  message contains 

Content-type: multipart/alternative; boundary==-=-=

Instead of 

Content-type: multipart/related; boundary==-=-=

As it would in my case, but it seems that thunderbird is OK
with that.

The reason I wrote you earlier that your changes made things
worse was that I did make a mistake in my modification of
mml-generate-mime. I also thought I checked your code with
the old mml function but  for some reason the old version was
not used even after a restart.

Sorry for the trouble!

Uwe 




[O] icalendar export skips todos with a scheduled time-range

2012-04-12 Thread Sébastien Delafond
Hello,

From Debian bug #668496[0]:

  If I have an org-file containing a todo with a scheduled date range, like
  this:

  ,[ foo.org ]
*** TODO Weekend with the lads
SCHEDULED: 2012-05-04 Fr--2012-05-08 Di
  `

  and try to export it via org-export-icalendar-this-file, the resulting
  foo.ics will look like this

  ,[ foo.ics ]
BEGIN:VCALENDAR
VERSION:2.0
X-WR-CALNAME:foo
PRODID:-//Friedrich Delgado//Emacs with Org-mode//EN
X-WR-TIMEZONE:Europe/Berlin
X-WR-CALDESC:nil
CALSCALE:GREGORIAN
END:VCALENDAR
  `

  (i.e.: contain no appointments at all)

  I think the responsible section of code may reside in
  /usr/share/emacs23/site-lisp/org-mode/org-icalendar.el, line 360:

  ,
(if (looking-at re2)
(progn
  (goto-char (match-end 0))
  (setq ts2 (match-string 1)
inc (not (string-match [0-9]\\{1,2\\}:[0-9][0-9] ts2
  (setq tmp (buffer-substring (max (point-min)
   (- pos org-ds-keyword-length))
  pos)
ts2 (if (string-match 
[0-9]\\{1,2\\}:[0-9][0-9]-\\([0-9]\\{1,2\\}:[0-9][0-9]\\) ts)
(progn
  (setq inc nil)
  (replace-match \\1 t nil ts))
  ts)
deadlinep (string-match org-deadline-regexp tmp)
scheduledp (string-match org-scheduled-regexp tmp)
todo (org-get-todo-state)
;; donep (org-entry-is-done-p)
))
  `

  From my basic understanding of the code-flow it looks like re2 ==
  (concat --?-?\\( org-ts-regexp \\)) is meant to match date-ranges,
  but the code in the t branch of the if doesn't set deadlinep,
  schedulep and todo, preventing all further processing of the entry.
  But I may be wrong about the intentions of that function.


Cheers,

--Seb

[0] http://bugs.debian.org/668496




Re: [O] idea, in-line preview link

2012-04-12 Thread peter . frings
Good day all,

On 05 Apr 2012, at 13:55, Christian Moe wrote:

 One of my first Lisp projects was a link type that behaves a bit like what 
 you describe.
 
 I don't bother with placing the snippet inline, though, I just flash it as a 
 message in the minibuffer. But I also leave it on the kill ring, so I can C-y 
 it into my current buffer if I like.

From a UX pov, changing the clipboard/kill-ring behind the user’s back is a bad 
thing to do, especially when the intention of the user action is only to have a 
quick look at that link. Suppose org-mode copied a whole sub-tree when all you 
did was to expand it... just in case you wanted to copy a piece of it.

In my opinion, it’s better to provide an explicit command to 
copy/insert/open/... the content of that link.

Cheers,
Peter.




[O] change single occurrence of repeating event

2012-04-12 Thread Andreas Leha
Hi all,

this is a basic (I think) question about repeating events.

I am looking for an equivalent to other calendar's change this specific
occurrence option.


Here is an example.

Assume, I have a repeating event, like a commute:

#+begin_src org
*** Train From Office 2012-01-02 Mo 15:49-17:07 +1w
#+end_src

Quite often, I need to change that:
1. because I am not commuting (holidays/conference/...)
2. an important meeting postpones the commute

As I aim for the same commuting times every day, I want
1. the repeating event to show in my agenda by default
2. the flexibility to delete or change single occurrences of that
   event.

How would be the best way to accomplish both?

Thanks in advance,
Andreas




Re: [O] org-yank improvement?

2012-04-12 Thread Thorsten
Bastien b...@gnu.org writes:

Hi Bastien,

 Thorsten quintf...@googlemail.com writes:

 Memnon Anon gegendosenflei...@googlemail.com writes:

 pin...@iro.umontreal.ca (François Pinard) writes:

 However, by mistake, it happens that the cursor is on the only visible
 bullet star of the next heading  instead of really being at the start
 of the line. 

 I recently edited some org files in clean mode for the first time (It
 might be the default mode on Worg?) and was surprised and a bit confused
 that my cursor(point) was invisible when on the invisible bullet stars
 at the beginning of the line. 
 I had to move point to the (only) visible bullet star on the line to find out
 where I am in the buffer. Maybe only a peculiarity of my color-settings,
 but nevertheless convincing me not to use clean mode. 

 Then we should fix org-indent.el accordingly.

 (Please avoid Clean mode as a way to refer to org-indent, it suggests
 other views are not clean!  Maybe the doc should be updated wrt this.)

 I must confess I'm not a user of org-indent.  I have been testing it a
 few times and always had the feeling it goes against Org's What You See
 is What You Have core principle.  But let's fix bugs in it anyway.

It might not really be a bug. I just double-checked in both my console
and my X11 session, and the symptom only appears in the console session
(overlays not visible?). 

So, on a user level, the solution might be to activate org-indent-mode
conditional of the display type, something like this:

,---
| (defun my-org-indent-conditional-activation-function ()
| Activates org-indent-mode conditional on the display type.
| (if (display-graphic-p)
|   (setq org-indent-mode t)))
`---

If Emacs is used 'the standard way', call this function once in your
.emacs should suffice. When using one Emacs daemon with many Emacsclients
in console as well as X11 sessions (as I do), this function should be
added to the server-visit-hook, so each emacsclient acts conditional on
the display-type of his session. 

-- 
cheers,
Thorsten



Re: [O] org-yank improvement?

2012-04-12 Thread Thorsten
Bastien b...@altern.org writes:

 Bernt Hansen be...@norang.ca writes:

 Carsten Dominik carsten.domi...@gmail.com writes:

 On 11.4.2012, at 08:38, Bastien wrote:

 I must confess I'm not a user of org-indent.  I have been testing it a
 few times and always had the feeling it goes against Org's What
 You See
 is What You Have core principle.  But let's fix bugs in it anyway.

 For what it is worth, I constantly use it.

 - Carsten

 Me too! 

 Okay -- a great relief to know I can count on Carsten and you 
 to help solve possible issues there!

I just posted a proposal how to activate org-indent conditional on the
sessions display-type, since the irritating behaviour I had only happens
in a console session, so I guess some overlays involved are only visible
in X11. 

i must admit I never used org-indent since I prefer book-like headlines,
I only had the problem of an unvisible cursor when editing Worg pages
(probably in a console session without being aware of that fact). 

-- 
cheers,
Thorsten



Re: [O] feature request: re-compute cache without evaluation

2012-04-12 Thread Eric Schulte
Henning Redestig henning@googlemail.com writes:

 Hi,

 I write many source blocks that take a fairly long time to execute
 (several minutes). Sometimes I find myself wanting to do cosmetic
 changes to the code, that I know (for sure) do not change the output,
 after the first evaluation. Unfortunately, after having made these
 changes the cache obviously does not match the code anymore and I have
 to re-evaluate to update the cache. I know it goes against the strict
 'reproducible research' idea but still I would like to be able to
 re-compute the cache without actually evaluating the block as it is
 not efficient to re-evaluate for the sole purpose of updating the
 cache.

 What do you think?

Press C-c C-v a (org-babel-sha1-hash) in the code block, then manually
replace the original hash with the hash returned by that function.

-- 
Eric Schulte
http://cs.unm.edu/~eschulte/



Re: [O] org-mime-htmlize: visual representation (thunderbird)

2012-04-12 Thread Eric Schulte
Uwe Brauer o...@mat.ucm.es writes:

 On Wed, 11 Apr 2012 09:38:46 -0400, Eric Schulte eric.schu...@gmx.com 
 wrote:

 Hi Uwe,
 Uwe Brauer o...@mat.ucm.es writes:
 

 OK, for my own edification I had changed the message body from
 (I'm hoping these are sufficiently quoted to survive mailing)

 ,[original]
 | 
 | 
 |   text alternative...
 | 
 | html alternative... |

 |   images for html...
 `

 to

 ,[revised (and more broken in TB)]
 | 
 | 
 |   text alternative...
 | 
 |

 |   html alternative...
 |   images for html...
 | 
 | 
 `

 which wraps the html and images into a multipart/related type.

 Why is this later structure illegal?  Are nested multi type parts not
 allowed?  Also, it seems that everything I've tried works in gnus and in
 most web user agents.  Is thunderbird simply a stickler for the letter
 of the RFC law?


 I cannot answer this. However I rechecked everything and the
 issue is the following.
 
 Which brings me to the good news. After I wrote to you
 I received a message from the TB developers which
 emphasised that, besides the information I have gave
 you, the main point is the header, which should be
 
 Content-type: multipart/related; boundary==-=-=
 and the thunderbird developers insist that this is the 
 RFC 2387 standard.
 
 Gnus actually generate  via the mml-generate-mime function
 the header 
 Content-type: multipart/mixed; boundary==-=-=
 which is wrong.
 

 OK, I've just reverted my change, but I'm keeping the change of image
 disposition to inline.


 I own you an apology!  If I leave mml-generate-mime
 untouched, that is I neither use my modification nor do I
 use  use Lars new code, but  I use your *new* code then the
 generated and sent message is displayed *correctly* in
 thunderbird.

 The resulting  message contains 

 Content-type: multipart/alternative; boundary==-=-=

 Instead of 

 Content-type: multipart/related; boundary==-=-=

 As it would in my case, but it seems that thunderbird is OK
 with that.

 The reason I wrote you earlier that your changes made things
 worse was that I did make a mistake in my modification of
 mml-generate-mime. I also thought I checked your code with
 the old mml function but  for some reason the old version was
 not used even after a restart.

 Sorry for the trouble!

 Uwe 


Hi Uwe,

No problem at all.  I just reverted by reversion in git, so if I read
this email correctly everything should be working now in TB.  Please let
me know if this is not the case.

Thanks,

-- 
Eric Schulte
http://cs.unm.edu/~eschulte/



Re: [O] multiple date_tree values possible in a single file

2012-04-12 Thread Stuart McLean
Hi, Nick

I have expressed myself poorly. It is not so much what I can not get to
work. It is more is such-and-such possible. I would like to have two headings
in one file, and to be able to use `org-capture' to file notes under
each of them
in a date-tree. I know you can file notes under an individual heading
using the DATE_TREE property, but how would you use this for two
different headings?

I hope this is a little more clear,

Stuart

On 4/11/12, Nick Dokos nicholas.do...@hp.com wrote:
 Stuart McLean smclean0...@gmail.com wrote:

 Hello, everyone

 I really like the date tree hierarchy. I was wondering whether it was
 possible to use
 multiple date_tree hierarchies in a single file, or how one would go
 about setting it up.

 For example

 * Items TODO
 ** tree 1
:PROPERTIES:
:DATE_TREE: t
:END:
 ** tree 2
:PROPERTIES:
:DATE_TREE: t
:END:

 I don't think i can get this to work. Any suggestions?


 I'm not sure what you mean: what exactly can you not get to work?

 Nick





Re: [O] table of contents and numbers

2012-04-12 Thread Nick Dokos
Julian Burgos jul...@hafro.is wrote:

 Thanks for the answer Nick.  So to get a TOC without numbers I would
 need to edit the TEX file directly, right?
 

You could do that, but you could also use John's idea below to add
\addcontentsline after each heading in the org file.

Nick

 On mið 11.apr 2012 19:00, John Hendy wrote:
  On Wed, Apr 11, 2012 at 12:12 PM, Nick Dokosnicholas.do...@hp.com  wrote:
  Julian Burgosjul...@hafro.is  wrote:
 
  Dear list,
 
  My apologies for another very basic question.  I'm wondering why I do
  not get a table of contents when exporting the following file as pdf
 
  ---start org file ---
  #+TITLE: Test
  #+OPTIONS:  toc:t num:nil
 
  * Part 1
  Some text
 
  * Part 2
  Some more text
  ---end org file ---
 
  I do get the TOC when exporting as hmtl, though.
 
  I believe it's because of a rather technical latex limitation: latex
  writes TOC entries into a .toc file, which is then read back in when the
  \tableofcontents macro is expanded. When you specify num:nil asking for
  unnumbered sections, the latex exporter produces \section* markers,
  instead of the standard \section markers. But when latex processes
  those, it does not add anything to the .toc file. If org added a
  \tableofcontents, you would get just the title and an empty TOC. In
  order to prevent that, the latex exporter requires that both toc and num
  be non-nil - see l.1487 ff in lisp/org-latex.el:
 
  ,
  |  ...
  |  ;; table of contents
  |  (when (and org-export-with-toc
  |   (plist-get opt-plist :section-numbers))
  |(funcall org-export-latex-format-toc-function
  | ...))
  `
  One can work around this by manually adding sections under each headline.
 
  -
  #+options: num:nil toc:t
 
  #+text: \tableofcontents
 
  * Introduction
  \addcontentsline{toc}{section}{Introduction}
  -
 
  Tedious for long documents, but does work.
 
 
  John
 
  The HTML exporter does this by hand, so to speak, so it is not as
  constrained and can do the right thing.
 
  Nick
 
 
 
 
 
 -- 
 Julian Mariano Burgos, PhD
 Hafrannsóknastofnunin/Marine Research Institute
 Skúlagata 4, 121 Reykjavík, Iceland
 Sími/Telephone : +354-5752037
 Bréfsími/Telefax:  +354-5752001
 Netfang/Email: jul...@hafro.is
 
 



Re: [O] org-yank improvement?

2012-04-12 Thread Nicolas Goaziou
Hello,

Thorsten quintf...@googlemail.com writes:

 I just posted a proposal how to activate org-indent conditional on the
 sessions display-type, since the irritating behaviour I had only happens
 in a console session, so I guess some overlays involved are only visible
 in X11.

There are no overlays involved in Org Indent mode.

You may want to customize `org-indent-mode-turns-on-hiding-stars' (or
use #+STARTUP: showstars) instead of completely disabling org-indent for
console sessions.


Regards,

-- 
Nicolas Goaziou



Re: [O] feature request: re-compute cache without evaluation

2012-04-12 Thread Henning Redestig
ah, this was easy, thanks!

2012/4/12 Eric Schulte eric.schu...@gmx.com:
 Henning Redestig henning@googlemail.com writes:

 Hi,

 I write many source blocks that take a fairly long time to execute
 (several minutes). Sometimes I find myself wanting to do cosmetic
 changes to the code, that I know (for sure) do not change the output,
 after the first evaluation. Unfortunately, after having made these
 changes the cache obviously does not match the code anymore and I have
 to re-evaluate to update the cache. I know it goes against the strict
 'reproducible research' idea but still I would like to be able to
 re-compute the cache without actually evaluating the block as it is
 not efficient to re-evaluate for the sole purpose of updating the
 cache.

 What do you think?

 Press C-c C-v a (org-babel-sha1-hash) in the code block, then manually
 replace the original hash with the hash returned by that function.

 --
 Eric Schulte
 http://cs.unm.edu/~eschulte/



-- 
/Henning



Re: [O] multiple date_tree values possible in a single file

2012-04-12 Thread Nick Dokos
Stuart McLean smclean0...@gmail.com wrote:

 Hi, Nick
 
 I have expressed myself poorly. It is not so much what I can not get to
 work. It is more is such-and-such possible. I would like to have two 
 headings
 in one file, and to be able to use `org-capture' to file notes under
 each of them
 in a date-tree. I know you can file notes under an individual heading
 using the DATE_TREE property, but how would you use this for two
 different headings?
 
 I hope this is a little more clear,
 
Yes, thanks!

The docs seem to imply that you cannot do that indeed: the file+datetree
target takes a filename arg, but no heading arg, and afaik they all end
up in the same date tree, i.e. the date tree provides the top level
structure. Cursory experimentation confirms that, but I may have missed
something.

Nick




Re: [O] bug with org-mode-hook and text-scale-set

2012-04-12 Thread Matt Lundin
Bastien b...@gnu.org writes:

 Du Yanning duyann...@gmail.com writes:

 text-mode-hook and c-mode-hook do NOT have this bug.
 and the org-mode-hook of orgmode shipped within emacs 23.3 does NOT
 have this bug.

 This is now fixed, thanks.

 The problem was that Org relied on `face-remapping-alist' to 
 remap the 'default face to the 'org-default face.  Relying on 
 this mechanism produces the error you reported, because the 
 text-scale-set doesn't interact well with remapped faces.

 I'm now relying on `buffer-face-mode' which seems to be a 
 cleaner approach.

On my machine, this change causes a noticeable lag when typing in
org-mode buffers. The cursor hesitates for a bit and then lurches
forward. If I turn off buffer-face-mode the lag disappears. I'm still
figuring out how to diagnose the problem.

Best,
Matt



[O] Killed Org files referred from the agenda?

2012-04-12 Thread François Pinard
Hi, Org people!

Now that many Org files are part of my agenda list, it became more
likely that I inadvertently kill one of them.  Then, commands like t
or RET in the agenda fail.

--8---cut here---start-8---
Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil)
  goto-char(nil)
  (let* ((marker ...) (buffer ...) (pos ...)) (org-pop-to-buffer-same-window 
buffer) (and delete-other-windows (delete-other-windows)) (widen) (goto-char 
pos) (when (eq major-mode ...) (org-show-context ...) (save-excursion ...) 
(when ... ...)))
  (if (and org-return-follows-link (not ...) (org-in-regexp 
org-bracket-link-regexp)) (org-open-link-from-string (match-string 0)) (let* 
(... ... ...) (org-pop-to-buffer-same-window buffer) (and delete-other-windows 
...) (widen) (goto-char pos) (when ... ... ... ...)))
  org-agenda-switch-to()
  call-interactively(org-agenda-switch-to nil nil)
--8---cut here---end---8---

I have to first revisit the Org file by some other mean first, for such
commands to succeed.  Could Org do the revisiting as needed, instead of
raising an error?

François



Re: [O] Strange extra-space when using yasnippet for Org-mode heading

2012-04-12 Thread Jason Dunsmore
On Tue, Apr 10 2012, Karl Voit wrote:

 When I invoke the snippet using »test« followed by the TAB key,
 yasnippet correctly inserts the template. But after pressing the
 first key afterwards, I get an extra space character.

 So with »test« followed by TAB, »foo«, TAB, »bar«, I get this:

 ,[ result with extra-space after »f« ]
 | ** f oo bar   :f oobar:
 | Cursor
 `

 I am not even sure if this is an Org-mode related problem at all.
 But since I do *not* end up with extra space characters when I
 modify the template so that the two asterisks are missing (no
 heading), I am afraid that Org-mode has a problem with yasnippet (at
 least at my side).

Are you using org-indent-mode?  If so, maybe what you're seeing is
related to this outstanding bug:
http://lists.gnu.org/archive/html/emacs-orgmode/2011-08/msg01059.html

Jason



Re: [O] Running org-babel-tangle and/or org-export-as-pdf in Emacs batch mode

2012-04-12 Thread Bernd Weiss
On 11.04.2012 16:14, Eric Schulte wrote:

[...]

 Hi Bernd,
 
 I can't recreate this hanging issue locally (I don't have access to a
 windows box).  This sounds like an ESS issue to me since ESS seems to be
 the hanging process.  Perhaps a good first step would be to try to
 evaluate (require 'ess) (R) in a batch Emacs session without Emacs
 hanging.  Once this is working then it should be clear how to run ESS
 sessions from code blocks.
 

Eric,

Thanks for your answer!

I am not sure if you had the following in mind but it again causes Emacs
to hang:

emacs -batch -l e:/config/.emacs --visit test.R --eval=(progn (require
'ess) (R) (ess-eval-buffer))


This is test.R

 test.R --
pdf(testplot.pdf)
hist(rnorm(100))
dev.off()
 test.R --


I wrote another email to the ESS list, which is currently awaiting
moderator approval.

However, I am still wondering that I seem to be the first person to
stumble upon this problem...

Thanks,

Bernd



Re: [O] Killed Org files referred from the agenda?

2012-04-12 Thread Nick Dokos
François Pinard pin...@iro.umontreal.ca wrote:

 Hi, Org people!
 
 Now that many Org files are part of my agenda list, it became more
 likely that I inadvertently kill one of them.  Then, commands like t
 or RET in the agenda fail.
 
 Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil)
   goto-char(nil)
   (let* ((marker ...) (buffer ...) (pos ...)) (org-pop-to-buffer-same-windo=
 w buffer) (and delete-other-windows (delete-other-windows)) (widen) (goto-c=
 har pos) (when (eq major-mode ...) (org-show-context ...) (save-excursion .=
 ..) (when ... ...)))
   (if (and org-return-follows-link (not ...) (org-in-regexp org-bracket-lin=
 k-regexp)) (org-open-link-from-string (match-string 0)) (let* (... ... ...)=
  (org-pop-to-buffer-same-window buffer) (and delete-other-windows ...) (wid=
 en) (goto-char pos) (when ... ... ... ...)))
   org-agenda-switch-to()
   call-interactively(org-agenda-switch-to nil nil)
 
 I have to first revisit the Org file by some other mean first, for such
 commands to succeed.  Could Org do the revisiting as needed, instead of
 raising an error?
 

Just do g in the agenda and retry the t.

Nick




Re: [O] Strange extra-space when using yasnippet for Org-mode heading

2012-04-12 Thread Karl Voit
* Jason Dunsmore jasondunsm...@gmail.com wrote:
 On Tue, Apr 10 2012, Karl Voit wrote:

 When I invoke the snippet using »test« followed by the TAB key,
 yasnippet correctly inserts the template. But after pressing the
 first key afterwards, I get an extra space character.

 So with »test« followed by TAB, »foo«, TAB, »bar«, I get this:

 ,[ result with extra-space after »f« ]
 | ** f oo bar   :f oobar:
 | Cursor
 `

 Are you using org-indent-mode?  

Yes.

 If so, maybe what you're seeing is
 related to this outstanding bug:
 http://lists.gnu.org/archive/html/emacs-orgmode/2011-08/msg01059.html

It is?

Oh. I do not get the relation yet and if I deactivate
«org-startup-indented», I still can reproduce my problem with the
extra space.

Probably I was not able to explain it correctly: I do not mind,
where the tags are being placed. The extra space is *within* the
first word I type. So »foo« gets replaced by »f oo« for example.

-- 
Karl Voit




[O] [babel] using babel for regression testing

2012-04-12 Thread Ilya Shlyakhter

Is there a babel command to do the following:
evaluate all code blocks; for those for which the result is not yet 
recorded in the org file, record the result; for those for which the

result was already recorded, compare the new result with the old result;
flag blocks where there is a difference.

thanks,

ilya




Re: [O] change single occurrence of repeating event

2012-04-12 Thread Karl Voit
* Andreas Leha andreas.l...@med.uni-goettingen.de wrote:
 Hi all,

 this is a basic (I think) question about repeating events.

 I am looking for an equivalent to other calendar's change this specific
 occurrence option.

Please do read the documentation related to
«org-clone-subtree-with-time-shift» where you can «expand» the
recurring events to distinct single events (followed by a recurring
event).

When you got distinct events, you can modify them as you wish.

It is somewhat «the other way round» but meanwhile I really do like
this method very much since I can add notes and so forth to every
single occurrence as well.

-- 
Karl Voit




Re: [O] Killed Org files referred from the agenda?

2012-04-12 Thread François Pinard
Nick Dokos nicholas.do...@hp.com writes:

 François Pinard pin...@iro.umontreal.ca wrote:

 Now that many Org files are part of my agenda list, it became more
 likely that I inadvertently kill one of them.  Then, commands like
 t or RET in the agenda fail.  I have to first revisit the Org
 file by some other mean first, for such commands to succeed.  Could
 Org do the revisiting as needed, instead of raising an error?
 

 Just do g in the agenda and retry the t.

Thanks for hint, Nick, I'll surely use it.

Yet, I do not think it is appropriate for Org to raise an Emacs Lisp
error.  It really looks like a bug.

François



[O] conditional TODOs

2012-04-12 Thread Daniel Krenn
I have the following situation: In a Project someone else has to do
something and I have to wait until that is finished. If it is finished,
then there are several TODOs. How do I that in a clever way? I.e. how to
write that future TODOs, so that they do not appear as TODOs now (e.g.
in the agenda) but only then, when the status of the project is changed
from WAIT (until the other person has finished) to a state where I have
to do something?

Daniel



Re: [O] table of contents and numbers

2012-04-12 Thread Jonas Hörsch

On Thu, Apr 12 2012, Julian Burgos wrote:

 Thanks for the answer Nick.  So to get a TOC without numbers I would
 need to edit the TEX file directly, right?


Hi there,

another option might be to remove the num:nil org option and instead
tell latex not to number any sections by setting secnumdepth to 0.

so for instance

---start org file ---
#+TITLE: Test
#+OPTIONS:  toc:t
#+LATEX_HEADER: \setcounter{secnumdepth}{0}

* Part 1
Some text

* Part 2
Some more text
---end org file ---

should do the trick.

the only drawback is that one still needs the num:nil option for the
other export formats.

perhaps this could become another way to implement num:nil for the latex
export in general. though i don't think it would work reliably for just a
subtree then.

Greets,
Jonas

 On mið 11.apr 2012 19:00, John Hendy wrote:
 On Wed, Apr 11, 2012 at 12:12 PM, Nick Dokosnicholas.do...@hp.com  wrote:
 Julian Burgosjul...@hafro.is  wrote:

 Dear list,

 My apologies for another very basic question.  I'm wondering why I do
 not get a table of contents when exporting the following file as pdf

 ---start org file ---
 #+TITLE: Test
 #+OPTIONS:  toc:t num:nil

 * Part 1
 Some text

 * Part 2
 Some more text
 ---end org file ---

 I do get the TOC when exporting as hmtl, though.

 I believe it's because of a rather technical latex limitation: latex
 writes TOC entries into a .toc file, which is then read back in when the
 \tableofcontents macro is expanded. When you specify num:nil asking for
 unnumbered sections, the latex exporter produces \section* markers,
 instead of the standard \section markers. But when latex processes
 those, it does not add anything to the .toc file. If org added a
 \tableofcontents, you would get just the title and an empty TOC. In
 order to prevent that, the latex exporter requires that both toc and num
 be non-nil - see l.1487 ff in lisp/org-latex.el:

 ,
 |  ...
 |  ;; table of contents
 |  (when (and org-export-with-toc
 |   (plist-get opt-plist :section-numbers))
 |(funcall org-export-latex-format-toc-function
 | ...))
 `
 One can work around this by manually adding sections under each headline.

 -
 #+options: num:nil toc:t

 #+text: \tableofcontents

 * Introduction
 \addcontentsline{toc}{section}{Introduction}
 -

 Tedious for long documents, but does work.


 John

 The HTML exporter does this by hand, so to speak, so it is not as
 constrained and can do the right thing.

 Nick







Re: [O] Killed Org files referred from the agenda?

2012-04-12 Thread Bernt Hansen
pin...@iro.umontreal.ca (François Pinard) writes:

 Nick Dokos nicholas.do...@hp.com writes:

 François Pinard pin...@iro.umontreal.ca wrote:

 Now that many Org files are part of my agenda list, it became more
 likely that I inadvertently kill one of them.  Then, commands like
 t or RET in the agenda fail.  I have to first revisit the Org
 file by some other mean first, for such commands to succeed.  Could
 Org do the revisiting as needed, instead of raising an error?
 

 Just do g in the agenda and retry the t.

 Thanks for hint, Nick, I'll surely use it.

 Yet, I do not think it is appropriate for Org to raise an Emacs Lisp
 error.  It really looks like a bug.

 François

Rebuilding the agenda buffer (with 'g') is potentially expensive -- I
don't want a multi-second delay in my block view whenever Emacs thinks
that is appropriate.

I'd rather have full manual control over when things are rebuilt.  I
think your error is generated because your agenda is out of date so the
markers on the agenda view are old and possibly pointing at the wrong
stuff.  Keeping this up to date automagically will make org-mode much
slower and less usable (for me)

So here's one vote against.

Regards,
Bernt



Re: [O] org-yank improvement?

2012-04-12 Thread Thorsten
Nicolas Goaziou n.goaz...@gmail.com writes:

Hello,

 Thorsten quintf...@googlemail.com writes:

 I just posted a proposal how to activate org-indent conditional on the
 sessions display-type, since the irritating behaviour I had only happens
 in a console session, so I guess some overlays involved are only visible
 in X11.

 There are no overlays involved in Org Indent mode.

 You may want to customize `org-indent-mode-turns-on-hiding-stars' (or
 use #+STARTUP: showstars) instead of completely disabling org-indent for
 console sessions.

Actually, the stars are hidden with this function from org-faces.el, it
seems:

,
| (defface org-hide
|   'background light)) (:foreground white))
| (((background dark)) (:foreground black)))
|   Face used to hide leading stars in headlines.
| The foreground color of this face should be equal to the background
| color of the frame.
|   :group 'org-faces)
`

so the whole issue might be the following:

when using Emacs on the console (at least in my case), the default
colors (-fg black -bg white) are reverted on the display, i.e. the
background is shown black and the (foreground-)text white. Thats exactly
what I want.

To achieve the same in an X11 session, I added a function
to the server-visit-hook that changes -bg to black and -fg to wheat
when emacsclient visits a server file. 

Now what is happening when I open a org-mode buffer in a console
session?

I see a blinking white underscore as cursor/point on a black background.
When I move it over a hidden star, point becomes invisible.  
(background-color-at-point) gives nil.
(foreground-color-at-point) gives 'black' instead of nil like in the
other parts of the buffer, and the black cursor on a black background
becomes invisible. 

In an X11 session, with point on hidden stars, the hidden star becomes
visible again instead, together with the cursor. 
What is the mechanism responsable for that?


-- 
cheers,
Thorsten




Re: [O] Ever used org-mode contrib packages?

2012-04-12 Thread Bernt Hansen
Christian Moe m...@christianmoe.com writes:

 On 4/11/12 10:46 PM, Martyn Jago wrote:
 suvayu alifatkasuvayu+li...@gmail.com  writes:

 Hi François,

 On Wed, Apr 11, 2012 at 21:22, François Allissonfranc...@allisson.co  
 wrote:
 I'm curious
 to know what you are using from org-contrib...

 - org-contacts
 - org-collector (for some projects)

 - org-checklist
 - org-mime

Regards,
Bernt



[O] [beamerposter] How do I suppress frame title?

2012-04-12 Thread Mikhail Titov
Hello!

I’m trying to use orgmode with beamerposter LaTeX package [1] to make a poster. 
I’ve managed to remove toc and override \maketitle . However I can’t seem to 
find a way to suppress a title from the only high level section * Poster. 
I've tried to add :B_ignoreheading: via C-c C-b i with no success :(

Is it possible? It is not a big deal just to remove frametitle from the final 
version but nevertheless.

[1] http://www-i6.informatik.rwth-aachen.de/~dreuw/latexbeamerposter.php

Mikhail






Re: [O] bug with org-mode-hook and text-scale-set

2012-04-12 Thread Matt Lundin
Matt Lundin m...@imapmail.org writes:

 Bastien b...@gnu.org writes:

 Du Yanning duyann...@gmail.com writes:

 text-mode-hook and c-mode-hook do NOT have this bug.
 and the org-mode-hook of orgmode shipped within emacs 23.3 does NOT
 have this bug.

 This is now fixed, thanks.

 The problem was that Org relied on `face-remapping-alist' to 
 remap the 'default face to the 'org-default face.  Relying on 
 this mechanism produces the error you reported, because the 
 text-scale-set doesn't interact well with remapped faces.

 I'm now relying on `buffer-face-mode' which seems to be a 
 cleaner approach.

 On my machine, this change causes a noticeable lag when typing in
 org-mode buffers. The cursor hesitates for a bit and then lurches
 forward. If I turn off buffer-face-mode the lag disappears. I'm still
 figuring out how to diagnose the problem.

Another question: is it customary for major modes to invoke
buffer-face-mode? I was a bit confused when I first saw BufFace in the
mode-line, as I had not explicitly invoked the minor mode. My
understanding was that this was primarily intended as a minor mode for
user-level modifications, not for major modes to rely on (but I may very
well be mistaken).

Best,
Matt



[O] sectioning depth limit on export

2012-04-12 Thread Pedro Silva
I'm having problems over a document with headings down to a depth of 5
export the levels 4 and 5 as \paragraph and \subparagraph, respectively.

My org-export-latex-classes includes the following:
(article \\documentclass[11pt]{article}
 (\\section{%s} . \\section*{%s})
 (\\subsection{%s} . \\subsection*{%s})
 (\\subsubsection{%s} . \\subsubsection*{%s})
 (\\paragraph{%s} . \\paragraph*{%s})
 (\\subparagraph{%s} . \\subparagraph*{%s}))

My source document includes the following:
#+LaTeX_CLASS: article, my org-export-latex-class is article, and my
org-export-latex-sectioning-depth is locally set to 6 (default is 3).

According to the More Highly-Structured Documents subsection of Latex
Export worg tutorial
http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-3

This setup should produce the following document structure, when
exported to LaTeX:

* section
** subsection
*** subsubsection
 paragraph
* subparagraph

However, this is what is produced:

* section
** subsection
*** subsubsection
 itemize
* sub-itemize, etc

This happens with all export types I've tried, namely LaTeX, HTML, and
plain text.  Any ideas about how to force export of 4 and 5-level deep
headings as paragraph and subparagraph headings in LaTeX?
-- 
Pedro



Re: [O] Killed Org files referred from the agenda?

2012-04-12 Thread Nick Dokos
François Pinard pin...@iro.umontreal.ca wrote:

 Nick Dokos nicholas.do...@hp.com writes:
 
  François Pinard pin...@iro.umontreal.ca wrote:
 
  Now that many Org files are part of my agenda list, it became more
  likely that I inadvertently kill one of them.  Then, commands like
  t or RET in the agenda fail.  I have to first revisit the Org
  file by some other mean first, for such commands to succeed.  Could
  Org do the revisiting as needed, instead of raising an error?
  
 
  Just do g in the agenda and retry the t.
 
 Thanks for hint, Nick, I'll surely use it.
 
 Yet, I do not think it is appropriate for Org to raise an Emacs Lisp
 error.  It really looks like a bug.
 

But it is an error: you've gotten rid of a buffer that it expected to
find.  Admittedly however, the error should be caught and a reasonable
error message printed out (something like ``Try pressing g in the
agenda and then retry the command '' :-) ) This would alleviate Bernt's
performance concerns as well: if you make the mistake (kill a buffer
that's needed), you suffer the consequences (slow rebuilding of the
agenda) - it does not affect anybody else.

Maybe org-with-remote-undo can check if the buffer argument is nil and
complain if it is.

Nick




Re: [O] sectioning depth limit on export

2012-04-12 Thread Nick Dokos
Pedro Silva psilva+...@pedrosilva.pt wrote:

 I'm having problems over a document with headings down to a depth of 5
 export the levels 4 and 5 as \paragraph and \subparagraph, respectively.
 
 My org-export-latex-classes includes the following:
 (article \\documentclass[11pt]{article}
  (\\section{%s} . \\section*{%s})
  (\\subsection{%s} . \\subsection*{%s})
  (\\subsubsection{%s} . \\subsubsection*{%s})
  (\\paragraph{%s} . \\paragraph*{%s})
  (\\subparagraph{%s} . \\subparagraph*{%s}))
 
 My source document includes the following:
 #+LaTeX_CLASS: article, my org-export-latex-class is article, and my
 org-export-latex-sectioning-depth is locally set to 6 (default is 3).
 

Try setting org-export-headline-levels to 6 or use the equivalent in-buffer 
setting

#+OPTIONS: H:6

Nick

 According to the More Highly-Structured Documents subsection of Latex
 Export worg tutorial
 http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-3
 
 This setup should produce the following document structure, when
 exported to LaTeX:
 
 * section
 ** subsection
 *** subsubsection
  paragraph
 * subparagraph
 
 However, this is what is produced:
 
 * section
 ** subsection
 *** subsubsection
  itemize
 * sub-itemize, etc
 
 This happens with all export types I've tried, namely LaTeX, HTML, and
 plain text.  Any ideas about how to force export of 4 and 5-level deep
 headings as paragraph and subparagraph headings in LaTeX?
 -- 
 Pedro
 



Re: [O] Ever used org-mode contrib packages?

2012-04-12 Thread Mike McLean
On Wednesday, April 11, 2012, François Allisson wrote:

 Hello,

 I've just updated the index of contributed packages on Worg [1]. Have
 a look, it is full of treasures...


I use org-collector pretty extensively for meeting workflows. I use
concepts similar to Org Mode Tips for Team Management (
http://juanreyero.com/article/emacs/org-teams.html ) but without the custom
code from it. Each meeting is a level 1 head in an org file dedicated to
the team I am leading, I track meeting notes, tasks, etc. using normal
org-mode features. I have a top-level task summary header that has a few
sections that populate tables based on different criteria using
org-collector. I circulate meeting notes as a PDF export via LaTeX limited
to the task summary header and the most current meeting (using a no export
tag on past/completed meetings so that they do not export).


Re: [O] sectioning depth limit on export

2012-04-12 Thread Pedro Silva
Nick Dokos nicholas.do...@hp.com writes:

 Try setting org-export-headline-levels to 6 or use the equivalent in-buffer 
 setting

 #+OPTIONS: H:6


Ah, that did it.  Thanks for your help!
-- 
Pedro



Re: [O] table of contents and numbers

2012-04-12 Thread Jonas Hörsch
On Thu, Apr 12 2012, Julian Burgos wrote:

 Thanks for the answer Nick.  So to get a TOC without numbers I would
 need to edit the TEX file directly, right?


Hi there,

another option might be to remove the num:nil org option and instead
tell latex not to number any sections by setting secnumdepth to 0.

so for instance

---start org file ---
#+TITLE: Test
#+OPTIONS:  toc:t
#+LATEX_HEADER: \setcounter{secnumdepth}{0}

* Part 1
Some text

* Part 2
Some more text
---end org file ---

should do the trick.

the only drawback is that one still needs the num:nil option for the
other export formats.

perhaps this could become another way to implement num:nil for the latex
export in general. though i don't think it would work reliably for just a
subtree then.

Greets,
Jonas

P.S.: sorry to those fellow newsgroup-reading people, who now got this
answer twice, but i just realized, this is originally a mailing list.

 On mið 11.apr 2012 19:00, John Hendy wrote:
 On Wed, Apr 11, 2012 at 12:12 PM, Nick Dokosnicholas.do...@hp.com  wrote:
 Julian Burgosjul...@hafro.is  wrote:

 Dear list,

 My apologies for another very basic question.  I'm wondering why I do
 not get a table of contents when exporting the following file as pdf

 ---start org file ---
 #+TITLE: Test
 #+OPTIONS:  toc:t num:nil

 * Part 1
 Some text

 * Part 2
 Some more text
 ---end org file ---

 I do get the TOC when exporting as hmtl, though.

 I believe it's because of a rather technical latex limitation: latex
 writes TOC entries into a .toc file, which is then read back in when the
 \tableofcontents macro is expanded. When you specify num:nil asking for
 unnumbered sections, the latex exporter produces \section* markers,
 instead of the standard \section markers. But when latex processes
 those, it does not add anything to the .toc file. If org added a
 \tableofcontents, you would get just the title and an empty TOC. In
 order to prevent that, the latex exporter requires that both toc and num
 be non-nil - see l.1487 ff in lisp/org-latex.el:

 ,
 |  ...
 |  ;; table of contents
 |  (when (and org-export-with-toc
 |   (plist-get opt-plist :section-numbers))
 |(funcall org-export-latex-format-toc-function
 | ...))
 `
 One can work around this by manually adding sections under each headline.

 -
 #+options: num:nil toc:t

 #+text: \tableofcontents

 * Introduction
 \addcontentsline{toc}{section}{Introduction}
 -

 Tedious for long documents, but does work.


 John

 The HTML exporter does this by hand, so to speak, so it is not as
 constrained and can do the right thing.

 Nick






Re: [O] conditional TODOs

2012-04-12 Thread Mike McLean
I typically handle this using the ordered property.


* Project
:PROPERTIES:
:ORDERED: t
:END:
** VERIFY Task I am waiting on (I have a TODO state named VERIFY in my normal 
setup)
** TODO Task I need to do first (after waiting)
** TODO Task I need to do second (after waiting and after the do first)
---

Note that on the VERIFY task I usually also have a person-based tag that tells 
me who it is that I'm waiting on

HTH

Mike

On Apr 12, 2012, at 11:37 AM, Daniel Krenn wrote:

 I have the following situation: In a Project someone else has to do
 something and I have to wait until that is finished. If it is finished,
 then there are several TODOs. How do I that in a clever way? I.e. how to
 write that future TODOs, so that they do not appear as TODOs now (e.g.
 in the agenda) but only then, when the status of the project is changed
 from WAIT (until the other person has finished) to a state where I have
 to do something?
 
 Daniel
 




Re: [O] Problem after updating org: C-c a a broken

2012-04-12 Thread Jinli
Sebastien Vauban wxhgmqzgwmuf@... writes:

 
 Hi Nick and Markus,
 
 Nick Dokos wrote:
  Nick Dokos nicholas.dokos@... wrote:
  Markus Heller hellerm2@... wrote:
  
   Hm, so ok, restarting emacs actually solved it.
   
   Kinda weird, because I never had to do this when updating org (I don't
   compile the sources, I just do C-c C-x !).
   
   Seems a bit odd to me but it's working again so I'm happy :)
   
   I apologize for the noise.
  
  Did you try M-x org-reload RET? That should work but sometimes it misses
  something (but if it does, that would be a bug of course, so report it).
 
  nm - I missed the C-c C-x !
 
 I don't think org-reload is fully bullet-proof. I think it misses changes in
 defvars, deffaces, and the like: once set, if the default is changed, it's not
 updated by reloading the files.
 
 Now, in 99.999% of the cases, that should not be a problem. But to be really
 safe...
 
 Last thing, how is this problem solved by a restart of Emacs and not by a
 reload, not sure we can easily understand.
 
 Best regards,
   Seb
 

Hello 

I got similar errors while updating from org 7.3 to 7.8.08/09. My
emacs is 23.1. Open up emacs and type C-c a a will give an error about
function org-today is not defined. If I do an M-x org-version at this
stage it shows as the old 7.3 version. I have to manually do M-x
org-reload, which will bring up to 7.8 version.  And then everything
seems to function just fine.

Also sometimes emacs won't open org file by default if I do emacs
$filename.org, again M-x org-reload will fix the issue. But it's
tedious as now I have to do 2 steps to open a file.

Can someone please advise what might be the problem here?

Thanks,
Jinli






Re: [O] Agenda filter for a specific file

2012-04-12 Thread Marcelo de Moraes Serpa
Thanks!

On Mon, Apr 9, 2012 at 12:10 PM, Bastien b...@gnu.org wrote:

 Hi Marcelo,

 Marcelo de Moraes Serpa celose...@gmail.com writes:

  I already knew about #1, but #2 seems interesting. How could I
  implement that?

 There are useful examples here:


 http://orgmode.org/worg/org-tutorials/org-custom-agenda-commands.html#sec-4

 HTH,

 --
  Bastien



[O] Setting a task's priority based on its subtasks priorities

2012-04-12 Thread Filippo A. Salustri
Hi all,
I'm looking for a little coding help.

I want to try to a task's priority automatically, based on the priorities
of its subtasks.
Specifically, I'd like to set the priority of the task to the priority of
the highest-priority subtask.
And I'd like that task priority to be updated (if necessary) automatically
any time I change the priority of one of its subtasks.

Can anyone offer me any pointers or boilerplate code I could use to kick
this off?

Cheers.
Fil

-- 
\V/_
Filippo A. Salustri, Ph.D., P.Eng.
Mechanical and Industrial Engineering
Ryerson University
350 Victoria St, Toronto, ON
M5B 2K3, Canada
Tel: 416/979-5000 ext 7749
Fax: 416/979-5265
Email: salus...@ryerson.ca
http://deseng.ryerson.ca/~fil/


[O] Changing what org-agenda-goto shows

2012-04-12 Thread Filippo A. Salustri
Hi everyone,

At the moment, org-agenda-goto shows me the current item plus one subitem.
I would prefer it to show all the subitems of the current item; and ideally
it would narrow the buffer to just the current item subtree.

I've looked at the code and variables that affect org-agenda-goto, and I
don't see any way to get the desired behaviour.
I should also note that I'm still running org 7.5.  (I know; shame on me -
but I haven't time to upgrade till I finish grading exams)

Can anyone suggest how I can get the desired behaviour?

Cheers.
Fil

-- 
\V/_
Filippo A. Salustri, Ph.D., P.Eng.
Mechanical and Industrial Engineering
Ryerson University
350 Victoria St, Toronto, ON
M5B 2K3, Canada
Tel: 416/979-5000 ext 7749
Fax: 416/979-5265
Email: salus...@ryerson.ca
http://deseng.ryerson.ca/~fil/


Re: [O] Setting a task's priority based on its subtasks priorities

2012-04-12 Thread Nick Dokos
Filippo A. Salustri salus...@ryerson.ca wrote:

 Hi all,
 I'm looking for a little coding help.
 
 I want to try to a task's priority automatically, based on the priorities of 
 its subtasks.
 Specifically, I'd like to set the priority of the task to the priority of the 
 highest-priority
 subtask.
 And I'd like that task priority to be updated (if necessary) automatically 
 any time I change the
 priority of one of its subtasks.
 

The basic idea in all of these situations is to use org-map-entries
from the mapping API:

 (info (org) Using the mapping API)

to walk the entries, applying a function on each.

The function to apply on each entry is frequently a specialization
of one of the functions provided by the property API:

 (info (org) Using the property API)

In this case, you need a function to get the priority of each entry:

(def fas/task-priority ()
 (org-entry-get (point) PRIORITY))

which you can then give to org-map-entries:

 (org-map-entries (function fas/task-priority) t 'tree)

The assumption here is that we are at the head node and we have
an arbitrary number of subnodes. The call above will accumulate
the priorities of each subnode in a list (if a subnode does not
have a priority assigned, the priority will be nil).

For example, applying 

* section
** [#B] subsection
*** [#C] subsubsection
 paragraph
* [#B] subparagraph

will return the list 

(nil B C nil B)

It is then just a matter of finding the highest priority and applying
it to the top node. Assuming that A is higher priority than B etc,
something like this will do:

--8---cut here---start-8---
(defun fas/task-priority ()
  (org-entry-get (point) PRIORITY))

(defun fas/set-task-priority ()
  (interactive)
  (let* ((priorities (org-map-entries (function fas/task-priority) t 'tree))
 (sortedpriorities (sort (delq nil priorities) (function 
string-lessp
(if sortedpriorities
(org-priority (aref (car sortedpriorities) 0)
--8---cut here---end---8---

org-priority wants a character, but sortedpriorities is a list of
strings, hence the aref rigmarole. It should work even if *no*
priorities are set at all: sortedpriorities will be nil, so nothing will
be done.

Nick




Re: [O] [OT] Defining System, process, methodology and framework

2012-04-12 Thread Marcelo de Moraes Serpa
Well, looks like my text was kind of stupid and or confusing...

Anyway, I started reading An Introduction To General Systems Thinking -
surprisingly interesting book, and it's helping me answer most of those
questions in deeper ways. I needed to do some additional investigation
before starting to ask questions ;)

I'll share the insights after I finish it,

Thanks!

Marcelo.

On Tue, Apr 10, 2012 at 9:24 PM, Marcelo de Moraes Serpa 
celose...@gmail.com wrote:

 Hi guys,

 I know there are quite a few smart brains around here, and I think this is
 valid discussion for this mailing list, even if OT.

 I'm not a cientist, nor work inside an academic environment. I'm just a
 regular guy trying to understand this world and making better use of my
 resources, specially time. For this, I have read dozens of books on
 personal productivity, including GTD, Making it All Work, and Work the
 System. All great books.

 I've started to notice a pattern though. All of them talk about systems
 and processes (and some might even use the word framework and methodology /
 or method), and although you can live by and be quite productivity if you
 apply the principles, I knew I had to understand in an even lower and basic
 level. I then asked myself What the heck is a system and what is the
 relationship it has with process, methodology and frameworks ?

 I found out, for example, that System and Process sometimes are used
 inter-changeably. So I went to google to try to find out the answer. The
 simplest answers simply say that a process is what a system is made of.
 It did not convince me.

 By reading the wikipedia article about System (
 http://en.wikipedia.org/wiki/System), I found out this paragraph under
 System concepts:

 Process and transformation process
 A system can also be viewed as a bounded transformation process, that is,
 a process or collection of processes that transforms inputs into outputs.
 Inputs are consumed; outputs are produced. The concept of input and output
 here is very broad. E.g., an output of a passenger ship is the movement of
 people from departure to destination.


 A system can viewed as a process? Hmm, confusing.

 Right now, my mental model basically says that a system is like
 blueprint with different components that communicate, and a process is what
 runs on it (or in on of its components). Framework is like a collection
 of systems and a methodology is basically akin to system (in my
 understanding).

 Why am I obsessing about this?

 The reason is systems thinking. I think it's a quite interesting mindset
 and way to perceive the world. By trying to view yourself and what
 surrounds you as systems (with sub-systems), it's much easier to document
 (them), get feedback, and improve, automating your life even further,
 understanding it more, and living better.

 For example, from this perspective I think, GTD is simply a product of an
 elevated point of view from the author David Allen. He simply viewed things
 systematically and documented them. That's why he says it's 'common-sense'.

 But before that, it would be nice to know exactly what a System is, and
 it's relationship with process, methodology and framework, in
 abstract terms.

  What do you think? I'm sure there are quite a few people here that might
 be crazy enough to have the same question, or perhaps, I'm just too crazy.
 Let me know, any insights very much appreciated.

 Cheers,

 - Marcelo.




Re: [O] conditional TODOs

2012-04-12 Thread Bastien
Mike McLean mike.mcl...@pobox.com writes:

 I typically handle this using the ordered property.

Yes, and for more complex dependencies, there is org-depend.el 
in the contrib/ directory.

-- 
 Bastien



Re: [O] Killed Org files referred from the agenda?

2012-04-12 Thread Bastien
As an exercise, we can have a function checking for markers
in the current agenda and double-checking for the existence
of the associated buffer.  The user could run this function
regularily in an agenda buffer if he wants.

Anyone?

-- 
 Bastien



Re: [O] bug with org-mode-hook and text-scale-set

2012-04-12 Thread Bastien
Matt Lundin m...@imapmail.org writes:

 On my machine, this change causes a noticeable lag when typing in
 org-mode buffers. The cursor hesitates for a bit and then lurches
 forward. If I turn off buffer-face-mode the lag disappears. I'm still
 figuring out how to diagnose the problem.

Let us know about this.  If this change triggers such problems for
several users, maybe we should just make `buffer-face-mode' optional.

-- 
 Bastien



Re: [O] Ever used org-mode contrib packages?

2012-04-12 Thread Bastien
François Allisson franc...@allisson.co writes:

 On my side, I am only discovering the contrib/lisp directory, but have
 already tested with profits org-contacts and org-mairix. I'm curious
 to know what you are using from org-contrib...

I'd be curious too.

Can someone organize a poll around this?

In the meantime, let's share our experience on the list, 
it's a good read.

-- 
 Bastien



Re: [O] 403 Forbidden link from FAQ

2012-04-12 Thread Bastien
Yagnesh Raghava Yakkala yagn...@live.com writes:

 I think directory listing is forbidden on org website.(for security
 reasons)

Directory listing is forbidden be default for all directory but some 
of them are accessible.

Jason just make this dir accessible: http://orgmode.org/img/

HTH,

-- 
 Bastien