Re: [O] [babel, R] Commands are not copied in the iESS buffer upon evaluation

2014-08-30 Thread Andreas Kiermeier
Hi Seb,
I'm not quite sure why the commands are not echoed and someone else
can probably explain this.
But for what it's worth, using a header argument :results output
shows the command plus their output in the *R* buffer.
Cheers,
Andreas



[O] bug 17524 in emacs 24.550.1

2014-08-30 Thread Jude DaShiell
I'm using archlinux which is a rolling distribution so have this version 
of emacs on my machine.  I did not experience this bug with org-mode until 
after installing eww which was not part of emacs 24.550.1 installed on 
archlinux.  I ran into it opening an org-mode table, but if I open a bash 
shell script the bug does not appear.  I did have some warnings when 
installing eww using bzr earlier.  I did not save these warnings then.  
If anyone would be interested, I could repeat that install process using 
script as a wrapper and grep all warnings and errors from the typescript 
file and post those here.

jude jdash...@shellworld.net




[O] bug16524 complication

2014-08-30 Thread Jude DaShiell
The eww branch put no code on my machine the second time I ran it.  I made 
the mistake of not configuring bzr oritinally and bzr put everything into 
a ~/trunk subdirectory.  After configuring bzr by making a repository for 
it according to the article on archwiki for bzr, the bzr command appeared 
to run normally but both the bzr.repo directory and trunk directory were 
empty upon completion.  Also, I found my .emacs had been modified by the 
original bzr process with much code I don't yet understand.  After having 
checked out th branch originally I had to run autogen.sh and then 
configure and then make and finally make install.

I had to use the --create-prefix on the init line of bzr doing 
configuration from archwiki article in otder to clear the error that came 
up (undocumented) and used $HOME as my prefix value.



jude jdash...@shellworld.net




Re: [O] Debug (ox-odt): No OpenDocument schema files installed

2014-08-30 Thread Christian Moe

Do org-odt-styles-dir and org-odt-schema-dir now point to the correct
directory?

If not, did you try putting

  (setq org-odt-data-dir /usr/share/emacs/24.3/etc/org)

in your .emacs and restarting?

Those variables are set on startup based on the contents of
org-odt-data-dir, and not immediately updated by changing the latter.

Yours,
Christian

Melleus writes:

 I'm trying to set up the odt exporter which is disabled by default.
 After loading the exporter with:
   (require 'ox-odt)
 I got the message about missing files.
 I inspected the org-odt-data-dir and found that it points to
 non-existant directory. So I did:
   (setq org-odt-data-dir /usr/share/emacs/24.3/etc/org)
 (the directory with the proper xml files) before loading the ox-odt
 library. The result did not changed. I still got the message about
 missing files.

 I use emacs-24.3.1 and org-mode-8.2.7b from Debian repositories.

 What am I doing wrong? (Or is it disabled by default because it's broken?)

 Thanks ahead.
  




Re: [O] Bug: Feature request: make length of history in org-clock-select-task customizable [8.2.7c (8.2.7c-51-g896fa6-elpaplus @ c:/Users/clange/.emacs.d/elpa/org-plus-contrib-20140825/)]

2014-08-30 Thread Christoph LANGE

On 2014-08-28 18:03, Subhan Michael Tindall wrote:
 Try
 (setq org-clock-history-length n)
 In your .emacs

Thank you very much, that's great!  I had no idea, because …

* the documentation of org-clock-goto and org-clock-in (which display 
the history given universal-argument) didn't refer to this,


* org-clock-select-task does not obviously refer to 
org-clock-history-length,


* I was misled by the hard-coded 10 in org-clock-select-task, which, as 
I now understand, defines the boundary between digits and letters to 
number tasks.


 I believe the max on the list length is 35, but I could be wrong.

I think you are right about this, given the initial code in 
org-clock-history-push, and the limit to 9 digits (why actually not use 
0 for the most recent one?) and 26 alphabetic letters.


Cheers,

Christoph

--
Christoph Lange, Enterprise Information Systems Department
Applied Computer Science @ University of Bonn; Fraunhofer IAIS
http://langec.wordpress.com/about, Skype duke4701

→ SEMANTiCS conference: Transfer–Engineering–Community.
  Leipzig, Germany, 4–5 September (workshops 1–3 September).
  Including Vocabulary Carnival, LOD for SMEs, Linked Data Quality.



Re: [O] org-ref no key found

2014-08-30 Thread John Kitchin
that is odd. this means org-ref is not finding the key you clicked
on. could you send me a small example that reproduces your problem (an
org-file and the bib file)?

Julian M. Burgos jul...@hafro.is writes:

 Hi John, 

 No, they still do not work even after I click on the bibliography link
 and get my .bib file opened.

 Julian

 John Kitchin writes:

 Julian M. Burgos jul...@hafro.is writes:

 If you click on the bibliography link to open the file, and then go back
 to your org-file, do the cite links work?

 I suspect the notes problem is related to the no key found problem.

 Hello everyone,

 I am playing around with Joh Kitchin's excellent org-ref, and I am
 having a few issues.  In my .emacs file I have set up the values for the
 org-ref-bibliography-notes, org-ref-default-bibliography, and
 org-ref-pdf-directory.

 With this I can access my .bib database and use org-ref-insert-cite link
 to add a citation link with no problems.  But when I press enter on the
 cite link, I get the following message:

 no key found
  (No key found) (p)df (u)rl (n)otes (q) quit

 If I press p I get the pdf file, but if I press n I get the
 following message: 

 Wrong type argument: stringp, nil.

 Any ideas how to solve this?

 Many thanks,

 Julian

-- 
---
John Kitchin
Professor
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
http://kitchingroup.cheme.cmu.edu



[O] progress indicator for code blocks?

2014-08-30 Thread John Kitchin
Hi all,
I am using org-mode in a class, and some students wondered if it was
possible for there to be a progress bar of some kind while a code block
is running. Right now Emacs just appears to lock up and there is no
indication anything is happening, especially the first time we run a
python block.

I found make-progress-reporter and tried something like this::
#+BEGIN_SRC emacs-lisp
(defadvice org-babel-execute-src-block (around progress nil activate)
  (let ((pr (make-progress-reporter Running)))
ad-do-it
(progress-reporter-done pr)))
#+END_SRC

but there is no way to update it, so it doesn't quite do anything
useful.

What I would really like is an hourglass or some spinning thing. Does
anyone know how to get that (in a cross-platform way)?

-- 
---
John Kitchin
http://kitchingroup.cheme.cmu.edu




[O] Latest clocktable mis-formats headings

2014-08-30 Thread Tory S. Anderson
My latest clocktables have started to stumble on the formatting of subheadings; 
some of the leading * of the items seem to be making it into the table as 
\emsp. What's the problem? 

Example:

#+BEGIN: clocktable :maxlevel 4 :scope subtree
#+CAPTION: Clock summary at [2014-08-30 Sat 10:58]
| Headline  | Time|   |   |  |
|---+-+---+---+--|
| *Total time*  | *24:45* |   |   |  |
|---+-+---+---+--|
| \emsp\emsp 
[[file:/home/torys/emacs/Notes/Work.org::Work%20Week%204%202014-08-25%20Mon--2014-08-30%20Sat][Work
 Week 4 2014-08-25...]] | |   | 24:45 |  |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::NRL][NRL]]   
| |   |   | 2:55 |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::GRA%20w/Murray][GRA 
w/Murray]]  | |   |   | 7:34 |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::8803%20Work][8803 
Work]] | |   |   | 3:50 |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::8801%20Work][8801 
Work]] | |   |   | 1:00 |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::CS%207637%20Work][CS 
7637 Work]]  | |   |   | 8:41 |
| \emsp\emsp\emsp 
[[file:/home/torys/emacs/Notes/Work.org::Personal%20Writing][Personal Writing]] 
 | |   |   | 0:45 |
#+END:



[O] Help with column formula in radiotable

2014-08-30 Thread Thorsten Grothe

Hello,

I would like to assign a relative column formular for the 6 column (name 
= BIPr).


The formular should start in the *second field* of column 3 (value = 12) 
and multiply it with *first value of column* 4 (value = 2.8) etc. like this:


12 * 2.8
4 * 0.7
...

|---+--+---+---+---+---+---|
| ! | Jahr | Menge | Preis |  BIPn |  BIPr | W |
|---+--+---+---+---+---+---|
| # |1 |10 |   2.8 | 28.00 | 0 |   |
| # |2 |12 |   0.7 |  8.40 |   |   |
| # |3 | 4 |  4.00 | 16.00 |   |   |
|---+--+---+---+---+---+---|
| _ |  |   |   |  suma |  sumb |   |
|   |  |   |   | 52.40 | 16.00 |   |

How can I do this?

Thanks in advance for your help!!

Regards
Thorsten Grothe





Re: [O] Latest clocktable mis-formats headings

2014-08-30 Thread Dieter Schön
Hi,
I had the same problem, and I could solve it by removing an org installation in 
.emacs.d/elpa.
(My regular org installation is a git sandbox).

Regards,
Dieter

On 30. August 2014 17:00:39 MESZ, torys.ander...@gmail.com wrote:
My latest clocktables have started to stumble on the formatting of
subheadings; some of the leading * of the items seem to be making it
into the table as \emsp. What's the problem? 

Example:

#+BEGIN: clocktable :maxlevel 4 :scope subtree
#+CAPTION: Clock summary at [2014-08-30 Sat 10:58]
| Headline  | Time|   |   |  |
|---+-+---+---+--|
| *Total time*  | *24:45* |   |   |  |
|---+-+---+---+--|
| \emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Work%20Week%204%202014-08-25%20Mon--2014-08-30%20Sat][Work
Week 4 2014-08-25...]] | |   | 24:45 |  |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::NRL][NRL]]  
| |   |   | 2:55 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::GRA%20w/Murray][GRA w/Murray]]
 | |   |   | 7:34 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8803%20Work][8803 Work]]  
  | |   |   | 3:50 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8801%20Work][8801 Work]]  
  | |   |   | 1:00 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::CS%207637%20Work][CS 7637
Work]]  | |   |   | 8:41 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Personal%20Writing][Personal
Writing]]  | |   |   | 0:45 |
#+END:

-- 
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.

[O] A Babel block to #+INCLUDE all .org files of a directory

2014-08-30 Thread Andrea Rossetti
Hi Org users,

  I wrote a Babel block to generate the #+INCLUDE statements
for all Org files of a directory.

  Nothing spectacular: not recursive through directories,
only .org files ... but I wanted to share it, just in case
someone finds it helpful. Source code and usage example
are available here:

https://github.com/thesoftwarebin/the-emacs-software-bin/tree/master/include-all-org-files

(GitHub renders Org files as html, so be sure to click the Raw button
in order to see #+BEGIN_SRC, #+END_SRC and #+COMMENTS)

  Opinions, corrections and enhancements are of course
more than welcome. Kindest regards,

  Andrea




Re: [O] A Babel block to #+INCLUDE all .org files of a directory

2014-08-30 Thread Grant Rettke
May you please discuss your use case that motivated this code?
Grant Rettke | ACM, ASA, FSF
g...@wisdomandwonder.com | http://www.wisdomandwonder.com/
“Wisdom begins in wonder.” --Socrates
((λ (x) (x x)) (λ (x) (x x)))
“Life has become immeasurably better since I have been forced to stop
taking it seriously.” --Thompson


On Sat, Aug 30, 2014 at 10:50 AM, Andrea Rossetti
andrea.rosse...@gmail.com wrote:
 Hi Org users,

   I wrote a Babel block to generate the #+INCLUDE statements
 for all Org files of a directory.

   Nothing spectacular: not recursive through directories,
 only .org files ... but I wanted to share it, just in case
 someone finds it helpful. Source code and usage example
 are available here:

 https://github.com/thesoftwarebin/the-emacs-software-bin/tree/master/include-all-org-files

 (GitHub renders Org files as html, so be sure to click the Raw button
 in order to see #+BEGIN_SRC, #+END_SRC and #+COMMENTS)

   Opinions, corrections and enhancements are of course
 more than welcome. Kindest regards,

   Andrea





Re: [O] Emacs-orgmode Digest, Vol 102, Issue 32

2014-08-30 Thread Tory S. Anderson
Hmm... I use the elpa as my main install, and maintain orgmode through those 
updates. Any other solutions, or idea why that fixed it? 
- Tory


Date: Sat, 30 Aug 2014 17:36:24 +0200
From: Dieter Sch?n die...@schoen.or.at
To: orgmode list emacs-orgmode@gnu.org
Subject: Re: [O] Latest clocktable mis-formats headings
Message-ID: c4c0b4f1-62c9-4d88-b985-ee4a7829b...@email.android.com
Content-Type: text/plain; charset=utf-8

Hi,
I had the same problem, and I could solve it by removing an org installation in 
.emacs.d/elpa.
(My regular org installation is a git sandbox).

Regards,
Dieter

On 30. August 2014 17:00:39 MESZ, torys.ander...@gmail.com wrote:
My latest clocktables have started to stumble on the formatting of
subheadings; some of the leading * of the items seem to be making it
into the table as \emsp. What's the problem? 

Example:

#+BEGIN: clocktable :maxlevel 4 :scope subtree
#+CAPTION: Clock summary at [2014-08-30 Sat 10:58]
| Headline  | Time|   |   |  |
|---+-+---+---+--|
| *Total time*  | *24:45* |   |   |  |
|---+-+---+---+--|
| \emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Work%20Week%204%202014-08-25%20Mon--2014-08-30%20Sat][Work
Week 4 2014-08-25...]] | |   | 24:45 |  |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::NRL][NRL]]  
| |   |   | 2:55 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::GRA%20w/Murray][GRA w/Murray]]
 | |   |   | 7:34 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8803%20Work][8803 Work]]  
  | |   |   | 3:50 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8801%20Work][8801 Work]]  
  | |   |   | 1:00 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::CS%207637%20Work][CS 7637
Work]]  | |   |   | 8:41 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Personal%20Writing][Personal
Writing]]  | |   |   | 0:45 |
#+END:

-- 
Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail gesendet.



Re: [O] Latest clocktable mis-formats headings

2014-08-30 Thread Tory S. Anderson
My elpa orgmode is running Org-mode version 8.2.7c, btw. Do others have this 
(possibly elpa-specific) problem? 

 Date: Sat, 30 Aug 2014 17:36:24 +0200
 From: Dieter Sch?n die...@schoen.or.at
 To: orgmode list emacs-orgmode@gnu.org
 Subject: Re: [O] Latest clocktable mis-formats headings
 Message-ID: c4c0b4f1-62c9-4d88-b985-ee4a7829b...@email.android.com
 Content-Type: text/plain; charset=utf-8

 Hi,
 I had the same problem, and I could solve it by removing an org installation 
 in .emacs.d/elpa.
 (My regular org installation is a git sandbox).

 Regards,
 Dieter

 On 30. August 2014 17:00:39 MESZ, torys.ander...@gmail.com wrote:
My latest clocktables have started to stumble on the formatting of
subheadings; some of the leading * of the items seem to be making it
into the table as \emsp. What's the problem? 

Example:

#+BEGIN: clocktable :maxlevel 4 :scope subtree
#+CAPTION: Clock summary at [2014-08-30 Sat 10:58]
| Headline  | Time|   |   |  |
|---+-+---+---+--|
| *Total time*  | *24:45* |   |   |  |
|---+-+---+---+--|
| \emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Work%20Week%204%202014-08-25%20Mon--2014-08-30%20Sat][Work
Week 4 2014-08-25...]] | |   | 24:45 |  |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::NRL][NRL]]  
| |   |   | 2:55 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::GRA%20w/Murray][GRA w/Murray]]
 | |   |   | 7:34 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8803%20Work][8803 Work]]  
  | |   |   | 3:50 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8801%20Work][8801 Work]]  
  | |   |   | 1:00 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::CS%207637%20Work][CS 7637
Work]]  | |   |   | 8:41 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Personal%20Writing][Personal
Writing]]  | |   |   | 0:45 |
#+END:



[O] accessing properties in org-element-parse-buffer tree

2014-08-30 Thread Eike

Hello list,

I want to ask for help regarding elisp and org-elements. I like to
access the properties of all my headlines and I created the following
function (tree is the parsed tree) that collects them into an a-list:

#+begin_src emacs-lisp
  (defun collect-props (tree)
(car (org-element-map tree 'headline
   (lambda (hl)
 (when (eq 2 (org-element-property :level hl)) ; want only level-2 
properties
   (org-element-map hl 'node-property
 (lambda (np)
   (cons (org-element-property :key np)
 (org-element-property :value np)
#+end_src

I'm not very confident about this, is this ok? Is there a better way?
For example, the first car looks strange, and I don't know how to get
rid of it.

Thanks you very much in advance!!!
Kind regards
Eike

--
gpg: AD7AC35E
finger print: 137F BB0B 1639 D25F DC5D  E59C B412 C5F5 AD7A C35E



[O] org-elements-parse-buffer and weird property drawers

2014-08-30 Thread Eike

Hello all,

I'm playing with the functions in org-elements.el and the following
effect seems strange to me:

I have a few propery drawers with empty propertys, like

#+BEGIN_EXAMPLE
:PROPERTIES:
:date: [2014-08-29 Fr]
:chf:  21.76
:eur:
:END:
#+END_EXAMPLE

If I do org-elements-parse-buffer, the empty one is not there, but the
first one is duplicated. At least, there are two node-property
elements in the tree like that:

#+BEGIN_EXAMPLE
(node-property (:key chf :value 21.76 :begin 38 :end 58 :post-blank 0 
:post-affiliated 38 :parent #4))
(node-property (:key chf :value 21.76 :begin 58 :end 67 :post-blank 0 
:post-affiliated 58 :parent #4))
#+END_EXAMPLE

The function call was this:

#+begin_src emacs-lisp
(with-current-buffer test-exp.org
  (org-element-parse-buffer))
#+end_src

And here is the test-exp.org org file:

#+BEGIN_EXAMPLE
* Sonstiges
** Pizza
   :PROPERTIES:
   :chf:  21.76
   :eur:
   :END:
#+END_EXAMPLE

Am I missing something, or are empty properties not supported?

Kind regards,
Eike



Re: [O] [babel, R] Commands are not copied in the iESS buffer upon evaluation

2014-08-30 Thread Aaron Ecay
Hi Seb,

2014ko abuztuak 29an, Sebastien Vauban-ek idatzi zuen:

[...]

 Does it have something to do with `ess-eval-visibly' not being respected
 (whose default is `t')?

Indeed, babel’s R support let-binds this variable to nil when evaluating
value-type results in a session.

-- 
Aaron Ecay



Re: [O] [RFC] [PATCH] org.el: fix ‘org-buffer-property-keys’

2014-08-30 Thread Aaron Ecay
Hi Nicolas,

2014ko abuztuak 28an, Nicolas Goaziou-ek idatzi zuen:

[...]

 
 Nevertheless, I think we should take a radical different approach, as
 discussed recently with Bastien, which is to enforce property drawers to
 start on the line right after the headline and maybe the planning info,
 if any. As a consequence, the code for this function will be different
 anyway. IOW, I wouldn't bother too much.

I see.  Thanks for the explanation.

-- 
Aaron Ecay



Re: [O] [bug?] org-copy-face doesn’t add faces to org-faces customize group

2014-08-30 Thread Aaron Ecay
Hi Seb,

2014ko abuztuak 29an, Sebastien Vauban-ek idatzi zuen:
 I think it's related to an Emacs bug (#16440) which I reported on the
 Org mailing list in February.

I don’t completely understand what is going on in that bug report.  My
proposal is to convert org-copy-face to defface.  I can’t tell if this
would fix your problem or not, but if it’s exclusive to the faces I
listed in my previous email the answer is probably “yes.”

-- 
Aaron Ecay



Re: [O] org-elements-parse-buffer and weird property drawers

2014-08-30 Thread Eike

forgot to mention org version:
Org-mode version 8.3beta (release_8.3beta-296-g851b77 @
/home/eike/.emacs.d/src/org-mode/lisp/)

Kind regards,
Eike

Eike writes:

 Hello all,

 I'm playing with the functions in org-elements.el and the following
 effect seems strange to me:

 I have a few propery drawers with empty propertys, like

 #+BEGIN_EXAMPLE
 :PROPERTIES:
 :date: [2014-08-29 Fr]
 :chf:  21.76
 :eur:
 :END:
 #+END_EXAMPLE

 If I do org-elements-parse-buffer, the empty one is not there, but the
 first one is duplicated. At least, there are two node-property
 elements in the tree like that:

 #+BEGIN_EXAMPLE
 (node-property (:key chf :value 21.76 :begin 38 :end 58 :post-blank 0 
 :post-affiliated 38 :parent #4))
 (node-property (:key chf :value 21.76 :begin 58 :end 67 :post-blank 0 
 :post-affiliated 58 :parent #4))
 #+END_EXAMPLE

 The function call was this:

 #+begin_src emacs-lisp
 (with-current-buffer test-exp.org
   (org-element-parse-buffer))
 #+end_src

 And here is the test-exp.org org file:

 #+BEGIN_EXAMPLE
 * Sonstiges
 ** Pizza
:PROPERTIES:
:chf:  21.76
:eur:
:END:
 #+END_EXAMPLE

 Am I missing something, or are empty properties not supported?

 Kind regards,
 Eike

--
gpg: AD7AC35E
finger print: 137F BB0B 1639 D25F DC5D  E59C B412 C5F5 AD7A C35E



Re: [O] accessing properties in org-element-parse-buffer tree

2014-08-30 Thread Eike

Hello again

it seems that I messed up my testing variables… I always had just one
headline and thus the list of lists had always one element that I then
extracted with `car'. So `car' must be removed:

#+begin_src emacs-lisp
  (defun collect-props (tree)
(org-element-map tree 'headline
  (lambda (hl)
(when (eq 2 (org-element-property :level hl)) ; want only level-2 
properties
  (org-element-map hl 'node-property
(lambda (np)
  (cons (org-element-property :key np)
(org-element-property :value np
#+end_src

I'd still be curious if there are other/better ways to do that; or is
this idiomatic usage of provided org functions?

Thanks again and kind regards
Eike

Eike writes:

 Hello list,

 I want to ask for help regarding elisp and org-elements. I like to
 access the properties of all my headlines and I created the following
 function (tree is the parsed tree) that collects them into an a-list:

 #+begin_src emacs-lisp
   (defun collect-props (tree)
 (car (org-element-map tree 'headline
(lambda (hl)
  (when (eq 2 (org-element-property :level hl)) ; want only 
 level-2 properties
(org-element-map hl 'node-property
  (lambda (np)
(cons (org-element-property :key np)
  (org-element-property :value np)
 #+end_src

 I'm not very confident about this, is this ok? Is there a better way?
 For example, the first car looks strange, and I don't know how to get
 rid of it.

 Thanks you very much in advance!!!
 Kind regards
 Eike

--
gpg: AD7AC35E
finger print: 137F BB0B 1639 D25F DC5D  E59C B412 C5F5 AD7A C35E



Re: [O] Debug (ox-odt): No OpenDocument schema files installed

2014-08-30 Thread Melleus

I did that. But got the same message.
Should I have anything except:

 ls
OrgOdtContentTemplate.xml  OrgOdtStyles.xml  README

in that directory?

Thank you.




Re: [O] accessing properties in org-element-parse-buffer tree

2014-08-30 Thread Thorsten Jolitz
Eike e...@eknet.org writes:

Hello,

 I want to ask for help regarding elisp and org-elements. I like to
 access the properties of all my headlines and I created the following
 function (tree is the parsed tree) that collects them into an a-list:

 #+begin_src emacs-lisp
   (defun collect-props (tree)
 (car (org-element-map tree 'headline
(lambda (hl)
  (when (eq 2 (org-element-property :level hl)) ; want only 
 level-2 properties
(org-element-map hl 'node-property
  (lambda (np)
(cons (org-element-property :key np)
  (org-element-property :value np)
 #+end_src

 I'm not very confident about this, is this ok? Is there a better way?
 For example, the first car looks strange, and I don't know how to get
 rid of it.

* Answer
  :PROPERTIES:
  :CUSTOM_ID: abc123
  :foo:  bar
  :END:

There are several options, here a few examples, some using my new
function 'org-dp-filter-node-props' from org-dp-lib.el which is very
good at filtering out only those node-properties you are really
interested in. 'org-entry-properties' does some filtering too, but its
less generic.

#+NAME: ex1
#+BEGIN_SRC emacs-lisp :results raw
(org-map-entries
(lambda () (org-entry-properties nil nil foo)))
#+END_SRC

#+results:
(((CATEGORY . 989)) ((CUSTOM_ID . abc123) (foo . bar) (CATEGORY . 989)))

#+NAME: ex2
#+BEGIN_SRC emacs-lisp :results raw
(require 'org-dp-lib)
(org-map-entries
  (lambda () (org-dp-filter-node-props 'org t t)))
#+END_SRC

#+results:
(nil ((foo . bar)))

#+NAME: ex3
#+BEGIN_SRC emacs-lisp :results raw
  (org-element-map (org-element-parse-buffer 'headline) 'headline
(lambda (hl)
  (when (eq 1 (org-element-property :level hl)) ; want only level-2 
properties
  (org-element-property :FOO hl
#+END_SRC

#+results: ex3
(bar)

#+NAME: ex4
#+BEGIN_SRC emacs-lisp :results raw
  (let (props)
(save-excursion
  (goto-char (point-min))
  (while (re-search-forward ^\\*+  nil t)
(save-excursion
  (beginning-of-line)
  (setq props
(cons
 (org-dp-filter-node-props
  '(FOO CUSTOM_ID) nil t)
 props
  (delq nil props)))
#+END_SRC

#+results: ex4
(((foo . bar) (CUSTOM_ID . abc123)))


PS 1

Strange behaviour in src-block ex1. 

Neither the example given nor

(org-entry-properties nil foo)
(org-entry-properties nil foo foo)

return what I would expect. 

PS 2

Without the :results header-arg I get the following error when running
src-block ex2:

Debugger entered--Lisp error: (args-out-of-range 0 1)
  orgtbl-to-orgtbl((nil ((foo . bar))) (:fmt (lambda (cell) (format %s 
cell
  org-babel-insert-result((nil ((foo . bar))) (replace) (emacs-lisp 
(require 'org-dp-lib)\n(org-map-entries (lambda () (org-dp-filter-node-props 
'org t t))) ((:comments . ) (:shebang . ) (:cache . no) (:padline . ) 
(:noweb . no) (:tangle . no) (:exports . code) (:results . replace) 
(:session . none) (:hlines . no) (:result-type . value) (:result-params 
replace) (:rowname-names) (:colname-names))  nil 0 #marker at 1263 in 
*outorg-edit-buffer*) nil 0 emacs-lisp)
  org-babel-execute-src-block(nil)
  org-babel-execute-src-block-maybe()
  org-babel-execute-maybe()
  org-babel-execute-safely-maybe()
  run-hook-with-args-until-success(org-babel-execute-safely-maybe)
  org-ctrl-c-ctrl-c(nil)
  call-interactively(org-ctrl-c-ctrl-c nil nil)


-- 
cheers,
Thorsten




Re: [O] org-elements-parse-buffer and weird property drawers

2014-08-30 Thread Thorsten Jolitz
Eike n...@eknet.org writes:

 Hello all,

 I'm playing with the functions in org-elements.el and the following
 effect seems strange to me:

 I have a few propery drawers with empty propertys, like

 #+BEGIN_EXAMPLE
 :PROPERTIES:
 :date: [2014-08-29 Fr]
 :chf:  21.76
 :eur:
 :END:
 #+END_EXAMPLE

 If I do org-elements-parse-buffer, the empty one is not there, but the
 first one is duplicated. At least, there are two node-property
 elements in the tree like that:

 #+BEGIN_EXAMPLE
 (node-property (:key chf :value 21.76 :begin 38 :end 58 :post-blank 0 
 :post-affiliated 38 :parent #4))
 (node-property (:key chf :value 21.76 :begin 58 :end 67 :post-blank 0 
 :post-affiliated 58 :parent #4))
 #+END_EXAMPLE


Indeed, I get

,
| (property-drawer (:begin 24 :end 78 :contents-begin 40 :contents-end 69
| :post-blank 0 :post-affiliated 24 :parent #3) (node-property (:key chf
| :value 21.76 :begin 40 :end 60 :post-blank 0 :parent #4))
| (node-property (:key chf :value 21.76 :begin 60 :end 69 :post-blank
| 0 :parent #4)))
`

too when parsing this 

,
| * ORG SCRATCH
| ** Pizza
|:PROPERTIES:
|:chf:  21.76
|:eur:
|:END:
`

looks like a bug to me.

-- 
cheers,
Thorsten




Re: [O] Latest clocktable mis-formats headings

2014-08-30 Thread Tory S. Anderson
I found the problem and have changed it as per below. The \emsp is being 
interpreted literally. I just changed mine back to underscores. 

From org-clock.el:

(defun org-clocktable-indent-string (level)
  (if (= level 1) 
(let ((str  ))
  (dotimes (k (1- level) str)
;;  (setq str (concat \\emsp str))
(setq str (concat __ str))


torys.ander...@gmail.com (Tory S. Anderson) writes:

 My elpa orgmode is running Org-mode version 8.2.7c, btw. Do others have this 
 (possibly elpa-specific) problem? 

 Date: Sat, 30 Aug 2014 17:36:24 +0200
 From: Dieter Sch?n die...@schoen.or.at
 To: orgmode list emacs-orgmode@gnu.org
 Subject: Re: [O] Latest clocktable mis-formats headings
 Message-ID: c4c0b4f1-62c9-4d88-b985-ee4a7829b...@email.android.com
 Content-Type: text/plain; charset=utf-8

 Hi,
 I had the same problem, and I could solve it by removing an org installation 
 in .emacs.d/elpa.
 (My regular org installation is a git sandbox).

 Regards,
 Dieter

 On 30. August 2014 17:00:39 MESZ, torys.ander...@gmail.com wrote:
My latest clocktables have started to stumble on the formatting of
subheadings; some of the leading * of the items seem to be making it
into the table as \emsp. What's the problem? 

Example:

#+BEGIN: clocktable :maxlevel 4 :scope subtree
#+CAPTION: Clock summary at [2014-08-30 Sat 10:58]
| Headline  | Time|   |   |  |
|---+-+---+---+--|
| *Total time*  | *24:45* |   |   |  |
|---+-+---+---+--|
| \emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Work%20Week%204%202014-08-25%20Mon--2014-08-30%20Sat][Work
Week 4 2014-08-25...]] | |   | 24:45 |  |
| \emsp\emsp\emsp [[file:/home/torys/emacs/Notes/Work.org::NRL][NRL]]  
| |   |   | 2:55 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::GRA%20w/Murray][GRA w/Murray]]
 | |   |   | 7:34 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8803%20Work][8803 Work]]  
  | |   |   | 3:50 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::8801%20Work][8801 Work]]  
  | |   |   | 1:00 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::CS%207637%20Work][CS 7637
Work]]  | |   |   | 8:41 |
| \emsp\emsp\emsp
[[file:/home/torys/emacs/Notes/Work.org::Personal%20Writing][Personal
Writing]]  | |   |   | 0:45 |
#+END:



Re: [O] A Babel block to #+INCLUDE all .org files of a directory

2014-08-30 Thread Andrea Rossetti
Hello,

Grant Rettke g...@wisdomandwonder.com writes:
 May you please discuss your use case that motivated this code?

  typical usage scenarios could be:

  1) write a book of many chapters, one main.org file
 and many second-level .org files, one file per chapter,
 and you don't want to manually write all the #INCLUDEs:

  main.org
chapter01-the-intro.org
chapter02-another-day-another-story.org
chapter03-bad-day-emacs-froze-again.org
...
chapter47-end.org

  2) write some reference manual (example: my_c_manual.org)
 that includes many .org files, every one of them shows usage
 and examples of a language keyword or library function:

  my_reference_manual.org
abs.org
...
printf.org
strcpy.org

  Thanks to everyone for whatever feedback, kindest regards.

  Andrea



Re: [O] accessing properties in org-element-parse-buffer tree

2014-08-30 Thread Eike

Thanks a lot for the examples, they are very helpful! I first thought to
parse the org buffer and then work with the resulting tree. But your
examples now makes me think to work directly on the buffer. Well, I will
play with a few different ways now…

Regards
Eike


Thorsten Jolitz writes:

 Eike e...@eknet.org writes:

 Hello,

 I want to ask for help regarding elisp and org-elements. I like to
 access the properties of all my headlines and I created the following
 function (tree is the parsed tree) that collects them into an a-list:

 #+begin_src emacs-lisp
   (defun collect-props (tree)
 (car (org-element-map tree 'headline
(lambda (hl)
  (when (eq 2 (org-element-property :level hl)) ; want only 
 level-2 properties
(org-element-map hl 'node-property
  (lambda (np)
(cons (org-element-property :key np)
  (org-element-property :value np)
 #+end_src

 I'm not very confident about this, is this ok? Is there a better way?
 For example, the first car looks strange, and I don't know how to get
 rid of it.

 * Answer
   :PROPERTIES:
   :CUSTOM_ID: abc123
   :foo:  bar
   :END:

 There are several options, here a few examples, some using my new
 function 'org-dp-filter-node-props' from org-dp-lib.el which is very
 good at filtering out only those node-properties you are really
 interested in. 'org-entry-properties' does some filtering too, but its
 less generic.

 #+NAME: ex1
 #+BEGIN_SRC emacs-lisp :results raw
 (org-map-entries
 (lambda () (org-entry-properties nil nil foo)))
 #+END_SRC

 #+results:
 (((CATEGORY . 989)) ((CUSTOM_ID . abc123) (foo . bar) (CATEGORY . 989)))

 #+NAME: ex2
 #+BEGIN_SRC emacs-lisp :results raw
 (require 'org-dp-lib)
 (org-map-entries
   (lambda () (org-dp-filter-node-props 'org t t)))
 #+END_SRC

 #+results:
 (nil ((foo . bar)))

 #+NAME: ex3
 #+BEGIN_SRC emacs-lisp :results raw
   (org-element-map (org-element-parse-buffer 'headline) 'headline
 (lambda (hl)
   (when (eq 1 (org-element-property :level hl)) ; want only level-2 
 properties
   (org-element-property :FOO hl
 #+END_SRC

 #+results: ex3
 (bar)

 #+NAME: ex4
 #+BEGIN_SRC emacs-lisp :results raw
   (let (props)
 (save-excursion
   (goto-char (point-min))
   (while (re-search-forward ^\\*+  nil t)
 (save-excursion
   (beginning-of-line)
   (setq props
 (cons
  (org-dp-filter-node-props
   '(FOO CUSTOM_ID) nil t)
  props
   (delq nil props)))
 #+END_SRC

 #+results: ex4
 (((foo . bar) (CUSTOM_ID . abc123)))


 PS 1

 Strange behaviour in src-block ex1.

 Neither the example given nor

 (org-entry-properties nil foo)
 (org-entry-properties nil foo foo)

 return what I would expect.

 PS 2

 Without the :results header-arg I get the following error when running
 src-block ex2:

 Debugger entered--Lisp error: (args-out-of-range 0 1)
   orgtbl-to-orgtbl((nil ((foo . bar))) (:fmt (lambda (cell) (format %s 
 cell
   org-babel-insert-result((nil ((foo . bar))) (replace) (emacs-lisp 
 (require 'org-dp-lib)\n(org-map-entries (lambda () (org-dp-filter-node-props 
 'org t t))) ((:comments . ) (:shebang . ) (:cache . no) (:padline . 
 ) (:noweb . no) (:tangle . no) (:exports . code) (:results . 
 replace) (:session . none) (:hlines . no) (:result-type . value) 
 (:result-params replace) (:rowname-names) (:colname-names))  nil 0 
 #marker at 1263 in *outorg-edit-buffer*) nil 0 emacs-lisp)
   org-babel-execute-src-block(nil)
   org-babel-execute-src-block-maybe()
   org-babel-execute-maybe()
   org-babel-execute-safely-maybe()
   run-hook-with-args-until-success(org-babel-execute-safely-maybe)
   org-ctrl-c-ctrl-c(nil)
   call-interactively(org-ctrl-c-ctrl-c nil nil)



[O] Customising colour of heading properties

2014-08-30 Thread Noah Slater
Hello,

Let's say I have this:

*** TODO Org tidy-up
SCHEDULED: 2014-08-22 Fri .+1d/2d
:LOGBOOK:...
:PROPERTIES:...

Now, in my relatively default configuration Org tidy-up is the same
face as everything that appears after it.

Is there any way to make the SCHEDULED, LOGBOOK, and PROPERTIES bits a
different face? (In this case, to make it grey, or less distracting.)

I'd like that if there's actual textual content in the node, after
PROPERTIES, say, that that is the regular face.

Thanks,

-- 
Noah Slater
https://twitter.com/nslater



Re: [O] A Babel block to #+INCLUDE all .org files of a directory

2014-08-30 Thread Andrea Rossetti
Andrea Rossetti andrea.rosse...@gmail.com writes:
   my_reference_manual.org
   abs.org
   ...
   printf.org
   strcpy.org

sorry for the typo, I meant:

  my_c_manual.org
abs.org
...
printf.org
strcpy.org



Re: [O] accessing properties in org-element-parse-buffer tree

2014-08-30 Thread Thorsten Jolitz
Eike e...@eknet.org writes:

 Thanks a lot for the examples, they are very helpful! I first thought to
 parse the org buffer and then work with the resulting tree. 
 
Thats the obvious thing to do in this case, and you can do everything
you want this way, but there are some alternatives too.

 But your examples now makes me think to work directly on the
 buffer. Well, I will play with a few different ways now…

I wrote 'org-dp-filter-node-props' based on 'org-dp-contents', so only
the property-drawer of the current entry is parsed and its content (the
node-properties) filtered. This is meant mostly for local usage (in
contrast to the global parse-tree), but can be used as function argument
for org-map-entries too. 

The big advantage is that it becomes really easy to filter out all the
system properties, or all properties that do not belong to a specific
application. I use it quite often now because I like the database
functionality of Org properties.

-- 
cheers,
Thorsten




[O] How are *you* realizing traceability from your org documents to their tangled and weaved destination?

2014-08-30 Thread Grant Rettke
How are *you* realizing traceability from your org documents to their
tangled and weaved destination?

I was thinking of using UUIDs or git hashes for commits, and wanted to
know what others have done.

Grant Rettke | ACM, ASA, FSF
g...@wisdomandwonder.com | http://www.wisdomandwonder.com/
“Wisdom begins in wonder.” --Socrates
((λ (x) (x x)) (λ (x) (x x)))
“Life has become immeasurably better since I have been forced to stop
taking it seriously.” --Thompson



Re: [O] org-ref no key found

2014-08-30 Thread Julian M. Burgos
John, for some weird reason everything seems to be working now.  Thanks
for your help... I will let you know if I break it again.

John Kitchin writes:

 that is odd. this means org-ref is not finding the key you clicked
 on. could you send me a small example that reproduces your problem (an
 org-file and the bib file)?

 Julian M. Burgos jul...@hafro.is writes:

 Hi John, 

 No, they still do not work even after I click on the bibliography link
 and get my .bib file opened.

 Julian

 John Kitchin writes:

 Julian M. Burgos jul...@hafro.is writes:

 If you click on the bibliography link to open the file, and then go back
 to your org-file, do the cite links work?

 I suspect the notes problem is related to the no key found problem.

 Hello everyone,

 I am playing around with Joh Kitchin's excellent org-ref, and I am
 having a few issues.  In my .emacs file I have set up the values for the
 org-ref-bibliography-notes, org-ref-default-bibliography, and
 org-ref-pdf-directory.

 With this I can access my .bib database and use org-ref-insert-cite link
 to add a citation link with no problems.  But when I press enter on the
 cite link, I get the following message:

 no key found
  (No key found) (p)df (u)rl (n)otes (q) quit

 If I press p I get the pdf file, but if I press n I get the
 following message: 

 Wrong type argument: stringp, nil.

 Any ideas how to solve this?

 Many thanks,

 Julian


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



[O] [[latex:textsc][some text]] becomes \texttt{some text}

2014-08-30 Thread Brady Trainor



I would have expected

[[latex:textsc][some text]]

to become

\textsc{some text}

Instead, it becomes

\texttt{some text}

My hackish fix is to modify a variable,

(setq org-latex-link-with-unknown-path-format \\textsc{%s})

Is there a better way?


Brady
Org-mode version 8.2.7c (8.2.7c-51-g896fa6-elpa @ 
/home/iam/.emacs.d/elpa/org-20140825/)





Re: [O] accessing properties in org-element-parse-buffer tree

2014-08-30 Thread Eric Abrahamsen
Eike e...@eknet.org writes:

 Hello list,

 I want to ask for help regarding elisp and org-elements. I like to
 access the properties of all my headlines and I created the following
 function (tree is the parsed tree) that collects them into an a-list:

You could also take a look at org-collector, in contrib. It might give
you some ideas, or even solve your problem directly.

 #+begin_src emacs-lisp
   (defun collect-props (tree)
 (car (org-element-map tree 'headline
(lambda (hl)
  (when (eq 2 (org-element-property :level hl)) ; want only 
 level-2 properties
(org-element-map hl 'node-property
  (lambda (np)
(cons (org-element-property :key np)
  (org-element-property :value np)
 #+end_src

 I'm not very confident about this, is this ok? Is there a better way?
 For example, the first car looks strange, and I don't know how to get
 rid of it.

 Thanks you very much in advance!!!
 Kind regards
 Eike

 --
 gpg: AD7AC35E
 finger print: 137F BB0B 1639 D25F DC5D  E59C B412 C5F5 AD7A C35E




Re: [O] org-image-actual-width has no effect

2014-08-30 Thread Claudius Mueller
Nick, your code worked! My example image was small and I could change 
the size by altering the width variable. The same image in a regular org 
file is huge.


That means something is wrong with my org-mode install? I have not 
changed or done anything to org-mode that came with the compiled emacs 
24.3 version. Any  tests I can do?


Thank you - this process has already taught me a lot.

Claudius


On 08/29/2014 10:54 PM, Nick Dokos wrote:

Claudius Mueller claudius.muel...@gmail.com writes:


Thanks for trying to help! I really appreciate that!

(image-type-available-p 'imagemagick) == output: t
org-image-actual-width == output: 10

I had set org-image-actual-width to 10 in the .emacs file to make sure
I really notice the difference once the problem is solved.


OK - this looks correct.

Inline images work by creating an overlay on a portion of a text, and
then giving the overlay a property (a key-value pair) where the key is
'display and the value is an image. The following is a minimal example
(you'll have to change the path to the image of course to suit your
situation).

If you execute the first code block with C-c C-c, you should see the
image replacing the word foo; executing the second code block should
get rid of the overlay and let you see foo again. Changing the width
(but not too much: from 50 to 100 and back should work, but larger
overlays tend to make the buffer visually a mess because the code is not
robust enough - you can always recover by killing the buffer and
revisiting the file) and reexecuting the first code block should give
you an image with the new width:

--8---cut here---start-8---
foo

















#+BEGIN_SRC emacs-lisp :results none
(setq ov (make-overlay 1 4))
(overlay-put ov 'display (create-image 
/home/nick/src/org/inline/hello-world.png 'imagemagick nil :width 50))
#+END_SRC


#+BEGIN_SRC emacs-lisp :results none
(delete-overlay ov)
#+END_SRC
--8---cut here---end---8---


In any case, the experiment takes org out of the picture, so if it works
by itself then there is probably a problem with your org-mode. If it
doesn't work, then there is something more basic that's busted.