Re: [Orgmode] Is it possible to expand the quick tag selection key

2010-03-21 Thread Carsten Dominik


On Mar 21, 2010, at 6:30 AM, Chao Lu wrote:


Dear all,

As I'm using more and more tags, I found the keys are not enough. It  
is possible to define keymaps like emacs?



(setq org-tag-alist '((Culture . ?c)
(ComputerSE . ?C)
  (English . ?e)
  (GuoXue . ?g)
(Humor . ?h)
  (IMP . ?i)
  (LIB . ?l)
  (Life . ?L)
;  (Love . ?)
;  (List . ?)
  (Mathematics . ?m)
  (MAYBE . ?M)
  (Obtain . ?o)
  (Org . ?O)
  (Physics . ?p)
  (P525 . ?P)
  (Question . ?q)
  (TODO . ?t)
  (Video . ?v)
  ))



No, we do not have keymaps for this.
You can press TAB at the tags interface and use completion.

- Carsten




The best,

Chao
___
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] Tag inheritance

2010-03-21 Thread Carsten Dominik


On Mar 21, 2010, at 6:35 AM, Chao Lu wrote:


Dear all,

Is it possible for all the headlines inherit tags from the filename?  
If we could make it a in-buffer setting, that will be great. For  
example, I usually write notes related to Emacs in a file called  
Emacs.org. ^.^


Hi Chao,

that would be

#+FILETAGS: Emacs

HTH

- Carsten



All the best,

Chao

___
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] org-crypt.el --- Public key encryption for org-mode entries

2010-03-21 Thread Carsten Dominik


On Sep 29, 2007, at 5:48 AM, John Wiegley wrote:

The following code is preliminary, but gets the job done in my  
simple tests.
Now's the time to beat down on, and refine, the user interface and  
behavior.


[...]

