I am not sure many know that since the Windows Creators update, svg parsing and painting is natively supported and is part of Direct2D. I wanted to test this Windows feature, however, the first obstacle was that the Direct2d headers that come with Delphi are very very old. There are two open tickets in
https://quality.embarcadero.com/.
Direct2D 1.1 support missing (open since XE7!) https://quality.embarcadero.com/browse/RSP-10159
Direct2D 1.2 and 1.3 support missing https://quality.embarcadero.com/browse/RSP-21071
SVG parsing and painting is natively supported and is part of Direct2D since MS Windows Creators https://docs.microsoft.com/en-us/windows/win32/direct2d/svg-support
You may want to vote for them, since lack of good Direct2D support (includes DirectWrite) it is a bit of a shame.
I then looked at other Direct2D translations and found two that are regularly updated. https://github.com/FactoryXCode/MfPack/tree/Master/MfPack https://github.com/CMCHTPC/DelphiDX12
They both had some issues but that was a good start. It turned out that parsing and painting svg files to Canvas is quite straightforward. Once you establish a renderer (Vcl.Direct2d does this, but it is easy to do it from scratch) you can do everything with two lines of code.
if Supports( rt, ID2D1DeviceContext5, fDeviceContext5) then ...
And it is easy to do things like scaling, opacity, rotation, recoloring etc. The quality and speed appear to be quite good, but there are some limitations, the most important of which I think is the lack of support for the text element. I am attaching the source code of my test project (no dependencies) in case anyone wants to play with it. The Svg scales automatically as you resize the form.
SVGIconImageList: Now it's possible also to use native VirtualImageList (from 10.3 or 10.4) linked to a TSVGIconImageCollection! If you have an older Delphi version you can use TSVGIconsVirtualImageList.
----------------------------------------------
The higher the degree, the greater the respect given to the humblest!RAD 11.3