[Orgmode] [ANN] It's not a bird, it's not a plane, it's... org-icons.el, reloaded !

2010-03-15 Thread Nicolas Girard
Hi all,

I'm pleased to announce a brand new, shiny release for org-icons.
A few minor limitations remain, but I think the code has matured
enough to be used on a daily basis.
See for yourself ! Grab it at [1] and see the following instructions
for installing.

I indend to win this year's Most Ridiculous Release Number Contest, so
I set the current one to 0.271182363. Wish me luck: I seem to have
some quite serious opponents... I dare you, Memoir ! [2].

[1] http://github.com/ngirard/org-icons
[2] http://www.ctan.org/tex-archive/macros/latex/contrib/memoir/


* Installation

1. Apply org-icons.patch on the latest org-mode code:
cd path/to/org-mode
patch -p0  path/to/org-icons/lisp/org-icons.patch
rm org.elc ; make ; sudo make install

2. Add org-icons/lisp to your load-path:
(setq load-path (cons /path/to/org-icons/lisp load-path))

3. Restart emacs

* Usage

- You can turn on `org-icons-mode' on startup by setting the
  org-startup-with-icons-mode variable to true,

(setq org-startup-with-icons-mode t)

- You can also enable or disable icon display on a per-buffer level, using

M-x org-icons-mode

- A key sequence can easily be used for this, like =C-c i= in this example:

(add-hook 'org-mode-hook
  (lambda () (local-set-key \C-ci 'org-icons-mode)))

* Configuration

Conceivably the Org Mode community will agree on how Org icons theme
should be defined, if they make sense. Org Mode's philosophy is to be
as generic as possible and it's not clear to me how to capture what
most people need while keeping in balance with flexibility.

Meanwhile, the set of icons that can be used, `org-icons-set', is a
little bit hardwired into the code.

