Three Graphics Tips For Delphi XE6 Firemonkey On Android And IOS

Delphi XE6 Firemonkey Graphics TipsHere are three different graphics question and answer tips from the Firemonkey section on StackOverflow:

#1: How do I flood fill a TCanvas with Firemonkey?

The given solution recommends defining path data in a TPathData and then flood filling the path with TCanvas.FillPath. TPathData is pretty useful as you can use it to draw all kinds of custom shapes in Firemonkey with it as well.

#2: How can I access every pixel on a mobile define screen when all the resolutions are different?

The solution basically says that you can draw with the native device resolution by inverting the scaling with TCanvas.SetMatrix like this:

#3: How can I display an image full screen with TImageView on mobile devices without distortion?

The recommended solution is to place the TImageView inside of a ScaledLayout and then use the Screen.Size property to scale the ScaledLayout component based on the screen size.

The code from these tips should work cross platform on all Firemonkey supported platforms which are Android, IOS, Windows, and OSX.

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

Three Graphics Tips For Delphi XE6 Firemonkey On Android And IOS by Delphi XE5 XE6 XE7 XE8 10 Seattle Berlin Firemonkey, Delphi Android, Delphi IOS is licensed under a Creative Commons Attribution 4.0 International License.

Leave a Reply

Show Buttons
Hide Buttons
Read previous post:
Delphi XE6 Firemonkey App Tethering Sample Code
App Tethering Sample Code Snippets In Delphi XE6 Firemonkey On Android And IOS

Developer Jens Fudge from Denmark has a blog post up about implementing app tethering with Delphi XE6 Firemonkey. Basically he...