Have an amazing solution built in RAD Studio? Let us know. Looking for discounts? Visit our Special Offers page!
DelphiIDEResearch

Delphi Offers Deeper Third-Party Tool API Integration Than WPF And Electron

wp1_tool_extension

How do Delphi, WPF .NET Framework, and Electron perform compared to each other, and what’s the best way to make an objective comparison? Embarcadero commissioned a whitepaper to investigate the differences between Delphi, WPF .NET Framework, and Electron for building Windows desktop applications. The benchmark application – a Windows 10 Calculator clone – was recreated in each framework by three Delphi Most Valuable Professionals (MVPs) volunteers, one expert freelance WPF developer, and one expert Electron freelance developer. In this blog post we are going to explore the Tool Extension metric which is part of the functionality comparison used in the whitepaper.

rad-studio-1042

How can Tool Extensions be compared?

Can the framework be extended in its own language? Frameworks that require plug-ins, extensions, or modifications to be written in a different language impose costs on businesses that require altered functionality. Rather than creating the required tool from resident knowledge, businesses may have to invest time and resources to hire an external contractor or build in-house skills in that alternate language.

Delphi ships with testing software and also gives businesses the opportunity to develop tools and extensions for the framework using the same talent that builds their product (the Delphi IDE is programmed in Delphi). WPF offers testing libraries through Visual Studio, and businesses can enjoy the large third-party tool and extension environment, but may need to outsource work to build their own extensions or invest in talent for non-WPF languages. Electron lacks a native IDE, giving businesses a choice but also removing some conveniences like integrated compilation and included testing libraries. Businesses developing in-house tools would have a more difficult time with Electron than the other frameworks.

Know the benefits when you install Visual Studio and how it can help you get on your way to application development.

wp1_tool_extension_gauge-4795592

Let’s take a look at each framework.

What tool extension capabilities are available for Delphi?

The RAD Studio IDE for Delphi is written in Delphi. Users can build their own extensions and tools in Delphi, eliminating the need to learn a new language and handle language boundary problems. Additionally, extensions and tools can be built in C++ via the C++Builder side of RAD Studio.

RAD Studio has a powerful API allowing you to extend or modify the IDE’s behavior. Create a package or DLL plugin that adds new tool windows, draws in the code editor, provides code completion, adds new project types, file types and highlighting, hooks into high-level and low-level events, tracks processes, and threads while debugging, and more.

There is a rich ecosystem of both open and closed source add-ons. There are a number of add-ons available directly via Embarcadero GetIt in the IDE.

The following is an excerpt from the Extending the Delphi IDE whitepaper by Bruno Fierens and Embarcadero.

What is the basic architecture of the Delphi IDE API?

The API is heavily based on interfaces. The interfaces typically start with the prefix IOTA or INTA. The IDE exposes a lot of interfaces that can be called from the plugin; conversely, the IDE itself can also call code from the plugin when a specific action is triggered in the IDE. To inform the IDE that the plugin has a handler for these actions, in most cases, this is done by writing a class descending from TNotifierObject that implements an interface and register the class with the IDE. As a plugin writer, you will find yourself mostly writing code that calls the IDE interfaces and write classes that implement interfaces that will be called from the IDE.

What areas of the RAD Studio IDE can be extended?

The Delphi IDE can be extended in many ways. This is a brief overview of the most common areas of extending the IDE:

  • Create and add custom docking panels
    It is possible to add custom docking panels like the component palette panel, the
    object inspector panel etc…
  • Interact with the code editor
    Interfaces are offered to programmatically manipulate the Delphi IDE code editor;
    for example, to insert snippets of code, replace text, handle special key sequences,
    add custom syntax highlighters and more…
  • Interact with Code Insight
    Code Insight in the editor can be customized as well, offering custom help texts on
    specific constructs in the code.
  • Interact with the Project Manager
    The IDE allows you to have custom context menus to projects and files in the IDE
    Project Manager tool panel.
  • Add custom wizards, items to the repository
    It is possible to add custom items or start custom wizards from items added to the
    Delphi repository. From these wizards, new project types, specific form types, or
    data modules can be created.
  • Interact with ToDo items
    An API is also available to interact with ToDo items in code from a Delphi IDE
    extension.
  • Interact with debugger, create custom debugger visualizers
    In newer Delphi versions, an IDE extension can be added that provides a custom
    display of a specific data type while debugging.
  • Interact with the form designer
    From a Delphi plugin, an API is available to interact with the form designer as well.
  • Splash screen notifications
    An interface is provided to add custom text on the splash screen during the startup
    of the IDE.

