August 2019 RAD Studio Roadmap Udpate

On the Embarcadero developer community site, there is a new blog post by Sarina DuPont covering: August 2019 Delphi Android Beta Plans & August Roadmap Update The blog post has an update to the May 2019 roadmap and it also highlights the plans around a Delphi Android 64-bit Beta that's going to be made available soon to update subscription customers. Read the article linked above for all of the details.
Read More

Installation and GetIt Workarounds for Delphi 10.3.2 (Updated)

Some of the Embarcadero servers (in one of the web farms) are experiencing some severe and prolonged outage. This is affecting (among other things) Delphi 10.3.2 installation. As a temporary workaround, the company has: provided the direct link to the ISO installer download, https://community.idera.com/developer-tools/b/blog/posts/10-3-2-installation-workarounds set up a new GetIt server to allow customers on 10.3.2 (and partially also on older 10.3.x versions) to install the most relevant add-ons and packages, like FMX Linux and Boost: https://community.idera.com/developer-tools/b/blog/posts/temporary-10-3-2-getit-server-for-installing-10-3-2-add-on-packages We should soon have the regular GetIt-based offline installer for 10.3.2 working again with the temporary server.  August 1st Update We now have the ability to install 10.3.2 via GetIt using this temporary system, there is no need to change the GetIt URL manually, as it is embedded in an updated installer. And CodeCentral MyRegistered products is online again with the updated downloads.  Read more on the latest status at https://community.idera.com/developer-tools/b/blog/posts/new-10-3-2-getit-installer. Thanks for your patience and sorry again for the inconvenience. 
Read More

delphi – Why variables are declared as TStrings and created as TStringList? – Stack Overflow

Blast from the past: [WayBack] delphi – Why variables are declared as TStrings and created as TStringList? – Stack Overflow Q Why variables are declared as TStrings and created as TStringList? A Because that way you could put another TStrings descendant in the SL variable (I’d probably call that Strings, not SL). In your case, that is moot, since the logic around SL contains the creation of a TStringList and no external assignment or parameter parsing. But if you ever split the logic away from the assignment, then you could benefit from using any TStrings descendant. For instance, a TMemoy.Lines, TListBox.Items, TComboBox.Items, etc. From the outside it looks like they are TStrings, but internally they do not use a TStringList but their own descendant. A few examples of classes that descend from TStrings: source\DUnit\Contrib\DUnitWizard\Source\DelphiExperts\Common\XP_OTAEditorUtils.pas: TXPEditorStrings = class(TStrings) source\fmx\FMX.ListBox.pas: TListBoxStrings = class(TStrings) source\fmx\FMX.Memo.pas: TMemoLines = class(TStrings) source\rtl\common\System.Classes.pas: TStringList = class(TStrings) source\vcl\Vcl.ComCtrls.pas: TTabStrings = class(TStrings) TTreeStrings = class(TStrings) TRichEditStrings = class(TStrings) source\vcl\Vcl.ExtCtrls.pas: TPageAccess = class(TStrings) THeaderStrings = class(TStrings) source\vcl\Vcl.Grids.pas: TStringGridStrings = class(TStrings) TStringSparseList = class(TStrings) source\vcl\Vcl.Outline.pas: TOutlineStrings = class(TStrings) source\vcl\Vcl.StdCtrls.pas: TCustomComboBoxStrings = class(TStrings) TMemoStrings = class(TStrings) TListBoxStrings = class(TStrings) source\vcl\Vcl.TabNotBk.pas: TTabPageAccess = class(TStrings) –jeroen
Read More

TMS VCL UI Pack is here, the next generation of TMS Component Pack

Since we launched TMS Component Pack back in 1998, it has been our flagship product for user interface controls for VCL based Windows application development with Delphi & C++Builder.
In the past 21 years, a lot happened. Unicode support was introduced, Win64 support added and more recently, VCL got support for (per monitor) high DPI and VCL Styles (including extra VCL styles from the DelphiStyles company). Embarcadero started offering in 2011 the FMX framework for cross platform development for which we meanwhile also developed a large number of cross platform user interface components and it became crucial to differentiate products by technology, like TMS FMX components, TMS FNC components, … and more recently also TMS WEB components…

After 21 years, we thought it was time to better align the VCL user interface components with our other product ranges and naming convention and therefore proudly introduce its successor product TMS VCL UI Pack v10.0. But there is much more to it than a name change for aligning it with other product lines. Internally we also completely moved the TMS Component Pack to a new build process that was already in use for our cross-platform FMX & FNC products.

The benefits are:

  • Moved to a new build & installer generation process allowing more frequent releases, faster rollout of improvements and fixes and also beta builds
  • Builds of full trial versions for all supported Delphi & C++Builder versions
  • In short term we will also submit a version for GetIt to facilitate download & install from the IDE itself
  • Faster migration & support to upcoming new Delphi & C++Builder versions
  • Better install/uninstall experience
  • Consistent & clear product naming
  • Focus on improvements for high DPI and VCL styles support across the entire TMS VCL UI Pack components
  • New components: Kanban board UI VCL control and TableView UI VCL control
  • Updated PDF generation library with new features
  • Keep components backwards compatible with TMS Component Pack v9.x components

A glimpse at what is new:

In TMS VCL UI Pack v10.0, we have not only 2 new VCL components but also several improvements to existing components:

  • TAdvKanbanBoard component, a highly configurable workflow visualization component
  • TAdvTableView component, a versatile & modern supercharged list control
  • PDF generation library improvements such as the capability to add rotated text
  • Support for VCL Styles

What does it practically mean?

Let there be no misunderstanding. We paid the utmost importance to make the step for you as easy as possible while moving the TMS Component Pack to our new build platform. Normally, it should be as simple as uninstalling TMS Component Pack + download and install TMS VCL UI Pack and recompile your applications with the new version. Some notes though:

  • If you use runtime packages, you will need to change the package name dependencies
  • If you use TAdvTreeView, we moved this component from using TCanvas to TAdvGraphics. When opening form files using TAdvTreeView, ignore possible property errors, save the form file and recompile.
  • If you use C++Builder, you will need to change the linked library name references in your project

We have summed up these steps in detail in a file migrate.txt that is included in the TMS VCL UI Pack install folder.

Moving to TMS VCL UI Pack

TMS VCL UI Pack v10.0 is the new product name for TMS Component Pack v10.0. This means all users entitled to get TMS Component Pack v10.0 automatically receive TMS VCL UI Pack v10.0. Also, users with an active subscription to TMS ALL-ACCESS, TMS VCL Subscription or TMS Component Studio receive TMS VCL UI Pack v10.0 automatically.

For your convenience, for a while we will simultaneously keep offering access to TMS Component Pack v9.x.
So, users with an active TMS Component Pack license will get both TMS Component Pack v9.x and TMS VCL UI Pack v10.x and users purchasing a TMS VCL UI Pack license or upgrading to TMS VCL UI Pack will also still get access to TMS Component Pack v9.x. Of course, as it concerns mostly the same components, these cannot be simultaneously installed in the IDE. But if, for one of the reasons above, a migration would require some work on your side to change package name references for example, you can freely chose when to plan this change and continue to use TMS Component Pack v9.x till you have time and are ready to switch to TMS VCL UI Pack.

What’s next

First of all, with our processes streamlined here, we will be even more efficient & productive to roll out new TMS VCL UI Pack versions with new features, new components and improvements more frequently and faster. The new naming convention should bring more clarity as to what technology the product can be used with. Similar work has been started here already for other TMS VCL products and all will get the TMS VCL xxx productname nomenclature in the coming months.

Feedback

Still having questions, comments or feedback? Don’t hesitate to leave a comment here on the blog or contact support for all questions and suggestions or sales for questions related to upgrading to TMS VCL UI Pack from older TMS Component Pack licenses or smaller VCL component bundles. We look forward to hear from you!

