Re: [O] Reference to org-drawers in the manual

2014-03-29 Thread Nicolas Goaziou
Hello,

Nick Dokos ndo...@gmail.com writes:

 Section 15.6, Summary of in-buffer settings, contains a reference to
 org-drawers which if I'm not mistaken no longer exists:

 `#+DRAWERS: NAME1 ...'
  Set the file-local set of additional drawers.  The corresponding
  global variable is `org-drawers'.

Fixed. Thank you.


Regards,

-- 
Nicolas Goaziou



Re: [O] [bug] Org-verbatim and org-code not converted into HTML tags

2014-03-29 Thread Sebastien Vauban
Hello,

Nicolas Goaziou wrote:
 Sebastien Vauban writes:

 When =:hlines yes=, strips horizontal lines from the input table.

 outputs the following HTML:

 pWhen =:hlines yes=, strips horizontal lines from the input
 table./p

 with Org-mode version 8.2.5h (release_8.2.5h-867-g25c591).

 This should be fixed. Thank you.

This is:

--8---cut here---start-8---
-liduring bweave/b (code blocks with =:exports= set to
-coderesults/code or codeboth/code)/li
+liduring bweave/b (code blocks with code:exports/code set
+to coderesults/code or codeboth/code)/li
--8---cut here---end---8---

Thank you.

Though, there are extra diffs in my HTML output, about the style of the
org-block delimiter lines: they've lost their under/over-line feature,
and colors are not the same anymore.

See:

--8---cut here---start-8---
   div class=org-src-container
 pre class=src src-org
 span style=
-color: #55; background-color: #E2E1D5; text-decoration: 
underline;#+begin_src lt;LANGUAGEgt; lt;HEADER-ARGSgt;/span
+color: #008ED1; background-color: #EAEAFF;#+begin_src lt;LANGUAGEgt; 
lt;HEADER-ARGSgt;/span
 span style=background-color: #E0;lt;BODYgt;
 /spanspan style=
-color: #55; background-color: #E2E1D5; text-decoration: 
overline;#+end_src/span
+color: #008ED1; background-color: #EAEAFF;#+end_src/span
 /pre
   /div
--8---cut here---end---8---