Here is also a featured Developer Skill Sprint video titled Developing Plugins in RAD Studio:

https://www.youtube.com/watch?v=2FV25pm2kXk

A number of popular extensions for RAD Studio include:

What tool extension capabilities are available for WPF .NET Framework?

Visual Studio, the native WPF IDE, can be extended in a number of ways and in multiple languages. Macros are written in Visual Basic, Add-Ins are written in .NET, and Packages can be written in .NET, C#, C++, or Visual Basic. Because WPF is written in XAML and ties into a C# logical back-end, businesses might not have in-house experience to build tools they need to enhance their development environments without out-sourcing the work or investing in training.

According to Microsoft, Visual Studio allows extending “menus, toolbars, commands, windows, solutions, projects, editors, and so on.” Additionally, it lists the following common items which can be extended.

  • Extending Menus and Commands
  • Extending and Customizing Tool Windows
  • Editor and Language Service Extensions
  • Extending Projects
  • Extending User Settings and Options
  • Extending Properties and the Property Window
  • Extending Other Parts of Visual Studio
  • Visual Studio Isolated Shell

Find out more about extending Visual Studio here:
https://docs.microsoft.com/en-us/visualstudio/extensibility/starting-to-develop-visual-studio-extensions?view=vs-2019

One question people commonly ask about .NET is: Is .NET dead?

What tool extension capabilities are available for Electron?

Electron lacks a native IDE but can use plug-ins available in IDEs such as Visual Studio Code. Additional Electron tools might have to be developed in-house from scratch or integrated with a third-3rd party tool such as Visual Studio Code. There are a large number of open source projects around tooling and functionality for Electron.

A popular editor used with Electron is Visual Studio Code. Other popular editors are Atom, Sublime Text, NotePad++, and other text editors. A lot of these text editors including VS Code support extensions but each one is uniquely different and therefor the extensions for Electron are scattered around and of varying quality.

Some of these tools include:

  • Electron Builder
  • Electron Snippets
  • Electron Build Tools

In conclusion, we have looked at tool extension capabilities in Delphi, WPF .NET Framework, and Electron tooling. Delphi provides the broadest tool extension capabilities with significant long term history behind the existing tools. It can be difficult to built tool extensions for WPF .NET Framework as in-house experience to build tools may not be available. Additionally, as WPF .NET Framework is a legacy framework according to Microsoft businesses may not want to allocate budget to supporting it. Electron is only a framework and therefor doesn’t have the same tool extension system that an integrated IDE like Delphi / RAD Studio and Visual Studio provide. The text editors that do support Electron each have their own unique plugin systems. Overall Delphi / RAD Studio provides the richest tool extension ecosystem.

Ready to explore all the metrics in the “Discovering The Best Developer Framework Through Benchmarking” whitepaper?

Download The Free Delphi vs. WPF vs. Electron For Windows Desktops Whitepaper


Reduce development time and get to market faster with RAD Studio, Delphi, or C++Builder.
Design. Code. Compile. Deploy.
Start Free Trial   Upgrade Today

   Free Delphi Community Edition   Free C++Builder Community Edition

About author

Director of Delphi Consulting for GDK Software USA. Many software related patents, including swipe and pattern unlock and search engines. First Silver and Gold Delphi badges on Stack Overflow Former Developer Advocate for Embarcadero Technologies. Long time fan of programming, especially with Delphi. Author, Podcaster/YouTuber, Improvisor, Public Speaker, Father, and Friend.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

IN THE ARTICLES