jed-users mailing list

[2005 Date Index] [2005 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

Re: no key for search again


On 25.10.05, Vladan Bato wrote:
> Holger Lillqvist wrote:
> 
> >Just hit <enter>. After the first search there is a message: "Press
> >RET to search again".
> 
> 
> Yes, but if you type anything else (for example to scroll the window or
> modify the text) it exits from the search and you have to start it all
> over again.

In jed 99.17 you can bind the function cua_repeat_search() to a key (or use
the CUA emulation where it is bound to Ctrl-L).

Otherwise use the following function

%{{{ repeat_search()  % should go to srchmisc.sl
%                       (and be used by ide.sl and brief.sl)
%!%+
%\function{repeat_search}
%\synopsis{continue searching with last searchstring}
%\usage{define repeat_search ()}
%\seealso{LAST_SEARCH, search_forward, search_backward}
%!%-
public define repeat_search()
{
   !if (strlen(LAST_SEARCH))
     {
	message("no previous search");
	return menu_select_menu("Global.&Search");
     }
   go_right (1);
   !if (fsearch(LAST_SEARCH)) error ("Not found.");
}
%}}}


> And bind search_next to any the key you want to use (I have no idea on
> how to put in the menu as I don't use it).

This can be done by e.g.

define search_load_popup_hook (menubar)
{
   menu_insert_item (2, "Global.&Search", "Repeat &Search", "repeat_search");
}
append_to_hook ("load_popup_hooks", &search_load_popup_hook);

in .jedrc.


Guenter

 
> P.S. Just a suggestion for the list maintainer: put
> jed-users@xxxxxxxxxxx in the Reply-To: header, so that a simple reply
> will go to the list by default. I sent this mail just to Holger by mistake.

However, with the current setting (and mutt) I have the easy choice of
replying to the sender alone with "r" or the list with "L".



-- 
G.Milde web.de

--------------------------
To unsubscribe send email to <jed-users-request@xxxxxxxxxxx> with
the word "unsubscribe" in the message body.
Need help? Email <jed-users-owner@xxxxxxxxxxx>.


[2005 date index] [2005 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]