pub struct ColorSinglePixel { /* private fields */ }Expand description
Represents a singular pixel implementing the Pixel trait.
Trait Implementations§
Source§impl Clone for ColorSinglePixel
impl Clone for ColorSinglePixel
Source§fn clone(&self) -> ColorSinglePixel
fn clone(&self) -> ColorSinglePixel
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl From<ColorSinglePixel> for DataCell
impl From<ColorSinglePixel> for DataCell
Source§fn from(val: ColorSinglePixel) -> Self
fn from(val: ColorSinglePixel) -> Self
Converts to this type from the input type.
Source§impl Pixel for ColorSinglePixel
impl Pixel for ColorSinglePixel
type U = TerminalColor
fn pixels(&self) -> &[Self::U; 1]
fn pixels_mut(&mut self) -> &mut [Self::U; 1]
fn new(pixels: [Self::U; 1]) -> Self
Source§fn subpixel(&self, x: usize, y: usize) -> Result<Self::U, String>
fn subpixel(&self, x: usize, y: usize) -> Result<Self::U, String>
Returns the value of the block at the specified coordinates. Read more
Source§fn set_subpixel(
&mut self,
x: usize,
y: usize,
value: Self::U,
) -> Result<(), String>
fn set_subpixel( &mut self, x: usize, y: usize, value: Self::U, ) -> Result<(), String>
Returns the value of the block at the specified coordinates. Read more
Source§fn build(args: &[Self::U]) -> Result<Self, String>
fn build(args: &[Self::U]) -> Result<Self, String>
Builds a block of pixels from a slice of pixels. Read more
fn subpixel_static<const X: usize, const Y: usize>(&self) -> Self::U
fn set_subpixel_static<const X: usize, const Y: usize>( &mut self, value: Self::U, )
impl Copy for ColorSinglePixel
Auto Trait Implementations§
impl Freeze for ColorSinglePixel
impl RefUnwindSafe for ColorSinglePixel
impl Send for ColorSinglePixel
impl Sync for ColorSinglePixel
impl Unpin for ColorSinglePixel
impl UnwindSafe for ColorSinglePixel
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more