[O] Captions for src and example blocks

2012-01-13 Thread Christian Wittern
Dear Orgmoders,

There was a thread last April about a way to introduce captions and
labels to src and example blocks (see
http://lists.gnu.org/archive/html/emacs-orgmode/2011-04/msg00877.html).
 Now I would like to use captions in a similar way, but not just for
LaTex, but also for the ODT export.  So a generic org-mode solution
would be much more helpful. I wonder if somebody has any idea about
how to achieve this.

Greetings,  Chris

-- 
Christian Wittern, Kyoto



[O] org-float with hours

2012-01-13 Thread sergio
Hello.

Is it possible to specify "every second Friday of each month at 15:43" date?

-- 
sergio.



Re: [O] No pictures when exporting narrowed/subtree

2012-01-13 Thread Ken Williams
> -Original Message-
> ... if I put my cursor near "Some more text" and choose 'switch
> buffer/subtree export' when exporting, or if I narrow (C-x n d) to that
> subtree and then export, the 'testout.png' plot doesn't show up.

Ping - anyone able to replicate or not replicate this?

 -Ken

CONFIDENTIALITY NOTICE: This e-mail message is for the sole use of the intended 
recipient(s) and may contain confidential and privileged information. Any 
unauthorized review, use, disclosure or distribution of any kind is strictly 
prohibited. If you are not the intended recipient, please contact the sender 
via reply e-mail and destroy all copies of the original message. Thank you.



Re: [O] Org-edit-special and C-x C-s strange behavior

2012-01-13 Thread Leo Alekseyev
>>>
>>> You still have to C-c ' to get back to the full buffer, mind you, but
>>> that's better, IMO, than changing the behaviour of such a fundamental
>>> key binding as C-x C-s.
>
>
> It appears that this bug is Emacs-version dependent: it functions as
> you describe with 23.2, but the buffer gets buried (with an error
> message "basic-save-buffer: Wrong type argument: stringp, nil") in
> 24.0.92.  Org mode is the current git HEAD.  I tried to step through
> basic-save-buffer in edebug, but I couldn't catch the error (I'm not
> very experienced with edebug).  Can someone test this on Emacs 24 and
> confirm what I'm seeing?


 I am using 24.0.92 and I have no problems at all (just tried right
 now).

 One difference, however, could be the window configurations we
 use.  Specifically, I have

       (setq org-src-window-setup (quote current-window))
>>
>>
>> Yes, this works. It's also a more sensible default. However, it
>> doesn't change the fact that there's a bug, it just switches to a case
>> where the bug isn't triggered :)
>
>
> It is also not triggered by the "other-window" option, which behaves more
> like
> "reorganize-frame" than "current-window" (emacs 24.0.92)

Folks, I still think that the fact that buffer-file-name is not nil is
a bug and should be fixed.  If I'm wrong, can someone point out why
this is so?

I have seen many functions that test whether or not a buffer is
visiting a file by checking buffer-file-name.  For instance, if I
wanted to enable autosave for org-src buffers, it would break since my
make-auto-save-file-name checks whether a file is being visited.

--Leo



Re: [O] Bug: ob-clojure.el depends on deprecated swank-clojure [7.7]

2012-01-13 Thread Eric Schulte
OK, I've just pushed up this change, please do test it out locally on
some more code blocks and let me know if you run into any more problems.

Thanks,

Andrew Cheng  writes:

> I think so. Here's *Messages* after (def ^:dynamic *state* {}) ...
>
> org-babel-execute:clojure
> Evaluate this clojure code block (state) on your system? (y or n)
> executing Clojure code block (state)...
> ("" "#'user/*state*")
>
> On Fri, Jan 13, 2012 at 2:48 PM, Eric Schulte  wrote:
>> Alright,
>>
>> if you load ob-clojure.el and then evaluate the following to over-ride
>> the existing definition of `org-babel-execute:clojure' does clojure code
>> evaluation work?
>>
>> (defun org-babel-execute:clojure (body params)
>>  "Execute a block of Clojure code with Babel."
>>  (require 'slime)
>>  (with-temp-buffer
>>    (insert (org-babel-expand-body:clojure body params))
>>    ((lambda (result)
>>       (let ((result-params (cdr (assoc :result-params params
>>         (if (or (member "scalar" result-params)
>>                 (member "verbatim" result-params))
>>             result
>>           (condition-case nil (org-babel-script-escape result)
>>             (error result)
>>     (slime-eval
>>      `(swank:eval-and-grab-output
>>        ,(buffer-substring-no-properties (point-min) (point-max)))
>>      (cdr (assoc :package params))
>>
>> Thanks,
>>
>> Andrew Cheng  writes:
>>
>>> I passed the question along to Phil Hagelberg in that Clojure google
>>> group thread. His reply:
>>>
>>> "Yes, clojure-test-mode uses both slime-eval and slime-eval-async; he
>>> should pick one of these like so:
>>>
>>> (defun clojure-test-eval (string &optional handler)
>>>  (slime-eval-async `(swank:eval-and-grab-output ,string)
>>>                    (or handler #'identity)))
>>>
>>> (defun clojure-test-eval-sync (string)
>>>  (slime-eval `(swank:eval-and-grab-output ,string)))
>>>
>>> Actually swank:interactive-eval-region and friends are not elisp
>>> functions; they are Clojure functions."
>>>
>>> (... end of reply) In case it helps, Stuart Sierra says he got
>>> org-babel and clojure working together. His dotfiles are at
>>> https://github.com/stuartsierra/dotfiles
>>>
>>> On Fri, Jan 13, 2012 at 1:09 AM, Eric Schulte  wrote:
 I personally no longer use Clojure (having graduated to Common Lisp :))
 so I'm not abreast of the current Clojure environment.

 The only function ob-clojure uses from swank-clojure is
 `swank:interactive-eval-region' (used with `slime-eval') in the
 `org-babel-execute:clojure' function.  Which function would now be used
 to evaluate a region of clojure code?  Would `slime-eval-region'
 suffice?

 Andrew Cheng  writes:

> 
>
> Phil Hagelberg has said that the swank-clojure elisp package has been
> deprecated and should not be used [1]. My version of ob-clojure.el
> requires swank-clojure. If I don't have the swank-clojure package, I
> get "org-babel-execute:clojure:Cannot open load file: swank-clojure".
> If I follow the instructions at [2] and get the swank-clojure package,
> I get past this error. Is org using a deprecated package, and is this
> a bug? Thanks in advance.
>
> [1] https://groups.google.com/forum/#!starred/clojure/HT8wixvD3GE
> [2] http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00629.html
>>
>> --
>> Eric Schulte
>> http://cs.unm.edu/~eschulte/

-- 
Eric Schulte
http://cs.unm.edu/~eschulte/



Re: [O] Bug: ob-clojure.el depends on deprecated swank-clojure [7.7]

2012-01-13 Thread Andrew Cheng
I think so. Here's *Messages* after (def ^:dynamic *state* {}) ...

org-babel-execute:clojure
Evaluate this clojure code block (state) on your system? (y or n)
executing Clojure code block (state)...
("" "#'user/*state*")

