The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,230 other followers

Delphi .dproj files: FrameworkType and FormType (via: Embarcadero Discussion Forums)

Posted by jpluimers on 2013/11/28

One more of the “Missed Schedule” series, this time it was originally scheduled for October 1st, (2013 that is).

Delphi XE2 and up introduced the FrameworkType and FormType elements in the .dproj files to distinguish between VCL and different flavours of FireMonkey.

Actually, Delphi XE1 already had the value None for FrameworkType, so some cross-platform changes trickled into the Delphi builds early.

Though the IDE writes these values to the .dproj files, you cannot change their values from within the Delphi IDE, not even through the Open Tools API.

There is no documentation about the values in the .dproj files. the only places I could find were these about FrameworkType in combination with Actions:

that basically tell this:

FrameworkType

Defines whether an action is created for the VCL or FireMonkey (FMX) framework. The default of this parameter is VCL (for compatibility with legacy applications).

This parameter is used to avoid situations when VCL actions are used in FireMonkey applications and inversely; this can lead to a serious increase in an application’s size and to execution errors, for example, calling of Windows API under MacOS.

But it is incomplete, and there is no documentation about FormType.

The valid values for FormType and FrameworkType are as follows:

FormType values:
<FormType>dfm</FormType>
<FormType>fmx</FormType>
<FormType>lfm</FormType>
FrameworkType values:
<FrameworkType>DotNet</FrameworkType>
<FrameworkType>FMI</FrameworkType>
<FrameworkType>FMX</FrameworkType>
<FrameworkType>None</FrameworkType>
<FrameworkType>UCL</FrameworkType>
<FrameworkType>VCL</FrameworkType>

view raw
dproj.txt
hosted with ❤ by GitHub

FormType values

Value FormType values are these:

dfm VCL form (equivalent to an empty string, or no element at all)
fmx Firemonkey form (except for Delphi XE2 where this denotes a non-mobile Firemonkey form)
lfm Delphi XE2 Firemonkey mobile form (for the iOS support through FreePascal)

FrameworkType values

Valid FrameworkType values are defined in the ToolsAPI.pas unit of the ToolsAPI:

sFrameworkTypeDotNet = ‘DotNet’; .NET application (this value is not used anywhere in http://sourceforge.net/projects/radstudiodemos/)
sFrameworkTypeFMI = ‘FMI’; Delphi XE2 Firemonkey mobile application (for the iOS support through FreePascal)
sFrameworkTypeFMX = ‘FMX’; Firemonkey application (except for Delphi XE2 where this denotes a non-mobile Firemonkey application)
sFrameworkTypeNone = ‘None’; VCL application (for backward compatibility; equivalent to no FrameworkType element at all)
UCL Firemonkey 3D application (this is an error value as it is not in ToolsAPI.pas, but it is in the RadStudioDemos)
sFrameworkTypeVCL = ‘VCL’; VCL application

UCL is an error (it is an invalid value), but it is present in these demos:

RadStudioDemos\branches\RadStudio_XE2\FireMonkey\helloworld3d\helloworld3d.dproj
RadStudioDemos\branches\RadStudio_XE2\FireMonkey\LowLevelDemo3D\LowLevel3DDemo.dproj
RadStudioDemos\branches\RadStudio_XE3\FireMonkey\helloworld3d\helloworld3d.dproj
RadStudioDemos\branches\RadStudio_XE3_Update\FireMonkey\helloworld3d\helloworld3d.dproj

and fixed to FMX as of Delphi XE4.

FMI

The only posting I could find about FMI was the one below.

To make sure the via Embarcadero Discussion Forums: Convert FMX to FMI …. does not get expired on the forums server (they have a finite retention there which can be quite short for certain newsgroups):

I have automated this in FinalBuilder with these steps:

Copy the whole project folder

1) Replace FMX. with FMX_ in Demo.dpr file
2) Replace <FrameworkType>FMX</FrameworkType> with <FrameworkType>FMI</FrameworkType> in Demo.dproj
3) Replace <FormType>fmx</FormType> with <FormType>lfm</FormType> in Demo.dproj
4) Rename Formfile UDemo.fmx to UDemo.lfm
5) Replace FMX. with FMX_ in UDemo.pas
6) Replace {$R *.fmx} with {$R *.lfm} in UDemo.pas
7) Run Dos command dpr2xcode on Demo.dpr to create XCode compatible project files.

view raw
Text
hosted with ❤ by GitHub

This should be sufficient to create a iOS compatible project from a HD project.

–jeroen

via: Embarcadero Discussion Forums: Convert FMX to FMI ….

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

 
%d bloggers like this: