Hi. I'm on Ubuntu Lucid, and I just installed a font called Museo Sans. I can use the font in most applications (gEdit, for example) but I can't use it in ImageMagick. (It's an OpenType Font, should that make a difference.)
When I run convert -list font | grep "Muse*" I don't come up with anything. (When I grep for "Tim*" I get all the Times fonts.)
I found this Perl script: http://www.imagemagick.org/Usage/script ... k_type_gen from http://www.imagemagick.org/Usage/, and ran updatedb for good measure, but it didn't save any "type.xml" file to ~/.magick/, nor did it fix my issue.
Any ideas? Thanks for reading.
Making IM aware of a font
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Making IM aware of a font
I believe that you can run it as
imagemagick_type_gen > type.xml
Then move that file to /usr/local/bin or where ever you have IM compiled
Do a search, such as
find /usr | grep "type.xml"
or
find /usr | grep "convert"
or
which convert
to see where it should be placed
Then run
convert -list type
and it should be there with all the other fonts.. Not too sure about OpenType, but I think I recall Anthony telling me that should be OK.
Alternately, just put the full path to your font in your -font command.
imagemagick_type_gen > type.xml
Then move that file to /usr/local/bin or where ever you have IM compiled
Do a search, such as
find /usr | grep "type.xml"
or
find /usr | grep "convert"
or
which convert
to see where it should be placed
Then run
convert -list type
and it should be there with all the other fonts.. Not too sure about OpenType, but I think I recall Anthony telling me that should be OK.
Alternately, just put the full path to your font in your -font command.
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Making IM aware of a font
Actually just copy that into a ".magick" sub-directory of your home. EG: $HOME/magick/type.xmlfmw42 wrote:I believe that you can run it as
imagemagick_type_gen > type.xml
Then move that file to /usr/local/bin or where ever you have IM compiled
However you don't need to get ALL the system fonts I myself just grab the oft and ttf filenames in my personal fonts directory....
Code: Select all
find $HOME/lib/fonts/ \( -name '*.ttf' -o -name '*.otf' \) |\
imagick_type_gen -f - > ~/.magick/type-myfonts.xml
Code: Select all
<typemap>
<include file="type-myfonts.xml" />
<include file="type-system.xml" />
</typemap>
But have putting it directly in the type.xml is fine too..
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/