[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-27 Thread RickL
Thanks for your reply and your help.  This plugin is exactly what I needed, 
and should be part of the default file in my opinion.

On Wednesday, December 27, 2017 at 4:55:40 AM UTC-5, BJ wrote:
>
> take at look at Danielo's plugin:
>
> http://contextplugin.tiddlyspot.com/
>
> all the best
> BJ
>
> On Tuesday, December 26, 2017 at 10:12:50 PM UTC+1, RickL wrote:
>>
>> I must not have  been clear in my questionso I will try again...How 
>> can one find a word in a TiddlyWiki file by a simple search if it is buried 
>> in a long tiddler?
>>
>> Thanks
>>
>> On Saturday, December 9, 2017 at 11:58:32 AM UTC-5, RickL wrote:
>>>
>>> I have had this same question for quite a while.  Your answer helps but 
>>> still does not help if the phrase is buried deep in a long tiddler.  Any 
>>> way to highlight the search results?
>>>
>>> Thanks
>>>
>>> On Saturday, December 9, 2017 at 10:55:17 AM UTC-5, Eric Shulman wrote:

 On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:
>
> When I search in TW5 with a phrase, I get all the tidders which have a 
> word or more of the phrase in any sequence in the title or the body. 
>
> Is there an option or plugin to search only for the exact phrase in 
> the title or the body?
>

 You can use the [regexp[...]] filter operator to search for exact 
 phrase matches including spaces.

 1) Open the $:/AdvancedSearch panel (click the magnifying glass icon 
 next to the regular sidebar search input field)
 2) In $:/AdvancedSearch, switch to the "Filter" tab
 3a) To search titles, enter your search syntax like this:
[regexp[your phrase here]]
 3b) To search tiddler text, enter your search like this:
[regexp:text[your phrase here]]

 Notes:
 * Because the syntax uses square brackets, you cannot search for text 
 that includes square brackets.
 * If you want to search both title AND text fields at the same time, 
 you can combine the filters in a sequence, separated by a space, like this:
[regexp[your phrase here]] [regexp:text[your phrase here]]
 * If you don't want to use the $:/AdvancedSearch interface, you can 
 create your own custom interface by putting the following syntax into a 
 tiddler you create:

 <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
 <$reveal state="$:/temp/mysearch" type="nomatch" text="">
 <>>> [regexp:text{$:/temp/mysearch}] -[title[$:/temp/mysearch]]">>
 

 * The $edit-text widget stores your search input in $:/temp/mysearch 
 (you can use any tiddler name you like, but something starting with 
 "$:/temp/..." is recommended to avoid cluttering up your regular list of 
 tiddlers)
 * The $reveal widget prevents listing ALL tiddlers when the search 
 input is blank.
 * The <> macro shows a bullet list using the combined 
 title/text search filter, and also automatically excludes the temporary 
 tiddler that holds your search input text.
 * Because the custom search uses a separate tiddler to store the search 
 text, you CAN search for text containing square brackets, as it avoids 
 conflicting with the surrounding filter syntax.
 * If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
 appear as an extra tab in the sidebar, allowing you to quickly invoke the 
 custom search at any time.

 enjoy,
 -e
 Eric Shulman
 TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
 InsideTiddlyWiki: The Missing Manuals

>>>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/3b1059ad-cf18-4607-b966-333a3cadf481%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-27 Thread BJ
take at look at Danielo's plugin:

http://contextplugin.tiddlyspot.com/

all the best
BJ

On Tuesday, December 26, 2017 at 10:12:50 PM UTC+1, RickL wrote:
>
> I must not have  been clear in my questionso I will try again...How 
> can one find a word in a TiddlyWiki file by a simple search if it is buried 
> in a long tiddler?
>
> Thanks
>
> On Saturday, December 9, 2017 at 11:58:32 AM UTC-5, RickL wrote:
>>
>> I have had this same question for quite a while.  Your answer helps but 
>> still does not help if the phrase is buried deep in a long tiddler.  Any 
>> way to highlight the search results?
>>
>> Thanks
>>
>> On Saturday, December 9, 2017 at 10:55:17 AM UTC-5, Eric Shulman wrote:
>>>
>>> On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:

 When I search in TW5 with a phrase, I get all the tidders which have a 
 word or more of the phrase in any sequence in the title or the body. 

 Is there an option or plugin to search only for the exact phrase in the 
 title or the body?