On Fri, Jan 13, 2012 at 2:48 PM, Eric Schulte  wrote:
> Alright,
>
> if you load ob-clojure.el and then evaluate the following to over-ride
> the existing definition of `org-babel-execute:clojure' does clojure code
> evaluation work?
>
> (defun org-babel-execute:clojure (body params)
>  "Execute a block of Clojure code with Babel."
>  (require 'slime)
>  (with-temp-buffer
>    (insert (org-babel-expand-body:clojure body params))
>    ((lambda (result)
>       (let ((result-params (cdr (assoc :result-params params
>         (if (or (member "scalar" result-params)
>                 (member "verbatim" result-params))
>             result
>           (condition-case nil (org-babel-script-escape result)
>             (error result)
>     (slime-eval
>      `(swank:eval-and-grab-output
>        ,(buffer-substring-no-properties (point-min) (point-max)))
>      (cdr (assoc :package params))
>
> Thanks,
>
> Andrew Cheng  writes:
>
>> I passed the question along to Phil Hagelberg in that Clojure google
>> group thread. His reply:
>>
>> "Yes, clojure-test-mode uses both slime-eval and slime-eval-async; he
>> should pick one of these like so:
>>
>> (defun clojure-test-eval (string &optional handler)
>>  (slime-eval-async `(swank:eval-and-grab-output ,string)
>>                    (or handler #'identity)))
>>
>> (defun clojure-test-eval-sync (string)
>>  (slime-eval `(swank:eval-and-grab-output ,string)))
>>
>> Actually swank:interactive-eval-region and friends are not elisp
>> functions; they are Clojure functions."
>>
>> (... end of reply) In case it helps, Stuart Sierra says he got
>> org-babel and clojure working together. His dotfiles are at
>> https://github.com/stuartsierra/dotfiles
>>
>> On Fri, Jan 13, 2012 at 1:09 AM, Eric Schulte  wrote:
>>> I personally no longer use Clojure (having graduated to Common Lisp :))
>>> so I'm not abreast of the current Clojure environment.
>>>
>>> The only function ob-clojure uses from swank-clojure is
>>> `swank:interactive-eval-region' (used with `slime-eval') in the
>>> `org-babel-execute:clojure' function.  Which function would now be used
>>> to evaluate a region of clojure code?  Would `slime-eval-region'
>>> suffice?
>>>
>>> Andrew Cheng  writes:
>>>
 

 Phil Hagelberg has said that the swank-clojure elisp package has been
 deprecated and should not be used [1]. My version of ob-clojure.el
 requires swank-clojure. If I don't have the swank-clojure package, I
 get "org-babel-execute:clojure:Cannot open load file: swank-clojure".
 If I follow the instructions at [2] and get the swank-clojure package,
 I get past this error. Is org using a deprecated package, and is this
 a bug? Thanks in advance.

 [1] https://groups.google.com/forum/#!starred/clojure/HT8wixvD3GE
 [2] http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00629.html
>
> --
> Eric Schulte
> http://cs.unm.edu/~eschulte/



Re: [O] Bug: ob-clojure.el depends on deprecated swank-clojure [7.7]

2012-01-13 Thread Eric Schulte
Alright,

if you load ob-clojure.el and then evaluate the following to over-ride
the existing definition of `org-babel-execute:clojure' does clojure code
evaluation work?

(defun org-babel-execute:clojure (body params)
  "Execute a block of Clojure code with Babel."
  (require 'slime)
  (with-temp-buffer
(insert (org-babel-expand-body:clojure body params))
((lambda (result)
   (let ((result-params (cdr (assoc :result-params params
 (if (or (member "scalar" result-params)
 (member "verbatim" result-params))
 result
   (condition-case nil (org-babel-script-escape result)
 (error result)
 (slime-eval
  `(swank:eval-and-grab-output
,(buffer-substring-no-properties (point-min) (point-max)))
  (cdr (assoc :package params))

Thanks,

Andrew Cheng  writes:

> I passed the question along to Phil Hagelberg in that Clojure google
> group thread. His reply:
>
> "Yes, clojure-test-mode uses both slime-eval and slime-eval-async; he
> should pick one of these like so:
>
> (defun clojure-test-eval (string &optional handler)
>  (slime-eval-async `(swank:eval-and-grab-output ,string)
>(or handler #'identity)))
>
> (defun clojure-test-eval-sync (string)
>  (slime-eval `(swank:eval-and-grab-output ,string)))
>
> Actually swank:interactive-eval-region and friends are not elisp
> functions; they are Clojure functions."
>
> (... end of reply) In case it helps, Stuart Sierra says he got
> org-babel and clojure working together. His dotfiles are at
> https://github.com/stuartsierra/dotfiles
>
> On Fri, Jan 13, 2012 at 1:09 AM, Eric Schulte  wrote:
>> I personally no longer use Clojure (having graduated to Common Lisp :))
>> so I'm not abreast of the current Clojure environment.
>>
>> The only function ob-clojure uses from swank-clojure is
>> `swank:interactive-eval-region' (used with `slime-eval') in the
>> `org-babel-execute:clojure' function.  Which function would now be used
>> to evaluate a region of clojure code?  Would `slime-eval-region'
>> suffice?
>>
>> Andrew Cheng  writes:
>>
>>> 
>>>
>>> Phil Hagelberg has said that the swank-clojure elisp package has been
>>> deprecated and should not be used [1]. My version of ob-clojure.el
>>> requires swank-clojure. If I don't have the swank-clojure package, I
>>> get "org-babel-execute:clojure:Cannot open load file: swank-clojure".
>>> If I follow the instructions at [2] and get the swank-clojure package,
>>> I get past this error. Is org using a deprecated package, and is this
>>> a bug? Thanks in advance.
>>>
>>> [1] https://groups.google.com/forum/#!starred/clojure/HT8wixvD3GE
>>> [2] http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00629.html

-- 
Eric Schulte
http://cs.unm.edu/~eschulte/



[O] How to include section in exported Latex file, but not in table of contents

2012-01-13 Thread Viktor Rosenfeld
Hi,

I would like to include an entry of my org file in the exported Latex
file, but I would like the entry to be skipped in the table of contents.

In other words, I would like to reproduce the behavior of Latex commands
like \section* and so on. Is this at all possible?

I tried EXPORT_OPTIONS: toc:nil in a property drawer below the entry,
but that didn't work out.

Thanks,
Viktor



Re: [O] Bug: ob-clojure.el depends on deprecated swank-clojure [7.7]

2012-01-13 Thread Andrew Cheng
I passed the question along to Phil Hagelberg in that Clojure google
group thread. His reply:

"Yes, clojure-test-mode uses both slime-eval and slime-eval-async; he
should pick one of these like so:

(defun clojure-test-eval (string &optional handler)
 (slime-eval-async `(swank:eval-and-grab-output ,string)
   (or handler #'identity)))

(defun clojure-test-eval-sync (string)
 (slime-eval `(swank:eval-and-grab-output ,string)))

Actually swank:interactive-eval-region and friends are not elisp
functions; they are Clojure functions."

(... end of reply) In case it helps, Stuart Sierra says he got
org-babel and clojure working together. His dotfiles are at
https://github.com/stuartsierra/dotfiles

On Fri, Jan 13, 2012 at 1:09 AM, Eric Schulte  wrote:
> I personally no longer use Clojure (having graduated to Common Lisp :))
> so I'm not abreast of the current Clojure environment.
>
> The only function ob-clojure uses from swank-clojure is
> `swank:interactive-eval-region' (used with `slime-eval') in the
> `org-babel-execute:clojure' function.  Which function would now be used
> to evaluate a region of clojure code?  Would `slime-eval-region'
> suffice?
>
> Andrew Cheng  writes:
>
>> 
>>
>> Phil Hagelberg has said that the swank-clojure elisp package has been
>> deprecated and should not be used [1]. My version of ob-clojure.el
>> requires swank-clojure. If I don't have the swank-clojure package, I
>> get "org-babel-execute:clojure:Cannot open load file: swank-clojure".
>> If I follow the instructions at [2] and get the swank-clojure package,
>> I get past this error. Is org using a deprecated package, and is this
>> a bug? Thanks in advance.
>>
>> [1] https://groups.google.com/forum/#!starred/clojure/HT8wixvD3GE
>> [2] http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00629.html



Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread John Hendy
On Fri, Jan 13, 2012 at 12:32 PM, Daniel Bausch  wrote:

> Hello!
>
> > On a usage note, I was surprised that the patch causes automatic
> insertion
> > of top and bottom rules even when the org table doesn't use ascii
> > top/bottom rules. In fact, if you use "|-" to put ascii rules on an org
> > chart using this patch, you get double rules.
>
> Disclaimer: I did not test this at all, but am interested in a convenient
> booktabs support, too.
>
> I think it is reasonable to put the top and bottom rules automatically, as
> booktabs somewhat defines that as the intended look.  So it would be
> redundant
> to require a |- on top and bottom for all tables on the org side.  I even
> think that org tables with top and bottom rules do not look good, because
> the
> vertical lines do not stop at the horizontal lines (from a visual point of
> view).  This way it looks like is a very small empty table line above and
> below the table.
>
>
I can see that point. I guess I was just surprised given the org-mode
default.

Perhaps it is just a preference with the look. I don't mind having them
"closed in" by ascii rules. In any case, what probably *shouldn't* happen
are double rules if someone by habit puts rules on their org table with |-.
That's the current behavior.


Best regards,
John


> Daniel
>
>


Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread Daniel Bausch
Hello!

> On a usage note, I was surprised that the patch causes automatic insertion
> of top and bottom rules even when the org table doesn't use ascii
> top/bottom rules. In fact, if you use "|-" to put ascii rules on an org
> chart using this patch, you get double rules.

Disclaimer: I did not test this at all, but am interested in a convenient 
booktabs support, too.

I think it is reasonable to put the top and bottom rules automatically, as 
booktabs somewhat defines that as the intended look.  So it would be redundant 
to require a |- on top and bottom for all tables on the org side.  I even 
think that org tables with top and bottom rules do not look good, because the 
vertical lines do not stop at the horizontal lines (from a visual point of 
view).  This way it looks like is a very small empty table line above and 
below the table.

Daniel



[O] Some more org-mode shirts

2012-01-13 Thread heathmatlock
I became distracted from real work last night and created some org-mode shirts:

http://open.spreadshirt.com

As an aside so people don't wrongly assume this is spam and that it's
an attempt to earn a lot of money, I earn $1 per shirt sold, and have
sold 9 shirts in 6 months (was just 6 until this was mentioned on
reddit last night). The graphic files are at
http://www.github.com/heath if you want to improve or make your own.

Cheers fellow org-mode users!

-- 
Heath Matlock
+1 256 274 4225



Re: [O] Question about repeating events.

2012-01-13 Thread Nick Dokos
Brian Wightman  wrote:

> On Thu, Jan 12, 2012 at 10:13 AM, Sam Auciello  wrote:
> > I'm trying to set up repeating events to stop repeating after a given date.
> > In this case it's classes I'm taking this semester that need to repeat once
> > a week so I enter them like:
> >
> > *** Programming Workshop
> >  <2012-01-24 Tue 13:30-14:50 +1w>, <2012-01-20 Fri 13:30-14:50 +1w>
> >
> > The agenda shows the class being scheduled each tuesday and friday but I
> > would like to tell it to stop repeating at the end of the semester.
> 
> Would diary-style datestamps work?
> 
> http://orgmode.org/manual/Timestamps.html#Timestamps
> 

Another possibility is to mark it DONE at the end of the semester and
archive the entry. That would prevent it from cluttering up anything except the
archive file.

Nick



[O] Old entry remains in appt when the original one in org file is changed

2012-01-13 Thread Takafumi Arakaki
I am using org-agenda-to-appt and I noticed a bug.


1. Add the following in the agenda file

* TODO test
  SCHEDULED: <2012-01-14 Sat 12:00>

2. Call org-agenda-to-appt

3. Change the SCHEDULED time-stamp in the entry like this

* TODO test
  SCHEDULED: <2012-01-14 Sat 12:00>

4. appt-time-msg-list has the old entry

 ((1380)
  #("12:00 TODO test" 6 15
(org-heading t))
  t)
 ((1390)
  #("12:10 TODO test" 6 15
(org-heading t))
  t)


I guess a workaround will be removing any entries which has
org-heading as property from appt-time-msg-list before adding the new
entries.

I think this guy had the same problem:
http://article.gmane.org/gmane.emacs.orgmode/8008/

--
Takafumi



Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread John Hendy
On Fri, Jan 13, 2012 at 9:39 AM, Carsten Dominik
wrote:

>
> On Jan 13, 2012, at 3:52 PM, Niels Giesen wrote:
>
> > There is a patch from me waiting to be incorporated into org mode that
> lets one use booktabs as export for normal org tables.
> >
> > You can find it @ http://patchwork.newartisans.com/patch/1016/
>
> Hi NIels,
>
> I am looking now at this patch, and maybe it would be better to implement
> these three variables as one, holding a property or association list?
>  Makes it easily extendable.
>
>
>From a pretty high-level user perspective (one who couldn't have written
that patch), I would say that from a usability point of view something like:

