|
|
|
Delphi - Developer Express - .Net & XP Styles
Download Project Sample
In this article we are going to cover some of the more advanced techniques used to tailor Developer Express components. The article covers both dxDBGrid and dxTreeView. We will be taking a look at techniques to paint rows and columns, add icons and stylize for an XP look and feel. Our examples relate to applications written in Delphi (5) or similar. For our examples we assume you already have a basic understanding of Delphi code syntax and have access to Developer Express components (EQGridPro).
Any good Delphi developer will tell you that Developer Express is one of the very best 3rd party providers for Delphi components. Their data aware grids and tree views are so simple to use but provide huge functionality. But how many of those same people have really ventured into the components to improve upon the look and feel of their applications? Developer Express provide the perfect features to help your Delphi applications look more like .Net and Windows XP. All it takes is a couple of properties and a little code and you can transform your applications.
Lets start by looking at the dxDBGrid component. For anyone who is not familiar with this component we strongly recommend you consider purchasing it as you wont be disappointed with the range of features available. The dxDBGrid component provides a much stronger data aware grid than the off the shelf Borland grids (TDBGrid). Developer Express allows you to modify the look and feel of the grid right down to the fine detail of actually choosing each column type you want to use. There are 20 different column types to choose from including Mask Column, Button Column, Time Column, Image Column and many more.
First of all we are going to look at the properties of dxDBGrid which we can tailor to make our applications look more like .Net and Windows XP. There are several properties we can adjust in the Developer Express grid to make our application look more like .Net:
OptionsDB- edgoPartialLoad : Setting this option to true mimics the behaviour of .Net. Only the visible records on screen are actually loaded into the grid. When the user scrolls down the grid the additional records are added and hence shown on screen. This option significantly improves the speed of data retrieval and display for large record sets.
OptionsBehaviour - edgoTabThrough - Setting this option allows the user to add new rows by pressing the tab key (when they are in the last column of the last row). This mimics the DataGridView component of .Net.
LookAndFeel - Changing this option dramatically changes the look of the grid. The grid borders become compressed and row details appear to be flat. This mimics the behaviour of .Net and XP. Users will notice a significant difference in your applications if you alter this option.
GridLineColor - Modifying this to a pale blue, similar to XP makes your grids look more modern
|
|
Featured |
Other popular Delphi resources. Why not try them for yourself?
|
|
Delphi Knowledge Base. Best practices, walkthroughs, tutorials, component advice and more. Solutions and professional designs for Delphi 4, Delphi 5, Delphi 6 and Delphi, 7. Word COM, Excel COM, Outlook COM including code examples for Word OLE, Excel OLE and Outlook OLE. Automating Outlook to create MailItem and send attachments in Delphi. ActiveX, Com. ADO Data Architecture, TMS component pack walk through and code examples. Using Developer Express and example walkthroughs. Date & time conversion routines, video playback and frame manipulation. COM articles, papers, tips, techniques and hints. How to create Word reports and excel spreadsheets using Delphi code and OLE automation. Understanding Delphi encryption and using ciphers, with source code examples of Blowfish, Twofish, and Rijndael. Securing application data and confidential information using open source encryption components. Free encryption dll component. Accessing and managing MS Excel sheets with Delphi. How to retrieve, display and edit Microsoft Excel spreadsheets with Delphi automation. Accessing and managing MS Word documents with Delphi. How to retrieve, display and edit Microsoft Word documents using Delphi automation. Read and write Excel spreadsheets using Delphi code. How to read and write registry entries using Delphi code. Source code examples using Delphi 5, Delphi 6 and Delphi 7. Working with VCL Developer Express components. How to apply grid styles and themes to Delphi applications. Using image columns and shading to improve the grid and treeview appearances. Including examples from ExpressQuantumPack, for Delphi, ExpressPack for Delphi. Developer guides for Developer Express components. All our articles are written by our senior Delphi professionals to help you get the best from your legacy Delphi applications |
|