New UI controls in TMS WEB Core v1.4 Ravenna

4 hours 5 minutes ago

TMS WEB Core v1.4 Ravenna has new features and improvements on all levels. There are many RTL improvements like different new type helpers, the TStringBuilder and lots more, there is Bluetooth device connectivity, there are several new options for using data back-end APIs like Embarcadero RAD server, FaunaDB, DreamFactory, there is enhanced HTML template binding with the TWebElementActionList, there are many IDE integration improvements like hierarchical folder import to facilitate HTML template usage and of course, there are also improvements on UI controls and also new UI controls!

Today, our colleague chief evangelist Dr. Holger Flick prepared videos showing you the new TWebImageSlider and the new TWebContinuousScroll.


Whenever there is a scenario where a list of information to be displayed to a user is very large, a convenient pattern is to show in the UI the initial first number of items filling the screen and only fetch more items as the user scrolls through the list. The advantage here clearly is that the page comes up very fast, will never load more items than the user wants to see and fetches extra items only as the user scrolls through the list. We have encapsulated all this functionality into a single new easy to use component TWebContinuousScroll. How it can be used is explained in this video or you can explore it directly in a demo application. Be sure to also try out this demo on a smartphone as the control is obviously also designed for use in responsive web applications.


Very often, one wants to present a selection of pictures of a product, a person, a house, a car to users in a web application. This is then typically done with a list of picture thumbnails one can click to view the large image or means to scroll trough the list of pictures. For this often used pattern, we created a new UI control TWebImageSlider that makes offering this UI as easy as filling a TStringList with URLs of images to be displayed. Dr. Holger Flick explains all in more detail with his newest video or try out the new component with our live demo.

Don't stay behind, discover TMS WEB Core v1.4 now!

Active registered users of TMS WEB Core get the new version v1.4 free. Login on our website and download the newest release. Not yet a TMS WEB Core user? Signup for a fully functional trial version of TMS WEB Core now also supporting the newest Delphi 10.4 Sydney.

