[O] Problem: Customizing agenda-views with org-agenda-prefix-format

2011-08-16 Thread Gustav Wikström
Hello!

I've tried to customize the output in agenda-views using
org-agenda-prefix-format but I didn't get it to work properly.

I created this agenda view to illustrate my problem:

(setq org-agenda-custom-commands
  '((w Deadlines
 ;; inbox
 ((tags-todo +DEADLINE=\today\
 ((org-agenda-prefix-format  %-12c%?-12t% s)
  (org-agenda-tags-todo-honor-ignore-options t)
  (org-agenda-todo-ignore-deadlines nil)
  ))
  (tags-todo +DEADLINE=\today\
 ((org-agenda-tags-todo-honor-ignore-options t)
  (org-agenda-todo-ignore-deadlines nil)
  ))

The only thing that differs is (org-agenda-prefix-format 
%-12c%?-12t% s) which
is present in the first of the two. The output when showing this agenda is:

Headlines with TAGS match: +DEADLINE=today
 Recurring   TODO Sommarlöpning

=
Headlines with TAGS match: +DEADLINE=today
  Recurring:  TODO Sommarlöpning

There are some differences corresponding to the agenda-prefix-format
(indentation and lack of :) but all the formatting options have not been
applied. I can not see the deadline-information I should get from % s.
(From org-agenda.org: %s   Scheduling/Deadline information, a short
string)

The following is the entry in my agenda-file:

** TODO Sommarlöpning
DEADLINE: 2011-08-14 Sun 16:00 .+2d
:LOGBOOK:
- Refiled on [2011-08-15 Mon 15:45]
- State CANCELED   from TODO   [2011-08-13 Sat 19:05]
- State DONE   from TODO   [2011-08-10 Wed 19:42]
- State TODO   from[2011-08-10 Wed 09:53]
:END:
:PROPERTIES:
:LAST_REPEAT: [2011-08-13 Sat 19:05]
:END:

Any guesses on what is wrong? Can anyone reproduce my problem or is it my
settings?

Regards Gustav


Re: [O] Bug: Refile sometimes loses the last line [7.7 (release_7.7.15.gc363)]

2011-08-16 Thread Bastien
David Maus dm...@ictsoc.de writes:

 I just pushed a simplified version of the solution: No need to count
 lines, just check if point is at end of buffer.

Thanks for your this fix!

-- 
 Bastien



Re: [O] Release 7.7

2011-08-16 Thread Bastien
Hi Torsten,

Torsten Wagner torsten.wag...@gmail.com writes:

 It might be worse to mention that this version find its way into
 emacs-git. 

You're right -- Org 7.7 is the version currently used in Emacs trunk.

From now on, I will merge Org into Emacs more regularily, provided there
is no feature freeze process that prevents it.

Best,

-- 
 Bastien



Re: [O] fatal: The remote end hung up unexpectedly

2011-08-16 Thread Bastien
Hi John,

John Hendy jw.he...@gmail.com writes:

 Is this enough of a problem with or.cz that the page on keeping up to
 date with orgmode should be updated?

I'm not sure how you want to update this section, but I think repo.or.cz
is usually doing a pretty good job, so no need to update IMHO.

Also, it's good to let users know there is this possibility to keep in
sync with another repo than the one on orgmode.org.

Best,

-- 
 Bastien



Re: [O] [bug?] wiki export vs. multilines list item

2011-08-16 Thread Bastien
Hi Walter,

Walter Franzini walter.franz...@gmail.com writes:

 I'm experimenting with org-mode's exporting features and I've discovered
 that, with both mediawiki exporters, multilines list's items are
 rendered as a list item followed by a preformatted text block.

Thanks for reporting this -- I've pushed a fix to org-mediawiki.el in
EXPERIMENTAL/, lists should be correctly exported now.

Best,

-- 
 Bastien



Re: [O] Headline level on org-mobile-inbox-for-pull

2011-08-16 Thread Bastien
Hi Carlos,

Carlos Russo mestre.adamas...@gmail.com writes:

 As far as I can tell from the documentation, whenever I do a M-x
 org-mobile-pull, all the entries I captured with my mobile device are
 eventually moved into *top-level headlines* of org-mobile-inbox-for-pull
 (from-mobile.org).

I'm not using org-mobile.el myself, but I hope someone will be able to
help you here.  Sounds like a reasonable request to me.

Best,

-- 
 Bastien



Re: [O] compute the difference between effort estimates and actual clocked time

2011-08-16 Thread Bastien
Hi Pascal,

M.P. mattia.pas...@gmail.com writes:

 I'd like to add to my tasks a property  whose value should be the difference 
 in
 time between the effort estimates and the actual clocked time. The final 
 purpose
 is to use the property in column view mode as I do with CLOCKSUM and Effort.
 Could you give me any hints?

There is no way to do this easily right now.

However, this command will display the remaining effort:

#+begin_src emacs-lisp
(defun my-org-display-remaining-effort ()
  Compute remaining effort for current subtree.
  (interactive)
  (let ((clocksum (org-clock-sum-current-item))
(effort (org-duration-string-to-minutes
  (org-entry-get (point) Effort
(message (org-minutes-to-hh:mm-string (- effort clocksum)
#+end_src

Also, the attached patch allow to postprocess property values with
custom functions when inserting them with org-set-properties.

Let me know if you find this useful!

Best,

From b2cdde739e4ed552b5cd4c30d62fb4215656d603 Mon Sep 17 00:00:00 2001
From: Bastien Guerry b...@altern.org
Date: Tue, 16 Aug 2011 16:21:31 +0200
Subject: [PATCH] New option `org-properties-postprocess-alist'.

* org.el (org-properties-postprocess-alist): New option to
allow postprocessing the values of properties set through
`org-set-property'.
(org-set-property): Use this option.

This is inspired by a request from Pascal Mattia.
---
 lisp/org.el |   25 +
 1 files changed, 25 insertions(+), 0 deletions(-)

diff --git a/lisp/org.el b/lisp/org.el
index 318339a..dbefab1 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -2967,6 +2967,28 @@ lined-up with respect to each other.
   :group 'org-properties
   :type 'string)
 
+(defcustom org-properties-postprocess-alist nil
+  Alist of properties and functions to adjust inserted values.
+Elements of this alist must be of the form 
+
+  ([string] [function])
+
+where [string] must be a property name and [function] must be a
+lambda expression: this lambda expression must take one argument,
+the value to adjust, and return the new value as a string.
+
+For example, this element will allow the property \Remaining\
+to be updated wrt the relation between the \Effort\ property
+and the clock summary:
+
+ ((\Remaining\ (lambda(value)
+   (let ((clocksum (org-clock-sum-current-item))
+ (effort (org-duration-string-to-minutes 
+   (org-entry-get (point) \Effort\
+ (org-minutes-to-hh:mm-string (- effort clocksum))
+  :group 'org-properties
+  :type 'alist)
+
 (defcustom org-use-property-inheritance nil
   Non-nil means properties apply also for sublevels.
 
@@ -14228,6 +14250,9 @@ in the current file.
   (let* ((property (or property (org-read-property-name)))
 	 (value (or value (org-read-property-value property
 (setq org-last-set-property property)
+;; Possibly postprocess the inserted value:
+(when (assoc property org-properties-postprocess-alist)
+  (setq value (funcall (cadr fn) value)))
 (unless (equal (org-entry-get nil property) value)
   (org-entry-put nil property value
 
-- 
1.7.5.2


-- 
 Bastien


Re: [O] making coloured tables

2011-08-16 Thread Bastien
Hi Andras,

Andras Major andras.g.ma...@gmail.com writes:

 I have an idea how my feature could be implemented, and it consists of
 two parts.

Thanks for bringing up these ideas -- just to make things clear: I'm 
not volunteering for implementing this, my knowledge of org tables is
falling a bit short here.

Best,

-- 
 Bastien



Re: [O] Problems with latex exporting in verbatim environment

2011-08-16 Thread Bastien
Hi Stephen,

Stephen Eglen s.j.eg...@damtp.cam.ac.uk writes:

 Using colon, the text is not reported verbatim.

I cannot reproduce this with Org 7.7.  Can you?

Best,

-- 
 Bastien



Re: [O] Keeping vertical bars in exported, ASCII file

2011-08-16 Thread Bastien
Hi Michael,

Michael Hannon jm_han...@yahoo.com writes:

 Greetings.  I wonder if there's a way to tell Emacs to keep the
 fences (vertical bars) in an exported, ASCII file.

Yes there is:

  (setq org-export-ascii-table-keep-all-vertical-lines t)

Best,

-- 
 Bastien



Re: [O] Bug: org-mobile-push opens a new frame with the .org file being pushed. [6.33x]

2011-08-16 Thread Bastien
Hi Stefano,

Stefano Ricciardi stefano.riccia...@gmail.com writes:

 As per subject: whenever I issue a org-mobile-push command, the
 pushed .org file is opened on a new Emacs frame.

You are using Org 6.33x, chances are that this problem has been fixed
since then.  Please upgrade to a more recent version of Org if that's
possible. 

 Configuration below.
 By the way, thank you for putting together the org-mode. It's
 amazing!

Org 7 (or higher) is even greater :)

Best,

-- 
 Bastien



Re: [O] TODO type problem on speedbar and imenu.

2011-08-16 Thread Bastien
Hi Nicolas,

Nicolas Goaziou n.goaz...@gmail.com writes:

 Bastien b...@altern.org writes:

 Yep.  When you have some free time (!), please suggest a patch and a
 small org test file so that we can test.

 Here is an attempt to convert word boundaries into white spaces where it
 matters.

Thanks a lot -- I have tested the patch during the last two hours and
didn't find any problem.  Feel free to apply it.

What about going one step further and removing the possibility of 
using tabs after TODO keywords?

Best,

-- 
 Bastien



Re: [O] [PATCH] recognize HH:MM duration when sorting table rows

2011-08-16 Thread Bastien
Hi Max,

Max Mikhanosha m...@openchat.com writes:

 `org-table-sort-lines' function allows one to sort the rows of a
 table, by the t/T format for the column only recognizes timestamps
 with a date. A patch pasted below adds recognition of HH:MM durations.

Thanks a lot -- I'm willing to apply this patch.  

Could you reformat it with git format-patch and include a proper
ChangeLog entry?  

Thanks,

-- 
 Bastien



Re: [O] Bug: Refile sometimes loses the last line [7.7 (release_7.7.15.gc363)]

2011-08-16 Thread Bastien
Bastien b...@altern.org writes:

 David Maus dm...@ictsoc.de writes:

 I just pushed a simplified version of the solution: No need to count
 lines, just check if point is at end of buffer.

 Thanks for your this fix!

Wow, how can someone munge his words so badly? :)

-- 
 Bastien



Re: [O] [PATCH 1/7] New macro: Execute BODY in enviroment with uninterned SYMBOLS

2011-08-16 Thread Bastien
Hi David,

David Maus dm...@ictsoc.de writes:

 Thanks for the feedback on org-with-uninterned. I'm preparing the
 patches for master and decided to use the 'add-noise' approach
 suggested by Štěpán but renamed the macro to `org-with-gensyms'. Thus
 we can change the implementation.

I see you have applied the serie of patches -- thanks a bunch for that!

Let me know if there is code in this area I need to double-check or to
learn from.

Best,

-- 
 Bastien



Re: [O] More on macros: Defined edebug-spec

2011-08-16 Thread Bastien
Hi David,

David Maus dm...@ictsoc.de writes:

 I just pushed a commit to master that adds edebug specifications to
 all macros defined by Org mode. 

This answers questions I've been asking myself for very long!

 With these specifications in place it
 is now possible to step through macros with edebug like a normal
 function call.

 Information about instrumenting macro calls can be found here:

 http://www.gnu.org/software/emacs/elisp/html_node/Instrumenting-Macro-Calls.html

Thanks *a lot* for the link.

Best,

-- 
 Bastien



Re: [O] New feature: loop over siblings for some commands

2011-08-16 Thread Bastien
Hi David,

David Maus dm...@ictsoc.de writes:

 At Wed, 10 Aug 2011 10:34:14 +0200,
 David Maus wrote:

 Whats next: Handle folded subtrees. Currently org-schedule w/ active
 region schedules hidden subtrees, too. Using a tags/prop/todo query
 seems suboptimal because you would have to know the characteristics of
 the region beforehand. To me this seems to defeat the conveniance of
 using the region: If I already know the characteristics of which
 headlines to schedule, I would have created a agenda command and use
 bulk-schedule.

 Done that.

 https://github.com/dmj/dmj-org-mode/commit/c6d636350125916539a041b93e45fc306f4bbd9b

Great -- can you submit a patch against current git head?

Best,

-- 
 Bastien



Re: [O] how to change the headline starter *

2011-08-16 Thread Bastien
Hi Matt,

Matt Lundin m...@imapmail.org writes:

 On further investigation, I can see very easily how much this cleans up
 the code. Sorry for the noise!

No problem!

 Perhaps for the relevant functions (e.g., org-overview) we could
 construct org-outline-regexp-bol from the a bound version of
 org-outline-regexp (i.e., one that uses the buffer local value of
 outline-regexp). 

 At the moment, this FAQ is obsolete:

 http://orgmode.org/worg/org-faq.html#use-visibility-cycling-in-outline-mode

 I think the best approach here is to hard-code org-outline-regexp and
 org-outline-regexp-bol (as you have done) but to make it more flexible
 in the *few* instances where one would like to use visibility functions
 in outline-mode. I've attached a simple patch that restores global
 cycling in outline-mode buffers. 

IIUC we don't need such patch anymore -- can you confirm this?

Thanks,

-- 
 Bastien



Re: [O] Pattch to org.texi: Document :eval no

2011-08-16 Thread Bastien
Hi Stephen,

Stephen Eglen s.j.eg...@damtp.cam.ac.uk writes:

 Small patch attached, thanks Seb for pointing this out.

Thanks for the patch -- I'm willing to apply it, but I'd rather apply a
complete patch, i.e. one with a ChangeLog entry.  Can you update it?

Put the cursor on your change in org.texi and use `C-x 4 a' to create a
proper ChangeLog entry, then copy this entry to the commit message.

Thanks in advance!

-- 
 Bastien



Re: [O] A new module for Org-mode: Org-X

2011-08-16 Thread Achim Gratz
John Wiegley jwieg...@gmail.com writes:
 I've been working a new set of modules for Org to make it easy to associate
 Org entries with data in external systems, such as Redmine, Bugzilla,
 WordPress, or even your e-mail Inbox.  It's called Org-X, as its meant to
 simplify writing linkup code for any system X.

You're on to something... :-)

I can easily see how this works with bug/issue trackers.  What I'm not
so sure is how you imagine it to work with files.  For my part I'm
hoping that it might be able to get some interface to the various bits
and pieces I've bookmarked and sometimes put into local versions with
the ScrapBook Firefox extension.

A few random comments:

I'd check source code for FIXME, not TODO.

If org-x-states is backend specific, why not let the backend define it?

LZW: is there really nothing in Emacs that already does this? In any
case it seems to belong into an own library and should probably be
unbundled from org before long.


Regards,
Achim.
-- 
+[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]+

SD adaptations for KORG EX-800 and Poly-800MkII V0.9:
http://Synth.Stromeko.net/Downloads.html#KorgSDada




Re: [O] [PATCH] org.el: Inhibit insertion of superfluous space character in org-add-planning-info.

2011-08-16 Thread Bastien
Hi Valentin,

Valentin Wüstholz wuesth...@gmail.com writes:

 I've noticed that org-add-planning-info adds a superfluous space
 character when a repeated task is marked as DONE and gets rescheduled.

Patch applied, thanks.

For the next patch, can you include the ChangeLog entry?

Thanks!

-- 
 Bastien



Re: [O] [PATCH 1/7] New macro: Execute BODY in enviroment with uninterned SYMBOLS

2011-08-16 Thread David Maus
At Tue, 16 Aug 2011 18:34:04 +0200,
Bastien wrote:
 
 Hi David,
 
 David Maus dm...@ictsoc.de writes:
 
  Thanks for the feedback on org-with-uninterned. I'm preparing the
  patches for master and decided to use the 'add-noise' approach
  suggested by Štěpán but renamed the macro to `org-with-gensyms'. Thus
  we can change the implementation.
 
 I see you have applied the serie of patches -- thanks a bunch for that!
 
 Let me know if there is code in this area I need to double-check or to
 learn from.

Well: Defining edebug specifications for macros is something really
useful for debugging those buggers. Maybe this could be something like
an informal policy: No macro without edebug spec, especially if the
macro wraps around a body.

Best,
  -- David
-- 
OpenPGP... 0x99ADB83B5A4478E6
Jabber dmj...@jabber.org
Email. dm...@ictsoc.de


pgpiG1yu0PJh9.pgp
Description: PGP signature


Re: [O] [RFC] inline task formatting in odt/doc (was Re: Org-odt fails to export when inline tasks are present)

2011-08-16 Thread Bastien
Hi Jambunathan,

Jambunathan K kjambunat...@gmail.com writes:

 Are there any opinions/preferences on how inline tasks could be exported
 in to odt format. I think having an ability to quickly navigate through
 all the inline tasks in the exported document would be a
 pre-requisite. 

I don't use inline tasks myself, so I don't have a strong opinion about
this.

 I am thinking of exporting them as Insert-Comments and from
 OpenOffice help it seems one can quickly visit such comments in
 order. 

These sounds like a reasonable choice, assuming we can find a solution
for the problem Suvayu has been pointing at.  If the solution we try to
implement first is not the best one, we can always improve it afterwards.

Thanks in advance for implementing this!

-- 
 Bastien



Re: [O] Bug: Refile sometimes loses the last line [7.7 (release_7.7.15.gc363)]

2011-08-16 Thread Achim Gratz
Bastien b...@altern.org writes:
 Wow, how can someone munge his words so badly? :)

In the force if Yoda's so strong, construct a sentence
with words in the proper order then why can't he?


Achim.
-- 
+[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]+

SD adaptations for Waldorf Q V3.00R3 and Q+ V3.54R2:
http://Synth.Stromeko.net/Downloads.html#WaldorfSDada




Re: [O] Reg: Publishing in html using property tags

2011-08-16 Thread Puneeth Chaganti
On Mon, Aug 15, 2011 at 1:44 PM, Bodhi thebb...@gmail.com wrote:
 Dear Puneeth,
 The org-mode link works magically. Thanks!
 But the same doesn't work for the generated html page.
 The pages get built, and the ID gets created, the html href contains that
 unique ID, but the browser is unable to load foo.html from the link in
 bar.html.

 Did you get any success on that front? Any ideas? I'm running org-mode 7.4.

If both the files are exported, it seems to work, doesn't it?
Make sure both, foo.org and bar.org are exported.

--
Puneeth



Re: [O] [PATCH] org.el: Preserve indentation of manually indented lines in example blocks.

2011-08-16 Thread Bastien
Hi Nicolas,

Nicolas Goaziou n.goaz...@gmail.com writes:

 Valentin Wüstholz wuesth...@gmail.com writes:

 Sure. I have attached the output.

 Thank you. I have applied it to master.

Thanks for taking care of applying this patch.

-- 
 Bastien



Re: [O] [PATCH 1/7] New macro: Execute BODY in enviroment with uninterned SYMBOLS

2011-08-16 Thread Bastien
David Maus dm...@ictsoc.de writes:

 Well: Defining edebug specifications for macros is something really
 useful for debugging those buggers. Maybe this could be something like
 an informal policy: No macro without edebug spec, especially if the
 macro wraps around a body.

Agreed.  Let's try to stick to this policy.

-- 
 Bastien



Re: [O] Reg: Publishing in html using property tags

2011-08-16 Thread Bodhi
Nope. No luck. :(
Both files are exported, because I can individually access foo.html and
bar.html.

On Tue, Aug 16, 2011 at 10:50 PM, Puneeth Chaganti puncha...@gmail.comwrote:

 On Mon, Aug 15, 2011 at 1:44 PM, Bodhi thebb...@gmail.com wrote:
  Dear Puneeth,
  The org-mode link works magically. Thanks!
  But the same doesn't work for the generated html page.
  The pages get built, and the ID gets created, the html href contains that
  unique ID, but the browser is unable to load foo.html from the link in
  bar.html.
 
  Did you get any success on that front? Any ideas? I'm running org-mode
 7.4.

 If both the files are exported, it seems to work, doesn't it?
 Make sure both, foo.org and bar.org are exported.

 --
 Puneeth




-- 
Regards,
Bodhisatta Barman Roy


Re: [O] Reg: Publishing in html using property tags

2011-08-16 Thread Puneeth Chaganti
On Tue, Aug 16, 2011 at 11:01 PM, Bodhi thebb...@gmail.com wrote:
 Nope. No luck. :(
 Both files are exported, because I can individually access foo.html and
 bar.html.

Where does the link in foo.html point to? Can you send the sample
files that you are using? Or a simplified version of them?

--
Puneeth



[O] thanks

2011-08-16 Thread Patrick O'Neill
I just wanted to give a quick word of thanks to Bernt Hansen and everyone
else answering questions on the emacs-orgmode list.  Since the mailing list
is publicly archived, answered questions can remain useful to others long
after the original respondents have probably forgotten about them.  This
answer (
http://lists.gnu.org/archive/html/emacs-orgmode/2008-08/msg00057.html) from
2008 was very useful to me and no doubt to others as well.

Cheers,
Patrick.


[O] [bug] Asterisks in source and example blocks interpreted as headings

2011-08-16 Thread Jason Dunsmore
Hello,

I noticed that lines with leading asterisks inside of source and example
blocks are interpreted as headings:

--8---cut here---start-8---
* Heading 1

#+begin_example
foo
* bar
blah
#+end_example

* Heading 2
--8---cut here---end---8---

If you put the point on Heading 1 and hit TAB, you'll see the
following:

--8---cut here---start-8---
* Heading 1...
* bar
blah
#+end_example

* Heading 2
--8---cut here---end---8---

I'm using GNU Emacs 23.2.1 and Org-mode version 7.7
(release_7.7.97.g9d5c5)

Regards,
Jason



Re: [O] fatal: The remote end hung up unexpectedly

2011-08-16 Thread John Hendy
On Tue, Aug 16, 2011 at 8:20 AM, Bastien b...@altern.org wrote:
 Hi John,

 John Hendy jw.he...@gmail.com writes:

 Is this enough of a problem with or.cz that the page on keeping up to
 date with orgmode should be updated?

 I'm not sure how you want to update this section, but I think repo.or.cz
 is usually doing a pretty good job, so no need to update IMHO.

It was more of a hypothetical suggestion if there were consistent
problems with that repo.


 Also, it's good to let users know there is this possibility to keep in
 sync with another repo than the one on orgmode.org.

And, indeed, that's the repo I used... until it didn't work for me.
I'll stay with the orgmode one unless it goes out and then I'll switch
back if I need to :)


John


 Best,

 --
  Bastien




Re: [O] [PATCH] org.el: Preserve indentation of manually indented lines in example blocks.

2011-08-16 Thread Bastien
Hi Valentin,

Valentin Wüstholz wuesth...@gmail.com writes:

 Meanwhile, could you please reformat a bit your patch (no more than 80
 columns, no parents on their own line), add a commit message followed
 by TINYCHANGE (unless you have signed FSF papers already) and use git
 format-patch for the output?

 Sure. I have attached the output.

Thanks for making the effort of reformatting patches this way.  With 
so many patches coming in, it's really important that everyone tries to
stick to immediately-applicable patches.

 From c64f1b607d937c6484dfc18110125b1287175ac4 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Valentin=20W=FCstholz?= wuesth...@gmail.com
 Date: Tue, 9 Aug 2011 21:28:56 +0200
 Subject: [PATCH] Preserve indentation of explicitly indented lines in example 
 blocks

 * lisp/org.el (org-indent-line-function): Made the way in which example 
 blocks are
   indented more flexible.

This line a bit long and should be something like:

 * lisp/org.el (org-indent-line-function): Made the way in which
   example blocks are indented more flexible.

Use M-q in change-log-mode on the ChangeLog to fill the region
correctly.

 Before: Lines in example blocks were indented like the surrounding begin and 
 end
 delimiters.
 After: By default, lines in example blocks are indented like the surrounding 
 begin and end
 delimiters, unless the user explicitly indents them differently.

Here again, I prefer 80 characters lines, but that's less important
than the ChangeLog entry.

Thanks,

-- 
 Bastien



Re: [O] [bug] org-inlinetask produces invalid xhtml

2011-08-16 Thread Bastien
Hi Nicolas,

Nicolas Goaziou n.goaz...@gmail.com writes:

 Loading org-inlinetask is the user's job. He has to assume weird things
 which will happen when the buffer holds inline tasks without them being
 loaded (but I give him an excuse as inline tasks are completely
 undocumented).

We should fix this -- anyone willing to put a stab at this?

Thanks!

-- 
 Bastien



Re: [O] A new module for Org-mode: Org-X

2011-08-16 Thread John Wiegley
Achim Gratz strom...@nexgo.ed writes:

 I can easily see how this works with bug/issue trackers.  What I'm not so
 sure is how you imagine it to work with files.  For my part I'm hoping that
 it might be able to get some interface to the various bits and pieces I've
 bookmarked and sometimes put into local versions with the ScrapBook Firefox
 extension.

The backend gets to define what the parts of an entry are.  Some backends will
import actual content into the related Org entry, while others will only
import a link back to the original content.  This is what I would do for a
backend that monitors files within an Inbox directory, for example.

 I'd check source code for FIXME, not TODO.

Sure, this would be configurable through both a customization variable (for
setting default behavior), and through an inherited property (as part of the
backend context).

 If org-x-states is backend specific, why not let the backend define it?

It is defined, by the ox-org backend. :)  I imagine that very soon now, I'll
pay attention to SEQ_TODO and the usual Org variable, rather than having my
own custom variable for this.

 LZW: is there really nothing in Emacs that already does this? In any case it
 seems to belong into an own library and should probably be unbundled from
 org before long.

There's really not!  I wrote it because I imagine at some point wanting to
take a snapshot of the state of an entry, for the purpose of accelerating
certain backends, but I haven't yet found that use.  For now, it's just living
in ox-lzw so that it's under version control.  If it becomes useful, I'll
submit it to Emacs separately and ahead of Org-X.

John



Re: [O] [bug] org-inlinetask produces invalid xhtml

2011-08-16 Thread Bastien
Hi Jambunathan,

Jambunathan K kjambunat...@gmail.com writes:

 I am attaching the patch and sample org/odt/doc/html files.

Applied, thanks a lot!

-- 
 Bastien



Re: [O] fatal: The remote end hung up unexpectedly

2011-08-16 Thread Bastien
John Hendy jw.he...@gmail.com writes:

 And, indeed, that's the repo I used... until it didn't work for me.
 I'll stay with the orgmode one unless it goes out and then I'll switch
 back if I need to :)

Hehe, that's precisely why we should advertize both!

-- 
 Bastien



Re: [O] A new module for Org-mode: Org-X

2011-08-16 Thread Achim Gratz
John Wiegley jwieg...@gmail.com writes:
 The backend gets to define what the parts of an entry are.  Some backends will
 import actual content into the related Org entry, while others will only
 import a link back to the original content.  This is what I would do for a
 backend that monitors files within an Inbox directory, for example.

Still clear as mud... I'll have to give this more time to think over.

 LZW: is there really nothing in Emacs that already does this? In any case it
 seems to belong into an own library and should probably be unbundled from
 org before long.

 There's really not!  I wrote it because I imagine at some point wanting to
 take a snapshot of the state of an entry, for the purpose of accelerating
 certain backends, but I haven't yet found that use.  For now, it's just living
 in ox-lzw so that it's under version control.  If it becomes useful, I'll
 submit it to Emacs separately and ahead of Org-X.

That's what I was suspecting.  It appears you're re-inventing certain
aspects of serialization/deserialization and that might come in handy
for a lot more things.  For starters, if it was built-in into Emacs that
whole business of dumping a bootstrapped Emacs and doing horrible things
to the resulting file to be able to get it back to life would probably
become uneccesary...


Regards,
Achim.
-- 
+[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]+

Factory and User Sound Singles for Waldorf Q+, Q and microQ:
http://Synth.Stromeko.net/Downloads.html#WaldorfSounds




Re: [O] [bug] Asterisks in source and example blocks interpreted as headings

2011-08-16 Thread Bastien
Hi Jason,

Jason Dunsmore emacs-orgm...@dunsmor.com writes:

 I noticed that lines with leading asterisks inside of source and example
 blocks are interpreted as headings:

The attached patch should fix this -- please confirm.

Thanks!

From 4ff6f7a78c07654e70ac8473c911b873340f0b67 Mon Sep 17 00:00:00 2001
From: Bastien Guerry b...@altern.org
Date: Tue, 16 Aug 2011 21:51:02 +0200
Subject: [PATCH] org.el: Fix bug about headlines in blocks.

* org.el (org-cycle): Use `org-at-heading-p'.
(org-heading-forbidden-blocks): Variable alias to
`org-list-forbidden-blocks'.
(org-on-heading-p, org-at-heading-p): only perform the check
when we are in allowed blocks, otherwise just return nil.

Thanks to Jason Dunsmor for pointing at this.
---
 lisp/org.el |   14 ++
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/lisp/org.el b/lisp/org.el
index 2c38b33..2eabcb8 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -5994,8 +5994,7 @@ in special contexts.
 
;; At an item/headline: delegate to `org-cycle-internal-local'.
((and (or (and org-cycle-include-plain-lists (org-at-item-p))
-		 (save-excursion (beginning-of-line 1)
- (looking-at org-outline-regexp)))
+		 (org-at-heading-p))
 	 (or (bolp) (not (eq org-cycle-emulate-tab 'exc-hl-bol
 	(org-cycle-internal-local))
 
@@ -20067,10 +20066,17 @@ This version does not only check the character property, but also
 (end-of-line)
 (null (re-search-backward org-outline-regexp-bol nil t
 
+(defvaralias 'org-heading-forbidden-blocks 'org-list-forbidden-blocks
+  List of blocks where a heading should not be treated as such.
+See `org-list-forbidden-blocks'.)
+
 (defun org-on-heading-p (optional ignored)
-  (outline-on-heading-p t))
+  (unless (org-in-block-p org-heading-forbidden-blocks)
+(outline-on-heading-p t)))
+
 (defun org-at-heading-p (optional ignored)
-  (outline-on-heading-p t))
+  (unless (org-in-block-p org-heading-forbidden-blocks)
+(outline-on-heading-p t)))
 
 (defun org-point-at-end-of-empty-headline ()
   If point is at the end of an empty headline, return t, else nil.
-- 
1.7.5.2


-- 
 Bastien


Re: [O] parsing options

2011-08-16 Thread Bastien
Hi Eric,

Eric Abrahamsen e...@ericabrahamsen.net writes:

 Is there a generic function for parsing options lines at the top of a
 file? 

See `org-infile-export-plist'.

 I'd like to use some custom lines to set certain file-specific
 variables, and haven't quite figured out the best way to do that.

 It looks like org-set-regexps-and-options does that when you open a new
 file, but that's a bear of a function, and doesn't provide for setting
 your own options (or at least doesn't appear to, my eyes crossed while
 reading it).

`org-set-regexps-and-options' is used to set options keywords and
regexp, so depending on what you exactly want to do, you may have 
to add your own options keywords here...

 Is there any smaller function available for our own minor modes or use
 cases? Should I just use regexp search? If there isn't anything like
 this, would one be useful (something that either found an option value
 or returned a default, or found an alist of option values, or found an
 alist of values for options matching a regexp, etc)?

Mhh..  hard to help you more without knowing more precisely what you
want to achieve.  Perhaps an example would help.

Thanks!

-- 
 Bastien



Re: [O] Org-Mode Homepage error

2011-08-16 Thread Bastien
Hi Achim,

CC'ing Sebastian in case he can have a look.

Achim Gratz strom...@nexgo.de writes:

 Could you be more specific what is a no good result?  

Well, the HTML page was empty -- same error than with the unpatched
version of org-info.js.

 I've been
 generating the index.html in org-info-js and it now works without error
 for me.  I've even found a simpler patch that is based on the class
 of the title heading so that it is found regardless of its position in
 preamble or content:

 Diff --git a/code/org-info-js/org-info-src.js 
 b/code/org-info-js/org-info-src.js
 index 2e49e9c..b521c50 100644
 --- a/code/org-info-js/org-info-src.js
 +++ b/code/org-info-js/org-info-src.js
 @@ -738,7 +738,7 @@ var org_html_manager = {
  
  // Move the title into the first visible section.
  // TODO: show title above everything if FIXED_TOC !!!
 -t.TITLE = t.BODY.getElementsByTagName(h1)[0];
 +t.TITLE = document.getElementsByClassName(title)[0];
  if(t.INNER_TITLE  !t.FIXED_TOC  t.VIEW != t.SLIDE_VIEW) {
t.INNER_TITLE = t.TITLE.cloneNode(true);
/* TODO: this is still based on wrong behaviour of browsers (same id 
 for two elements)

If you're confident this works with this structure:

  div id=preamble
h1 class=titleTitle/h1
  div
  
  div id=content
  ...
  div

then I will apply the patch (with a ChangeLog!)

Thanks,

-- 
 Bastien



Re: [O] [bug] Asterisks in source and example blocks interpreted as headings

2011-08-16 Thread Jason Dunsmore
Bastien b...@altern.org writes:

 Hi Jason,

 Jason Dunsmore emacs-orgm...@dunsmor.com writes:

 I noticed that lines with leading asterisks inside of source and example
 blocks are interpreted as headings:

 The attached patch should fix this -- please confirm.

Hm, I'm still seeing the same issue with both source and example blocks.



[O] odt export bug, I think.

2011-08-16 Thread Matt Price
Hi,

I think I've found an odt export bug.  Certain complex URL's stored within
links can end up being rendered with forbidden characters, e.g. '' and
''.  so, e.g., a link to this URL:

http://www.jstor.org.myaccess.library.utoronto.ca/sici?origin=sfx%253Asfxsici=1363-3554%25281995%252939%253C182%253E1.0.CO%253B2-L;

was rendered in content.xml like this:
xlink:href=
http://www.jstor.org/sici?origin=sfx:sfxamp;sici=1363-3554(1995)39182
1.0.CO;2-Lamp;

resulting in a syntax error when libreoffice tries to load it.  I've
attached a minimal test file that reproduces the bug.

This is happening under a recent git snapshot of org-mode, using an emacs
snapshot from 2011-04.  Not sure if there are other xml-related packages
whose versions I should be tracking.

Thanks as always, and let me know what I can do to help with this.

Matt


test.odt
Description: application/vnd.oasis.opendocument.text


test.org
Description: Binary data


Re: [O] TODO type problem on speedbar and imenu.

2011-08-16 Thread Nicolas Goaziou
Hello,

Bastien b...@altern.org writes:

 Thanks a lot -- I have tested the patch during the last two hours and
 didn't find any problem.  Feel free to apply it.

Done.

 What about going one step further and removing the possibility of 
 using tabs after TODO keywords?

There are quite a few places indeed using [ \t] which may use  
instead. Before TODO keywords, before priority cookies, before
check-boxes, etc.

We might remove any use of [ \t] but for indentation. Though, I don't
use tabs, and there could well be corner cases that I can't see[1].

Regards,

[1] Like * TODO  Headline  :tag:

-- 
Nicolas Goaziou



Re: [O] TODO type problem on speedbar and imenu.

2011-08-16 Thread Carsten Dominik

On 13.8.2011, at 12:16, Nicolas Goaziou wrote:

 Hello,
 
 Bastien b...@altern.org writes:
 
 Yep.  When you have some free time (!), please suggest a patch and a
 small org test file so that we can test.
 
 Here is an attempt to convert word boundaries into white spaces where it
 matters.

I am not sure this is a good idea.  With this patch, you always
require the space to be there.  So * TODO would not be a task.
I am not sure, this might have side effects.

- Carsten

 
 I paste again the test file from Osamu Okano for reference.
 
 #+begin_src org
 #+TYP_TODO: SOMEDAY 
 * someday/maybe 
 * SOMEDAY/maybe 
 * SOMEDAY maybe 
 * someday maybe 
 * read/review   
 * READ/review   
 * conf  
 #+end_src
 
 
 Regards,
 
 -- 
 Nicolas Goaziou
 0001-Enforce-white-space-after-todo-keywords.patch




[O] Hide table columns on export

2011-08-16 Thread Johnny
Is there a way to hide certain columns of a table when exporting? 

I know the / will hide rows, and  can group columns, but haven't
been able to find any way to hide certain columns on export? The
rationale being that I use some column for intermediary calculations
that I don't want to see in the export.

Thanks for any pointers!
-- 
Johnny



Re: [O] [PATCH] org.el: Inhibit insertion of superfluous space character in org-add-planning-info.

2011-08-16 Thread Valentin Wüstholz
Hi Bastien.


On Tue, Aug 16, 2011 at 7:05 PM, Bastien b...@altern.org wrote:
 Hi Valentin,

 Valentin Wüstholz wuesth...@gmail.com writes:

 I've noticed that org-add-planning-info adds a superfluous space
 character when a repeated task is marked as DONE and gets rescheduled.

 Patch applied, thanks.

 For the next patch, can you include the ChangeLog entry?


Sure! I had thought that that wasn't necessary for very small changes.

Thanks,

Valentin



Re: [O] [PATCH] org.el: Preserve indentation of manually indented lines in example blocks.

2011-08-16 Thread Valentin Wüstholz
Hi Bastien,

thanks for the comments. I'll certainly keep that in mind for future
patches. Maybe that's something that could be added to the
corresponding worg page (http://orgmode.org/worg/org-contribute.html).

Best regards,

Valentin


On Tue, Aug 16, 2011 at 9:18 PM, Bastien b...@altern.org wrote:
 Hi Valentin,

 Valentin Wüstholz wuesth...@gmail.com writes:

 Meanwhile, could you please reformat a bit your patch (no more than 80
 columns, no parents on their own line), add a commit message followed
 by TINYCHANGE (unless you have signed FSF papers already) and use git
 format-patch for the output?

 Sure. I have attached the output.

 Thanks for making the effort of reformatting patches this way.  With
 so many patches coming in, it's really important that everyone tries to
 stick to immediately-applicable patches.

 From c64f1b607d937c6484dfc18110125b1287175ac4 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Valentin=20W=FCstholz?= wuesth...@gmail.com
 Date: Tue, 9 Aug 2011 21:28:56 +0200
 Subject: [PATCH] Preserve indentation of explicitly indented lines in 
 example blocks

 * lisp/org.el (org-indent-line-function): Made the way in which example 
 blocks are
   indented more flexible.

 This line a bit long and should be something like:

 * lisp/org.el (org-indent-line-function): Made the way in which
   example blocks are indented more flexible.

 Use M-q in change-log-mode on the ChangeLog to fill the region
 correctly.

 Before: Lines in example blocks were indented like the surrounding begin and 
 end
 delimiters.
 After: By default, lines in example blocks are indented like the surrounding 
 begin and end
 delimiters, unless the user explicitly indents them differently.

 Here again, I prefer 80 characters lines, but that's less important
 than the ChangeLog entry.

 Thanks,

 --
  Bastien




Re: [O] Hide table columns on export

2011-08-16 Thread Nick Dokos
Johnny yggdra...@gmx.co.uk wrote:

 Is there a way to hide certain columns of a table when exporting? 
 
 I know the / will hide rows, and  can group columns, but haven't
 been able to find any way to hide certain columns on export? The
 rationale being that I use some column for intermediary calculations
 that I don't want to see in the export.
 
 Thanks for any pointers!

I don't know of any way to do that within org and it might be a nice
feature to have.

But it's always good to remember that it's all just text (TM) and
you have emacs as well as org backing you up.

In this particular case, you could easily kill the columns you don't
want to export (with M-S-left in a table context), do the export (C-c e
h or whatever) and then undo (C-x u) enough times to get back to where
you started.

Nick




Re: [O] Pattch to org.texi: Document :eval no

2011-08-16 Thread Stephen Eglen
  Small patch attached, thanks Seb for pointing this out.
 
 Thanks for the patch -- I'm willing to apply it, but I'd rather apply a
 complete patch, i.e. one with a ChangeLog entry.  Can you update it?
 
 Put the cursor on your change in org.texi and use `C-x 4 a' to create a
 proper ChangeLog entry, then copy this entry to the commit message.
 
 Thanks in advance!

hi Bastien, thanks I'll remember that for future reference; for this
patch, it looks like Eric already applied it.  Stephen


commit c88c76b5519a27b3747344668d387f8561bf5fda
Author: Eric Schulte schulte.e...@gmail.com
Date:   Thu Jul 28 17:00:13 2011 -0600

doc: flesh out description of :eval header argument

  Thanks to Stephen Eglen for this patch



Re: [O] TODO type problem on speedbar and imenu.

2011-08-16 Thread Nicolas Goaziou
Hello,

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

 I am not sure this is a good idea.  With this patch, you always
 require the space to be there.  So * TODO would not be a task.
 I am not sure, this might have side effects.

Notwithstanding the fontification problem, isn't * TODO considered as
a valid task, whose text is TODO and without a keyword?

Regards,


-- 
Nicolas Goaziou



[O] formulas in spreadsheet to increase date

2011-08-16 Thread Matt Price
Hi,

It's htat time of year again and I'm putting together course syllabi.  I
would really love to be able to dynamically calculate dates in a
spreadsheet, e.g.:

|Topic 1|Date1|Description1|
|Topic2|Above Date + 7| Description2|
|Topic3|Above Date + 7| Description3|

Is there a way for me to do that?  Even better would be to be able to do the
same thing in headlines, e.g.:
** 0. 2011-09-13 Tue[[file:./syllabus/what-is-history-for][What is History
For?]]
** 1.  Last Date Plus 7
[[file:Syllabus/history-and-the-public-sphere][History and the Public
Sphere]]

but there I'm in deeper water, I think.

Thanks as always,
matt


[O] Markdown export (using org-export-generic)

2011-08-16 Thread Paul Sexton
Wes Hardaker's org-export-generic (in worg) does a pretty good job of 
exporting to markdown syntax. The following works (use C-c C-e g to 
run the exporter):

(require 'org-export-generic)
(org-set-generic-type
 markdown 
 '(:file-suffix .markdown
   :key-binding ?M
   :title-formatTitle: %s\n
   :date-format Date: %s\n
   :toc-export  nil
   :author-export   t
   :tags-export nil
   :drawers-export  nil
   :date-export t
   :timestamps-export  t
   :priorities-export  nil
   :todo-keywords-export t
   :body-line-fixed-format \t%s\n
   ;:body-list-prefix \n
   :body-list-format - %s
   :body-list-suffix \n
   :header-prefix (  ###    #  ## )
   :body-section-header-prefix (  ###    #  ## )
   :body-section-header-format %s\n
   :body-section-header-suffix (?= ?- )
   :body-header-section-numbers nil
   :body-header-section-number-format %s) 
   :body-line-format %s\n
   :body-newline-paragraph \n
   :bold-format **%s**
   :italic-format _%s_
   :verbatim-format `%s`
   :code-format `%s`
   :body-line-wrap   75
   ))

There are some defects however, which an't really be fixed without altering
the exporter code. The main ones are:

1. Nested lists don't seem to be supported.

2. Tables come out as:

col 1col 2
---+---
 1   2
 3   4

But need to look like this:

|col 1  | col 2 |
|---|---|
| 1 |  2|
| 3 |  4|

3. Links are not exported correctly.

A link [[http://www.google.com][like this]] comes out as

A link [like this]
...
[like this]: http://www.google.com

But need to look either like:

A link [like this][1]
...
[1]: http://www.google.com

Or like:

A link [like this](http://www.google.com)

Paul





Re: [O] parsing options

2011-08-16 Thread Eric Abrahamsen
On Wed, Aug 17 2011, Bastien wrote:

 Hi Eric,

 Eric Abrahamsen e...@ericabrahamsen.net writes:

 Is there a generic function for parsing options lines at the top of a
 file? 

 See `org-infile-export-plist'.

 I'd like to use some custom lines to set certain file-specific
 variables, and haven't quite figured out the best way to do that.

 It looks like org-set-regexps-and-options does that when you open a new
 file, but that's a bear of a function, and doesn't provide for setting
 your own options (or at least doesn't appear to, my eyes crossed while
 reading it).

 `org-set-regexps-and-options' is used to set options keywords and
 regexp, so depending on what you exactly want to do, you may have 
 to add your own options keywords here...

 Is there any smaller function available for our own minor modes or use
 cases? Should I just use regexp search? If there isn't anything like
 this, would one be useful (something that either found an option value
 or returned a default, or found an alist of option values, or found an
 alist of values for options matching a regexp, etc)?

 Mhh..  hard to help you more without knowing more precisely what you
 want to achieve.  Perhaps an example would help.

I'm just thinking of cases where you have a little set of functions (or
even a minor-mode built on top of Org), that users will want to specify
buffer-local settings for. Say a function that operates on subtrees
with a specific tag, but you don't want to hard-code the tag, so you let
them set it with an option at the top of the file. That could be done
with #+BIND, I guess, but it would be nicer to have
a #+SOME_FUNCTION_TAG_NAME line. Then the thing you've written gets that
option before it does anything.

Part of the reason I was suggesting this is that, properly done, it
could be used in a refactoring of the standard setup functions like
`org-infile-export-plist' and `org-set-regexps-and-options', removing
some of their complexity and adding flexibility. If this would be
undesirable or impractical, then it's probably not worth it.

(I'd still like to know the best way to provide one-off, buffer-local
settings for org functions, though!)

Thanks,
Eric




Re: [O] Reg: Publishing in html using property tags

2011-08-16 Thread Bodhi
Here you go.

On Tue, Aug 16, 2011 at 11:07 PM, Puneeth Chaganti puncha...@gmail.comwrote:

 On Tue, Aug 16, 2011 at 11:01 PM, Bodhi thebb...@gmail.com wrote:
  Nope. No luck. :(
  Both files are exported, because I can individually access foo.html and
  bar.html.

 Where does the link in foo.html point to? Can you send the sample
 files that you are using? Or a simplified version of them?

 --
 Puneeth




-- 
Regards,
Bodhisatta Barman Roy


foo.org
Description: Binary data


bar.org
Description: Binary data


Re: [O] Reg: Publishing in html using property tags

2011-08-16 Thread Puneeth Chaganti
On Wed, Aug 17, 2011 at 8:51 AM, Bodhi thebb...@gmail.com wrote:
 Here you go.

I'm not able to make my org-mode use the PROPERTY ID that's already
been defined by you. I got rid of it and created a new ID. The export
works for me.  I tested with realease_7.4 without any of my
customizations. (`emacs -Q`).  I don't know what could be wrong with
your setup.

But, I noticed one thing. Your IDs had capital alphabets, where as my
ID never gets capital alphabets.  I don't think this should be the
cause of the problem, but that's the only difference I could notice.

Can someone with more knowledge about org-id and the html export help?

--
Puneeth