add suggestive fallback messages on unavailable fonts

as per https://github.com/jwilm/alacritty/issues/39
This commit is contained in:
Tom Crayford authored and Joe Wilm committed 2017-01-12 21:21:14 -08:00
1 parent f85cc353a6
commit 67aba7f4e4
2 files changed
+4 -2

No files matched your search

+2 -1
View File
@@ -111,7 +111,8 @@ impl ::std::fmt::Display for Error {
write!(f, "Glyph not found for char {:?}", c)
},
Error::MissingFont(ref desc) => {
write!(f, "Couldn't find a font with {}", desc)
write!(f, "Couldn't find a font with {}\
\n\tPlease check the font config in your alacritty.yml.", desc)
},
Error::FontNotLoaded => {
f.write_str("Tried to use a font that hasn't been loaded")
+2 -1
View File
@@ -252,7 +252,8 @@ impl ::std::fmt::Display for Error {
err.fmt(f)
},
Error::MissingFont(ref desc) => {
write!(f, "Couldn't find a font with {}", desc)
write!(f, "Couldn't find a font with {}\
\n\tPlease check the font config in your alacritty.yml.", desc)
},
Error::FontNotLoaded => {
f.write_str("Tried to use a font that hasn't been loaded")