To try out the SVG package you can download the demo zip files, you can find these on the download page.
The demo has the following limitations : it contains only compiled sources for Win32 and the produced SVG images will have a watermark, for the rest it is fully functional.
First you need to download and install the pacakge that corresponds with your Delphi version:
- For Delphi XE2 to XE4, download SVGDemoXE2_XE4_240.zip
- For Delphi XE5 to XE7, download SVGDemoXE5_XE7_240.zip
- For Delphi XE8 to DX1, download SVGDemoXE8_DX1_240.zip
- For Delphi DX2 to DX4, download SVGDemoDX2_DX4_240.zip
- For Delphi D11, download SVGDemoD11_240.zip
- If you are using C++ builder you need to download the corresponding CPP zip as well.
After unzipping you will find a “Bpl” and a “Dcu” folder. The files in de “Bpl” folder contain the package libraries and the “Dcu” directory contain the compiled units.
Next, if you have an earlier version of the packages installed you have to remove these first. In Delphi:
- Go to menu “Component->Install packages…”
- Deselect the previous version packages and remove them.
- Then restart Delphi.
Next you have to add the “Bpl” files:
- Again, go to menu “Component->Install package…”
- Locate and add the three files of your Delphi version from the “Bpl” folder.
- Check that a “SVG2” group was added to the “Tool palette”
Next, add the path to the “Dcu” folder to your library path:
- In Delphi select menu “Tools->Options…”.
- From the “Options” dialog in the left panel select “Environment Options->Delphi Options->Library”.
- On the right top in “Selected Platform” select “32-bit Windows”
- Finally add the “Dcu” folder to the “Library path”
Now you should be good to go:
- Create a new VCL Forms Application
- Add the TSVG2Image2 from the “Tool Palette” “SVG2” group
- Select an SVG graphic in the “Filename” property of the SVG2Image1 object
- Run the application.
Examples can be found on github: delphi-svg-control-examples