Web Browser Component For Delphi XE6 Firemonkey On Windows And Mac OSX

  

The web browser control (TWebBrowser) that ships with Delphi XE6 Firemonkey only supports Android and IOS. If you want to use a web browser control in Firemonkey on Windows and Mac one option is the Chromium Embedded Framework (CEF). There are two different versions of the framework for Delphi which areDelphi CEF1 and Delphi CEF3. Both claim to support Firemonkey but I had to have an oDesk developer update CEF3 to support Delphi XE5 Firemonkey (and AppMethod) for me. It had to be modified a bit to run on XE6 and an architecture change was made to allow you to create TChromiumFMX at runtime. I have not tested it on Mac OSX but I believe it will also work there as there is a Mac library in the bin directory. When you use this TChromiumFMX component you will need to copy all of the files from the \cef_Chromium\bin\Win32 directory (or Win64) to whatever the final directory of your EXE file ends up being. You will also need to deploy all of these files with your application. I have two links below. The first one contains the MacOSX, Win32 and Win64 runtime files and the second download has no runtime files. If you already have the CEF3 file from Sourceforge or you have the XE5 version of this component you can download the second version. Here is some sample code for creating it at runtime:
procedure TForm1.Button1Click(Sender: TObject);
var
fBrowser: TChromiumFMX;
begin
fBrowser := TChromiumFMX.Create(Self);
fBrowser.Parent := form1;
fBrowser.Align := TAlignLayout.alclient;
fBrowser.InitializeBrowser; // this line is to add obligatory
fBrowser.Load(‘http://www.fmxexpress.com/’);
end;
Download TChromiumFMX for Delphi XE6 Firemonkey on Windows and Mac (70.2MB).
Download TChromiumFMX for Delphi XE6 Firemonkey on Windows and Mac without Runtime (106k).

Comments are closed.