(font: Texture, width: usize, height: usize)
| 19 | |
| 20 | impl Console { |
| 21 | pub fn new(font: Texture, width: usize, height: usize) -> Console { |
| 22 | let cell_size = (font.width() / 16) as f32; |
| 23 | |
| 24 | Console { |
| 25 | font, |
| 26 | cells: vec![ |
| 27 | ConsoleCell { |
| 28 | glyph: ' ', |
| 29 | foreground: Color::rgb(1.0, 1.0, 1.0), |
| 30 | background: Color::rgb(0.0, 0.0, 0.0), |
| 31 | }; |
| 32 | width * height |
| 33 | ], |
| 34 | cell_size, |
| 35 | width, |
| 36 | height, |
| 37 | } |
| 38 | } |
| 39 | |
| 40 | pub fn clear(&mut self) { |
| 41 | self.cells = vec![ |
nothing calls this directly
no outgoing calls
no test coverage detected