Read More

Read More

macOS 64 bit compile-ready support

Intro macOS 64 bit compilation support has been added to our products. Below is a list of products that are currently enabled to compile for macOS 64 bit TMS FMX UI Pack TMS FMX Chart TMS FMX Cloud Pack TMS FMX WebGMaps TMS FMX WebOSMaps TMS mCL TMS FNC Core TMS FNC Cloud Pack TMS FNC UI Pack TMS FNC Blox TMS FNC Chart TMS FNC Dashboard Pack We continue adding macOS 64 bit support to our other products, and will mention that in the version history whenever an update is released. macOS 64 bit compile-ready support? Our products are prepared to compile for macOS 64 bit, but this is not automatically enabled. Unfortunately, RAD Studio Rio 10.3.2 is an update that uses the same version number as older RAD Studio 10.3.* versions and therefore we have decided to not automatically install for macOS 64 bit, but make it compile-ready. To compile your applications for macOS 64 bit, please follow the steps below. Install/Update one of the products in the above list Update the macOS 64 bit library path with the path to the source files Compile/Deploy your application for macOS 64 bit by changing the target MapView TMS mCL TMS mCL originally has a MapView component that was working in a 32 bit macOS operating system and was then removed from the frameworks due to technical reasons. Now, with 64 bit, you will be able to use the MapView component again. Feedback Please provide any feedback regarding macOS 64 bit compilation support so we can further improve our products.
Read More

FNC Code Gems: Helpers for Base64 encoding and decoding

In the last post, I looked at methods to help you get information about connected displays and determine the path name for common folders. Let’s look at something very valuable when you want to convert binary data into a string: Base64 encoding.This is somewhat tricky if you have to consider all the different platforms and frameworks. FNC makes it very easy!

Again, the class TTMSFNCUtils offers awesome methods to get results quickly:

class function FileToBase64(const AFile: TTMSFNCUtilsFile): string;
   
class function Decode64(const AValue: string; 
                        const AURL: Boolean = False): string;
class function Encode64(const AValue: string; 
                        const AURL: Boolean = False): string; overload;
class function Encode64(const AValue: TBytes; 
                        const AURL: Boolean = False): string; overload;  

Not only are there methods to encode and decode strings, there is also FileToBase64 which allows you to retrieve the Base64 string for a file using a single line of code:

LBase64String := TTMSFNCUtils.FileToBase64( 'mydata.bin' );

Ignore the data type of AFile to specify the filename. In VCL and FMX the type TTMSFNCUtilsFile it is mapped to a string. However, for web applications you cannot specify a local file name and the method has to be invoked differently. There is no inverse function for this as it is already a one-liner in Delphi now to store a string or a byte array into a file using TFile from System.IOUtils.

In order to encode a string, call Encode64; call Decode64 to decode a string:

LMyBase64String := TTMSFNCUtils.Encode64( 'testtest', false );
LMyTestString   := TTMSFNCUtils.Decode64( LMyBase64String, false );

Remember, these methods are available for VCL, FMX, LCL, and TMS Web Core.

Read More

Read More

One Codebase – Multiple Targets

FNC

This week we focused on FNC, with a series of media content, brought to you via Facebook, Twitter, blog posts and other media channels. We wanted to focus on what FNC is by highlighting each framework and its corresponding operating systems individually. Here is a sample of what this looks like for the WEB.

We plan on using this for communication, promotion, technical articles, and we believe this will allow you, as a customer, have a better understanding on what FNC is. Below is an overview of what FNC offers, and what it can potentially mean for your application.

TMS FNC Controls can be simultaneously used on these frameworks:

  • VCL
  • WEB
  • FMX
  • LCL

TMS FNC Controls can be simultaneously used on these operating systems/browsers:

TMS FNC Controls can be simultaneously used on these IDE’s:

One Codebase

With FNC, we aim for one code base, that can be re-used on all the supported frameworks and eventually target multiple operating systems. We started with FMX and VCL, and thanks to the high level of abstraction we added LCL support which gave us access to Unix operating systems. Recently, we have added WEB support as well via TMS WEB Core. As an example, we have created an FNC overview demo to demonstrate the “one-codebase – multiple targets” principle.

We are currently also working very hard on a BETA of FNC, which brings a lot of small improvements and fixes, but also brings 2 new components: TTMSFNCPDFLib and TTMSFNCGraphicsPDFIO. In case you missed the blog post demonstrating these 2 components, check out the blog post at the following URL: https://www.tmssoftware.com/site/blog.asp?post=560. The blog post focusses on creating a report in PDF completely generated client-side in the webbrowser. It shows how to mix custom PDF content and existing FNC components and of course also works on the “one codebase – multiple targets” principle explained in this blog post.

We want your feedback!

Please feel free to leave a comment, send us an email with suggestions on this approach and what we can improve in our communication. We want you to get a smile out of your application, because a smiling application, is a smiling customer!

Read More

Read More

Ate too much candy? Calculate and export your BMI to PDF with FNC for the WEB!

Ate too much candy?

We all have those moments in life where we are proud of what we have achieved, be it in sports, school, at work… . Whenever we have reached a goal, were hard work lies at the base of it, we tend to reward ourselves with something that makes us even more excited of what we have achieved. For me, that something is candy. I know, I should be eating less of it, but hey!, I have earned it! As I’m obviously eating too much of it, I created a BMI calculation app to track if I should stop eating, or if there is still room for one tiny sweet piece of candy.

FNC for the web!

The application, which calculates the BMI, is written with the help of TMS FNC UI Pack, TMS FNC Dashboard Pack and TMS WEB Core and is running in the webbrowser. It allows entering your name, height (cm) and your weight (kg). The calculate button will indicate your BMI in the grid, allowing you to know if you should loose or gain some weight, or if you are absolutely perfect.

PDF for the web!

The BMI application is allowing you to export your data to PDF. Typically, when generating a report, invoice, or any other PDF data file in the browser, this is done on a back end server. The costs to handle the load, scalability can quickly rise and the maintenance gives a lot of headaches. With the TTMSFNCPDFLib and TTMSFNCGraphicsPDFIO components that are both used in the BMI application you no longer need a backend to generate a PDF in your web application. The components completely generate the PDF at the client-side (front end).

The TTMSFNCPDFLib component is used to generate the PDF, and the TTMSFNCGraphicsPDFIO component is a bridge to export FNC UI controls such as the TTMSFNCPlanner, TTMSFNCGrid, TTMSFNCChart and many more. In the BMI web application, both are used to combine the custom PDF exporting capabilities with the TTMSFNCGrid and TTMSFNCWidgetGauge components.

The code behind this is actually very simple.

procedure TPDFLibBMILogic.GeneratePDF;
var
  fn: string;
  o: TTMSFNCPDFIOExportObjectArray;
  r: TTMSFNCPDFIOExportRectArray;
  ms: TMemoryStream;
begin
  {$IFDEF ANDROID}
  fn := TPath.GetSharedDocumentsPath + PathDelim + 'BMI.pdf';
  {$ENDIF}
  {$IFDEF MACOS}
  fn := TPath.GetDocumentsPath + PathDelim + 'BMI.pdf';
  {$ENDIF}
  {$IFNDEF ANDROID}
  {$IFNDEF MACOS}
  fn := 'BMI.pdf';
  {$ENDIF}
  {$ENDIF}
  p.Options.Header := 'BMI Report for ' + FName;
  SetLength(o, 2);
  o[0] := FGauge;
  o[1] := FGrid;
  SetLength(r, 2);
  r[0] := RectF(50, 180, 50 + FGauge.Width, 180 + FGauge.Height);
  r[1] := RectF(50 + FGauge.Width + 50, 180, 50 + FGauge.Width + 50 + FGrid.Width, 180 + FGrid.Height);
  ms := TMemoryStream.Create;
  try
    p.Save(ms, o, r);
    ms.SaveToFile(fn);
    {$IFNDEF WEBLIB}
    TTMSFNCUtils.OpenFile(fn);
    {$ENDIF}
  finally
    ms.Free;
  end;
