Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
Hi Bastien, Thanks for the idea. Doesn't work. Maybe it's an emacs bug. On Fri, Jul 3, 2009 at 02:18, Bastien wrote: > My other guess would be that the macro execution is too fast for the > display engine. Maybe the trick is to insert a command in your macro > sequence that makes sure the tab is displayed correctly before you try > to remember it. > > C-x ( f8 f8 n M-> M-< c-x ) > ^^^ <- this goes to the end and beginning of buffer > > Anyway, you might have clearer/cleverer answers on help-gnu-emacs@ > > HTH, > > -- > Bastien > ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
Samuel Wales writes: > On each of my many emacs-w3m tabs, I can remember manually with f8 f8 > n (my binding for org-remember and my ?n template which I sent). It > grabs the title and URL perfectly. I can also do m-right, which is my > binding for next tab. > > To use the macro, I do c-x ( f8 f8 n m-right c-x ) . To execute it I > do c-x e. It does not get executed on any tabs. My other guess would be that the macro execution is too fast for the display engine. Maybe the trick is to insert a command in your macro sequence that makes sure the tab is displayed correctly before you try to remember it. C-x ( f8 f8 n M-> M-< c-x ) ^^^ <- this goes to the end and beginning of buffer Anyway, you might have clearer/cleverer answers on help-gnu-emacs@ HTH, -- Bastien ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
On each of my many emacs-w3m tabs, I can remember manually with f8 f8 n (my binding for org-remember and my ?n template which I sent). It grabs the title and URL perfectly. I can also do m-right, which is my binding for next tab. To use the macro, I do c-x ( f8 f8 n m-right c-x ) . To execute it I do c-x e. It does not get executed on any tabs. Thanks. On 2009-07-02, Bastien wrote: > Samuel Wales writes: > >> It happens on all tabs. > > You mean on *each* tab? > >> ("note" ?n "* %? %i -- %a %U\n%i") > > Can you remember at least one tab with this template? > > Can you send the full macro? > > -- > Bastien > -- Myalgic encephalomyelitis is causing death and severe suffering worse than MS. Conflicts of interest are destroying research. People get the disease at any time permanently. Do science and justice matter to you? http://www.meactionuk.org.uk/What_Is_ME_What_Is_CFS.htm ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
Samuel Wales writes: > It happens on all tabs. You mean on *each* tab? > ("note" ?n "* %? %i -- %a %U\n%i") Can you remember at least one tab with this template? Can you send the full macro? -- Bastien ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
Hi Bastien, It happens on all tabs. ("note" ?n "* %? %i -- %a %U\n%i") Thanks. On Wed, Jul 1, 2009 at 22:52, Bastien wrote: > Samuel Wales writes: > >> I cannot use org-remember to save all my w3m tabs using remember and >> keyboard macros. > > Are you using a specific remember template when remembering those > w3m tabs? My guess is that your remember template tries to fetch > a title or same tab-related info that isn't available for some tab. > >> Says command rang the bell, but I don't know which even with stack trace on. >> >> call-last-kbd-macro(nil kmacro-loop-setup-function) >> kmacro-call-macro(nil nil) >> kmacro-end-and-call-macro(nil) >> call-interactively(kmacro-end-and-call-macro) >> >> Is this related? > > Looks like some tab prevents the macro from being repeated correctly. > > Maybe you can try to debug this like this: > > 1. use several identic tabs (and see if the error occurs); > 2. use two different tabs, then three, etc. > > HTH > > -- > Bastien > -- Myalgic encephalomyelitis is causing death and severe suffering worse than MS. Conflicts of interest are destroying research. People get the disease at any time permanently. Do science and justice matter to you? http://www.meactionuk.org.uk/What_Is_ME_What_Is_CFS.htm ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
Samuel Wales writes: > I cannot use org-remember to save all my w3m tabs using remember and > keyboard macros. Are you using a specific remember template when remembering those w3m tabs? My guess is that your remember template tries to fetch a title or same tab-related info that isn't available for some tab. > Says command rang the bell, but I don't know which even with stack trace on. > > call-last-kbd-macro(nil kmacro-loop-setup-function) > kmacro-call-macro(nil nil) > kmacro-end-and-call-macro(nil) > call-interactively(kmacro-end-and-call-macro) > > Is this related? Looks like some tab prevents the macro from being repeated correctly. Maybe you can try to debug this like this: 1. use several identic tabs (and see if the error occurs); 2. use two different tabs, then three, etc. HTH -- Bastien ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
I cannot use org-remember to save all my w3m tabs using remember and keyboard macros. Says command rang the bell, but I don't know which even with stack trace on. call-last-kbd-macro(nil kmacro-loop-setup-function) kmacro-call-macro(nil nil) kmacro-end-and-call-macro(nil) call-interactively(kmacro-end-and-call-macro) Is this related? ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: bug#3597: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
Thanks, I'll check it out. - Carsten On Jun 27, 2009, at 2:43 AM, Stefan Monnier wrote: This sounds like interactive-p is working as documented and the excplicit check I proposed would be neccessary. True enough, and I am applying your fix. IIUC you may want to use called-interactively-p instead. Stefan ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: bug#3597: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
>> This sounds like interactive-p is working as documented and the >> excplicit check I proposed would be neccessary. > True enough, and I am applying your fix. IIUC you may want to use called-interactively-p instead. Stefan ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
On Jun 24, 2009, at 2:39 PM, Andreas Seltenreich wrote: [Sorry about setting Cc instead X-Debbugs-Cc and causing the duplicate report. I set a proper Mail-Followup-To header now.] Carsten Dominik writes: This looks to me as if it was a bug in keyboard macro execution, which should call functions interactively. The docstring for interactive-p has the following paragraph: ,[ C-h f interactive-p RET ] | The only known proper use of `interactive-p' is in deciding whether to | display a helpful message, or how to display it. If you're thinking | of using it for any other purpose, it is quite likely that you're | making a mistake. Think: what do you want to do when the command is | called from a keyboard macro? ` The elisp reference states: ,[ (info "(elisp)Distinguish Interactive") ] | -- Function: interactive-p | This function returns `t' if the containing function (the one | whose code includes the call to `interactive-p') was called in | direct response to user input. This means that it was called with | the function `call-interactively', and that a keyboard macro is | not running, and that Emacs is not running in batch mode. ` This sounds like interactive-p is working as documented and the excplicit check I proposed would be neccessary. True enough, and I am applying your fix. Thanks. - Carsten Thanks, andreas ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
[Sorry about setting Cc instead X-Debbugs-Cc and causing the duplicate report. I set a proper Mail-Followup-To header now.] Carsten Dominik writes: > This looks to me as if it was a bug in keyboard macro execution, > which should call functions interactively. The docstring for interactive-p has the following paragraph: ,[ C-h f interactive-p RET ] | The only known proper use of `interactive-p' is in deciding whether to | display a helpful message, or how to display it. If you're thinking | of using it for any other purpose, it is quite likely that you're | making a mistake. Think: what do you want to do when the command is | called from a keyboard macro? ` The elisp reference states: ,[ (info "(elisp)Distinguish Interactive") ] | -- Function: interactive-p | This function returns `t' if the containing function (the one | whose code includes the call to `interactive-p') was called in | direct response to user input. This means that it was called with | the function `call-interactively', and that a keyboard macro is | not running, and that Emacs is not running in batch mode. ` This sounds like interactive-p is working as documented and the excplicit check I proposed would be neccessary. Thanks, andreas ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
This looks to me as if it was a bug in keyboard macro execution, which should call functions interactively. - Carsten On Jun 17, 2009, at 1:15 PM, Andreas Seltenreich wrote: Your bug report will be posted to the emacs-pretest-...@gnu.org mailing list. Please describe exactly what actions triggered the bug and the precise symptoms of the bug: org-store-link works fine when recording a keyboard macro but it is a NOP when executing it. The following change appears to fix it. regards, andreas In GNU Emacs 23.0.94.1 (x86_64-unknown-linux-gnu) of 2009-05-28 on tengen --8<---cut here---start->8--- *** org.el.~1.48.~ 2009-02-20 10:02:49.0 +0100 --- org.el 2009-06-17 12:55:15.0 +0200 *** *** 6594,6600 desc (or desc cpltxt)) (if (equal desc "NONE") (setq desc nil)) ! (if (and (interactive-p) link) (progn (setq org-stored-links (cons (list link desc) org-stored-links)) --- 6594,6600 desc (or desc cpltxt)) (if (equal desc "NONE") (setq desc nil)) ! (if (and (or (interactive-p) executing-kbd-macro) link) (progn (setq org-stored-links (cons (list link desc) org-stored-links)) --8<---cut here---end--->8--- ___ Emacs-orgmode mailing list Remember: 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 Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] 23.0.94; [PATCH] org-store-link broken within kbd macros
> Your bug report will be posted to the emacs-pretest-...@gnu.org mailing list. > Please describe exactly what actions triggered the bug > and the precise symptoms of the bug: org-store-link works fine when recording a keyboard macro but it is a NOP when executing it. The following change appears to fix it. regards, andreas > In GNU Emacs 23.0.94.1 (x86_64-unknown-linux-gnu) > of 2009-05-28 on tengen --8<---cut here---start->8--- *** org.el.~1.48.~ 2009-02-20 10:02:49.0 +0100 --- org.el 2009-06-17 12:55:15.0 +0200 *** *** 6594,6600 desc (or desc cpltxt)) (if (equal desc "NONE") (setq desc nil)) ! (if (and (interactive-p) link) (progn (setq org-stored-links (cons (list link desc) org-stored-links)) --- 6594,6600 desc (or desc cpltxt)) (if (equal desc "NONE") (setq desc nil)) ! (if (and (or (interactive-p) executing-kbd-macro) link) (progn (setq org-stored-links (cons (list link desc) org-stored-links)) --8<---cut here---end--->8--- ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode