Fix the doc issue described in #80 (#99)

This commit is contained in:
Jay Oster 2020-07-19 01:56:52 -07:00 committed by GitHub
parent b5b55c43f7
commit e3b10ab83b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -405,7 +405,7 @@ impl Pixels {
/// assert_eq!(pixel_pos, (0, 20)); /// assert_eq!(pixel_pos, (0, 20));
/// ///
/// let pixel_pos = pixels.clamp_pixel_pos((11, 3000)); /// let pixel_pos = pixels.clamp_pixel_pos((11, 3000));
/// assert_eq!(pixel_pos, (11, 240)); /// assert_eq!(pixel_pos, (11, 239));
/// # Ok::<(), pixels::Error>(()) /// # Ok::<(), pixels::Error>(())
/// ``` /// ```
pub fn clamp_pixel_pos(&self, pos: (isize, isize)) -> (usize, usize) { pub fn clamp_pixel_pos(&self, pos: (isize, isize)) -> (usize, usize) {