Re: Search Thread
"John E. Davis" <[email protected]> Sat, 19 May 2012 10:21:20 -0400
| Newsgroups | gmane.network.slrn.user |
|---|---|
| Message-ID | <[email protected]> |
T <[email protected]> wrote: > Pressing / in article view prompts for text and searches the current > article for that text. Is there a way to search all articles in the thread > for the text, instead of having go to each one? You might try these functions. The main interface is through the "newsgroup_searches" function, which I have bound to the "$" key. You may want to change that. --John private variable Last_Art_Search_Str = ""; private define search_newsgroup_or_thread (confine_to_thread) { variable str; variable flags; str = read_mini ("Search for regexp: ", Last_Art_Search_Str, ""); if (str == "") return; Last_Art_Search_Str = str; if (confine_to_thread) uncollapse_thread (); else uncollapse_threads (); forever { flags = get_header_flags (); if (re_search_article (str)) { pop (); return; } set_header_flags (flags); ifnot (header_down (1)) break; if (confine_to_thread && not has_parent ()) break; } if (is_article_visible ()) call ("hide_article"); throw RunTimeError, "Not found"; } define search_thread () { search_newsgroup_or_thread (1); } define search_newsgroup () { search_newsgroup_or_thread (1); } define newgroup_searches () { variable rsp; rsp = get_select_box_response ("NewsGroup Searches", % title "search articles", "search thread", 2); switch (rsp) { case 0: search_newsgroup (); } { case 1: search_thread (); } } definekey ("newsgroup_searches", "$", "article"); ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/