Skip to content

Commit

Permalink
Update font
Browse files Browse the repository at this point in the history
  • Loading branch information
leighmacdonald committed Mar 7, 2023
1 parent d48e933 commit 21f8a4a
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 18 deletions.
4 changes: 0 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@ fmt:
gofmt -s -w .

fonts:
fyne bundle --pkg ui -o ./internal/ui/embed_font.go ./internal/ui/resources/JetBrainsMono/fonts/ttf/JetBrainsMono-Regular.ttf
fyne bundle --pkg ui -a -o ./internal/ui/embed_font.go ./internal/ui/resources/JetBrainsMono/fonts/ttf/JetBrainsMono-Bold.ttf
fyne bundle --pkg ui -a -o ./internal/ui/embed_font.go ./internal/ui/resources/JetBrainsMono/fonts/ttf/JetBrainsMono-Italic.ttf
fyne bundle --pkg ui -a -o ./internal/ui/embed_font.go ./internal/ui/resources/JetBrainsMono/fonts/ttf/JetBrainsMono-BoldItalic.ttf
fyne bundle --pkg ui -o ./internal/ui/embed_img.go ./internal/ui/resources/default_avatar.jpg
fyne bundle --pkg ui -a -o ./internal/ui/embed_img.go ./internal/ui/resources/Icon.png
fyne bundle --pkg ui -a -o ./internal/ui/embed_img.go ./internal/ui/resources/tf2.png
Expand Down
10 changes: 10 additions & 0 deletions internal/ui/embed_font.go

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion internal/ui/resources/JetBrainsMono
Submodule JetBrainsMono deleted from 68685b
14 changes: 1 addition & 13 deletions internal/ui/theme.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,7 @@ import (
type bdTheme struct{}

func (bdTheme) Font(s fyne.TextStyle) fyne.Resource {
if s.Monospace {
return resourceJetBrainsMonoRegularTtf
}
if s.Bold {
if s.Italic {
return resourceJetBrainsMonoBoldItalicTtf
}
return resourceJetBrainsMonoBoldTtf
}
if s.Italic {
return resourceJetBrainsMonoItalicTtf
}
return resourceJetBrainsMonoRegularTtf
return theme.DefaultTheme().Font(s)
}

func (bdTheme) Color(c fyne.ThemeColorName, v fyne.ThemeVariant) color.Color {
Expand Down

0 comments on commit 21f8a4a

Please sign in to comment.