>>>
>>> You can use the [regexp[...]] filter operator to search for exact phrase 
>>> matches including spaces.
>>>
>>> 1) Open the $:/AdvancedSearch panel (click the magnifying glass icon 
>>> next to the regular sidebar search input field)
>>> 2) In $:/AdvancedSearch, switch to the "Filter" tab
>>> 3a) To search titles, enter your search syntax like this:
>>>[regexp[your phrase here]]
>>> 3b) To search tiddler text, enter your search like this:
>>>[regexp:text[your phrase here]]
>>>
>>> Notes:
>>> * Because the syntax uses square brackets, you cannot search for text 
>>> that includes square brackets.
>>> * If you want to search both title AND text fields at the same time, you 
>>> can combine the filters in a sequence, separated by a space, like this:
>>>[regexp[your phrase here]] [regexp:text[your phrase here]]
>>> * If you don't want to use the $:/AdvancedSearch interface, you can 
>>> create your own custom interface by putting the following syntax into a 
>>> tiddler you create:
>>>
>>> <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
>>> <$reveal state="$:/temp/mysearch" type="nomatch" text="">
>>> <>> [regexp:text{$:/temp/mysearch}] -[title[$:/temp/mysearch]]">>
>>> 
>>>
>>> * The $edit-text widget stores your search input in $:/temp/mysearch 
>>> (you can use any tiddler name you like, but something starting with 
>>> "$:/temp/..." is recommended to avoid cluttering up your regular list of 
>>> tiddlers)
>>> * The $reveal widget prevents listing ALL tiddlers when the search input 
>>> is blank.
>>> * The <> macro shows a bullet list using the combined 
>>> title/text search filter, and also automatically excludes the temporary 
>>> tiddler that holds your search input text.
>>> * Because the custom search uses a separate tiddler to store the search 
>>> text, you CAN search for text containing square brackets, as it avoids 
>>> conflicting with the surrounding filter syntax.
>>> * If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
>>> appear as an extra tab in the sidebar, allowing you to quickly invoke the 
>>> custom search at any time.
>>>
>>> enjoy,
>>> -e
>>> Eric Shulman
>>> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
>>> InsideTiddlyWiki: The Missing Manuals
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/7b350c8b-58d7-493c-918c-16690d57a402%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-26 Thread RickL
I must not have  been clear in my questionso I will try again...How can 
one find a word in a TiddlyWiki file by a simple search if it is buried in 
a long tiddler?

Thanks

On Saturday, December 9, 2017 at 11:58:32 AM UTC-5, RickL wrote:
>
> I have had this same question for quite a while.  Your answer helps but 
> still does not help if the phrase is buried deep in a long tiddler.  Any 
> way to highlight the search results?
>
> Thanks
>
> On Saturday, December 9, 2017 at 10:55:17 AM UTC-5, Eric Shulman wrote:
>>
>> On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:
>>>
>>> When I search in TW5 with a phrase, I get all the tidders which have a 
>>> word or more of the phrase in any sequence in the title or the body. 
>>>
>>> Is there an option or plugin to search only for the exact phrase in the 
>>> title or the body?
>>>
>>
>> You can use the [regexp[...]] filter operator to search for exact phrase 
>> matches including spaces.
>>
>> 1) Open the $:/AdvancedSearch panel (click the magnifying glass icon next 
>> to the regular sidebar search input field)
>> 2) In $:/AdvancedSearch, switch to the "Filter" tab
>> 3a) To search titles, enter your search syntax like this:
>>[regexp[your phrase here]]
>> 3b) To search tiddler text, enter your search like this:
>>[regexp:text[your phrase here]]
>>
>> Notes:
>> * Because the syntax uses square brackets, you cannot search for text 
>> that includes square brackets.
>> * If you want to search both title AND text fields at the same time, you 
>> can combine the filters in a sequence, separated by a space, like this:
>>[regexp[your phrase here]] [regexp:text[your phrase here]]
>> * If you don't want to use the $:/AdvancedSearch interface, you can 
>> create your own custom interface by putting the following syntax into a 
>> tiddler you create:
>>
>> <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
>> <$reveal state="$:/temp/mysearch" type="nomatch" text="">
>> <> -[title[$:/temp/mysearch]]">>
>> 
>>
>> * The $edit-text widget stores your search input in $:/temp/mysearch (you 
>> can use any tiddler name you like, but something starting with 
>> "$:/temp/..." is recommended to avoid cluttering up your regular list of 
>> tiddlers)
>> * The $reveal widget prevents listing ALL tiddlers when the search input 
>> is blank.
>> * The <> macro shows a bullet list using the combined 
>> title/text search filter, and also automatically excludes the temporary 
>> tiddler that holds your search input text.
>> * Because the custom search uses a separate tiddler to store the search 
>> text, you CAN search for text containing square brackets, as it avoids 
>> conflicting with the surrounding filter syntax.
>> * If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
>> appear as an extra tab in the sidebar, allowing you to quickly invoke the 
>> custom search at any time.
>>
>> enjoy,
>> -e
>> Eric Shulman
>> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
>> InsideTiddlyWiki: The Missing Manuals
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/9d5b8ef9-298d-4f6c-8cc9-3a15bfcf6eb5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-11 Thread coda coder


