From bfd27fa3fa94817ddb6ae3e2debbba177e2a389d Mon Sep 17 00:00:00 2001 From: Michael Sippel Date: Fri, 1 Oct 2021 16:29:18 +0200 Subject: [PATCH] update dependencies --- nested/src/terminal/ansi_parser.rs | 14 +++++++++----- rust-toolchain | 2 +- sdf_editor/src/main.rs | 8 ++++---- 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/nested/src/terminal/ansi_parser.rs b/nested/src/terminal/ansi_parser.rs index 4ae37ef..a5cf2fc 100644 --- a/nested/src/terminal/ansi_parser.rs +++ b/nested/src/terminal/ansi_parser.rs @@ -46,7 +46,7 @@ pub fn read_ansi_from(ansi_reader: &mut R, port: InnerViewPort< loop { match ansi_reader.read(&mut buf) { - Ok(0) => break, + //Ok(0) => break, Ok(n) => { for byte in &buf[..n] { statemachine.advance(&mut performer, *byte); @@ -119,22 +119,24 @@ impl Perform for PerfAtom { } fn hook(&mut self, params: &Params, intermediates: &[u8], ignore: bool, c: char) { + /* eprintln!( "[hook] params={:?}, intermediates={:?}, ignore={:?}, char={:?}", params, intermediates, ignore, c ); + */ } fn put(&mut self, byte: u8) { - eprintln!("[put] {:02x}", byte); + //eprintln!("[put] {:02x}", byte); } fn unhook(&mut self) { - eprintln!("[unhook]"); + //eprintln!("[unhook]"); } fn osc_dispatch(&mut self, params: &[&[u8]], bell_terminated: bool) { - eprintln!("[osc_dispatch] params={:?} bell_terminated={}", params, bell_terminated); + //eprintln!("[osc_dispatch] params={:?} bell_terminated={}", params, bell_terminated); } fn csi_dispatch(&mut self, params: &Params, intermediates: &[u8], ignore: bool, c: char) { @@ -284,10 +286,12 @@ impl Perform for PerfAtom { } fn esc_dispatch(&mut self, intermediates: &[u8], ignore: bool, byte: u8) { + /* eprintln!( "[esc_dispatch] intermediates={:?}, ignore={:?}, byte={:02x}", - intermediates, ignore, byte + intermediates, ignore, byte ); +*/ } } diff --git a/rust-toolchain b/rust-toolchain index d4e1e1f..5841773 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -5,5 +5,5 @@ # to the user in the error, instead of "error: invalid channel name '[toolchain]'". [toolchain] -channel = "nightly-2021-08-27" +channel = "nightly-2021-09-29" components = ["rust-src", "rustc-dev", "llvm-tools-preview"] diff --git a/sdf_editor/src/main.rs b/sdf_editor/src/main.rs index 4cd1609..16a2be2 100644 --- a/sdf_editor/src/main.rs +++ b/sdf_editor/src/main.rs @@ -24,7 +24,7 @@ use{ }, nako::{ stream::{SecondaryStream2d, PrimaryStream2d}, - glam::{Vec2, Vec3, UVec2}, + glam::{Vec2, Vec3, UVec2, IVec2}, operations::{ planar::primitives2d::Box2d, volumetric::{Color, Union, Round}, @@ -126,7 +126,7 @@ impl SdfTerm { id.into(), LayerInfo { extent: UVec2::new(1 + self.font_height / 2, self.font_height), - location: UVec2::new(pt.x as u32 * self.font_height / 2, pt.y as u32 * self.font_height) + location: IVec2::new(pt.x as i32 * self.font_height as i32 / 2, pt.y as i32 * self.font_height as i32) }); self.bg_layers.insert(*pt, (false, id)); @@ -145,7 +145,7 @@ impl SdfTerm { id.into(), LayerInfo { extent: UVec2::new(1 + self.font_height / 2, self.font_height), - location: UVec2::new(pt.x as u32 * self.font_height / 2, pt.y as u32 * self.font_height) + location: IVec2::new(pt.x as i32 * self.font_height as i32 / 2, pt.y as i32 * self.font_height as i32) }); self.fg_layers.insert(*pt, (false, id)); @@ -273,7 +273,7 @@ async fn main() { }); renderer.lock().unwrap().set_layer_info(color_layer_id.into(), LayerInfo{ extent: UVec2::new(600, 600), - location: UVec2::new(200,100) + location: IVec2::new(200,100) }); event_loop.run(move |event, _target, control_flow|{