Jump to content

Carlo Barazzetta

Members
  • Content Count

    13
  • Joined

  • Last visited

  • Days Won

    2

Carlo Barazzetta last won the day on September 17

Carlo Barazzetta had the most liked content!

Community Reputation

37 Excellent

About Carlo Barazzetta

  • Birthday 02/12/1968

Technical Information

  • Delphi-Version
    Delphi 10.4 Sydney

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Carlo Barazzetta

    Looking for SVG support in Delphi?

    I've published an article about SVGIconImageList and IconFontsImageList:https://ethea.it/icons_in_delphi/
  2. Carlo Barazzetta

    Looking for Icon Fonts support in Delphi for High-DPI and Themed app?

    I've published an article about SVGIconImageList and IconFontsImageList: https://ethea.it/icons_in_delphi/
  3. Carlo Barazzetta

    Looking for Icon Fonts support in Delphi for High-DPI and Themed app?

    The transition to "Virtual" is now complete (released ver.2.3). Demos for 10.3 and 10.4 now uses native TVirtualImageList + TIconFontsImageCollection, and the TIconFontImage component can also be linked to VirtualImageList and IconFontsVirtualImageList (not only to IconFontsImageList). I'm searching for users and contributors to the project, expecially for older Delphi versions (because the components are compatible from Delphi 7 to current): it's very hard to me to maintain backward compatibility without help. From Delphi XE4 they uses GDI+ to render icons.
  4. Carlo Barazzetta

    Help: preview of Svg image in Open-Dialog works only with VCLStyle active.

    Ok, I've resolved, with this solution: I'm using a new class, implementing Execute without call the "inherited" metod, because the "magic" OpenDialog with the preview is activated by : Template := 'DLGTEMPLATE' but it's used only when TStyleManager.IsCustomStyleActive Using Template 'DLGTEMPLATE' also without CustomStyleActive shows always the dialog with the preview: TOpenPictureDialogSvg = class(TOpenPictureDialog) function TOpenPictureDialogSvg.Execute(ParentWnd: HWND): Boolean; begin Template := 'DLGTEMPLATE'; Result := DoExecute(@GetOpenFileName, ParentWnd); end; Not very elegant, but it works...
  5. Carlo Barazzetta

    Help: preview of Svg image in Open-Dialog works only with VCLStyle active.

    Yes! I've notice now that the two Dialog are quite different... but the call is always the same: OpenDialog.Execute. The TOpenDialog properties: object OpenDialog: TOpenPictureDialog Filter = 'Scalable Vector Graphics (*.svg)|*.svg' Options = [ofHideReadOnly, ofAllowMultiSelect, ofPathMustExist, ofFileMustExist, ofEnableSizing] Left = 328 Top = 96 end
  6. I have a question about a problem developing SVGIconImageList components: At design-time, the component editor cannot show the svg icon preview into the OpenDialog when loading files from "Add..." button.Compiling the demo, *and* and activating any VCLStyle, the icon is visibile: Disabling the VCL style, the preview is not visible also at run-time (I'm using Windows in dark mode): Could it be possible to have the same functionality at design time? It is very important to see the preview, during selection of svg files using the editor! Do I need some OpenDialog "hook" to have the preview also in "normal" style? Thansk for any suggestions. Carlo
  7. Carlo Barazzetta

    Looking for Icon Fonts support in Delphi for High-DPI and Themed app?

    Actually the components do not install any fonts on purpose, to avoid thinking they only works with a specific font ... The demo uses a sample font, and also shows how to load it on-the-fly if it is not installed on the system. The downside is that when you open the demo you don't see the icons right away in the IDE and this could make you think that the component is not working properly... The other aspect is that any font loaded as a resource in the IDE affects the possibility of installing a new version on the same font in the system... I think that letting the developer choose to install the fonts he needs to use in his applications to use them with the components is the right and least invasive choice, don't you agree?
  8. Carlo Barazzetta

    Looking for Icon Fonts support in Delphi for High-DPI and Themed app?

    Yes, to develop the app the font must be installed on the system in order to use it in the IDE. Deploying the app you can do as you explain: I have similar code in the demo, which responds to the OnFontMissing event raised by the component if Font is not installed: //The "material desktop font is not installed into system: load and install now from disk LFontFileName := ExtractFilePath(Application.ExeName)+'..\Fonts\Material Design Icons Desktop.ttf'; if FileExists(LFontFileName) then begin {$IFNDEF D2010+} AddFontResource(PChar(LFontFileName)); {$ELSE} AddFontResource(PWideChar(LFontFileName)); {$ENDIF} SendMessage(HWND_BROADCAST, WM_FONTCHANGE, 0, 0); end
  9. IconFontsImageList components by @Carlo Barazzetta could be the answer: you can explorer the complete wiki to see how it works. Summary of library: An IconFontsImageCollection component that inherits from Delphi's CustomImageCollection and is compatible with VirtualImageList A IconFontsVirtualImageList, to use with Delphi version older than 10.3 A rendering engine of Icon-fonts using GDI+ (from Delphi XE4) A complete backward compatibility with older Delphi versions (from Delphi 7) A useful Collection and Component editor, with support for Category of Icons A custom CharMap viewer, to easily select icons contained in any Font Support for changing the Color based on the active VCL Style. High performance of drawing engine Support for FMX (also for mobile platforms) It's free and open-source Icons based on Fonts are a good alternative to bitmaps because they need only the Font installed in the system to obtain thousands of images (like the "Material Design Font Desktop.ttf" font: https://github.com/Templarian/MaterialDesign-Font). The icons scales perfectly, so, you don't need to multiple resolutions of your images to match the DPI of the monitors and multiple colors for Theme used. The Collection of Icons can be rendered by a single Font/Color defined at collection level, or by different Fonts/Color defined at Icon level, so you can mix different icons from different Fonts in a single collection. The library is quite stable, but any contribution is welcome!
  10. Carlo Barazzetta

    Looking for SVG support in Delphi?

    I want to personally thank Vincent Parrett and Kyriakos Vlahos for the great contribution to the project! The official 2.0 version will be released shortly and also published on GetIt. Meanwhile, you can download the project from Github and report any problems. I'm also working on IconFontsImageList to add similar funcionalities, like a IconFontsVirtualImageList and IconFontsImageCollection...
  11. Carlo Barazzetta

    Native Svg parsing and painting in Windows

    The work on https://github.com/EtheaDev/SVGIconImageList continues, many issues have been solved. 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. With the help of VincentParrent and pyscripter the components and the SVG library improve day by day ... Stay tuned!
  12. Today I've merged the great work made by @pyscripter and @Vincent Parrett into SVGIconImageList project and released 1.8 version. Now with the new components SVGIconImageCollection and SVGIconVirtualImageList it's possibile to build multi-form High-DPI app in a multi-monitor environment using a single ImageCollection shared by the forms. Many SVG rendering problems are now fixed!
  13. Carlo Barazzetta

    Native Svg parsing and painting in Windows

    Vincent, I can't process your pull request for a few days because I'm busy, but your job is very important to give flexibility to these components. Thanks for your support to the SVGIconImageList project.
×