emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] [NEW] navi-mode for org files


From: Thorsten Jolitz
Subject: Re: [O] [NEW] navi-mode for org files
Date: Tue, 09 Apr 2013 00:19:37 +0200
User-agent: Gnus/5.130002 (Ma Gnus v0.2) Emacs/24.3 (gnu/linux)

Charles Berry <address@hidden> writes:

> `------------------------------------------------------------------------
>> >
>> > I cannot seem to get this to work. If I try to execute
>> >
>> > ;; # #+begin_src emacs-lisp
>> > ;; #  (require 'outshine)
>> > ;; #  (add-hook ‘outline-minor-mode-hook ‘outshine-hook-function)
>> > ;; # #+end_src
>> >
>> > the add-hook returns 
>> >
>> > Debugger entered--Lisp error: (void-variable ‘outline-minor-mode-hook)
>> >
>> >
>> > I am running 
>> >
>> > Org-mode version 8.0-pre (release_8.0-pre-276-g3d3465  <at>  ...
>> > GNU Emacs 24.3.1 (x86_64-apple-darwin, NS apple-appkit-1038.36) of
>> >  2013-03-12 on bob.porkrind.org
>> 
>> Looks as if outshine is loaded before outline? But since outshine
>> requires outline, 'outline-minor-mode-hook' should be loaded when the
>> hook function is added. 
>> It works here, I'm running:
>> 
>> ,----------------------------------------------------------------
>> | GNU Emacs Version:
>> | (24.3.1 24 3 gnu/linux hostname x86_64-unknown-linux-gnu x nil)
>> | Org-mode version 8.0-pre (release_8.0-pre-199-g2746c7  <at>  ...
>> `----------------------------------------------------------------
>> 
>> could you try 'M-x toggle-debug-on-error', execute the above, and send
>> the backtrace?
>> 
>
> This is what I get:
>
>
> Debugger entered--Lisp error: (void-variable ‘outline-minor-mode-hook)
>   (add-hook ‘outline-minor-mode-hook ‘outshine-hook-function)
>   eval((add-hook ‘outline-minor-mode-hook ‘outshine-hook-function) nil)
>   eval-last-sexp-1(nil)
>   eval-last-sexp(nil)
>   call-interactively(eval-last-sexp nil nil)
>
>
> FWIW, C-h v outline- TAB gives:
>
>
> Click <mouse-2> on a completion to select it.
> In this buffer, type RET to select the completion near point.
>
> Possible completions are:
> outline-blank-line                     outline-cycle-emulate-tab
> outline-font-lock-faces                outline-font-lock-keywords
> outline-heading-alist                  outline-heading-end-regexp
> outline-isearch-open-invisible-function         outline-level
> outline-minor-mode                     outline-minor-mode-map
> outline-minor-mode-menu-bar-map        outline-minor-mode-prefix
> outline-mode-abbrev-table              outline-mode-hook
> outline-mode-map                       outline-mode-menu-bar-map
> outline-mode-prefix-map                outline-mode-syntax-table
> outline-promotion-headings             outline-regexp
> outline-structedit-modifiers           outline-view-change-hook


strange, I get:

,------------------------------------------------------------------------------
| Click <mouse-2> on a completion to select it.
| In this buffer, type RET to select the completion near point.
| 
| Possible completions are:
| outline-blank-line                     outline-cycle-emulate-tab  (option)
| outline-font-lock-faces                outline-font-lock-keywords
| outline-heading-alist                  outline-heading-end-regexp  (option)
| outline-isearch-open-invisible-function         outline-level
| outline-minor-mode                     outline-minor-mode-hook
| outline-minor-mode-map                 outline-minor-mode-menu-bar-map
| outline-minor-mode-prefix  (option)    outline-mode-abbrev-table
| outline-mode-hook                      outline-mode-map
| outline-mode-menu-bar-map              outline-mode-prefix-map
| outline-mode-syntax-table              outline-promotion-headings
| outline-regexp  (option)               outline-structedit-modifiers  (option)
| outline-view-change-hook
`------------------------------------------------------------------------------

and with C-h v outline-minor-mode-hook:

,-----------------------------------------------------------
| outline-minor-mode-hook's value is (outshine-hook-function
|  (lambda nil
|    (require 'outline-mode-easy-bindings)))
`-----------------------------------------------------------

doesn't say where it is defined, I think its implicitly defined by macro
'define-minor-mode' in outline.el. 

When you do

,----------------------------------------------
| M-: (find-file (locate-library "outline.el"))
`----------------------------------------------

do you have this starting from line 356?
(outline.el doesn't seem to have a version variable, unfortunately)

,------------------------------------------------------------------------------
| ;;;###autoload
| (define-minor-mode outline-minor-mode
|   "Toggle Outline minor mode.
| With a prefix argument ARG, enable Outline minor mode if ARG is
| positive, and disable it otherwise.  If called from Lisp, enable
| the mode if ARG is omitted or nil.
| 
| See the command `outline-mode' for more information on this mode."
|   nil " Outl" (list (cons [menu-bar] outline-minor-mode-menu-bar-map)
|                     (cons outline-minor-mode-prefix outline-mode-prefix-map))
|   :group 'outlines
|   (if outline-minor-mode
|       (progn
|         ;; Turn off this mode if we change major modes.
|         (add-hook 'change-major-mode-hook
|                   (lambda () (outline-minor-mode -1))
|                   nil t)
|         (set (make-local-variable 'line-move-ignore-invisible) t)
|         ;; Cause use of ellipses for invisible text.
|         (add-to-invisibility-spec '(outline . t)))
|     (setq line-move-ignore-invisible nil)
|     ;; Cause use of ellipses for invisible text.
|     (remove-from-invisibility-spec '(outline . t))
|     ;; When turning off outline mode, get rid of any outline hiding.
|     (show-all)))
`------------------------------------------------------------------------------

-- 
cheers,
Thorsten




reply via email to

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