Skip to content

Commit

Permalink
Merge pull request #80 from ericphanson/patch-1
Browse files Browse the repository at this point in the history
Clarify & fix README example
  • Loading branch information
SimonDanisch authored Nov 22, 2023
2 parents 955a954 + 6b6c09e commit 329d89a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,12 @@ Draw text into a Matrix.

using FreeTypeAbstraction

# load a font
face = FTFont("hack_regular.ttf")
# search for a font on your system
# Choose the name of a font you have installed
face = findfont("arial") # if this returns `nothing`, that means it could not find the font

# render a character
img, metric = renderface(face, 'C')
img, metric = renderface(face, 'C', 100)

# render a string into an existing matrix
myarray = zeros(UInt8, 100, 100)
Expand Down

0 comments on commit 329d89a

Please sign in to comment.