On Saturday, December 9, 2017 at 7:49:58 PM UTC-6, John wrote:
>
> 3- In classic TW, I used to search long tiddlers by pressing ctl-F in the 
> browser window. With TW5 under NW, is there a way to have a "find" function 
> similar to ctl-F of the browser?
>

Sorry to point this out, but Ctrl-F (like a back button, bookmarks and 
anything else you normally access from a menu) are "browser features".  NW 
is not a browser.  So Ctrl-F et al do not exist unless they are 
re-implemented by the underlying "page" (read: a ton of work to code and 
support).

Coda

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/d7b877cc-9839-4ee3-bcc3-d62057fd21a5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-09 Thread John
Thank you very much Eric. I really appreciate your help.  


On Sunday, December 10, 2017 at 2:57:50 PM UTC+11, Eric Shulman wrote:
>
> On Saturday, December 9, 2017 at 5:49:58 PM UTC-8, John wrote:
>>
>> Thank you Eric for your comprehensive answer.
>> I have three more questions while I have your attention: 
>>
>> 1- How to force the custom search to ignore case? 
>>
> I can do this by typing (?i)(Some Example) in the input box and it works.
>> I want to put it in the custom search tiddler code. I tried all 
>> combinations of brackets around $:/temp/mysearch but nothing worked.
>
>
> This is a bit more complex... but only a little.  The trick is to define a 
> macro (e.g., "makefilter") that assembles the complete filter syntax using 
> a variable, like this:
>
> \define makefilter() [regexp[(?i)$(pattern)$]] [regexp:text[(?i)$(pattern)
> $]] -[title[$:/temp/mysearch]]
>
> <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
> <$reveal state="$:/temp/mysearch" type="nomatch" text="">
> <$vars pattern={{$:/temp/mysearch}}>
> <$count filter=<>/> matches:
> <$macrocall $name="list-links" filter=<>/>
> 
> 
>
> * The "makefilter()" macro uses a variable named "pattern" that is defined 
> outside the macro itself
> * The $vars widget retrieves the value stored in $:/temp/mysearch and sets 
> the "pattern" variable, which surrounds the call to the list-links macro
> * You can't use a variable reference as a parameter in the < ...>> macro syntax, so we use the underlying <$macrocall> widget syntax 
> instead
> * Note: I added a bit of extra output using the <$count> widget to show 
> the number of matching results
>  
>
>> 2- How to replace the standard search with the new custom search? 
>>
>
> The standard search interface is defined within 
> the $:/core/ui/SideBarLists shadow tiddler, which also defines the output 
> of the tabbed lists below the search.  To use your custom search, you can 
> replace most of the content in $:/core/ui/SideBarLists, like this:
>
> 
> {{MySearch}}
> <$macrocall $name="tabs" 
> tabsList="[all[shadows+tiddlers]tag[$:/tags/SideBar]!has[draft.of]]" 
> default={{$:/config/DefaultSidebarTab}} state="$:/state/tab/sidebar" />
> 
>
> To make the custom search look nice in the sidebar, you can also add some 
> styling to the MySearch definition by surrounding the $macrocall within a 
> ... block, like this:
>
> 
> <$macrocall $name="list-links" filter=<>>
> 
>
> * The  uses the same class definitions ("tc-block-dropdown 
> tc-search-drop-down") as the standard search results.  This makes the 
> custom search results "float" on top of the sidebar lists, and gives it a 
> nice surrounding box with rounded corners and drop shadow.
>  
>
>> 3- In classic TW, I used to search long tiddlers by pressing ctl-F in the 
>> browser window. With TW5 under NW, is there a way to have a "find" function 
>> similar to ctl-F of the browser?
>>
>
> I just use the browser's ctrl-F function, the same way as in TWClassic.
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
> InsideTiddlyWiki: The Missing Manuals
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/bc7dc0d9-6ec1-47e2-a02e-0f7623299333%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-09 Thread Eric Shulman
On Saturday, December 9, 2017 at 5:49:58 PM UTC-8, John wrote:
>
> Thank you Eric for your comprehensive answer.
> I have three more questions while I have your attention: 
>
> 1- How to force the custom search to ignore case? 
>
I can do this by typing (?i)(Some Example) in the input box and it works.
> I want to put it in the custom search tiddler code. I tried all 
> combinations of brackets around $:/temp/mysearch but nothing worked.


This is a bit more complex... but only a little.  The trick is to define a 
macro (e.g., "makefilter") that assembles the complete filter syntax using 
a variable, like this:

\define makefilter() [regexp[(?i)$(pattern)$]] [regexp:text[(?i)$(pattern)$
]] -[title[$:/temp/mysearch]]

<$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
<$reveal state="$:/temp/mysearch" type="nomatch" text="">
<$vars pattern={{$:/temp/mysearch}}>
<$count filter=<>/> matches:
<$macrocall $name="list-links" filter=<>/>



* The "makefilter()" macro uses a variable named "pattern" that is defined 
outside the macro itself
* The $vars widget retrieves the value stored in $:/temp/mysearch and sets 
the "pattern" variable, which surrounds the call to the list-links macro
* You can't use a variable reference as a parameter in the <> macro syntax, so we use the underlying <$macrocall> widget syntax 
instead
* Note: I added a bit of extra output using the <$count> widget to show the 
number of matching results
 

> 2- How to replace the standard search with the new custom search? 
>

The standard search interface is defined within the $:/core/ui/SideBarLists 
shadow tiddler, which also defines the output of the tabbed lists below the 
search.  To use your custom search, you can replace most of the content in 
$:/core/ui/SideBarLists, like this:


{{MySearch}}
<$macrocall $name="tabs" 
tabsList="[all[shadows+tiddlers]tag[$:/tags/SideBar]!has[draft.of]]" 
default={{$:/config/DefaultSidebarTab}} state="$:/state/tab/sidebar" />


To make the custom search look nice in the sidebar, you can also add some 
styling to the MySearch definition by surrounding the $macrocall within a 
... block, like this:


<$macrocall $name="list-links" filter=<>>


* The  uses the same class definitions ("tc-block-dropdown 
tc-search-drop-down") as the standard search results.  This makes the 
custom search results "float" on top of the sidebar lists, and gives it a 
nice surrounding box with rounded corners and drop shadow.
 

> 3- In classic TW, I used to search long tiddlers by pressing ctl-F in the 
> browser window. With TW5 under NW, is there a way to have a "find" function 
> similar to ctl-F of the browser?
>

I just use the browser's ctrl-F function, the same way as in TWClassic.

enjoy,
-e
Eric Shulman
TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
InsideTiddlyWiki: The Missing Manuals

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/4b187f64-204e-474c-a502-3a43264a637c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-09 Thread John
Thank you Eric for your comprehensive answer.

I have three more questions while I have your attention: 

1- How to force the custom search to ignore case? 

I can do this by typing (?i)(Some Example) in the input box and it works.
I want to put it in the custom search tiddler code. I tried all 
combinations of brackets around $:/temp/mysearch but nothing worked.

2- How to replace the standard search with the new custom search? 

3- In classic TW, I used to search long tiddlers by pressing ctl-F in the 
browser window. With TW5 under NW, is there a way to have a "find" function 
similar to ctl-F of the browser?

Thank you


On Sunday, December 10, 2017 at 2:55:17 AM UTC+11, Eric Shulman wrote:
>
> On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:
>>
>> When I search in TW5 with a phrase, I get all the tidders which have a 
>> word or more of the phrase in any sequence in the title or the body. 
>>
>> Is there an option or plugin to search only for the exact phrase in the 
>> title or the body?
>>
>
> You can use the [regexp[...]] filter operator to search for exact phrase 
> matches including spaces.
>
> 1) Open the $:/AdvancedSearch panel (click the magnifying glass icon next 
> to the regular sidebar search input field)
> 2) In $:/AdvancedSearch, switch to the "Filter" tab
> 3a) To search titles, enter your search syntax like this:
>[regexp[your phrase here]]
> 3b) To search tiddler text, enter your search like this:
>[regexp:text[your phrase here]]
>
> Notes:
> * Because the syntax uses square brackets, you cannot search for text that 
> includes square brackets.
> * If you want to search both title AND text fields at the same time, you 
> can combine the filters in a sequence, separated by a space, like this:
>[regexp[your phrase here]] [regexp:text[your phrase here]]
> * If you don't want to use the $:/AdvancedSearch interface, you can create 
> your own custom interface by putting the following syntax into a tiddler 
> you create:
>
> <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
> <$reveal state="$:/temp/mysearch" type="nomatch" text="">
> < -[title[$:/temp/mysearch]]">>
> 
>
> * The $edit-text widget stores your search input in $:/temp/mysearch (you 
> can use any tiddler name you like, but something starting with 
> "$:/temp/..." is recommended to avoid cluttering up your regular list of 
> tiddlers)
> * The $reveal widget prevents listing ALL tiddlers when the search input 
> is blank.
> * The <> macro shows a bullet list using the combined 
> title/text search filter, and also automatically excludes the temporary 
> tiddler that holds your search input text.
> * Because the custom search uses a separate tiddler to store the search 
> text, you CAN search for text containing square brackets, as it avoids 
> conflicting with the surrounding filter syntax.
> * If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
> appear as an extra tab in the sidebar, allowing you to quickly invoke the 
> custom search at any time.
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
> InsideTiddlyWiki: The Missing Manuals
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/e9a6d16a-667d-44cc-9331-9a1ae004d6ac%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-09 Thread Diego Mesa
Eric,

