emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] Org-mode version 6.32trans (release_6.32b.dirty); org-list


From: Carsten Dominik
Subject: Re: [Orgmode] Org-mode version 6.32trans (release_6.32b.dirty); org-list-send-list matching problem
Date: Thu, 29 Oct 2009 14:48:04 +0100

Hi Daniel,

thanks for the report and fix, I have made the proposed change.

- Carsten

On Oct 29, 2009, at 1:04 PM, Daniel Hackney wrote:

When attempting to use radio lists for exporting in LaTeX, I found that they
didn't work. I am using the example file shown below:

---BEGIN_EXAMPLE---

#+LaTeX: % BEGIN RECEIVE ORGLST programs
#+LaTeX: % END RECEIVE ORGLST programs

#+ORGLST: SEND programs org-list-to-latex
  - Emacs text editor
  - Ubuntu Linux
  - Git version control system
  - Firefox web browser
  - Drupal content management system
  - Subversion version control system
  - Eclipse integrated development environment

---END_EXAMPLE---

I eventually ran `org-list-send-list' manually on the list, and got the
following error:

 funcall: Wrong type argument: number-or-marker-p, (unordered
#("Emacs text editor" [snip...]

I started debugging `org-list-send-list' and found that the error occurred when calling (funcall transform list). Looking back, I saw that `transform' was assigned (in the let*) after `item-beginning'. Stepping through the execution, I saw that `transform' was being assigned a value of `-'. It turns out when assigning to `item-beginning', (org-list-item-beginning) is called, which runs a regular expression with a capture group, overwriting the previously matched
capture group.

Luckily, the fix is simple; all that needs be done is to switch the assignment to `transform' with `item-beginning' so the regex in (org-list-item- beginning) doesn't override the match-string data. I tried this fix out and it worked
perfectly.

Thanks for a program which never ceases to amaze me!

Emacs  : GNU Emacs 23.1.1 (i486-pc-linux-gnu, GTK+ Version 2.18.2)
of 2009-10-14 on palmer, modified by Debian
Package: Org-mode version 6.32trans (release_6.32b.dirty)

current state:
==============
(setq
org-log-done 'time
org-agenda-custom-commands '(("p" tags "PROJECT-MAYBE-DONE" nil) ("m"
tags "PROJECT&MAYBE" nil))
org-agenda-files '("~/org/root.org")
org-export-latex-list-parameters '(:cbon "\\texttt{[ ]}" :cboff
"\\texttt{[ ]}")
org-after-todo-state-change-hook '(org-clock-out-if-current
wicked/org-clock-out-if-waiting wicked/org-clock-in-if-starting)
org-archive-location "%s_archive::* Archived Tasks"
org-id-locations-file "~/.emacs.d/tmp/.org-id-locations"
org-export-preprocess-hook '(org-export-blocks-preprocess)
org-tab-first-hook '(org-hide-block-toggle-maybe)
org-src-mode-hook '(org-src-mode-configure-edit-buffer)
org-confirm-shell-link-function 'yes-or-no-p
org-todo-keywords '((sequence "TODO" "STARTED" "WAITING" "DONE"))
org-agenda-before-write-hook '(org-agenda-add-entry-text)
org-default-notes-file "~/org/root.org"
org-registry-file "~/.emacs.d/tmp/org-registry.el"
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-latex-classes '(("vita"

