Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pixmap methods only have camelCase #1041

Closed
cbm755 opened this issue May 2, 2021 · 3 comments
Closed

Pixmap methods only have camelCase #1041

cbm755 opened this issue May 2, 2021 · 3 comments
Assignees
Labels

Comments

@cbm755
Copy link
Contributor

cbm755 commented May 2, 2021

I was doing a pass cleaning up fitz.camelCase to fitz.snake_case.

I noticed the Pixmap methods only have camelCase, e.g. writeImage, writePNG, get* and set*.

Is intentional or just didn't get to those ones yet?

@JorjMcKie
Copy link
Collaborator

That's correct - I am just not yet done with it 😒

@JorjMcKie
Copy link
Collaborator

The nexr version, 1.18.13, will have that changed, finally. It won't always be just a foreseeable insertion of changing upper case to lower case with a prefixed underscore:
I am also trying to find more consistent names across classes: Pixmap.writeImage / Pixmap.writePNG ==> Pixmap.save, Pixmap.getPNGData ==> Pixmap.tobytes, Pixmap.pillowWrite ==> Pixmap.pil_save, Pixmap.pillowData ==> Pixmap.pil_tobytes, and similar.

There are also leftovers in the Page class: Page.addXYZAnnot(). That will become page.add_xyz_annot().

@JorjMcKie
Copy link
Collaborator

Fixed in v1.18.13, which was just published.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants