While several definitions can be formulated, they all contain one universal message. In my opinion the most accurate definition is given in the Wikipedia:
Let’s consider whether developing application in RAD style (visually), can we use general reusable solution and do we solve common problems? Of course, every day. Developers in Delphi are using design patterns, even if they do not realize it.
Delphi UI patterns
Some of this patterns are related to user interface and much less is VCL agnostic. UI patterns in VCL are well known and often without using them it’s difficult to build working solution. I can list here a few of these patterns: forms inheritance, form separation using frames, grid centric UI, master-detail layout with edits and navigator for the master and grid for the details, non-editable grid with item list and modal form with editable controls, and much more.
Visual patterns are popular among Delphi developers, but I do not know anyone who would dare to public and named them. Several books describe how to apply elements, but they do not treat them as reusable patterns. In practice each group of developers builds and discovers them internally. Sometimes this discovery takes many years. In my opinion, this is excellent material for a new book on developing UI in Delphi.
Non-visual Delphi patterns
Looking for these non-visual patterns I found only four, for sure there are a bit more but not so much. All this patterns are very useful, but they also have their dark side of the force. During designing them, the highest priority was the simplicity of use and not the maintenance. For this reason, they work great in small projects, and as these projects are growing they are becoming less and less comfortable. This four pattern non-visual pattern suggestion are: Data set pattern, Action pattern, Data module pattern, Delphi event pattern. Certainly some I missed so please comment below.
Data set pattern
It’s not just about the TDataSet component and their descendants, but about general architecture and his behavior, I mean: tabular structure with strongly typed columns, with access to one data row, with state (e.g. browse, edit, insert), with TField collection containing visual metadata and internal integrity metadata, with events used for notifying other application areas, with internal datatalink, and external TDataSource component, and much more.
During my consultancy work I noticed that most Delphi developers learned by trial-and-error method how to apply this pattern, but only some of them are able to use full power of this pattern in a sensible way. Some developers have learned that data set can be useful not only in database applications, but can be used in any application that contains data. Thanks to the ability to create dynamically memory data sets and visualize them in any way.
Well-used pattern becomes a very powerful tool in the hands of the architect. Full use of a field metadata allow to build dynamic and flexible solutions. As an example, I would like to write about methods converting data from a TDataSet object to a JSON / XML collection, or automatically generate tabular report template and many other data transformations.
Register for Python GUI Apps Con 2023 today!
Reduce development time and get to market faster with RAD Studio, Delphi, or C++Builder. Design. Code. Compile. Deploy. Start Free TrialUpgrade Today
We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies.
This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
Cookie
Duration
Description
cookielawinfo-checkbox-analytics
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional
11 months
The cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy
11 months
The cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.