Implement setter for filter_method property of viewer

This commit is contained in:
gigas002 2024-03-11 21:02:15 +09:00
parent af8ab81403
commit 0c93c3c5fc

View file

@ -40,6 +40,12 @@ impl<Handle> Viewer<Handle> {
}
}
/// Sets the [`image::FilterMethod`] of the [`Viewer`].
pub fn filter_method(mut self, filter_method: image::FilterMethod) -> Self {
self.filter_method = filter_method;
self
}
/// Sets the padding of the [`Viewer`].
pub fn padding(mut self, padding: impl Into<Pixels>) -> Self {
self.padding = padding.into().0;