Get access to over 100 FireMonkey cross platform samples for Android, IOS, OSX, Windows, and Linux!

AndroidAppmethodCode SnippetDelphiFiremonkeyIOSOSXWindows

Customize Button Colors In Delphi XE5 & XE6 Firemonkey On Android And IOS

Delphi XE6 Firemonkey Customize Color SpeedButtonDelphi XE6 Firemonkey has some new tint properties for easily changing the color of a TSpeedButton, a TButton, and a TToolBar. Sarina DuPont from Embarcadero has a new blog post up where she explains how to use the new properties and what they actually effect. The properties are cross platform but behave a bit different depending on the OS that your app is running on. For example, in IOS7 the TintColor property changes the outline and mousedown looks of a button but on Android it changes the background color of the button. You can also customize the color of the icon on some button styles using the IconTintColor property. And lastly you can modify the font color depending on the button state like being focused or pressed. Something else to keep in mind is that you can also use a colored TRectangle as a button or as a background for other transparent controls (like a TLabel or a transparent TListBox) because with Firemonkey any control can be the parent of any other control. Which is to say every control in Firemonkey is a container for every other control like it was a VCL TPanel. A TRectangle has a Fill and a Stroke property which allows you to change the background color and the line color of the rectangle. You can also use this TRectangle trick with Delphi XE5 and AppMethod since they do not support the new TintColor property. Be sure to set HitTest to True if you use a TRectangle as a button.

Head over and check the full blog post about using the new TintColor properties with Delphi XE6 Firemonkey.

Have Delphi Firemonkey questions? Ask and get answers on StackOverflow.

Related posts
AndroidC++BuilderCode SnippetDelphiDemoFiremonkeyIOSOSXShowcaseWindows

Powerful Cross Platform Email App Sample In Delphi 10.4.1 FireMonkey For Android And IOS


Significant Update Available For Delphi FireMonkey 10.4.1 On Android, IOS, OSX, Windows, And Linux


Professional SVG Icon Image List For Delphi 10.4 FireMonkey On Windows


Top Tips And Tricks To Speed Up Development With Delphi 10.4 FireMonkey On Android and IOS

Sign up for our Newsletter and
stay informed

Leave a Reply