,---
| org-export-latex-tables-format
`---

With values of "plain/standard/default" or "booktabs" would be awesome.

That is, unless there's situations where someone would want some
combination of regular \hlines mixed with booktabs top and bottom rules?

On a usage note, I was surprised that the patch causes automatic insertion
of top and bottom rules even when the org table doesn't use ascii
top/bottom rules. In fact, if you use "|-" to put ascii rules on an org
chart using this patch, you get double rules.

Just some input from playing with the package a bit.


Thanks again,
John


> Equally important - it would be great if you could try to implement this
> same change in the new exporter engine from Nicolas, to ensure that the new
> exporter will not lag behind.
>
> Regards
>
> - Carsten
>
> >
> >
> >
> > On Fri, Jan 13, 2012 at 2:21 PM, John Hendy  wrote:
> > On Thu, Jan 12, 2012 at 6:01 PM, Thomas S. Dye  wrote:
> > Hi John,
> >
> > The Library of Babel comes with your Org-mode distribution.
> >
> > You'll find it at /contrib/babel/library-of-babel.org
> >
> >
> > I guess you learn something new every day!
> >
> > In the org file, look for
> > * Tables
> > ** LaTeX Table Export
> >
> > There should be functions booktabs and booktabs-notes.
> >
> > One way to use booktabs is described here:
> >
> > http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-13-2
> >
> >
> > I'll check these out. Looked at the worg howto. Not a huge fan of the
> method, especially with hiding my tables, but I'll give it a shot. I figure
> there's got to be a simpler way; just change the first \hline -> \toprule
> and the bottom one to \bottomrule; \midrules in between.
> >
> > Thanks again,
> > John
> >
> > hth,
> > Tom
> >
> > John Hendy  writes:
> >
> > > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  wrote:
> > >
> > >> Hi John,
> > >>
> > >> Agreed, booktabs makes good looking tables.
> > >>
> > >> Check out your Library of Babel.  There should  be a couple of
> functions
> > >> there that will help you go from Org mode to booktabs.
> > >>
> > >>
> > > Haven't done much with babel other than writing code blocks. Do you
> mean
> > > this page?
> > > --- http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
> > >
> > > Thanks for the suggestion. Feeling a bit lost, but am happy to look
> around
> > > for something that seems similar. I have no elisp-fu, so it'll need to
> be
> > > pretty darn similar :)
> > >
> > >
> > > John
> > >
> > >
> > >> hth,
> > >> Tom
> > >>
> > >> John Hendy  writes:
> > >>
> > >> > Greetings,
> > >> >
> > >> >
> > >> > I was using wikibooks for some formatting assistance on tables the
> other
> > >> > day and ran into mention of the booktabs package in the
> "Professional
> > >> > tables" section. [1] [2]
> > >> >
> > >> > I really, really liked it's formatting, especially since one of my
> column
> > >> > headers was a fraction. The standard tabular package places the
> \hlines
> > >> > extremely close to the top and bottom of my header row vs., as the
> > >> booktabs
> > >> > package says, having extremely nice looking spacing for the table. I
> > >> ended
> > >> > up doing the table manually inside #+begin_latex block.
> > >> >
> > >> > Would there be any way to specify that booktabs should be used? The
> > >> > formatting is literally identical except for 1) including the
> booktabs
> > >> > package and 2) using \toprule, \midrule and \bottomrule instead of
> > >> \hlines.
> > >> > In fact, even with booktabs included, if you use \hlines instead of
> the
> > >> > booktab specific lines, you'll get a "regular" tabular table.
> > >> >
> > >> > Any thoughts on this?
> > >> >
> > >> >
> > >> > Best regards,
> > >> > John
> > >> >
> > >> > -
> > >> > [1] http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
> > >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
> > >> > Greetings,I was using wikibooks for some formatting assistance on
> tables
> > >> the other day and ran into mention of the booktabs package in the
> > >> "Professional tables" section. [1] [2]
> > >> > I really, really liked it's formatting, especially since one of
> my
> > >> column headers was a fraction. The standard tabular package places the
> > >> \hlines extremely close to the top and bottom of my header row vs.,
> a

Re: [O] Question about repeating events.

2012-01-13 Thread Sam Auciello
Thanks, I was confused by the distinction between scheduled items and
appointments but you've cleared this up.  What I was thinking would be
cluttered was if I just used the <.. +1w> syntax and I was looking at my
agenda for next semester (when the class is over) then the agenda would be
cluttered with events that weren't meant to be there.  This link:
http://orgmode.org/worg/org-faq.html#org-class, looks to be just what I
needed.

Thanks,

Peace
~Sam

On Fri, Jan 13, 2012 at 10:32 AM, Eric S Fraga  wrote:

> Sam Auciello  writes:
>
> > I apologize in advance if this is the wrong forum for this question.
>
> Not at all; definitely the right place.  However, I would suggest you
> search the mailing list first before asking as your question has come up
> umpteen times before!  It's also answered on Worg.
>
> > I'm trying to set up repeating events to stop repeating after a given
> > date.  In this case it's classes I'm taking this semester that need to
> > repeat once a week so I enter them like:
> >
> > *** Programming Workshop
> >  <2012-01-24 Tue 13:30-14:50 +1w>, <2012-01-20 Fri 13:30-14:50 +1w>
> >
> > The agenda shows the class being scheduled each tuesday and friday but I
> > would like to tell it to stop repeating at the end of the semester.
> >
> > I didn't see anything helpful here:
> > http://orgmode.org/manual/Repeated-tasks.html#Repeated-tasks
> >
> > The options I see here are using C-c C-x c to make a bunch of duplicate
> > entries (which seems a little messy to me, but perhaps this is just how
> > it's done) or simply marking the item as DONE at the end of the semester.
> > The latter option seems a little weird to me too since it would make my
> > agenda for the following semester cluttered if I was looking at it to
> plan
> > future events.  Is there an option I'm overlooking?
> >
> > Thank you,
> >
> > Peace
> > ~Sam
>
> I do the latter (copy with time shift) and have been doing so for quite
> a while.  I find this is quite appropriate for schedules like this as it
> allows one to "miss" the odd entry (e.g. study/reading week or class
> cancelled for whatever reason).
>
> I am not sure what you mean by saying that it makes the agenda
> cluttered?  The result is the same in the agenda view: an entry for each
> day/time a class is scheduled.  I also do not understand your reference
> to marking anything done!  This is not a TODO item, it is an
> appointment.
>
> I think it's worthwhile distinguishing between appointments (which
> *have* to take place at the appointed time) and scheduled work (i.e. a
> /task/ which you intend to do at a certain time but which may end up
> being done earlier or later).  The latter is a TODO item; the former is
> not.  The latter will remain in the agenda view until it is marked done
> whereas the former only appears on the time+day indicated.
>
> I hope this makes some sort of sense...
>
> --
> : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.92.1
> : using Org-mode version 7.8.03 (release_7.8.03.122.g5b407)
>


Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread Carsten Dominik

On Jan 13, 2012, at 3:52 PM, Niels Giesen wrote:

> There is a patch from me waiting to be incorporated into org mode that lets 
> one use booktabs as export for normal org tables.
> 
> You can find it @ http://patchwork.newartisans.com/patch/1016/

Hi NIels,

I am looking now at this patch, and maybe it would be better to implement these 
three variables as one, holding a property or association list?  Makes it 
easily extendable.

Equally important - it would be great if you could try to implement this same 
change in the new exporter engine from Nicolas, to ensure that the new exporter 
will not lag behind.

Regards

- Carsten

> 
> 
> 
> On Fri, Jan 13, 2012 at 2:21 PM, John Hendy  wrote:
> On Thu, Jan 12, 2012 at 6:01 PM, Thomas S. Dye  wrote:
> Hi John,
> 
> The Library of Babel comes with your Org-mode distribution.
> 
> You'll find it at /contrib/babel/library-of-babel.org
> 
> 
> I guess you learn something new every day!
>  
> In the org file, look for
> * Tables
> ** LaTeX Table Export
> 
> There should be functions booktabs and booktabs-notes.
> 
> One way to use booktabs is described here:
> 
> http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-13-2
> 
> 
> I'll check these out. Looked at the worg howto. Not a huge fan of the method, 
> especially with hiding my tables, but I'll give it a shot. I figure there's 
> got to be a simpler way; just change the first \hline -> \toprule and the 
> bottom one to \bottomrule; \midrules in between.
> 
> Thanks again,
> John
>  
> hth,
> Tom
> 
> John Hendy  writes:
> 
> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  wrote:
> >
> >> Hi John,
> >>
> >> Agreed, booktabs makes good looking tables.
> >>
> >> Check out your Library of Babel.  There should  be a couple of functions
> >> there that will help you go from Org mode to booktabs.
> >>
> >>
> > Haven't done much with babel other than writing code blocks. Do you mean
> > this page?
> > --- http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
> >
> > Thanks for the suggestion. Feeling a bit lost, but am happy to look around
> > for something that seems similar. I have no elisp-fu, so it'll need to be
> > pretty darn similar :)
> >
> >
> > John
> >
> >
> >> hth,
> >> Tom
> >>
> >> John Hendy  writes:
> >>
> >> > Greetings,
> >> >
> >> >
> >> > I was using wikibooks for some formatting assistance on tables the other
> >> > day and ran into mention of the booktabs package in the "Professional
> >> > tables" section. [1] [2]
> >> >
> >> > I really, really liked it's formatting, especially since one of my column
> >> > headers was a fraction. The standard tabular package places the \hlines
> >> > extremely close to the top and bottom of my header row vs., as the
> >> booktabs
> >> > package says, having extremely nice looking spacing for the table. I
> >> ended
> >> > up doing the table manually inside #+begin_latex block.
> >> >
> >> > Would there be any way to specify that booktabs should be used? The
> >> > formatting is literally identical except for 1) including the booktabs
> >> > package and 2) using \toprule, \midrule and \bottomrule instead of
> >> \hlines.
> >> > In fact, even with booktabs included, if you use \hlines instead of the
> >> > booktab specific lines, you'll get a "regular" tabular table.
> >> >
> >> > Any thoughts on this?
> >> >
> >> >
> >> > Best regards,
> >> > John
> >> >
> >> > -
> >> > [1] http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
> >> > Greetings,I was using wikibooks for some formatting assistance on tables
> >> the other day and ran into mention of the booktabs package in the
> >> "Professional tables" section. [1] [2]
> >> > I really, really liked it's formatting, especially since one of my
> >> column headers was a fraction. The standard tabular package places the
> >> \hlines extremely close to the top and bottom of my header row vs., as the
> >> booktabs package says, having extremely nice looking spacing for the table.
> >> I ended up doing the table manually inside #+begin_latex block.
> >> > Would there be any way to specify that booktabs should be used? The
> >> formatting is literally identical except for 1) including the booktabs
> >> package and 2) using \toprule, \midrule and \bottomrule instead of \hlines.
> >> In fact, even with booktabs included, if you use \hlines instead of the
> >> booktab specific lines, you'll get a "regular" tabular table.
> >> > Any thoughts on this?Best regards,John-[1]
> >> http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
> >>
> >> --
> >> Thomas S. Dye
> >> http://www.tsdye.com
> >>
> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  > dir="ltr"> wrote:
> > Hi John,
> >
> > Agreed, booktabs makes good looking tables.
> >
> > Check out your Library of Babel.  There should  be a couple of functions
> 

Re: [O] funny problem for table of contents when publishing org-latex with #+INCLUDE other.org

2012-01-13 Thread tg
On Sat, 12 Nov 2011 15:28:25 -0500, jack song wrote:
> I got a funny (or strange) problem when I published to latex with #+INCLUDE
> other org file
> 
> problem: if there is no any * first line in the index.org file before the
> #+INCLUDE otherfile.org, there will be no table of contents. Other wise it
> works.

This bug also occured to me, I could reproduce it with the following files
using org-mode 7.7 and 7.8.03:

test.org:
--
#+TITLE: Test
#+AUTHOR: Foo Bar

start

#+INCLUDE inc.org

end
--

inc.org:
--
inc

* Foo

bar
--

The relevant part of the exported latex document is:

--
\begin{document}

\maketitle

\setcounter{tocdepth}{3}
\tableofcontents
\vspace*{1cm}
\section{Foo}
\label{sec-1}


bar

\end{document}
--

Everything is removed between the start of the document and the first section
of the included file.

A workaround is to add a non-exported section to the main file:

test2.org:
--
#+TITLE: Test
#+AUTHOR: Foo Bar

start

* :NOEXPORT:

#+INCLUDE inc.org

end
--

In this case the latex export looks like:

test2.tex:
--
\begin{document}

\maketitle

\setcounter{tocdepth}{3}
\tableofcontents
\vspace*{1cm}

start

\section{Foo}
\label{sec-1}


bar


end

\end{document}
--

This workaround is not perfect, though, the part before the first section
in the included file is still missing.

> a, No table of contents in latex file, IF index.org is below,

The table of contents remained in the exported document in all cases for me.

-- 
tg



Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread John Hendy
On Fri, Jan 13, 2012 at 8:52 AM, Niels Giesen wrote:

> There is a patch from me waiting to be incorporated into org mode that
> lets one use booktabs as export for normal org tables.
>
> You can find it @ http://patchwork.newartisans.com/patch/1016/
>
>
Brilliant! This is fantastic. I love that you can leave it alone (default)
or choose to change the variables.

Thanks so much for chiming in.


John



>
> On Fri, Jan 13, 2012 at 2:21 PM, John Hendy  wrote:
>
>> On Thu, Jan 12, 2012 at 6:01 PM, Thomas S. Dye  wrote:
>>
>>> Hi John,
>>>
>>> The Library of Babel comes with your Org-mode distribution.
>>>
>>> You'll find it at /contrib/babel/library-of-babel.org
>>>
>>>
>> I guess you learn something new every day!
>>
>>
>>> In the org file, look for
>>> * Tables
>>> ** LaTeX Table Export
>>>
>>> There should be functions booktabs and booktabs-notes.
>>>
>>> One way to use booktabs is described here:
>>>
>>> http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-13-2
>>>
>>>
>> I'll check these out. Looked at the worg howto. Not a huge fan of the
>> method, especially with hiding my tables, but I'll give it a shot. I figure
>> there's got to be a simpler way; just change the first \hline -> \toprule
>> and the bottom one to \bottomrule; \midrules in between.
>>
>> Thanks again,
>> John
>>
>>
>>> hth,
>>> Tom
>>>
>>> John Hendy  writes:
>>>
>>> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  wrote:
>>> >
>>> >> Hi John,
>>> >>
>>> >> Agreed, booktabs makes good looking tables.
>>> >>
>>> >> Check out your Library of Babel.  There should  be a couple of
>>> functions
>>> >> there that will help you go from Org mode to booktabs.
>>> >>
>>> >>
>>> > Haven't done much with babel other than writing code blocks. Do you
>>> mean
>>> > this page?
>>> > --- http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
>>> >
>>> > Thanks for the suggestion. Feeling a bit lost, but am happy to look
>>> around
>>> > for something that seems similar. I have no elisp-fu, so it'll need to
>>> be
>>> > pretty darn similar :)
>>> >
>>> >
>>> > John
>>> >
>>> >
>>> >> hth,
>>> >> Tom
>>> >>
>>> >> John Hendy  writes:
>>> >>
>>> >> > Greetings,
>>> >> >
>>> >> >
>>> >> > I was using wikibooks for some formatting assistance on tables the
>>> other
>>> >> > day and ran into mention of the booktabs package in the
>>> "Professional
>>> >> > tables" section. [1] [2]
>>> >> >
>>> >> > I really, really liked it's formatting, especially since one of my
>>> column
>>> >> > headers was a fraction. The standard tabular package places the
>>> \hlines
>>> >> > extremely close to the top and bottom of my header row vs., as the
>>> >> booktabs
>>> >> > package says, having extremely nice looking spacing for the table. I
>>> >> ended
>>> >> > up doing the table manually inside #+begin_latex block.
>>> >> >
>>> >> > Would there be any way to specify that booktabs should be used? The
>>> >> > formatting is literally identical except for 1) including the
>>> booktabs
>>> >> > package and 2) using \toprule, \midrule and \bottomrule instead of
>>> >> \hlines.
>>> >> > In fact, even with booktabs included, if you use \hlines instead of
>>> the
>>> >> > booktab specific lines, you'll get a "regular" tabular table.
>>> >> >
>>> >> > Any thoughts on this?
>>> >> >
>>> >> >
>>> >> > Best regards,
>>> >> > John
>>> >> >
>>> >> > -
>>> >> > [1] http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
>>> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
>>> >> > Greetings,I was using wikibooks for some formatting assistance on
>>> tables
>>> >> the other day and ran into mention of the booktabs package in the
>>> >> "Professional tables" section. [1] [2]
>>> >> > I really, really liked it's formatting, especially since one of
>>> my
>>> >> column headers was a fraction. The standard tabular package places the
>>> >> \hlines extremely close to the top and bottom of my header row vs.,
>>> as the
>>> >> booktabs package says, having extremely nice looking spacing for the
>>> table.
>>> >> I ended up doing the table manually inside #+begin_latex block.
>>> >> > Would there be any way to specify that booktabs should be used? The
>>> >> formatting is literally identical except for 1) including the booktabs
>>> >> package and 2) using \toprule, \midrule and \bottomrule instead of
>>> \hlines.
>>> >> In fact, even with booktabs included, if you use \hlines instead of
>>> the
>>> >> booktab specific lines, you'll get a "regular" tabular table.
>>> >> > Any thoughts on this?Best regards,John-[1]
>>> >> http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
>>> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
>>> >>
>>> >> --
>>> >> Thomas S. Dye
>>> >> http://www.tsdye.com
>>> >>
>>> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye >> t...@tsdye.com> wrote:
>>> > Hi John,
>>> >
>>> > Agreed, booktabs makes good looking tables.
>>> >
>>> > Check out your Library of Babel.  There should  be

Re: [O] Question about repeating events.

2012-01-13 Thread Eric S Fraga
Sam Auciello  writes:

> I apologize in advance if this is the wrong forum for this question.

Not at all; definitely the right place.  However, I would suggest you
search the mailing list first before asking as your question has come up
umpteen times before!  It's also answered on Worg.

> I'm trying to set up repeating events to stop repeating after a given
> date.  In this case it's classes I'm taking this semester that need to
> repeat once a week so I enter them like:
>
> *** Programming Workshop
>  <2012-01-24 Tue 13:30-14:50 +1w>, <2012-01-20 Fri 13:30-14:50 +1w>
>
> The agenda shows the class being scheduled each tuesday and friday but I
> would like to tell it to stop repeating at the end of the semester.
>
> I didn't see anything helpful here:
> http://orgmode.org/manual/Repeated-tasks.html#Repeated-tasks
>
> The options I see here are using C-c C-x c to make a bunch of duplicate
> entries (which seems a little messy to me, but perhaps this is just how
> it's done) or simply marking the item as DONE at the end of the semester.
> The latter option seems a little weird to me too since it would make my
> agenda for the following semester cluttered if I was looking at it to plan
> future events.  Is there an option I'm overlooking?
>
> Thank you,
>
> Peace
> ~Sam

I do the latter (copy with time shift) and have been doing so for quite
a while.  I find this is quite appropriate for schedules like this as it
allows one to "miss" the odd entry (e.g. study/reading week or class
cancelled for whatever reason).

I am not sure what you mean by saying that it makes the agenda
cluttered?  The result is the same in the agenda view: an entry for each
day/time a class is scheduled.  I also do not understand your reference
to marking anything done!  This is not a TODO item, it is an
appointment.

I think it's worthwhile distinguishing between appointments (which
*have* to take place at the appointed time) and scheduled work (i.e. a
/task/ which you intend to do at a certain time but which may end up
being done earlier or later).  The latter is a TODO item; the former is
not.  The latter will remain in the agenda view until it is marked done
whereas the former only appears on the time+day indicated.

I hope this makes some sort of sense...

-- 
: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.92.1
: using Org-mode version 7.8.03 (release_7.8.03.122.g5b407)



Re: [O] Question about repeating events.

2012-01-13 Thread Brian Wightman
On Thu, Jan 12, 2012 at 10:13 AM, Sam Auciello  wrote:
> I'm trying to set up repeating events to stop repeating after a given date.
> In this case it's classes I'm taking this semester that need to repeat once
> a week so I enter them like:
>
> *** Programming Workshop
>  <2012-01-24 Tue 13:30-14:50 +1w>, <2012-01-20 Fri 13:30-14:50 +1w>
>
> The agenda shows the class being scheduled each tuesday and friday but I
> would like to tell it to stop repeating at the end of the semester.

Would diary-style datestamps work?

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

Brian



Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread Niels Giesen
There is a patch from me waiting to be incorporated into org mode that lets
one use booktabs as export for normal org tables.

You can find it @ http://patchwork.newartisans.com/patch/1016/



On Fri, Jan 13, 2012 at 2:21 PM, John Hendy  wrote:

> On Thu, Jan 12, 2012 at 6:01 PM, Thomas S. Dye  wrote:
>
>> Hi John,
>>
>> The Library of Babel comes with your Org-mode distribution.
>>
>> You'll find it at /contrib/babel/library-of-babel.org
>>
>>
> I guess you learn something new every day!
>
>
>> In the org file, look for
>> * Tables
>> ** LaTeX Table Export
>>
>> There should be functions booktabs and booktabs-notes.
>>
>> One way to use booktabs is described here:
>>
>> http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-13-2
>>
>>
> I'll check these out. Looked at the worg howto. Not a huge fan of the
> method, especially with hiding my tables, but I'll give it a shot. I figure
> there's got to be a simpler way; just change the first \hline -> \toprule
> and the bottom one to \bottomrule; \midrules in between.
>
> Thanks again,
> John
>
>
>> hth,
>> Tom
>>
>> John Hendy  writes:
>>
>> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  wrote:
>> >
>> >> Hi John,
>> >>
>> >> Agreed, booktabs makes good looking tables.
>> >>
>> >> Check out your Library of Babel.  There should  be a couple of
>> functions
>> >> there that will help you go from Org mode to booktabs.
>> >>
>> >>
>> > Haven't done much with babel other than writing code blocks. Do you mean
>> > this page?
>> > --- http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
>> >
>> > Thanks for the suggestion. Feeling a bit lost, but am happy to look
>> around
>> > for something that seems similar. I have no elisp-fu, so it'll need to
>> be
>> > pretty darn similar :)
>> >
>> >
>> > John
>> >
>> >
>> >> hth,
>> >> Tom
>> >>
>> >> John Hendy  writes:
>> >>
>> >> > Greetings,
>> >> >
>> >> >
>> >> > I was using wikibooks for some formatting assistance on tables the
>> other
>> >> > day and ran into mention of the booktabs package in the "Professional
>> >> > tables" section. [1] [2]
>> >> >
>> >> > I really, really liked it's formatting, especially since one of my
>> column
>> >> > headers was a fraction. The standard tabular package places the
>> \hlines
>> >> > extremely close to the top and bottom of my header row vs., as the
>> >> booktabs
>> >> > package says, having extremely nice looking spacing for the table. I
>> >> ended
>> >> > up doing the table manually inside #+begin_latex block.
>> >> >
>> >> > Would there be any way to specify that booktabs should be used? The
>> >> > formatting is literally identical except for 1) including the
>> booktabs
>> >> > package and 2) using \toprule, \midrule and \bottomrule instead of
>> >> \hlines.
>> >> > In fact, even with booktabs included, if you use \hlines instead of
>> the
>> >> > booktab specific lines, you'll get a "regular" tabular table.
>> >> >
>> >> > Any thoughts on this?
>> >> >
>> >> >
>> >> > Best regards,
>> >> > John
>> >> >
>> >> > -
>> >> > [1] http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
>> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
>> >> > Greetings,I was using wikibooks for some formatting assistance on
>> tables
>> >> the other day and ran into mention of the booktabs package in the
>> >> "Professional tables" section. [1] [2]
>> >> > I really, really liked it's formatting, especially since one of
>> my
>> >> column headers was a fraction. The standard tabular package places the
>> >> \hlines extremely close to the top and bottom of my header row vs., as
>> the
>> >> booktabs package says, having extremely nice looking spacing for the
>> table.
>> >> I ended up doing the table manually inside #+begin_latex block.
>> >> > Would there be any way to specify that booktabs should be used? The
>> >> formatting is literally identical except for 1) including the booktabs
>> >> package and 2) using \toprule, \midrule and \bottomrule instead of
>> \hlines.
>> >> In fact, even with booktabs included, if you use \hlines instead of the
>> >> booktab specific lines, you'll get a "regular" tabular table.
>> >> > Any thoughts on this?Best regards,John-[1]
>> >> http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
>> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
>> >>
>> >> --
>> >> Thomas S. Dye
>> >> http://www.tsdye.com
>> >>
>> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye > t...@tsdye.com> wrote:
>> > Hi John,
>> >
>> > Agreed, booktabs makes good looking tables.
>> >
>> > Check out your Library of Babel.  There should  be a couple of functions
>> > there that will help you go from Org mode to booktabs.
>> > Haven't done much with babel other than writing code blocks. Do you
>> mean this page?---
>> http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
>> > Thanks for the suggestion. Feeling a bit lost, but am happy to look
>> around for something that seems similar. I hav

[O] [bug] org-columns for read only buffer (was Re: Bug: exporting ical files from read-only buffers [7.8.03 (release_7.8.03.112.g8861)])

2012-01-13 Thread Eric S Fraga
Stephen Eglen  writes:

> I've found a small bug with exporting ical files from read-only org
> buffers.  Create a simple buffer, e.g.:
>
> * test1
>   <2012-01-12 Thu>
>
> and then hit C-x C-q to make the buffer read-only.  Then do C-c C-e i
> to export an ical file.  You get an error that the buffer is read-only.
>
> I think this is due to the call to org-refresh-category-properties,
> which can't update text proprties.  
>
> My workaround is to do:
> (setq inhibit-read-only nil)
>
> so that text properties can be added to read-only buffers.  This could
> be done locally within the ical export functions if others thought
> sensible, for which I can send a patch if desired.
>
> Stephen

I have just run into another case where text properties and/or overlays
clash with a read-only file: column view (M-x org-columns, C-c C-x
C-c).  In a read-only file, I get the error

   org-columns-compute-all: Buffer is read-only: #

If I make the file writable, org-columns works but, of course, does not
actually modify the file.

Thanks,
eric
-- 
: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.92.1
: using Org-mode version 7.8.03 (release_7.8.03.122.g5b407)



Re: [O] Way to replace normal tabular env with booktabs?

2012-01-13 Thread John Hendy
On Thu, Jan 12, 2012 at 6:01 PM, Thomas S. Dye  wrote:

> Hi John,
>
> The Library of Babel comes with your Org-mode distribution.
>
> You'll find it at /contrib/babel/library-of-babel.org
>
>
I guess you learn something new every day!


> In the org file, look for
> * Tables
> ** LaTeX Table Export
>
> There should be functions booktabs and booktabs-notes.
>
> One way to use booktabs is described here:
>
> http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-13-2
>
>
I'll check these out. Looked at the worg howto. Not a huge fan of the
method, especially with hiding my tables, but I'll give it a shot. I figure
there's got to be a simpler way; just change the first \hline -> \toprule
and the bottom one to \bottomrule; \midrules in between.

Thanks again,
John


> hth,
> Tom
>
> John Hendy  writes:
>
> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  wrote:
> >
> >> Hi John,
> >>
> >> Agreed, booktabs makes good looking tables.
> >>
> >> Check out your Library of Babel.  There should  be a couple of functions
> >> there that will help you go from Org mode to booktabs.
> >>
> >>
> > Haven't done much with babel other than writing code blocks. Do you mean
> > this page?
> > --- http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
> >
> > Thanks for the suggestion. Feeling a bit lost, but am happy to look
> around
> > for something that seems similar. I have no elisp-fu, so it'll need to be
> > pretty darn similar :)
> >
> >
> > John
> >
> >
> >> hth,
> >> Tom
> >>
> >> John Hendy  writes:
> >>
> >> > Greetings,
> >> >
> >> >
> >> > I was using wikibooks for some formatting assistance on tables the
> other
> >> > day and ran into mention of the booktabs package in the "Professional
> >> > tables" section. [1] [2]
> >> >
> >> > I really, really liked it's formatting, especially since one of my
> column
> >> > headers was a fraction. The standard tabular package places the
> \hlines
> >> > extremely close to the top and bottom of my header row vs., as the
> >> booktabs
> >> > package says, having extremely nice looking spacing for the table. I
> >> ended
> >> > up doing the table manually inside #+begin_latex block.
> >> >
> >> > Would there be any way to specify that booktabs should be used? The
> >> > formatting is literally identical except for 1) including the booktabs
> >> > package and 2) using \toprule, \midrule and \bottomrule instead of
> >> \hlines.
> >> > In fact, even with booktabs included, if you use \hlines instead of
> the
> >> > booktab specific lines, you'll get a "regular" tabular table.
> >> >
> >> > Any thoughts on this?
> >> >
> >> >
> >> > Best regards,
> >> > John
> >> >
> >> > -
> >> > [1] http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
> >> > Greetings,I was using wikibooks for some formatting assistance on
> tables
> >> the other day and ran into mention of the booktabs package in the
> >> "Professional tables" section. [1] [2]
> >> > I really, really liked it's formatting, especially since one of my
> >> column headers was a fraction. The standard tabular package places the
> >> \hlines extremely close to the top and bottom of my header row vs., as
> the
> >> booktabs package says, having extremely nice looking spacing for the
> table.
> >> I ended up doing the table manually inside #+begin_latex block.
> >> > Would there be any way to specify that booktabs should be used? The
> >> formatting is literally identical except for 1) including the booktabs
> >> package and 2) using \toprule, \midrule and \bottomrule instead of
> \hlines.
> >> In fact, even with booktabs included, if you use \hlines instead of the
> >> booktab specific lines, you'll get a "regular" tabular table.
> >> > Any thoughts on this?Best regards,John-[1]
> >> http://en.wikibooks.org/wiki/LaTeX/Tables#Professional_tables
> >> > [2] http://www.ctan.org/tex-archive/macros/latex/contrib/booktabs/
> >>
> >> --
> >> Thomas S. Dye
> >> http://www.tsdye.com
> >>
> > On Thu, Jan 12, 2012 at 2:12 PM, Thomas S. Dye  t...@tsdye.com> wrote:
> > Hi John,
> >
> > Agreed, booktabs makes good looking tables.
> >
> > Check out your Library of Babel.  There should  be a couple of functions
> > there that will help you go from Org mode to booktabs.
> > Haven't done much with babel other than writing code blocks. Do you
> mean this page?---
> http://orgmode.org/worg/org-contrib/babel/library-of-babel.html
> > Thanks for the suggestion. Feeling a bit lost, but am happy to look
> around for something that seems similar. I have no elisp-fu, so it'll
> need to be pretty darn similar :)
> > John
> > hth,
> > Tom
> >
> > John Hendy  writes:
> >
> >> Greetings,
> >>
> >>
> >> I was using wikibooks for some formatting assistance on tables the other
> >> day and ran into mention of the booktabs package in the "Professional
> >> tables" section. [1] [2]
> >>
> >> I really, really liked it's formatting, 

Re: [O] Writing an new org entry to a .gpg file - ends up in .org file instead

2012-01-13 Thread Richard Riley
Eric S Fraga  writes:

> Richard Riley  writes:
>
>> Eric S Fraga  writes:
>>
>>>
>>> I don't know if this may help but I do something similar.  In my case,
>>> my file is named "secure.org.gpg".  Maybe try "journal.org.gpg" in your
>>> case, i.e. add the ".org" element?
>>
>> Hi Eric,
>>
>> I tried this and its still creating and writing out to journal.org.
>>
>> (org-mode with emacs 24 snapshot)
>>
>> regards
>>
>> r.
>
> Interesting.  It must have something to do with the extra settings you
> have for that template.  My template is:
>
> ("s" "secure" entry (file+datetree+prompt "~/git/notes/secure.org.gpg")
>  "* %(format-time-string \"%H:%M\") %^{Entry} %^G\n%i%?")
>
> I have just tested it (hadn't added a secure entry in a while) and it
> works just fine.  This is with emacs snapshot (most recent) and org from
> last night my time (see signature for version).
>
> Maybe try without the PROPERTY etc. bits you have in your template?

thanks for that example, that worked... no idea why. Anyone? (I hate
prompts for tags etc ;)




Re: [O] [bug] Tables in lists not exported to ODT

2012-01-13 Thread Eric S Fraga
Eric S Fraga  writes:

> Hello,
>
> I am trying to export a document which includes small tables within a
> list.  The export to PDF via Latex works perfectly.  However, when I
> export to ODT, the tables simply disappear.
>
> Attached is a simple example to illustrate the effect, both org and odt
> files.
>
> I have looked at the documentation but have not seen any caveat related
> to tables.  Have I missed something or is this a bug?
>
> Thanks,
> eric

Pursuing this, to the un-trained eye (mine), the ODT code being
generated looks fine so maybe this is a libreoffice bug?

However, when looking at content.xml, the "

Re: [O] Writing an new org entry to a .gpg file - ends up in .org file instead

2012-01-13 Thread Eric S Fraga
Richard Riley  writes:

> Eric S Fraga  writes:
>
>>
>> I don't know if this may help but I do something similar.  In my case,
>> my file is named "secure.org.gpg".  Maybe try "journal.org.gpg" in your
>> case, i.e. add the ".org" element?
>
> Hi Eric,
>
> I tried this and its still creating and writing out to journal.org.
>
> (org-mode with emacs 24 snapshot)
>
> regards
>
> r.

Interesting.  It must have something to do with the extra settings you
have for that template.  My template is:

("s" "secure" entry (file+datetree+prompt "~/git/notes/secure.org.gpg")
 "* %(format-time-string \"%H:%M\") %^{Entry} %^G\n%i%?")

I have just tested it (hadn't added a secure entry in a while) and it
works just fine.  This is with emacs snapshot (most recent) and org from
last night my time (see signature for version).

Maybe try without the PROPERTY etc. bits you have in your template?
-- 
: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.92.1
: using Org-mode version 7.8.03 (release_7.8.03.122.g5b407)



Re: [O] Writing an new org entry to a .gpg file - ends up in .org file instead

2012-01-13 Thread Richard Riley
Eric S Fraga  writes:

>
> I don't know if this may help but I do something similar.  In my case,
> my file is named "secure.org.gpg".  Maybe try "journal.org.gpg" in your
> case, i.e. add the ".org" element?

Hi Eric,

I tried this and its still creating and writing out to journal.org.

(org-mode with emacs 24 snapshot)

regards

r.


-- 
☘ http://www.richardriley.net




Re: [O] Writing an new org entry to a .gpg file - ends up in .org file instead

2012-01-13 Thread Eric S Fraga
Richard Riley  writes:

> I have an org template set up like this and frequently use the journal
> option

[...]

> |   ("j" "Journal" entry
> |(file+datetree "journal.gpg")
> |"* %?\n\t:PROPERTIES:\n\t:DateCreated: 
> %T\n\t:END:\n%i\n%a")

[...]

>
> Notice the journal.gpg which has a first line :
>
> ,
> | ;;-*- mode:org -*- epa-file-encrypt-to: ("rile...@gmail.com") -*-
> `
>
> so I can open the file in org mode just fine.
>
> So far so good, but when I C-c C-c the new journal item its being
> written to journal.org instead of journal.gpg.
>
> I'm guessing I missed something in my browse of the manual, but what?
>
> cheers
> r.

