Closed PatWalters closed 1 year ago
Thanks.
I'll try to have a look soon enough.
Thanks, it would also be useful to scale the structure in the middle of the circle. Currently, it's really big.
I revisited the code and it turns out that we compute the bounding box coordinate but never "draw" the actual text 😅
The following line is missing after the snippet above:
self.draw.text((center_x - w//2, center_y + width //2 - 2*h), txt, fill="black", font=font)
I can make a PR (and also remove the annoying missing font message on osx). But I really would like to move away from hacking PIL image together to using the RDKit's canvas framework and this seems like one good opportunity.
Should be easy to translate the current code, but I probably wouldn't get started on this before the weekend
Thanks, it would also be useful to scale the structure in the middle of the circle. Currently, it's really big.
In addition to this, it would make sense to give the user some control over how the molecules are rendered (just forwarding dm.to_image
arguments)
This all sounds great, thank you!
The circle_grid capability is very interesting. However, I can't figure out how to get text to display. I put together this gist to show how I'm trying to use it. Please tell me what I'm doing wrong. Thanks!
https://gist.github.com/PatWalters/cab0c8555298a5b9fca5e047b3a7096a