In the previous version (- above), the `org-block-begin-line' (for
example) had well its underline and the colors did match their
definition in the color theme I use (Leuven, in current Emacs trunk, or
on MELPA):

--8---cut here---start-8---
   `(org-block-begin-line ((,class (:underline #A7A6AA :foreground #55 
:background #E2E1D5
   `(org-block-end-line ((,class (:overline #A7A6AA :foreground #55 
:background #E2E1D5
--8---cut here---end---8---

This is not the case anymore. Any idea?

Best regards,
  Seb

-- 
Sebastien Vauban




[O] How to test a draft of a new worg page?

2014-03-29 Thread James Harkins

Hi,

I just searched worg for test a new worg file, but the results seemed 
irrelevant to my question, so...


As promised, I'm writing up my workflow for the big workshop project. I've 
cloned worg, saved my (in progress) org file under exporters/beamer. Now 
I'd like to see what my page will look like *without* having to push 
anything.


I assume I need to specify the worg CSS and perhaps some other export 
properties, but the details are not easy to find and I don't care to guess 
at the moment.


Can somebody explain *really* how to contribute to worg?

Thanks,
hjh



Re: [O] ignoreheading in LaTeX export

2014-03-29 Thread Alan Schmitt
Hi Rasmus,

Rasmus ras...@gmx.us writes:

 This is why you would want to use a filter rather than a hook
 (i.e. you only want to retain the Org structure when exporting).
 Here's a slightly modified version of the filter I use.

Thank you for this suggestion.

I went back to my original problem (how to neatly fold away some setup
code at the beginning of the file) and I'm now using a solution that
seems to work well.

- The setup heading has a 'ignoreheading' tag (there is no longer
  a 'noexport' tag).
- Code blocks inside have a ':exports none' header.
- The next block where I want to add some heading-less text also has
  a 'ignoreheading' tag.
- I'm using the before-parsing hook to get rid of these headings.

Thanks again,

Alan




Re: [O] Chaining strings between babel blocks: why so many '\'?

2014-03-29 Thread Alan Schmitt
Hi Eric,

I see you are the author of ob-dot.el. Should I push the attached patch?

Thanks,

Alan

From c6437e8b7132d95ca432b0690bf65ede6e248567 Mon Sep 17 00:00:00 2001
From: Alan Schmitt alan.schm...@polytechnique.org
Date: Thu, 27 Mar 2014 13:35:31 +0100
Subject: [PATCH] ob-dot.el: Substitute variables literally

* lisp/ob-dot.el (org-babel-expand-body:dot): Do not change the case
nor interpret '\' when substituting block variables.
---
 lisp/ob-dot.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lisp/ob-dot.el b/lisp/ob-dot.el
index b35d7bb..1e399e7 100644
--- a/lisp/ob-dot.el
+++ b/lisp/ob-dot.el
@@ -55,7 +55,9 @@
 	   (replace-regexp-in-string
 		(concat \$ (regexp-quote name))
 		(if (stringp value) value (format %S value))
-		body
+		body
+		t
+		t
  vars)
 body))
 
-- 
1.8.5.3



Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Alan Schmitt
Hello,

Alan Schmitt alan.schm...@polytechnique.org writes:

 Hello,

 Here is a patch that allows for the output of ocaml babel blocks to be
 captured. It also makes the parsing of the resulting value more robust:
 results of type string list are now converted to a table, for
 instance.

 At the moment I only check for results of the form verbatim or
 output (before this patch, only verbatim was possible). Results of
 kind value are parsed as before (converted to a string, a number,
 a table, or left as-is).

 Please don't hesitate to suggest improvements, to the code or to the
 Changelog.

Should I push this patch?

Thanks,

Alan




Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Bastien
Hi Alan,

Alan Schmitt alan.schm...@polytechnique.org writes:

 Should I push this patch?

Please go ahead,

-- 
 Bastien



[O] Why may some Org regexps be risky when set as buffer-local variables?

2014-03-29 Thread Thorsten Jolitz

Hi List, 

there are dozens of regexps that are set as buffer-local variables when
org-mode is turned on as major-mode, but other regexps are defined and
set only once as global variables when e.g. org.el is loaded, and the
docstring of these variables often reads like this:

,---
| org-block-regexp is a variable defined in `org.el'.
| Its value is [...]
| 
|   This variable may be risky if used as a file-local variable.
| 
| Documentation:
| Regular expression for hiding blocks.
`---


Why are these variables considered risky when used as a file-local
variables? Was this risk the prime reason to make them global - or are
they global simply because there was no special reason to make them
buffer-local? 

-- 
cheers,
Thorsten





Re: [O] Images in tables?

2014-03-29 Thread Peter Davis


On 3/28/14, 10:58 PM, Feng Shu wrote:

Peter Davis p...@pfdstudio.com writes:


I'm finishing a PDF document that will contain a number of screen
shots. I'd like to put them in a table to avoid just having them
arranged vertically on the page. Is there a way to do that?

#+MACRO:  p   \includegraphics[scale=1]{$1}

| {{{p(a.png)}}} | {{{p(b.png)}}} |
| {{{p(c.png)}}} | {{{p(d.png)}}} |


Excellent! Thank you.

-pd


--

Peter Davis
The Tech Curmudgeon
www.techcurmudgeon.com




Re: [O] Why may some Org regexps be risky when set as buffer-local variables?

2014-03-29 Thread Nick Dokos
Thorsten Jolitz tjol...@gmail.com writes:

 Hi List, 

 there are dozens of regexps that are set as buffer-local variables when
 org-mode is turned on as major-mode, but other regexps are defined and
 set only once as global variables when e.g. org.el is loaded, and the
 docstring of these variables often reads like this:

 ,---
 | org-block-regexp is a variable defined in `org.el'.
 | Its value is [...]
 | 
 |   This variable may be risky if used as a file-local variable.
 | 
 | Documentation:
 | Regular expression for hiding blocks.
 `---


 Why are these variables considered risky when used as a file-local
 variables? Was this risk the prime reason to make them global - or are
 they global simply because there was no special reason to make them
 buffer-local? 

All it means is that nobody has gone to the trouble of certifying them
as safe. By default, file local variable are considered risky. See

  (info (emacs) Safe File Variables)

for more.
-- 
Nick




Re: [O] Chapter headings

2014-03-29 Thread Scott Randby
On 03/28/2014 10:18 PM, Steven Arntson wrote:
 Back in my mac-user days I used a program called Scrivener that would
 renumber chapters on the fly if I dragged them to new positions. I think
 I was missing that functionality a little, but now that I think about
 it, I shouldn't miss it. It didn't add anything. My next project will be
 to learn more about exporting. I'm sure I will have questions as I
 encounter that ...


One of the wonderful features of Org is the ability to rearrange
headlines easily without worrying about numbering. You can switch
headlines around at will and Org takes care of all the numbering when
you export.

Scott Randby



Re: [O] Why may some Org regexps be risky when set as buffer-local variables?

2014-03-29 Thread Thorsten Jolitz
Nick Dokos ndo...@gmail.com writes:

 Thorsten Jolitz tjol...@gmail.com writes:

 Hi List, 

 there are dozens of regexps that are set as buffer-local variables when
 org-mode is turned on as major-mode, but other regexps are defined and
 set only once as global variables when e.g. org.el is loaded, and the
 docstring of these variables often reads like this:

 ,---
 | org-block-regexp is a variable defined in `org.el'.
 | Its value is [...]
 | 
 |   This variable may be risky if used as a file-local variable.
 | 
 | Documentation:
 | Regular expression for hiding blocks.
 `---


 Why are these variables considered risky when used as a file-local
 variables? Was this risk the prime reason to make them global - or are
 they global simply because there was no special reason to make them
 buffer-local? 

 All it means is that nobody has gone to the trouble of certifying them
 as safe. By default, file local variable are considered risky. See

   (info (emacs) Safe File Variables)

 for more.

Ok, then as long as these variables hold strings there is no risk anyway
since e.g. (eval (+ 2 2)) gives (+ 2 2) and not 4. Thanks.

-- 
cheers,
Thorsten




Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Nicolas Goaziou
Hello,

Alan Schmitt alan.schm...@polytechnique.org writes:

 Should I push this patch?

Nitpick: it is better to remove the dangling parenthesis prior to this. Thanks.


Regards,

-- 
Nicolas Goaziou



Re: [O] Tasks with lots of logbook entries are very slow

2014-03-29 Thread Marcin Borkowski
Dnia 2014-03-28, o godz. 10:37:08
Pere Quintana Seguí p...@quintanasegui.com napisał(a):

 I didn't understand your message. I thought you meant archiving the
 task, but in fact you meant archiving the logs. That's what I've done.

Take a look at the senders: *I* did mean archiving the task, and
*Peter* meant archiving the logs.

 thanks :-)

Best,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Adam Mickiewicz University



Re: [O] Export Org checkboxes in ox-html using UTF-8 symbols

2014-03-29 Thread Marcin Borkowski
Dnia 2014-03-28, o godz. 10:59:43
Rick Frankel r...@rickster.com napisał(a):

 On 2014-03-28 10:01, Sebastien Vauban wrote:
  Rick Frankel wrote:
  BTW, i used [nbsp;] for the unchecked box (we use the same for
  checked and trans)... I think i'll change the unchecked box to
  #x2610; to match the checked box (same as sachua).
  
  Isn't it error-prone and very misleading to have 3 different states
  in the Org files, and just 2 different in the HTML exports?
 
 There *are* three different states in the exported file -- the
 transient mode is for partially completed rollups:
 
 #+BEGIN_SRC org
 ,* rollup
 - [-] All done
 - [X] one
 - [ ] two
 #+END_SRC
 
 Generates (abbreviated and indented):
 
 #+BEGIN_SRC html
 ul class=org-ul
 licode[-]/code All done
 ul class=org-ul
 licode[X]/code one
 /li
 licode[#xa0;]/code two
 /li
 /ul
 /li
 /ul
 #+END_SRC

Wouldn't it be better to have (maybe in addition) three distinct
classes for the li elements with checkboxes in various states?  This
would make styling them with CSS possible.

 rick

Best,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Adam Mickiewicz University



Re: [O] ignoreheading in LaTeX export

2014-03-29 Thread Marcin Borkowski
Dnia 2014-03-27, o godz. 09:23:06
Alan Schmitt alan.schm...@polytechnique.org napisał(a):

 Hello,
 
 I need to ignore a heading during a LaTeX export (I don't want the
 section command to be generated, but I need the text to be included;
 the heading is there because the previous one is tagged with
 export). I found this solution:
 
 https://stackoverflow.com/questions/10295177/is-there-an-equivalent-of-org-modes-b-ignoreheading-for-non-beamer-documents
 
 Is it still the way to go?

Just my 2 cents: you could always go for a /really/ dirty hack and do
it on the LaTeX side.  AFAIR, tags end up somewhere in the title of the
section, so you can /redefine/ the =\section= macro to recognize that
and do nothing in that case.  This is most probably an overkill, but
the general rule (maybe) worth remembering would be: if you want to
tweak something with LaTeX export, it /might/ be possible that it would
be (a) doable and maybe even (b) reasonable to do it on the LaTeX side.

 Thanks,
 
 Alan

Hth,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Adam Mickiewicz University



Re: [O] How to setup this custom function with Org-mode functions? (org-habit)

2014-03-29 Thread Marcin Borkowski
Dnia 2014-03-28, o godz. 16:09:01
stardiviner numbch...@gmail.com napisał(a):

 
 I want to create a custom keybinding to custom function which will
 execute all necessary steps for creating an org habit.
 The bellowing is my code, but seems it doesn't work at all.
 I don't know how to write this custom function actually. (I just put
 some keybindings corresponding functions in the custom function
 body.) And some org-mode functions are interactively.
 
 #+BEGIN_SRC emacs-lisp
 ;; TODO: create an key binding for all necessary steps for create a
 habit. (reference in Org-mode.org file) (defun org-habit-apply ()
   Apply org-habit on this task.
   (interactive)
   (lambda ()
 (org-todo HABIT)
 (org-insert-property-drawer); TODO: :STYLE: habit (value)
 (org-schedule)))
 
 (define-key org-mode-map (kbd C-c C-x h) 'org-habit-apply)
 #+END_SRC
 
 Does anybody can help me this? and thanks in advance.

Is this of any help?

http://mbork.pl/2013-09-23_Automatic_insertion_of_habit_templates_%28en%29

Hth,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Adam Mickiewicz University



Re: [O] Proposal to replace the prefix repetition with whitespace during expansion of noweb references

2014-03-29 Thread Charles Berry
Pontus Michael m.pontus at gmail.com writes:

 
 I would like to propose a change to the behavior of noweb expansion in 
 relation to prefix handling. 
[snip]


 I recommend to introduce a change that will replace the inserted prefix
 with whitespace of equal length.

[snip]


The behavior you desire can be obtained by using the 

 code-block-name(optional arguments)

idiom for noweb. For example, with a suitably crafted block called 
'my-noweb', this reference

my-noweb( (concat, foo, ) )

would expand just as you want. You can use the functions
org-babel-goto-named-src-block  and org-babel-get-src-block-info to achieve
this.

Multiple noweb references might be handled as well by delimiting the second
argument, e.g. foo,bar.

---

Revising the behavior of the existing code base might break code
that folks have written that depend on the current behavior.

HTH,

Chuck




[O] exporting link abbreviations

2014-03-29 Thread Greg Minshall
hi.  i'm playing with the example in the manual of a google map link
(gmap:).  technology is wonderful, and it's amazing (to simple-minded
me) to see the map pop up with the locations.

but, i'm less happy with how these links look when i've provided no
description and they are exported.  if i have a link like:

[[gmap:123 Main Street, Our Town, California, United States]]


what is *shown* on the exported web page (say) is something ugly like:

http://maps.google.com/maps?q=123%20Main%20Street,%20Our%20Town,%20California,%20United%20States


i'd rather not specify the address twice (once in the link tag, a second
time in the link description), out of laziness, i guess (but also for
2nd-normal-form'ity).

what i'd *like* the user to see on the web page is the address (123
Main Street, Out Town, California, United States, in this example).

i could define a macro:

#+MACRO: gmap   [[gmap: $1][$1]]

and invoke it with

{{{gmap(123 Main Street Los Altos California United States)}}}


but then
1) i'd have to get rid of the commas in the address (it might
be nice to have a $* or some such to give the entire argument ); and

2) i wouldn't have the link active in my org-mode buffer itself
(something i find so magical, plus it helps entering the info to be able
to check the map before exporting).

i wonder if there's something i've missed?  or, if something could be
added?

cheers, Greg Minshall



Re: [O] Images in tables?

2014-03-29 Thread Marcin Borkowski
Dnia 2014-03-29, o godz. 10:58:59
Feng Shu tuma...@gmail.com napisał(a):

 Peter Davis p...@pfdstudio.com writes:
 
  I'm finishing a PDF document that will contain a number of screen
  shots. I'd like to put them in a table to avoid just having them
  arranged vertically on the page. Is there a way to do that?
 
 #+MACRO:  p   \includegraphics[scale=1]{$1}
 
 | {{{p(a.png)}}} | {{{p(b.png)}}} |
 | {{{p(c.png)}}} | {{{p(d.png)}}} |

I wouldn't use [scale=1] (it seems to depend on the resolution set up
properly in the bitmap file).  Why not use [height=2in] or [width=3cm]
etc.?

Hth,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Adam Mickiewicz University



Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Alan Schmitt
Nicolas Goaziou n.goaz...@gmail.com writes:

 Hello,

 Alan Schmitt alan.schm...@polytechnique.org writes:

 Should I push this patch?

 Nitpick: it is better to remove the dangling parenthesis prior to
 this. Thanks.

I'm sorry, but I don't see a dangling parenthesis. Where is it?

Thanks,

Alan




Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Nicolas Goaziou
Alan Schmitt alan.schm...@polytechnique.org writes:

+  (mapcar #'org-babel-trim (reverse raw)))
+(raw (org-babel-trim clean))
+(result-params (cdr (assoc :result-params params)))
+(parsed 
+ (string-match 
+  \\(\\(.*\n\\)*\\)[^:\n]+ : \\([^=\n]+\\) =\\(\n\\| \\)\\(.+\\)$ 
+  raw))
+(output (match-string 1 raw))
+(type (match-string 3 raw))
+(value (match-string 5 raw))
+)

 ^
Here.


Regards,

-- 
Nicolas Goaziou



Re: [O] exporting link abbreviations

2014-03-29 Thread Nicolas Goaziou
Hello,

Greg Minshall minsh...@acm.org writes:

 but, i'm less happy with how these links look when i've provided no
 description and they are exported.  if i have a link like:
 
 [[gmap:123 Main Street, Our Town, California, United States]]
 

 what is *shown* on the exported web page (say) is something ugly like:
 
 http://maps.google.com/maps?q=123%20Main%20Street,%20Our%20Town,%20California,%20United%20States
 

 i'd rather not specify the address twice (once in the link tag, a second
 time in the link description), out of laziness, i guess (but also for
 2nd-normal-form'ity).

 what i'd *like* the user to see on the web page is the address (123
 Main Street, Out Town, California, United States, in this example).

 i could define a macro:
 
 #+MACRO: gmap   [[gmap: $1][$1]]
 
 and invoke it with
 
 {{{gmap(123 Main Street Los Altos California United States)}}}
 

 but then
 1) i'd have to get rid of the commas in the address (it might
 be nice to have a $* or some such to give the entire argument ); and

No, you don't have to. Commas can be escaped within a macro:

  {{{gmap(123 Main Street\, Los Altos\, California\, United States)}}}

 2) i wouldn't have the link active in my org-mode buffer itself
 (something i find so magical, plus it helps entering the info to be able
 to check the map before exporting).

You may want to add gmap as a new link type with dedicated export
functions. See `org-add-link-type'.


Regards,

-- 
Nicolas Goaziou



Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Alan Schmitt
Nicolas Goaziou n.goaz...@gmail.com writes:

 Alan Schmitt alan.schm...@polytechnique.org writes:

 +(mapcar #'org-babel-trim (reverse raw)))
 +  (raw (org-babel-trim clean))
 +  (result-params (cdr (assoc :result-params params)))
 +  (parsed 
 +   (string-match 
 +\\(\\(.*\n\\)*\\)[^:\n]+ : \\([^=\n]+\\) =\\(\n\\| \\)\\(.+\\)$ 
 +raw))
 +  (output (match-string 1 raw))
 +  (type (match-string 3 raw))
 +  (value (match-string 5 raw))
 +  )

  ^
 Here.

OK, I put it on the previous line. I'll commit now.

Thanks,

Alan




Re: [O] I need help extending ob-ocaml to support :results output

2014-03-29 Thread Nicolas Goaziou
Alan Schmitt alan.schm...@polytechnique.org writes:

 OK, I put it on the previous line. I'll commit now.

Thank you.

-- 
Nicolas Goaziou



[O] Bug : Subscripting not properly working

2014-03-29 Thread Xavier Garrido

Dear Orgers,

I get a strange behavior when using subscripting /i.e./ =_= char. Here 
is a minimal example


subscripting.org

#+OPTIONS: ^:{}

The file a_b_c works.

The file a_b_c_d does not work.

The file =a_b_c_d= works again.

When exporting to pdf through LaTeX, the first and last lines export 
properly while the second line gives the following result


The file a_b d__cdoes not work.

The problem occurs when using more than 2 underscores.

Cheers,
Xavier



[O] Bug: `org-agenda-prepare-buffers' fails at (org-refresh-properties APPT_WARNTIME 'org-appt-warntime) [8.2.5h (8.2.5h-82-gd91d4b-elpaplus @ /home/wgg/.emacs.d/elpa/org-plus-contrib-20140324/)]

2014-03-29 Thread wgg2

Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.  You don't know how to make a good report?  See

 http://orgmode.org/manual/Feedback.html#Feedback

Your bug report will be posted to the Org-mode mailing list.


Hello,

On the latest `org-plus-contrib' build from the org package.el repo, my
Agenda buffers (for any Agenda command) fail to render properly, with
these pertinent lines from *Backtrace*:

--8---cut here---start-8---
Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil)
  put-text-property(28484 nil org-appt-warntime 60)
  org-refresh-properties(APPT_WARNTIME org-appt-warntime)
  (or (memq (quote appt) org-agenda-ignore-drawer-properties) 
(org-refresh-properties APPT_WARNTIME (quote org-appt-warntime)))
--8---cut here---end---8---

I first attempted to deactivate all use of the appt library in my Emacs,
including my setting of agenda-mode-hook which previously had called
`org-agenda-to-appt'. Still the Agenda would not render correctly.

I then isolated this to the following lines of function
`org-agenda-prepare-buffers':

--8---cut here---start-8---
(or (memq 'appt org-agenda-ignore-drawer-properties)
(org-refresh-properties APPT_WARNTIME 'org-appt-warntime))
--8---cut here---end---8---

With these lines commented out, my Agenda buffer was able to load
correctly.

Best,
WGG


Emacs  : GNU Emacs 24.3.1 (x86_64-slackware-linux-gnu)
 of 2014-03-13 on motoko
Package: Org-mode version 8.2.5h (8.2.5h-82-gd91d4b-elpaplus @ 
/home/wgg/.emacs.d/elpa/org-plus-contrib-20140324/)

current state:
==
(setq
 org-id-locations-file ~/org/.org-id-locations
 org-tab-first-hook '(org-hide-block-toggle-maybe 
org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe 
org-babel-header-arg-expand)
 org-latex-classes '((memoir-MSWordish
  
\\documentclass[12pt,article,oneside]{memoir}\n\\usepackage{times}\n\\usepackage{indentfirst}\n\\usepackage[left=1in,right=1in,top=1in,bottom=1in]{geometry}\n\\linespread{1.6}
  (\\chapter{%s} . \\chapter*{%s}) (\\section{%s} . 
\\section*{%s}) (\\subsection{%s} . \\subsection*{%s})
  (\\subsubsection{%s} . \\subsubsection*{%s}) 
(\\paragraph{%s} . \\paragraph*{%s}))
 (beamer \\documentclass{beamer} org-beamer-sectioning)
 (my-letter
  
\\documentclass[fromalign=left,backaddress=false]{scrlttr2}\n\\usepackage[english]{babel}\n\\usepackage{times}\n\\usepackage{indentfirst}\n\\usepackage[left=1in,right=1in,top=1in,bottom=1in]{geometry}\n\\linespread{1.6})
 (memoir-helvetica
  
\\documentclass[12pt,article,oneside]{memoir}\n\\usepackage{helvet}\n\\renewcommand*{\\familydefault}{\\sfdefault}\n\\usepackage{indentfirst}\n\\usepackage[left=1in,right=1in,top=1in,bottom=1in]{geometry}\n\\linespread{1.6}
  (\\chapter{%s} . \\chapter*{%s}) (\\section{%s} . 
\\section*{%s}) (\\subsection{%s} . \\subsection*{%s})
  (\\subsubsection{%s} . \\subsubsection*{%s}) 
(\\paragraph{%s} . \\paragraph*{%s}))
 (memoir-MSWordish-tiny
  
\\documentclass[10pt,article,oneside]{memoir}\n\\usepackage{times}\n\\usepackage{indentfirst}\n\\usepackage[left=1in,right=1in,top=1in,bottom=1in]{geometry}
  (\\chapter{%s} . \\chapter*{%s}) (\\section{%s} . 
\\section*{%s}) (\\subsection{%s} . \\subsection*{%s})
  (\\subsubsection{%s} . \\subsubsection*{%s}) 
(\\paragraph{%s} . \\paragraph*{%s}))
 )
 org-footnote-section nil
 org-latex-default-packages-alist '((utf8 inputenc t) (T1 fontenc t) 
( fixltx2e nil) ( graphicx t) ( longtable nil) ( float nil)
( wrapfig nil) (normalem ulem t) 
( textcomp t) ( marvosym t) ( wasysym t) ( latexsym t)
( amssymb t) ( amstext nil) ( 
hyperref nil) \\tolerance=1000)
 org-speed-command-hook '(org-speed-command-default-hook 
org-babel-speed-command-hook)
 org-gnus-prefer-web-links t
 org-agenda-diary-file ~/org/Diary.org
 org-occur-hook '(org-first-headline-recenter)
 org-src-tab-acts-natively t
 org-imenu-depth 4
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-html-format-drawer-function '(lambda (name contents) contents)
 org-latex-format-inlinetask-function 'ignore
 org-confirm-shell-link-function 'yes-or-no-p
 org-id-link-to-org-use-id t
 org-columns-default-format %40ITEM %10TODO %10Effort\n  %20TAGS
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-export-with-date nil
 org-export-with-section-numbers nil
 org-export-with-toc nil
 

Re: [O] exporting link abbreviations

2014-03-29 Thread Greg Minshall
Nicholas,

 You may want to add gmap as a new link type with dedicated export
 functions. See `org-add-link-type'.

awesome -- thanks!  (sorry i didn't see it/think of it in the manual.)

cheers, Greg

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

 Hello,
 
 Greg Minshall minsh...@acm.org writes:
 
  but, i'm less happy with how these links look when i've provided no
  description and they are exported.  if i have a link like:
  
  [[gmap:123 Main Street, Our Town, California, United States]]
  
 
  what is *shown* on the exported web page (say) is something ugly like:
  
  http://maps.google.com/maps?q=123%20Main%20Street,%20Our%20Town,%20California,%20United%20States
  
 
  i'd rather not specify the address twice (once in the link tag, a second
  time in the link description), out of laziness, i guess (but also for
  2nd-normal-form'ity).
 
  what i'd *like* the user to see on the web page is the address (123
  Main Street, Out Town, California, United States, in this example).
 
  i could define a macro:
  
  #+MACRO: gmap   [[gmap: $1][$1]]
  
  and invoke it with
  
  {{{gmap(123 Main Street Los Altos California United States)}}}
  
 
  but then
  1) i'd have to get rid of the commas in the address (it might
  be nice to have a $* or some such to give the entire argument ); and
 
 No, you don't have to. Commas can be escaped within a macro:
 
   {{{gmap(123 Main Street\, Los Altos\, California\, United States)}}}
 
  2) i wouldn't have the link active in my org-mode buffer itself
  (something i find so magical, plus it helps entering the info to be able
  to check the map before exporting).
 
 You may want to add gmap as a new link type with dedicated export
 functions. See `org-add-link-type'.
 
 
 Regards,
 
 -- 
 Nicolas Goaziou
 



[O] TODOs in the agenda?

2014-03-29 Thread Sharon Kimble
I have a document called 'organiser.org' which is mainly comprised of various
TODOs under various projects, and various NEXT under birthdays and hospital
appointments. These TODOs can be up to 4 levels in depth, and with one level 1
TODO as the project header. How can all of these TODOs be included in the agenda
please?

Here is one example - 

,
| * Jobs to do [53%] [8/15]
| ** TODO eat breakfast
`

and another -

,
| ** Gnus setup [5/6] [83%]
| *** DONE set up gnus for localhost email
| CLOSED: [2014-03-25 Tue 16:57]
| *** DONE set up gnus for gmail
| CLOSED: [2014-03-25 Tue 16:57]
| *** TODO get bbdb working with gnus
`

And the whole document is like that, several projects with loads of TODOs
within them, but how do I get them all showing in the agenda please?

Thanks
Sharon.
-- 
A taste of linux = http://www.sharons.org.uk
my git repo = https://bitbucket.org/boudiccas/dots
TGmeds = http://www.tgmeds.org.uk
Debian testing, Fluxbox 1.3.5, emacs 24.3.1



Re: [O] Bug : Subscripting not properly working

2014-03-29 Thread Nicolas Goaziou
Hello,

Xavier Garrido xavier.garr...@gmail.com writes:

 I get a strange behavior when using subscripting /i.e./ =_= char. Here 
 is a minimal example

 subscripting.org
 
 #+OPTIONS: ^:{}

 The file a_b_c works.

 The file a_b_c_d does not work.

 The file =a_b_c_d= works again.

 When exporting to pdf through LaTeX, the first and last lines export 
 properly while the second line gives the following result

 The file a_b d__cdoes not work.

 The problem occurs when using more than 2 underscores.

This should be fixed. Thank you.


Regards,

-- 
Nicolas Goaziou



[O] [SOLVED] Re: TODOs in the agenda?

2014-03-29 Thread Sharon Kimble
Sharon Kimble boudic...@talktalk.net writes:

 I have a document called 'organiser.org' which is mainly comprised of various
 TODOs under various projects, and various NEXT under birthdays and hospital
 appointments. These TODOs can be up to 4 levels in depth, and with one level 1
 TODO as the project header. How can all of these TODOs be included in the 
 agenda
 please?

 Here is one example - 

 ,
 | * Jobs to do [53%] [8/15]
 | ** TODO eat breakfast
 `

 and another -

 ,
 | ** Gnus setup [5/6] [83%]
 | *** DONE set up gnus for localhost email
 | CLOSED: [2014-03-25 Tue 16:57]
 | *** DONE set up gnus for gmail
 | CLOSED: [2014-03-25 Tue 16:57]
 | *** TODO get bbdb working with gnus
 `

 And the whole document is like that, several projects with loads of TODOs
 within them, but how do I get them all showing in the agenda please?

Sorted, just C-s each one and schedule the task, then it shows in the
agenda. Doh!

Sharon.
-- 
A taste of linux = http://www.sharons.org.uk
my git repo = https://bitbucket.org/boudiccas/dots
TGmeds = http://www.tgmeds.org.uk
Debian testing, Fluxbox 1.3.5, emacs 24.3.1


pgp5ANgPCvhOZ.pgp
Description: PGP signature


Re: [O] Reference to org-drawers in the manual

2014-03-29 Thread Christian Wittern

On 2014-03-29, 13:37, Nick Dokos wrote:

`#+DRAWERS: NAME1 ...'
  Set the file-local set of additional drawers.  The corresponding
  global variable is `org-drawers'.
Has that been removed?  I do rely quite heavily on this and do not want to 
loose it.  Which version dropped it and what is the suggested workaround?


In case somebody wonders, I am using custom drawers for specific multiline 
annotations and declare them in the file header.


All the best,  Christian

--
Christian Wittern, Kyoto




Re: [O] Export arrays for 'sh' code blocks when using bash

2014-03-29 Thread Eric Schulte
Thanks for making these changes.  Once they're in and Bastien figures
out how the google-wide copyright attribution works we should be good to
go.

Thanks!

Pascal Fleury fle...@google.com writes:

 Hi Eric, see comments inline.


 On Thu, Mar 27, 2014 at 6:43 PM, Eric Schulte schulte.e...@gmail.comwrote:

 Hi Pascal,

 This looks like a good patch.  If I could make three changes/requests.


 Thanks, I am happy to see it makes sense.


 1. This patch should also work for begin_src bash code blocks.  After
a very quick glance it doesn't appear to.

 I have actually tried this with the latest org-mode release (8.2.5h) and
 it did plainly not accept 'begin_src bash'. Maybe that's new with the
 ob-shell.el (I noticed it has been renamed :-)


 2. Could you include one or two tests ensuring that this patch does what
it intends with bash code blocks, and does not affect code blocks
executed with bin/sh?


 Will do, seeing it has some traction.



 3. Large contributions like this require some FSF paperwork.  Please see
the following page for information on requirements to contribute.


 I checked internally, and apparently, Google has already such a signed
 document. It would run on the same document, as I am a google employee.


http://orgmode.org/worg/org-contribute.html

 Thanks, and I look forward to seeing this merged into Org-mode!
 Eric

 Pascal Fleury fle...@google.com writes:

  Hello,
 
  I'dl like to propose a patch for inclusion into org-mode (ob-shell.el in
  particular).
 
  *TL;DR:* use arrays and associative arrays when exporting variables to
 bash
  in 'sh' code blocks.
 
  *Details:*
  When variables are defined in a 'sh' code block, they are exported as
  strings. when the variable itself is an array or a table, then we simply
  get a shell variable that contains the list of all values in a
  non-structured form. E.g.
 
  #+NAME: my_list
  | one   |
  | two   |
  | three |
 
  #+NAME: experiment
  | name | first_attempt|
  | date | [2014-03-27 Thu] |
  | user | fleury   |
 
  #+BEGIN_SRC sh :var scalar=some value :var array=my_list :var
 table=config
  echo ${scalar}  # - prints 'some value'
  echo ${array}   # - prints 'one two three'
  echo ${table}   # - prints 'first attempt [2014-03-27 Thu] fleury'
  #+END_SRC
 
  This will print simple strings. Also, there is no easy way to access the
  date of the experiment, for example. Now bash has things like arrays and
  associative arrays, but the current ob-shell.el does not use these.
  Probably because their syntax is bash-specific, and ob-shell.el is
  shell-agnostic.
 
  My patch (attached) changes this in the case you have
  (setq org-babel-sh-command bash)
  in your emacs config somewhere. If any other value is used, it continues
 to
  export them as we do today (I don't know enough about other shells).
 
  In that case, it will export the list as an array, the table as an
  associative array, and the scalar as it does already. So the 'sh' code
  block could then use
 
  #+BEGIN_SRC sh :var scalar=some value :var array=my_list :var
 table=config
  echo ${scalar}
  echo ${array[1]} # - prints two
  echo ${table[user]} # - prints fleury
  #+END_SRC
 
  In the case we have a bigger table, then the first row is used as key,
 the
  others are represented as a string with all the values (as it is for
 array
  currently). bash does not have multi-dimensional arrays, so it needs to
 be
  a string.
 
  This makes writing shell snippets much easier in my experience, and there
  I'd like to propose this fix for the org-mode community at large.
 
  --paf
 
  diff --git a/lisp/ob-shell.el b/lisp/ob-shell.el
  index 3ede701..0a691e2 100644
  --- a/lisp/ob-shell.el
  +++ b/lisp/ob-shell.el
  @@ -106,6 +106,30 @@ This function is called by
 `org-babel-execute-src-block'.
 
   ;; helper functions
 
  +(defun org-babel-variable-assignments:bash_array (varname values
 optional sep hline)
  +  Returns a list of statements declaring the values as a bash array.
  +  (format declare -a %s=( \%s\ )
  + varname
  + (mapconcat 'identity
  +   (mapcar
  + (lambda (value) (org-babel-sh-var-to-sh value sep hline))
  + values)
  +   \ \)))
  +
  +(defun org-babel-variable-assignments:bash_associative (varname values
 optional sep hline)
  +  Returns a list of statements declaring the values as bash
 associative array.
  +  (format declare -A %s\n%s
  +varname
  +(mapconcat 'identity
  +  (mapcar
  +(lambda (items)
  +  (format %s[\%s\]=%s
  +varname
  +(org-babel-sh-var-to-sh (car items) sep hline)
  +(org-babel-sh-var-to-sh (cdr items) sep hline)))
  +values)
  +  \n)))
  +
   (defun org-babel-variable-assignments:sh (params)
 Return list of shell statements assigning the block's variables.
 (let ((sep (cdr (assoc :separator params)))
  @@ -114,9 +138,17 @@ This function is called by
 `org-babel-execute-src-block'.