The new GExperts version still supports all Delphi versions back to Delphi 6 (with the notable exception of Delphi 8) and even the Delphi 11 version is no longer in Beta state. There are even a few new features: Fast add mode for the Uses Clause Manager is back. Uses Clause Manager: Units "System" and … Continue reading GExperts 1.3.22 experimental twm 2023-03-25 released
Category: Delphi
Setting a form’s bounds can cause the DPI to change
Note to self: Setting a form's bounds can move the form to a different monitor. If that monitor has a different DPI than the one the form was originally on, this will cause a WM_DPICHANGED message to be sent to the form, which in turn will change the form's bounds again. This happened, for example, … Continue reading Setting a form’s bounds can cause the DPI to change
When showing a hint causes an Access Violation
I have just updated my last blog post regarding another effect of the Screen object caching the monitor configuration: Displaying a hint (via standard Delphi VCL functionality) causes an access violation. The solution is again to access the form's monitor property. Unfortunately, it's not that simple, as there is no user action that causes the … Continue reading When showing a hint causes an Access Violation
When Screen.Monitor[x].WorkAreaRect contains garbage
I'm posting this here so I can look it up later in case I forget it again: Some Delphi versions (I know about Delphi 2007 and earlier, not sure when it was fixed) have got a bug in the VCL code for the TScreen (global Screen object) when the monitor configuration changes. That class caches … Continue reading When Screen.Monitor[x].WorkAreaRect contains garbage
TdzSpeedBitBtn updated to support scaling
4 years ago I wrote a helper class TdzSpeedBitBtn which turns a TBitBtn into a TSpeedButton that can have the focus. That helper class has also been used in GExperts (in the Uses Clause Manager and Rename Components). It worked fine until Delphi 11 introduced per monitor DPI awareness. Then it still worked but the … Continue reading TdzSpeedBitBtn updated to support scaling
Why renaming a running executable can fail
I always thought that it is not possible to rename an executable that is currently running. Turns out I was wrong (happened before). It works fine for many executables, but not for all of them. In particular it does not work for the executables of our internal tools. Windows complains that the file is in … Continue reading Why renaming a running executable can fail
What does the following Delphi function do?
Still playing around with ChatGPT, I asked it "What does the following Delphi function do?" The Delphi function you posted converts a file size in bytes into a human-readable string format, using binary prefixes (KiB, MiB, GiB, TiB, PiB, EiB) to represent larger values. The function first checks the size of the file against various … Continue reading What does the following Delphi function do?
I asked ChatGPT what’s wrong with the following Delphi code
Slashdot just posted "What Happens When ChatGPT Can Find Bugs in Computer Code?" which links a PC Mag article with the title "Watch Out, Software Engineers: ChatGPT Is Now Finding, Fixing Bugs in Code" So I asked ChatGPT "What's wrong with the following Delphi code:" (That code is from GExperts' GX_GenericUtils unit.) It answered this: … Continue reading I asked ChatGPT what’s wrong with the following Delphi code
New Edit Path expert in GExperts
It has been in the source code for quite a while and some few people and I have tested it, but I didn't tell anybody else about it: There is a new expert in GExperts for editing the current project's unit search path. It looks like this: It offers the same functionality as the Search … Continue reading New Edit Path expert in GExperts
Need help testing a GExperts bugfix
I have just applied patches that are supposed to fix some Unicode issues with Russian characters. These apply to the following editor experts: Expand Macro Template Locate / Move to matching delimiter Previous / Next Identifier reference My tests so far have shown no changes on how these work on my source code, but I … Continue reading Need help testing a GExperts bugfix