summaryrefslogtreecommitdiffstats
path: root/native
diff options
context:
space:
mode:
authorLibravatar Soham Chowdhury <chow.soham@gmail.com>2020-03-01 06:44:06 +0530
committerLibravatar Soham Chowdhury <chow.soham@gmail.com>2020-03-01 06:44:06 +0530
commiteb7e3250d3da495f46480360c99540a8f643d2e6 (patch)
tree28492d24ff7390df6828a774aa6275bd29ededb2 /native
parent18410154289fa3262403bb2c9de3dd741fd7dda2 (diff)
downloadiced-eb7e3250d3da495f46480360c99540a8f643d2e6.tar.gz
iced-eb7e3250d3da495f46480360c99540a8f643d2e6.tar.bz2
iced-eb7e3250d3da495f46480360c99540a8f643d2e6.zip
Note BGRA requirement in Handle::from_pixels docs
Diffstat (limited to 'native')
-rw-r--r--native/src/widget/image.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/native/src/widget/image.rs b/native/src/widget/image.rs
index a1743744..fbe38bfc 100644
--- a/native/src/widget/image.rs
+++ b/native/src/widget/image.rs
@@ -125,7 +125,9 @@ impl Handle {
Self::from_data(Data::Path(path.into()))
}
- /// Creates an image [`Handle`] containing the image pixels directly.
+ /// Creates an image [`Handle`] containing the image pixels directly. This
+ /// function expects the input data to be provided as a `Vec<u8>` of BGRA
+ /// pixels.
///
/// This is useful if you have already decoded your image.
///