"\\documentclass[ComputerScience]{vita}\n\\usepackage{hyperref}\n\ \usepackage{multicol}\n\\usepackage{comment}\n\\addtolength{\ \textwidth}{2in}\n\\addtolength{\\oddsidemargin}{-1in}\n\ \addtolength{\\evensidemargin}{-1in}\n\\setlength{\\topsep}{-1in}\n\ \setlength{\\parskip}{0in}\n\\topmargin=0in\n\\textheight=10.1in"
                            ("\\section{%s\\hrulefill}" .
"\\section*{%s \\hrulefill}") ("\\subsection{%s}" .
"\\subsection*{%s}")
                            ("\\subsubsection{%s}" .
"\\subsubsection*{%s}") ("\\paragraph{%s}" . "\\paragraph*{%s}")
("\\subparagraph{%s}" . "\\subparagraph*{%s}"))
                           ("article"

"\\documentclass[11pt]{article}\n\\usepackage[utf8]{inputenc}\n\ \usepackage[T1]{fontenc}\n\\usepackage{graphicx}\n\ \usepackage{longtable}\n\\usepackage{hyperref}"
                            ("\\section{%s}" . "\\section*{%s}")
("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}" .
"\\subsubsection*{%s}")
                            ("\\paragraph{%s}" . "\\paragraph*{%s}")
("\\subparagraph{%s}" . "\\subparagraph*{%s}"))
                           ("report"

"\\documentclass[11pt]{report}\n\\usepackage[utf8]{inputenc}\n\ \usepackage[T1]{fontenc}\n\\usepackage{graphicx}\n\ \usepackage{longtable}\n\\usepackage{hyperref}"
                            ("\\part{%s}" . "\\part*{%s}")
("\\chapter{%s}" . "\\chapter*{%s}") ("\\section{%s}" .
"\\section*{%s}")
                            ("\\subsection{%s}" .
"\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))
                           ("book"

"\\documentclass[11pt]{book}\n\\usepackage[utf8]{inputenc}\n\ \usepackage[T1]{fontenc}\n\\usepackage{graphicx}\n\ \usepackage{longtable}\n\\usepackage{hyperref}"
                            ("\\part{%s}" . "\\part*{%s}")
("\\chapter{%s}" . "\\chapter*{%s}") ("\\section{%s}" .
"\\section*{%s}")
                            ("\\subsection{%s}" .
"\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))
                           )
org-mode-hook '((lambda nil (setq org-mouse-context-menu-function
(quote org-mouse-context-menu))
                 (when (memq (quote context-menu) org-mouse-features)
(define-key org-mouse-map (if (featurep (quote xemacs)) [button3]
[mouse-3]) nil)
                  (define-key org-mode-map [mouse-3] (quote
org-mouse-show-context-menu)))
                 (define-key org-mode-map [down-mouse-1] (quote
org-mouse-down-mouse))
                 (when (memq (quote context-menu) org-mouse-features)
(define-key org-mouse-map [C-drag-mouse-1] (quote
org-mouse-move-tree))
                  (define-key org-mouse-map [C-down-mouse-1] (quote
org-mouse-move-tree-start)))
                 (when (memq (quote yank-link) org-mouse-features)
(define-key org-mode-map [S-mouse-2] (quote org-mouse-yank-link))
                  (define-key org-mode-map [drag-mouse-3] (quote
org-mouse-yank-link)))
                 (when (memq (quote move-tree) org-mouse-features)
(define-key org-mouse-map [drag-mouse-3] (quote org-mouse-move-tree))
                  (define-key org-mouse-map [down-mouse-3] (quote
org-mouse-move-tree-start)))
(when (memq (quote activate-stars) org-mouse- features)
                  (font-lock-add-keywords nil (\` (((\,
outline-regexp) 0 (\` (face org-link mouse-face highlight keymap (\,
org-mouse-map))) (quote prepend)))) t))
(when (memq (quote activate-bullets) org-mouse- features)
                  (font-lock-add-keywords nil
                   (\` (("^[       ]*\\([-+*]\\|[0-9]+[.)]\\) +" (1 (\`
(face org-link keymap (\, org-mouse-map) mouse-face highlight)) (quote
prepend))))) t)
                  )
(when (memq (quote activate-checkboxes) org-mouse- features)
                  (font-lock-add-keywords nil
                   (\` (("^[       ]*\\([-+*]\\|[0-9]+[.)]\\) +\\(\\[[
X]\\]\\)" (2 (\` (face bold keymap (\, org-mouse-map) mouse-face
highlight)) t)))) t)
                  )
                 (defadvice org-open-at-point (around
org-mouse-open-at-point activate)
                  (let ((context (org-context)))
                   (cond ((assq :headline-stars context) (org-cycle))
((assq :checkbox context) (org-toggle-checkbox))
                    ((assq :item-bullet context) (let
((org-cycle-include-plain-lists t)) (org-cycle))) (t ad-do-it))
                   )
                  )
                 )
                (lambda nil (add-hook (quote after-save-hook) (quote
org-registry-update) t t)) turn-on-flyspell
                (lambda nil (org-add-hook (quote
change-major-mode-hook) (quote org-show-block-all) (quote append)
(quote local))))
org-export-latex-emphasis-alist '(("*" "\\textbf{%s}" nil) ("/"
"\\emph{%s}" nil) ("_" "\\underline{%s}" nil) ("+" "\\texttt{%s}" nil)
("=" "\\verb=%s=" nil)
                                  ("~" "\\verb~%s~" t))
org-return-follows-link t
org-confirm-elisp-link-function 'yes-or-no-p
org-agenda-mode-hook '((lambda nil (setq
org-mouse-context-menu-function (quote org-mouse-agenda-context-menu))
                        (define-key org-agenda-keymap (if (featurep
(quote xemacs)) [button3] [mouse-3]) (quote
org-mouse-show-context-menu))
                        (define-key org-agenda-keymap [down-mouse-3]
(quote org-mouse-move-tree-start))
                        (define-key org-agenda-keymap (if (featurep
(quote xemacs)) [(control mouse-4)] [C-mouse-4]) (quote
org-agenda-earlier))
                        (define-key org-agenda-keymap (if (featurep
(quote xemacs)) [(control mouse-5)] [C-mouse-5]) (quote
org-agenda-later))
                        (define-key org-agenda-keymap [drag-mouse-3]
                         (quote (lambda (event) (interactive "e")
(case (org-mouse-get-gesture event) (:left (org-agenda-earlier 1))
(:right (org-agenda-later 1))))))
                        )
                       )
org-occur-hook '(org-first-headline-recenter)
org-export-latex-inline-image-extensions '("pdf" "jpeg" "jpg" "png")
org-modules '(org-bbdb org-bibtex org-gnus org-info org-jsinfo
org-habit org-irc org-registry)
org-remember-templates '(("Todo" 116 "** TODO %?\n  %i\n %a"
"~/org/root.org" "") ("Appointment" 97 "** Appointment: %?\n%^T\n%i\n
%a" "~/org/root.org" "")
                         ("Blog Idea" 98 "*** %^{Title}\n    %i%?"
"~/org/root.org" "Blog Ideas")
                         ("Music" 109 "*** %^{Song title} -
%^{Artist}%!" "~/org/music.org" "To buy"))
org-export-latex-low-levels 'description
)

--
Daniel M. Hackney


_______________________________________________
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
address@hidden
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

- Carsten







reply via email to

[Prev in Thread] Current Thread [Next in Thread]