Re: [O] Inserted Heading Starts on Prior Heading's Fold Mark

2015-04-06 Thread John Hendy
On Mon, Apr 6, 2015 at 12:05 PM, Daniel E. Doherty ded-...@ddoherty.net wrote:

 I don't know when this started, but recently I've seen the following annoying
 behavior from M-RET in org files.

I have this on my main Org file and just assumed it was due to it
being big and Org having a tough time keeping track of all the various
blocks (src, example, etc.), properties, ids, and whatnot. I figured
I'd messed up the syntax in there somewhere and would just have to
deal with this quirky behavior.

I think others have experienced this as well (e.g.
http://lists.gnu.org/archive/html/emacs-orgmode/2010-09/msg00457.html).

Can you try commenting out:

#+begin_src .emacs
;;(setq org-blank-before-new-entry nil)
#_end_src

I copied my .emacs into a new config, started with emacs -Q, loaded
that file, and then tried your original post's exercise, repeating
after commenting out various lines in my own config file. We both had
the above setting, and that turned out to fix it for me on your test
file. Not sure if there's another interaction between your options vs.
mine, though, so confirmation is needed.


John


 I've tried tweaking a number of these settings with no luck.

 Any ideas about what is going wrong here?

 Dan Doherty





Re: [O] Function that jumps to an entry with a certain CUSTOM_ID

2015-04-06 Thread Leo Ufimtsev
+1

* Non-technical feedback ::
 - Thank you so much for sharing. I've been looking for something like this for 
a while.
 - I hope it'll make it into org-mode some way or another, it seems like a 
valuable addition. 
 - imho the HELM integration is essential.

Leo Ufimtsev | Software Engineer @ Eclipse Team

- Original Message -
From: Christoph LANGE math.semantic@gmail.com
To: emacs-orgmode@gnu.org
Sent: Tuesday, March 31, 2015 12:36:45 PM
Subject: [O] Function that jumps to an entry with a certain CUSTOM_ID

Hi all,

the following function has served me well for a few years, so I thought 
I'd share it.  I would even be happy to contribute it to the codebase of 
org-mode (core or contrib); however in this case someone would have to 
point me to a fool-proof guide for how to do this.  I know that for 
contributing code I will have to sign some FSF copyright forms, and I 
know how to use git, but I don't know the exact org-mode specific steps 
of doing so.

--- % --- % --- % --- % --- % --- % --- % --- % --- % --- % ---
(defun org-jump-to-id ()
   Asks for an identifier and searches for the first entry in the 
current file that has this identifier as a CUSTOM_ID property.
   (interactive)
   (let* ((property CUSTOM_ID)
  (custom-id (org-icompleting-read CUSTOM_ID of entry: 
   (mapcar 'list 
(org-property-values property)
   (org-link-search (concat # custom-id

(define-key org-mode-map (kbd \C-cj) 'org-jump-to-id)
--- % --- % --- % --- % --- % --- % --- % --- % --- % --- % ---

This implementation works efficiently in a 4 MB org file with 100 IDs. 
Together with ido or helm I find it a very user-friendly way of jumping 
to frequently used headlines.

I noticed that org-babel-ref-goto-headline-id does something similar, so 
maybe some code could be shared among the two functions.

Cheers,

Christoph

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

→ Semantic Publishing Challenge: Assessing the Quality of Scientific Output
   ESWC, 31 May–4 June 2014, Portorož, Slovenia. 
https://tinyurl.com/SPChallenge15
   Submission deadline 27 March (abstracts: 20 March)




Re: [O] How to convert CSV text containing newlines to org-table?

2015-04-06 Thread Rasmus
Hi,

Kaushal kaushal.m...@gmail.com writes:

 I have this sample text:

 a,b,c,def,
 ghi

 When I convert that to org-table using C-u C-c |, I get

 | a| b | c | def |   |
 | ghi |   |   |  |   |

 This was my expected outcome:

 | a | b | c | def, |
 |   |   |   | ghi  |

For the reference:

LO opens is as
| a | b |c | def\nghi|

And Gnumeric opens it as

| a, b, c, def |
| ghi |

It's not obvious what is the correct behavior here.

-- 
Send from my Emacs




Re: [O] Inserted Heading Starts on Prior Heading's Fold Mark

2015-04-06 Thread Daniel E . Doherty
John,

You nailed it.  I had that variable set in my custom file to

'(org-blank-before-new-entry (quote ((heading) (plain-list-item . auto

which is not a proper alist.  When I chaned it back to 

'(org-blank-before-new-entry (quote ((heading . auto) (plain-list-item . 
auto

the bad behavior went away.

Thanks a ton for taking a look at this, John.  Back to loving org-mode!


On Mon, 06 Apr 2015 13:12:21 -0500,
John Hendy jw.he...@gmail.com wrote:
 
 On Mon, Apr 6, 2015 at 12:05 PM, Daniel E. Doherty ded-...@ddoherty.net 
 wrote:
 
  I don't know when this started, but recently I've seen the following 
  annoying
  behavior from M-RET in org files.
 
 I have this on my main Org file and just assumed it was due to it
 being big and Org having a tough time keeping track of all the various
 blocks (src, example, etc.), properties, ids, and whatnot. I figured
 I'd messed up the syntax in there somewhere and would just have to
 deal with this quirky behavior.
 
 I think others have experienced this as well (e.g.
 http://lists.gnu.org/archive/html/emacs-orgmode/2010-09/msg00457.html).
 
 Can you try commenting out:
 
 #+begin_src .emacs
 ;;(setq org-blank-before-new-entry nil)
 #_end_src
 
 I copied my .emacs into a new config, started with emacs -Q, loaded
 that file, and then tried your original post's exercise, repeating
 after commenting out various lines in my own config file. We both had
 the above setting, and that turned out to fix it for me on your test
 file. Not sure if there's another interaction between your options vs.
 mine, though, so confirmation is needed.
 
 
 John
 
 
  I've tried tweaking a number of these settings with no luck.
 
  Any ideas about what is going wrong here?
 
  Dan Doherty
 
 
 



Re: [O] org-cite and org-citeproc

2015-04-06 Thread Richard Lawrence
Hi Aaron and all,

Richard Lawrence richard.lawre...@berkeley.edu writes:

 Alright, I'll try to move to json.el, and possibly change to having
 org-citeproc generate Org markup in the meantime.

Just a heads up: I've pushed some changes to my branch of Org to make
org-cite use json.el, and to add a basic Org format writer to
org-citeproc.

I have not made any other changes to org-cite to use the Org formatted
output from org-citeproc, though, as I believe doing this properly will
involve parsing the output and inserting it into Org's exporter's parse
tree (to accommodate the bibliography and note-based styles).  I won't
have time to work on that this week, but I'll come back to it.

Best,
Richard



[O] How to convert CSV text containing newlines to org-table?

2015-04-06 Thread Kaushal
Hi,

I have this sample text:

a,b,c,def,
ghi

When I convert that to org-table using C-u C-c |, I get

| a| b | c | def |   |
| ghi |   |   |  |   |

This was my expected outcome:

| a | b | c | def, |
|   |   |   | ghi  |


Re: [O] Inserted Heading Starts on Prior Heading's Fold Mark

2015-04-06 Thread Nicolas Goaziou
Hello,

Daniel E. Doherty ded-...@ddoherty.net writes:

 I don't know when this started, but recently I've seen the following annoying
 behavior from M-RET in org files.

 Here is a minimal file to demonstrate what I'm seeing lately:

 == demo.org ==
 * First Header
 Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
 tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim
 veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
 commodo consequat. Duis aute irure dolor in reprehenderit in voluptate
 velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
 occaecat cupidatat non proident, sunt in culpa qui officia deserunt
 mollit anim id est laborum.

 * Second Header
 ===

 When the headings are completely folded, I see the following, as expected:

 == demo.org ==
  * First Header...
 ^* Second Header
 ===

 With my cursor on the ^, I hit M-RET to insert a new heading between First
 Header and Second Header, and I get the following:

 ===

 When the headings are completely folded, I see the following, as expected:

 == demo.org ==
  * First Header...* ^
  * Second Header
 ===

Fixed in edeb7fd8e17733cc516fbb6620a21092bac0d765. Thank you.

Regards,

-- 
Nicolas Goaziou



[O] [PATCH] lisp/ob-sql.el: add support for :dbport parameter

2015-04-06 Thread Saulius Menkevičius

This (tiny) patch implements ability to set dbport for org-babel sql
functionality. I often use ssh port forwarding to connect to remote
mysql servers where port is mapped to non-standard one on local machine.

This is my first patch, below the 15 line threshold.

From ca3f85877bdf406deefaf66cbac3483a7e41f134 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Saulius=20Menkevi=C4=8Dius?= saulius.menkevic...@gmail.com
Date: Mon, 6 Apr 2015 23:13:06 +0300
Subject: [PATCH] ob-sql: Add possibility to set dbport

 * lisp/ob-sql.el: will now recognize dbport parameter. Currently it
   is supported for mysql engine only.

TINYCHANGE
---
 lisp/ob-sql.el | 8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el
index 493b3dc..2de5d6e 100644
--- a/lisp/ob-sql.el
+++ b/lisp/ob-sql.el
@@ -36,6 +36,7 @@
 ;; - engine
 ;; - cmdline
 ;; - dbhost
+;; - dbport
 ;; - dbuser
 ;; - dbpassword
 ;; - database
@@ -68,6 +69,7 @@
   '((engine	   . :any)
 (out-file	   . :any)
 (dbhost	   . :any)
+(dbport	   . :any)
 (dbuser	   . :any)
 (dbpassword	   . :any)
 (database	   . :any))
@@ -78,11 +80,12 @@
   (org-babel-sql-expand-vars
body (mapcar #'cdr (org-babel-get-header params :var
 
-(defun org-babel-sql-dbstring-mysql (host user password database)
+(defun org-babel-sql-dbstring-mysql (host port user password database)
   Make MySQL cmd line args for database connection.  Pass nil to omit that arg.
   (combine-and-quote-strings
(delq nil
 	 (list (when host (concat -h host))
+	   (when port (concat -P (number-to-string port)))
 	   (when user (concat -u user))
 	   (when password (concat -p password))
 	   (when database (concat -D database))
@@ -102,6 +105,7 @@ This function is called by `org-babel-execute-src-block'.
   (let* ((result-params (cdr (assoc :result-params params)))
  (cmdline (cdr (assoc :cmdline params)))
  (dbhost (cdr (assoc :dbhost params)))
+ (dbport (cdr (assoc :dbport params)))
  (dbuser (cdr (assoc :dbuser params)))
  (dbpassword (cdr (assoc :dbpassword params)))
  (database (cdr (assoc :database params)))
@@ -126,7 +130,7 @@ This function is called by `org-babel-execute-src-block'.
  (org-babel-process-file-name in-file)
  (org-babel-process-file-name out-file)))
 ('mysql (format mysql %s %s %s  %s  %s
-(org-babel-sql-dbstring-mysql dbhost dbuser dbpassword database)
+(org-babel-sql-dbstring-mysql dbhost dbport dbuser dbpassword database)
 (if colnames-p  -N)
 (or cmdline )
 (org-babel-process-file-name in-file)
-- 
2.3.3


-- 
Saulius Menkevičius (saulius.menkevic...@gmail.com)


[O] Bug: Evaluating octave code with :results verbatim prints table [8.2.10 (8.2.10-35-g19a7d6-elpaplus @ /home/martinv/.emacs.d/elpa/org-plus-contrib-20150330/)]

2015-04-06 Thread Martin Vuk
If octave code block is evaluated by C-c C-c, the results are 
printed as table even if :results verbatim option is used.

For example this code

#+BEGIN_SRC octave :results verbatim 
[1 2; 3 4]
#+END_SRC

#+RESULTS:
| 1 | 2 |
| 3 | 4 |

should return

#+RESULTS:
 1 2
 3 4

without table delimeters.


Martin Vuk




Emacs  : GNU Emacs 24.4.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.10.8)
 of 2015-04-04 on veliki-picard
Package: Org-mode version 8.2.10 (8.2.10-35-g19a7d6-elpaplus @ 
/home/martinv/.emacs.d/elpa/org-plus-contrib-20150330/)

current state:
==
(setq
 org-tab-first-hook '(org-hide-block-toggle-maybe 
org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe 
org-babel-header-arg-expand)
 org-speed-command-hook '(org-speed-command-default-hook 
org-babel-speed-command-hook)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-html-format-drawer-function '(lambda (name contents) contents)
 org-latex-format-inlinetask-function 'ignore
 org-confirm-shell-link-function 'yes-or-no-p
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-support-shift-select 'always
 org-latex-format-headline-function 'org-latex-format-headline-default-function
 org-default-notes-file ~/org/notes.org
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-latex-format-drawer-function '(lambda (name contents) contents)
 org-from-is-user-regexp \\Martin Vuk\\
 org-src-mode-hook '(org-src-babel-configure-edit-buffer 
org-src-mode-configure-edit-buffer)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-mode-hook '(org-display-inline-images #[nil \300\301\302\303\304$\207 
[org-add-hook change-major-mode-hook org-show-block-all append local] 5]
 #[nil \300\301\302\303\304$\207 [org-add-hook 
change-major-mode-hook org-babel-show-result-all append local] 5]
 org-babel-result-hide-spec org-babel-hide-all-hashes 
org-journal-update-auto-mode-alist)
 org-ascii-format-drawer-function '(lambda (name contents width) contents)
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point 
org-babel-execute-safely-maybe)
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers 
org-cycle-hide-inline-tasks org-cycle-show-empty-lines
  org-optimize-window-after-visibility-change)
 org-modules '(org-bbdb org-bibtex org-docview org-gnus org-info org-irc 
org-mhe org-rmail org-w3m org-collector)
 org-babel-tangle-lang-exts '((julia . jl) (python . py) (emacs-lisp 
. el))
 org-confirm-elisp-link-function 'yes-or-no-p
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-babel-after-execute-hook '(org-display-inline-images)
 org-html-format-headline-function 'ignore
 org-babel-load-languages '((python . t) (R . t) (octave . t) (dot . t) (julia 
. t))
 org-html-format-inlinetask-function 'ignore
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-confirm-babel-evaluate nil
 org-src-fontify-natively t
 )



[O] Bug: Pressing TAB in table cell with CJK characters sometimes destroys proper column alignment [8.2.10 (8.2.10-dist @ /usr/share/emacs24/site-lisp/org-mode/)]

2015-04-06 Thread Eugen Dueck

In a simple org-table like the following:

|  |   |
| 漢   |   |

when pressing the TAB key in the bottom left cell, one space character 
is removed from that cell and the table thus looks like


|  |   |
| 漢  |   |

Pressing TAB again in that cell removes another space character

|  |   |
| 漢 |   |

I can repeat this until only one space remains between the Japanese 
character and the column separator to its right.


When working on a table, navigating via TAB, over time all the CJK cells 
that I TABbed out of - or Shift-TABbed out of - get affected, messing up 
the overall table layout. Once I press C-c C-c, the formatting of the 
whole table gets restored, until my next TAB, but it would of course be 
nice if TABs didn't destroy it in the first place.


Btw, org-table rocks and I use it all the time - and I hope to be able 
to use it with Japanese characters as well.






Emacs  : GNU Emacs 24.4.1 (x86_64-pc-linux-gnu, GTK+ Version 3.14.5)
 of 2014-12-10 on gaia, modified by Debian
Package: Org-mode version 8.2.10 (8.2.10-dist @ 
/usr/share/emacs24/site-lisp/org-mode/)





Re: [O] Inserted Heading Starts on Prior Heading's Fold Mark

2015-04-06 Thread John Hendy
On Mon, Apr 6, 2015 at 3:16 PM, Daniel E. Doherty ded-...@ddoherty.net wrote:
 John,

 You nailed it.  I had that variable set in my custom file to

 '(org-blank-before-new-entry (quote ((heading) (plain-list-item . auto

 which is not a proper alist.  When I chaned it back to

 '(org-blank-before-new-entry (quote ((heading . auto) (plain-list-item . 
 auto

 the bad behavior went away.

 Thanks a ton for taking a look at this, John.  Back to loving org-mode!

Glad it worked! Thankfully it only took me a couple tries before
hitting the right variable. Plus, it was of interest as I've long
noticed this issue myself. Out of curiosity... *should* this work
without the =. auto=? It's been in my config so long I'm not really
even sure why I put it there, but from re-googling around I think it's
just an appearance/preference thing. Do you want your headlines
separated by a newline or not -- is that the gist?

If so, should this be glitching?

I've had other odd behavior where I'll fold the last headline and it's
last few characters will end up after the ellipsis and now wonder if
this was causing that as well.


Anyway, glad you're all set!
John



 On Mon, 06 Apr 2015 13:12:21 -0500,
 John Hendy jw.he...@gmail.com wrote:

 On Mon, Apr 6, 2015 at 12:05 PM, Daniel E. Doherty ded-...@ddoherty.net 
 wrote:
 
  I don't know when this started, but recently I've seen the following 
  annoying
  behavior from M-RET in org files.

 I have this on my main Org file and just assumed it was due to it
 being big and Org having a tough time keeping track of all the various
 blocks (src, example, etc.), properties, ids, and whatnot. I figured
 I'd messed up the syntax in there somewhere and would just have to
 deal with this quirky behavior.

 I think others have experienced this as well (e.g.
 http://lists.gnu.org/archive/html/emacs-orgmode/2010-09/msg00457.html).

 Can you try commenting out:

 #+begin_src .emacs
 ;;(setq org-blank-before-new-entry nil)
 #_end_src

 I copied my .emacs into a new config, started with emacs -Q, loaded
 that file, and then tried your original post's exercise, repeating
 after commenting out various lines in my own config file. We both had
 the above setting, and that turned out to fix it for me on your test
 file. Not sure if there's another interaction between your options vs.
 mine, though, so confirmation is needed.


 John

 
  I've tried tweaking a number of these settings with no luck.
 
  Any ideas about what is going wrong here?
 
  Dan Doherty
 
 




[O] Hiding blocked TODO items

2015-04-06 Thread Nikolaus Rath
Hello,

Is there a way to have TODO items blocking each other?

For example, if I have this document:

* TODO Pay water
  :PROPERTIES:
   :blocked-on: checks
  :END:
* TODO Pay electricity
  :PROPERTIES:
   :blocked-on: checks
  :END:
* TODO Get new checks
  :PROPERTIES:
   :id: checks
  :END:

Then I'd like the first two TODO items not to show up in the agenda
until the third one is DONE (but I don't much care if the items can be
manually switched to DONE or not).

I looked at org-depend.el but as far as I can tell, it only allows to
set up chains of dependencies, i.e. I could have Pay Water and Pay
electricity in state NEXT, and have a trigger in Get new checks that
would switch one, but not both, of the NEXT items to TODO.

Do I understand that correctly? Is there some other way to achieve what
I want?

Best,
-Nikolaus
-- 
GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F
Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

 »Time flies like an arrow, fruit flies like a Banana.«



Re: [O] Bug: Pressing TAB in table cell with CJK characters sometimes destroys proper column alignment [8.2.10 (8.2.10-dist @ /usr/share/emacs24/site-lisp/org-mode/)]

2015-04-06 Thread Eric Abrahamsen
Eugen Dueck eu...@tworks.co.jp writes:

 In a simple org-table like the following:

 |  |   |
 | 漢   |   |

 when pressing the TAB key in the bottom left cell, one space character
 is removed from that cell and the table thus looks like

 |  |   |
 | 漢  |   |

 Pressing TAB again in that cell removes another space character

 |  |   |
 | 漢 |   |

 I can repeat this until only one space remains between the Japanese
 character and the column separator to its right.

 When working on a table, navigating via TAB, over time all the CJK
 cells that I TABbed out of - or Shift-TABbed out of - get affected,
 messing up the overall table layout. Once I press C-c C-c, the
 formatting of the whole table gets restored, until my next TAB, but it
 would of course be nice if TABs didn't destroy it in the first place.

 Btw, org-table rocks and I use it all the time - and I hope to be able
 to use it with Japanese characters as well.

A while ago I spent some time making this work as well as possible for
double-width glyphs, but I also noticed that sometime recently it's gone
back to the old behavior. I can look into it again, but work is
encroaching and it might take me a little time...




Re: [O] Best practices to get reminders?

2015-04-06 Thread Jorge A. Alfaro-Murillo

Nikolaus Rath writes:

However, there's one thing where I feel lost. I don't expect to 
be editing my orgmode files on a daily basis (at least not yet), 
so how can I make sure that I don't miss an important deadline? 
It seems to me that it doesn't help much if instead of worrying 
to forget a deadline I now have to worry about forgetting to 
check my org-mode agenda... 

How do other people handle this? Is everyone else opening and 
working on their org files daily so that this becomes a 
non-issue?


You can put this after your org-agenda-files configuration in your 
.emacs:


#+BEGIN_SRC emacs-lisp
 (appt-activate 1)
 (org-agenda-to-appt)
#+END_SRC

Then you will be reminded of things in your org files, before the 
appointment time (I think 12 min is the default).


You could also add this, so that the appointments refresh and new 
get added every time that you call the agenda:


#+BEGIN_SRC emacs-lisp
 (add-hook 'org-agenda-finalize-hook (lambda () 
 (org-agenda-to-appt t)))

#+END_SRC

Best,
--
Jorge.




Re: [O] Best practices to get reminders?

2015-04-06 Thread Eric Abrahamsen
Nikolaus Rath nikol...@rath.org writes:

 Hello,

 I'm just starting to use org-mode. The first thing I'd like to use it
 for is to keep track of stuff that I need to do. Writing things up and
 calling up the agenda is easy enough, and I really like how-much
 functionality is available in what's essentially a plain text document.

 However, there's one thing where I feel lost. I don't expect to be
 editing my orgmode files on a daily basis (at least not yet), so how can
 I make sure that I don't miss an important deadline? It seems to me that
 it doesn't help much if instead of worrying to forget a deadline I now
 have to worry about forgetting to check my org-mode agenda...

 How do other people handle this? Is everyone else opening and working on
 their org files daily so that this becomes a non-issue?

At this point I have so much of my life (personal and professional) in
Org files that yes, checking the Agenda isn't an issue anymore. It's the
first thing I do in the morning, and the last thing I do before knocking
off at the end of the day.

If you're someone who restarts Emacs each morning, you could put a call
to `org-agenda' in your init file. The others have mentioned
`org-agenda-to-appt', but I find that if you're really using Org to
manage your time (checking where you are in the midst of longer
projects, clocking, surveying the week ahead, etc) then you'll want to
be looking at the Agenda every day.


Eric




[O] Best practices to get reminders?

2015-04-06 Thread Nikolaus Rath
Hello,

I'm just starting to use org-mode. The first thing I'd like to use it
for is to keep track of stuff that I need to do. Writing things up and
calling up the agenda is easy enough, and I really like how-much
functionality is available in what's essentially a plain text document.

However, there's one thing where I feel lost. I don't expect to be
editing my orgmode files on a daily basis (at least not yet), so how can
I make sure that I don't miss an important deadline? It seems to me that
it doesn't help much if instead of worrying to forget a deadline I now
have to worry about forgetting to check my org-mode agenda...

How do other people handle this? Is everyone else opening and working on
their org files daily so that this becomes a non-issue?


Best,
-Nikolaus
-- 
GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F
Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

 »Time flies like an arrow, fruit flies like a Banana.«



Re: [O] Best practices to get reminders?

2015-04-06 Thread Carlos Sosa
Nikolaus Rath nikol...@rath.org writes:

 How do other people handle this? Is everyone else opening and working on
 their org files daily so that this becomes a non-issue?

  Have you tried (org-agenda-to-appt) and (appt-activate t)?
  If you do end up using those functions, and you're using Emacs 24.x,
  checkout desktop notifications:
  
https://www.gnu.org/software/emacs/manual/html_node/elisp/Desktop-Notifications.html

  - Carlos




Re: [O] Best practices to get reminders?

2015-04-06 Thread Nikolaus Rath
On Apr 06 2015, jorge.alfaro-muri...@yale.edu (Jorge A. Alfaro-Murillo) wrote:
 Nikolaus Rath writes:

 However, there's one thing where I feel lost. I don't expect to 
 be editing my orgmode files on a daily basis (at least not yet), 
 so how can I make sure that I don't miss an important deadline? 
 It seems to me that it doesn't help much if instead of worrying 
 to forget a deadline I now have to worry about forgetting to 
 check my org-mode agenda... 
 
 How do other people handle this? Is everyone else opening and 
 working on their org files daily so that this becomes a 
 non-issue?

 You can put this after your org-agenda-files configuration in your 
 .emacs:

 #+BEGIN_SRC emacs-lisp
   (appt-activate 1)
   (org-agenda-to-appt)
 #+END_SRC
 Then you will be reminded of things in your org files, before the 
 appointment time (I think 12 min is the default).

Hmm. I tried it with this test-event:

* TODO Test task
  SCHEDULED: 2015-04-07 Tue

But running (org-agenda-to-appt) just gives No event to add.

Is this because there is no time specified? I'm not really concerned
with appointments that have a time span, but with projects that have
specific due dates...


Best,
-Nikolaus

-- 
GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F
Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

 »Time flies like an arrow, fruit flies like a Banana.«



Re: [O] Best practices to get reminders?

2015-04-06 Thread Nikolaus Rath
On Apr 06 2015, Carlos Sosa gnus...@gnusosa.net wrote:
 Nikolaus Rath nikol...@rath.org writes:

 How do other people handle this? Is everyone else opening and working on
 their org files daily so that this becomes a non-issue?

   Have you tried (org-agenda-to-appt) and (appt-activate t)?
   If you do end up using those functions, and you're using Emacs 24.x,
   checkout desktop notifications:
   
 https://www.gnu.org/software/emacs/manual/html_node/elisp/Desktop-Notifications.html

I am using Emacs 24, but I'm still not sure how how you are using
this. For example, if you'd like to get some reminder if a project is
due in 3 days, how exactly do you set things up?

Do you show the notification just once (but what if I'm not at the
screen what that happens)? Or do you show it periodically until I've
somehow told Emacs that I've seen it?

Thanks,
-Nikolaus
-- 
GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F
Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

 »Time flies like an arrow, fruit flies like a Banana.«



Re: [O] Best practices to get reminders?

2015-04-06 Thread Jorge A. Alfaro-Murillo

Nikolaus Rath writes:

On Apr 06 2015, jorge.alfaro-muri...@yale.edu (Jorge A. 
Alfaro-Murillo) wrote: 
Nikolaus Rath writes: 

However, there's one thing where I feel lost. I don't expect 
to  be editing my orgmode files on a daily basis (at least not 
yet),  so how can I make sure that I don't miss an important 
deadline?  It seems to me that it doesn't help much if instead 
of worrying  to forget a deadline I now have to worry about 
forgetting to  check my org-mode agenda...How do other 
people handle this? Is everyone else opening and  working on 
their org files daily so that this becomes a  non-issue? 


You can put this after your org-agenda-files configuration in 
your  .emacs: 

#+BEGIN_SRC emacs-lisp 
  (appt-activate 1) (org-agenda-to-appt) 
#+END_SRC Then you will be reminded of things in your org 
files, before the  appointment time (I think 12 min is the 
default). 


Hmm. I tried it with this test-event: 

* TODO Test task 
  SCHEDULED: 2015-04-07 Tue 

But running (org-agenda-to-appt) just gives No event to add. 


Is this because there is no time specified?


Yes.

I'm not really concerned with appointments that have a time 
span, but with projects that have specific due dates...


Well that is what the org agenda is for.

If you just can't remember to check the agenda every so often you 
could do something like (not tested):


#+BEGIN_SRC emacs-lisp
 (run-at-time t 120 'org-agenda-list)
#+END_SRC

To run the agenda every two hours automatically.

Best,

--
Jorge.




Re: [O] [PATCH] lisp/ob-sql.el: add support for :dbport parameter

2015-04-06 Thread Xavier Maillard

Saulius Menkevičius saulius.menkevic...@gmail.com writes:

 This (tiny) patch implements ability to set dbport for org-babel sql
 functionality. I often use ssh port forwarding to connect to remote
 mysql servers where port is mapped to non-standard one on local machine.

 This is my first patch, below the 15 line threshold.

Seems good AFAICS.

Do you often use orgmode, BABEL and sql all together ? (just curious
as I am a DBA in real life).

-- Xavier.



Re: [O] Define Keyboard Shortcut for Open in Emacs

2015-04-06 Thread Xavier Maillard

Jorge A. Alfaro-Murillo jorge.alfaro-muri...@yale.edu writes:

 Xavier Maillard writes:

 Thank you very much for these clarifications. Should I expect
 anything from xdg-* when not using a desktop environment at all?
 (I am using something home-brewed where I could add support for
 something like this but that's not for now).

 I am not sure. You could try xdg-open in any file from the
 terminal, to see if it works as expected

Lovely ! It just works.

-- Xavier.



[O] couldn't find this example in info org

2015-04-06 Thread Jude DaShiell
Spreadsheet section, couldn't find equivalent of (@..@) for when you 
have table coordinates that look like c4.  Does such an equivalent exist?


--
Twitter: JudeDaShiell




[O] pdf screen reader accessibility?

2015-04-06 Thread Jude DaShiell

http://www.adobe.com/accessibility/products.html
is a good place to start.
When a document gets written in Microsoft Word, its language is made part 
of that document.  If that document is later converted to a pdf file that 
language information is taken in by the conversion process then becomes 
the first component that starts to make screen reader accessibility of a 
pdf file possible.  Other components exist, but without that language 
attribute presence, screen reader accessibility is disabled.  Another 
major requirement is ocr scanned content pictures by themselves in pdf 
files are worthless to screen readers.  I'm using speakup over here on 
archlinux and am curious if it is now possible or some day will be 
possible for me to export to a screen reader accessible pdf file I can 
share with other screen reader users with no fear that the file won't be 
accessible.




-- Twitter: JudeDaShiell




[O] orgmode bug capture procedure

2015-04-06 Thread Jude DaShiell
With a linux command that is defective, I can run script and get me a 
typescript file to send to an author.  Is that my best bet for capturing 
an emacs-orgmode bug?



-- Twitter: JudeDaShiell




Re: [O] pdf screen reader accessibility?

2015-04-06 Thread Rasmus
Jude DaShiell jdash...@panix.com writes:

 http://www.adobe.com/accessibility/products.html
 is a good place to start.

It's a list of a bunch of software packages of which most are not (i) free
in any meaning of the word; and (ii) supported on GNU/Linux.

What is your point?

 When a document gets written in Microsoft Word, its language is made
 part of that document.  If that document is later converted to a pdf
 file that language information is taken in by the conversion process
 then becomes the first component that starts to make screen reader
 accessibility of a pdf file possible.

AFAIK, the language is set as part of the metadata in pdfs in 8.3 based
on #+LANGUAGE.  Can you test if that works for you?  If not, what will
needed to be changed to make it work?

—Rasmus

-- 
Send from my Emacs




Re: [O] pdf screen reader accessibility?

2015-04-06 Thread Rasmus
Marcin Borkowski mb...@wmi.amu.edu.pl writes:

 On 2015-04-06, at 13:40, Rasmus ras...@gmx.us wrote:

 Jude DaShiell jdash...@panix.com writes:

 http://www.adobe.com/accessibility/products.html
 is a good place to start.

 It's a list of a bunch of software packages of which most are not (i) free
 in any meaning of the word; and (ii) supported on GNU/Linux.

 So what?  IIUC, the OP wants to have something similar using Emacs and
 (maybe) free (in a usual sense, or in FSF sense) software.  Isn't it
 a valid request?

Of course it is, but OP is referring to features of some software that I
don't have access to, so how am I supposed to make sense of it?  I'm not
going to (i) install a new OS; and (ii) buy/torrent software to understand
and test a feature in named software.

If there's a standard I'm eager to hear about it.

 Maybe it's an answer to my question below?

 ,
 |  Do those files by default conform to screen reader accessibility 
 standards 
 |  or can such files be made to conform to screen reader accessibility 
 |  standards?  Since adobe was responsible for creating pdf files Adobe has 
 |  screen reader accessibility standards on its website.
 | 
 | Could you point out these standards (direct links)?
 `

 (No idea why the OP started a new thread, though.)  In my browser, on
 the right there are some links to general accessibility info (or so it
 seems, I didn't follow them yet).

Thanks.

 When a document gets written in Microsoft Word, its language is made
 part of that document.  If that document is later converted to a pdf
 file that language information is taken in by the conversion process
 then becomes the first component that starts to make screen reader
 accessibility of a pdf file possible.

 AFAIK, the language is set as part of the metadata in pdfs in 8.3 based
 on #+LANGUAGE.  Can you test if that works for you?  If not, what will
 needed to be changed to make it work?

 Quick test using

 #+LANGUAGE: polish

 or

 #+LANGUAGE: pl

 showed it didn't work.  (I didn't check the pdf file, though, only
 grepped the LaTeX source.)

Please give an example of how to specify the language, or an example of a
way to test it that can be done easily from GNU/Linux.

With emacs -q and Org 8.3, and a document with #+LANGUAGE: da I get:

 $ exiftool test.pdf | grep -i lang
 Language: Danish

—Rasmus

-- 
Send from my Emacs




Re: [O] pdf screen reader accessibility?

2015-04-06 Thread Marcin Borkowski

On 2015-04-06, at 13:40, Rasmus ras...@gmx.us wrote:

 Jude DaShiell jdash...@panix.com writes:

 http://www.adobe.com/accessibility/products.html
 is a good place to start.

 It's a list of a bunch of software packages of which most are not (i) free
 in any meaning of the word; and (ii) supported on GNU/Linux.

So what?  IIUC, the OP wants to have something similar using Emacs and
(maybe) free (in a usual sense, or in FSF sense) software.  Isn't it
a valid request?

 What is your point?

Maybe it's an answer to my question below?

,
|  Do those files by default conform to screen reader accessibility standards 
|  or can such files be made to conform to screen reader accessibility 
|  standards?  Since adobe was responsible for creating pdf files Adobe has 
|  screen reader accessibility standards on its website.
| 
| Could you point out these standards (direct links)?
`

(No idea why the OP started a new thread, though.)  In my browser, on
the right there are some links to general accessibility info (or so it
seems, I didn't follow them yet).

 When a document gets written in Microsoft Word, its language is made
 part of that document.  If that document is later converted to a pdf
 file that language information is taken in by the conversion process
 then becomes the first component that starts to make screen reader
 accessibility of a pdf file possible.

 AFAIK, the language is set as part of the metadata in pdfs in 8.3 based
 on #+LANGUAGE.  Can you test if that works for you?  If not, what will
 needed to be changed to make it work?

Quick test using

#+LANGUAGE: polish

or

#+LANGUAGE: pl

showed it didn't work.  (I didn't check the pdf file, though, only
grepped the LaTeX source.)

 —Rasmus

Best,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Faculty of Mathematics and Computer Science
Adam Mickiewicz University



Re: [O] Define Keyboard Shortcut for Open in Emacs

2015-04-06 Thread Jorge A. Alfaro-Murillo

Xavier Maillard writes:

Thank you very much for these clarifications. Should I expect 
anything from xdg-* when not using a desktop environment at all? 
(I am using something home-brewed where I could add support for 
something like this but that's not for now).


I am not sure. You could try xdg-open in any file from the 
terminal, to see if it works as expected



Also, can you share an emacsclient.desktop file ?


That is not a file, but how xdg identifies emacsclient. You can 
find more about it here: 
https://wiki.archlinux.org/index.php/Xdg-open


Best,

--
Jorge.




[O] Inserted Heading Starts on Prior Heading's Fold Mark

2015-04-06 Thread Daniel E . Doherty

I don't know when this started, but recently I've seen the following annoying
behavior from M-RET in org files.

Here is a minimal file to demonstrate what I'm seeing lately:

== demo.org ==
* First Header
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim
veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
commodo consequat. Duis aute irure dolor in reprehenderit in voluptate
velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
occaecat cupidatat non proident, sunt in culpa qui officia deserunt
mollit anim id est laborum.

* Second Header
===

When the headings are completely folded, I see the following, as expected:

== demo.org ==
 * First Header...
^* Second Header
===

With my cursor on the ^, I hit M-RET to insert a new heading between First
Header and Second Header, and I get the following:

===

When the headings are completely folded, I see the following, as expected:

== demo.org ==
 * First Header...* ^
 * Second Header
===

In other words, the new heading is being placed after the elipses for the
folded content of the first heading.

Naturally, I expect the following:

== demo.org ==
 * First Header...
 * ^
 * Second Header
===

I'm trying to determine if this is an odd intereaction from some of my
settings, or if it is a bug in the org code.

It does the same whether I have org-indent-mode toggled on or off.

Does anyone else see this behavior?

My emacs-version is:
GNU Emacs 24.4.1 (x86_64-unknown-linux-gnu, GTK+ Version 2.24.23) of 2014-10-28 
on micah

Here are the main org settings from my init file:

,[ init.el ]
| #+BEGIN_SRC emacs-lisp :tangle yes
|   (setq org-directory (expand-file-name ~/Dropbox/Projects/))
|   (setq org-agenda-files (concat org-directory agenda-files))
|   (setq
|  org-attach-directory user-data-dir
|  org-agenda-include-diary t
|  org-agenda-span 3
|  org-todo-keywords '((sequence TODO(t) WAIT(w) | DONE(d) 
CNCL(x)))
|  org-todo-interpretation 'sequence
|  org-return-follows-link t
|  org-cycle-separator-lines 2
|  org-completion-use-ido t
|  org-refile-use-outline-path 'file
|  org-outline-path-complete-in-steps nil
|  org-refile-allow-creating-parent-nodes t)
| #+END_SRC
`

And here is what I have set in my custom.el files:

,[ custom.el ]
| #+BEGIN_SRC emacs-lisp
|  '(org-agenda-span (quote day))
|  '(org-blank-before-new-entry (quote ((heading) (plain-list-item . auto
|  '(org-confirm-babel-evaluate nil)
|  '(org-entities-ascii-explanatory t)
|  '(org-export-babel-evaluate nil)
|  '(org-file-apps
|(quote
| ((auto-mode . emacs)
|  (\\.mm\\' . default)
|  (\\.x?html?\\' . default)
|  (\\.pdf\\' . default)
|  (ods . oocalc
|  '(org-footnote-fill-after-inline-note-extraction t)
|  '(org-format-latex-options
|(quote
| (:foreground OliveDrab :background default :scale 1.2 :html-foreground 
Black :html-background Transparent :html-scale 1.0 :matchers
|  (begin $1 $ $$ \\( \\[
|  '(org-highlight-latex-and-related (quote (latex)))
|  '(org-icalendar-include-todo t)
|  '(org-icalendar-use-plain-timestamp t)
|  '(org-latex-pdf-process
|(quote
| (/usr/bin/pdflatex -interaction nonstopmode -output-directory %o %f 
/usr/bin/pdflatex -interaction nonstopmode -output-directory %o %f 
/usr/bin/pdflatex -interaction nonstopmode -output-directory %o %f)))
|  '(org-list-demote-modify-bullet (quote ((+ . -) (- . *) (* . 
+
|  '(org-list-indent-offset 2)
|  '(org-log-refile (quote time))
|  '(org-modules
|(quote
| (org-bbdb org-bibtex org-docview org-gnus org-info org-irc org-protocol 
org-vm org-wl org-w3m)))
|  '(org-outline-path-complete-in-steps nil)
|  '(org-pretty-entities-include-sub-superscripts nil)
|  '(org-refile-targets (quote ((org-agenda-files :maxlevel . 1
|  '(org-refile-use-outline-path (quote file))
|  '(org-special-ctrl-a/e t)
|  '(org-special-ctrl-k t)
|  '(org-src-fontify-natively t)
|  '(org-src-tab-acts-natively t)
|  '(org-startup-align-all-tables t)
|  '(org-startup-folded t)
|  '(org-table-number-regexp
|^\\([]?\\(\\$ 
*\\)?[-+^.,0-9]*[0-9][-+^.0-9eEdDx()%:]*\\|\\(0[xX]\\)[0-9a-fA-F]+\\|nan\\)$)
|  '(org-time-stamp-custom-formats (quote (%b %d, %Y (%a) . %b %d, %Y 
(%a) @ %H:%M)))
| #+END_SRC
`

I've tried tweaking a number of these