Merge pull request #61 from sepandhaghighi/background_bug

Background Bug
pull/62/head
Sadra Sabouri 2021-10-18 17:00:30 +03:30 zatwierdzone przez GitHub
commit 9a83d1fb0a
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
3 zmienionych plików z 12 dodań i 2 usunięć

Wyświetl plik

@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
### Changed
- `depth` parameter added to `save_image` method
- `depth` parameter added to `save_fig_file` function
- `save_image` and `nft_storage` methods background bug fixed
- `README.md` updated
- Test system updated
## [0.2] - 2021-10-14
### Added

Plik binarny nie jest wyświetlany.

Przed

Szerokość:  |  Wysokość:  |  Rozmiar: 184 KiB

Po

Szerokość:  |  Wysokość:  |  Rozmiar: 197 KiB

Wyświetl plik

@ -129,7 +129,11 @@ def save_fig_file(figure, file_adr, depth):
return {"status": False, "message": NO_FIG_ERROR_MESSAGE}
result = {"status": True, "message": FIG_SAVE_SUCCESS_MESSAGE}
try:
figure.savefig(file_adr, dpi=depth * figure.dpi)
figure.savefig(
file_adr,
dpi=depth * figure.dpi,
facecolor=figure.get_facecolor(),
edgecolor='none')
return result
except Exception as e:
result["status"] = False
@ -153,7 +157,11 @@ def save_fig_buf(figure):
"buffer": None}
try:
buf = io.BytesIO()
figure.savefig(buf, format='png')
figure.savefig(
buf,
format='png',
facecolor=figure.get_facecolor(),
edgecolor='none')
result["buffer"] = buf
return result
except Exception as e: