Skip to content

Commit 35f3430

Browse files
committed
print fonts with family and style
1 parent d04c01f commit 35f3430

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/types.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,10 @@ function Base.getproperty(font::FTFont, fieldname::Symbol)
161161
end
162162
end
163163

164+
function Base.show(io::IO, font::FTFont)
165+
print(io, "FTFont (family = $(font.family_name), style = $(font.style_name))")
166+
end
167+
164168
# Allow broadcasting over fonts
165169
Base.Broadcast.broadcastable(ft::FTFont) = Ref(ft)
166170

0 commit comments

Comments
 (0)