Archive for Delphi

SkypeNote

I got an idea for project that will improve user experience of a Skype.

I call it SkypeNote. It will allow users to add notes to each Skype window. It took me some time to create prove of concept, but I manage to make it working and I’m using it for my internal uses.

photo-main

I’m now trying to finance this project over KickStarter.

If you are interested please support me.

Another fix of Delphi code – Click on the ListView

My customer found another but at Delphi application:

TListView Bug

 

If you click at TListView on the empty are, last item get automatically selected and events as  OnClick and OnItemClick are called.

Well it can be nice feature for someone, but it’s not really logical .. for example if you have open keyboard and you want to hide it, by clicking at the empty area.

There is no settings to tun this behavior off as it’s hard coded.

The problem is at FMX.ListView.pas unit at FindItemAbsoluteAt procedure, line 4060.

This code:

if ViewAt >= HeightSums[HeightSums.Count - 1] then
 Exit(HeightSums.Count - 1);

Replace with this code:

 if ViewAt >= HeightSums[HeightSums.Count - 1]+GetItemHeight(HeightSums.Count-1) then
 Exit(-1);

And the system will start to work logically.

You can download modified unit here, just include into your project.

Fixes of TMemo for Samsung Android

One of my customer reported falling of the Delphi XE5 Application at his Samsung Android device.

DelphiBug

When he was quickly typing multiple lines after while the app crashed.

It took me while to get the problem replicated, but eventually I found the bug.

It’s at the FMX.Platform.Android unit at TTextServiceAndroid.DrawSingleLine procedure.

From some reason the FCaredPosition is out of the range of the FLines StringList.

Replace this code:

if (FLines.Count > 0) then

with

if (FLines.Count > 0) and (FCaretPosition.Y>=0) and (FCaretPosition.Y<Flines.Count) then

 

Or you can download fixed unit here and simply included it into your project.

Embarcadero recently released new version of Delphi – XE6. Well I would suggest them to focus on fixing bugs at existing XE5 for people who already purchased their product, rather then release new version ever few months.

Reading data from the MIDI keyboard at iOS (and probably also at the Mac)

I’m just implementing support for the MIDI keyboard under iOS – mean you can connect MIDI keyboards (I’m using MIDITECH GARAGEKEY Mini) connected via the Apple iPad Camera Connection Kit.

The keyboard works perfect, you just plug it into the iPhone or iPad and it works. As the keyboard doesn’t have any additional led diode it has really low power consumption.

From the free software I found only GarageBand from Apple to be working with the keys.

At my application the keyboards can be easily implemented via the CoreMIDI (here is link to download my implementation for Delphi).

Garagekey mini

 

Read more

Submitting application to the Apple store from Delphi.

Today I wanted to submit my app to the Apple Store for my customer.

This is generally the procedure: http://docwiki.embarcadero.com/RADStudio/XE5/en/Deploying, but I got some problems.

It’s done via Application Loader that can be downloaded after registration at the https://itunesconnect.apple.com .

Application-loader-2-5-1

Unfortunately I got few errors after first upload:

ERROR ITMS-9000: “The bundle identifier cannot be changed from the current value, ‘PianoWizard’. If you want to change your bundle identifier, you will need to create a new application in iTunes Connect.” at SoftwareAssets/SoftwareAsset (MZItmspSoftwareAssetPackage)

ERROR ITMS-9000: “This bundle is invalid. The application-identifier entitlement is missing; it should contain your 10-character Apple Developer ID, followed by a dot, followed by your bundle identifier.” at SoftwareAssets/SoftwareAsset (MZItmspSoftwareAssetPackage)

ERROR ITMS-9000: “Invalid Launch Image – Your app contains a launch image with a size modifier that is only supported for apps built with the iOS 6.0 SDK or later.” at SoftwareAssets/SoftwareAsset (MZItmspSoftwareAssetPackage)

ERROR ITMS-9000: “This bundle is invalid. Apple is not currently accepting applications built with this version of the SDK or Xcode.” at SoftwareAssets/SoftwareAsset (MZItmspSoftwareAssetPackage)

Here is how I handled them:

Read more

Opening an URL at separated browser under Delphi XE5.

I was just recently handling quite simple task – to open an URL from the mobile application.

It’s simple under windows .. you will just call ShellExecute function.

But at Delphi that should unify access to all basic tasks for all different platforms is this function somehow missing… ops.

I found solution for the Android and solution for the iOS.

Read more

Implementing missing iOS frameworks

The challenge

As I mentioned in previous posts, I’m just writing a game for an iOS under Delphi XE-5.

Well on the begging it was looking really nice and easy, but there are some catches.

XcodeFirst Delphi doesn’t support multi-touch. This was handled thanks to support of Iztok Kacin.

Second catch was MIDI.

I found that iOS can play MIDI by this article, but from Delphi I couldn’t call it, because “god knows why” Embarcadero created support for some of the frameworks under Delphi.

So I was digging and digging and I found out that it’s actually relatively simple to add missing frameworks to Delphi.

The solution

Embarcadero did that for some of them and Xcode gives header files to each of the framework.

Read more

Tool to easy setup deployment files for Delphi XE5

I’m using Delphi XE-5 for development and they are contradictory.

I think that person who is responsible for whole product is truly visionary and he actually saved future of whole product.

Delphi XE5

The fact that you can by one code develop under Windows (32 or 64bit), Mac, Android and iOS is just amazing.

And it’s really working.

Well the Android app take long time until it starts because the app is not a Java but it’s a native application. Benefit is that any component will work there. It’s really great.

But there are also bad things. There are some decisions that was made and that makes me crazy.

Read more

Publishing AddHoc application on the iPhone

I’m now working on my first commercial game for the iPhone at Delphi XE5. It’s called Piano Wizard .

Delphi XE5

I was just sending to the customer a version for testing (it’s called Ad hoc) and it doesn’t worked at his phone.

Read more