[Feature Request] Regular Expressions option in Live Search?

A place for users to ask each other questions, make suggestions, and discuss Bookends.
Post Reply
iandol
Posts: 481
Joined: Fri Jan 25, 2008 2:31 pm

[Feature Request] Regular Expressions option in Live Search?

Post by iandol »

I use Live Search (⌘⌥F) a lot, and really like that it doesn't modify the Hits list (which Find... and SQL search do) and is very flexible. However it would be even more flexible if we could use regular expressions, for example ^xxx to find something beginning with xxx etc. We could enable/disable this in the Live search menu or otherwise the Preferences. It would allow a much more powerful way of quickly filtering the reference list. It could be off by default so it doesn't disturb users who do not know about regular expressions.

Here is an example UI for a similar feature in Scrivener:
Screen Shot 2017-12-07 at 15.36.28_SMALL.png
Screen Shot 2017-12-07 at 15.36.28_SMALL.png (14.08 KiB) Viewed 3392 times
Jon
Site Admin
Posts: 10291
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: [Feature Request] Regular Expressions option in Live Search?

Post by Jon »

Live search is meant to be easy, fast, accessible. More complex searches, including Regex, are available via Refs -> SQL/Regex searches or Find (Command-F). Note that the default Live Search option is for "words beginning with". Whole word/partial word searches are done by enclosing the search term(s) in quote marks. If you want something more elaborate use SQL/Regex searches.

Jon
Sonny Software
iandol
Posts: 481
Joined: Fri Jan 25, 2008 2:31 pm

Re: [Feature Request] Regular Expressions option in Live Search?

Post by iandol »

Well I find regex fast and easy, but perhaps I'm an outlier! :D As I said the problems with Find or SQL are that they modify the hits list, which is why for quick searches I prefer Live Search (quickly find a ref I want to check before doing anything with hits). Regex can be entered quickly yet be much more specific than "words beginning with" or "phrase" searches. I was hoping this would be part of the search system programming API you use under the hood, and that it would be simple to implement. But I understand you have to balance the the cost of a new feature with the potential benefits.
Jon
Site Admin
Posts: 10291
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: [Feature Request] Regular Expressions option in Live Search?

Post by Jon »

If you are using the Hits List to keep track of references you're holding it wrong. :-)

That's what groups are for (and it's easy to go from hits to groups and back again).

Jon
Sonny Software
iandol
Posts: 481
Joined: Fri Jan 25, 2008 2:31 pm

Re: [Feature Request] Regular Expressions option in Live Search?

Post by iandol »

I'm often holding things wrong :wink: — but at least in this case I'm using hits only for short term sets that I'm using e.g. in an email, or to formulate a temporary idea I may throw away, quick sets that can make their way to the bibliography window...
Post Reply