[Orgmode][babel] How-to realise a simplified usage scenario?
Hi, I tried to use org-babel (particular with python) several times. However, I always struggled with the amount of options and it take me long time to get it right. I would like to describe my personal perfect scenario and hope that some of those points could find a way into babel. Basically, I would like to use org-babel for some kind of literate programming. It has not to produce publishing ready manuscripts (maybe, this might be a final goal). Basically, I would like to keep my more technically notes together with my calculations. Basically I want something like this Example-- * My problem This is my problem description and I might use all kind of org-madness to describe it, add todos, deadlines, tag it, add tables and links, etc. At the beginning I might call some initialisation code #+begin_src sessionname #!/usr/bin/env python #import modules import numpy as py from myreadfile import * # global variables constant1 = 5 loaddata("data") y=5 #+end_src After even more org-mode text, I come to the point to do some calculus #+begin_src sessionname :export def myfunction(x=1): # x is a parameter c1 = 1e-4 c2 = 3 c3 = 1e6 b = 3 return c1*x**3+c2*x**2+c3*x**x+b #+end_src I just continue writing to say what I just did. Now I want to state that myfunction result in <>. Which gives me the return value of myfunction for x = 10 and formats it into scientific notation. I also could write <> which would be replaced by the standard integer representation 5. Sure I could write <> as well to get the result of my function for the variable y which I defined in the first code block. I could even create a new variable on the fly <> print it z= <> and show the result for myfunction: <>. I could even switch to another language (however, I doubt that this is often the case). Either by direct replacement and taking care of the formatting manually #+begin_src elisp_session #!/usr/bin/emacs --script (setq a 3) (setq b <>) (message "%+3.5f" (* a b)) #+end_src or (esp. for more complex inputs) by additional use of helper functions defined for the target language #+begin_src elisp_session #!/usr/bin/emacs --script (setq a 3) (setq b (<>)) (message "%+3.5f" (* a b)) #+end_src which would take care to place it in the source code block with the correct target syntax. End Example--- The key-points are: * All code blocks belong to a session to allow sharing namespace * The entire code is still written in a way to execute it "stand-alone" if tangled, the tangle operation could replace var_sessionname commands by appropriate print commands in the target language. Functions are real valid functions of the target language. * no need to specify the language over and over again since it can be found by reading the shebang for each session * var_sessionname commands define were to place output of the target language and how to format it. Formatting and output could be realized in the native target language which then returns an appropriate raw-orgmode string. This would even allow complex scenarios like embedding a plot created in the target language without the need for the user to know about that. * C-c C-c somewhere in a code block refresh the entire session. Honestly, I had to much problems with python errors due to old running sessions which were only partially updated and a confused python interpreter. Keep it simple, close any old session, open a new, rerun the code. If source code gets to long and computation takes to much time people might consider to split it into different sessions. * Tangeling the code could be a org-export function with options to save it in a file, open it in a buffer or execute it e.g., in ipython In a similar way like for other exports C-c C-e 1 c (c for code export) would tangle only the session to which the code under the pointer belongs and C-c C-e c exports all sessions in different buffers, etc. * Parts of the source code blocks which should appear in export are simply marked :export all other will not be exported no resuls will be exported unlike they are explicit called via the var_sessioname command. I'm aware that babel can do some of the above points already. However, at least for python is is still very rough sometimes. I like babel and I really would like to express my grateful thanks to the developers but I really have a hard time to use it and would like to see some more simplified usage. Hope I have hit a few good points... Torsten ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Bug: Missing prompt label in capture template expansion
Remember to cover the basics, that is, what you expected to happen and what in fact did happen. You don't know how to make a good report? See http://orgmode.org/manual/Feedback.html#Feedback Your bug report will be posted to the Org-mode mailing list. STEPS TO REPRODUCE: 1. Add this to the list of capture templates: ("t" "Test" entry (file "z:/Temp/t.org") "*** TODO %^{Foo} [[bar:%^{Bar}][Bar]]") 2. Run org-capture. 3. Fill in a value for “Foo” when prompted and press Enter. EXPECTED RESULTS: Prompted for second value, with label “Bar”. ACTUAL RESULTS: Prompted for second value, with label “ ” (single space). NOTES: I tried this using org-mode from git (commit id: b23d35de06c229db84472d893c8645c63896a6cd) after starting Emacs with ‘emacs -Q’ to ensure there was no interference. A couple of variations on the template above work fine, correctly showing the label when prompting for a value: * No prompts before the one in the link: ("t" "Test" entry (file "z:/Temp/t.org") "*** TODO [[bar:%^{Bar}][Bar]]") * No link description: ("t" "Test" entry (file "z:/Temp/t.org") "*** TODO [[bar:%^{Bar}][Bar]]") Config follows… Emacs : GNU Emacs 24.0.50.1 (i386-mingw-nt6.1.7601) of 2010-11-10 on SHAN-PC Package: Org-mode version 7.4 current state: == (setq org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars) org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-metaup-hook '(org-babel-load-in-session-maybe) org-capture-templates '(("t" "Test" entry (file "z:/Temp/t.org" "Media") "*** TODO %^{Foo} [[bar:%^{Bar}][Bar]]") ) org-after-todo-state-change-hook '(org-clock-out-if-current) org-export-blocks-postblock-hook '(org-exp-res/src-name-cleanup) org-export-latex-format-toc-function 'org-export-latex-format-toc-default org-tab-first-hook '(org-hide-block-toggle-maybe org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe) org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-confirm-shell-link-function 'yes-or-no-p org-export-first-hook '(org-beamer-initialize-open-trackers) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-babel-pre-tangle-hook '(save-buffer) org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-export-preprocess-before-normalizing-links-hook '(org-remove-file-link-modifiers) org-mode-hook '(#[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-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe) org-confirm-elisp-link-function 'yes-or-no-p org-export-interblocks '((lob org-babel-exp-lob-one-liners) (src org-babel-exp-inline-src-blocks)) org-occur-hook '(org-first-headline-recenter) org-export-preprocess-before-selecting-backend-code-hook '(org-beamer-select-beamer-code) org-export-latex-final-hook '(org-beamer-amend-header org-beamer-fix-toc org-beamer-auto-fragile-frames org-beamer-place-default-actions-for-lists) org-metadown-hook '(org-babel-pop-to-session-maybe) org-export-blocks '((src org-babel-exp-src-block nil) (comment org-export-blocks-format-comment t) (ditaa org-export-blocks-format-ditaa nil) (dot org-export-blocks-format-dot nil)) ) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Uncover bullet points with BEAMER_env: ignoreheading
I've been using BEAMER_env: ignoreheading to generate columns of bulleted lists as follows #+begin_src org * hidden heading 1:BMCOL:B_ignoreheading: :PROPERTIES: :BEAMER_col: 0.5 :BEAMER_env: ignoreheading :BEAMER_envargs: [<+->] :END: ** Item 1 ** Item 2 * hidden heading 2:BMCOL:B_ignoreheading: :PROPERTIES: :BEAMER_col: 0.5 :BEAMER_env: ignoreheading :BEAMER_envargs: [<+->] :END: ** Item 3 ** Item 4 #+begin_src org But the "[<+->]" is not included in the LaTeX export so the bullets are not revealed sequentially. Is there a way to include this flag in the export? Thanks, Derek Thomas ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] org-toggle-checkbox bug
Matt Lundin wrote: > According to the docstring of org-toggle-checkbox, the function can be > called on headlines: > > , > | If the cursor is in a headline, apply this to all checkbox items > | in the text below the heading, taking as reference the first item > | in subtree, ignoring drawers. > ` > > When I call org-toggle-checkbox on the following entry... > > --8<---cut here---start->8--- > * Test > - [ ] Now > - [ ] Not now > - [ ] Later > - Not yet > - Never > --8<---cut here---end--->8--- > > ...I get the following results... > > --8<---cut here---start->8--- > * Test > - [ ] Now > - [X] Not now > - [X] Later > - Not yet > - Never > --8<---cut here---end--->8--- > > Then if I call org-toggle-checkbox on the headline again, nothing > happens. The two boxes remain checked. > Try this patch: diff --git a/lisp/org-list.el b/lisp/org-list.el index f66c665..1449062 100644 --- a/lisp/org-list.el +++ b/lisp/org-list.el @@ -2134,7 +2134,7 @@ in subtree, ignoring drawers." (bottom (copy-marker (org-list-get-bottom-point struct))) (items-to-toggle (org-remove-if (lambda (e) (or (< e lim-up) (> e lim-down))) -(mapcar 'car (cdr struct) +(mapcar 'car struct (mapc (lambda (e) (org-list-set-checkbox e struct ;; if there is no box at item, leave as-is Nick ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Org-Remember C-1 C-c C-c
Whenever I use Remember to shoot a note to a specific location I press C-1 and get the following error: M-[ 1 ; 5 q is undefined I changed my .emacs to make the default refiling and C-1 C-c C-c is now the template location specified. At times I would still like to use the C-1 C-c C-c behavior. I thought about setting a 1 press function key binding but I haven't been able to determine what function is called (either direction depending on the setup I have in my .emacs) and I haven't been able to figure out what is causing the error when i press C-1 (it happens whenever I press the key combo). I am using cygwin in mintty, with emacs and orgmode 7.4 (I pull off the git every few days, don't remember which exact commit I have). GNU Emacs 23.2.1 (i686-pc-cygwin, GTK+ Version 2.20.1) of 2010-10-01 This happened even before I upgraded from the version of orgmode that comes with emacs 23.2.1 I am just not sure which direction to go to find the problem and I know how to work around it by calling the correct function and/or binding it to a key. Any input is most appreciated as the more college classes I take the more class files I have to file into. Matthew Sauer ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] org-toggle-checkbox bug
John Hendy wrote: > On Thu, Feb 24, 2011 at 5:52 PM, Matt Lundin wrote: > > According to the docstring of org-toggle-checkbox, the function can be > called on headlines: > > , > | If the cursor is in a headline, apply this to all checkbox items > | in the text below the heading, taking as reference the first item > | in subtree, ignoring drawers. > ` > > When I call org-toggle-checkbox on the following entry, [I get (shortened > from your example)]: > > --8<---cut here---start->8--- > * Test > - [ ] Now > - [ ] Not now ---> [x] > - [ ] Later ---> [x] > - Not yet > - Never > --8<---cut here---end--->8--- > > Then if I call org-toggle-checkbox on the headline again, nothing > happens. The two boxes remain checked. > > Odd; this is not the behavior I get. I just tried on a structure and got this > cycling: > ,- > | * top > | ** next > | *** next > | - [x] item 1 --> [ ] --> [x] > | - [ ] item 2 --> [ ] --> [x] > | - [ ] item 3 --> [ ] --> [x] > | - [ ] item 4 --> [ ] --> [x] > `- > > So... it seems to be working for me, though I was not sure based on the > docstring whether "taking as reference the first item in subtree" meant it > would toggle the rest to be like it or everything to be the opposite of it. > It appears it's the latter definition. > > Maybe provide your version? I'm using 7.4. > Not working for me: I can reproduce the behavior that Matt reported. Org-mode version 7.4 (release_7.4.529.gb23d.dirty) Nick ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Grouping clock report by tag?
Hi, I just decided to try to start clocking tasks and would find it most helpful to organize by tag, not file. Perhaps my filing system is unorthodox, but I originally started using an org file per work project but just found it cumbersome when it came to recording my notes since I'd be switching back and forth between many files. I suppose I could have used capture for this, but I think my current system makes more sense. It is to use one file per month and the format is like so: ,- | ~/org/2011-02Feb.org | --- | * [2011-02-04 Fri]... | * [2011-02-08 Tue]... | * [2011-02-22 Tue]... | ** Description of something I did :project-name: | CLOCK: [whatever]--[whatever] | Notes | ** Something else I did this day:other-project: | CLOCK: [whatever]--[whatever] | Notes `- Hopefully that's clear. I like this method as it keeps file sizes down and just seems more organized than how I was before. In any case, I realize that I can setup clock reports with something like =:tags "project-name"= to get a report for a particular tag. That can at least give me per-project reports for a given timeframe, but I wouldn't mind the ability to have something that shows all my time but includes tags somehow. Perhaps it would display the headline (which is actually nice since my top headlines are the dates), then the sub-item (which would be helpful because it would be a description of what I was doing), but somehow give a summary of time-per-tag or a column that lists the tag for teach task as well? Is this possible? That would be great as I'd be able to get a snapshot of how I spent my day per project. Again.. manually, this is possible as I can create a "clockreport.org" file with a headline per project with a specific =:tag "project-name"= argument and then I could add up times and compare them from there. Though perhaps there's a better way to get something like this as well? Thanks for any thoughts or even sharing how you use clocking when it comes to analyzing the data afterward. Best regards, Joh ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Re: [Accepted] Re: Bug: Jumping to a date in the agenda changes view back to 'day' [7.4 (release_7.4.80.g0e5e5)]
Hi Matt, Bastien writes: > I'm not able to reproduce your problem with emacs -q and the minimal > configuration you proposed. Can I ask you to check again? Forget my message - I *can* reproduce your issue, I will investigate this tomorrow. Thanks for your patience, -- Bastien ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: [Accepted] Re: Bug: Jumping to a date in the agenda changes view back to 'day' [7.4 (release_7.4.80.g0e5e5)]
Hi Matt, Matt Lundin writes: > Matt Lundin writes: >> >> Has there been any progress on this issue? I am finding that the local >> span bindings in the custom command above still do not have any effect. >> My default agenda span is a day. If I call the custom command above, it >> displays only one day, despite the local setting. > > I think I know what's happening. The custom agenda commands had been > working properly until this commit on Feb 18, which brought back the > behavior described above: > > c6dbde1babaa0b2efa278d75a6ec82f91ef59d5e This commit should have fixed the issue - not brought it back :/ I'm not able to reproduce your problem with emacs -q and the minimal configuration you proposed. Can I ask you to check again? Thanks, -- Bastien ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] org-toggle-checkbox bug
On Thu, Feb 24, 2011 at 5:52 PM, Matt Lundin wrote: > According to the docstring of org-toggle-checkbox, the function can be > called on headlines: > > , > | If the cursor is in a headline, apply this to all checkbox items > | in the text below the heading, taking as reference the first item > | in subtree, ignoring drawers. > ` > > When I call org-toggle-checkbox on the following entry, [I get (shortened > from your example)]: > > --8<---cut here---start->8--- > * Test > - [ ] Now > - [ ] Not now ---> [x] > - [ ] Later ---> [x] > - Not yet > - Never > --8<---cut here---end--->8--- > > Then if I call org-toggle-checkbox on the headline again, nothing > happens. The two boxes remain checked. > > Odd; this is not the behavior I get. I just tried on a structure and got this cycling: ,- | * top | ** next | *** next | - [x] item 1 --> [ ] --> [x] | - [ ] item 2 --> [ ] --> [x] | - [ ] item 3 --> [ ] --> [x] | - [ ] item 4 --> [ ] --> [x] `- So... it seems to be working for me, though I was not sure based on the docstring whether "taking as reference the first item in subtree" meant it would toggle the rest to be like it or everything to be the opposite of it. It appears it's the latter definition. Maybe provide your version? I'm using 7.4. Best, > Matt > > ___ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode > ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Capture question
Hi, I'm trying to setup capture for the first time and am getting some odd behavior. I've been following the manual and my .emacs has this: ,- | ;; capture | (setq org-default-notes-file (concat org-directory "~/org/2011-02Feb.org" "Tracking")) | (global-set-key "\C-cc" 'org-capture) | (setq org-capture-templates | '(("t" "todo" entry (file+headline "~/org/2011-02Feb.org" "Tracking") | "* TODO %?\n"))) | (define-key global-map "\C-c c" | (lambda () (interactive) (org-capture "t"))) `- My questions/issues: 1) The biggest is that when I capture and then use C-c C-c to file it, I'm getting odd headline behavior. My file structure is like so: ,- | ~/org/2011-02Feb.org `- | #+ setupfile: ~/path/to/setupfile.org | * Tracking | ** TODO stuff | ** TODO more stuff | ** TODO even more stuff | * [date] | ** Notes | * [date] | ** Notes `- In other words, I have a file per month and one headline per day with my work notes. When I use capture, I get this when I visit the file next: ,- | * Tracking | ** TODO stuff | ** TODO more stuff | ** TODO even more stuff | ** TODO the captured note...* [date] | ... `- So it's like the captured note gets inserted before a different headline for some reason. I can't expand the captured TODO, but if I highlight the date and expand it, then it rights itself and the * [date] that's appended to the captured TODO goes back to being a first level headline and the capture TODO is on a line by itself. Why might this be happening? 2) The manual suggests some methods of automatically setting the capture target when using templates. My files are always "year-##Month.org" (like 2011-02Feb.org). Could I set this somehow to automatically cycle based on the date? I don't know what "handles" I have at my disposal with eslisp to do something like that. 3) The manual suggestion of using: ,- | (define-key global-map "\C-c c" | (lambda () (interactive) (org-capture "t"))) `- does not seem to be working. I still have to pick [t] when the capture template window pops up. I won't really use capture for anything else besides refilling todos and starting a clock since I only am ever using one file rather (since it's time based note-taking vs. having a file per project/customer/etc.). As this is the case, yes, I would love if C-c c automatically just brought up the TODO template I have defined above. Many thanks, John ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] org-toggle-checkbox bug
According to the docstring of org-toggle-checkbox, the function can be called on headlines: , | If the cursor is in a headline, apply this to all checkbox items | in the text below the heading, taking as reference the first item | in subtree, ignoring drawers. ` When I call org-toggle-checkbox on the following entry... --8<---cut here---start->8--- * Test - [ ] Now - [ ] Not now - [ ] Later - Not yet - Never --8<---cut here---end--->8--- ...I get the following results... --8<---cut here---start->8--- * Test - [ ] Now - [X] Not now - [X] Later - Not yet - Never --8<---cut here---end--->8--- Then if I call org-toggle-checkbox on the headline again, nothing happens. The two boxes remain checked. Best, Matt ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Note buffer killed unexpectedly
Raymond Zeitler wrote: > After typing a note, I pressed C-u C-c C-c and unintentionally killed the > buffer without saving the note. I should've pressed C-c C-c, but I'm so > used to pressing C-u C-c C-c to refile each new task, that I used that key > combination instead. > > Why would adding a prefix argument to C-c C-c kill *Org Note*? > It seems it's by design: org-store-log-note() contains the following code: ... (when (or current-prefix-arg org-note-abort) (when org-log-into-drawer (org-remove-empty-drawer-at (if (stringp org-log-into-drawer) org-log-into-drawer "LOGBOOK") org-log-note-marker)) (setq lines nil)) so current-prefix-arg causes lines to be set to nil, and the note is just thrown away. > In general I'm nervous about using scratch buffers such as *Org Note* for > anything I wish to save. Is there an option to auto-save its contents to a > visited file called something like ~/#Org Note#? Or can I add a > confirmation before I close the buffer? Perhaps if I modified > org-add-log-note to somehow change the call to > (org-switch-to-buffer-other-window "Org Note")...? > You can try getting rid of the current-prefix-arg and see if you get into other problems, but only Carsten can say why it is that way to begin with. Nick PS. I did some git archaelogy: commit 3d2e1c0f04c4bb3eaeb2627d00c8cba6e376f8eb modified things a bit in this part of the code, but the current-prefix-arg behavior predated it. The earliest commits I found were commit 2b3fe71634d8afb7e5e6da7606223e82481f0fa8 which added the capability to add a note interactively and also remotely from the agenda, and commit fe939ecb95d36377162bf1cb9ce63c2b6047612b which was a massive structure cleanup/reorg with no substantive code changes, but I think the org-store-log-note() function existed before the git era. ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Note buffer killed unexpectedly
After typing a note, I pressed C-u C-c C-c and unintentionally killed the buffer without saving the note. I should've pressed C-c C-c, but I'm so used to pressing C-u C-c C-c to refile each new task, that I used that key combination instead. Why would adding a prefix argument to C-c C-c kill *Org Note*? In general I'm nervous about using scratch buffers such as *Org Note* for anything I wish to save. Is there an option to auto-save its contents to a visited file called something like ~/#Org Note#? Or can I add a confirmation before I close the buffer? Perhaps if I modified org-add-log-note to somehow change the call to (org-switch-to-buffer-other-window "Org Note")...? BTW, org-version is set to "TAG=7.01g" -- I haven't upgraded in a few months. FWIW, my customizations are on emacswiki: http://www.emacswiki.org/emacs/RaymondZeitler TIA for any helpful advice you can give on the matter. -- Raymond Zeitler ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] [PATCH] new babel latex feature :imagemagick
Andreas Leha writes: > Hi all, > > Just a small patch that might make life easier for > LaTeX (and esp. tikz) users. It enables the output of graphics in a > lot of formats using imagemagick. See below for an example. [...] This seems to work rather well. I tried the following: #+begin_src org * tikz with image magick The following is a simple figure generated using tikz: #+begin_src latex :exports results :results (if (and (boundp 'backend) (eq backend 'latex)) "latex" "file") :file test.png :imagemagick yes :iminoptions -density 600 :imoutoptions -geometry 400 :fit yes :noweb yes :headers '("\\usepackage{tikz}") \begin{tikzpicture} \node[red!50!black] (a) {A}; \node (b) [right of=a] {B}; \draw[->] (a) -- (b); \end{tikzpicture} #+end_src #+end_src and I get native tikz in the latex output and a png in the html output. very nice! I haven't done exhaustive testing so I don't know if the patch breaks anything, mind you. Thanks, eric -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.4 (release_7.4.529.gb23d.dirty) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] bug: invalid export key in export visible region
The following commands error out, seeming to say that the keys are wrong. c-c c-e v H c-c c-e v R Emacs 22, latest org git master. Thanks. Samuel -- The Kafka Pandemic: http://thekafkapandemic.blogspot.com/2010/12/welcome-to-kafka-pandemic-two-forces_9182.html I support the Whittemore-Peterson Institute (WPI) === I want to see the original (pre-hold) Lo et al. 2010 NIH/FDA/Harvard MLV paper. ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [babel] Bug? :cache yes ignored when :noweb yes
Hi all, When ':noweb yes' is in the header, ':cache yes' is ignored during export. (At least when I export the sample file below.) To me this seems to be a bug. Or am I missing something? Regards, Andreas PS: Example: * Test #+srcname: test_sleep #+begin_src R :session :exports code Sys.sleep(time=5) 1:10 #+end_src #+srcname: test_sleep #+begin_src R :session :exports results :noweb yes :cache yes <> #+end_src #+results[e2c9e6c2f84563b590a765502057d92463e50182]: test_sleep | 1 | | 2 | | 3 | | 4 | | 5 | | 6 | | 7 | | 8 | | 9 | | 10 | == smime.p7s Description: S/MIME Cryptographic Signature ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] question about indirect buffers for capture and line-breaks
On my aquamacs, (auto-fill-mode nil) seems to toggle the mode, whereas (auto-fill-mode -1) seems to always disable it. In any case, that seems to have fixed it. Thanks! Cheers. Fil On 24 February 2011 11:09, Jeff Horn wrote: > Yep. > > Evaluate the following two lines in the scratch buffer: > >(auto-fill-mode -1) >(auto-fill-mode nil) > > The first returns nil every time. The second returns true every time. > Funky. > > On Thu, Feb 24, 2011 at 11:07 AM, Jeff Horn wrote: > > What happens if you use (auto-fill-mode -1) intead? > > > > ,[ C-h f auto-fill-mode RET ] > > | auto-fill-mode is an interactive compiled Lisp function in > > | `simple.el'. > > | > > | (auto-fill-mode &optional ARG) > > | > > | Toggle Auto Fill mode. > > | With ARG, turn Auto Fill mode on if and only if ARG is positive. > > | In Auto Fill mode, inserting a space at a column beyond > `current-fill-column' > > | automatically breaks the line at a previous space. > > | > > | The value of `normal-auto-fill-function' specifies the function to use > > | for `auto-fill-function' when turning Auto Fill mode on. > > ` > > > > I think "nil" counts as a positive number. Maybe that's a bug? I dunno. > > > > On Thu, Feb 24, 2011 at 7:33 AM, Filippo A. Salustri > > wrote: > >> Hi, > >> I've turned off hard line breaks for various reasons. I do it like > this: > >>> > >>> (add-hook 'org-mode-hook > >>> '(lambda () > >>> (auto-fill-mode nil) > >>> (visual-line-mode t))) > >> > >> However, in the indirect buffers used by capture, hard line breaks are > still > >> in place. > >> I've looked, but can't find an explanation of how to control this. > >> Can anyone advise me? > >> Cheers. > >> Fil > >> > >> -- > >> Filippo A. Salustri, Ph.D., P.Eng. > >> Mechanical and Industrial Engineering > >> Ryerson University > >> 350 Victoria St, Toronto, ON > >> M5B 2K3, Canada > >> Tel: 416/979-5000 ext 7749 > >> Fax: 416/979-5265 > >> Email: salus...@ryerson.ca > >> http://deseng.ryerson.ca/~fil/ > >> > >> ___ > >> Emacs-orgmode mailing list > >> Please use `Reply All' to send replies to the list. > >> Emacs-orgmode@gnu.org > >> http://lists.gnu.org/mailman/listinfo/emacs-orgmode > >> > >> > > > > > > > > -- > > Jeffrey Horn > > http://www.failuretorefrain.com/jeff/ > > > > > > -- > Jeffrey Horn > http://www.failuretorefrain.com/jeff/ > -- Filippo A. Salustri, Ph.D., P.Eng. Mechanical and Industrial Engineering Ryerson University 350 Victoria St, Toronto, ON M5B 2K3, Canada Tel: 416/979-5000 ext 7749 Fax: 416/979-5265 Email: salus...@ryerson.ca http://deseng.ryerson.ca/~fil/ ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Org-mode tutorial in Hungarian
The Hungarian version of David O'Toole's tutorial is avilable at http://deneb.iszt.hu/~pasztor/orgtutorial/notebook/orgtutorial-hu.html The org and pdf versions are also available at: http://deneb.iszt.hu/~pasztor/orgtutorial/notebook/ Cheers, Miklós -- signature.asc Description: Digital signature ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [PATCH] new babel latex feature :imagemagick
Hi all, Just a small patch that might make life easier for LaTeX (and esp. tikz) users. It enables the output of graphics in a lot of formats using imagemagick. See below for an example. This is my first patch, I have never programmed emacs lisp before, and my common lisp experiences have been short and a while ago. So please excuse a (possibly) bad patch. Details: LaTeX source blocks now have three new options: - :imagemagick When not nil the source block is processed to pdf and the pdf is converted with imagemagick to whatever is given as :file Thus, the format is not limited to png. - :iminoptions This is passed to imagemagick before the pdf file - :imoutoptions This is passed to imagemagick before the output file Small Example: #+begin_src latex ... :file test.jpg :imagemagick yes :iminoptions -density 300 :imoutoptions -geometry 400 ... will use this command for conversion: convert -density 300 -geometry 400 test.jpg Full example: Export this to pdf and to html to see the effect. === * Test #+begin_src R :session :exports both :results silent library("tikzDevice") #+end_src #+srcname: test_plot #+begin_src R :session :exports code :results output latex tikz(console=TRUE, width=4, height=4) plot(rnorm(100), rnorm(100)) dummy <- dev.off() #+end_src #+srcname: test_plot_png #+begin_src latex :exports (if (and (boundp 'backend) (eq backend 'latex)) "none" "results") :file test.png :imagemagick yes :iminoptions -density 600 :imoutoptions -geometry 400 :fit yes :noweb yes :headers '("\\usepackage{tikz}") <> #+end_src #+srcname: test_plot_tikz #+begin_src latex :noweb yes <> #+end_src * Latex Options :noexport: #+LATEX_HEADER: \usepackage{tikz} === Regards, Andreas diff --git a/lisp/ob-latex.el b/lisp/ob-latex.el index 8943ded..6152ad3 100644 --- a/lisp/ob-latex.el +++ b/lisp/ob-latex.el @@ -72,6 +72,10 @@ This function is called by `org-babel-execute-src-block'." (let* ((out-file (cdr (assoc :file params))) (tex-file (org-babel-temp-file "latex-" ".tex")) (border (cdr (assoc :border params))) + (imagemagick (cdr (assoc :imagemagick params))) + (im-in-options (cdr (assoc :iminoptions params))) + (im-out-options (cdr (assoc :imoutoptions params))) + (pdfpng (cdr (assoc :pdfpng params))) (fit (or (cdr (assoc :fit params)) border)) (height (and fit (cdr (assoc :pdfheight params (width (and fit (cdr (assoc :pdfwidth params @@ -81,10 +85,10 @@ This function is called by `org-babel-execute-src-block'." (append (cdr (assoc :packages params)) org-export-latex-packages-alist))) (cond - ((string-match "\\.png$" out-file) + ((and (string-match "\\.png$" out-file) (not imagemagick)) (org-create-formula-image body out-file org-format-latex-options in-buffer)) - ((string-match "\\.pdf$" out-file) + ((or (string-match "\\.pdf$" out-file) imagemagick) (require 'org-latex) (with-temp-file tex-file (insert @@ -118,13 +122,26 @@ This function is called by `org-babel-execute-src-block'." (concat "\n\\begin{document}\n" body "\n\\end{document}\n"))) (org-export-latex-fix-inputenc)) (when (file-exists-p out-file) (delete-file out-file)) - (rename-file (org-babel-latex-tex-to-pdf tex-file) out-file)) + (let* ((transient-pdf-file (org-babel-latex-tex-to-pdf tex-file))) + (cond + ((string-match "\\.pdf$" out-file) + (rename-file transient-pdf-file out-file)) + (imagemagick + (convert-pdf transient-pdf-file out-file im-in-options im-out-options) + (when (file-exists-p transient-pdf-file) (delete-file transient-pdf-file)) ((string-match "\\.\\([^\\.]+\\)$" out-file) - (error "can not create %s files, please specify a .png or .pdf file" + (error "can not create %s files, please specify a .png or .pdf file or try the :imagemagick header arguement" (match-string 1 out-file nil) ;; signal that output has already been written to file body)) + +(defun convert-pdf (pdffile out-file im-in-options im-out-options) + "Generate a file from a pdf file using imagemagick." + (let* ((cmd (concat "convert " im-in-options " " pdffile " " im-out-options " " out-file))) +(message (concat "Converting pdffile file " cmd "...")) +(shell-command cmd))) + (defun org-babel-latex-tex-to-pdf (file) "Generate a pdf file according to the contents FILE. Extracted from `org-export-as-pdf' in org-latex.el." smime.p7s Description: S/MIME Cryptographic Signature ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] question about indirect buffers for capture and line-breaks
Yep. Evaluate the following two lines in the scratch buffer: (auto-fill-mode -1) (auto-fill-mode nil) The first returns nil every time. The second returns true every time. Funky. On Thu, Feb 24, 2011 at 11:07 AM, Jeff Horn wrote: > What happens if you use (auto-fill-mode -1) intead? > > ,[ C-h f auto-fill-mode RET ] > | auto-fill-mode is an interactive compiled Lisp function in > | `simple.el'. > | > | (auto-fill-mode &optional ARG) > | > | Toggle Auto Fill mode. > | With ARG, turn Auto Fill mode on if and only if ARG is positive. > | In Auto Fill mode, inserting a space at a column beyond > `current-fill-column' > | automatically breaks the line at a previous space. > | > | The value of `normal-auto-fill-function' specifies the function to use > | for `auto-fill-function' when turning Auto Fill mode on. > ` > > I think "nil" counts as a positive number. Maybe that's a bug? I dunno. > > On Thu, Feb 24, 2011 at 7:33 AM, Filippo A. Salustri > wrote: >> Hi, >> I've turned off hard line breaks for various reasons. I do it like this: >>> >>> (add-hook 'org-mode-hook >>> '(lambda () >>> (auto-fill-mode nil) >>> (visual-line-mode t))) >> >> However, in the indirect buffers used by capture, hard line breaks are still >> in place. >> I've looked, but can't find an explanation of how to control this. >> Can anyone advise me? >> Cheers. >> Fil >> >> -- >> Filippo A. Salustri, Ph.D., P.Eng. >> Mechanical and Industrial Engineering >> Ryerson University >> 350 Victoria St, Toronto, ON >> M5B 2K3, Canada >> Tel: 416/979-5000 ext 7749 >> Fax: 416/979-5265 >> Email: salus...@ryerson.ca >> http://deseng.ryerson.ca/~fil/ >> >> ___ >> Emacs-orgmode mailing list >> Please use `Reply All' to send replies to the list. >> Emacs-orgmode@gnu.org >> http://lists.gnu.org/mailman/listinfo/emacs-orgmode >> >> > > > > -- > Jeffrey Horn > http://www.failuretorefrain.com/jeff/ > -- Jeffrey Horn http://www.failuretorefrain.com/jeff/ ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] question about indirect buffers for capture and line-breaks
What happens if you use (auto-fill-mode -1) intead? ,[ C-h f auto-fill-mode RET ] | auto-fill-mode is an interactive compiled Lisp function in | `simple.el'. | | (auto-fill-mode &optional ARG) | | Toggle Auto Fill mode. | With ARG, turn Auto Fill mode on if and only if ARG is positive. | In Auto Fill mode, inserting a space at a column beyond `current-fill-column' | automatically breaks the line at a previous space. | | The value of `normal-auto-fill-function' specifies the function to use | for `auto-fill-function' when turning Auto Fill mode on. ` I think "nil" counts as a positive number. Maybe that's a bug? I dunno. On Thu, Feb 24, 2011 at 7:33 AM, Filippo A. Salustri wrote: > Hi, > I've turned off hard line breaks for various reasons. I do it like this: >> >> (add-hook 'org-mode-hook >> '(lambda () >> (auto-fill-mode nil) >> (visual-line-mode t))) > > However, in the indirect buffers used by capture, hard line breaks are still > in place. > I've looked, but can't find an explanation of how to control this. > Can anyone advise me? > Cheers. > Fil > > -- > Filippo A. Salustri, Ph.D., P.Eng. > Mechanical and Industrial Engineering > Ryerson University > 350 Victoria St, Toronto, ON > M5B 2K3, Canada > Tel: 416/979-5000 ext 7749 > Fax: 416/979-5265 > Email: salus...@ryerson.ca > http://deseng.ryerson.ca/~fil/ > > ___ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode > > -- Jeffrey Horn http://www.failuretorefrain.com/jeff/ ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: TODO state change from TODO to DONE blocked
Hi, Sébastien Vauban wrote: > I've a really weird exception occurring: change state from TODO to DONE is > blocked... while I'm on a leaf of the Org tree!? > > Debugger entered--Lisp error: (error #("TODO state change from TODO to DONE > blocked" 23 27 (face org-todo) 31 35 (face org-done))) > signal(error (#("TODO state change from TODO to DONE blocked" 23 27 (face > org-todo) 31 35 (face org-done > error("TODO state change from %s to %s blocked" #("TODO" 0 4 (face > org-todo)) #("DONE" 0 4 (face org-done))) > (if (interactive-p) (error "TODO state change from %s to %s blocked" this > state) (message "TODO state change from %s to %s blocked" this state) (throw > (quote exit) nil)) > (if (save-excursion (save-match-data ...)) nil (if (interactive-p) (error > "TODO state change from %s to %s blocked" this state) (message "TODO state > change from %s to %s blocked" this state) (throw ... nil))) > (unless (save-excursion (save-match-data ...)) (if (interactive-p) (error > "TODO state change from %s to %s blocked" this state) (message "TODO state > change from %s to %s blocked" this state) (throw ... nil))) > (progn (setq org-last-todo-state-is-todo (not ...)) (unless (save-excursion > ...) (if ... ... ... ...))) > (if org-blocker-hook (progn (setq org-last-todo-state-is-todo ...) (unless > ... ...))) > (when org-blocker-hook (setq org-last-todo-state-is-todo (not ...)) (unless > (save-excursion ...) (if ... ... ... ...))) > (let* ((match-data ...) (startpos ...) (logging ...) (org-log-done > org-log-done) (org-log-repeat org-log-repeat) (org-todo-log-states > org-todo-log-states) (this ...) (hl-pos ...) (head ...) (ass ...) (interpret > ...) (done-word ...) (final-done-word ...) (last-state ...) > (completion-ignore-case t) (member ...) (tail ...) (state ...) (state ...) > (next ...) (change-plist ...) dolog now-done-p) (when org-blocker-hook (setq > org-last-todo-state-is-todo ...) (unless ... ...)) (store-match-data > match-data) (replace-match next t t) (unless (pos-visible-in-window-p hl-pos) > (message "TODO state changed to %s" ...)) (unless head (setq head ... ass ... > interpret ... done-word ... final-done-word ...)) (when (memq arg ...) > (message "Keyword-Set %d/%d: %s" ... ... ...)) (setq > org-last-todo-state-is-todo (not ...)) (setq now-done-p (and ... ...)) (and > logging (org-local-logging logging)) (when (and ... ... ...) (setq dolog ...) > (if ... ...) (when ... ...) (when ... ... ...) (when ... ...)) > (org-todo-trigger-tag-changes state) (and org-auto-align-tags (not > org-setting-tags) (org-set-tags nil t)) (when org-provide-todo-statistics > (org-update-parent-todo-statistics)) (run-hooks (quote > org-after-todo-state-change-hook)) (if (and arg ...) (setq head ...)) > (put-text-property (point-at-bol) (point-at-eol) (quote org-todo-head) head) > (when now-done-p (when ... ...) (org-auto-repeat-maybe state)) (if (and ... > ... ... ...) (progn ... ...)) (when org-trigger-hook (save-excursion ...))) > (catch (quote exit) (org-back-to-heading t) (if (looking-at outline-regexp) > (goto-char ...)) (or (looking-at ...) (looking-at " *")) (let* (... ... ... > ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... dolog > now-done-p) (when org-blocker-hook ... ...) (store-match-data match-data) > (replace-match next t t) (unless ... ...) (unless head ...) (when ... ...) > (setq org-last-todo-state-is-todo ...) (setq now-done-p ...) (and logging > ...) (when ... ... ... ... ... ...) (org-todo-trigger-tag-changes state) (and > org-auto-align-tags ... ...) (when org-provide-todo-statistics ...) > (run-hooks ...) (if ... ...) (put-text-property ... ... ... head) (when > now-done-p ... ...) (if ... ...) (when org-trigger-hook ...))) > (save-excursion (catch (quote exit) (org-back-to-heading t) (if ... ...) > (or ... ...) (let* ... ... ... ... ... ... ... ... ... ... ... ... ... ... > ... ... ... ... ... ...))) > (let ((org-blocker-hook org-blocker-hook) (case-fold-search nil)) (when > (equal arg ...) (setq arg nil org-blocker-hook nil)) (when (and > org-blocker-hook ...) (setq org-blocker-hook nil)) (save-excursion (catch ... > ... ... ... ...))) > org-todo(nil) > call-interactively(org-todo) > (cond ((commandp org-speed-command) (setq this-command org-speed-command) > (call-interactively org-speed-command)) ((functionp org-speed-command) > (funcall org-speed-command)) ((and org-speed-command ...) (eval > org-speed-command)) (t (let ... ...))) > (cond ((and org-use-speed-commands ...) (cond ... ... ... ...)) ((and ... > ... ... ...) (let ... ... ... ... ...)) (t (setq org-table-may-need-update t) > (self-insert-command N) (org-fix-tags-on-the-fly) (if > org-self-insert-cluster-for-undo ...))) > org-self-insert-command(1) > call-interactively(org-self-insert-command nil nil) > > I absolutely don't understand which conditions are met for provoking that > strange reaction. > > Taking that leaf an
[Orgmode] Re: [Accepted] Re: Bug: Jumping to a date in the agenda changes view back to 'day' [7.4 (release_7.4.80.g0e5e5)]
Matt Lundin writes: > > Has there been any progress on this issue? I am finding that the local > span bindings in the custom command above still do not have any effect. > My default agenda span is a day. If I call the custom command above, it > displays only one day, despite the local setting. I think I know what's happening. The custom agenda commands had been working properly until this commit on Feb 18, which brought back the behavior described above: c6dbde1babaa0b2efa278d75a6ec82f91ef59d5e Thanks, Matt ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: [Accepted] Re: Bug: Jumping to a date in the agenda changes view back to 'day' [7.4 (release_7.4.80.g0e5e5)]
Matt Lundin writes: > Bastien Guerry writes: > >> Patch 543 (http://patchwork.newartisans.com/patch/543/) is now "Accepted". > >>> * org-agenda.el (org-agenda-list): Use org-agenda-current-span as a >>> possible default span if it is set. > This patch breaks custom commands --- i.e., if one binds org-agenda-span > in a custom command, it seems to be overridden by the span of whatever > agenda command one last called (i.e., org-agenda-current-span). > > Steps to replicate: > > 1. (setq org-agenda-span 'day) > > 2. M-x org-agenda-list > > 3. Check the value of org-agenda-current-span => day > > 4. Call the following custom command: > > (setq org-agenda-custom-commands > '(("c" "Calendar" agenda "" >((org-agenda-span 'week) > (org-agenda-start-on-weekday 0) > (org-agenda-time-grid nil) > (org-agenda-entry-types '(:timestamp :sexp)) > (org-agenda-prefix-format " %-12:t ") > (org-deadline-warning-days 0) > (org-agenda-include-all-todo nil) > (org-agenda-repeating-timestamp-show-all t) > > > This results in only a day view because org-agenda-current-span is still > 'day. > Has there been any progress on this issue? I am finding that the local span bindings in the custom command above still do not have any effect. My default agenda span is a day. If I call the custom command above, it displays only one day, despite the local setting. Best, Matt ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [babel] Possible bug: (mis)handling tuples for :return value in Python [7.4 (release_7.4.153.ga0b8)]
I do not think that =org-babel-read= is correctly handling Python tuples that are returned from source blocks. If I execute the following source block: #+begin_src python :results value return (1,2) #+end_src I get the following error message: : Symbol's function definition is void: 1\, The Python output for this source block is =(1,2)=, which =org-babel-read= interprets as lisp and tries to eval. I can work around the problem using either a Python list: #+begin_src python :results value return [1,2] #+end_src or by using =:results output= #+begin_src python :results output :session (1,2) #+end_src Regards, Scott Emacs : GNU Emacs 23.2.1 (i686-pc-linux-gnu, GTK+ Version 2.21.6) of 2010-09-01 on rhenium, modified by Debian Package: Org-mode version 7.4 (release_7.4.529.gb23d) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] question about indirect buffers for capture and line-breaks
Hi, I've turned off hard line breaks for various reasons. I do it like this: > (add-hook 'org-mode-hook > '(lambda () > (auto-fill-mode nil) > (visual-line-mode t))) However, in the indirect buffers used by capture, hard line breaks are still in place. I've looked, but can't find an explanation of how to control this. Can anyone advise me? Cheers. Fil -- Filippo A. Salustri, Ph.D., P.Eng. Mechanical and Industrial Engineering Ryerson University 350 Victoria St, Toronto, ON M5B 2K3, Canada Tel: 416/979-5000 ext 7749 Fax: 416/979-5265 Email: salus...@ryerson.ca http://deseng.ryerson.ca/~fil/ ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [HOW] no way to escape vertical bar (pipe char) in tables?
I want to manage some perl regexps in a table then feed them to a code block (literate programming). Unfortunately they include alternatives (|) and the table editor thinks this is a column break. There's no way to escape this? On a related thought: what is the best way to manage leading/trailing spaces in a table cell? I've been forced to use \x20 for this purpose... ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] TODO state change from TODO to DONE blocked
Hi, I've a really weird exception occurring: change state from TODO to DONE is blocked... while I'm on a leaf of the Org tree!? --8<---cut here---start->8--- Debugger entered--Lisp error: (error #("TODO state change from TODO to DONE blocked" 23 27 (face org-todo) 31 35 (face org-done))) signal(error (#("TODO state change from TODO to DONE blocked" 23 27 (face org-todo) 31 35 (face org-done error("TODO state change from %s to %s blocked" #("TODO" 0 4 (face org-todo)) #("DONE" 0 4 (face org-done))) (if (interactive-p) (error "TODO state change from %s to %s blocked" this state) (message "TODO state change from %s to %s blocked" this state) (throw (quote exit) nil)) (if (save-excursion (save-match-data ...)) nil (if (interactive-p) (error "TODO state change from %s to %s blocked" this state) (message "TODO state change from %s to %s blocked" this state) (throw ... nil))) (unless (save-excursion (save-match-data ...)) (if (interactive-p) (error "TODO state change from %s to %s blocked" this state) (message "TODO state change from %s to %s blocked" this state) (throw ... nil))) (progn (setq org-last-todo-state-is-todo (not ...)) (unless (save-excursion ...) (if ... ... ... ...))) (if org-blocker-hook (progn (setq org-last-todo-state-is-todo ...) (unless ... ...))) (when org-blocker-hook (setq org-last-todo-state-is-todo (not ...)) (unless (save-excursion ...) (if ... ... ... ...))) (let* ((match-data ...) (startpos ...) (logging ...) (org-log-done org-log-done) (org-log-repeat org-log-repeat) (org-todo-log-states org-todo-log-states) (this ...) (hl-pos ...) (head ...) (ass ...) (interpret ...) (done-word ...) (final-done-word ...) (last-state ...) (completion-ignore-case t) (member ...) (tail ...) (state ...) (state ...) (next ...) (change-plist ...) dolog now-done-p) (when org-blocker-hook (setq org-last-todo-state-is-todo ...) (unless ... ...)) (store-match-data match-data) (replace-match next t t) (unless (pos-visible-in-window-p hl-pos) (message "TODO state changed to %s" ...)) (unless head (setq head ... ass ... interpret ... done-word ... final-done-word ...)) (when (memq arg ...) (message "Keyword-Set %d/%d: %s" ... ... ...)) (setq org-last-todo-state-is-todo (not ...)) (setq now-done-p (and ... ...)) (and logging (org-local-logging logging)) (when (and ... ... ...) (setq dolog ...) (if ... ...) (when ... ...) (when ... ... ...) (when ... ...)) (org-todo-trigger-tag-changes state) (and org-auto-align-tags (not org-setting-tags) (org-set-tags nil t)) (when org-provide-todo-statistics (org-update-parent-todo-statistics)) (run-hooks (quote org-after-todo-state-change-hook)) (if (and arg ...) (setq head ...)) (put-text-property (point-at-bol) (point-at-eol) (quote org-todo-head) head) (when now-done-p (when ... ...) (org-auto-repeat-maybe state)) (if (and ... ... ... ...) (progn ... ...)) (when org-trigger-hook (save-excursion ...))) (catch (quote exit) (org-back-to-heading t) (if (looking-at outline-regexp) (goto-char ...)) (or (looking-at ...) (looking-at " *")) (let* (... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... dolog now-done-p) (when org-blocker-hook ... ...) (store-match-data match-data) (replace-match next t t) (unless ... ...) (unless head ...) (when ... ...) (setq org-last-todo-state-is-todo ...) (setq now-done-p ...) (and logging ...) (when ... ... ... ... ... ...) (org-todo-trigger-tag-changes state) (and org-auto-align-tags ... ...) (when org-provide-todo-statistics ...) (run-hooks ...) (if ... ...) (put-text-property ... ... ... head) (when now-done-p ... ...) (if ... ...) (when org-trigger-hook ...))) (save-excursion (catch (quote exit) (org-back-to-heading t) (if ... ...) (or ... ...) (let* ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...))) (let ((org-blocker-hook org-blocker-hook) (case-fold-search nil)) (when (equal arg ...) (setq arg nil org-blocker-hook nil)) (when (and org-blocker-hook ...) (setq org-blocker-hook nil)) (save-excursion (catch ... ... ... ... ...))) org-todo(nil) call-interactively(org-todo) (cond ((commandp org-speed-command) (setq this-command org-speed-command) (call-interactively org-speed-command)) ((functionp org-speed-command) (funcall org-speed-command)) ((and org-speed-command ...) (eval org-speed-command)) (t (let ... ...))) (cond ((and org-use-speed-commands ...) (cond ... ... ... ...)) ((and ... ... ... ...) (let ... ... ... ... ...)) (t (setq org-table-may-need-update t) (self-insert-command N) (org-fix-tags-on-the-fly) (if org-self-insert-cluster-for-undo ...))) org-self-insert-command(1) call-interactively(org-self-insert-command nil nil) --8<---cut here---end--->8--- I absolutely don't understand which conditions are met for provoking that strange reaction. Taking that leaf and putting it in a blanco Org file allows me to d
Re: [Orgmode] [babel] maxima support?
Eric S Fraga writes: > Litvinov Sergey writes: > >> I have not found (i)maxima on this page. >> http://orgmode.org/worg/org-contrib/babel/languages.html >> (Babel: Languages) >> >> Has someone implemented it? > > I have implemented a very basic interface (attached). Example: > > #+begin-src org > * maxima test > *** simple test > #+begin_src maxima > programmode: false; > eq: x**2-1 = 0; > solution: solve(eq, x); > print(solution); > #+end_src > > > #+results: > : [x = - 1, x = 1] > #+end_src > > However, please note that this is rather linux (maybe Unix) specific in > that it post-processes the output of maxima using a sequence of shell > commands to get rid of unnecessary (to my mind) output. Maxima is a bit > verbose... I hit C-c C-c too quickly (got confused as to which buffer I was in). Please delete the "programmode: false;" line in the source code block above to get the desired behaviour... -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.4 (release_7.4.529.gb23d) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] [babel] maxima support?
Litvinov Sergey writes: > I have not found (i)maxima on this page. > http://orgmode.org/worg/org-contrib/babel/languages.html > (Babel: Languages) > > Has someone implemented it? I have implemented a very basic interface (attached). Example: #+begin-src org * maxima test *** simple test #+begin_src maxima programmode: false; eq: x**2-1 = 0; solution: solve(eq, x); print(solution); #+end_src #+results: : [x = - 1, x = 1] #+end_src However, please note that this is rather linux (maybe Unix) specific in that it post-processes the output of maxima using a sequence of shell commands to get rid of unnecessary (to my mind) output. Maxima is a bit verbose... ob-maxima.el Description: org babel maxima interface -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.4 (release_7.4.529.gb23d) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Possible Calc support for Org-Babel?
"Eric Schulte" writes: > Christopher Allan Webber writes: > >> (failed to wide-reply initially) >> >> I just had use for this for some quick calculations I wanted to add to >> one of my files, but... >> >> Any idea why variables inside of parentheses don't work, but variables >> outside of them do? >> >> #+BEGIN_SRC calc :var testvar=9000 >> testvar - 200 >> #+END_SRC >> >> #+results: >> : 8800 >> >> >> #+BEGIN_SRC calc :var testvar=9000 >> (testvar - 200) 800 >> #+END_SRC >> >> #+results: >> : 800 testvar - 16 >> > > Hi Christopher, > > Sorry about the LONG delay in replying to this email. I've just pushed > up a fix for this problem. Thanks for reporting. > > Best -- Eric Further on this, any suggestions on how to pass a vector variable to calc using babel? I tried #+begin-src org #+begin_src calc :var y=[1 2 3] 3 y #+end_src #+end_src but get an error that says : Bad format in variable contents: Expected a number I've tried putting the vector in quotes but that doesn't help either. Is this maybe not possible? Thanks, eric -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.4 (release_7.4.529.gb23d) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Using org-protocol to (org-)capture files for read/review?
Hello, notmuch-org! I'm using org-mode to structure most of my life, but I haven't been able to incorporate my list of PDFs (or other documents) to read/review in org-mode, so currently I'm just putting them in ~/read-review. However, I thought I'd use org-protocol and emacsclient to add links to these files to org-mode, but I'm unable to figure out how to do it. I'd like to map the full path to a file, and then have that file appended to a plain list in a given org file with the TODO tag set (something like »* TODO [[file:/path/to/filename.pdf]]«) given a run of »emacsclient org-protocol:/capture:/r/path/to/filename.pdf/«. I can then implement pushing to my read/review stack with a simple shell command that a) moves the new file to ~/read-review and b) adds a link to the file on my org-mode read/review stack using the above mentioned emacsclient command. So far, I've tried adding the following to org-capture-templates: ("r" "read/review" entry (file "~/org/read-review.org") "* TODO read %c" :immediate-finish t) Obviously »%c« wrong here -- but what should I replace it with? Thanks in advance, Albin PS. Sorry if I've insufficiently R:d TFM, but I really did try. ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode