Skip to content

Commit 1fc8995

Browse files
committed
Set defaults for each font family type
1 parent 49d08a5 commit 1fc8995

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

cli/src/convert.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ pub fn convert_(
1717
let mut fontdb = fontdb::Database::new();
1818
fontdb.load_system_fonts();
1919

20+
fontdb.set_serif_family("Times New Roman");
21+
fontdb.set_sans_serif_family("Arial");
22+
fontdb.set_cursive_family("Comic Sans MS");
23+
fontdb.set_fantasy_family("Impact");
24+
fontdb.set_monospace_family("Courier New");
25+
2026
// Convert the file.
2127
let name = Path::new(input.file_name().ok_or("Input path does not point to a file")?);
2228
let output = output.unwrap_or_else(|| name.with_extension("pdf"));

0 commit comments

Comments
 (0)