I don't know if this may help but I do something similar.  In my case,
my file is named "secure.org.gpg".  Maybe try "journal.org.gpg" in your
case, i.e. add the ".org" element?

-- 
: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.92.1
: using Org-mode version 7.8.03 (release_7.8.03.122.g5b407)



[O] [bug] Tables in lists not exported to ODT

2012-01-13 Thread Eric S Fraga
Hello,

I am trying to export a document which includes small tables within a
list.  The export to PDF via Latex works perfectly.  However, when I
export to ODT, the tables simply disappear.

Attached is a simple example to illustrate the effect, both org and odt
files.

I have looked at the documentation but have not seen any caveat related
to tables.  Have I missed something or is this a bug?

Thanks,
eric

-- 
Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D)


examplebug.odt
Description: application/vnd.oasis.opendocument.text
#+TITLE: examplebug.org
#+AUTHOR:Eric S Fraga
#+EMAIL: e.fr...@ucl.ac.uk
#+DATE:  2012-01-09 Mon

* tables in lists

  - This a very simple list
  - The second entry has a table

| time | temperature |
|--+-|
|0 | 100 |
|1 | 80. |
|2 | 64. |
#+TBLFM: @3$2=0.8*@-1::@4$2=0.8*@-1
  - The third one does not.


[O] Writing an new org entry to a .gpg file - ends up in .org file instead

