Fix comments typo

This commit is contained in:
Candifloss 2025-12-08 16:21:29 +05:30
parent eea3c757c0
commit 199c60b874

View File

@ -50,9 +50,9 @@ impl XContext {
/// Capture a rectangular part of the screen. /// Capture a rectangular part of the screen.
/// ///
/// `ctxt` connection + screen info\ /// `ctxt` - connection + screen info\
/// `x_coord,y_coord` top-left corner of the rectangle\ /// `x_coord,y_coord` - top-left corner of the rectangle\
/// `width,height` size of the rectangle /// `width,height` - size of the rectangle
/// ///
/// Returns: a `Vec<u8>` containing RGBA pixel data. /// Returns: a `Vec<u8>` containing RGBA pixel data.
pub fn capture_rect( pub fn capture_rect(
@ -104,10 +104,10 @@ pub fn capture_rect(
/// Save an RGBA pixel buffer as a PNG file. /// Save an RGBA pixel buffer as a PNG file.
/// ///
/// `path` where to write the file\ /// `path` - where to write the file\
/// `width` image width in pixels\ /// `width` - image width in pixels\
/// `height` image height in pixels\ /// `height` - image height in pixels\
/// `rgba` pixel data in RGBA format /// `rgba` - pixel data in RGBA format
pub fn save_png(path: &str, width: u16, height: u16, rgba: &[u8]) -> anyhow::Result<()> { pub fn save_png(path: &str, width: u16, height: u16, rgba: &[u8]) -> anyhow::Result<()> {
let file = File::create(path)?; let file = File::create(path)?;