;; 3. To later decrypt an entry, use `M-x org-decrypt-entry'.  It  
might be
;;useful to bind this to a key, like C-c C-/.  I hope that in  
the future,

;;C-c C-r can be might overloaded to also decrypt an entry if it's
;;encrypted, since that fits nicely with the meaning of reveal.


This is now the case, when org-crypt is loaded, C-c C-r will also  
decrypt.


- 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] A testing framework (was: Testing)

2010-03-21 Thread Carsten Dominik

Hi Martin,

thanks for this.

we had an earlier threads about testing frameworks:

http://orgmode.org/worg/org-tests/index.php

http://thread.gmane.org/gmane.emacs.orgmode/8759/focus=8775

http://thread.gmane.org/gmane.emacs.orgmode/8743/focus=8743

I think it would be great to have a testing framework and a
lot of tests, but I do not have time to make this happen.
Maybe you can try to get the people who were active in those
threads and energize them?

- Carsten


On Mar 20, 2010, at 1:18 AM, Martin Pohlack wrote:


Hi Again,

I assume all of you ignored my previous email due to me choosing a
clever subject :-/.

I went ahead anyway and implemented a first version of the framework.

It currently contains 2 sample test cases, one that works and one that
fails with my org-mode version.

3. and 4. may need some wild-card representation for the timestamps  
in

order to make the equality comparison portable.


This problem is currently solved by filtering the output and comparing
generalized output.

Please have a look at the framework here:

 http://github.com/martinp26/org-mode-test

Cheers,
Martin Pohlack


___
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] Org babel R Help

2010-03-21 Thread Joseph Cole



Joseph Cole coljo...@student.otago.ac.nz writes:


I've been struggling with a few aspects of org babel R:

1) src_R surrounds output with ==.

E.g. src_R{1+1} gives =2=

I would expect it to just give 2. Because it surrounds the output with
equals signs, this means you are unable to use the output in latex
equations, general text or tables as it's ugly.


Hi Joseph,

If you use ':results raw', then the results will be inserted without the
surrounding '='. You will need to pull the latest git head as I just
fixed a bug regarding that. So you could use

src_R[:results raw]{1+1}

but to make it less clumsy you could configure
org-babel-default-inline-header-args, e.g.

(setq org-babel-default-inline-header-args
     (org-babel-merge-params org-babel-default-inline-header-args
'((:results . raw

after which

\begin{equation}
1 + src_R{1+1} = 3
\end{equation}

exports to latex as

\begin{equation}
1 + 2 = 3
\end{equation}

As for the default behaviour, the == declares that the contents should
be formatted fixed-width on export. Normally in latex export that
results in \texttt{}, but I see that inside a begin_equation the ==
remain. I wonder whether that could be argued to be an org-mode latex
exporter bug?


Thanks for the help, I'm pulling down the head to test.
It certainly would make more sense to embed raw automatically within  
equations.






Where should I start looking to fix this? I'm a lisp novice but happy
to learn.


org-babel-exp.el


Thanks. The code makes sense.


2) Width/Height exports for R graphics output. Do they work?

I've tried a lot of combinations of :width and :height as exports, and
they don't seem to work at all. I've tried small numbers (1-10), large
numbers (100-2000) and numbers prefixed by cm with no luck.


Hmm, I'm not seeing a problem here. It works for me with both png and
pdf output. E.g.

#+begin_src R :file z.pdf :width 20 :height 40 :exports both
plot(1:10)
#+end_src



What image format (i.e. R graphics device) are you using?  Can you post
an example block that is not working? The values for :width and :height
will be passed straight on to the graphics device, so their meaning
depends on which graphics device is being used in R.


I'm trying the code you posted with the latest org-mode from ubuntu  
and getting nothing in my results if I use png. If I use pdf, I get a  
really tiny chart which is incomprehensible. Width and height seem to  
work randomly, as using 20:40 work with pdf (although tiny), but  
100,100 do not work at all.


It only works correctly if I use the #+attr_latex: width=Xcm and omit  
the width and height.


I'm using ubuntu jaunty fully up to date, org mode from the website  
(6.34c), R 2.92, and the stock standard latex install for ubuntu.






I know I can use #+attr_latex: width=15cm.

3) R-graphics quality

I can't seem to find any examples of how to set the R graphics output
quality, and nothing I try seems to alter the result (using :quality).


I'm not sure what you mean by R graphics output quality. The section
Graphical output in

http://orgmode.org/worg/org-contrib/babel/languages/org-babel-doc-R.php

describes how to pass arguments to the R graphics devices. In addition
to the ones that org-babel knows about like :width, you can pass
arbitrary extra arguments to the R device using :R-dev-args.



Are there any publication quality r-graphics examples I could take a
look at, as I've been unable to find any on google.


You mean using org-babel or just using R?


Using babel. For some reason my R graphics embedded within my pdf's  
don't seem to be as nice as viewing them from within R, i.e.  
slightly fuzzy edges. It's like the antialiasing has failed or  
something. The text labels on the axes are definitely not up to latex  
standard.


Best regards,
Joe


___
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] dangling clock message might be incomprehensible to a few users

2010-03-21 Thread Friedrich Delgado Friedrichs
Hi!

I'd like to chime in here:
Samuel Wales schrieb:
 Here is part of it:
 
   [(kK)p (sS)ub (C)ncl (i)gn]? )
 
 Some users might ask:
 
 kp=?  Keep?  Keep what?
 sub=subtract what from what?
 cncl=cancel command?  Why C only?
 ign=ignore what?   Why i only?
---Zitatende---

I'd also appreciate it if there was an option to give a time when the
clock should end, instead of just a number of minutes to keep. It's
easier for me to figure out when I ended work on the task, than how
minutes I spent on it.

Also I think the last clock entry isn't always displayed, which makes
it even harder to figure out how to answer the 'k' question.


-- 
Friedrich Delgado Friedrichs frie...@nomaden.org
 TauPan on Ircnet and Freenode ;)


___
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] Org babel R Help

2010-03-21 Thread Graham Smith
Joseph/Dan

 2) Width/Height exports for R graphics output. Do they work?

 I've tried a lot of combinations of :width and :height as exports, and
 they don't seem to work at all. I've tried small numbers (1-10), large
 numbers (100-2000) and numbers prefixed by cm with no luck.

 Hmm, I'm not seeing a problem here. It works for me with both png and
 pdf output. E.g.

 #+begin_src R :file z.pdf :width 20 :height 40 :exports both
 plot(1:10)
 #+end_src

 What image format (i.e. R graphics device) are you using?  Can you post
 an example block that is not working? The values for :width and :height
 will be passed straight on to the graphics device, so their meaning
 depends on which graphics device is being used in R.

 I'm trying the code you posted with the latest org-mode from ubuntu and
 getting nothing in my results if I use png. If I use pdf, I get a really
 tiny chart which is incomprehensible. Width and height seem to work
 randomly, as using 20:40 work with pdf (although tiny), but 100,100 do not
 work at all.

 It only works correctly if I use the #+attr_latex: width=Xcm and omit the
 width and height.

Based on what is happening here with me on Ubuntu 9.10, R 2.10 and orgmode 6.34.

The  :file z.pdf :width 20 :height 40 :exports both  is affecting
the size of the graphic that R produces. If you open x.pdf directly
you will find that it changes size as expected.

BUT regardless of the size of the z.pdf, Latex defaults to a fixed,
and tiny, standard size.  Unless you give an explicit latex command
#+attr_latex: width=Xcm


 Using babel. For some reason my R graphics embedded within my pdf's don't
 seem to be as nice as viewing them from within R, i.e. slightly fuzzy
 edges. It's like the antialiasing has failed or something. The text labels
 on the axes are definitely not up to latex standard.

Are you just viewing them or printing them. I find with Ubuntu that
the default viewer seems to arbitrarily  change between programs and
the quality of graphics on the screen varies, but the quality of
printed output stays the same. Try opening the final PDF in an
alternative viewer and see if things still appear the same.

Graham


___
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] Is there a way to fill org-mode's table cell with the values nearby?

2010-03-21 Thread filebat Mark
Hi All

I am wondering whether we have a handy way to fill table's cell with the
values nearby.
Like in office excel:
- C-d: Fill current cell with the value of the upper cell
- C-r: Fill current cell with the value of the left cell.

-- 
Thanks  Regards

Denny Zhang
___
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] org-mac-addressbook.el

2010-03-21 Thread Alexander Poslavsky
Hello,

playing around with mac integration and org (using org-mac-protocol) I wrote 
mac address-book integration. It is slightly based on org-mac-message. It is 
the first ever lisp and/or applescript I ever wrote, so … but it works.

New hyperlink: [[address:BC70B043-0144-4AC1-9FFA-9D33F04C8B8A:ABPerson][Name]], 
which, when clicked will open the entry in the address book. It works for both 
persons as companies.

Adding a link to org is done using org-remember (and quicksilver).

thanks,

Alex

Attached: a diff to getItemMetadata from org-mac-protocol, and a new file 
called org-mac-addressbook



getItemMetadata.applescript.diff
Description: Binary data




org-mac-addressbook.el
Description: Binary data



___
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] Re: Clocking in the current task should clock it out first

2010-03-21 Thread Daniel Clemente
El vie, mar 19 2010 a les 18:36, Carsten Dominik va escriure:
 Hi,

 strangely enough, this does not happen for me.  Maybe you
 have some setup for clock resolution that I do not have?


No. Just Emacs:
GNU Emacs 24.0.50.1 (i686-pc-linux-gnu, GTK+ Version 2.18.6) of 2010-03-13

I used this .emacs:
(add-to-list 'load-path /w/org-mode/lisp) (require 'org-install)
(add-to-list 'load-path /w/org-mode/contrib/lisp)
(require 'org)


Commit 29d945720095a65852f69b7c628c1199eb4961fe (Date:   Fri Nov 27 08:09:10 
2009 +0100) was done precisely to leave clocks open; the bad behaviour comes 
from this change.
Via bisect I found that the previous revision was good and the next revision 
bad.


-- Daniel


___
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] Org babel R Help

2010-03-21 Thread Dan Davison
Graham Smith myotis...@gmail.com writes:

 Joseph/Dan

 2) Width/Height exports for R graphics output. Do they work?

 I've tried a lot of combinations of :width and :height as exports, and
 they don't seem to work at all. I've tried small numbers (1-10), large
 numbers (100-2000) and numbers prefixed by cm with no luck.

 Hmm, I'm not seeing a problem here. It works for me with both png and
 pdf output. E.g.

 #+begin_src R :file z.pdf :width 20 :height 40 :exports both
 plot(1:10)
 #+end_src

 What image format (i.e. R graphics device) are you using?  Can you post
 an example block that is not working? The values for :width and :height
 will be passed straight on to the graphics device, so their meaning
 depends on which graphics device is being used in R.

 I'm trying the code you posted with the latest org-mode from ubuntu and
 getting nothing in my results if I use png.

Hi Joseph,

I also get nothing with png:
,
| #+begin_src R :file z.png :width 20 :height 40 :exports both
`
If you do C-c C-c on the block, you should get an error buffer
explaining why
,
| Error in plot.new() : figure margins too large
| Calls: write.table ... inherits - main - plot - plot.default - plot.new
| Execution halted
`
In R, for png(), jpg() et al, the default units for width and height are
pixels. For pdf() and ps() width and height are in inches. So while 20
and 40 are sensible values for pdf they are not for png.

 If I use pdf, I get a really
 tiny chart which is incomprehensible. Width and height seem to work
 randomly, as using 20:40 work with pdf (although tiny), but 100,100 do not
 work at all.

What do you mean when you say 100,100 do not work at all? What I get
is something which looks very much like a blank plot inserted into the
pdf. However if you look closely, it is in fact a scaled down version of
a large pdf (100 inches by 100 inches). The axes, plotting characters
and label annotation are very hard to see because they have not been
scaled up and are tiny relative to the plot dimensions.


 It only works correctly if I use the #+attr_latex: width=Xcm and omit the
 width and height.

 Based on what is happening here with me on Ubuntu 9.10, R 2.10 and orgmode 
 6.34.

 The  :file z.pdf :width 20 :height 40 :exports both  is affecting
 the size of the graphic that R produces. If you open x.pdf directly
 you will find that it changes size as expected.

 BUT regardless of the size of the z.pdf, Latex defaults to a fixed,
 and tiny, standard size.  Unless you give an explicit latex command
 #+attr_latex: width=Xcm


Thanks Graham for the further explanation.

So I believe we do understand the situation. The question is how do we
improve it. First the facts:

1. With png R graphics :width and :height specify pixel dimensions and
   must be sensible for the graphic to be produced without an R error.
2. With pdf R graphics, :width and :height are in inches. However, the
   pdf output produced by org rescales the resulting image down to a
   small default size.

So as Graham has explained, a good approach at the moment is to create
the graphics with C-c C-c in buffer, get rid of ':exports both', and
manually insert an ATTR_LaTeX line. You may or may not want to
use :width and :height to set plot dimensions in R, in addition to the
rescaling at the latex stage. See also Graham's recent thread

[babel] captions and figure size on export
http://comments.gmane.org/gmane.emacs.orgmode/22837

As for improvements, it is tempting to think that 

1. org-babel should automatically insert the ATTR_LaTeX line in
   accordance with :width and :height when creating latex output.
2. org-babel should keep existing ATTR_LaTeX lines attached to their
   respective figures (contra Graham's thread linked above)

I've had a brief look and doubtless all this is possible. It brings up
issues of what units :width and :height are assumed to be in (e.g. just
because R uses inches for pdf() doesn't mean that anyone else thinks
that's a sensible decision). And we have to be a careful because it
means altering what org-babel considers to be part of its results.


 Using babel. For some reason my R graphics embedded within my pdf's don't
 seem to be as nice as viewing them from within R, i.e. slightly fuzzy
 edges. It's like the antialiasing has failed or something. The text labels
 on the axes are definitely not up to latex standard.

OK, well we definitely don't want org-babel to be producing sub-par pdf
images, so it would be very helpful if you could help us further
here. First, can we determine whether this is an org-mode/org-babel
issue or an R/latex/pdf issue? E.g. If you create a pdf in R and embed
it in a LaTeX document manually does it come out looking better than the
equivalent operation done in org-babel? What about if you use postscript
output rather than pdf? If you use Sweave, how does the image in the pdf
output of Sweave compare to that of org-babel? Any further
investigations here would be much appreciated.

Dan


[Orgmode] Problem using bracket with the LaTeX backend

2010-03-21 Thread Günter Kolousek


I think there is a problem using brackets at the beginning
of plain list items with the LaTeX backend:

  1. [A] foo bar...

The generated LaTeX code looks like:

  \item[A] foo bar...

but rather this would be the expected output:

  \item{}[A] foo bar...

Here follows the patch:

*** org-list.el 2010-03-21 15:33:49.0 +0100
--- org-list.el.old 2010-03-21 15:26:38.0 +0100
***
*** 1336,1342 
   :dstart \\begin{description} :dend \\end{description}
   :dtstart [ :dtend ]
   :ddstart  :ddend 
!  :istart \\item{}  :iend 
   :isep \n :lsep \n
   :cbon \\texttt{[X]} :cboff \\texttt{[ ]})
  params)))
--- 1336,1342 
   :dstart \\begin{description} :dend \\end{description}
   :dtstart [ :dtend ]
   :ddstart  :ddend 
!  :istart \\item  :iend 
   :isep \n :lsep \n
   :cbon \\texttt{[X]} :cboff \\texttt{[ ]})
  params)))

Cheers and thanks a lot for the wonderful org-mode!
Günter


___
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] Highlighting current header and its contents

2010-03-21 Thread Tom
One of my main gripes with orgmode is often I cannot make out
clearly when the text content of an opened header ends and the
next header begins, because there is no apparent visual
indication.

Of course, I can add empty lines manually to the end of the
content, but this solution is not really satisfying (I don't need
empty lines there, I add them only to see better where the
content ends).

I'm still thinking of a proper solution for this problem, but I'm
posting one of my attempts for the time being which some may find
useful. It highlights the header the cursor is in and its contents with a
different background color:


(make-variable-buffer-local 'my-org-highlight-overlay)

(add-hook 'post-command-hook 'my-org-highlight)


(defun my-org-highlight ()
  (when (and (eq major-mode 'org-mode)
 (sit-for 0.1))
(unless my-org-highlight-overlay
  (setq my-org-highlight-overlay (make-overlay 0 0))
  (overlay-put my-org-highlight-overlay 'face '(:background azure)))

(let ((header (save-excursion
(beginning-of-line)
(looking-at outline-regexp

  (move-overlay my-org-highlight-overlay
(save-excursion
  (if header
  (beginning-of-line)
(outline-previous-visible-heading 1))
  (point))
(save-excursion
  (outline-next-visible-heading 1)
  (point))




___
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] forcing the end of

2010-03-21 Thread Łukasz Stelmach
Hello.

It's been said couple of times that there is no way in org mode to jump
back on the higher level of the outline tree without creating a new node
on that level. After thinking for a while I've agreed that there is no
need for this. There isn't such things in books. However I start to miss
it and I'll give an example of how I'd use it.

I publish some materials for my students. For example test questions. As
you might expect I'd like to keep them secret until the test starts. So
I write this:

--8---cut here---start-8---
** OpenOffice Writer ( [2010-03-21 nie] ) :ATTACH:
#+HTML: ?php if(time() - mktime(10, 50, 00, 3, 28, 2010)  0) { ?

  The questions will be availble on Sunday at 10:50.

#+HTML: ?php } else { ?

  + How to write a poem?
  + How to create a graph?
  + How?

#+HTML: ?php } ?
--8---cut here---end---8---

What I get is roughly this:

--8---cut here---start-8---
div id=outline-container-1.3 class=outline-3
h3 id=sec-1.3span class=section-number-31.3/span OpenOffice Writer 
( span class=timestamp-wrapper span class=timestamp2010-03-21 
nie/span/span )/h3
div class=outline-text-3 id=text-1.3


?php if(time() - mktime(10, 50, 00, 3, 28, 2010)  0) { ?
p
The questions will be availble on Sunday at 10:50.
/p

?php } else { ?
ul
li
How to write a poem?
/li
li
How to create a graph?
/li
li
How?

?php } ?
/li  !-- these two should be --
/ul  !-- above the ?php }? tag --
/div
/div
/div
--8---cut here---end---8---

Which makes the HTML code that comes out of PHP invalid as  because of
those dangling /li/ul (/divs seem to be OK here).

How? How to force org-mode to close this plain list befor the php
closing curly bracket?

PS. If I add a node below the list some of its cloing /divs go below
the ?php } ? too.
-- 
Miłego dnia,
Łukasz Stelmach



___
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] Is there a way to fill org-mode's table cell with the values nearby?

2010-03-21 Thread Chris Randle

Denny Zhang (filebat Mark) wrote:
I am wondering whether we have a handy way to fill table's cell with the 
values nearby.


S-RET will do the trick. If the current cell is empty, it copies the 
first non-blank line above. If the current cell is not empty, it copies 
and moves to the cell below. It will also (depending on value of 
org-table-copy-increment) increment integer values as it does so.


If you supply an arg, S-RET copies from that many non-empty lines above. 
With a 0 (zero) as the arg, it disables the integer increment for the 
next copy.


There's a description on p.18 of v6.34c of the manual.

--
Chris Randle.


___
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] Re: forcing the end of

2010-03-21 Thread Łukasz Stelmach
Łukasz Stelmach lukasz.stelm...@iem.pw.edu.pl writes:

 I publish some materials for my students. For example test questions. As
 you might expect I'd like to keep them secret until the test starts. So
 I write this:

--8---cut here---start-8---
 ** OpenOffice Writer ( [2010-03-21 nie] ) :ATTACH:
 #+HTML: ?php if(time() - mktime(10, 50, 00, 3, 28, 2010)  0) { ?

   The questions will be availble on Sunday at 10:50.

 #+HTML: ?php } else { ?

   + How to write a poem?
   + How to create a graph?
   + How?

 #+HTML: ?php } ?
--8---cut here---end---8---

 What I get is roughly this:

--8---cut here---start-8---
 How?

 ?php } ?
 /li  !-- these two should be --
 /ul  !-- above the ?php }? tag --
 /div
 /div
 /div
--8---cut here---end---8---

 Which makes the HTML code that comes out of PHP invalid as  because of
 those dangling /li/ul (/divs seem to be OK here).

 How? How to force org-mode to close this plain list befor the php
 closing curly bracket?

OK. I've found a hack. I put three empty lines between the last How?
and the ?php } ? in the middle one I put U200B (ZERO WIDTH SPACE)
which induces closing of the list and creation of an empty paragraph
p/p. Yet I'd like to see something cleaner.


PS. U00A0 NO-BREAK SPACE works too and it's better because Emacs
fontifies it. Shouldn't be exported as a HTML entity nbsp;?

-- 
Miłego dnia,
Łukasz Stelmach



___
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] Org babel R Help

2010-03-21 Thread Graham Smith
Dan

 So I believe we do understand the situation. The question is how do we
 improve it. First the facts:

 As for improvements, it is tempting to think that

 1. org-babel should automatically insert the ATTR_LaTeX line in
   accordance with :width and :height when creating latex output.
 2. org-babel should keep existing ATTR_LaTeX lines attached to their
   respective figures (contra Graham's thread linked above)

 I've had a brief look and doubtless all this is possible. It brings up
 issues of what units :width and :height are assumed to be in (e.g. just
 because R uses inches for pdf() doesn't mean that anyone else thinks
 that's a sensible decision). And we have to be a careful because it
 means altering what org-babel considers to be part of its results.

Now that I know what is happening I am reasonably content with it as it is.

However, it would seem to make sense that :width and :height commands
should relate to the image size in the compiled pdf.  And it would
also make sense that these should be consistently in mm, regardless of
file format.

Graham


___
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] Highlighting current header and its contents

2010-03-21 Thread Dan Davison
Tom levelha...@gmail.com writes:

 One of my main gripes with orgmode is often I cannot make out
 clearly when the text content of an opened header ends and the
 next header begins, because there is no apparent visual
 indication.

 Of course, I can add empty lines manually to the end of the
 content, but this solution is not really satisfying (I don't need
 empty lines there, I add them only to see better where the
 content ends).

 I'm still thinking of a proper solution for this problem, but I'm
 posting one of my attempts for the time being which some may find
 useful. It highlights the header the cursor is in and its contents with a
 different background color:

Hi Tom,

Your overlay code's instructive for me, but I don't understand the
problem it's solving. Isn't the next heading made sufficiently distinct
by being bold and coloured and having an asterisk in front of it?

Dan



 (make-variable-buffer-local 'my-org-highlight-overlay)

 (add-hook 'post-command-hook 'my-org-highlight)


 (defun my-org-highlight ()
   (when (and (eq major-mode 'org-mode)
  (sit-for 0.1))
 (unless my-org-highlight-overlay
   (setq my-org-highlight-overlay (make-overlay 0 0))
   (overlay-put my-org-highlight-overlay 'face '(:background azure)))

 (let ((header (save-excursion
 (beginning-of-line)
 (looking-at outline-regexp

   (move-overlay my-org-highlight-overlay
 (save-excursion
   (if header
   (beginning-of-line)
 (outline-previous-visible-heading 1))
   (point))
 (save-excursion
   (outline-next-visible-heading 1)
   (point))




 ___
 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


[Orgmode] Re: Highlighting current header and its contents

2010-03-21 Thread Tom
Dan Davison davison at stats.ox.ac.uk writes:
 
 Your overlay code's instructive for me, but I don't understand the
 problem it's solving. Isn't the next heading made sufficiently distinct
 by being bold and coloured and having an asterisk in front of it?
 

Not really. My headings are not bold, because it's too heavy for
the eyes when several headings without content follow each
other. Too much boldness. :)

The color and the asterisk sometimes melt into the surroundings
when there is lots of text before it. Not distinctive enough.

The problem is I don't want to make headers too distinctive,
because when I use lots of empty headers below each other then I
don't want them to glow in my face. On the other hand, when
headings have text content then it should be separated clearly
from the surrounding headings.

Clearly, others have similar problems with it judging from the lots of
possible values of org-cycle-separator-lines.

But it's subjective, of course.






___
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] Re: Writing a dissertation using org-mode

2010-03-21 Thread Thomas S. Dye

Hi Carsten,

I added an entry to the Export section of the FAQ.

All the best,
Tom

On Mar 9, 2010, at 6:27 AM, Carsten Dominik wrote:


Hi Thomas,

I think this explanation would be good to have (a bit longer, maybe)  
in the FAQ.


- Carsten

On Mar 7, 2010, at 4:10 AM, Thomas S. Dye wrote:



On Mar 6, 2010, at 1:54 PM, Eric S Fraga wrote:

I have to agree with Torsten: I'd write the thesis directly in  
LaTeX,

only because of the power of AUCTeX and RefTeX (and preview, if you
have lots of plots and math).


For me, org-mode's power overwhelms what auctex brings to the show.
Not having to worry about any \begins etc not only keeps the text
cleaner, it helps me in my continuing battle against RSI!

However, I do agree that reftex is particularly useful and I do miss
some aspects of it.

The preview aspects will of course depend on the topic of the  
thesis!


Aloha Eric,

I have this in my emacs starter-kit and it gives me access to  
reftex in latex code blocks in org-babel.  I've changed a few  
things from the code I found on the link provided, which has two  
methods of integrating reftex with org-mode.  The link also  
provides suggestions for key-bindings within org-mode.  Perhaps you  
don't have to miss reftex anymore.


*** ON Org-mode RefTeX setup
   - Kevin Brubeck Unhammer, [[http://www.mfasold.net/blog/2009/02/using-emacs-org-mode-to-draft-papers/ 
][Reftex Setup]]

#+begin_src emacs-lisp :tangle yes
 (defun org-mode-article-modes ()
   (reftex-mode t)
   (and (buffer-file-name)
(file-exists-p (buffer-file-name))
(reftex-parse-all)))

 (add-hook 'org-mode-hook
(lambda ()
  (if (member REFTEX org-todo-keywords-1)
  (org-mode-article-modes
#+end_src

I was struggling without reftex!

All the best,
Tom

Thomas S. Dye, Ph.D.
T. S. Dye  Colleagues, Archaeologists, Inc.
Phone: (808) 529-0866 Fax: (808) 529-0884
http://www.tsdye.com


___
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] A testing framework

2010-03-21 Thread Martin Pohlack
Hi Carsten, all,

On 21.03.2010 08:26, Carsten Dominik wrote:
 we had an earlier threads about testing frameworks:
 
 http://orgmode.org/worg/org-tests/index.php
 
 http://thread.gmane.org/gmane.emacs.orgmode/8759/focus=8775
 
 http://thread.gmane.org/gmane.emacs.orgmode/8743/focus=8743

Very interesting, I just went through all this.

From above material, two general approaches have been considered for
testing org-mode:
* Lisp based unit testing.
* Example-file based feature testing.

I am targeting the second approach here for now as I think it may
provide more benefit per time spent and would allow more people to
participate easily.

I hope that every emacs user will be able to write tests with my
framework.  Basically only an example test case and the expected
result should be need for tests, together with a minimal description
of the setup.

If only an example file triggering a bug is available, a corresponding
test can be crafted with minimal effort.


For now I have a minimal framework running with two tests
demonstrating expected behavior for folding and a bug in the version
I'm using.

I would like to enquire comments regarding the following open issues,
where I have no satisfying solution yet:

* I would like to start the test in something like a temporally stable
  setup, such that generated timestamps would be somewhat predictable
  (basically with the system clock set to 1.1.2005 20:00, or something
  like that).

  There are several levels where this could be achieved, ranging from:
  1. Experimental patches to the Linux kernel,
  2. Library wrappers using LD_PRELOAD around emacs to virtualize the
 time and gettimeofday system calls,
  3. Advised lisp functions for obtaining time stamps, and
  4. Post processing the test output to generalized time stamps.

  Currently, I'm going with 4, 3 may make sense if someone could
  identify the hopefully 2-3 functions to be advised.

  2 and 1 are probably too Linux specific and I'm not sure if 2 works
  with emacs.

  Comments?

* Currently I use a list of lisp functions for specifying the behavior
  to be executed in a test, for example:

  (org-todo)

  or

  (org-end-of-line)
  (org-cycle)

  This is not very intuitive for users.  I would rather like something
  like a recorded macro to execute.

  For example:

  end, tab

  Does anyone here has a tip how to specify a list of user-input
  actions in a file and play that back?

* For visual comparison I currently simply save the visible part of
  buffers.

  One may get a step further here and also capture properties, faces and
  the cursor position.  I remember vaguely that there is such a
  facility somewhat related to rich text in emacs, but wasn't able to
  find it again.  Do you guys know of such a thing?

 I think it would be great to have a testing framework and a
 lot of tests, but I do not have time to make this happen.
 Maybe you can try to get the people who were active in those
 threads and energize them?

I assumed everyone still interested in contributing to org-mode is
still lurking in this list.  So speak up if you are interested in
contributing to the tests :-).

Cheers,
Martin


___
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] Re: Displaying your Org agenda after idle time

2010-03-21 Thread Ross A. Laird
John Wiegley jwieg...@gmail.com writes:

 I have the following snippet in my .emacs file, which I find very
 useful. Basically what it does is that if I don't touch my Emacs for 5
 minutes, it displays the current agenda. This keeps my tasks always
 in mind whenever I come back to Emacs after doing something else,
 whereas before I had a tendency to forget that it was there.

 John

 (defun jump-to-org-agenda ()
   (interactive)
   (let ((buf (get-buffer *Org Agenda*))
   wind)
 (if buf
   (if (setq wind (get-buffer-window buf))
   (select-window wind)
 (if (called-interactively-p)
 (progn
   (select-window (display-buffer buf t t))
   (org-fit-window-to-buffer)
   ;; (org-agenda-redo)
   )
   (with-selected-window (display-buffer buf)
 (org-fit-window-to-buffer)
 ;; (org-agenda-redo)
 )))
   (call-interactively 'org-agenda-list)))
   ;;(let ((buf (get-buffer *Calendar*)))
   ;;  (unless (get-buffer-window buf)
   ;;(org-agenda-goto-calendar)))
   )

 (run-with-idle-timer 300 t 'jump-to-org-agenda)


This is fantastically useful.
Thanks very much!

Ross

--
Ross A. Laird, PhD
www.rosslaird.com



___
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] Publish atom feeds based on Org files

2010-03-21 Thread Eric S Fraga
On Fri, 19 Mar 2010 23:00:23 +0100, David Maus dm...@ictsoc.de wrote:

 Carving another stone that might fit into the cathedral known as
 Emacs/Orgmode I am glad to present attached file org-atom.el that
 provides an exporting and a publishing function to create atom feeds
 based on Org files.

David,

many thanks for this.  I have been waiting for something like this for
a very long time now (but haven't had the time or knowledge to do it
myself unfortunately)!

I have played around with it and it works very well indeed.  

  - use the w3c feed validator at http://validator.w3.org/feed/

The validation came through with flying colours as well.

The only thing missing in your documentation was how to make your
exported org (i.e. the html) file be recognised as an RSS feed by the
browsers.  I found that adding this to my org setup did the job:

--8---cut here---start-8---
#+STYLE: link rel=alternate type=application/rss+xml title=your page 
title here href=the URL to the atom file here /
--8---cut here---end---8---

I've not played yet with integrating the creation of the atom file
with my normal publishing steps but will try soon.  However, simply
being able to export to atom manually and then publish as normal works
just fine.

I would definitely vote for org-atom.el to be included in the standard
org distribution!

Thanks again,
eric


___
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] suggestion: display of #+TITLE

2010-03-21 Thread Dan Davison
Dan Davison davi...@stats.ox.ac.uk writes:

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

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

 Might it be worth considering a special display for the #+title line
 in
 org buffers?

 Currently it is easy for the title to get buried among more technical
 configuration lines like #+options, #+startup, #+seq_toto etc. One can
 take the approach of leaving #+title at the top of the document, and
 moving the other config lines elesewhere, but even so I am wondering
 whether anyone else is attracted by the idea of providing an org-title
 display property that would hide the #+title: component, and use an
 appropriate face for the title text.

 In some ways, the current state gives the impression that the title is
 something which becomes important during export, but is not really a
 key
 component of document when it is being viewed in emacs. For example, I
 expect others are familiar with the experience of exporting an org
 file
 without a title, finding that the first heading has been used as a
 title, and then going back to add in the title as an
 afterthought. But a
 title is an important part of a document, and I thought perhaps a
 special title display would help to make the title more of a first
 class
 citizen in org buffers?

 Hi Dan,

 I agree.  Maybe he same should be true for DATE and AUTHOR, maybe EMAIL?

 Would you like to make a patch for this, introducing a new face
 and applying it to these constructs?

[I tried sending this with screenshot images and it got rejected. I've
replaced them with URLs]

I've made a proposed patch (below). This involved making a few decisions
about appearance -- it would be great to get other peoples' views and
alternative proposals.

At the risk of stating the obvious, I think we should ask the question
What might attract new users to org-mode most?, rather than query our
personal preferences (because we can all change it ourselves or fire off
an email to this list asking how).

Here's my main proposal (corresponding to the patch below). Note that in
the first 4 lines the #+TITLE: and #+AUTHOR: etc bits are still there,
but invisible.

http://www.princeton.edu/~ddavison/org-faces/Default-MidnightBlue.png

The main issue then is that I'm suggesting making the title face larger
than the other faces. This would be the only large face in org-mode, but
I thought that it was appropriate for the title. Here's a version
without the large title face:

http://www.princeton.edu/~ddavison/org-faces/Default-MidnightBlue-NoBigTitle.png

As for the colours, here's an alternative:

http://www.princeton.edu/~ddavison/org-faces/Default-DarkSlateGrey.png

The important thing is the default emacs colour theme shown above, but I
did pick a colour for dark backgrounds. For what it's worth, here is
what it looks like with (the excellent) color-theme-charcoal-black:

http://www.princeton.edu/~ddavison/org-faces/CharcoalBlack-SteelBlue.png

Here's the patch. If anyone wants to play around, it's pretty obvious in
the patch below where to change the colours (and boldness and
height). Don't forget the functions list-colors-display and
list-faces-display.

There's at least one issue with the patch: if you leave a space between
e.g. '#+TITLE:' and the start of the title text, then that space will
not be made invisible and so will appear at the start of the title. I
couldn't see how to avoid that without altering one of the key font-lock
regexps.

Dan

--8---cut here---start-8---
commit 72aa791ea0bf613d50b9bf88affd6a53e91c1ebe
Author: Dan Davison davi...@stats.ox.ac.uk
Date:   Sun Mar 21 20:26:02 2010 -0400

Alter display of title, author, email and date lines.

For each of #+TITLE:, #+AUTHOR:, #+EMAIL:, #+DATE:, the
initial #+KEYWORD: part is hidden and the following new
faces are applied to the remaining visible part:

org-title-line
org-author-line
org-email-line
org-date-line

diff --git a/lisp/org-faces.el b/lisp/org-faces.el
index e336b3c..ebc9596 100644
--- a/lisp/org-faces.el
+++ b/lisp/org-faces.el
@@ -468,6 +468,25 @@ changes.
   :group 'org-faces
   :version 22.1)
 
+(defface org-title-line
+  'class color) (background light)) (:foreground midnight blue :weight 
bold :height 1.44))
+(((class color) (background dark)) (:foreground steel blue :weight bold 
:height 1.44))
+(t (:weight bold :height 1.44)))
+  Face for #+TITLE: line.
+  :group 'org-faces)
+
+(defface org-author-line
+  'class color) (background light)) (:foreground midnight blue))
+(((class color) (background dark)) (:foreground steel blue)))
+  Face for #+AUTHOR: line.
+  :group 'org-faces)
+
+(org-copy-face 'org-author-line 'org-email-line
+  Face for #+EMAIL: line.)
+
+(org-copy-face 'org-author-line 'org-date-line
+  Face for #+DATE: line.)
+
 (defface org-block
   (org-compatible-face 'shadow
 'class color grayscale) (min-colors 88) (background light))
diff --git 

[Orgmode] Simple tool to do outlining in HTML

2010-03-21 Thread Daniel Clemente

Hi,
  I'd like to present a task list and a visualization tool, esquemadorg.

  The task list is my published todo list, in Spanish, where I track work on 
some programs, topics, bugs and ideas. It's at [1]. There's a section for 
org-mode bugs too, under Emacs, concretely at: [2]

  The tool is the system which I used in that page. It is a JavaScript code 
([3]) which provides outlining in a web browser with a mouse. You just click on 
a header, and it expands or contracts smoothly. A newly expanded section will 
contain closed sections which have to be opened too, and so on. There is no 
cycling; just open/close.
  There's also a link at the top right of first section which disables 
outlining completely.
  The code used ideas from Sebastian Rose's org-info-jq but was newly written 
using jQuery. You may use it in your pages. Try these two designs: simple [4], 
nice [5]

  I also wrote a page explaining what is org-mode, what does it look like for 
me, how do I export to HTML and why you should prefer org over HTML: [6].

  I hope you find it useful.

Daniel

[1]:  http://www.danielclemente.com/hacer/ 
[2]:  http://www.danielclemente.com/hacer/emacs.html#sec-3
[3]:  http://www.danielclemente.com/pagina/esquemadorg.js
[4]:  http://www.danielclemente.com/pagina/esquemadorg.css
[5]:  http://www.danielclemente.com/hacer/basic.css
[6]:  http://www.danielclemente.com/hacer/org.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


[Orgmode] using orgmode to send html mail?

2010-03-21 Thread Matt Price
Hi,

I just wondered whether anyone composes mail in orgmode  then
generates html from the source code.  I'd like to be able to do that
sometimes in wanderlust, e.g. when I'm responding to html mail with
links in it.

like I say, just wondering -- glad for any help anyone can offe.r  thanks,
matt


___
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] ordered list items start with letters?

2010-03-21 Thread Xiao-Yong Jin
Hi, is it possible to use a single letter to start an
ordered list item?  Such as

  a) first
  b) second?

Thanks
-- 
Jc/*__o/*
X\ * (__
Y*/\  


___
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-21 Thread Matthew Phillips
On 18/03/2010, at 4:29 PM, Carsten Dominik wrote:

 On Mar 17, 2010, at 1:53 AM, Matthew Phillips wrote:
 
 On 16/03/2010, at 6:21 PM, Carsten Dominik wrote:
 
 On Mar 16, 2010, at 1:36 AM, Matthew Phillips wrote:
 
 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.
 
 My mistake:
 
 +BLOCKEDt/+TODO
 
 This means that the BLOCKED property should not be equal to “t”.
 
 Hmm, the following query still does not work (still shows greyed blocked 
 tasks)
 
 (tags +BLOCKED\t\/+TODO)
 
 And using +BLOCKED=\t\/TODO selects nothing.
 
 I just tested it, and this is working properly for me.  Are you
 running a recent version of Org-mode?  The BLOCKED property was
 only added in 6.34.

Ah, I was running “6.33x” that came bundled with Emacs 23.1.94.1. Upgrading to 
a local install of 6.34c fixed it — sorry not to have tried that earlier.

Thanks again for your assistance, much appreciated.

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