Added some rofi stuff for easier & quicker interaction

Looking actually pretty okay!
This commit is contained in:
2025-08-19 23:01:32 +01:00
parent 3f4af21a93
commit bcf68c8332
3 changed files with 44 additions and 0 deletions

View File

@@ -78,6 +78,22 @@ pub fn update_db_with_file(file: PathBuf) -> bool {
true
}
// unsure if this should be in this file...
impl fmt::Display for DbCard {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match &self.mana_cost {
Some(mc) => writeln!(f, "{}\t{}", self.name, mc)?,
None => writeln!(f, "{}", self.name)?,
}
match &self.oracle_text {
Some(ot) => writeln!(f, "{}", ot)?,
None => (),
}
Ok(())
}
}
#[derive(Debug)]
pub struct DbCard {
pub name: String,