From 73115fd0f327efd210309163d8c333f9a9a4a698 Mon Sep 17 00:00:00 2001 From: Chris Date: Thu, 18 Oct 2018 22:19:36 +0200 Subject: [PATCH] tes --- examples/embedded_linux_epd4in2/src/main.rs | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/examples/embedded_linux_epd4in2/src/main.rs b/examples/embedded_linux_epd4in2/src/main.rs index 158d141..6ce118e 100644 --- a/examples/embedded_linux_epd4in2/src/main.rs +++ b/examples/embedded_linux_epd4in2/src/main.rs @@ -15,7 +15,7 @@ use eink_waveshare_rs::{ extern crate embedded_graphics; use embedded_graphics::coord::Coord; -use embedded_graphics::fonts::Font6x8; +use embedded_graphics::fonts::{Font6x8, Font12x16}; use embedded_graphics::prelude::*; use embedded_graphics::primitives::{Circle, Line}; use embedded_graphics::Drawing; @@ -289,7 +289,7 @@ fn run() -> Result<(), std::io::Error> { .into_iter(), ); display.draw( - Font6x8::render_str("It's working!") + Font6x8::render_str("It's working-WoB!") // Using Style here .with_style(Style { fill_color: Some(Color::Black), @@ -300,6 +300,18 @@ fn run() -> Result<(), std::io::Error> { .into_iter(), ); + display.draw( + Font6x8::render_str("It's working-BoW!") + // Using Style here + .with_style(Style { + fill_color: Some(Color::White), + stroke_color: Some(Color::Black), + stroke_width: 0u8, // Has no effect on fonts + }) + .translate(Coord::new(50, 50)) + .into_iter(), + ); + let mut i = 0;