end;

The result, when clicking on the “Export To PDF” button, is shown below

Play with the demo yourself!

Curious on how the demo works, or if you want to know if you can eat more candy? Below is a link that shows the demo live! Note that the components, demo is currently not yet released, but we are working hard on a beta of FNC that is coming real soon, so stay tuned!

https://download.tmssoftware.com/tmsweb/demos/TMSWeb_FNCPDFLib_BMI/

Read More

Read More

TMS WEB Core v1.2 tips & tricks part 8: 3D Charts made easy

One of the big new features in TMS WEB Core v1.2 Padua is the built-in support for 3D graphics. This is accomplished by providing Object Pascal components and classes that wrap the powerful ThreeJS / WebGL libraries for rendering 3D graphics in the browser. This technology is meanwhile supported on every mainstream browser, including on mobile devices.

As always, the goal of TMS WEB Core is to offer OO RAD Component based we development, so, integrating 3D graphics in your TMS WEB Core web client applications becomes a piece of cake. So, let’s immediately jump to writing the code as an inspiration to get you started exploring the wonderful 3D web world.

When interfacing with an existing JavaScript libraries is done from a TMS WEB Core application, we have made it equally easy to setup the link references to these libraries. In case of 3D we will need the ThreeJS library. So, from the project context menu in the Delphi IDE select “Manage JavaScript Libraries” and from there check to use ThreeJS.

Next, put a TWebThreeJSChart on the form and you can start defining series for your chart. Since climate change is a bit a “hot” topic (pun intended) in the last years everywhere, for our sample we got the idea to render the average month temperatures in Belgium (where our main TMS office is located) for the past 3 years. We got the data from a website that lists the temperature measurements since 1833. You can find the data here.

The series we want to display are a series with all months of the year and a series for years. A series is of the type TThreeJsChartSeries and is created with the X and Y axis labels via:

var
  aSeries: TThreeJsChartSeries;

begin
  aSeries := TThreeJsChartSeries.Create(
   TJSArray.New('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'), 
   TJSArray.New('2017', '2018', '2019'));
end;

As you can see, we can create in Object Pascal a dynamic JavaScript array that ThreeJS needs via TJSArray.New(values).

Next, let’s add values for each month for the 3 years to the series. This is done for a month via:

  aSeries.addLegendRow('Jan', TJSArray.New(1.1, 6.0, 3.0));

Other than this, all we need is to setup things like title, X-axis label, Y-axis label, Z-axis label, Z-axis maximum and step value and the formatting of the values along the Z-Axis. When this is ready, to display the series, we simply clear any possible previous series that were setup and then assign the series created and call WebThreeJsChart.createChart.

One more property available in a series is the property TThreeJsChartSeries.ChartType. The 3D chart supports following types: ctBarChart, ctCylinderChart, ctConeChart, ctLineChart, ctAreaChart.

The total code becomes:

procedure TForm1.InitChart(AType: TThreeJSChartType);
var
  aSeries: TThreeJsChartSeries;
