1

I know that this question has probably being asked several times, but so far none of the answers was addressing my specific problem.

I'm going to deploy a django application on Heroku; it needs to draw some text on an image and then display it to the user. The text will be in italian, meaning that unicode support is mandatory.

I'm encountering several problems:

A solution to one (or both) problem will resolve my issue:

  • How to deploy PIL/Pillow on heroku with FreeType support
  • How to draw non-ascii chars using PIL fonts

Many thanks

Community
  • 1
  • 1
mgalardini
  • 1,397
  • 2
  • 16
  • 30

1 Answers1

1

You can use this PIL fork at your requirements.txt on heroku with FreeType support:

-e git://github.com/errkk/gitpil.git#egg=PIL
Pillow==1.7.8
panjianom
  • 236
  • 4
  • 18
  • Thanks for the suggestion, but for me it doesn't work, the setup.py displays "*** FREETYPE2 support not available". I'm inside virtual_env, as suggested by the Heroku django tutorial. – mgalardini Oct 15 '13 at 08:32
  • 1
    I do mistake, please try again with new answer above. – panjianom Oct 15 '13 at 19:03
  • It does the trick to load a FreeType font, but it is still impossible to complete the load of an image. I get a "DecodeError: decoder zip not available". That is strange, since during pip installation i've got "--- ZLIB (PNG/ZIP) support available". Any ideas? – mgalardini Oct 16 '13 at 17:38
  • For now i am using GIFs, which is the only format supported by this weird installation... – mgalardini Oct 17 '13 at 20:33
  • perhaps uninstall previous PIL/Pillow by using command: "heroku run pip uninstall PIL Pillow" & then install the fork again. – panjianom Oct 17 '13 at 22:04