Der schöne Günther
Members-
Content Count
691 -
Joined
-
Last visited
-
Days Won
12
Everything posted by Der schöne Günther
-
Blogged - Code signing with USB tokens
Der schöne Günther replied to Vincent Parrett's topic in Tips / Blogs / Tutorials / Videos
Thank you so much! I never bothered with code signing (we ship devices with our software pre-installed), so this is all entirely new to me. -
Hope not to derail this thread, but there is a ton of UI libraries for Rust. However, I know of no IDE that offers some kind of a form designer like those from RAD Studio or Visual Studio. I have used a simple WebView for small hobbyist projects in Rust (using wry which is also used by Tauri [Tauri in 100 Seconds - YouTube]). I'm not sure if I'd really miss creating VCL over HTML. I found it very enjoyable so far, however just on a very small scale. If you have heavily invested in custom VCL components over the years, then you're pretty much "locked in". From time to time, I am replacing some smaller parts of our Delphi applications with web interfaces. So far, I am very happy with the results, and I'd like to continue going down that route.
-
I haven't seen Windows automatically launching an application after plugging in a USB drive for ten or 15 years. Consult the official documentation about autorun.inf: Autorun.inf Entries - Win32 apps | Microsoft Learn
-
After all their licensing stuff went south, we never installed Delphi IDEs on real machines anymore, just virtual ones. If licensing (or the IDE itself) breaks, just roll back the VM, and you're back in the game. The VM doesn't even need internet.
-
With Delphi 11.1, my actual output is exactly what you expect.
-
Encoding accented char in JSON format
Der schöne Günther replied to DavidOne's topic in Network, Cloud and Web
As far as I understand, not the DB layer (TFields and stuff) is throwing the exception, but your Writer is, correct? If that's the case, have you seen its StringEscapeHandling-property? -
Me neither, there really is a lot of room for improvement, even with MMX. I really like the "time since last edit". I suppose it's referring to the files on disk, not the underlying source control system? Not sure if an absolute path to the files is really helpful. Wouldn't a path, relative to the active project root, be sufficient? 🤔
-
I remember using CromisIPC about 8 years ago, but it never really worked 100%, so we stopped using it.
-
11.2 Pre-Upgrade Checklist / back out plan
Der schöne Günther replied to SwiftExpat's topic in Delphi IDE and APIs
Just use a VM. Problem with an update, something not working as it should? Just roll back. Takes just a couple of seconds and you can be sure everything is in a state that is working fine. -
Get call count with Delphi debugger
Der schöne Günther replied to Tommi Prami's topic in Delphi IDE and APIs
I just noticed that if the breakpoint has a condition, the pass count reflects the number of times the condition was true. That's actually pretty nice. Now if only one line could have multiple breakpoints with different conditions... 😇 PS: Fun fact: If you kill the process with [Ctrl]+[F2] rather than letting it terminate gracefully, the IDE will still show the last pass count for a breakpoint. -
Strange behavior with "is" operator
Der schöne Günther replied to Sonjli's topic in Algorithms, Data Structures and Class Design
Cannot reproduce: unit Unit1; interface type MyAttributeOne = class(TCustomAttribute); [MyAttributeOne] TMyObject = class(TObject); implementation end. program Project1; uses System.SysUtils, System.Rtti, Unit1 in 'Unit1.pas'; var ctx: TRttiContext; rttiType: TRttiType; attribute: TCustomAttribute; begin ctx := TRttiContext.Create(); rttiType := ctx.GetType( TypeInfo(TMyObject) ); for attribute in rttiType.GetAttributes() do if(attribute is MyAttributeOne) then WriteLn('It is MyAttributeOne!') else WriteLn('It is something else'); end. will output It is MyAttributeOne! -
Anyone using an open-source ORM?
Der schöne Günther replied to Bill Meyer's topic in Delphi Third-Party
It may sound irritating, but I don't use ORMs at all. Maybe that's because we usually don't have many things stuffed into relational databases, or maybe because this old article left a lasting impression: Object-Relational Mapping is the Vietnam of Computer Science (codinghorror.com). I have no proof, but that for the few times, it was more time-efficient to do it by hand than include a massive ORM library and learn how to use it properly. -
delphi Twebbrowser Javascript error
Der schöne Günther replied to clubreseau's topic in General Help
-
delphi Twebbrowser Javascript error
Der schöne Günther replied to clubreseau's topic in General Help
To be honest, I have never heard of that, let alone experienced it myself. It is still working fine, at least for the parts where have not migrated to the (fantastic!) EdgeBrowser yet. -
Function arguments are always evaluated, then passed into the function. This "IfThen" (which I have never seen before), is just a regular function. The compiler has no knowledge that there is no need to evaluate the other arguments if the first one results to False.
-
The best way to handle undo and redo.
Der schöne Günther replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
The Command Design Pattern (sourcemaking.com) is generally used for undo/redo operations. Regarding databases: Not sure if you're looking for undo/redo or just transactions. Maybe this is relevant to you: Managing Transactions (FireDAC) - RAD Studio (embarcadero.com) -
Converting a very long text to concatenated strings?
Der schöne Günther replied to PeterPanettone's topic in GExperts
This is exactly what the MultiPaste tool is for. You can find it in Delphi at Edit -> MultiPaste. Using the MultiPaste Tool - RAD Studio (embarcadero.com) (I think the picture they posted is incorrect, as it is not realated to MultiPaste at all) -
I am running "Delphi 11 and C++ Builder 11 Update 1" which is, I believe, the most current version. However, the integrated Sqlite library the IDE makes use of (FireDAC), is considerably older. I'd like to update it, as the query editor doesn't even understand some of our queries anymore. Double-clicking on a TFDConnection, then navigating to Info reveals the following: ================================ Client info ================================ Loading driver sQLite ... DLL = <sqlite3_x86.obj statically linked> Client version = 3.31.1 I found a sqlite3.dll in C:\Program Files (x86)\Embarcadero\Studio\22.0\bin and replaced it with the most current version, downloaded from the SQLite Download Page. However, that changed nothing. I have no idea how to proceed. I find dozens of guides how to manage the dll your own application will pick at runtime. But I am looking for the IDE, bds.exe. How to update sqlite?
-
How do I update the sqlite dll in RAD Studio?
Der schöne Günther replied to Der schöne Günther's topic in Databases
I would have considered going to quality.embarcadero.com - But it's been down again since yesterday 😉 -
How do I update the sqlite dll in RAD Studio?
Der schöne Günther replied to Der schöne Günther's topic in Databases
Yes, fancy things like these were exactly why I updated 😊 🎉 It already works fine in my application by setting the driver link settings to "dynamic" (as you mentioned). I just wish the IDE would also be capable of that. Instead of being tied to an outdated version of sqlite that is baked into it. There really is no reason to do that, it's a very strange design decision. -
How do I update the sqlite dll in RAD Studio?
Der schöne Günther replied to Der schöne Günther's topic in Databases
Thank you for the swift reply, that's what I feared. I have no clue why they did it that way. Every freeware tool I know has the sqlite.dll in a separate library, so that it can be updated later, even when the tool itself is no longer supported. -
__fastcall for overlapped virtual destructor of Delphi base class in CLANG compiler
Der schöne Günther replied to AlexBelo's topic in General Help
Yes, __fastcall has zero effect on x64 and ARM, compilers will usually just ignore it. It seems ctors/dtors are a special case when it comes to calling conventions. See [RSP-30762] [bcc32c]: fastcall calling convention ignored on constructor/destructor - Embarcadero Technologies [RSP-23671] Unexpected compiler error - Embarcadero Technologies [RSP-33071] [bcc32c error] virtual function '~XXX' has different calling convention attributes ('void ()') than the function it overrides (which has calling convention 'void () __attribute__((fastcall))') : overridden virtual function is here - Embarcadero Technologies From what I gathered, Embarcadero maintained their own patch queue of modifications for clang so that calling conventions were handled also for constructors/destructors but appearantly, they are struggling to keep up with clang development. -
Changing TToolButton image and using transparency
Der schöne Günther replied to Tom F's topic in VCL
That is not a good idea, even with something like 32 × 32 pixels. You should always have an alpha layer, where pixels are neither entirely black or "not there", but something in between. So that it doesn't matter which background they're on: Here it is getting more obvious: In our VCL applications, we're using png files. Theyre small, lossless and support alpha channel. If you can, you could even consider vector graphics like SVG. That way, you won't even have to worry about supplying different resolutions for different displays. -
Not sure about hooks, but it looks the spooler API has what you need DocumentEvent function (Winspool.h) - Win32 apps | Microsoft Docs FindFirstPrinterChangeNotification function (Winspool.h) - Win32 apps | Microsoft Docs
-
Ugly exception handling bug in 11.1.5
Der schöne Günther replied to AlexBelo's topic in General Help
I stopped using C++ Builder because of the truly abysmal exception handling with Clang. The leaks were the least of my concern. According to [RSP-13173] C++ compiler exception handling is completely broken - Embarcadero Technologies, it should have been fixed, and they even had a blog post how it should have been improved with 10.4.2: (Source) Sad to see it's still not properly fixed. They have been having the LLVM backend for C++ for what now... ten years?