Excited about all the hot technology we offer for Delphi & C++Builder developers, get your VIP seat with TMS ALL-ACCESS, our no-nonsense subscription to our entire product offerings, priority support and access to betas (such as the upcoming TMS WEB Core for Visual Studio Code!

Coming up: style your components with FNC styles!

4 hours 5 minutes ago

Look and Feel A major part of your application is the look and feel. It can take up a lot of resources and time to make your application stand out, make it attractive, a feast for the eyes. When eating dinner, you also want your plate to look nice, because it makes it more appealing, and yells: "Eat me!". Of course, your application needs to function properly, but don't we all want to have a nice looking user interface?

Coming around the corner are FNC styles, that will help you achieve a slick user interface!

FNC Styles FNC Styles is designed to provide you with 2 ways to style your application.

  • Built-in styles
  • Custom styles
In the first version of FNC Styles the built-in styles will be: Dark, Light, Office 2019 Black, Office 2019 Gray and Office 2019 White.

Custom styles will be configurable through the style manager, based on the default or built-in styles.

The style manager (also available as a separate component), will provide you with an easy way to load styles at designtime & runtime, and the possibility to combine multiple individual component styles to one style, that you can apply to all your forms. At designtime and runtime, the built-in styles are available through a resource.

JSON based The style mechanism is based on the persistence interfaces that already exist in FNC. It will generate a JSON that only contains the necessary information based on the components appearance properties. The detection happens automatically, but finetuning can be done with the IsAppearanceProperty virtual. Some components needs to save more information than others. Even custom components that you have designed will be styleable through the ITMSFNCPersistence interface, when inheriting from TTMSFNCCustomControl.

{ "$type":"TTMSFNCCalendar", "Color":"#484848", "DateAppearance":{ "$type":"TTMSFNCCalendarDateAppearance", "BadgeFill":{ "$type":"TTMSFNCGraphicsFill", "Color":"#FF0000", "ColorMirror":"gcNull", "ColorMirrorTo":"gcNull", "ColorTo":"#808080", "Kind":1, "OnChanged":null, "Opacity":1, "Orientation":1, "Texture":"", "TextureMode":2 }, "BadgeFont":{ "$type":"TTMSFNCGraphicsFont", "Color":"#FFFFFF", "Family":"Segoe UI", "Name":"Segoe UI", "OnChanged":null, "Size":10, "IsFMX":true, "Style":0 }, "BadgeStroke":{ "$type":"TTMSFNCGraphicsStroke", "Color":"#FF0000", "Kind":1, "OnChanged":null, "Opacity":1, "Width":1 }, "DateAfterFill":{ "$type":"TTMSFNCGraphicsFill", "Color":"#484848", ... Create your own style! When the new FNC style mechanism is released, it will allow you to use the built-in styles or create and apply a custom style to your application. Feel free to share the style you have created, we can even include it as a built-in style. Stay tuned, FNC Styles is around the corner and will be available real soon!

Hardening: sshd_config – How to configure the OpenSSH server | SSH.COM

5 hours 4 minutes ago
If you want to harden your ssh server, read at least [WayBack] sshd_config – How to configure the OpenSSH server | SSH.COM. After that use some ssh tools to check your config from the outside world. They work in a similar way as the TLS/SSL/https scans from Source: SSL Server Test (Powered by Qualys SSL Labs) or […]

Thread.Destroy deadlocks in finalization of COM+ dll’s…

23 hours 4 minutes ago
Reminder to self that this is still broken: [WayBack] Thread.Destroy deadlocks in finalization of COM+ dll’s This serious bug still exists in Delphi 10.2 after 12 years being reported! http://qc.embarcade… – 丽丽乌克 – Google+ Original report: WayBack1: QC Report # 29843 Thread.Destroy deadlocks in finalization of COM+ dll’s WayBack2: QC Report # 29843 Thread.Destroy deadlocks […]

Access Bluetooth devices from your TMS WEB Core v1.4 Ravenna web apps

1 day 4 hours ago

TMS WEB Core v1.4 is released and one of the many exciting new components added is the TWebBluetooth component to make it seamless to access Bluetooth devices from your web applications. At this moment, all modern web browsers except Safari, offer the web Bluetooth API for this. We can only hope that Apple will soon follow this trend.

With more than 4 billion Bluetooth devices produced in 2019, including all current smartphones, tablets, laptops, TV’s, and speakers on the market, Bluetooth has truly started a revolution. By 2023, up to 90% of all Bluetooth devices will have Bluetooth Low Energy (BLE) capability. With that in mind TMS Software is providing you with the tools to embrace this exciting technology and run with it.

The TWebBluetooth component and supporting classes allows for quick and easy development of all your Bluetooth Low Energy applications, bringing device functionality straight to the browser. To get up and running, just add the WEBLib.Bluetooth library to your TMS Webcore project under uses and you will gain access to the following features:

TBluetooth component: Used to create an instance of a Bluetooth Device. It contains methods for filtering which devices you wish to connect to.

Device class: It contains methods for establishing and maintaining a connection to, or disconnecting from the GATT server. It also contains methods allowing access to and discovery of services on a device.

Service class: It can be seen as a container for characteristics. The service class contains methods allowing access to and discovery of its characteristics.

Characteristic class: This is the main component of any BLE device. Reading and writing to these characteristics gives you control over a device. Our Characteristic class contains options for reading, writing and notifying data of all different data types/data streams to and from a Characteristic. Characteristics also contain methods for accessing and discovering its descriptors.

Descriptor class: Descriptors contain information about their characteristics. The Descriptor class has methods for reading and writing to descriptors.

To demonstrate how easy our tools are to use, I have configured an ESP-32 with a BME-280 temperature, humidity and pressure sensor. The ESP-32 is a microcontroller with onboard Bluetooth functionality. Using the BLE Server library with the Arduino IDE, I created a service with 4 characteristics. The first characteristic will be used to store and retrieve an integer value. The second is configured to control the onboard LED, allowing us to turn it on and off. The final two characteristics are set to retrieve temperature and humidity readings.

Getting started In our TMS WebCore project we must first declare the components we will be using: Public { Public declarations } bt: TBluetooth; MyDevice: TBluetoothDevice; MyService: TBluetoothService; IntCharacteristic: TBluetoothCharacteristic; LedCharacteristic: TBluetoothCharacteristic; TemperatureCharacteristic: TBluetoothCharacteristic; HumidityCharacteristic: TBluetoothCharacteristic;
Each Bluetooth service, characteristic or descriptor has an UUID, this is the address used to access it.

const MyServiceUuid = '4c652180-1201-4fdf-b853-36bac4cced0a'; IntUuid = 'fa67024c-78d6-11ea-bc55-0242ac130003'; LedUuid = 'fa66fffe-78d6-11ea-bc55-0242ac130003'; TemperatureUuid = '14f3ff86-95b8-11ea-bb37-0242ac130002'; HumidityUuid = '14f4038c-95b8-11ea-bb37-0242ac130002'; UserDescUuid = '0x2901'; DeviceName = 'Custom_ESP32';

Setting up BLE I used anonymous methods when retrieving my device, service and characteristics. Anonymous methods are useful in this scenario as they allow us to chain up all our procedures needed during setup. This makes getting a device up and running much more efficient.
An instance of TBluetooth called bt is created. We must now add our intended services to the bt.FilterService list. This is a built-in security feature within Web Bluetooth. Failing to do so will deny us access to them. The name of the device we want to access specifically can also be configured with bt.DeviceName.
The rest of the code below connects us to the GATT server, creates our device, creates the service we will be using and finally creates our characteristics. The characteristics we created receive ‘On’ methods, these will be used to control our device - more on this later.

procedure TForm7.WebButton1Click(Sender: TObject); begin bt := TBluetooth.Create; bt.FilterService.Add(MyServiceUuid); bt.DeviceName := 'Custom_ESP32'; bt.GetDevice( procedure begin bt.Device.Connect( procedure begin bt.Device.GetService(myServiceUuid, procedure(AService: TBluetoothService) begin AService.GetCharacteristic(IntUuid, procedure(AChar: TBluetoothCharacteristic) begin IntCharacteristic := AChar; end); AService.GetCharacteristic(LedUuid, procedure(AChar: TBluetoothCharacteristic) begin LedCharacteristic := AChar; LedCharacteristic.Read( procedure(AValue: integer) begin ReadLedCharacteristic(Self, AValue); end); end); AService.GetCharacteristic(TemperatureUuid, procedure(AChar: TBluetoothCharacteristic) begin TempCharacteristic := AChar; TempCharacteristic.OnNotifyDouble:= NotifyTempCharacteristic; end); AService.GetCharacteristic(HumidityUuid, procedure(AChar: TBluetoothCharacteristic) begin HumCharacteristic := AChar; HumCharacteristic.OnNotifyDouble:= NotifyHumCharacteristic; end); EnableButtons; end); end); end); end; Note: Humidity has been shortened to Hum and Temperature to temp to fit the format.

Pairing the Device Once these steps have been taken, pressing the “Start BLE” button will display a pop up with a list of connectable devices. In our case the Custom_ESP32 has shown up. Selecting it and clicking pair will form a connection with our device.

Reading data We can read the data stored within our intCharacteristic by using the Read method. When we press the ReadValue button, intCharacteristic.Read is called. This retrieves the integer stored within our intCharacteristic as AValue. We can then cast AValue to a string and display this in our WebLabel on the form.

procedure TForm7.WebButton4Click(Sender: TObject); begin intCharacteristic.Read( procedure(AValue: integer) begin WebLabelReadValue.Caption:= IntToStr(AValue); end); end;
Writing data We can change the data stored within our characteristics by writing to them. This is as simple as calling a Write method on our characteristic. In this case I am using WriteInt to write an integer value into IntCharcateristic.

procedure TForm7.WebButton5Click(Sender: TObject); begin IntCharacteristic.WriteInt(StrtoInt(WebEdit1.Text)); ShowMessage('Wrote value of ' + WebEdit1.Text + ' to device'); end;

Expanding this concept to real world devices Reading and writing numbers to and from a device probably isn’t the most exciting thing you’ve ever witnessed. But doing so provides us with the functionality we need to interact with real world devices. The write function we just applied to our IntCharacteristic can also be used for turning on and off a LED.

  • LedCharacteristic.WriteInt(1); to turn on the LED.
  • LedCharacteristic.WriteInt(0); to turn off the LED.

But don’t think of the LED as just a LED, this could be lights, heating, a fan, a water pump or any other device you wish to control, once again, straight from any device with browser capability.

Realtime sensor readings Since the TemperatureCharacteristic and HumidityCharacteristic were given the notify option when I programmed them on the ESP-32, we can now use the notify methods in our Webcore project. First, we bind one of the ‘OnNotify’ procedures to the characteristic we wish to use. In this case, we will be retrieving a double, so we opt for the OnNotifyDouble method.

AService.GetCharacteristic(TemperatureUuid, procedure(AChar: TBluetoothCharacteristic) begin TemperatureChar:= AChar; TempCharacteristic.OnNotifyDouble:= NotifyTempCharacteristic; end);
By adding the StartNotify method to the temperature characteristic we can start the readings. TemperatureCharacteristic.StartNotify;
To stop the readings, we just need to call the StopNotify method, it really is that simple! TemperatureCharacteristic.StopNotify;

Summary This concludes our overview of the TMS WEB Core v1.4 new Bluetooth support.

  • Code once, run everywhere for wireless interaction with real world devices in the browser.
  • Effortless implementation, allowing you to turn on/off devices, change their settings or enable communication between different devices using the Read, Write and Notify methods.
  • Quick and easy development of Web Bluetooth projects, all within the Object Pascal language.

Included in the TMS WEB Core v1.4 distribution is a demo that uses the Texas Instruments Sensor tag.

This way you can easily start experimenting with Bluetooth from web applications without getting your hands dirty assembling an ESP32 with I2C sensors on a breadboard and dabbling in C code (for now) with Arduino to program the ESP32.

TMS WEB Core v1.4 for Delphi/Lazarus is available standalone now and is also part of TMS ALL-ACCESS. The Bluetooth support will also be available in the upcoming TMS WEB Core for Visual Studio Code!
Do you have already one or more TMS product licenses and are interested to get on board for TMS ALL-ACCESS, our no-nonsense formula for access to our full current and future toolset, priority support and access to betas, contact our sales: for a best possible upgrade offer.

Article written by Luc Levez

Why Is SQLite Coded In C

1 day 5 hours ago
Old, but still an interesting read: [WayBack] Why Is SQLite Coded In C and [WayBack] Appropriate Uses For SQLite. TL;DR: SQLite – mainly competing with fopen has few dependencies and uses C in a boring way. I think that’s good. Via: [WayBack] Why Is SQLite Coded In C – ThisIsWhyICode – Google+ –jeroen

Shell Extensions (.NET)

1 day 11 hours ago
Over time it seems that Shell Extensions (.NET) [WayBack] have become possible. In the past this was recommended against because Shell Extensions can be loaded by any process having a file dialog open, even if these did not expect .NET framework(s) to be hosted in-process. It looks like that restriction has been alleviated with .NET 4.x where […]

Some links on hooking anonymous methods to Delphi events

1 day 23 hours ago
On my reading list are these: [WayBack] Is there a way in Delphi to assign an anonymous method to a button event? – Stack Overflow [WayBack] delphi – VCL events with anonymous methods – what do you think about this implementation? – Stack Overflow [WayBack] delphi – TProc<TObject> to TNotifyEvent – Stack Overflow [WayBack] delphi […]

TMS WEB Core v1.4 Ravenna released

2 days 4 hours ago

We are thrilled to announce the release of TMS WEB Core v1.4! The new version not only introduces a record number of improvements, amazing new features but also supports the latest and greatest Delphi 10.4 Sydney. The new version v1.4 is available free for all active registered TMS WEB Core or TMS ALL-ACCESS users

TMS WEB Core v1.4 represents multiple months of hard work from our team, some parts have been over 6 months in development.
Here is a summary of what you can discover in the TMS WEB Core v1.4:

  • New TWebBluetooth Non-visual component offering seamless access to Bluetooth devices from web applications
  • New TWebImageSlider UI control to make presenting catalogs with pictures fast and easy
  • New TWebContinuousScroll UI control to bring fast loading and load-as-you-scroll lists
  • New TWebElementActionList to facilitate binding Pascal code to HTML template elements
  • New TWebRadServerClientDataset offering a codeless interface to data from Embarcadero RAD server
  • New TWebDreamFactoryClientDataSet making consuming data via DreamFactory REST APIs a breeze
  • New TWebFaunaDBClientDataSet letting you bind cloud data in web client applications code-less
  • New Electron 8 support allowing you to take advantage of the newest stable Electron framework for building cross platform desktop applications
  • New TWebSignatureCapture allowing to capture touch based signature writing as image in web applications
  • New TWebPayPal migrated to the newest PayPal JavaScript SDK
  • New demos for TWebListControl, TWebElementActionList, HTML templates, TWebBluetooth, PDF streaming, TWebSignatureCapture, various DB backends
  • New latest stable release pas2js 1.4.24 compiler & RTL support added
  • New TBitmap load from URL, file, cache with anonymous method added
  • New TWebHttpRequest anonymous methods for handling asynchronous requests in a different way
Other than these new features added, literally hundreds of smaller improvements have been done and several issues fixed. A lot of the smaller improvements are a direct result of the simultaneous work done to make the TMS WEB Core framework work as seamless as possible with the live designer in the upcoming TMS WEB Core for Visual Studio Code.

The documentation was expanded and totals over 440 pages now. The number of included demos is now just under 100 (not counting the Lazarus converted demos also included). So, there is a lot to learn about this newest TMS WEB Core release. In the coming days and weeks we will highlight many of the new capabilities in more details. For today we have a video of what we personally consider one of the nicest new components: TWebElementActionList. This is not to be confused with a Delphi action list but offers an easy way to write Object Pascal code that interacts with HTML elements of all kinds in HTML templates used together with the TMS WEB Core web client application.

TMS WEB Core v1.4: TWebElementActionList

In addition, to learn all about TMS WEB Core, following additional resources are available:

  • Online training courses for TMS WEB Core
  • Book: TMS WEB Core: Web Application Development with Delphi

    TMS WEB Core v1.4 for Delphi/Lazarus is available standalone now and is also part of TMS ALL-ACCESS. Do you have already one or more TMS product licenses and are interested to get on board for TMS ALL-ACCESS, our no-nonsense formula for access to our full current and future toolset, priority support and access to betas, contact our sales: for a best possible upgrade offer.

  • Cursor Movement in bash: either echo escape sequences or use tput

    2 days 11 hours ago
    I read [WayBack] Cursor Movement earlier than [WayBack] Colours and Cursor Movement With tput and [WayBack] The Floating Clock Prompt. So in one of my scripts I’ve now used an escape sequence, but I might change it to tput in a future version: ## Move one line up, then write finished scripts: echo -e "\033[1A$finished\r" I would probably have started with […]

    Are there any static code analysis tools for Delphi/Pascal? – Stack Overflow

    2 days 23 hours ago
    Still interesting question: [WayBack] Are there any static code analysis tools for Delphi/Pascal? – Stack Overflow The basic problem here is that there is no formal language definition for the Delphi or Object Pascal language. [WayBack] GitHub – RomanYankovsky/DelphiAST: Abstract syntax tree builder for Delphi (which also supports FreePascal and Lazarus) comes closest, and is […]

    SysUtils.pas Why parameters of these anonymous not const? TProc = …

    3 days 5 hours ago
    At [WayBack] SysUtils.pas Why parameters of these anonymous not const? TProc = reference to procedure (Arg1: T1; Arg2: T2); TProc = reference … – Jacek Laskowski – Google+, Hallvard Vasbotn made this nail on the head comment: It could have been solved if the const’ness had been seen as a implementation detail by the compiler […]

    How do I delete a Bash function? – Stack Overflow

    3 days 11 hours ago
    I hardly do this, so I tend to forget that unset -f functionname deletes a function and unset variablename or unset -v variablename deletes a variable. From: I have done this:bash $ z() { echo ‘hello world’; }How do I get rid of it? Source: [WayBack] How do I delete a Bash function? – Stack Overflow Reference: [WayBack] unset Man […]

    GitHub – kzahel/web-server-chrome: An HTTP Web Server for Chrome (chrome.sockets API)

    3 days 23 hours ago
    Cool: [WayBack] GitHub – kzahel/web-server-chrome: An HTTP Web Server for Chrome (chrome.sockets API) This allows you to develop HTTP applications that live in Chrome: [Archive.is1/Archive.is2] Web Server for Chrome – Chrome Web Store: A Web Server for Chrome, serves web pages from a local folder over the network, using HTTP. Runs offline. Of course you could […]

    Logitech remotes for presenting

    3 days 23 hours ago
    A few links on Logitech remotes for presenters. I like how the spotlight can highlight portions of the screen, but I wish it had the LCD display timer of the R800 and R700. The big problem of the Spotlight seems to be the stability of the Logitech software, both on Windows and on MacOS. The […]

    Force NTP Time Update on Linux | KrazyWorks

    4 days 5 hours ago
    A while ago, I had a problem that one of my Raspberry Pi machines hadn’t been turned on for a while, so after a reboot the clock was way off. This resulted in errors like the below: SEC_ERROR_OCSP_FUTURE_RESPONSE errors indicating the TLS certificates being not yet valid (and numerous other TLS certificate issues). The /etc/ntp.conf was […]