Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 16 additions & 16 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion gdk-pixbuf/src/auto/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion gdk-pixbuf/sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
9 changes: 5 additions & 4 deletions gio/src/auto/desktop_app_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,8 @@ impl DesktopAppInfo {
} else {
None
};
let pid_callback_data: Option<&mut dyn (FnMut(&DesktopAppInfo, glib::Pid))> = pid_callback;
let mut pid_callback_data: Option<&mut dyn (FnMut(&DesktopAppInfo, glib::Pid))> =
pid_callback;
unsafe extern "C" fn pid_callback_func(
appinfo: *mut ffi::GDesktopAppInfo,
pid: glib::ffi::GPid,
Expand All @@ -239,8 +240,8 @@ impl DesktopAppInfo {
None
};
let super_callback0: Box_<Option<Box_<dyn FnOnce() + 'static>>> = user_setup_data;
let super_callback1: &Option<&mut dyn (FnMut(&DesktopAppInfo, glib::Pid))> =
&pid_callback_data;
let super_callback1: &mut Option<&mut dyn (FnMut(&DesktopAppInfo, glib::Pid))> =
&mut pid_callback_data;
unsafe {
let mut error = std::ptr::null_mut();
let is_ok = ffi::g_desktop_app_info_launch_uris_as_manager(
Expand All @@ -251,7 +252,7 @@ impl DesktopAppInfo {
user_setup,
Box_::into_raw(super_callback0) as *mut _,
pid_callback,
super_callback1 as *const _ as *mut _,
super_callback1 as *mut _ as *mut _,
&mut error,
);
debug_assert_eq!(is_ok == glib::ffi::GFALSE, !error.is_null());
Expand Down
12 changes: 6 additions & 6 deletions gio/src/auto/file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ pub trait FileExt: IsA<File> + sealed::Sealed + 'static {
cancellable: Option<&impl IsA<Cancellable>>,
progress_callback: Option<&mut dyn (FnMut(i64, i64))>,
) -> Result<(), glib::Error> {
let progress_callback_data: Option<&mut dyn (FnMut(i64, i64))> = progress_callback;
let mut progress_callback_data: Option<&mut dyn (FnMut(i64, i64))> = progress_callback;
unsafe extern "C" fn progress_callback_func(
current_num_bytes: i64,
total_num_bytes: i64,
Expand All @@ -247,7 +247,7 @@ pub trait FileExt: IsA<File> + sealed::Sealed + 'static {
} else {
None
};
let super_callback0: &Option<&mut dyn (FnMut(i64, i64))> = &progress_callback_data;
let super_callback0: &mut Option<&mut dyn (FnMut(i64, i64))> = &mut progress_callback_data;
unsafe {
let mut error = std::ptr::null_mut();
let is_ok = ffi::g_file_copy(
Expand All @@ -256,7 +256,7 @@ pub trait FileExt: IsA<File> + sealed::Sealed + 'static {
flags.into_glib(),
cancellable.map(|p| p.as_ref()).to_glib_none().0,
progress_callback,
super_callback0 as *const _ as *mut _,
super_callback0 as *mut _ as *mut _,
&mut error,
);
debug_assert_eq!(is_ok == glib::ffi::GFALSE, !error.is_null());
Expand Down Expand Up @@ -1257,7 +1257,7 @@ pub trait FileExt: IsA<File> + sealed::Sealed + 'static {
cancellable: Option<&impl IsA<Cancellable>>,
progress_callback: Option<&mut dyn (FnMut(i64, i64))>,
) -> Result<(), glib::Error> {
let progress_callback_data: Option<&mut dyn (FnMut(i64, i64))> = progress_callback;
let mut progress_callback_data: Option<&mut dyn (FnMut(i64, i64))> = progress_callback;
unsafe extern "C" fn progress_callback_func(
current_num_bytes: i64,
total_num_bytes: i64,
Expand All @@ -1275,7 +1275,7 @@ pub trait FileExt: IsA<File> + sealed::Sealed + 'static {
} else {
None
};
let super_callback0: &Option<&mut dyn (FnMut(i64, i64))> = &progress_callback_data;
let super_callback0: &mut Option<&mut dyn (FnMut(i64, i64))> = &mut progress_callback_data;
unsafe {
let mut error = std::ptr::null_mut();
let is_ok = ffi::g_file_move(
Expand All @@ -1284,7 +1284,7 @@ pub trait FileExt: IsA<File> + sealed::Sealed + 'static {
flags.into_glib(),
cancellable.map(|p| p.as_ref()).to_glib_none().0,
progress_callback,
super_callback0 as *const _ as *mut _,
super_callback0 as *mut _ as *mut _,
&mut error,
);
debug_assert_eq!(is_ok == glib::ffi::GFALSE, !error.is_null());
Expand Down
2 changes: 1 addition & 1 deletion gio/src/auto/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion gio/sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion glib/gobject-sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion glib/src/auto/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
6 changes: 3 additions & 3 deletions glib/src/source.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ impl FromGlib<u32> for SourceId {
}

// rustdoc-stripper-ignore-next
/// Process identificator
/// Process identifier
#[derive(Copy, Clone, Debug, Eq, PartialEq)]
#[doc(alias = "GPid")]
pub struct Pid(pub ffi::GPid);
Expand Down Expand Up @@ -1092,9 +1092,9 @@ where
ffi::g_source_set_callback(
source,
Some(transmute::<
*const (),
*mut (),
unsafe extern "C" fn(ffi::gpointer) -> ffi::gboolean,
>(trampoline_child_watch::<F> as *const ())),
>(trampoline_child_watch::<F> as *mut ())),
into_raw_child_watch(func),
Some(destroy_closure_child_watch::<F>),
);
Expand Down
2 changes: 1 addition & 1 deletion glib/sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion graphene/src/auto/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion graphene/sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
3 changes: 3 additions & 0 deletions pango/Gir.toml
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,9 @@ status = "generate"
[[object.function]]
name = "x_to_index"
manual = true
[[object.function]]
name = "get_x_ranges"
manual = true

[[object]]
name = "Pango.Matrix"
Expand Down
6 changes: 3 additions & 3 deletions pango/src/auto/attr_list.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ impl AttrList {
#[doc(alias = "pango_attr_list_filter")]
#[must_use]
pub fn filter<P: FnMut(&Attribute) -> bool>(&self, func: P) -> Option<AttrList> {
let func_data: P = func;
let mut func_data: P = func;
unsafe extern "C" fn func_func<P: FnMut(&Attribute) -> bool>(
attribute: *mut ffi::PangoAttribute,
user_data: glib::ffi::gpointer,
Expand All @@ -41,12 +41,12 @@ impl AttrList {
(*callback)(&attribute).into_glib()
}
let func = Some(func_func::<P> as _);
let super_callback0: &P = &func_data;
let super_callback0: &mut P = &mut func_data;
unsafe {
from_glib_full(ffi::pango_attr_list_filter(
self.to_glib_none().0,
func,
super_callback0 as *const _ as *mut _,
super_callback0 as *mut _ as *mut _,
))
}
}
Expand Down
6 changes: 3 additions & 3 deletions pango/src/auto/fontset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ mod sealed {
pub trait FontsetExt: IsA<Fontset> + sealed::Sealed + 'static {
#[doc(alias = "pango_fontset_foreach")]
fn foreach<P: FnMut(&Fontset, &Font) -> bool>(&self, func: P) {
let func_data: P = func;
let mut func_data: P = func;
unsafe extern "C" fn func_func<P: FnMut(&Fontset, &Font) -> bool>(
fontset: *mut ffi::PangoFontset,
font: *mut ffi::PangoFont,
Expand All @@ -38,12 +38,12 @@ pub trait FontsetExt: IsA<Fontset> + sealed::Sealed + 'static {
(*callback)(&fontset, &font).into_glib()
}
let func = Some(func_func::<P> as _);
let super_callback0: &P = &func_data;
let super_callback0: &mut P = &mut func_data;
unsafe {
ffi::pango_fontset_foreach(
self.as_ref().to_glib_none().0,
func,
super_callback0 as *const _ as *mut _,
super_callback0 as *mut _ as *mut _,
);
}
}
Expand Down
17 changes: 0 additions & 17 deletions pango/src/auto/layout_line.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,23 +90,6 @@ impl LayoutLine {
unsafe { ffi::pango_layout_line_get_start_index(self.to_glib_none().0) }
}

#[doc(alias = "pango_layout_line_get_x_ranges")]
#[doc(alias = "get_x_ranges")]
pub fn x_ranges(&self, start_index: i32, end_index: i32) -> Vec<i32> {
unsafe {
let mut ranges = std::ptr::null_mut();
let mut n_ranges = std::mem::MaybeUninit::uninit();
ffi::pango_layout_line_get_x_ranges(
self.to_glib_none().0,
start_index,
end_index,
&mut ranges,
n_ranges.as_mut_ptr(),
);
FromGlibContainer::from_glib_full_num(ranges, n_ranges.assume_init() as _)
}
}

#[doc(alias = "pango_layout_line_index_to_x")]
pub fn index_to_x(&self, index_: i32, trailing: bool) -> i32 {
unsafe {
Expand Down
2 changes: 1 addition & 1 deletion pango/src/auto/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
17 changes: 17 additions & 0 deletions pango/src/layout.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,4 +90,21 @@ impl LayoutLine {
is_inside,
}
}

#[doc(alias = "pango_layout_line_get_x_ranges")]
#[doc(alias = "get_x_ranges")]
pub fn x_ranges(&self, start_index: i32, end_index: i32) -> Vec<i32> {
unsafe {
let mut ranges = std::ptr::null_mut();
let mut n_ranges = std::mem::MaybeUninit::uninit();
ffi::pango_layout_line_get_x_ranges(
self.to_glib_none().0,
start_index,
end_index,
&mut ranges,
n_ranges.as_mut_ptr(),
);
FromGlibContainer::from_glib_full_num(ranges, 2 * n_ranges.assume_init() as usize)
}
}
}
2 changes: 1 addition & 1 deletion pango/sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion pangocairo/src/auto/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
2 changes: 1 addition & 1 deletion pangocairo/sys/versions.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Generated by gir (https://github.com/gtk-rs/gir @ c954dbdc9ac0)
Generated by gir (https://github.com/gtk-rs/gir @ e9ef1f366af2)
from gir-files (https://github.com/gtk-rs/gir-files @ 1dc2560a9ae8)
Loading