apache / netbeans

Apache NetBeans
https://netbeans.apache.org/
Apache License 2.0
2.62k stars 841 forks source link

When searching text inside editor, Capital Turkish character 'I' not working #5588

Open tugalsan opened 1 year ago

tugalsan commented 1 year ago

Apache NetBeans version

Apache NetBeans 17

What happened

I cannot use find on editor for search-text that contains I.

How to reproduce

When editing a java file, with a line "... public static boolean is_FILENAME_START( ..."

Did this work correctly in an earlier version?

No / Don't know

Operating System

Microsoft Windows [Version 10.0.22621.1265] Turkish

JDK

OpenJDK 64-Bit Server VM Temurin-19.0.1+10 (build 19.0.1+10, mixed mode, sharing)

Apache NetBeans packaging

Apache NetBeans provided installer

Anything else

image image

Are you willing to submit a pull request?

No

mbien commented 1 year ago

this sounds like a toLowerCase() issue to me as described in the javadoc: https://docs.oracle.com/en/java/javase/19/docs/api/java.base/java/lang/String.html#toLowerCase()

want to fix it?

tugalsan commented 1 year ago

I would love to. But, I have never suggest any code change before. Let me try, If i can find a solution...

mbien commented 1 year ago

took a quick look and it might be a bit more difficult to fix since the implementation uses a mix of Strings and char arrays: https://github.com/apache/netbeans/blob/master/ide/editor.search/src/org/netbeans/modules/editor/search/DocumentFinder.java

there is also a lot of toLowerCase/toUpperCase usage without Locale.ROOT, so it is probably not only one place which is causing this issue.

tugalsan commented 1 year ago