More flexible are the functions governing which icon to draw, namely
`org-todo-state-icon-at', `org-priority-icon-at', `org-drawer-icon-at'
and `org-special-keyword-icon-at'. Looking at the source code should
be enough for you to redefine these functions to suit your needs. For
instance, you'll most probably want to write in your configuration

  (defun org-todo-state-icon-at (state priority tags)
(cond
  ...
)
  )

and instead of the dots, a set of (condition icon-name) like

  ((member SOMEDAY  tags ) state-someday)

or more complex, like

  ((equal  NEXT state)
 (if (= priority 2000) state-next-important state-next))

* Bugs and limitations

- Documentation is missing.
- No themes yet: see the introduction.
- When cycling from a TODO keyword to no keyword using S-right, the
  latest icon remains displayed.
- When loading an org buffer, font-lock-fontify-buffer is called twice
  if org-startup-with-icons-mode is set to t.
- The standard icon set isn't visually consistent enough

* Please consider...

- the code is still beta;
- any suggestion / contribution warmly welcome.


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Showing scheduled blocked tasks [SEC=UNCLASSIFIED]

2010-03-15 Thread Carsten Dominik


On Mar 15, 2010, at 1:23 AM, Matthew Phillips wrote:


On 12/03/2010, at 3:29 AM, Carsten Dominik wrote:

snip


On Mar 11, 2010, at 9:43 AM, Matthew Phillips wrote:

What I mean is setting it as an option in the custom commands does  
not seem to work, e.g. see list line in:


(setq org-agenda-custom-commands
...
 (d Daily Action List
  ((agenda  ((org-agenda-ndays 1)
   (org-agenda-sorting-strategy
(quote ((agenda time-up priority-down tag-up) )))
   (org-deadline-warning-days 7)))
  (tags TODO=\STARTED\+SCHEDULED=\\+DEADLINE=\\
((org-agenda-dim-blocked-tasks 'invisible)))
...

The org-agenda-dim-blocked-tasks on the generated tags view does  
not get honoured. It *does* get honoured as a setting one level  
higher, i.e. as a local setting to the whole org-agenda-custom- 
commands block, but that's not very useful here.


OK, I see now what is happening here.  The dimming of blocked tasks  
is
done only once, at the very end, when the agenda has been made.   
And that is outside the scope of the local options.


You can use a normal (custom) agenda command and do the setting  
there. Or you can use the global options for the block agenda to  
set this for the entire block agenda.  But not for a single segment  
in a bloc agenda, I am afraid.


Changing this would be significant work, and I don't want to do  
this based on a single use case.


OK, I can understand that.

So, is there any way I can use a custom skip function in the TODO  
block to remove blocked tasks? Is there a way of getting the blocked  
status of a task from such a function?


Yes, BLOCKED is a virtual property which does this.  I think you can  
just do a tags/property/todo search like this


-BLOCKED/+TODO

Or you can test for the BLOCKED property in a user-written skip  
function.


- Carsten



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [ANN] It's not a bird, it's not a plane, it's... org-icons.el, reloaded !

2010-03-15 Thread Alexander Poslavsky
On Mar 15, 2010, at 2:17 PM, Nicolas Girard wrote:

 I'm pleased to announce a brand new, shiny release for org-icons.
 A few minor limitations remain, but I think the code has matured
 enough to be used on a daily basis.

Tried it today on the latest git-version, works well. This seems a very good 
idea, is this going to be in mainline org?

Note: maybe you can add: 

#+STARTUP: hidestars

to test_icons.org, it just looks better.

thanks for your hard work,

alex

___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [ANN] It's not a bird, it's not a plane, it's... org-icons.el, reloaded !

2010-03-15 Thread Dan Davison
Alexander Poslavsky alexander.poslav...@gmail.com writes:

 On Mar 15, 2010, at 2:17 PM, Nicolas Girard wrote:

 I'm pleased to announce a brand new, shiny release for org-icons.
 A few minor limitations remain, but I think the code has matured
 enough to be used on a daily basis.

 Tried it today on the latest git-version, works well. This seems a very good 
 idea, is this going to be in mainline org?

Hi Nicolas,

My first impression is that this is really nice!

There was another thread recently about the plain theme on the org web
page, and I do agree with the idea of attempting to appeal to more
mainstream tastes in external appearance. The logic, and lisp
technology, underlying org-mode is so sophisticated and represents so
much good work, that it would be a real shame if potential users were
put off trying org-mode merely because it doesn't meet their
expectations of what a computer application looks like. With the support
for image display in modern emacs, it appears that that might be
unnecessary, as you are demonstrating.

If you have time, I'd be excited to hear your suggestions for how
begin_XXX end_XXX blocks should be displayed in your framework. (One
obvious thought is that for begin_src LANG, it would be nice to have a
different icon for each language.)

Thanks for this,

Dan




 Note: maybe you can add: 

 #+STARTUP: hidestars

 to test_icons.org, it just looks better.

 thanks for your hard work,

 alex

 ___
 Emacs-orgmode mailing list
 Please use `Reply All' to send replies to the list.
 Emacs-orgmode@gnu.org
 http://lists.gnu.org/mailman/listinfo/emacs-orgmode


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Showing scheduled blocked tasks [SEC=UNCLASSIFIED]

2010-03-15 Thread Manish
On Thu, Mar 11, 2010 at 7:04 AM, Matthew Phillips wrote:
 Hello all,

 I am trying to get a TODO tags view in my daily agenda just shows
 the first TODO of a “Project” (a la the “next action” in GTD).
 This allows me to have a TODO “tags” block in my custom agenda
 that doesn’t run to several pages: I just see the next action for
 each project, and, as each action is marked DONE, the next one
 pops up.

have you considered using org-depend? this is what i use for almost
exactly what you described:

1. a project has several TODOs
2. the first TODO (manually) is assigned a TRIGGER property with
   chain-siblings(NEXT) as value
3. as this task is marked DONE, the one below is switched to NEXT
   state and also gets the property
4. switching to NEXT causes org-todo-state-tags-triggers to tag the
   task with NEXT tag
5. a custom agenda view adds a block of these NEXT tasks

hth
-- 
manish


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] due today agenda command stopped working

2010-03-15 Thread Carsten Dominik

Hi Michael,

are you using git to keep up to date?  Then you could use git bisect  
to locate the precise commit where this behavior changed - that would  
then make it very easy to find out what is causing the problem.


- Carsten

On Mar 14, 2010, at 5:20 PM, Michael Gilbert wrote:


Hi —

A while back, Carsten helped me out with a due today custom agenda  
command. This is it:


