xles / hyphenator

Automatically exported from code.google.com/p/hyphenator
GNU General Public License v3.0
0 stars 0 forks source link

Hyphenator breaks searching, when using "selection for searching". #197

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Have a word with a possible hyphenation, like "check­boxes". It does not 
have to be hyphenated.

2. Select it and mark for searching (cmd-E).

3. Go to any other document with the word "check­boxes", it will not be found 
since you are now actually searching for "check­boxes".

- What is the expected output? What do you see instead?

If "Remove hyphenation when copying text" was selected when creating the 
script, it should also remove hyphens from the search.

- What version of the product are you using?

Latest version (just re-created it to be sure).

- On what operating system?

OSX, all browsers.

Original issue reported on code.google.com by olof.tho...@gmail.com on 16 Feb 2014 at 2:39

GoogleCodeExporter commented 9 years ago
Hi

I'm totally aware of this issue, but I haven't found a solution, yet.

HTML4 clearly says "For operations such as searching and sorting, the soft 
hyphen should always be ignored." (See: 
http://www.w3.org/TR/html401/struct/text.html) Given that the behaviour you 
described is a bug in the browsers (or a missing feature?)
As of HTML5 I can't find anything similar. But Unicode says "At a first level 
of approximation, most Unicode format controls should be ignored for searching 
and sorting." (Unicode 6.2.0 Chapter 5.21)
So again, it's probably a bug in the browser.

While it was somehow possible to filter out soft hyphens when copying (it is a 
hack that uses the incopy-event) to work around this bug there's no way to know 
when a user uses a selection for find.

So I can't fix that.
Sorry

Original comment by mathiasn...@gmail.com on 28 Feb 2014 at 3:02

GoogleCodeExporter commented 9 years ago
Thanks for the reply!

Alright, it is a browser bug. Will report this bug to Apple.

28 feb 2014 kl. 16:02 skrev hyphenator@googlecode.com:

Original comment by olof.tho...@gmail.com on 28 Feb 2014 at 3:14