Convert HTML string to an image in Python
graphicsmagick, html, image, imagemagick, python
Solution
webkit2png. The original version is OSX-only, but luckily there is a cross-platform fork: https://github.com/AdamN/python-webkit2png
Problem
I want to convert following HTML to PNG image in Python. ``` <html> <b>Bold text</b> </html> ``` This HTML is, of course, an example. I have tried 'pisa' but it converts html to PDF, not to image. I can convert HTML to PDF and then convert PDF to PNG, but I was wondering if there is any direct solution (i.e HTML to PNG). Any built-in or external module will work nicely. If this can be done in Graphicsmagick or Imagemagick, then it will be perfect.