New release
It’s now time for a new Gtk-rs release! As usual, a lot of improvements in a lot of places but subclasses in particular got a lot of updates. Time to dive in on some improvements. Enjoy!
Update of minimum supported versions §
The minimum supported version of the C library of various crates was updated to the versions available in Ubuntu 18.04:
- GLib/GIO requires at least version 2.56 now and supports API up to version 2.74
- gdk-pixbuf requires at least version 2.36.8 and supports API up to version 2.42
- Pango requires at least version 1.40 and supports API up to version 1.52
- GTK3 requires at least version 3.22.30 and supports API up to version 3.24.30
- GTK4 requires at least version 4.0.0 and supports API up to version 4.8
The minimum supported Rust version by all crates was updated to version 1.63.
More async support §
A couple of futures helper functions were added with this release that should make futures usage easier in GTK applications.
- Timeouts:
glib::future_with_timeout(Duration::from_millis(20), fut)
will resolve to the result offut
if it takes less than 20ms or otherwise to an error - Cancellation:
gio::CancellableFuture::new(fut, cancellable)
will resolve to the future unless thecancellable
is cancelled before that
GTK 4 §
Along with plenty of bugfixes and small improvements, the 0.5 release of gtk4-rs brings a couple of useful features
gsk::Transform
Most of the C functions return NULL
which represents an identity transformation. The Rust API nowadays returns an identity
transformation instead of None
#[gtk::CompositeTemplate]
runtime validation
If used with #[template(string=...)]
or #[template(file=...)]
and the xml_validation
feature is enabled, the XML content will be validated to ensure the child widgets that the code is trying to retrieve exists.
#[gtk::test]
As GTK is single-threaded, using it in your tests is problematic as you can’t initialize GTK multiple times. The new attribute macro helps with that as it runs the tests in a thread pool instead of in parallel.
Details at https://gtk-rs.org/gtk4-rs/stable/latest/docs/gtk4_macros/attr.test.html
WidgetClassSubclassExt::install_action_async
In a lot of use cases, people used to do
klass.install_action("some_group.action", None, |widget, _, _| {
let ctx = glib::MainContext::default();
ctx.spawn_local(clone!(@weak widget => async move {
/// call some async function
widget.async_function().await;
}));
})
The new helper function allows you to write the code above like
klass.install_action_async("some_group.action", None, |widget, _, _| async move {
/// call some async function
widget.async_function().await;
})
Which helps avoiding the usage of the clone
macro in some cases.
- GTK 4.8 API additions which can be enabled with
v4_8
- Various fixes for the gdk-wayland & wayland-rs integration requiring wayland-client v0.30
- Plenty of new examples:
- Gif Paintable for rendering Gifs
- ColumnView for displaying data in a table-like format
- Confetti animation
- Rotation / Squeezer example
glib::Object
now has a more convenient object builder §
In addition to dynamic objects construction, or e.g. when implementing new GObject subclasses, via glib::Object::new()
and related API, there is also a more convenient object builder available.
let obj = glib::Object::builder::<MyObject>()
.property("prop1", 123)
.property("prop2", "test")
.property("prop3", false)
.build();
This allows for slightly more idiomatic Rust code.
GIO objects completion closure doesn’t need to be Send
anymore §
Asynchronous operations on GIO objects previously required the completion closure to be Send
. This is not required anymore as the objects themselves are not Send
-able either and the operation will be completed on the current thread via the thread’s own main context. This should make usage of the asynchronous operations easier from GTK applications, where all UI objects are not Send
.
As a result of this, also futures provided by GIO objects based on these asynchronous operations do not implement the Send
trait anymore, which was wrong to begin with and caused panics at runtime in any situation where the future was actually used on different threads.
Added support for #[derive(glib::Variant)]
for enums §
Starting with the previous release it was possible to derive the required trait implementations for (de)serializing Rust structs from/to glib::Variant
s. With this release, support for enums is also added with different options for how the enum is going to be represented. Both C-style enums as well as enums with values in the variants are supported.
#[derive(Debug, PartialEq, Eq, glib::Variant)]
enum Foo {
MyA,
MyB(i32),
MyC { some_int: u32, some_string: String }
}
let v = Foo::MyC { some_int: 1, some_string: String::from("bar") };
let var = v.to_variant();
assert_eq!(var.child_value(0).str(), Some("my-c"));
assert_eq!(var.get::<Foo>(), Some(v));
No need to implement Send
and Sync
for subclasses anymore §
In the past it was necessary to manually implement the Send
and Sync
traits via an unsafe impl
block for the object types of GObject subclasses defined in Rust.
glib::wrapper! {
pub struct MyObject(ObjectSubclass<imp::MyObject>);
}
unsafe impl Send for MyObject {}
unsafe impl Sync for MyObject {}
This is not necessary anymore and happens automatically if the implementation struct implements both traits. Like this it is also harder to accidentally implement the traits manually although the requirements of them are not fulfilled.
Simpler subclassing for virtual methods §
Previously when creating a GObject subclass, all virtual methods passed the implementation struct and the object itself as arguments, e.g.
pub trait ObjectImpl {
fn constructed(&self, obj: &Self::Type);
}
This caused a lot of confusion and was also redundant. Instead, starting with this release only the implementation struct is passed by reference, e.g.
pub trait ObjectImpl {
fn constructed(&self);
}
In most contexts the object itself was not actually needed, so this also simplifies the code. For the cases when the object is needed, it can be retrieved via the obj()
method on the implementation struct
impl ObjectImpl for MyObject {
fn constructed(&self) {
self.parent_constructed();
let obj = self.obj();
obj.do_something();
}
}
In a similar way it is also possible to retrieve the implementation struct from the instance via the imp()
method. Both methods are cheap and only involve some pointer arithmetic.
Additionally, to make it easy to pass around the implementation struct into e.g. closures, there is now also a reference counted wrapper around it available (ObjectImplRef
) that can be retrieved via imp.to_owned()
or imp.ref_counted()
, and a weak reference variant that can be retrieved via imp.downgrade()
. Both are working in combination with the glib::clone!
macro, too.
impl ObjectImpl for MyObject {
fn constructed(&self) {
self.parent_constructed();
// for a strong reference
self.button.connect_clicked(glib::clone!(@to-owned self as imp => move |button| {
imp.do_something();
}));
// for a weak reference
self.button.connect_clicked(glib::clone!(@weak self as imp => move |button| {
imp.do_something();
}));
}
}
Simpler subclassing for properties §
When creating properties for GObject subclasses they need to be declared beforehand via a glib::ParamSpec
. Previously these had simple new()
functions with lots of parameters. These still exist but it’s usually more convenient to use the builder pattern to construct them, especially as most of the parameters have sensible defaults.
// Now
let pspec = glib::ParamSpecUInt::builder("name")
.maximum(1000)
.construct()
.build();
// Previously
let pspec = glib::ParamSpecUInt::new("name", None, None, 0, 1000, 0, glib::ParamFlags::READWRITE | glib::ParamFlags::CONSTRUCT);
In a similar spirit, signal definitions are available via a builder. This was available in the previous already but usage was simplified, for example by defaulting to no signal arguments and ()
signal return type.
// Now
let signal = glib::subclass::Signal::builder("closed").build();
// Before
let signal = glib::subclass::Signal::builder("closed", &[], glib::Type::UNIT).build();
Removing Result<>
wrapping in some functions returned values §
glib::Object::new()
returned a Result
in previous versions. However, the only way how this could potentially fail was via a programming error: properties that don’t exist were tried to be passed, or values of the wrong type were set for a property. By returning a Result
, the impression was given that this can also fail in a normal way that is supposed to be handled by the caller.
As this is not the case, glib::Object::new()
always panics if the arguments passed to it are invalid and no longer returns a Result
.
In the same spirit, object.try_set_property()
, object.try_property()
, object.try_emit()
and object.try_connect()
do not exist any longer and only the panicking variants are left as the only way they could fail was if invalid arguments are provided.
Transform functions for property bindings are now supported §
Object property bindings allow for transform functions to be defined, which convert the property value to something else for the other object whenever it changes. Previously these were defined on the generic glib::Value
type, but as the types are generally fixed and known in advance it is now possible to define them directly with the correct types.
source
.bind_property("name", &target, "name")
.flags(crate::BindingFlags::SYNC_CREATE)
.transform_to(|_binding, value: &str| Some(format!("{} World", value)))
.transform_from(|_binding, value: &str| Some(format!("{} World", value)))
.build();
If the types don’t match then this is considered a programming error and will panic at runtime.
The old way of defining transform functions via glib::Value
is still available via new functions
source
.bind_property("name", &target, "name")
.flags(crate::BindingFlags::SYNC_CREATE)
.transform_to_with_values(|_binding, value| {
let value = value.get::<&str>().unwrap();
Some(format!("{} World", value).to_value())
})
.transform_from_with_values(|_binding, value| {
let value = value.get::<&str>().unwrap();
Some(format!("{} World", value).to_value())
})
.build();
Construct SimpleAction
with ActionEntryBuilder
§
It is now possible to use gio::ActionEntryBuilder
to construct a gio::SimpleAction
, the advantage of using that is the gio::ActionMap
type is passed as a first parameter to the activate
callback and so avoids the usage of the clone!
macro.
Before:
let action = gio::SimpleAction::new("some_action", None);
action.connect_activate(clone!(@weak some_obj => move |_, _| {
// Do something
});
actions_group.add_action(&action);
After
let action = gio::ActionEntry::builder("some_action").activate(move |some_obj: &SomeType, _, _| {
// Do something
}).build();
// It is safe to `unwrap` as we don't pass any parameter type that requires validation
actions_group.add_action_entries([action]).unwrap();
Changes §
For the interested ones, here is the list of the merged pull requests:
- cairo: Implement
Send+Sync
forImageSurfaceData
andImageSurfaceDataOwned
- cairo: Allow converting
ImageSurfaceDataOwned
back into anImageSurface
- pango: add setters for Rectangle
- glib: use Result from std for logging macros
- gio: move task docs on the structs
- glib: Generate bindings for markup_escape_text
- glib: implement To/FromVariant for OS strings and paths
- glib-macros: Remove redundant allocations
- pangocairo: don’t re-export types on prelude
- glib-macros: Smaller subclass macro
- glib: Add an object builder
- glib: Add more documentation on how to replace g_signal_connect_object
- glib: Provide
ThreadGuard
andthread\_id()
as public API - Don’t require
Send
closures for GIO-style async functions - gio: Don’t implement
Send
onGioFuture
anymore - gio: add Initable::with_type
- gio: Use correct callback type for
File::copy\_async()
- glib: Never pass
NULL
tog\_log\_structured\_standard()
- gio: Use correct callback type for
File::copy\_async()
- impl
StaticType
and{From,To}Value
forgpointer
- dynamic type function variants for Variants and Values
- gtask: fix memory leak when calling g_task_return_value
- Handle empty slices correctly
- cairo: Allow writing arbitrary
Surface
s asPNG
s - glib: add trait
StaticTypeExt
with methodtype\_ensure
- Add missing pango attrs
- Remove remaining public fields
- glib: Add an
Object
specific value type checker - glib: Fix handling of closures that provide a return value pointer that is initialized to
G_TYPE_INVALID
- Fix cairo FFI types name
- glib: Don’t use
from\_glib\_full()
for the individual items of an array for boxed inline types - cairo: fix Glyph::index type
- translate: Pre-allocate Rust hashmap at correct size
- glib-macros: Pass a pointer for watched objects into closure macro
- Variant::from_dict_entry
- Smaller spec numeric definition
- pango: Add LayoutLine.runs()
- pango: Add missing getter for GlyphItemIter.
- define a corresponding
Builder
for eachParamSpec
- glib: impl AsRef<Variant> for Variant
- glib-macros: Add support for enums to glib::Variant
- use Self where possible in wrapper macros
- remove problematic phantom in glib_shared_wrapper
- glib: Use “%s” instead of replacing % in log functions
- impl
ToValue
,FromValue
for char - glib: Correctly cast log messages to C char types
- glib: Automatically implement
Send + Sync
on object subclasses if their implementation struct implements those traits - Use glib 2.71 for minimum v2_72 pkg-config versions
- glib: Add function to wrap a future with a timeout
- glib: Allow using other error types and value type checkers for optional values
- glib: Only auto-impl
Send+Sync
for subclasses if the parent type does - glib: Use the correct value type checker for optional types
- Add new classes from glib 2.72
- More gio::Cancellable methods
- glib: Allow borrowing a
ParamSpec
reference from aValue
- glib: Allow borrowing a
ParamSpec
reference from aValue
- Structured Logging
- gio: add AsyncInitable
- Use Send+Sync for more Boxed types
- glib: Disable log_structured doc test before v2_50
- glib: VariantTy tuple type iterator
- impl FromStr for VariantType
- glib: print and parse for Variant
- glib-macros: Port clone failure tests to trybuild2
- glib: Fix build with
v2_72
and require 2.72.0 now - glib: Generate docs for BindingGroupBuilder
- More Cairo GValue fixes
- Implement ValueTypeOptional for BoxedInline and cairo types
- glib: implement ValueTypeOptional for Variant, VariantType, BoxedValue
- Add rustfmt.toml to allow some editors to auto-format the code on save
- Update minimum supported GLib version to 2.56
- glib: Fix
mkdtemp()
andmkdtemp\_full()
- glib/variant: add some more safe wrappers
- glib: Remove ending NUL when converting Variant to OsString.
- error: add
matches
method - Fix Windows build
- glib: Remove SendUnique and SendUniqueCell
- glib: Add new
ObjectImplRef
andObjectImplWeakRef
types - gdk_pixbuf: opt-in for gi-docgen
- remove extend_from_slice position subtraction, add test
- gdk_pixbuf: Improve
Pixbuf::pixels
documentation - glib: Remove redundant null-checks before
g\_free
- Remove more redundant null checks
- glib: Don’t serialize 0 value flags as variants
- glib: Add bindings for GSignalGroup
- gio: Add local variant for connect_cancelled
- glib: WatchedObject improvements
- glib-macros: Remove boxed_nullable and shared_boxed_nullable attribute for glib::Boxed
- glib: Add getter for
glib::Error
domain quark - Set properties improvements
- impl fallible IntoIterator for ListModel,ListStore
- cairo+gio+glib: Add safety docs for low hanging fruits
- glib: Add WeakRefNotify (v2)
- Move
gio::compile\_resources
to its own crate - Add IntoGlibPtr trait
- glib: Use
ptr::NonNull
forVariantType
pointer storage - cairo: Add missing User Fonts
- glib/gio: Implement
FusedFuture
/FusedStream
in some places - Port Dockerfile to fedora rawhide and use system deps from git
- Implement
FusedIterator
for various custom iterators - cairo: Fix user font callbacks.
- Add some more tests for various custom
Iterator
impls - Don’t build gdk-pixbuf tests in the docker image
- gio: add AsyncInitable subclassing support
- gio: Use guard objects for
Application::hold()
andmark\_busy()
- cairo: Add missing
cairo\_surface\_get\_content
- cairo: Add new for TextCluster/TextExtents and add setter for TextCluster
- cairo: Add setter for Glyph.
- cairo: add some 1.18 features
- cairo: Use freetype-sys instead of freetype.
- Fix GBindingGroup bindings
- Add more tests for Binding/BindingGroup
- glib: add missing emit_by_name methods
- Use RefCell::take() when possible
- SocketAddressEnumerator:
next
return value should be nullable - translate.rs: free the container memory also when the container is empty
- gstring: implement AsRef<Path> for GString and GStr
- ProcessLauncher:
close
method should be available on unix only - Remove is_windows_utf8
- Fix off-by-one in GString::from (and missing null terminator in a test)
- gio: Update serial_test dependency to 0.8
- Add is_empty for List and SList
- glib: Fix
ParamSpec::name()
return value lifetime - glib: fix ParamSpec with null blurb and nick
- pango: Mark parameters to
extents\_to\_pixels()
as mutable - add set_glyph to GlyphInfo
- fix glyph string methods that don’t need to be &mut
- glib: add doc alias for g_type_class_ref
- glib: bind iconv functions
- cairo: Update to freetype 0.31
- glib: Add flag setters to ParamSpec builders
- gio: Manually implement ActionEntry
- as_ptr() and as_mut_ptr() accessors are safe
- cairo: Don’t leak user data if setting it failed
- glib: Simplify SignalBuilder constructor
- glib: Allow passing
SignalType
s and plain arrays to the signal builder for the types - glib: Variant wrapper types for handles, object paths and signatures
- Add
#\[must\_use\]
to guard objects - glib/object: add track_caller annotation in a few places
- glib: Remove unneeded and wrong
upcast()
fromBoxedAnyObject
docs example - Don’t checkout submodules by default
- glib: Various paramspec builder API improvements
- glib/gio: Replace various type parameters with
impl trait
- glib/types: use rustc-hash for HashMap
- glib/subclass/types: use BTreeMap instead of HashMap
- gio: make Task::cancellable return Option
- Implement Borrow on object types
- glib: Reduce number of allocations when writing non-structured logs via the GlibLogger
- gio:
CancellableFuture
ergonomic for cancelling tasks - glib: Don’t allow passing a construct(-only) property twice during object construction
- glib: Panic in Object::new() and related functions and add try_new()
- Implement more FFI translation traits for shared types
- cairo: Use AsRef<T> for custom subclassing types
- glib/BindingBuilder: add concrete type based transform setters
- pango: Manually implement GlyphItemIter and AttrIterator with lifetimes
- Pango odds and ends
- Change *Impl trait methods to only take &self and not Self::Type in addition
- glib: Improve assertion message when number of arguments in
glib::closure!
are not matching - glib: Add
IntoGlibPtr
as supertrait forObjectType
/IsA
and remove redundant'static
requirement fromIsA
- glib: Some
IsA
trait polishing - glib: Implement
Send+Sync
forBorrowedObject
/ObjectImplRef
/ObjectImplWeakRef
- Expose some fields of GDBusNodeInfo
- pangocairo: Trust upstream nullable annotations for return values
- Add information about pangocairo::FontMap generation and fix some methods
- pango: Trust upstream nullable annotations for return values
- drop problematic include & add missing symlinks
- Drop cursed include and add missing links
- Fix
gdkwayland
pkg name in README.md snippets - gtk/{Text,Tree}Iter: derive Debug
- Replace
Foo::from\_instance(foo)
withfoo.imp()
- gdk-wayland: re-export ffi
- gtk: Use
u32
as underlying type for thestock-size
property ofCellRendererPixbuf
- gdk: Add constructor for
gdk::Geometry
- gtk: Set gtk-rs as initialized after the original
GtkApplication::startup
has returned - Don’t require
Send
closures for GIO-style async functions - Make various newly added 3.24 API conditionally available
- gtk: Add
Atk.Role
tomanual
to generate some more bindings - Handle empty slices correctly
- gtk3-macros: Add doc links to glib/gtk items
- gdk: Fix per phantom field removal
- Add rustfmt.toml to allow some editors to auto-format the code on save
- subclass support for GtkEntry
- Fix link to docs of gdkwayland crate
- examples: Migrate to
glib-build-tools
- Add binding for gtk_file_chooser_add_choice()
- Add binding for Gtk.FileFilterInfo
- gtk: Add an
unsafe-assume-initialized
feature - gdk: Fix binding for
gdk\_event\_get\_state
- Don’t checkout submodules by default
- Update for glib::Object::new() API changes
- Change *Impl trait methods to only take &self and not Self::Type in addition
- Add example of a Rotation Bin widget
- gtk4/{Text,Tree}Iter: derive Debug
- gtk: fix TreeView subclassing support
- book: Remove all mentions of meson and flatpak
- Replace
Foo::from\_instance(foo)
withfoo.imp()
- gtk: Set gtk-rs as initialized after the original
GtkApplication::startup
has returned - book: Use closure to connect signal
- gdk: implement conversions for Rectangle
- make use of impl T wherever possible
- gtk: mark some of TextIter methods as nullable
- book: Introduce template callbacks
- gtk: mark Snapshot::to_(node|paintable) as nullable
- Don’t require Send closures for GIO-style async functions
- Remove unnecessary
Send
bounds from GIO-style async functions - Trust return value nullability again for gsk
- Fix library name for epoxy on Windows.
- image: build on PR as well
- Handle empty slices correctly
- Disable broken builders/default implementations
- gdk: Fix compilation after
cairo::Rectangle
API changes - gtk: Pass an object pointer into rust builder closures instead of weak ref
- gtk4-macros: Use relative doc links for glib/gtk items
- gtk4: CompositeTemplate set_template fixes
- gtk4: Add runtime type checks for template children
- gtk4: Add convenience traits for binding template callbacks to classes
- gdk: Fix post removal of PhantomData for BoxedInline
- Add CODEOWNERS file
- gtk4-macros: Improve error reporting, add failure tests
- gtk4-macros: Allow async template callbacks
- More checks for composite template children
- Add is method to fundamental types
- gtk: Add ParamSpecExpressionBuilder
- examples: Add new widget that squeezes its child
- gtk4-macros: Fix compile error on rust 1.56
- gdk: Implement Value traits for Key
- gdk4-wayland: Use wayland_client::Display instead of a display proxy
- book: Bring todo closer to libadwaita example
- book: Add check in todo whether entry is empty
- Add rustfmt.toml to allow some editors to auto-format the code on save
- book: Rename (TodoRow, TodoObject) -> (TaskRow, TaskObject)
- gtk4-macros: Fix re-entrancy panic in async template callback test
- book: Link snippets to code examples on github
- book: Replace git version of the book with link to stable
- book: Refactor
current\_tasks
- book: Rename
list\_view
- book: Add nix to linux installation guide
- book: fix links
- fix vendoring by removing include from gdk4/Cargo.toml
- book: Improve
TaskData
methods - Removed extra bracket in 5.1
- [🐛 Fix] Fix app variable name in build_ui function
- Implement FusedIterator for custom iterators
- Migrate state storing back to json
- book: Use
extend\_from\_slice
instead ofsplice
- gtk: Add NativeDialog::run_async
- Rename app-id
- book: Use xtask to install data
- book: Fix application window comment
- book: Update xtask
- book: Rename variables in preparation of upcoming chapter
- gtk4: Use
Key
inaccelerator\_
function bindings - gdk4-x11: Fix broken initialized test to be no-op; fix argument for
X11Display::set\_program\_class
- gtk4: Mark
gtk::GestureClick::unpaired-release
sequence parameter as nullable - book: Fixes link in list widgets chapter
- Book: Improved grammar and readability
- book: Stop using hyphens in app ids
- book: Update appid in book
- book: Add Todo App 6 using Adwaita
- book: Use param spec builders
- book: Rename
current\_tasks
totasks
- dialog: Use present instead of show in run manuals
- book: Add Todo5
- book: Add chapter about the Adwaita library
- gtk4: Add an
unsafe-assume-initialized
feature - book: Add Todo5
- book: Remove AdwWindowTitle
- book: Add tooltips to main menu
- Update per glib::SignalBuilder changes
- book: Replace usage of gtk preludes with adwaita ones
- TextNode::new doesn’t need to take glyphstring as mut
- book: Remove unused
menu\_button
reference - gtk: Implement ParamSpecBuilderExt for ParamSpecExpression
- gtk: Make xml validation optional
- gtk: Add a WidgetClassSubclassExt::install_action_async
- book: Address Alexander’s review comments
- book: Remove frame style from TodoTaskRow
- examples: Use ParamSpec builder pattern
- gtk: Simplify types passed to ClosureExpression
- book: Fix wrong references
- Add gtk::ColumnView “data grid” example
- Add confetti_snapshot_animation example
- Fixes #1114 by passing a null ptr when
colors
is empty - book: Remove
remove-current-collection
action - book: Second libadwaita section
- Remove fold threshold policy
- Update for glib::Object::new() API changes
- book: use
cargo add
when adding dependencies - book: Fix and complete recent
cargo add
changes - gsk: Add a ColorStopBuilder
- gtk: Make use of the new move configuration
- Update for new trait impls in gtk-rs-core
- gsk: Handle nullable Transform
- examples: Add a GIF paintable
- subclass: Drop Self::Type usage
- gdk4-wayland: Update wayland crate to 0.30
- examples: Update to glium 0.32
- gtk/gdk: mark Snapshot as not final and implement necessary traits
- gtk: Manually implement FileChooser::set_current_folder
- Fix dox features
All this was possible thanks to the gtk-rs/gir project as well:
- sys: run ABI tests only under linux
- Don’t require
Send
closures for GIO-style async functions - Mention Default impls for objects with Builders
- docs: Handle gi-docgen namespaces when looking for types to link
- Parse and codegen
doc-deprecated
for enum members - book: Pass output path to gir in console examples
- add GitHub urls to book
- Add “default_value” parameter
- If an async function is marked unsafe, mark unsafe also the _future variant
- codegen: Use GString::as_str instead of
Option<GString>::as_deref
- docs: Never use ExtManual trait with GObject
- suppress insertion of assertion for result of throw function to return void
- trampoline_from_glib: Replace broken deref with as_ref
- Fix error message for constant parsing
- Add generate_doc
- Remove
SendUnique
code generation - Fix finding the deps for the sys crate
- Fix UB and clippy::let-and-return in function out variables handling
- docs: don’t generate implements links for fundamental types
- add non unix fallback for creating PathBuf from
Vec<u8>
- Remove is_windows_utf8 function
- Fix
BoolError
import when being used from glib directly - Remove leading ‘>’ from tutorial
- book: Unbreak syntax highlighting on
console
codeblocks, address concerns consistently - analysis: Call extra to_glib functions in array len transformation
- don’t assume GObject.Object is always available
- codegen/sys/tests: Don’t trim whitespace on C constant output
- analysis: Don’t generate duplicate getter/notify/setter from parent type
- analysis: Fix logic when analysing a function
- config: Add a move configuration for functions parameters
- Update for
Object::new()
panicking instead of returning aResult
- Remove parsing and storage of unused and deprecated allow-none attribute
- codegen/sys: Properly generate dox features for external libraries
Thanks to all of our contributors for their (awesome!) work on this release:
- @A6GibKm
- @AaronErhardt
- @abergmeier
- @alatiera
- @andy128k
- @anlumo
- @arcnmx
- @BiagioFesta
- @bilelmoussaoui
- @bvinc
- @cgwalters
- @cmdcolin
- @Davidoc26
- @ebanDev
- @euclio
- @fengalin
- @filnet
- @FineFindus
- @gdesmott
- @GuillaumeGomez
- @gwutz
- @heftig
- @Hofer-Julian
- @ids1024
- @Jaakkonen
- @Jedsek
- @jf2048
- @jim4067
- @JoelMon
- @jsparber
- @kelnos
- @khrj
- @kianmeng
- @lucab
- @lucastarche
- @MarijnS95
- @mbiggio
- @pbor
- @pentamassiv
- @philn
- @ranfdev
- @RealKC
- @rodrigorc
- @saethlin
- @sdroege
- @SeaDve
- @songww
- @takaswie
- @Ungedummt
- @zecakeh
- @zhangyuannie