[LH3475|3497] Inconsistencies when searching

ad
adrm
Posts: 47
Joined: Sun Dec 02, 2018 11:58 am
Platform: Windows

Thu Mar 14, 2019 5:17 pm Post

Not sure if this happens with all types of project searches (I think it does), but here's a concrete example:

1) I choose RegEx type search and enter ( {2,})
2) Fine, it locates all occurrences of two consecutive spaces and highlights their position in each document.

BUT the search also lists some documents where nothing is highlighted. Nothing in the text, the notes, foot notes, etc. For a moment I thought it had located two spaces in the scene name, but that proved not to be the case.

Am I overlooking something?

User avatar
tiho_d
Posts: 614
Joined: Tue Sep 13, 2011 1:14 pm
Platform: Linux + Windows

Thu Mar 14, 2019 6:32 pm Post

This is best described and reproduced with a demo project.

ad
adrm
Posts: 47
Joined: Sun Dec 02, 2018 11:58 am
Platform: Windows

Thu Mar 14, 2019 7:22 pm Post

tiho_d wrote:This is best described and reproduced with a demo project.


I created a new project from a template and pasted in some random text. No problems there.

It's hard to recreate the issue when I have no clue what causes it.
I suspect it has something to do with scenes that have, or have had, text in Synopsis or Notes, although when I check these for the scenes that show up in the search, I can't see any double spaces in them. :(

Perhaps if you can list all the places that are searched? I can then do a manual check inside fields and files to see if I can discover what's happening.
My criteria are: Search in Project + All/RegEx/Search in Included documents/Search in Excluded documents

th
thePhilosoraptor
Posts: 845
Joined: Sat Feb 13, 2016 3:28 am
Platform: Windows

Thu Mar 14, 2019 9:07 pm Post

You can change 'ALL' to Synopsis, Notes, or any other field. That should help you narrow it down.
Bryan Bender

ad
adrm
Posts: 47
Joined: Sun Dec 02, 2018 11:58 am
Platform: Windows

Fri Mar 15, 2019 7:53 am Post

thePhilosoraptor wrote:You can change 'ALL' to Synopsis, Notes, or any other field. That should help you narrow it down.


Gah! Getting dumber by the day. I should have realised that :oops:

I see the issue(s) now.
1) Sometimes the result of a search is not highlighted. Typically this seems to happen (in my example) if Scrivener wraps the line, e.g.
some long text<space>{Scrivener wraps here}
<space>more long text

2) Search hits are not highlighted for hits outside the main text (e.g. notes) when using type All. This can lead to some confusion

th
thePhilosoraptor
Posts: 845
Joined: Sat Feb 13, 2016 3:28 am
Platform: Windows

Fri Mar 22, 2019 10:38 pm Post

Thanks for your help. Both of these issues have been filed.
Bryan Bender

ad
adrm
Posts: 47
Joined: Sun Dec 02, 2018 11:58 am
Platform: Windows

Thu Apr 18, 2019 9:17 pm Post

thePhilosoraptor wrote:Thanks for your help. Both of these issues have been filed.


Although it works much better than before, there still are a few inconsistencies.

During my last clean-up session, a few documents were listed as having two consecutive spaces in them, but it was impossible to find these inside the documents,

If I remember correctly, I spent quite a bit of time trying to figure out the culprits, including toggling "show invisibles" on.
In the end, I was only able to resolve the issues by cutting all text from the document and then pasting it back as plain text.

Whatever the RegEx search triggered on in those cases, it did not appear to be <space><space>