TImageList is a new FireMonkey component in RAD Studio XE8. Image lists can be used as centralized collections of images with many different UI controls such as menus, lists and more. TImageList has built-in support for multiple resolutions to ensure your application icons and images appear correctly on different device form factors, resolutions and platforms.
I created a small Restaurant Menu demo application that shows how to use TImageList with the TListView component.
In this example, TListView is bound into some sample data that I loaded to the FDMemTable component. The ImageList component is selected on the Images property for TListView. The ImageIndex field in the data set is bound into TListView’s ImageIndex property.
As you can see in the snippet below, ImageIndex="0" correlates with ‘Burgers’ in my list.
<RowList><Row RowID="0" RowState="Unchanged"> <Original FoodItemName="Burgers" ImageIndex="0"/>
To find out more about TImageList, have a look at these resources:
- Docwiki article on using TImageList
- YouTube video showing the feature in action
- RAD Studio XE8 ImageList demo project
Below is a screenshot of my application running on Windows with the new ‘Radiant’ premium FireMonkey style for RAD Studio XE8.
Want to learn more about the great new features in Delphi, C++Builder and RAD Studio XE8?
Download a free trial here and click on the banner below to sign up for our new Developer Skill Sprint series, starting next Tuesday, April 21st, 2015.
posted @ Fri, 17 Apr 2015 20:49:32 +0000 by sarinadupont
The new maps component in RAD Studio XE8 makes it easy to add mapping functionality to your mobile applications. TMapView provides access to map APIs for iOS and Android. On Android, it uses the Google Maps Android API and on iOS, it uses the Map Kit Framework.
The key features of the TMapView component are:
- Four Types of Maps: Normal, Satellite, Hybrid and Terrain (Android only)
- Gesture Control: Intuitive tilt, rotate and zoom gesture controls
- Control the Map View: Ability to control the map properties such as the map center coordinates, the map orientation and so on
- Custom markers: Ability to add markers to the maps
If you are using TMapView on Android, you will need to obtain a Google Maps API key.
RAD Studio XE8 ships with two maps sample applications for Object Pascal and C++.
- C:\Users\Public\Documents\Embarcadero\Studio\16.0\Samples\Object Pascal\Mobile Samples\Device Sensors and Services\Maps
- C:\Users\Public\Documents\Embarcadero\Studio\16.0\Samples\Object Pascal\Mobile Samples\Device Sensors and Services\Map Type Selector
- C:\Users\Public\Documents\Embarcadero\Studio\16.0\Samples\CPP\Mobile Samples\Device Sensors and Services\Maps
- C:\Users\Public\Documents\Embarcadero\Studio\16.0\Samples\CPP\Mobile Samples\Device Sensors and Services\Map Type Selector
I created a small demo project that uses the Spitcast REST API, REST component framework, FDMemTable and TMapView to display surf locations on my map based on the longitude, latitude and spot name information returned from the REST service. A custom marker graphic in the shape of a surfboard fin is used to indicate the locations on the map.
You can download my demo project here.
Here is a code snippet from the demo project:
procedure TForm26.FormCreate(Sender: TObject); var LongitudeField: TField; LatitudeField: TField; MyLocation: TMapCoordinate; Descr: TMapMarkerDescriptor; SpotName : TField; begin RESTRequest1.Execute; begin LongitudeField := FDMemtable1.FieldByName('longitude'); LatitudeField := FDMemtable1.FieldByName('latitude'); SpotName := FDMemTable1.FieldByName('spot_name'); FDMemTable1.First; while not FDMemTable1.EOF do begin MyLocation := TMapCoordinate.Create(StrToFloat(LatitudeField.AsWideString),StrToFloat(LongitudeField.AsWideString)); MapView1.Location := MyLocation; Descr := TMapMarkerDescriptor.Create(MyLocation, SpotName.AsWideString); Descr.Icon := BitmapSource.Bitmap; BitmapSource.Visible := True; Descr.Draggable := True; MapView1.AddMarker(Descr); MapView1.Zoom := 8; FDMemTable1.Next; end; end; end;
Here is the app running on my iPad:
posted @ Thu, 16 Apr 2015 17:15:07 +0000 by sarinadupont
posted @ Thu, 16 Apr 2015 11:25:00 +0000 by Tim Del Chiaro
Продолжим рассмотрение нового подхода разработки (1 часть, 2 часть) и в этой статье рассмотрим использование нативных контролов на базе механизма презентаций для iOS. В качестве примера мы превратим TSpinBox в нативный для iOS.
Полная статья доступна здесь
posted @ Wed, 15 Apr 2015 12:25:28 +0000 by Yaroslav Brovin
A beacon is a Bluetooth Low Energy device including some information in its advertising data.
Working with beacons requires code to read the beacons and some setup to ensure you read only the right beacons, especially as more and more are appearing! This article mainly focuses on the latter and what you should be aware of before you deploy your beacons.
Programming for iBeacons & AltBeacons
While you can code to work with beacons via a number of languages, RAD Studio XE8 has introduces a new multi-platform component for working with beacons – as covered in this post from Sarina DuPont – this is very cool making it super easy to have both Android and iOS and Mac applications running from common code. However this is out of the scope of this post.
I will however point you to the sample projects shipped with RAD Studio XE8 using both Delphi and C++ in the following samples folder which can be opened directly using the shortcut to the samples in the IDE.
There is also great detail about what beacons are in DocWiki
<Samples>\<language>\Mobile Samples\Device Sensors and Services\Bluetooth\Beacons
Getting started with Beacon Hardware
So what do I need to know about beacons?
Firstly, beacons are typically following 2 standards for broadcasting over Bluetooth 4.
Using these standards you can pick up data to identify a specific beacon and how far it is away. The 4 key bits of information to manage this are
Using the new Beacons component you can define which type of beacon(s) you want to scan for using the UUID as a filter, and optionally Major and Minor ID – and this brings us onto the importance of the UUID
By default the UUID is set based on the beacon manufacturer. If you are going to use beacons in a real world application then you will probably want to update the UUID to a unique ID that you will be scanning for. This way you can limit any other beacons that are deployed.
Beacon Major and Minor
Beacon Major and Minor ID’s are used to identify the specific location you want to indicate with the Beacon. Hence its important that you update the UUID so you read only the correct beacons to check for the location you are at.
An example would be using the major to identify a retail store and a minor to a specific area in the retail store.
Programming the Beacon
There are a number of beacon manufacturers out there, and its typically easy to re-program your beacon to have that unique UUID and then set the Major and Minor ID’s.
Once such beacon is the RadBeacon from Radius Networks
Radius Networks provide a useful Beacon config application that you can download for free (once you register)
The default pin for editing the beacons is 0000.
Requirements for the Config App
For the software requirements visit the Beacon config application home page. In short, Bluetooth 4 is a minimum and Mac (10.9+) or recent iOS / Android releases.
Securing your Beacons….
Before you deploy your beacons, you may want to secure your beacon from tampering.
It is suggested by Radius networks that you lock your beacon before its put into a live environment. Locking a beacon prevents any further editing over bluetooth, so you need to be sure of your config before you do this.
A little less radical is updating the pin code for editing the beacon, however this is easily cracked so really only ideal for short term setup.
More about what the different options on the config application do are available here: http://www.radiusnetworks.com/ibeacon/radbeacon/mac/2-0-0/help.html
posted @ Sat, 11 Apr 2015 10:40:01 +0000 by Stephen Ball
Free 30-day fully functional trials of the Architect edition.
|Install from the Web for XE8 registered users |
If you need to re-download the installer after your initial installation.
|RAD Studio XE8 ISOs for registered users |
If you want to create a full install backup DVD after installing and registering.
RAD Studio XE8 ISOs for first time installs
If you can't install using the web installer due to firewall issues and need to create a DVD for your initial install.
Note that there are no official torrent or other downloads for RAD Studio XE8, Delphi XE8 or C++Builder XE8. Be sure to download them from the official source.
posted @ Sat, 11 Apr 2015 07:30:00 +0000 by Tim Del Chiaro
Delphi, C++Builder and RAD Studio XE8 include some great new VCL Styles. UI theming is an easy way to quickly change the look of your existing applications.
The following new styles are included in XE8:
You can easily apply a custom style to your existing VCL Windows applications via Project > Options > Application > Appearance.
New premium VCL styles are also available for RAD Studio XE8 as part of the XE8 Bonus Pack. You can access the offer details here: http://www.embarcadero.com/radoffer
posted @ Fri, 10 Apr 2015 18:04:20 +0000 by sarinadupont
If you buy or upgrade now, you can get all of this:
- 10% introductory discount
- Bonus software with your purchase
- XE3 and later registered users qualify for upgrade pricing
- XE2 and earlier registered users qualify for upgrade pricing when purchasing with 1 year Update Subscription
posted @ Fri, 10 Apr 2015 13:33:00 +0000 by Tim Del Chiaro
Database updates in RAD Studio XE8
FireDAC & IBX support for Change Views
FireDAC has introduced new support for Change Views – enabling rapid identification of what has changed on the server side data and updating of client side stored data. See this <2min video for how these work.
Source code for the example ships in the samples directory:
IBX has also introduced new components to make it easier to work with change views and subscriptions.
New Platform – Teradata
FireDAC now includes support for Teradata, using the driver name TData.
An example of how to set the driver properties is shown on the docwiki help for connecting to Teradata with Delphi.
TDataSet TField speed up.
Marco Cantu mentioned on the Launch webinar Q&A a customer was claiming seen a speed up of around 25% on a TClientDataSet application due to the refactoring at the base of how TField is used at the core layer. This is really cool for both VCL and also FMX developers.
64bit support for iOS
With the new platform for iOS 64bit, the database layer is also seamlessly available, just recompile and run
There are updates for EMS including push notification. EMS is a great way to access central data from mobile devices. EMS now is updated to include InterBase XE7 for both the server and ToGo side, allowing you to use Change Views on both Server and Clients.
Where FireDAC uses SQLite, it has been updated to a newer driver.
For more of whats new in RAD Studio XE8, including EMS updates, please click here Whats new in Delphi XE8 and C++ Builder XE8
posted @ Fri, 10 Apr 2015 10:40:01 +0000 by Stephen Ball
New approach of development of FireMonkey control "Control — Model — Presentation". Part 2. TEdit with autocomplete
We will continue a subject of the review of new approach on division of a control into the model and presentation described here. And in this article we will consider practical uses of this approach on the example autocompletion of input in TEdit.
Full article is available here
posted @ Thu, 09 Apr 2015 14:28:32 +0000 by Yaroslav Brovin