Closed AokiAhishatsu closed 7 years ago
Thank you so much! I love it! My only question is that I would like to understand the implication for adding unit=' u'
. I believe that this results in outputs that will - by default - say 21.04 u
instead of simply 21.04
, correct? I didn't see any other changes related to this.
Yes, I my intention was to display a default unit with one space in front.
And btw, I use img_data
to read images from base64 strings. This is very useful when you want create single file executables with pyInstaller.
I was about to merge your pull request, but I am very intrigued by your img_data
comment. Could you elaborate?
You can save an image in a string. You can generate the string with this:
import base64
with open("\some\path\and\file.py", "rb") as image_file:
encoded_string = base64.b64encode(image_file.read())
print(encoded_string)
And call the constructor with the string.
Would you be opposed to removing the unit = u
? In the circles I travel in, this often means micro
as in microseconds
. Other than that, I'm quite happy. Your pull request will then be merged and released to v0.2.5
on pypi.
I will take the image string advice. I have already had issues with images and pyinstaller, so this will help on multiple fronts. That will probably be the next release up, v0.3.x
since it is a bit more comprehensive.
I don't care about the u