Hello everyone,
Sorry to re-up a bug topic but I have created a temporary patch for LCase() and UCase().
Code:
; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
; Project name : LCase bug with accented characters
; File Name : LCase - Ucase bug with accented characters.pb
; File version: 1.1.0
; Programmation : Bug Demonstration
; Programmed by : Guimauve
; Date : 30-08-2011
; Last Update : 22-05-2012
; PureBasic code : 4.61 Final
; Plateform : Linux Mint 12 x64
; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Procedure.s LCase_Patch(String.s)
For CharID = 1 To 27
String = ReplaceString(String, Mid("ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÑÒÓÔÕÖÙÚÛÜÝ", CharID, 1), Mid("àáâãäåæçèéêëìíîïñòóôõöùúûüý", CharID, 1))
Next
ProcedureReturn LCase(String)
EndProcedure
Procedure.s UCase_Patch(String.s)
For CharID = 1 To 27
String = ReplaceString(String, Mid("àáâãäåæçèéêëìíîïñòóôõöùúûüý", CharID, 1), Mid("ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÑÒÓÔÕÖÙÚÛÜÝ", CharID, 1))
Next
ProcedureReturn UCase(String)
EndProcedure
Debug "LCase(" + Chr(34) + "ÉÈÊ" + Chr(34) + ") = " + LCase("ÉÈÊ") + " --> This should return " + Chr(34) + "éêê" + Chr(34) + " instead of " + Chr(34) + "ÉÈÊ" + Chr(34)
Debug "UCase(" + Chr(34) + "éêê" + Chr(34) + ") = " + UCase("éêê") + " --> This should return " + Chr(34) + "ÉÈÊ" + Chr(34) + " instead of " + Chr(34) + "éêê" + Chr(34)
Debug "LCase_Patch(" + Chr(34) + "ÉÈÊ" + Chr(34) + ") = " + LCase_Patch("ÉÈÊ")
Debug "UCase_Patch(" + Chr(34) + "éêê" + Chr(34) + ") = " + UCase_Patch("éêê")
; <<<<<<<<<<<<<<<<<<<<<<<
; <<<<< END OF FILE <<<<<
; <<<<<<<<<<<<<<<<<<<<<<<
Best regards.
Guimauve