I am making an interface in Tkinter and I need to have custom fonts. Not just, say, Helvetica at a certain size or whatever, but fonts other than what would normally be ava
for linux, I was able to install the otf font file I had into the system fonts directory:
mkdir /usr/share/fonts/opentype/my_fonts_name
cp ~/Downloads/my_fonts_name.otf /usr/share/fonts/opentype/my_fonts_name/
I found this home directory worked, and ended up using it instead:
mkdir ~/.fonts/
cp ~/Downloads/my_fonts_name.otf ~/.fonts/
in either case, then I could load it using a string of the font-name (as all the tkinter docs show):
# unshown code
self.canvas = tk.Canvas(self.data_frame, background="black")
self.canvas.create_text(event.x, event.y, text=t, tags='clicks',
fill='firebrick1',
font=("My Fonts Name", 22))