Your answers are always thorough and well explained.They are an 
inspiration. Thank you!! 

On Saturday, December 9, 2017 at 9:55:17 AM UTC-6, Eric Shulman wrote:
>
> On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:
>>
>> When I search in TW5 with a phrase, I get all the tidders which have a 
>> word or more of the phrase in any sequence in the title or the body. 
>>
>> Is there an option or plugin to search only for the exact phrase in the 
>> title or the body?
>>
>
> You can use the [regexp[...]] filter operator to search for exact phrase 
> matches including spaces.
>
> 1) Open the $:/AdvancedSearch panel (click the magnifying glass icon next 
> to the regular sidebar search input field)
> 2) In $:/AdvancedSearch, switch to the "Filter" tab
> 3a) To search titles, enter your search syntax like this:
>[regexp[your phrase here]]
> 3b) To search tiddler text, enter your search like this:
>[regexp:text[your phrase here]]
>
> Notes:
> * Because the syntax uses square brackets, you cannot search for text that 
> includes square brackets.
> * If you want to search both title AND text fields at the same time, you 
> can combine the filters in a sequence, separated by a space, like this:
>[regexp[your phrase here]] [regexp:text[your phrase here]]
> * If you don't want to use the $:/AdvancedSearch interface, you can create 
> your own custom interface by putting the following syntax into a tiddler 
> you create:
>
> <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
> <$reveal state="$:/temp/mysearch" type="nomatch" text="">
> < -[title[$:/temp/mysearch]]">>
> 
>
> * The $edit-text widget stores your search input in $:/temp/mysearch (you 
> can use any tiddler name you like, but something starting with 
> "$:/temp/..." is recommended to avoid cluttering up your regular list of 
> tiddlers)
> * The $reveal widget prevents listing ALL tiddlers when the search input 
> is blank.
> * The <> macro shows a bullet list using the combined 
> title/text search filter, and also automatically excludes the temporary 
> tiddler that holds your search input text.
> * Because the custom search uses a separate tiddler to store the search 
> text, you CAN search for text containing square brackets, as it avoids 
> conflicting with the surrounding filter syntax.
> * If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
> appear as an extra tab in the sidebar, allowing you to quickly invoke the 
> custom search at any time.
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
> InsideTiddlyWiki: The Missing Manuals
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/d34023bf-cdde-470f-89a3-c2c8c2e1cdfc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-09 Thread RickL
I have had this same question for quite a while.  Your answer helps but 
still does not help if the phrase is buried deep in a long tiddler.  Any 
way to highlight the search results?

Thanks

On Saturday, December 9, 2017 at 10:55:17 AM UTC-5, Eric Shulman wrote:
>
> On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:
>>
>> When I search in TW5 with a phrase, I get all the tidders which have a 
>> word or more of the phrase in any sequence in the title or the body. 
>>
>> Is there an option or plugin to search only for the exact phrase in the 
>> title or the body?
>>
>
> You can use the [regexp[...]] filter operator to search for exact phrase 
> matches including spaces.
>
> 1) Open the $:/AdvancedSearch panel (click the magnifying glass icon next 
> to the regular sidebar search input field)
> 2) In $:/AdvancedSearch, switch to the "Filter" tab
> 3a) To search titles, enter your search syntax like this:
>[regexp[your phrase here]]
> 3b) To search tiddler text, enter your search like this:
>[regexp:text[your phrase here]]
>
> Notes:
> * Because the syntax uses square brackets, you cannot search for text that 
> includes square brackets.
> * If you want to search both title AND text fields at the same time, you 
> can combine the filters in a sequence, separated by a space, like this:
>[regexp[your phrase here]] [regexp:text[your phrase here]]
> * If you don't want to use the $:/AdvancedSearch interface, you can create 
> your own custom interface by putting the following syntax into a tiddler 
> you create:
>
> <$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
> <$reveal state="$:/temp/mysearch" type="nomatch" text="">
> < -[title[$:/temp/mysearch]]">>
> 
>
> * The $edit-text widget stores your search input in $:/temp/mysearch (you 
> can use any tiddler name you like, but something starting with 
> "$:/temp/..." is recommended to avoid cluttering up your regular list of 
> tiddlers)
> * The $reveal widget prevents listing ALL tiddlers when the search input 
> is blank.
> * The <> macro shows a bullet list using the combined 
> title/text search filter, and also automatically excludes the temporary 
> tiddler that holds your search input text.
> * Because the custom search uses a separate tiddler to store the search 
> text, you CAN search for text containing square brackets, as it avoids 
> conflicting with the surrounding filter syntax.
> * If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
> appear as an extra tab in the sidebar, allowing you to quickly invoke the 
> custom search at any time.
>
> enjoy,
> -e
> Eric Shulman
> TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
> InsideTiddlyWiki: The Missing Manuals
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/d299583d-47e5-46bc-be5a-f485dd3008b3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[tw] Re: search TW5 tiddlers body for exact phrase

2017-12-09 Thread Eric Shulman
On Saturday, December 9, 2017 at 7:06:51 AM UTC-8, John wrote:
>
> When I search in TW5 with a phrase, I get all the tidders which have a 
> word or more of the phrase in any sequence in the title or the body. 
>
> Is there an option or plugin to search only for the exact phrase in the 
> title or the body?
>

You can use the [regexp[...]] filter operator to search for exact phrase 
matches including spaces.

1) Open the $:/AdvancedSearch panel (click the magnifying glass icon next 
to the regular sidebar search input field)
2) In $:/AdvancedSearch, switch to the "Filter" tab
3a) To search titles, enter your search syntax like this:
   [regexp[your phrase here]]
3b) To search tiddler text, enter your search like this:
   [regexp:text[your phrase here]]

Notes:
* Because the syntax uses square brackets, you cannot search for text that 
includes square brackets.
* If you want to search both title AND text fields at the same time, you 
can combine the filters in a sequence, separated by a space, like this:
   [regexp[your phrase here]] [regexp:text[your phrase here]]
* If you don't want to use the $:/AdvancedSearch interface, you can create 
your own custom interface by putting the following syntax into a tiddler 
you create:

<$edit-text tiddler="$:/temp/mysearch" tag="input" default=""/>
<$reveal state="$:/temp/mysearch" type="nomatch" text="">
<>


* The $edit-text widget stores your search input in $:/temp/mysearch (you 
can use any tiddler name you like, but something starting with 
"$:/temp/..." is recommended to avoid cluttering up your regular list of 
tiddlers)
* The $reveal widget prevents listing ALL tiddlers when the search input is 
blank.
* The <> macro shows a bullet list using the combined 
title/text search filter, and also automatically excludes the temporary 
tiddler that holds your search input text.
* Because the custom search uses a separate tiddler to store the search 
text, you CAN search for text containing square brackets, as it avoids 
conflicting with the surrounding filter syntax.
* If you add the tag "$:/tags/SideBar" to your custom tiddler, it will 
appear as an extra tab in the sidebar, allowing you to quickly invoke the 
custom search at any time.

enjoy,
-e
Eric Shulman
TiddlyTools.com: "Small Tools for Big Ideas!" (tm)
InsideTiddlyWiki: The Missing Manuals

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/eea03f4d-5cd0-40d8-b890-522f944562ec%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.