“We said from the beginning, we want this to be supported by several programming languages because in 10 or 20 years when Rust will not be good anymore, we want to be able to swap that for the user so that they can write in their language,” Goffart told The New Stack. “Rust [is] not really a great language to write the application logic itself, as you do not often need so much performance for the application logic.”
Although the Slint creators were experienced with C++, they thought Rust had better tooling and felt more modern than C++, while still having the potential of C++. It also had the added benefit of being safer, Goffart added.
“We wanted something that can be really fast, because when you run an embedded [app], every cycle of the CPU counts — and so we cannot afford a garbage collector,” Goffart said.
Slint compiles the application to run natively on embedded devices, or on Linux, Mac, and Windows desktops.
How Slint Works and Why It’s Embedded
Slint is implemented in Rust, but the API for it is written in a domain specific language called the Slint language. Then there is an API to connect to the supported language libraries.
SixtyFPS GmbH opted to go after the embedded space because there’s less competition than in the web UI space. It’s arguably more lucrative as well, they believe. The tool is designed to work on the “really low end” of embedded devices, which tend to have low compute power, Goffart explained.
“There are different levels of embedded — there is a really cheap microprocessor that can run only compiled code and doesn’t have much memory, then there is the high-end embedded, which is sometimes even more powerful [than]… a personal computer,” he said. “Since we scale, we can also support more and more computers that are either not perfect at all, or that even have hardware accelerators — so, anything that can display a user interface.”
Why the Desktop?
There is a trend right now to use the browser as the basis to create web pages that run like desktop applications as well, Goffart said. For Slint, the team wanted to enable a native-looking user interface on the desktop.
“We want to offer a way to make a user interface that is not in the browser, so it’s native and it looks like a real application for a computer and not a website,” Goffart said. “We think that native styling is important so that all the controls look like the operating system’s controls.”
Right now, the tool team is focused on what developers need to create a UI.
“If you make the display panel a control panel for some industrial machine that bends metal in some factory, you’re not going to hire an agency to create a beautiful design for it,” said Simon Hausmann, also a SixtyFPS GmbH co-founder. “You’re going to task yourself or [your] developers to implement the functionality as easily as possible, as quickly as possible. It should be usable, of course, and it should look decent, but you’re not going to focus on the design aspects so much.”
In the future, that may change — their plan is to make Slint into a tool that designers could use alongside developers.
“We want to not only target software developers but also the designers; so that the designers and software developers can more easily work together, with the focus on products that are either embedded devices [or] applications that run on laptops, for example,” Goffart said.
Slint is dual licensed, which means developers can license it under the GPL version 3, an open source license, or under a proprietary license that allows using Slint in products where the owner does not wish to make their source code available. The proprietary license is available by purchasing a copy or taking part in Slint’s ambassador program, where developers exchange a free proprietary license for branding the app as built using Slint. Competitors include free products and QT, where Hausmann previously worked.