(target: &mut D, offset: Point, color: Rgb565)
| 13 | pub const LOGO_OFFSET_Y: i32 = 100; |
| 14 | |
| 15 | pub fn clear_text<D>(target: &mut D, offset: Point, color: Rgb565) -> Result<(), D::Error> |
| 16 | where |
| 17 | D: DrawTarget<Color = Rgb565>, |
| 18 | { |
| 19 | const TEXT_H: i32 = 20; |
| 20 | Rectangle::new( |
| 21 | Point::new(0, 30) + offset - Point::new(0, 15), |
| 22 | Size::new(130, TEXT_H as u32), |
| 23 | ) |
| 24 | .into_styled(PrimitiveStyle::with_fill(color)) |
| 25 | .draw(target)?; |
| 26 | |
| 27 | Ok(()) |
| 28 | } |
| 29 | |
| 30 | pub fn draw_text<D>(target: &mut D, target_text: &str, offset: Point) -> Result<(), D::Error> |
| 31 | where |