refactors and new dct binary

This commit is contained in:
2024-05-17 13:43:18 +02:00
parent 8c3112f9f2
commit 1b2536f1e0
7 changed files with 196 additions and 36 deletions
+2 -2
View File
@@ -8,7 +8,6 @@ use std::path::Path;
use std::fmt;
use log::{info, debug, error};
use bktree::*;
use viuer::{Config, print};
#[derive(Debug)]
pub enum SaveError {
@@ -66,6 +65,7 @@ impl DescriptorStore {
/// Inserts a single value into the store
pub fn insert(&mut self, key: u64, value: String) {
self.map.insert(key, value);
self.bktree.insert(key);
}
/// Calculates all descriptions with a given descriptor
@@ -112,7 +112,7 @@ impl DescriptorStore {
match name {
Some(n) => {
println!("{element:b}: {n} (distance: {distance})");
if x+16 >= term_width {
if x+16 >= term_width {
x = 0;
y += 8;
}