Jump to content

Filter results (match): word boundary or space delimited ?


Recommended Posts

Sorry @Andrew for asking you directly, but I think you're the only one that really know the answer since you're the one implementing it...

 

I've been testing/using the new Match Mode of the Script Filters and I thought that when you said word boundaries that would mean word separated by white spaces. However, from testing this seems to be only true for word delimited by spaces. So, any other white spaces directly in front of a word (newline '\n' or tab '\t') would make this word to never match... At the moment I'm modifying the string before setting the 'match' item of the JSON to replace '\n' and '\t' with space, but I was wondering if this was your intention to only allow spaces to delimit words ?

 

Here is a workflow to show you an example. Filter the results with the word 'match' [wbf match] and you will see that not all items are kept: https://nofile.io/f/sx6xst0g3RC/Example-Word+Boundary+Filtering.alfredworkflow

 

I'm repeating myself, but thanks for this addition in Alfred! :)

 

Best!

Link to post

ok, so simply whitespaces = simply spaces at the moment (other whitespace elements are for later)

 

Thanks for confirming and I'll keep modifying my strings while a wider range of word boundaries isn't possible. However, to make it clearer for the user and avoid any confusion, maybe you should specify that word boundaries are delimited by spaces instead of using the word "whitespaces" since whitespace habitually means any character that add space between word in a text (I mean, newlines and tabs are also whitespaces, so it's a little confusing)

Edited by GuiB
Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...