FindBar-Tweak
FindBar-Tweak copied to clipboard
Highlight on Find Again
I don't know why but it seems to the option works reversed. When enabled words aren't highlighted and when disabled words are highlighted.
That's weird, it seems to work fine for me. It's supposed to only highlight when pressing F3 if the "highlight all" button is checked and the highlights aren't done (for example, after hitting Esc on a page with highlights to remove them or changing the location by clicking a link).
Is this not happening? Could you give me a specific example?
Maybe I don't understand the feature correctly. I mean when Highlight All is disabled and Highlight on Find Again is enabled (screenshot) current hit isn't highlighted in defined color in options.
I think you didn't correctly understand the feature as well. Let me try to explain.
First of all, the - only - highlights absolute commander is the "Highlight all" button in the findbar. No matter what preferences you have set, highlights will only be placed when that button is checked and they will never be placed when that button is not checked.
What the "Highlight all matches by default" preference does is automatically check that button when you open the findbar, otherwise the button will be unchecked when you open the findbar. This way, when you search for something, it will see that the button is checked and place the highlights without you actually having to click the button, as you would need to without the add-on.
When you hit F3 to "Find Again", the search routine is a bit different by default, it is a faster kind of search that just searches for the immediate next result. Because of this, it wouldn't place any highlights by itself because it doesn't search for all results, just the next one. What the "Also highlight on 'Find Again'" does is force it to find all results and place the highlights even when hitting F3.
On one hand, this will only happen if the highlights aren't already placed, because if they are it's unnecessary to do the highlights again, so it will only search for the next result as normal. On the other hand, this also depends on the checked state of the "Highlight all" button, if the button isn't checked it will also assume you don't want highlights placed. So, for F3 to also place the highlights, the "Highlight all" button must still be checked. Whether it is checked automatically through the "Highlight all by default" preference, or by the user manually clicking the button isn't important, what matters is that it actually is checked. Like I said, this button is the absolute on/off switch for highlights.
Also, the "current search hit color" will only be used when the highlights are placed, when there are no highlights it will be shown with the normal text selection color (because it will be essentially a normal text selection).
I hope this clarifies things a bit. I think I'll add a link in the add-on description to this issue, to prevent future misunderstandings of the feature.
I also have problem with this feature - when I search for something on a page (using FAYT, if this matters), the highlights are shown normally. Then if I close the search bar (press ESC) and press F3, the highlights aren't shown again. The sight does show up, also the highlight color is the one I've chosen in FB and not the default selection color, only the highlights are missing.
I have FastestSearch and FindList extensions installed (and many others of course, but these 2 may be interfering with the find bar itself) and FF version is 26.
Do you have the "Remove highlights when the findbar is closed" preference enabled? Because if you do (and it sounds like you do) that is expected, it won't place the highlights because you closed the find bar.
Yes, this is it :) I could not figure out what would be the meaning of the F3 option without removing the highlight first, but when I saw it in practice (that they are removed on second press of ESC in that case), it made sense.
Why have you not made it to work in the first case too - when the "Remove highlights when the findbar is closed" is enabled? I don't see some logical correlation (or anti-correlation) between the two.
That would depend on how you would use it of course. For example, if you rely only on closing the find bar through hitting Ctrl+F to remove the highlights, then you hit F3 and it adds the highlights back again, you wouldn't have a quick way to remove them again, because the find bar is already closed (so you can't close it again, you'd have to open it first and then close it).
Of course, you'd still have the Esc key, but that's something apart. If, as a general user, you're expecting to control everything with only the find bar open/closed state, then the current behavior is the most coherent: find bar open = highlights on; find bar closed = highlights off. That's what that feature means.