Hi Robert, > One example is in fixing the nodes of Delphi's TreeView which still > only take ansicode strings. Bob has suggested a number of fixes which > are also found on QualityCentral. Until such time as Codegear decides to > implement these in a fix, ( unless they already have done so and I > haven't heard about it ), he suggests copying the offending pas file to the > project directory and making the changes there...which I imagine is to > protect > the original source and keep backward compatibility. Since I needn't worry > about that myself, but still don't like altering the source either, can I > place the unit with the changes I've made in my lib path and have it take > precedence over the original for all projects without having to actually > include it with my project files? Is there some other path that I can > use to allow this?
Yes, you can do that as well - placing the modified .pas file in your LIB directory. However, when you then compile your .pas file, it will replace the orginal .dcu file. That's why I always place modified VCL source code units in my project directories only (for each individual project), so the .dcu files will not overwrite the original ones (until the patch from CodeGear appears). > And what about Windows API functions where as Microsoft has seen fit > to provide both Ansi and Wide String versions. Must I use actual > WideStrings, cast Unicode to Wide, or will they work correctly with > Unicode right out of the box? The Windows unit is automatically calling the W-versions of the Windows API, and passing String and PChar, which are now UnicodeString and PWideChar, so that's not something to worry about. Unless you explicitly want to call a Windows API function by adding the W- or A- postfix yourself... > In any event, I just want to thank Bob for making a very readable > text. I must admit that with all the many things I've read about the > differences between UTF8, UTF16, and UTF32 over the years, his is the > first that gave me a practical sense of their relationship. But of course the > most interesting line in the whole file comes in the next chapter > where he says, "In this section I'll globally cover Globalization...! Thanks for the kind words. I must admit that the above sentence about the global globalisation wasn't written with any pun intended at the time ;-) Groetjes, Bob Swart -- Bob Swart Training & Consultancy (eBob42.com) Forever Loyal to Delphi CodeGear Technology Partner -- CodeGear RAD Studio Reseller (BeNeLux) Delphi Win32 & .NET books on Lulu.com: http://stores.lulu.com/drbob42 Personal courseware + e-mail support http://www.ebob42.com/courseware Blog: http://www.drbob42.com/blog - RSS: http://eBob42.com/weblog.xml _______________________________________________ Delphi mailing list -> Delphi@elists.org http://lists.elists.org/cgi-bin/mailman/listinfo/delphi