(setq org-agenda-custom-commands
'((d Due today agenda 
   ((org-deadline-warning-days 0)
(org-agenda-skip-scheduled-if-deadline-is-shown t)
(org-agenda-skip-function
 (lambda ()
   (let* ((dl (org-entry-get nil DEADLINE)))
 (if (or (not dl)
 (equal dl )
 (org-time dl (org-time-today)))
 (progn (outline-next-heading) (point
  )

I routinely keep up with org-mode updates and recently this stopped  
working properly. What it does now is list a small subset of the  
items due today. After an hour looking at them, I can't figure out  
why it's leaving most of them out. The pattern just isn't clear to  
me. I'm wondering if something this command depends upon has  
changed. Well, probably it has, but the questions are: What changed?  
And is there another solution to the due today custom command?


Any thoughts?

— Michael



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


- Carsten





___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [PATCH 2/2] Fix adaptive filling.

2010-03-15 Thread Carsten Dominik

Hi Dan,

I have applied your patch thanks.

This is a the limit of what I can take without you signing the FSF  
papers.  Would you consider signing them?


Thanks

- Carsten

On Mar 1, 2010, at 2:49 PM, Dan Hackney wrote:

For paragraph text, `org-adaptive-fill-function' did not handle the  
base case of
regular text which needed to be filled. This commit saves a buffer- 
local value
of `adaptive-fill-regexp' and uses it if none of the org-specific  
regexps match.

This allows email-style  comments to be filled correctly.

Signed-off-by: Dan Hackney d...@haxney.org
---
lisp/org.el |   25 -
1 files changed, 20 insertions(+), 5 deletions(-)

diff --git a/lisp/org.el b/lisp/org.el
index 8ba782a..073061e 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -17289,6 +17289,12 @@ which make use of the date at the cursor.
   t t))
(org-move-to-column column)))

+(defvar org-adaptive-fill-regexp-backup adaptive-fill-regexp
+  Variable to store copy of `adaptive-fill-regexp'.
+Since `adaptive-fill-regexp' is set to never match, we need to
+store a backup of its value before entering `org-mode' so that
+the functionality can be provided as a fall-back.)
+
(defun org-set-autofill-regexps ()
  (interactive)
  ;; In the paragraph separator we include headlines, because filling
@@ -17324,8 +17330,11 @@ which make use of the date at the cursor.
  ;; and fixed-width regions are not wrapped.  That function will pass
  ;; through to `fill-paragraph' when appropriate.
  (org-set-local 'fill-paragraph-function 'org-fill-paragraph)
-  ; Adaptive filling: To get full control, first make sure that
+  ;; Adaptive filling: To get full control, first make sure that
  ;; `adaptive-fill-regexp' never matches.  Then install our own  
matcher.

+  (unless (local-variable-p 'adaptive-fill-regexp)
+(org-set-local 'org-adaptive-fill-regexp-backup
+   adaptive-fill-regexp))
  (org-set-local 'adaptive-fill-regexp \000)
  (org-set-local 'adaptive-fill-function
 'org-adaptive-fill-function)
@@ -17354,8 +17363,11 @@ which make use of the date at the cursor.
  Return a fill prefix for org-mode files.
In particular, this makes sure hanging paragraphs for hand-formatted  
lists

work correctly.
-  (cond ((looking-at #[ \t]+)
-(match-string 0))
+  (cond
+   ;; Comment line
+   ((looking-at #[ \t]+)
+(match-string-no-properties 0))
+   ;; Description list
((looking-at [ \t]*\\([-*+] .*? :: \\))
 (save-excursion
   (if ( (match-end 1) (+ (match-beginning 1)
@@ -17363,11 +17375,14 @@ work correctly.
   (goto-char (+ (match-beginning 1) 5))
 (goto-char (match-end 0)))
   (make-string (current-column) ?\ )))
-   ((looking-at [ \t]*\\([-*+] \\|[0-9]+[.)]  ?\\)?)
+;; Ordered or unordered list
+   ((looking-at [ \t]*\\([-*+] \\|[0-9]+[.)]  ?\\))
 (save-excursion
   (goto-char (match-end 0))
   (make-string (current-column) ?\ )))
-   (t nil)))
+;; Other text
+((looking-at org-adaptive-fill-regexp-backup)
+ (match-string-no-properties 0

;;; Other stuff.

--
1.6.3.3



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


- Carsten





___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] :scale option in org-format-latex-options

2010-03-15 Thread Carsten Dominik


On Mar 14, 2010, at 5:16 PM, Dan Davison wrote:


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


On Mar 14, 2010, at 8:54 AM, David Maus wrote:


Hi Dan,

Dan Davison wrote:

[...]

Is there any reason not to
make
a change like this?


I see two problems: First we should find out what x magnification
and magstep actually is and why the manual suggests using these
strange standard numbers.  And second: At least dvipng shipped  
with

debian testing

[...]

does not have a -y option.


I remember removing the option precise because some (newer?)
versions of dvipng do not have these options.  I believe you can  
use a

larger DPI to make the image larger.


Ah, right, thanks David and Carsten, I see. What I thought was the
effects of -x and -y was in fact the effect of the DPI option, which  
is
already set by :scale. So it was already working fine for my  
purposes :)


I think the following is a docstring typo (org-format-latex-options),
right?

--8---cut here---start-8---
diff --git a/lisp/org.el b/lisp/org.el
index aa22309..e5d046e 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -2860,7 +2860,7 @@ This is a property list with the following  
properties:

 \$\  find math expressions surrounded by $...$
 \$$\ find math expressions surrounded by $$$$
 \\\(\ find math expressions surrounded by \\(...\\)
- \\\ [\find math expressions surrounded by \\ [... 
\\]
+ \\\[\find math expressions surrounded by \\[...\ 
\]

  :group 'org-latex
  :type 'plist)
--8---cut here---end---8---



:-)  That definitely looks like a typo, but is is not.  Try to apply  
you patch and then look at the docstring using C-h v:-)


\\[  ]  is treated special in docstrings.

If you find a way to do this without breaking the docstring, I'd love  
to hear about it.


- Carsten



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [PATCH 2/2] Fix adaptive filling.

2010-03-15 Thread Daniel Hackney
Carsten Dominik carsten.domi...@gmail.com wrote:
 I have applied your patch thanks.

I'm glad that you found it useful!

 This is a the limit of what I can take without you signing the FSF
 papers. Would you consider signing them?

Absolutely. I submitted an application about a week ago (for my work on
package.el), but haven't heard back yet. I am certainly willing to sign
over these patches, if that makes things more convenient.

I can let you know once my papers have gone through. I definitely intend
to keep contributing to org-mode!

--
Daniel M. Hackney


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


[Orgmode] faster refile history

2010-03-15 Thread Samuel Wales
I use ido refile.

I have restricted refile for speed, which uses a tag.  It is
still slow, but somewhat faster than a less restricted refile.

I have a less-restricted refile for getting more headlines.
It is ridiculously slow.

But there is a subtle problem with refile history.

  1) I do less-restricted refile, which is slow.  This is
 M-x org-refile.  I refile using it to headline alpha.
  3) I refile to headline beta using any type of
 refile
  4) I want to refile another headline to headline alpha (or go to it).
 This is ideally done using refile history.
  5) So I do M-x restricted refile (or c-u)
  6) Then up arrow twice to get headline alpha
  7) Then RET to select it
  8) This does not work because headline alpha is not part
 of the restricted refile set
  9) So I actually have to use less-restricted refile in
 order to refile to headline alpha
  10) But this is a problem because it is too slow to come
  up with the ido interface in order to do so.

I wonder if it makes sense to be able to access refile
history no matter what refile targets is set to.

Thanks.

-- 
Q: How many CDC scientists does it take to change a lightbulb?
A: You only think it's dark. [CDC has denied a deadly disease for 25 years]
==
Retrovirus: http://www.wpinstitute.org/xmrv/index.html


___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] [PATCH 2/2] Fix adaptive filling.

2010-03-15 Thread Carsten Dominik


On Mar 15, 2010, at 8:04 PM, Daniel Hackney wrote:


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

I have applied your patch thanks.


I'm glad that you found it useful!


This is a the limit of what I can take without you signing the FSF
papers. Would you consider signing them?


Absolutely. I submitted an application about a week ago (for my work  
on

package.el), but haven't heard back yet.


If you have other things besides org-mode, you mind want to get a  
past and future changes to Emacs, which will cover anything you  
contribute to Emacs.




I am certainly willing to sign
over these patches, if that makes things more convenient.

I can let you know once my papers have gone through.


Please do hat indeed, thanks.

- Carsten


I definitely intend
to keep contributing to org-mode!

--
Daniel M. Hackney


- Carsten





___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] %3f shouldn't be unescaped in HTTP URLs

2010-03-15 Thread Ivan Vilata i Balaguer
Sebastien Delafond (el 2010-03-09 a les 17:36:16 +) va dir::

 Quoting from Debian bug #573186[0]:
 
   Some HTTP URLs have literal '?' in them.  Since '?' also separates the
   path from query arguments, it needs to be escaped in the first case.
   These are examples of the two cases:
 
   - http://en.wikipedia.org/wiki/Who%27s_Afraid_of_Virginia_Woolf%3F
 (literal '?')
   - http://www.google.com/search?q=org+mode (query separator)
 
   These are the URLs generated by Org mode when exporting them to HTML:
 
   - http://en.wikipedia.org/wiki/Who%27s_Afraid_of_Virginia_Woolf?
   - http://www.google.com/search?q=org+mode
 
   I.e. '?' is left as is, but '%3f' is unescaped, producing the wrong
   URL (don't be fooled by the fact that Wikipedia actually accepts it ;)
   ).  This makes impossible to correctly export an HTTP URL with a
   literal question mark in it.
 
   The solution would be to leave '%3f' as is, too, in the same way as
   '%27' has been left as is in the previous example.

Hasn't anyone come across this behaviour?  I think it's a bug which should be
fixed since it makes some URLs impossible to write.  And according to that last
sentence, the solution doesn't seem too hard.

Thanks and cheers,

::

  Ivan Vilata i Balaguer -- http://ivan.lovesgazpacho.net/


signature.asc
Description: Digital signature
___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] %3f shouldn't be unescaped in HTTP URLs

2010-03-15 Thread Carsten Dominik


On Mar 15, 2010, at 8:17 PM, Ivan Vilata i Balaguer wrote:


Sebastien Delafond (el 2010-03-09 a les 17:36:16 +) va dir::


Quoting from Debian bug #573186[0]:

 Some HTTP URLs have literal '?' in them.  Since '?' also separates  
the

 path from query arguments, it needs to be escaped in the first case.
 These are examples of the two cases:

 - http://en.wikipedia.org/wiki/Who%27s_Afraid_of_Virginia_Woolf%3F
   (literal '?')
 - http://www.google.com/search?q=org+mode (query separator)

 These are the URLs generated by Org mode when exporting them to  
HTML:


 - http://en.wikipedia.org/wiki/Who%27s_Afraid_of_Virginia_Woolf?
 - http://www.google.com/search?q=org+mode

 I.e. '?' is left as is, but '%3f' is unescaped, producing the wrong
 URL (don't be fooled by the fact that Wikipedia actually accepts  
it ;)

 ).  This makes impossible to correctly export an HTTP URL with a
 literal question mark in it.

 The solution would be to leave '%3f' as is, too, in the same way as
 '%27' has been left as is in the previous example.


Hasn't anyone come across this behaviour?  I think it's a bug which  
should be
fixed since it makes some URLs impossible to write.  And according  
to that last

sentence, the solution doesn't seem too hard.


Hi Ivan,

the bug has not yet been fixed because my time is limited.  Please  
consider submitting a patch.


- Carsten



___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode


Re: [Orgmode] Showing scheduled blocked tasks [SEC=UNCLASSIFIED]

2010-03-15 Thread Matthew Phillips
On 16/03/2010, at 12:24 AM, Carsten Dominik wrote:

 On Mar 15, 2010, at 1:23 AM, Matthew Phillips wrote:

snip

 So, is there any way I can use a custom skip function in the TODO block to 
 remove blocked tasks? Is there a way of getting the blocked status of a task 
 from such a function?
 
 Yes, BLOCKED is a virtual property which does this.  I think you can just do 
 a tags/property/todo search like this
 
 -BLOCKED/+TODO”

That query still shows the blocked tasks, unfortunately.

 Or you can test for the BLOCKED property in a user-written skip function.

I’ll follow this route next...

Thanks very much for your help, Carsten.

Cheers,

Matthew.
IMPORTANT: This email remains the property of the Australian Defence 
Organisation and is subject to the jurisdiction of section 70 of the CRIMES ACT 
1914.  If you have received this email in error, you are requested to contact 
the sender and delete the email.




___
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode