Re: [O] Buffer-specific export filter?
Hello, James Harkins writes: > But maybe there's a better solution for my specific case. The problem is > that I'm using the colloquial <<'em>> for "them." The preceding space causes > org to export this as `em. Normally a single quote after a space would > correctly be an opening single quote, but here it's for a contraction and > should be an apostrophe. In that case, you should disable smart quotes, which are not smart enough for your use case. Note that they are not enabled by default. > Related question: If I wanted to force a non-breaking space in LaTeX export, > how would I do that without a filter? ~ exports, reasonably, as > \textasciitilde. Use \nbsp{} macro. Regards, -- Nicolas Goaziou
Re: [O] Problem writing my first export filter
Hello, James Harkins writes: > I just tried the following, so that I could maintain a list of special cases > where org's default latex export doesn't do what I want. > > (setq hjh-org-latex-macros '(("`em" "'em"))) > > (defun hjh-latex-filter-macros (text backend info) > "hjh: Replace special cases listed in hjh-org-latex-macros." > (when (org-export-derived-backend-p backend 'latex) > (dolist (element hjh-org-latex-macros) > (replace-regexp-in-string (car element) (car (cdr element)) text > > First I tried > > (setq org-export-filter-plain-text-functions '(hjh-latex-filter-macros)) > > -- no result: `em passes through unchanged. So then I tried clearing > plain-text-functions and using final-output-functions instead. Same thing: > the filter didn't do anything. > > I suppose I'm missing something simple. Your filter returns nil (due to the `dolist') and is therefore ignored. You have to make sure it returns the new string: (defun hjh-latex-filter-macros (text backend info) "hjh: Replace special cases listed in hjh-org-latex-macros." (when (org-export-derived-backend-p backend 'latex) (dolist (element hjh-org-latex-macros text) (setq text (replace-regexp-in-string (car element) (nth 1 element) text) Regards, -- Nicolas Goaziou
Re: [O] quote, quotation environments in org beamer export just comment text out.
Hello, Ratish Punnoose writes: > Is there a reason that quote, quotation, verse, environments during export > to tex just comment their contents. Contents are not commented out, only the headline text is. Such environments do not accept any argument, but headline text is still inserted in the buffer as a comment, for information. Regards, -- Nicolas Goaziou
Re: [O] orgmode and academic conferences advice needed: how to integrate orgmode to capture ideas/data
Xebar Saram writes: > Hi all > > im currently in Basel in a Academic conference and was thinking how one > would "absorb" all the torrents of ideas/data/images/conversations quickly > into org mode :) does any one have any real life experience with this? do > you use mobile-org or that, or another method? > i have an andorid phone/tablet and a laptop as well so i was wondering if > any one had any ideas? > > in a perfect world i would use my tablet to capture text etc and phone to > capture images/posters/quick ideas and have them all automatically sync to > my org mode file but i know that wishful thinking > > best > > Itai Mostly I do it with mindmaps. Either directly on paper using the bic 4 color ballpoint pen [1] Otherwise use org-mode and then export it into freemind C-c C-e m (org-export-as-freemind) I have seen that Vym (view your mind) has a experimental export function to org-mode. I have never tested it though. Best, Giammi Footnotes: [1] http://www.bicworld.com/en/products/details/18/4-color -- I kindly ask you not to send me attachments in proprietary file formats, use open standards like PDF, HTML, RTF or plain text.
Re: [O] WISH: SQL on org-mode tables
I started using EDBI myself just last week, it's working really well so far! An EDBI--org combination would be amazing for database work. 2013/8/21 SAKURAI Masashi > Hi, > > I wrote a full DB browser in Emacs, EDBI > https://github.com/kiwanami/emacs-edbi. > > This program provides DB Query API (like Perl's DBI) and table layout > framework. > One can query any SQL and layout the results into a rigid table format. > There is no document for API, please see the demo code. > https://github.com/kiwanami/emacs-edbi/blob/master/edbi-demo.el > > I don't have a time to integrate it into org-mode, > if someone would write the code, I think I can help a little. > > > Regards > -- > SAKURAI, Masashi (family, given) > m.saku...@kiwanami.net > > > At Sun, 18 Aug 2013 16:06:43 +0200, > Johan W. Kl�+dwer wrote: > > > > [1 ] > > > > [2 ] > > I wish it were possible to execute SQL on tables in org-mode buffers. > Filtering rows and columns, > > joining values across named tables, and so forth could be done with SQL > in the org-table SEND > > clauses. > > > > There's a script called csvsql that allows for executing SQL on comma- > or tab-separated files from > > the command-line (using the H2 database engine): > https://github.com/jdurbin/durbinlib/wiki/csvsql. > > I'm thinking csvsql or similar could provide the query capability, and > org-mode would take care of > > sending it org tables in tab separated format. > > > > That's my wish. > > > > Cheers > > > > Johan > > > > >
[O] Editing HTML blocks: no special environment to edit here
Hi! Org-mode version 8.0.2 (release_8.0.2-121-g86fab4 from the git repository a couple of weeks ago) #+BEGIN_SRC html bar #+END_SRC #+BEGIN_HTML foo #+END_HTML I can edit "bar" in a separate buffer by invoking C-c ' (org-edit-special). However, this does not work for "foo" ("user-error: No special environment to edit here") although I guess that the foo-html-block is the one that should be preferred.[1] It is either rooted in my personal set-up, my (older) org-mode version from git, or a general bug. So I started Emacs with "--no-init-file" and got "Org-mode version 6.33x" (the site-specific org installation). After I evaluated the statements to my local org-mode installation I got "Org-mode version 6.33x (release_8.0.2.121.g86fab)". Strange (6.33x vs. 8.0.2...) but I hope this worked so far and I got the newer release from git. In this rather minimal Emacs, I can edit both blocks as special buffers as I want to. So I guess I did something in my Org-mode setup files [2] which causes this issue. Unfortunately, I could not locate anything which I identify as the root of this issue. Do you have any idea what this might be? 1. There is not even an entry for "html" on http://orgmode.org/worg/org-contrib/babel/languages.html 2. https://github.com/novoid/dot-emacs -> org-mode.el -- mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML to Org-mode: > get Memacs from https://github.com/novoid/Memacs < https://github.com/novoid/extract_pdf_annotations_to_orgmode + more on github
Re: [O] orgmode and academic conferences advice needed: how to integrate orgmode to capture ideas/data
* Xebar Saram wrote: > > Hi all Hi! > im currently in Basel in a Academic conference and was thinking how one > would "absorb" all the torrents of ideas/data/images/conversations quickly > into org mode :) does any one have any real life experience with this? do > you use mobile-org or that, or another method? > i have an andorid phone/tablet and a laptop as well so i was wondering if > any one had any ideas? I am using my MobileOrg (Android) to quickly[1] add short notes and URLs (share with ... MobileOrg) to myself while being on the road. I think that there is no easy/quick way of adding other data than simple test to Org-mode on the phone. However, I always return with lots of new headings in my inbox.org from events like research conferences and such :-) 1. There is a capture widget -- mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML to Org-mode: > get Memacs from https://github.com/novoid/Memacs < https://github.com/novoid/extract_pdf_annotations_to_orgmode + more on github
Re: [O] Buffer-specific export filter?
On Aug 21, 2013 3:41 PM, "Nicolas Goaziou" wrote: > In that case, you should disable smart quotes, which are not smart > enough for your use case. Note that they are not enabled by default. That's reasonable, but irritating while I'm still editing. I'm certain I'll leave some ASCII double quotes in there by mistake. Should be easy enough to handle as the last thing, using regexp replace. > > Related question: If I wanted to force a non-breaking space in LaTeX export, > > how would I do that without a filter? ~ exports, reasonably, as > > \textasciitilde. > > Use \nbsp{} macro. Ok, thanks. And thanks also for the hint on the filter. I'm fairly new to lisp (obviously). I know about functions' return values, just forgot here... hjh
[O] Problem with special characters in dired and attachment paths
I'm having problems with special characters like äöü in dired mode and in attachment paths: 1) When I'm trying to access a directory with M-x dired, the displayed path contains strange characters like e.g. "\374" for "ü" or "\366" for "ö". Same is true for directory and file listings displayed by dired. Is there a setting which can make dired display the characters with the correct encoding? 2) my other problem seems to be related: I currently added a long server path as attachment directory in org-mode, like //servername/dir1/dir2/dir2/dir4/etcetera/Zubehör/ (I usually copy the UNC path in Windows 7 Explorer with the PathCopy context menu) The path is shown like that in :ATTACH_DIR: in the properties with the "ö" correctly displayed. When I type C-c C-a C-f to open the directory in Windows Explorer, it creates a new directory at the same path called Zubehör which is opened instead of the right one. How can I solve those 2 problems? Kind regards Martin
Re: [O] quote, quotation environments in org beamer export just comment text out.
Thanks much for the explanation.
[O] Using org-goto loses org-todo-keyword-faces settings
Hi, My thanks to everyone who works on org-mode. It is a truly indispensable tool. I'm not sure if I have a bug or a feature request: I have custom faces set up for my todo keywords (see my file local variable for org-todo-keyword-faces at the bottom of this report). When I use org-goto (C-c C-j) and then exit goto mode, my custom colors for todo keywords are reset to the defaults. Explicitly: 1. Create and save an org file with the following contents: --8<--Cut here--8<-- * WAITING test1 #+TODO: NEW(n) PENDING(p!) WAITING(w!) HOLD(h!) | DONE(d!) CANCELLED(c!) # Local Variables: # org-todo-keyword-faces: (("WAITING" . "dark orange") # ("HOLD" . "dark orange")) # End: --8<--Cut here--8<-- 2. Revert the buffer to pick up the in-buffer configuration including file local variables. 3. C-c C-j followed by C-g to exit goto mode. What I expected: WAITING would still be "dark orange" when I exit goto mode. What I observed: WAITING reverts to the default red color when I exit goto mode. (WAITING is also red while I'm in org-goto mode, which is less of a problem for me. I'd be happy enough if the color was just restored when I'm done with org-goto.) I would, of course, be grateful if my org-todo-keyword-faces would still be respected after using goto mode. I am using Emacs 24.3.1, apparently, the unofficial Emacs Mac Port (ftp://ftp.math.s.chiba-u.ac.jp/emacs/). I just confirmed this behavior using org-mode's master branch from git://orgmode.org/org-mode.git as of a few minutes ago. The output from org-submit-bug-report is below. Thanks for everything, Dale Emacs : GNU Emacs 24.3.1 (x86_64-apple-darwin12.4.0, Carbon Version 1.6.0 AppKit 1187.39) of 2013-06-26 Package: Org-mode version 8.0.7 (release_8.0.7-383-g927f1b @ /Users/dale/.emacs.d/packages/org-mode/) current state: == (setq org-hide-leading-stars t 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-reverse-note-order t org-time-clocksum-format "%d:%02d" org-occur-hook '(org-first-headline-recenter) org-metaup-hook '(org-babel-load-in-session-maybe) org-agenda-todo-ignore-deadlines 'far org-src-window-setup 'other-window org-confirm-shell-link-function 'yes-or-no-p org-agenda-todo-ignore-scheduled 1 org-default-notes-file "~/todo.org" org-startup-indented t org-after-todo-state-change-hook '(org-clock-out-if-current) org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-tags-column -76 org-agenda-before-write-hook '(org-agenda-add-entry-text) org-babel-pre-tangle-hook '(save-buffer) org-agenda-dim-blocked-tasks nil 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 my:org-mode-hook) org-outline-path-complete-in-steps nil org-agenda-todo-list-sublevels nil org-replace-disputed-keys t org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe) org-refile-use-outline-path t org-enforce-todo-dependencies t 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-after-refile-insert-hook '(my:org-maybe-note-refile) org-metareturn-hook '(my:org-meta-return-hook) org-confirm-elisp-link-function 'yes-or-no-p org-metadown-hook '(org-babel-pop-to-session-maybe) org-default-priority 68 org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent) org-completion-use-ido t org-src-preserve-indentation t org-clock-in-hook '(my:org-clock-in-set-pending-hook) org-agenda-files '("~/todo.org") org-clock-out-hook '(org-clock-remove-empty-clock-drawer) ) In-buffer configuration: #+TODO: NEW(n) PENDING(p!) WAITING(w!) HOLD(h!) | DONE(d!) CANCELLED(c!) # Local Variables: # org-todo-keyword-faces: (("WAITING" . "dark orange") # ("HOLD" . "dark orange")) # End:
Re: [O] invalid byte-code error when publishing
On Tue, Aug 20, 2013 at 9:48 AM, Sebastien Vauban wrote: > Mehul Sanghvi wrote: > > Sebastien Vauban wrote: > >> Mehul Sanghvi wrote: > Mehul Sanghvi wrote: > > The error only occurs if I'm using org-babl. The offending piece of > code > > I've got is: > > > > #+BEGIN_SRC emacs-lisp > > (setq tramp-default-method "ssh") > > #+END_SRC > > > > If I remove the #+BEGIN_SRC and #+END_SRC than everything works fine > and > > I'm able to publish. > > Would this fix it? > > #+BEGIN_SRC emacs-lisp :eval no > (setq tramp-default-method "ssh") > #+END_SRC > >>> > >>> Thanks for the suggestion. That does not fix the problem. I still get > the > >>> same error as before. > >> > >> Check out the value of: > >> > >> - `org-babel-default-header-args', and > >> - `org-babel-default-header-args:emacs-lisp'. > >> > >> And try whether `:eval query' makes a difference (when answering yes, > and > >> when answering no)? > > > > Using ':eval query' does not make a difference. It does not prompt for > yes > > or no. > > Then, there are now 2 things I don't understand: > > - why it does not query you for eval? > - why that code gets you in troubles? > > I'm out of ideas here... > > Try with an ECM, or with emacs -Q? > > Best regards, > Seb > > -- > Sebastien Vauban > > > This works now. I don't know why it was causing problems, but it worked just fine in a new instance. I had done a org-reload rather than re-start my emacs. Thanks for your help. cheers, mehul -- Mehul N. Sanghvi email: mehul.sang...@gmail.com
[O] babel-load problem
Any idea on what I am doing wrong? I just want to set up my config to be load by babel? I have my Windows emacs set up with the latest packer for org (20130819) and have the following in my .emacs ;; setup orgmode babel (setq org-babel-load-languages '((emacs-lisp . t))) (setq org-confirm-babel-evaluate nil) (require 'org-install) (require 'org) ;; load orgmode organized config (org-babel-load-file "~/emacs.org") This gives me the follwing error : Debugger entered--Lisp error: (file-error "Cannot open load file" "c:/Users/fe/Dropbox/emacs/emacs.el") load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) load-file("~/emacs.el") org-babel-load-file("~/emacs.org") eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/.emacs" nil t) ; Reading at buffer position 221 load-with-code-conversion("c:/Users/fe/Dropbox/emacs/.emacs" "c:/Users/fe/Dropbox/emacs/.emacs" t t) load("~/.emacs" t t) #[0 "\205\262 So if I then copy my .emacs to emacs.el instead I get the following error : Debugger entered--Lisp error: (error "Recursive load" "c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/.emacs") load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) load-file("~/emacs.el") org-babel-load-file("~/emacs.org") eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/emacs.el" nil t) ; Reading at buffer position 221 load-with-code-conversion("c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" nil nil) load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) load-file("~/emacs.el") org-babel-load-file("~/emacs.org") eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/emacs.el" nil t) ; Reading at buffer position 221 load-with-code-conversion("c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" nil nil) load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) load-file("~/emacs.el") org-babel-load-file("~/emacs.org") eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/emacs.el" nil t) ; Reading at buffer position 221 load-with-code-conversion("c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" nil nil) load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) load-file("~/emacs.el") org-babel-load-file("~/emacs.org") eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/emacs.el" nil t) ; Reading at buffer position 221 load-with-code-conversion("c:/Users/fe/Dropbox/emacs/emacs.el" "c:/Users/fe/Dropbox/emacs/emacs.el" nil nil) load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) load-file("~/emacs.el") org-babel-load-file("~/emacs.org") eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/.emacs" nil t) ; Reading at buffer position 221 load-with-code-conversion("c:/Users/fe/Dropbox/emacs/.emacs" "c:/Users/fe/Dropbox/emacs/.emacs" t t) load("~/.emacs" t t) #[0 "\205\262 Any idea on what I am doing wrong? I just want to set up my config to be load by babel?
Re: [O] babel-load problem
Fredrik writes: > Any idea on what I am doing wrong? I just want to set up my config to be load > by > babel? > > I have my Windows emacs set up with the latest packer for org (20130819) and > have the following in my .emacs > ;; setup orgmode babel > (setq org-babel-load-languages '((emacs-lisp . t))) > (setq org-confirm-babel-evaluate nil) > (require 'org-install) > (require 'org) > > ;; load orgmode organized config > (org-babel-load-file "~/emacs.org") > > This gives me the follwing error : > > Debugger entered--Lisp error: (file-error "Cannot open load file" > "c:/Users/fe/Dropbox/emacs/emacs.el") > load("c:/Users/fe/Dropbox/emacs/emacs.el" nil nil t) > load-file("~/emacs.el") > org-babel-load-file("~/emacs.org") > eval-buffer(# nil "c:/Users/fe/Dropbox/emacs/.emacs" nil t) > ; > Reading at buffer position 221 > load-with-code-conversion("c:/Users/fe/Dropbox/emacs/.emacs" > "c:/Users/fe/Dropbox/emacs/.emacs" t t) > load("~/.emacs" t t) > #[0 "\205\262 > In emacs.org, are you trying to load "c:/Users/fe/Dropbox/emacs/emacs.el" ? or is your $HOME set to c:/Users/fe/Dropbox/emacs ? Thanks and Regards Noorul
Re: [O] babel-load problem
My emacs.org is empty so far... But yes my $HOME is set to c:/Users/fe/Dropbox/emacs Regards, Fredrik On 2013-08-22 05:13, Noorul Islam K M wrote: In emacs.org, are you trying to load "c:/Users/fe/Dropbox/emacs/emacs.el" ? or is your $HOME set to c:/Users/fe/Dropbox/emacs ? Thanks and Regards Noorul
Re: [O] babel-load problem
I solved it... but don't really understand why. I tested changing the name of my org file between .emacs.org and emacs.org and changing the loadpath accordingly : (org-babel-load-file "~/emacs.org") And now suddenly it works but only if the file is named emacs.org if I add an dot in front of the name I get the same issues as before On 2013-08-22 07:08, Fredrik wrote: My emacs.org is empty so far... But yes my $HOME is set to c:/Users/fe/Dropbox/emacs Regards, Fredrik On 2013-08-22 05:13, Noorul Islam K M wrote: In emacs.org, are you trying to load "c:/Users/fe/Dropbox/emacs/emacs.el" ? or is your $HOME set to c:/Users/fe/Dropbox/emacs ? Thanks and Regards Noorul
[O] babel .el-files?
I have set up my emacsconfig to use org-files. Now it creates .el-files when I start emacs so can I control where it puts these files so it doesn't clutter my filesystem? Regards, Fredrik