Skip to content

Commit

Permalink
fonts: fix other platforms and tests
Browse files Browse the repository at this point in the history
Ungh, shouldn't push before I'm awake :-/

refs: #648
  • Loading branch information
wez committed Apr 5, 2021
1 parent d7c7c27 commit a5bb5be
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion wezterm-font/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ impl FontConfigInner {
}

for attr in &attributes {
if !attr.is_fallback && !loaded.contains(attr) {
if !attr.is_synthetic && !attr.is_fallback && !loaded.contains(attr) {
let styled_extra = if attr.bold || attr.italic {
". A bold or italic variant of the font was requested; \
TrueType and OpenType fonts don't have an automatic way to \
Expand Down
1 change: 1 addition & 0 deletions wezterm-font/src/locator/core_text.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ fn build_fallback_list_impl() -> anyhow::Result<Vec<FontDataHandle>> {
bold: false,
italic: false,
is_fallback: true,
is_synthetic: true,
};
if let Ok(descriptor) = descriptor_from_attr(&symbols) {
if let Some(handle) = handle_from_descriptor(&descriptor) {
Expand Down
1 change: 1 addition & 0 deletions wezterm-font/src/locator/gdi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@ impl FontLocator for GdiFontLocator {
italic: false,
family: font.family_name(),
is_fallback: true,
is_synthetic: true,
};

if !resolved.contains(&attr) {
Expand Down
1 change: 1 addition & 0 deletions wezterm-font/src/shaper/harfbuzz.rs
Original file line number Diff line number Diff line change
Expand Up @@ -469,6 +469,7 @@ mod test {
family: "JetBrains Mono".into(),
bold: false,
is_fallback: false,
is_synthetic: false,
italic: false,
})
.unwrap()
Expand Down

0 comments on commit a5bb5be

Please # to comment.