After three months of development the launch of the new version was presented of the cross-platform toolkit for creating a graphical user interface GTK 4.2.0 in which about 1268 were implemented individual changes from 54 developers and a total of 73950 lines added and 60717 removed.
The new branch of GTK 4 is being developed as part of a new development process which tries to provide application developers with a stable and compatible API for several years, which can be used without fear of having to redo applications every six months due to API changes in the next branch of GTK.
What's new in GTK 4.2.0?
This new version of GTK 4.2.0 mainly fixes bugs and introduces API improvements based on feedback from developers who have ported their programs to GTK4.
In addition, that some of the most notable improvements in GTK 4.2 include the NGL renderer, a new OpenGL rendering engine that is enabled by default on Linux, Windows, and macOS. The NGL renderer provides noticeably better performance with improvements in frames per second, as well as power and CPU usage. To revert to the previous rendering engine, start the application with the environment variable GSK_RENDERER = gl.
This release is the result of the initial round of feedback from application developers migrating their projects to GTK4, so it mainly consists of bug fixes and API improvements, but we also added new features, such as a new GL renderer; various improvements to the way the toolkit handles composition and dead key sequences; create system enhancements for compiling GTK on Windows and macOS; and a completely new API reference, generated from the same introspection data that is also consumed by language bindings.
Also highlighted in the announcement of this new version of GTK 4.2.0 that sand implemented the ability to use GTK as a subproject in the Meson build system, allowing you to compile GTK and all its dependencies as part of your own application's build environment, as well as get all compilation artifacts for delivery along with your application using the selected toolkit.
The API documentation has been redesigned, pFor whose training the new gi-docgen generator is used, which produces a more convenient presentation of information, including buttons to add code samples to the clipboard, a visual representation of the hierarchy of ancestors and interfaces of each class, a list of inherited properties , signals and methods of the class.
Moreover the interface supports client-side search and automatically adapts to different screen sizes, In addition, a new documentation site, docs.gtk.org, has been launched, which also offers complementary guides on GObject, Pango, and GdkPixbuf introspection.
The performance of various components was also optimized, from the GLSL shaders involved in rendering to objects for people with disabilities.
Of the other changes that stand out of this new version:
- Modified the handling of composition sequences and mute keys that change the appearance of the next input character.
- Improved support for compiling GTK for Windows and macOS using native toolkits for these platforms.
- Sub-pixel text positioning has been implemented when using new versions of the Cairo library.
- Provided responsive interface design for emoji selection.
- Improved support for the Wayland protocol extension for entry control.
- Improved scrolling performance in the text view widget.
- Improved rendering of shadows in popover widgets.
- Pango and GdkPixbuf also switched to gi-docgen
- Performance improvements across the board
Finally, if you are interested in knowing more about this new released version, you can consult the details In the following link.