[O] Emacs with Org 8?

2014-07-17 Thread SabreWolfy
The latest stable release of Emacs is 24.3.1, which does not contain Org
version 8? Therefore, using Org 8 requires (manual) installation? I am using
a modified version of Emacs on Mac, with ESS and other packages
pre-installed. This version has Org 7.9.3 though :(




[O] input date/time properties

2014-07-17 Thread Eike Kettner

Dear List,

I've discovered orgmode only several weeks ago and this was a great
day. So this is my first post and I want to thank you all making this
free software!

Now I have several org files and I sometimes want to attach date or
datetime properties to a headline. So I type C-c C-x p and answer the
minibuffer. For a date/time value I'd like to use the nice input method
(I think provided by `org-read-date') but I cannot figure out how to
enable it when adding properties this way. Is this possible or should I
add the PROPERTIES drawer first and then use C-c ! to add date value?

Also, how can I instruct org to update the date value of a property?
(If I hit C-c C-c inside the property drawer the property action menu
appears.)

kind regards
Eike



Re: [O] Emacs with Org 8?

2014-07-17 Thread Nicolas Richard
SabreWolfy  writes:

> The latest stable release of Emacs is 24.3.1, which does not contain Org
> version 8? Therefore, using Org 8 requires (manual) installation? I am using
> a modified version of Emacs on Mac, with ESS and other packages
> pre-installed. This version has Org 7.9.3 though :(


This is because Emacs 24.3.1 was released before Org 8 was released. Org
8 will ship with the next release, Emacs 24.4. Alternatively you can
update to Org 8 via elpa. (M-x list-packages).

Regards,

-- 
Nicolas.



Re: [O] input date/time properties

2014-07-17 Thread Thorsten Jolitz
Eike Kettner  writes:

> Now I have several org files and I sometimes want to attach date or
> datetime properties to a headline. So I type C-c C-x p and answer the
> minibuffer. For a date/time value I'd like to use the nice input method
> (I think provided by `org-read-date') but I cannot figure out how to
> enable it when adding properties this way. Is this possible or should I
> add the PROPERTIES drawer first and then use C-c ! to add date value?

It works for me over here:

,
| C-c C-x p mydate RET C-c !
`

and calendar window opens ...

PS 

Org-mode version beta_8.3 (beta_8.3-21-g815c21 @
/usr/share/emacs/24.3/lisp/org/lisp/)

-- 
cheers,
Thorsten




[O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Xebar Saram
hi all

i keep once and a while screwing up my notes with unintended editing
(erroneous key presses etc) and was wondering if any one knew of a way
to to switch orgmode notes between read-only/editing? i have used such
options in previous note taking apps that had that option build in but i
understand that since orgmode notes are just text files its a bit more
complicated

i would love to hear any suggestions on how you guys deal with protecting
notes/data that still needs to be edited (i do use git ofc but i dont
always know i screwed my notes :))

best

Z.


Re: [O] input date/time properties

2014-07-17 Thread Eike Kettner

Aahhh.. I knew I'm missing something obvious. I just wasn't brave enough
to simply try those key strokes from within the minibuffer... silly
me. It also works here, of course.

Thank you

Eike

Thorsten Jolitz writes:

> Eike Kettner  writes:
>
>> Now I have several org files and I sometimes want to attach date or
>> datetime properties to a headline. So I type C-c C-x p and answer the
>> minibuffer. For a date/time value I'd like to use the nice input method
>> (I think provided by `org-read-date') but I cannot figure out how to
>> enable it when adding properties this way. Is this possible or should I
>> add the PROPERTIES drawer first and then use C-c ! to add date value?
>
> It works for me over here:
>
> ,
> | C-c C-x p mydate RET C-c !
> `
>
> and calendar window opens ...
>
> PS 
>
> Org-mode version beta_8.3 (beta_8.3-21-g815c21 @
> /usr/share/emacs/24.3/lisp/org/lisp/)



Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Thorsten Jolitz
Xebar Saram  writes:

> hi all
>
> i keep once and a while screwing up my notes with unintended editing
> (erroneous key presses etc) and was wondering if any one knew of a way
> to to switch orgmode notes between read-only/editing? i have used such
> options in previous note taking apps that had that option build in but
> i understand that since orgmode notes are just text files its a bit
> more complicated
>
> i would love to hear any suggestions on how you guys deal with
> protecting notes/data that still needs to be edited (i do use git ofc
> but i dont always know i screwed my notes :))

,[ C-h f view-mode RET ]
| view-mode is an interactive autoloaded compiled Lisp function in
| `view.el'.
| 
| (view-mode &optional ARG)
| 
| Toggle View mode, a minor mode for viewing text but not editing it.
| With a prefix argument ARG, enable View mode if ARG is positive,
| and disable it otherwise.  If called from Lisp, enable View mode
| if ARG is omitted or nil.
| 
| When View mode is enabled, commands that do not change the buffer
| contents are available as usual.  Kill commands insert text in
| kill buffers but do not delete.  Most other commands beep and
| tell the user that the buffer is read-only.
| 
| 
| 
| The following additional commands are provided.  Most commands
| take prefix arguments.  Page commands default to "page size"
| lines which is almost a whole window, or number of lines set by
| z or w.
| Half page commands default to and set "half page size" lines
| which initially is half a window full.  Search commands default
| to a repeat count of one.
| 
| H, h, ?This message.
| Digitsprovide prefix arguments.
| - negative prefix argument.
| < move to the beginning of buffer.
| > move to the end of buffer.
| o scroll so that buffer end is at last line of window.
| SPC   scroll forward "page size" lines.
| With prefix scroll forward prefix lines.
| DEL   scroll backward "page size" lines.
| With prefix scroll backward prefix lines.
| z like  SPC  but with prefix sets "page size" to prefix.
| w like  DEL  but with prefix sets "page size" to prefix.
| d scroll forward "half page size" lines.  With prefix, sets
| "half page size" to prefix lines and scrolls forward that much.
| u scroll backward "half page size" lines.  With prefix, sets
| "half page size" to prefix lines and scrolls backward that much.
| RET, LFD  scroll forward one line.  With prefix scroll forward prefix line(s).
| y scroll backward one line.  With prefix scroll backward prefix line(s).
| F revert-buffer if necessary and scroll forward.
| Use this to view a changing file.
| = prints the current line number.
| % goes prefix argument (default 100) percent into buffer.
| g goes to line given by prefix argument (default first line).
| . set the mark.
| x exchanges point and mark.
| @ return to mark and pops mark ring.
| Mark ring is pushed at start of every successful search and when
| jump to line occurs.  The mark is set on jump to buffer start or end.
| m save current position in character register.
| ' go to position saved in character register.
| s do forward incremental search.
| r do reverse incremental search.
| / searches forward for regular expression, starting after current page.
| ! and @ have a special meaning at the beginning of the regexp.
| ! means search for a line with no match for regexp.  @ means start
| search at beginning (end for backward search) of buffer.
| \ searches backward for regular expression, starting before current page.
| n searches forward for last regular expression.
| p searches backward for last regular expression.
| q quit View mode, restoring this window and buffer to previous state.
| q is the normal way to leave view mode.
| e exit View mode but stay in current buffer.  Use this if you started
| viewing a buffer (file) and find out you want to edit it.
| This command restores the previous read-only status of the buffer.
| E exit View mode, and make the current buffer editable
| even if it was not editable before entry to View mode.
| Q quit View mode, restoring all windows to previous state.
| c quit View mode and maybe switch buffers, but don't kill this buffer.
| C quit View mode, kill current buffer and go back to other buffer.
| 
| The effect of c, q and C depends on how view-mode was entered.  If it was
| entered by view-file, view-file-other-window, view-file-other-frame, or
| M-x dired-view-file (M-x view-file, M-x view-file-other-window,
| M-x view-file-other-frame, or the Dired mode v command),
| then q will try to kill the current buffer.
| If view-mode was entered from another buffer, by C-c v,
| M-x view-buffer-other-window, M-x view-buffer-other frame, M-x view-file,
| M-x view-file-other-window, or M-x view-file-other-frame,
| then 

Re: [O] Problem with org-mode after upgradiing to org 8

2014-07-17 Thread Nick Dokos
Roland Everaert  writes:

> With the minimal-config, the org version is "Org-mode version 8.3beta 
> (release_8.3beta-40-g9cf3c4 @ 
> /home/reveatwork/.emacs.d/site-lisp/org-mode/lisp/)". So I have created a file
> that load only org-mode and my configuration.
>
> It begins like this:
>
> (let ((default-directory "~/.emacs.d/site-lisp/"))
>   (normal-top-level-add-to-load-path '("."))
>   (normal-top-level-add-subdirs-to-load-path))
>
> ;; Load Org-mode
> (add-to-list 'load-path "~/.emacs.d/site-lisp/org-mode/lisp")
> (add-to-list 'load-path "~/.emacs.d/site-lisp/org-mode/contrib/lisp")
> (add-to-list 'auto-mode-alist '("\\.\\(org\\|org_archive\\)$" . org-mode))
>
> The right version of org-mode is loaded, but I have an error upon starting 
> emacs. Below is the backtrace:
>
> Debugger entered--Lisp error: (void-variable org-element-block-name-alist)
>   add-to-list(org-element-block-name-alist ("HTML" . 
> org-element-export-block-parser))
>   ...
>   eval-buffer(# nil 
> "/home/reveatwork/.emacs.d/site-lisp/org-mode/lisp/ox-html.el" nil t)  ; 
> Reading at buffer position 8239
>   
> load-with-code-conversion("/home/reveatwork/.emacs.d/site-lisp/org-mode/lisp/ox-html.el"
>  "/home/reveatwork/.emacs.d/site-lisp/org-mode/lisp/ox-html.el" nil t)
>   require(ox-html)
>   eval-buffer(# nil 
> "/home/reveatwork/.emacs.d/site-lisp/my-org-mode-config.el" nil t)  ; Reading 
> at buffer position 21243
>   
> load-with-code-conversion("/home/reveatwork/.emacs.d/site-lisp/my-org-mode-config.el"
>  "/home/reveatwork/.emacs.d/site-lisp/my-org-mode-config.el" nil nil)
>   load("my-org-mode-config")
>   load-library("my-org-mode-config")
>   eval-buffer(# nil "/home/reveatwork/.emacs.d/init.el" nil 
> t)  ; Reading at buffer position 6127
>   load-with-code-conversion("/home/reveatwork/.emacs.d/init.el" 
> "/home/reveatwork/.emacs.d/init.el" t t)
>   load("/home/reveatwork/.emacs.d/init" t t)

org-element-block-name-alist is defined in org-element.el,
so you need to load that file before you can use it. Find
the place where you are setting it in your init.el and modify
it as follows:

--8<---cut here---start->8---
...
(require 'org-element)
(add-to-list 'org-element-block-name-alist
 '("HTML" . org-element-export-block-parser))
...
--8<---cut here---end--->8---

But I don't think you need to modify it at all: I start with a
minimal init file, do a (require 'ox-html) and
org-element-block-name-alist already contains the HTML element above.
This is with

Org-mode version 8.3beta (release_8.3beta-40-g9cf3c4)

YMMV of course if you are using a different version: there might be
a bug that has been fixed more recently - I haven't checked.

-- 
Nick




Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Xebar Saram
Thx Thorston this looks great

can you recommend a way to open all orgmode notes in view mode by default,
i guess i would then bind a key to disable view mode to start editing right?

thanks alot again

Z


On Thu, Jul 17, 2014 at 4:13 PM, Thorsten Jolitz  wrote:

> Xebar Saram  writes:
>
> > hi all
> >
> > i keep once and a while screwing up my notes with unintended editing
> > (erroneous key presses etc) and was wondering if any one knew of a way
> > to to switch orgmode notes between read-only/editing? i have used such
> > options in previous note taking apps that had that option build in but
> > i understand that since orgmode notes are just text files its a bit
> > more complicated
> >
> > i would love to hear any suggestions on how you guys deal with
> > protecting notes/data that still needs to be edited (i do use git ofc
> > but i dont always know i screwed my notes :))
>
> ,[ C-h f view-mode RET ]
> | view-mode is an interactive autoloaded compiled Lisp function in
> | `view.el'.
> |
> | (view-mode &optional ARG)
> |
> | Toggle View mode, a minor mode for viewing text but not editing it.
> | With a prefix argument ARG, enable View mode if ARG is positive,
> | and disable it otherwise.  If called from Lisp, enable View mode
> | if ARG is omitted or nil.
> |
> | When View mode is enabled, commands that do not change the buffer
> | contents are available as usual.  Kill commands insert text in
> | kill buffers but do not delete.  Most other commands beep and
> | tell the user that the buffer is read-only.
> |
> |
> |
> | The following additional commands are provided.  Most commands
> | take prefix arguments.  Page commands default to "page size"
> | lines which is almost a whole window, or number of lines set by
> | z or w.
> | Half page commands default to and set "half page size" lines
> | which initially is half a window full.  Search commands default
> | to a repeat count of one.
> |
> | H, h, ?This message.
> | Digitsprovide prefix arguments.
> | - negative prefix argument.
> | < move to the beginning of buffer.
> | > move to the end of buffer.
> | o scroll so that buffer end is at last line of window.
> | SPC   scroll forward "page size" lines.
> | With prefix scroll forward prefix lines.
> | DEL   scroll backward "page size" lines.
> | With prefix scroll backward prefix lines.
> | z like  SPC  but with prefix sets "page size" to prefix.
> | w like  DEL  but with prefix sets "page size" to prefix.
> | d scroll forward "half page size" lines.  With prefix, sets
> | "half page size" to prefix lines and scrolls forward that much.
> | u scroll backward "half page size" lines.  With prefix, sets
> | "half page size" to prefix lines and scrolls backward that much.
> | RET, LFD  scroll forward one line.  With prefix scroll forward prefix
> line(s).
> | y scroll backward one line.  With prefix scroll backward prefix
> line(s).
> | F revert-buffer if necessary and scroll forward.
> | Use this to view a changing file.
> | = prints the current line number.
> | % goes prefix argument (default 100) percent into buffer.
> | g goes to line given by prefix argument (default first line).
> | . set the mark.
> | x exchanges point and mark.
> | @ return to mark and pops mark ring.
> | Mark ring is pushed at start of every successful search and when
> | jump to line occurs.  The mark is set on jump to buffer start or
> end.
> | m save current position in character register.
> | ' go to position saved in character register.
> | s do forward incremental search.
> | r do reverse incremental search.
> | / searches forward for regular expression, starting after current
> page.
> | ! and @ have a special meaning at the beginning of the regexp.
> | ! means search for a line with no match for regexp.  @ means
> start
> | search at beginning (end for backward search) of buffer.
> | \ searches backward for regular expression, starting before current
> page.
> | n searches forward for last regular expression.
> | p searches backward for last regular expression.
> | q quit View mode, restoring this window and buffer to previous state.
> | q is the normal way to leave view mode.
> | e exit View mode but stay in current buffer.  Use this if you started
> | viewing a buffer (file) and find out you want to edit it.
> | This command restores the previous read-only status of the
> buffer.
> | E exit View mode, and make the current buffer editable
> | even if it was not editable before entry to View mode.
> | Q quit View mode, restoring all windows to previous state.
> | c quit View mode and maybe switch buffers, but don't kill this
> buffer.
> | C quit View mode, kill current buffer and go back to other buffer.
> |
> | The effect of c, q and C depends on how view-mode was entered.  I

Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Xebar Saram
PS. Also can anyone think of a way to get a visual cue when the file is in
"view mode"?

thx!

Z


On Thu, Jul 17, 2014 at 4:22 PM, Xebar Saram  wrote:

> Thx Thorston this looks great
>
> can you recommend a way to open all orgmode notes in view mode by default,
> i guess i would then bind a key to disable view mode to start editing right?
>
> thanks alot again
>
> Z
>
>
> On Thu, Jul 17, 2014 at 4:13 PM, Thorsten Jolitz 
> wrote:
>
>> Xebar Saram  writes:
>>
>> > hi all
>> >
>> > i keep once and a while screwing up my notes with unintended editing
>> > (erroneous key presses etc) and was wondering if any one knew of a way
>> > to to switch orgmode notes between read-only/editing? i have used such
>> > options in previous note taking apps that had that option build in but
>> > i understand that since orgmode notes are just text files its a bit
>> > more complicated
>> >
>> > i would love to hear any suggestions on how you guys deal with
>> > protecting notes/data that still needs to be edited (i do use git ofc
>> > but i dont always know i screwed my notes :))
>>
>> ,[ C-h f view-mode RET ]
>> | view-mode is an interactive autoloaded compiled Lisp function in
>> | `view.el'.
>> |
>> | (view-mode &optional ARG)
>> |
>> | Toggle View mode, a minor mode for viewing text but not editing it.
>> | With a prefix argument ARG, enable View mode if ARG is positive,
>> | and disable it otherwise.  If called from Lisp, enable View mode
>> | if ARG is omitted or nil.
>> |
>> | When View mode is enabled, commands that do not change the buffer
>> | contents are available as usual.  Kill commands insert text in
>> | kill buffers but do not delete.  Most other commands beep and
>> | tell the user that the buffer is read-only.
>> |
>> |
>> |
>> | The following additional commands are provided.  Most commands
>> | take prefix arguments.  Page commands default to "page size"
>> | lines which is almost a whole window, or number of lines set by
>> | z or w.
>> | Half page commands default to and set "half page size" lines
>> | which initially is half a window full.  Search commands default
>> | to a repeat count of one.
>> |
>> | H, h, ?This message.
>> | Digitsprovide prefix arguments.
>> | - negative prefix argument.
>> | < move to the beginning of buffer.
>> | > move to the end of buffer.
>> | o scroll so that buffer end is at last line of window.
>> | SPC   scroll forward "page size" lines.
>> | With prefix scroll forward prefix lines.
>> | DEL   scroll backward "page size" lines.
>> | With prefix scroll backward prefix lines.
>> | z like  SPC  but with prefix sets "page size" to prefix.
>> | w like  DEL  but with prefix sets "page size" to prefix.
>> | d scroll forward "half page size" lines.  With prefix, sets
>> | "half page size" to prefix lines and scrolls forward that much.
>> | u scroll backward "half page size" lines.  With prefix, sets
>> | "half page size" to prefix lines and scrolls backward that much.
>> | RET, LFD  scroll forward one line.  With prefix scroll forward prefix
>> line(s).
>> | y scroll backward one line.  With prefix scroll backward prefix
>> line(s).
>> | F revert-buffer if necessary and scroll forward.
>> | Use this to view a changing file.
>> | = prints the current line number.
>> | % goes prefix argument (default 100) percent into buffer.
>> | g goes to line given by prefix argument (default first line).
>> | . set the mark.
>> | x exchanges point and mark.
>> | @ return to mark and pops mark ring.
>> | Mark ring is pushed at start of every successful search and when
>> | jump to line occurs.  The mark is set on jump to buffer start
>> or end.
>> | m save current position in character register.
>> | ' go to position saved in character register.
>> | s do forward incremental search.
>> | r do reverse incremental search.
>> | / searches forward for regular expression, starting after current
>> page.
>> | ! and @ have a special meaning at the beginning of the regexp.
>> | ! means search for a line with no match for regexp.  @ means
>> start
>> | search at beginning (end for backward search) of buffer.
>> | \ searches backward for regular expression, starting before current
>> page.
>> | n searches forward for last regular expression.
>> | p searches backward for last regular expression.
>> | q quit View mode, restoring this window and buffer to previous
>> state.
>> | q is the normal way to leave view mode.
>> | e exit View mode but stay in current buffer.  Use this if you
>> started
>> | viewing a buffer (file) and find out you want to edit it.
>> | This command restores the previous read-only status of the
>> buffer.
>> | E exit View mode, and make the current buffer editable
>> | even if it was not editable before entry to View mode.
>> | Q quit View mo

Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Thorsten Jolitz
Xebar Saram  writes:

> Thx Thorston this looks great
>
> can you recommend a way to open all orgmode notes in view mode by
> default

you could try (untested!!)

,
| (add-hook 'org-mode-hook 'view-mode)
`

> i guess i would then bind a key to disable view mode to start
> editing right?

That key is 'e' for editing (or 'q' for quitting), already defined in
view-mode. 

I usually open files directly from dired with 'v' instead of 'f' in
view-mode to just have a look, and then either do 'e' or 'q'. 

> On Thu, Jul 17, 2014 at 4:13 PM, Thorsten Jolitz 
> wrote:
>
> 
> Xebar Saram  writes:
> 
> > hi all
> >
> > i keep once and a while screwing up my notes with unintended
> editing
> > (erroneous key presses etc) and was wondering if any one knew of
> a way
> > to to switch orgmode notes between read-only/editing? i have
> used such
> > options in previous note taking apps that had that option build
> in but
> > i understand that since orgmode notes are just text files its a
> bit
> > more complicated
> >
> > i would love to hear any suggestions on how you guys deal with
> > protecting notes/data that still needs to be edited (i do use
> git ofc
> > but i dont always know i screwed my notes :))
> 
> 
> ,[ C-h f view-mode RET ]
> | view-mode is an interactive autoloaded compiled Lisp function in
> | `view.el'.
> |
> | (view-mode &optional ARG)
> |
> | Toggle View mode, a minor mode for viewing text but not editing
> it.
> | With a prefix argument ARG, enable View mode if ARG is positive,
> | and disable it otherwise. If called from Lisp, enable View mode
> | if ARG is omitted or nil.
> |
> | When View mode is enabled, commands that do not change the
> buffer
> | contents are available as usual. Kill commands insert text in
> | kill buffers but do not delete. Most other commands beep and
> | tell the user that the buffer is read-only.
> |
> |
> |
> | The following additional commands are provided. Most commands
> | take prefix arguments. Page commands default to "page size"
> | lines which is almost a whole window, or number of lines set by
> | z or w.
> | Half page commands default to and set "half page size" lines
> | which initially is half a window full. Search commands default
> | to a repeat count of one.
> |
> | H, h, ? This message.
> | Digits provide prefix arguments.
> | - negative prefix argument.
> | < move to the beginning of buffer.
> | > move to the end of buffer.
> | o scroll so that buffer end is at last line of window.
> | SPC scroll forward "page size" lines.
> | With prefix scroll forward prefix lines.
> | DEL scroll backward "page size" lines.
> | With prefix scroll backward prefix lines.
> | z like SPC but with prefix sets "page size" to prefix.
> | w like DEL but with prefix sets "page size" to prefix.
> | d scroll forward "half page size" lines. With prefix, sets
> | "half page size" to prefix lines and scrolls forward that much.
> | u scroll backward "half page size" lines. With prefix, sets
> | "half page size" to prefix lines and scrolls backward that much.
> | RET, LFD scroll forward one line. With prefix scroll forward
> prefix line(s).
> | y scroll backward one line. With prefix scroll backward prefix
> line(s).
> | F revert-buffer if necessary and scroll forward.
> | Use this to view a changing file.
> | = prints the current line number.
> | % goes prefix argument (default 100) percent into buffer.
> | g goes to line given by prefix argument (default first line).
> | . set the mark.
> | x exchanges point and mark.
> | @ return to mark and pops mark ring.
> | Mark ring is pushed at start of every successful search and when
> | jump to line occurs. The mark is set on jump to buffer start or
> end.
> | m save current position in character register.
> | ' go to position saved in character register.
> | s do forward incremental search.
> | r do reverse incremental search.
> | / searches forward for regular expression, starting after
> current page.
> | ! and @ have a special meaning at the beginning of the regexp.
> | ! means search for a line with no match for regexp. @ means
> start
> | search at beginning (end for backward search) of buffer.
> | \ searches backward for regular expression, starting before
> current page.
> | n searches forward for last regular expression.
> | p searches backward for last regular expression.
> | q quit View mode, restoring this window and buffer to previous
> state.
> | q is the normal way to leave view mode.
> | e exit View mode but stay in current buffer. Use this if you
> started
> | viewing a buffer (file) and find out you want to edit i

Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Thorsten Jolitz
Xebar Saram  writes:

> PS. Also can anyone think of a way to get a visual cue when the file
> is in "view mode"?

There is a visual cue in the mode-line:

,
| 1-UUU:**--
`

changes to 

,
| 1-UUU:%%--
`

when view-mode is active

> On Thu, Jul 17, 2014 at 4:22 PM, Xebar Saram 
> wrote:
>
> Thx Thorston this looks great
> 
> 
> can you recommend a way to open all orgmode notes in view mode by
> default, i guess i would then bind a key to disable view mode to
> start editing right?
> 
> 
> thanks alot again
> 
> 
> Z
> 
> 
> 
> 
> 
> On Thu, Jul 17, 2014 at 4:13 PM, Thorsten Jolitz
>  wrote:
> 
> 
> 
> Xebar Saram  writes:
> 
> > hi all
> >
> > i keep once and a while screwing up my notes with unintended
> editing
> > (erroneous key presses etc) and was wondering if any one
> knew of a way
> > to to switch orgmode notes between read-only/editing? i have
> used such
> > options in previous note taking apps that had that option
> build in but
> > i understand that since orgmode notes are just text files
> its a bit
> > more complicated
> >
> > i would love to hear any suggestions on how you guys deal
> with
> > protecting notes/data that still needs to be edited (i do
> use git ofc
> > but i dont always know i screwed my notes :))
> 
> 
> ,[ C-h f view-mode RET ]
> | view-mode is an interactive autoloaded compiled Lisp
> function in
> | `view.el'.
> |
> | (view-mode &optional ARG)
> |
> | Toggle View mode, a minor mode for viewing text but not
> editing it.
> | With a prefix argument ARG, enable View mode if ARG is
> positive,
> | and disable it otherwise. If called from Lisp, enable View
> mode
> | if ARG is omitted or nil.
> |
> | When View mode is enabled, commands that do not change the
> buffer
> | contents are available as usual. Kill commands insert text
> in
> | kill buffers but do not delete. Most other commands beep and
> | tell the user that the buffer is read-only.
> |
> |
> |
> | The following additional commands are provided. Most
> commands
> | take prefix arguments. Page commands default to "page size"
> | lines which is almost a whole window, or number of lines set
> by
> | z or w.
> | Half page commands default to and set "half page size" lines
> | which initially is half a window full. Search commands
> default
> | to a repeat count of one.
> |
> | H, h, ? This message.
> | Digits provide prefix arguments.
> | - negative prefix argument.
> | < move to the beginning of buffer.
> | > move to the end of buffer.
> | o scroll so that buffer end is at last line of window.
> | SPC scroll forward "page size" lines.
> | With prefix scroll forward prefix lines.
> | DEL scroll backward "page size" lines.
> | With prefix scroll backward prefix lines.
> | z like SPC but with prefix sets "page size" to prefix.
> | w like DEL but with prefix sets "page size" to prefix.
> | d scroll forward "half page size" lines. With prefix, sets
> | "half page size" to prefix lines and scrolls forward that
> much.
> | u scroll backward "half page size" lines. With prefix, sets
> | "half page size" to prefix lines and scrolls backward that
> much.
> | RET, LFD scroll forward one line. With prefix scroll forward
> prefix line(s).
> | y scroll backward one line. With prefix scroll backward
> prefix line(s).
> | F revert-buffer if necessary and scroll forward.
> | Use this to view a changing file.
> | = prints the current line number.
> | % goes prefix argument (default 100) percent into buffer.
> | g goes to line given by prefix argument (default first
> line).
> | . set the mark.
> | x exchanges point and mark.
> | @ return to mark and pops mark ring.
> | Mark ring is pushed at start of every successful search and
> when
> | jump to line occurs. The mark is set on jump to buffer start
> or end.
> | m save current position in character register.
> | ' go to position saved in character register.
> | s do forward incremental search.
> | r do reverse incremental search.
> | / searches forward for regular expression, starting after
> current page.
> | ! and @ have a special meaning at the beginning of the
> regexp.
>

Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Nick Dokos
Xebar Saram  writes:

> PS. Also can anyone think of a way to get a visual cue when the file
> is in "view mode"?
>
> thx!
>
> Z
>
> On Thu, Jul 17, 2014 at 4:22 PM, Xebar Saram  wrote:
>
>
> can you recommend a way to open all orgmode notes in view mode by
> default, i guess i would then bind a key to disable view mode to
> start editing right?
>

Add a function that enables the minor mode to org-mode-hook (this is a
completely general emacs mechanism and worth understanding thoroughly):

   (add-hook 'org-mode-hook (lambda () (view-mode 1)))

As for visual cues, you get "View" added to the list of modes in the
mode-line.

Nick

 




Re: [O] [bug] in org-element cache (?)

2014-07-17 Thread Nicolas Goaziou
Hello,

Nicolas Berthier  writes:

> I just hit a bug in org-element with the current development branch
> (commit 9cf3c4e9712aba63be36eac7193e4ac85f491f8b), when exporting
> a rather big Org file to LaTeX (HTML export works fine). It happens
> during export, in function `org-element--cache-process-request', with
> error "(wrong-type-argument number-or-marker-p nil)" (complete backtrace
> attached).

This should be fixed. Thank you for reporting it.


Regards,

-- 
Nicolas Goaziou



Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Jorge A. Alfaro-Murillo
Xebar Saram  writes:

> i keep once and a while screwing up my notes with unintended editing
> (erroneous key presses etc) and was wondering if any one knew of a way
> to to switch orgmode notes between read-only/editing?

Hi Xebar. Use C-x C-q. This works for every file, I use it in particular
for notes that I do not want to edit.

It runs the command read-only-mode which changes whether the current
buffer is read-only. Actually the command switches the local variable
buffer-read-only, so you can use that variable as local for every file
that you do not want to edit by default. At the end of those files add:

#+BEGIN_EXAMPLE
%%% Local Variables:
%%% buffer-read-only: t
%%% End:
#+END_EXAMPLE

And every time that you want to edit them just do C-x C-q

Best,

Jorge.




Re: [O] cache problem, with ECM

2014-07-17 Thread Nicolas Goaziou
Hello,

Alan Schmitt  writes:

> I noticed this morning, after updating org-mode to the latest version,
> that I would get an error with a trace related to a cache even if a just
> started emacs. It took me a while to get down to an ECM, but here it is.
>
> The init file used:
>
>
> ;; use with "open /Applications/Emacs.app --args -Q -l ~/tmp/init-org.el"
>
> (add-to-list 'load-path "/Users/schmitta/projets/org-mode/lisp")
>
> (require 'org)
>
> (toggle-debug-on-error)
>
> (setq org-log-into-drawer t)
>
> (setq org-todo-keywords
>'((sequence "TODO(t)" "NEXT(n)" "|" "DONE(d!/!)")
>  (sequence "WAITING(w@/!)" "HOLD(h@/!)" "|" "CANCELLED(c@/!)")))
>
> The crucial parts seem to be the 'org-log-into-drawer' and the fact that
> switching out of WAITING triggers a note.
>
> Here is an org file showing the problem
>
> #+STARTUP: hidestars
> * Perso
> :PROPERTIES:
> :CATEGORY: Perso
> :END:
> ** DONE bar
>:LOGBOOK:
>- State "DONE"   from "TODO"   [2014-07-06 Sun 19:22]
>:END:
>   [2014-07-06 Sun 10:01]
> ** WAITING foo   
> :@fun:
>   SCHEDULED: <2014-07-09 Wed>
>   :PROPERTIES:
>   :ID:   79A4028E-DBDA-49D4-AD39-BD2786EF9FBD
>   :END:
> * Hacking
> :PROPERTIES:
> :CATEGORY: Hacking
> :END:

This should be fixed. Thank you for reporting it.


Regards,

-- 
Nicolas Goaziou



Re: [O] [ANN] Org-gamify

2014-07-17 Thread Jürgen Hötzel
On Wed, Jul 9, 2014 at 4:39 AM, Paul Sexton  wrote:

> I have written a plugin for org agenda, which allows "gamification" of
> task management. Define currencies, earn them by completing tasks, and
> spend them on rewards. Inspired by HabitRPG, Epic Win and similar
> systems.
>
> http://bitbucket.org/eeeickythump/org-gamify
>

Thanks for creating this. I just have some issues:

1. There is no easy way to share the Inventory between multiple
machines/emacs setups.
I sync my .org files/folders via Unison. But  the the current inventory
state is saved
via `savehist-*' and thus get saved in my machine-local
.emacs.d/history file.

2. If i change a task state multiple times by accident (e.g.:
TODO->DONE->TODO->DONE) i also get rewarded multiple times.
I know this is useful for repeating tasks. But there is no easy way to
UNDO an invalid reward,


Any hints appreciated.

Jürgen


Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Xebar Saram
Thanks guys. really appreciate all your help

im now using view-mode with hooks as suggested. btw whats the advantages of
viewer-mode over read-only-mode

best

Z


On Thu, Jul 17, 2014 at 5:46 PM, Jorge A. Alfaro-Murillo <
jorge.a.alf...@gmail.com> wrote:

> Xebar Saram  writes:
>
> > i keep once and a while screwing up my notes with unintended editing
> > (erroneous key presses etc) and was wondering if any one knew of a way
> > to to switch orgmode notes between read-only/editing?
>
> Hi Xebar. Use C-x C-q. This works for every file, I use it in particular
> for notes that I do not want to edit.
>
> It runs the command read-only-mode which changes whether the current
> buffer is read-only. Actually the command switches the local variable
> buffer-read-only, so you can use that variable as local for every file
> that you do not want to edit by default. At the end of those files add:
>
> #+BEGIN_EXAMPLE
> %%% Local Variables:
> %%% buffer-read-only: t
> %%% End:
> #+END_EXAMPLE
>
> And every time that you want to edit them just do C-x C-q
>
> Best,
>
> Jorge.
>
>
>


[O] bug#18035: Linum-mode + org-indent-mode results in graphical bug

2014-07-17 Thread Eli Zaretskii
> From: Michael Heerdegen 
> Cc: 18...@debbugs.gnu.org,  Lionel Henry 
> Date: Wed, 16 Jul 2014 20:14:46 +0200
> 
> Michael Heerdegen  writes:
> 
> > > > Activating both linum-mode and org-indent-mode will cause several
> > > > graphical glitches in the current line.
> > > > See
> > > > http://lists.gnu.org/archive/html/emacs-orgmode/2011-01/msg01204.html
> > >
> > > That discussion provides no reproducible recipe.
> 
> But I think I found something that is related (before-string overlays
> vs. text properties) and is reproducible for emacs -Q:

It's specific to invisible property, not just any property, and also
requires that another text property starts exactly where the invisible
property ends.

I'm not sure this is the same problem as reported by the OP, so it
probably should have been reported as a separate bug (merging them
later is easy).

> - visit a file under version control (I tried a git controlled file here)
> - M-x vc-annotate
> - v (i.e. vc-annotate-toggle-annotation-visibility)
> - M-x linum-mode
> 
> ==> all lines but one loose their coloring.  Those lines that are still
> colored loose their line number.
> 
> nlinum-mode behaves similarly.

Fixed in revision 117382 on the emacs-24 branch.





[O] turn off monospace in src result

2014-07-17 Thread regcl

With this line in my .org file ...

This is src_R{foo<-"FOO"; paste(foo)}.

... when I publish to html or pdf, I get ...

This is FOO.

... which is wonderful, except that "FOO" is monospace.  

Can I turn off monospace for all results of inline source?

Thanks,
regcl




[O] Infinite loop with org-log-done 'time?

2014-07-17 Thread Ethan
Hi list,

I'm running org-mode from git (version "8.3beta"), and recently I started
to get hangs in org files. I can't characterize them completely; I have a
clear memory of causing something when I hit Enter to create a newline
before a heading. Today I managed to reproduce it reliably when I changed a
particular heading from DONE to TODO. When I trigger the hang, emacs's CPU
spikes to 100% and C-g doesn't stop emacs (it flashes to signal that it got
a quit, but doesn't actually quit). I've had to kill emacs, sometimes with
-9, and restart.

The bug has been tricky to track down. I can reproduce it reliably in one
particular file by switching DONE to TODO on one particular heading.
Changing DONE to TODO on another nearby heading doesn't seem to cause the
problem. For this reason, I don't have a minimal example.

It doesn't happen in org-mode in stock emacs. It also doesn't happen, even
with org-mode from git, if I disable my '(org-log-done 'time)
customization. I managed to get a backtrace using gdb (attached). I can
provide (off-list) the .org file that I used to induce the failure.

I haven't seen anyone else comment about this issue so I assume it's
something specific to my configuration. Has anyone else seen anything like
this?

Ethan
(gdb) thread apply all backtrace

Thread 4 (Thread 0x7fffe37ae700 (LWP 10101)):
#0  0x71a6afbd in poll () at ../sysdeps/unix/syscall-template.S:81
#1  0x75618fe4 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x756190ec in g_main_context_iteration () from 
/lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x75619129 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x7563df15 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x71d4b182 in start_thread (arg=0x7fffe37ae700) at 
pthread_create.c:312
#6  0x71a7830d in clone () at 
../sysdeps/unix/sysv/linux/x86_64/clone.S:111

Lisp Backtrace:
"org-heading-components" (0xae80)
"org-element-headline-parser" (0xb130)
"org-element--current-element" (0xb310)
"byte-code" (0xb460)
"org-element--parse-to" (0xb800)
"byte-code" (0xb950)
"org-element--cache-process-request" (0xbcf0)
"byte-code" (0xbe40)
"org-element--cache-sync" (0xc1f0)
"org-element--cache-submit-request" (0xc3f0)
"org-element--cache-after-change" (0xc628)
"replace-match" (0xc880)
"byte-code" (0xc9d0)
"org-add-planning-info" (0xcd90)
"byte-code" (0xcef0)
"org-todo" (0xd308)
"call-interactively" (0xd4c8)

Thread 3 (Thread 0x7fffe94fe700 (LWP 10098)):
#0  0x71a6afbd in poll () at ../sysdeps/unix/syscall-template.S:81
#1  0x75618fe4 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x7561930a in g_main_loop_run () from 
/lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x76378e16 in ?? () from /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0
#4  0x7563df15 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x71d4b182 in start_thread (arg=0x7fffe94fe700) at 
pthread_create.c:312
#6  0x71a7830d in clone () at 
../sysdeps/unix/sysv/linux/x86_64/clone.S:111

Lisp Backtrace:
"org-heading-components" (0xae80)
---Type  to continue, or q  to quit---
"org-element-headline-parser" (0xb130)
"org-element--current-element" (0xb310)
"byte-code" (0xb460)
"org-element--parse-to" (0xb800)
"byte-code" (0xb950)
"org-element--cache-process-request" (0xbcf0)
"byte-code" (0xbe40)
"org-element--cache-sync" (0xc1f0)
"org-element--cache-submit-request" (0xc3f0)
"org-element--cache-after-change" (0xc628)
"replace-match" (0xc880)
"byte-code" (0xc9d0)
"org-add-planning-info" (0xcd90)
"byte-code" (0xcef0)
"org-todo" (0xd308)
"call-interactively" (0xd4c8)

Thread 2 (Thread 0x7fffe9cff700 (LWP 10097)):
#0  0x71a6afbd in poll () at ../sysdeps/unix/syscall-template.S:81
#1  0x75618fe4 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x756190ec in g_main_context_iteration () from 
/lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x7fffe9d071ad in ?? () from 
/usr/lib/x86_64-linux-gnu/gio/modules/libdconfsettings.so
#4  0x7563df15 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x71d4b182 in start_thread (arg=0x7fffe9cff700) at 
pthread_create.c:312
#6  0x71a7830d in clone () at 
../sysdeps/unix/sysv/linux/x86_64/clone.S:111

Lisp Backtrace:
"org-heading-components" (0xae80)
"org-element-headline-parser" (0xb130)
"org-element--current-element" (0xb310)
"byte-code" (0xb460)
"org-element--parse-to" (0xb800)
"byte-code" (0xb950)
"org-element--cache-process-request" (0xbcf0)
"byte-code" (0xbe40)
"org-element--cache-sync" (0xc1f0)
"org-element--cache-submit-request" (0xc3f0)
"org-element--cache-after-change" (0xc628)
"replace-match" (0xc880)
"byte-code" (0xc9d0)
---Type  to continue, or q  to quit---
"org-add-planning-info" (0xcd90)
"

[O] orgtbl export to latex :fmt() fails

2014-07-17 Thread Thorsten Grothe
Hi List,

I have a problem with a orgtbl which I would like to export with certain
options to latex.

The table looks like this:

#+TBLNAME: test
#+ORGTBL: SEND test orgtbl-to-latex :skip 2 :splice t :fmt (4"\\num{%s}")

| Soll |   |  | Haben |
|--+---+--+---|
|  |   |  | 39000 |

I would like to export the 4 column of the table with the latex \num{} tag,
see :fmt (4"\\num{%s}"), I got this from the manual.

this works fine but *only* if the first column is *not* empty like so:

| Soll |   |  | Haben |
|--+---+--+---|
|  0   |   |  | 39000 |

Result:
% BEGIN RECEIVE ORGTBL test
0 &  &  & \num{39000} \\
% END RECEIVE ORGTBL test


if the first column is *empty* the result looks like this:

| Soll |   |  | Haben |
|--+---+--+---|
|  |   |  | 39000 |

Result:
% BEGIN RECEIVE ORGTBL test
&  & 39000 \\
% END RECEIVE ORGTBL test

the \num{} tag is not exported and one "&" in the table is missing.

I don't know what I'm doing wrong???

Thanks in advance for your help!!

Regards
Th. Grothe



Re: [O] fill-paragraph running slowly in org mode

2014-07-17 Thread Sean Markan
>
>
> > I just upgraded to a new version of Linux/emacs/org-mode, and am finding
> > that fill-paragraph (M-q) runs very slowly in org-mode on large files.
> > With about 50k lines in the buffer, fill-paragraph takes around 3 seconds
> > even if the paragraph is only a couple lines.  (The behavior is correct,
> > the problem is just the slowness.)  The time seems to scale linearly with
> > the number of lines in the buffer as if the whole file is being processed
> > during each fill-paragraph.
>
> Actually, the full section is processed. It can be slow on very large
> sections, indeed. Though, you could use a profiler (M-x profiler-start)
> to check if something is suspicious.
>
> Note that Org 8.3+ makes it a lot better with a cache mechanism, but it
> is still buggy at the moment.
>

I see, thanks!  I will insert some section breaks in my file.

- Sean


Re: [O] orgtbl export to latex :fmt() fails

2014-07-17 Thread Nick Dokos
Thorsten Grothe  writes:

> Hi List,
>
> I have a problem with a orgtbl which I would like to export with certain
> options to latex.
>
> The table looks like this:
>
> #+TBLNAME: test
> #+ORGTBL: SEND test orgtbl-to-latex :skip 2 :splice t :fmt (4"\\num{%s}")
>
> | Soll |   |  | Haben |
> |--+---+--+---|
> |  |   |  | 39000 |
>
> I would like to export the 4 column of the table with the latex \num{} tag,
> see :fmt (4"\\num{%s}"), I got this from the manual.
>
> this works fine but *only* if the first column is *not* empty like so:
>
> | Soll |   |  | Haben |
> |--+---+--+---|
> |  0   |   |  | 39000 |
>
> Result:
> % BEGIN RECEIVE ORGTBL test
> 0 &  &  & \num{39000} \\
> % END RECEIVE ORGTBL test
>
>
> if the first column is *empty* the result looks like this:
>
> | Soll |   |  | Haben |
> |--+---+--+---|
> |  |   |  | 39000 |
>
> Result:
> % BEGIN RECEIVE ORGTBL test
> &  & 39000 \\
> % END RECEIVE ORGTBL test
>
> the \num{} tag is not exported and one "&" in the table is missing.
>
> I don't know what I'm doing wrong???
>

Nothing - there is a bug in org-table.el:org-table-clean-before-export
where the regexp that matches special chars in the first column (see

  (info "(org)Advanced features")

for the details) inadvertently matches "| | | | 3900|" and deletes the
first column. The regexp is set like this:

--8<---cut here---start->8---
  (let ((special (if maybe-quoted
 "^[ \t]*| *?[\#!$*_^/ ] *|"
   "^[ \t]*| *[\#!$*_^/ ] *|"))
--8<---cut here---end--->8---

and in each case I think that the space inside the second [...] is
spurious.

So try this patch:

--8<---cut here---start->8---
diff --git a/lisp/org-table.el b/lisp/org-table.el
index d7ef615..864493e 100644
--- a/lisp/org-table.el
+++ b/lisp/org-table.el
@@ -447,8 +447,8 @@ available parameters."
   "Check if the table has a marking column.
 If yes remove the column and the special lines."
   (let ((special (if maybe-quoted
-"^[ \t]*| *?[\#!$*_^/ ] *|"
-  "^[ \t]*| *[\#!$*_^/ ] *|"))
+"^[ \t]*| *?[\#!$*_^/] *|"
+  "^[ \t]*| *[\#!$*_^/] *|"))
(ignore  (if maybe-quoted
 "^[ \t]*| *?[!$_^/] *|"
   "^[ \t]*| *[!$_^/] *|")))
--8<---cut here---end--->8---

I think it's OK for the non-quoted case, but I'm not sure
about the quoted case (maybe-quotes is t). If there are no
objections, I'll push it later on tonight.

Just to be sure: this is a bug, so it should be committed
to the maint branch and then a merge should be done onto master -
correct?

Nick








Re: [O] turn off monospace in src result

2014-07-17 Thread Andreas Leha
Hi regcl,

regcl  writes:

> With this line in my .org file ...
>
> This is src_R{foo<-"FOO"; paste(foo)}.
>
> ... when I publish to html or pdf, I get ...
>
> This is FOO.
>
> ... which is wonderful, except that "FOO" is monospace.  
>
> Can I turn off monospace for all results of inline source?

I do not know, how to do that for all inline source blocks.  But you can
turn it off
1. per code block as in src_R[:results raw]{foo<-"FOO"; paste(foo)}
2. globally for all block as in '#+PROPERTY: results raw'
   (then you would override this setting per non-inline code block)

HTH,
Andreas




Re: [O] turn off monospace in src result

2014-07-17 Thread Nick Dokos
Andreas Leha  writes:

> Hi regcl,
>
> regcl  writes:
>
>> With this line in my .org file ...
>>
>> This is src_R{foo<-"FOO"; paste(foo)}.
>>
>> ... when I publish to html or pdf, I get ...
>>
>> This is FOO.
>>
>> ... which is wonderful, except that "FOO" is monospace.  
>>
>> Can I turn off monospace for all results of inline source?
>
> I do not know, how to do that for all inline source blocks.  But you can
> turn it off
> 1. per code block as in src_R[:results raw]{foo<-"FOO"; paste(foo)}

Looks like

--8<---cut here---start->8---
This is src_R[:results raw]{foo<-"FOO"; paste(foo)}.
--8<---cut here---end--->8---

produces a newline after the evaluated code block in the HTML file,
which is rendered as a space between the word FOO and the period.  Bug?

Nick







Re: [O] turn off monospace in src result

2014-07-17 Thread Andreas Leha
Hi Nick,

Nick Dokos  writes:

> Andreas Leha  writes:
>
>> Hi regcl,
>>
>> regcl  writes:
>>
>>> With this line in my .org file ...
>>>
>>> This is src_R{foo<-"FOO"; paste(foo)}.
>>>
>>> ... when I publish to html or pdf, I get ...
>>>
>>> This is FOO.
>>>
>>> ... which is wonderful, except that "FOO" is monospace.  
>>>
>>> Can I turn off monospace for all results of inline source?
>>
>> I do not know, how to do that for all inline source blocks.  But you can
>> turn it off
>> 1. per code block as in src_R[:results raw]{foo<-"FOO"; paste(foo)}
>
> Looks like
>
> This is src_R[:results raw]{foo<-"FOO"; paste(foo)}.
>
> produces a newline after the evaluated code block in the HTML file,
> which is rendered as a space between the word FOO and the period.  Bug?
>

I tend to agree.  There was some discussion on this last year [fn:1] that went
dead after a while.  I still think that modifying raw results (as in
adding newline) should be avoided -- at least in inline source blocks.

Regards,
Andreas



Footnotes:

[fn:1] http://article.gmane.org/gmane.emacs.orgmode/71385




Re: [O] orgtbl export to latex :fmt() fails

2014-07-17 Thread Thorsten Grothe
Nick,

> Nothing - there is a bug in org-table.el:org-table-clean-before-export
> where the regexp that matches special chars in the first column (see
> 
>   (info "(org)Advanced features")
> 
> for the details) inadvertently matches "| | | | 3900|" and deletes the
> first column. The regexp is set like this:
> 
> --8<---cut here---start->8---
>   (let ((special (if maybe-quoted
>"^[ \t]*| *?[\#!$*_^/ ] *|"
>  "^[ \t]*| *[\#!$*_^/ ] *|"))
> --8<---cut here---end--->8---
> 
> and in each case I think that the space inside the second [...] is
> spurious.
> 
> So try this patch:
> 
> --8<---cut here---start->8---
> diff --git a/lisp/org-table.el b/lisp/org-table.el
> index d7ef615..864493e 100644
> --- a/lisp/org-table.el
> +++ b/lisp/org-table.el
> @@ -447,8 +447,8 @@ available parameters."
>"Check if the table has a marking column.
>  If yes remove the column and the special lines."
>(let ((special (if maybe-quoted
> -  "^[ \t]*| *?[\#!$*_^/ ] *|"
> -"^[ \t]*| *[\#!$*_^/ ] *|"))
> +  "^[ \t]*| *?[\#!$*_^/] *|"
> +"^[ \t]*| *[\#!$*_^/] *|"))
>   (ignore  (if maybe-quoted
>"^[ \t]*| *?[!$_^/] *|"
>  "^[ \t]*| *[!$_^/] *|")))
> --8<---cut here---end--->8---
> 
> I think it's OK for the non-quoted case, but I'm not sure
> about the quoted case (maybe-quotes is t). If there are no
> objections, I'll push it later on tonight.
> 
> Just to be sure: this is a bug, so it should be committed
> to the maint branch and then a merge should be done onto master -
> correct?

thank you very much for your response, well I'm not an emacs guru, so my simple
question is, how to apply this patch? I'm working with archlinux here and I
installed orgmode systemwide not locally, I guess I should first install it in
my local homedir and than patch it, but how?

Sorry about this simple question :-)


Regards
Th. Grothe



Re: [O] orgtbl export to latex :fmt() fails

2014-07-17 Thread Nick Dokos
Thorsten Grothe  writes:

> thank you very much for your response, well I'm not an emacs guru, so
> my simple question is, how to apply this patch? I'm working with
> archlinux here and I installed orgmode systemwide not locally, I guess
> I should first install it in my local homedir and than patch it, but
> how?
>

It depends on how exactly you installed: from git, from elpa, from a
tarball, using the org mode that came with your emacs, some other way?

If you don't mind living somewhat dangerously, you can find out where
org-table is located (M-x locate-library RET org-table RET) which is
going to be either a byte-compiled file (org-table.elc) or a .el file.
If a .el file, you can just edit it and delete the spaces (carefully: it
should like look the + lines in the patch after you are done). If it's a
.elc file, then you'll have to locate the .el file, edit it as before,
byte-compile it and then replace the .elc file with the new file.
In either case, you'll need to reload the file or restart your emacs.

I can't in all honesty recommend this procedure (it's too error-prone),
but desperate situations call for desperate measures. OTOH, if you
are not desperate, then waiting for the change to happen upstream and
then percolate down to you is a much safer (but slower) alternative.

HTH,
Nick




[O] bug#18035: Linum-mode + org-indent-mode results in graphical bug

2014-07-17 Thread Michael Heerdegen
Eli Zaretskii  writes:


> [...]  I'm not sure this is the same problem as reported by the OP, so
> it probably should have been reported as a separate bug (merging them
> later is easy).

Ok.  I wasn't sure what would be best.


> > - visit a file under version control (I tried a git controlled file
> > here)
> > - M-x vc-annotate
> > - v (i.e. vc-annotate-toggle-annotation-visibility)
> > - M-x linum-mode
> > 
> > ==> all lines but one loose their coloring.  Those lines that are still
> > colored loose their line number.
> > 
> > nlinum-mode behaves similarly.
>
> Fixed in revision 117382 on the emacs-24 branch.

Works for me, thanks!


Michael.





Re: [O] a quick way to switch orgmode notes between read-only/editing?

2014-07-17 Thread Eric Abrahamsen
Xebar Saram  writes:

> Thanks guys. really appreciate all your help 
>
> im now using view-mode with hooks as suggested. btw whats the
> advantages of viewer-mode over read-only-mode

Mostly that you get more convenient navigation commands. Scrolling and
searching etc don't require control modifiers, and it becomes a bit
easier to move around files.

> best
>
> Z
>
>
> On Thu, Jul 17, 2014 at 5:46 PM, Jorge A. Alfaro-Murillo <
> jorge.a.alf...@gmail.com> wrote:
>
> Xebar Saram  writes:
>
> > i keep once and a while screwing up my notes with unintended
> editing
> > (erroneous key presses etc) and was wondering if any one knew
> of a way
> > to to switch orgmode notes between read-only/editing?
>
> Hi Xebar. Use C-x C-q. This works for every file, I use it in
> particular
> for notes that I do not want to edit.
>
> It runs the command read-only-mode which changes whether the
> current
> buffer is read-only. Actually the command switches the local
> variable
> buffer-read-only, so you can use that variable as local for every
> file
> that you do not want to edit by default. At the end of those
> files add:
>
> #+BEGIN_EXAMPLE
> %%% Local Variables:
> %%% buffer-read-only: t
> %%% End:
> #+END_EXAMPLE
>
> And every time that you want to edit them just do C-x C-q
>
> Best,
>
> Jorge.
>
>




Re: [O] orgtbl export to latex :fmt() fails

2014-07-17 Thread Nick Dokos
Nick Dokos  writes:

> Nothing - there is a bug in org-table.el:org-table-clean-before-export
> where the regexp that matches special chars in the first column (see
>
>   (info "(org)Advanced features")
>
> for the details) inadvertently matches "| | | | 3900|" and deletes the
> first column. The regexp is set like this:
>
>   (let ((special (if maybe-quoted
>"^[ \t]*| *?[\#!$*_^/ ] *|"
>  "^[ \t]*| *[\#!$*_^/ ] *|"))
>
>

Checking the list of special chars in the Advanced Features section
above, I see #!$*_^/ only - I'm not sure what the \ is doing in the
[...] character class. I propose getting rid of it as well as the space.

Also, org-table-clean-before-export is called from two places in
org-table.el, neither of which uses the maybe-quoted argument[fn:1], so
I propose getting rid of it and the if clauses as well. Like this:

--8<---cut here---start->8---
diff --git a/lisp/org-table.el b/lisp/org-table.el
index 6d649ab..bfe396e 100644
--- a/lisp/org-table.el
+++ b/lisp/org-table.el
@@ -436,15 +436,11 @@ available parameters."
   "[ \t]*|[ \t]*")))
 
 (defvar org-table-clean-did-remove-column nil) ; dynamically scoped
-(defun org-table-clean-before-export (lines &optional maybe-quoted)
+(defun org-table-clean-before-export (lines)
   "Check if the table has a marking column.
 If yes remove the column and the special lines."
-  (let ((special (if maybe-quoted
-"^[ \t]*| *?[\#!$*_^/ ] *|"
-  "^[ \t]*| *[\#!$*_^/ ] *|"))
-   (ignore  (if maybe-quoted
-"^[ \t]*| *?[!$_^/] *|"
-  "^[ \t]*| *[!$_^/] *|")))
+  (let ((special "^[ \t]*| *[#!$*_^/] *|")
+   (ignore "^[ \t]*| *[!$_^/] *|"))
 (setq org-table-clean-did-remove-column
  (not (memq nil
 (mapcar
--8<---cut here---end--->8---

Any objections?

Footnotes:

[fn:1] I checked contrib as well and nobody uses it there either. Although
   it's possible that somebody uses it out in the wild, I think it's
   very unlikely. But if you do use it, let me know.

Thanks,
-- 
Nick




Re: [O] cache problem, with ECM

2014-07-17 Thread Alan Schmitt
On 2014-07-17 16:43, Nicolas Goaziou  writes:

> This should be fixed. Thank you for reporting it.

I confirm it works. Thanks a lot!

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7


pgpQ5yvO04f9s.pgp
Description: PGP signature