more ReprTree refactoring

- <Vec Char>  ~>  <Vec ReprTree>  packing/unpacking
- remove Arc<RwLock<>> around EditTree
- gentle ListEditor update
- reactivate PosInt example
This commit is contained in:
Michael Sippel 2025-01-02 12:35:13 +01:00
parent 26186b3375
commit 47dd4ce747
Signed by: senvas
GPG key ID: F96CF119C34B64A6
20 changed files with 564 additions and 508 deletions
examples/tty-05-dictionary/src

View file

@ -181,6 +181,8 @@ async fn main() {
}
let mut edittree = list_editor.into_node(SingletonBuffer::new(0).get_port());
nested_tty::editors::list::PTYListController::for_node(&mut edittree, None, None);
edittree.goto(TreeCursor{
leaf_mode: nested::editors::list::ListCursorMode::Insert,
tree_addr: vec![0, 0]
@ -244,8 +246,8 @@ async fn main() {
}
show_edit_tree( &ctx, &mut comp, &symbol_rt.descend(Context::parse(&ctx, "Instruction ~ Mnemonic ~ <Seq~List Char>")).unwrap(), 1 );
show_edit_tree( &ctx, &mut comp, &symbol_rt.descend(Context::parse(&ctx, "Instruction ~ Opcode ~ ~ <PosInt 10 BigEndian>")).unwrap(), 3 );
show_edit_tree( &ctx, &mut comp, &symbol_rt.descend(Context::parse(&ctx, "Instruction ~ Opcode ~ ~ <PosInt 16 BigEndian>")).unwrap(), 5 );
//show_edit_tree( &ctx, &mut comp, &symbol_rt.descend(Context::parse(&ctx, "Instruction ~ Opcode ~ ~ <PosInt 10 BigEndian>")).unwrap(), 3 );
//show_edit_tree( &ctx, &mut comp, &symbol_rt.descend(Context::parse(&ctx, "Instruction ~ Opcode ~ ~ <PosInt 16 BigEndian>")).unwrap(), 5 );
}
/* write the changes in the view of `term_port` to the terminal