2012-01-13 Thread Richard Riley

I have an org template set up like this and frequently use the journal
option


,
| (setq org-capture-templates '(("t" "Todo" entry
|  (file+headline "" "Tasks To Refile")
|  "* TODO %?\n\t:PROPERTIES:\n\t:DateCreated: 
%T\n\t:END:\n%i\n%a")
| ("c" "Contacts" entry (file "~/Org/contacts.org")
|  "* %(org-contacts-template-name)
| :PROPERTIES:
| :EMAIL: %(org-contacts-template-email)
| :END:")
| ("j" "Journal" entry
|  (file+datetree "journal.gpg")
|  "* %?\n\t:PROPERTIES:\n\t:DateCreated: 
%T\n\t:END:\n%i\n%a")
| ("n" "Quick note to refile later" entry
|  (file+headline "" "Notes To Refile")
|  "* %?\n\t:PROPERTIES:\n\t:DateCreated: 
%T\n\t:END:\n%i\n%a")
| ("w" "web capture" entry
|  (file "refile.org")
|  "* %a %?\n\t:PROPERTIES:\n\t:DateCreated: 
%T\n\t:END:n%i")))
`

Notice the journal.gpg which has a first line :

,
| ;;-*- mode:org -*- epa-file-encrypt-to: ("rile...@gmail.com") -*-
`

so I can open the file in org mode just fine.

So far so good, but when I C-c C-c the new journal item its being
written to journal.org instead of journal.gpg.

I'm guessing I missed something in my browse of the manual, but what?

cheers
r.




Re: [O] Help with elisp function

2012-01-13 Thread Olaf Dietsche
Marcelo de Moraes Serpa  writes:

> So, I made a small elisp function that basically creates a "reference
> file" in my org dir and indexes it in an org file, so it can be
> searchable with the agenda without the overhead of adding the file to
> the agenda list:
>
> (defun create-reference-file (filename title tags) "Creates a new
> reference and file it"
>   (interactive (list
> (read-string "Filename: ") (read-string "Title: ")
> (read-string "Tags: ") ))
>   (set-buffer (get-buffer-create filename)) (beginning-of-buffer)
>   (insert (concat "* tags " tags))
>;;saves the buffer (when (file-writable-p filename)
>   (write-region (point-min) (point-max) (concat
> "~/org/data/dynamic_reference/" filename ".org")))
>   (set-buffer (find-file-noselect "~/org/gtd/reference.org"))
>   (end-of-buffer) ;;(create-wiki-page filename) (insert (concat "** "
>   title " " tags ":reference:file:\n")) (org-insert-time-stamp nil t
>   nil) (insert "\n") (insert (concat
>   "[[file://~/org/data/dynamic_reference/" filename
> ".org]]"))
>   (insert "\n") (save-buffer) )
>
> I'm only beginning with elisp, so bear with me...
>
> Anyway, it works as expected, but I would like the tags prompt to be
> like the prompt org uses, with tags auto-completion and adding the : :
> automatically around the tags. Right now, I have to type the : around
> the words.

C-h c C-c C-q runs the command org-set-tags-command.
org-set-tags-command calls org-set-tags. Looking through org-set-tags in
org.el, there's a part starting with a comment:

;; Get a new set of tags from the user
...
  (let ((org-add-colon-after-tag-completion t))
(org-trim
 (org-icompleting-read "Tags: "
   'org-tags-completion-function
   nil nil current 
'org-tags-history))
...

So, I guess org-icompleting-read is, what you are looking for.

Regards, Olaf