begin
  aSeries := TThreeJsChartSeries.Create(
    TJSArray.New('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'),
    TJSArray.New('2017', '2018', '2019')
  );

  aSeries.addLegendRow('Jan', TJSArray.New(1.1, 6.0, 3.0));
  aSeries.addLegendRow('Feb', TJSArray.New(6.1, 0.8, 7.0));
  aSeries.addLegendRow('Mar', TJSArray.New(9.6, 5.4, 8.5));
  aSeries.addLegendRow('Apr', TJSArray.New(8.8, 13.0, 11.0));
  aSeries.addLegendRow('May', TJSArray.New(15.5, 16.3, 12.0));
  aSeries.addLegendRow('Jun', TJSArray.New(19.2, 18.1, 0));
  aSeries.addLegendRow('Jul', TJSArray.New(18.3, 22.0, 0));
  aSeries.addLegendRow('Aug', TJSArray.New(18.1, 19.4, 0));
  aSeries.addLegendRow('Sep', TJSArray.New(14.1, 15.4, 0));
  aSeries.addLegendRow('Oct', TJSArray.New(13.3, 12.6, 0));
  aSeries.addLegendRow('Nov', TJSArray.New(6.6, 7.4, 0));
  aSeries.addLegendRow('Dec', TJSArray.New(4.4, 5.8, 0));

  aSeries.valueAxisMarkMaximum := 30;
  aSeries.valueAxisMarkStep := 5;
  aSeries.ChartType := AType;
  aSeries.valueFormatFloat := '#,##0°C';
  aSeries.Title := 'Average month'#13#10'temperatures Belgium';
  aSeries.ValueAxisTitle := 'Temp';
  aSeries.LegendAxisTitle := 'Months';
  aSeries.CategoryAxisTitle := 'Year';

  WebThreeJsChart1.Series := aSeries;
  WebThreeJsChart1.clearChart;
  WebThreeJsChart1.createChart;
end;

Finally, we want to add one more additional tip and that is a frequently asked question how we can easily center a control in the browser window using pure Object Pascal code instead of what is in web development more commonly done using HTML/CSS. Well, the good news is that in Object Pascal this is also very easy. Add an event hanlder for Form.OnResize and write the code:

procedure TForm1.WebFormResize(Sender: TObject);
begin
  if WebThreeJsChart1.Width 


This results in the chart with the numbers we have till now, May 2019:



or better discover it live here

There is much more than doing just 3D charts with ThreeJS and TMS WEB Core, there are also samples for creating surface charts, show 3D model files or setup your own 3D scenes. Discover these and more exciting features in TMS WEB Core that let you create web client applications with unprecedented capabilities.

You can download the trial version, go ahead with the standalone version you purchased or with TMS WEB Core and additional tools that are all included in TMS ALL-ACCESS. Our team looks forward to all your comments, feedback, feature-requests to help steering the development of TMS WEB Core to the next stages!

Read More

Read More

Delphi Now Has Linux UI Support

Just announced, FMXLinux has been licensed from KSDev for inclusion in the Enterprise and Architect editions of RAD Studio and related products (Delphi & C++ Builder).  The product is available via GetIt for all current subscribers. Since I have been following FMXLinux’s development for some time, I immediately installed the licensed version.  Unfortunately, the IDE experience is the same as the trial I previously installed directly from KSDev. I created a new Multi-device application with tabbed navigation from the wizard.  Looking at the list of target platforms (Android, Mac OS, iOS, Windows) I didn’t see Linux.  Fair enough, the templates on which the application is based do not contain the new UI platform.  Perhaps in a subsequent release since as per Marco’s introduction the product has not been fully integrated into the IDE. I went to add the new platform to the solution, by Rt. clicking The Target Platforms node in the project manager and it is greyed out.  If I delete a target it is re-enabled, but the list of targets I can add only contains the one I just deleted.  Rt. Clicking on the Application node in Projects window, there is an option “Add Linux Platform”.  Now I get a Linux 64 bit target platform node. This is covered in Marco’s introduction, but he doesn’t mention that attempting to add a component to my UI doesn’t work.  I can’t add a button to my form until I switch to another target platform, and then switch back so I can actually deploy and test on Linux.  This has been a known issue with the trial, and I was hopeful that such a poor user experience would be fixed now that EMBT has licensed the product.  For now, it’s an issue you will have to work around, and I’m sure it will be corrected in a future release. While only major Linux distros are currently supported (Ubuntu, RedHat and possibly a couple others) the team at KSDEV are working to support others including the more obscure ones like Elementary OS.  I for one am very pleased that Delphi finally can target Linux with GUI applications making it a complete XPlatform desktop solution for all 3 major targets.
Read More