Case-insensitive search in IDE fails on Win9x
Original Reporter info from Mantis: Bart @flyingsheep
-
Reporter name: Bart Broersma
Original Reporter info from Mantis: Bart @flyingsheep
- Reporter name: Bart Broersma
Description:
On Win9x platform, case-insensitive search in the IDE fails (search is always case-sensitive).
This is because TSynEditSearch.FindNextOne uses Utf8LowerCase from LCLProc, and LCLProc.Utf8LowerCase (and LCLProc.Utf8UpperCase) return inputstring on Win9x platform.
This could be solved in two different ways:
Use LazUtf8.Utf8LowerCase (and LazUtf8.UpperCase) instead of LCLProc.
(These procedures work on Win9x systems.)
Or maybe even let LCL.Utf8Upper/LowerCase "inline" LazUtf8.Utf8Upper/LowerCase (like it was done for Utf8Pos() tect.), so this will work throughout the entire IDE.)
In LCLProc add {IFDEF WINDOWS},Win9xWsManager{
ENDIF} to the uses clause.
The Win9xWsManager unit comes with fpc 2.6.0 and silently replaces the
WideStringManager.UpperWideStringProc and StringManager.LowerWideStringProc on Win9x systems without penalties for XP/NT and up (and it does nothing on non-windows).
This also will make all Utf8UpperCase/LowerCase work on Win9x systems throughout the IDE.
I attach a patch for the second solution.
Target 0.99 for review of patch.