-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Deprecate ImageCms constants and versions() function #7702
Conversation
@@ -32,7 +34,7 @@ | |||
|
|||
_imagingcms = DeferredError.new(ex) | |||
|
|||
DESCRIPTION = """ | |||
_DESCRIPTION = """ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When removing this constant, is there any important info in this text we should keep somewhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Originally released under LGPL. Graciously donated to PIL in
March 2009, for distribution under the standard PIL license
This should probably be turned into a comment - I've pushed a commit.
There are also links to https://www.cazabon.com/pyCMS and https://www.littlecms.com. I'm not sure these need to be kept; https://www.cazabon.com/pyCMS is the first result I get on Google for "Kevin Cazabon's PyCMS library" in a private window.
Otherwise, it just duplicates information from comments in ImageCms.py
, text from ImageCms.rst
, and part of CHANGES.rst
for PIL 1.1.7c1.
docs/releasenotes/10.3.0.rst
Outdated
``ImageCms.VERSION`` ``PIL.__version__`` | ||
``ImageCms.FLAGS["MATRIXINPUT"]`` :py:attr:`.ImageCms.Flags.CLUT_POST_LINEARIZATION` | ||
``ImageCms.FLAGS["MATRIXOUTPUT"]`` :py:attr:`.ImageCms.Flags.FORCE_CLUT` | ||
``ImageCms.FLAGS["MATRIXONLY"]`` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No replacement for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is equal to (1 | 2)
i.e. (MATRIXINPUT | MATRIXOUTPUT)
, so it could be CLUT_POST_LINEARIZATION | FORCE_CLUT
, but from the flag names it looks like these values have been repurposed in LCMS2.
I wasn't even sure about listing the replacements for MATRIXINPUT
and MATRIXOUTPUT
, but I couldn't find any LCMS2 documentation on this and didn't feel like hunting around in LCMS2 source code to check for each flag, so I just matched all flags by their values.
…deprecations without a replacement
Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
Thanks! |
Deprecations proposed in this pull request:
DESCRIPTION
is just a subset of the information in the docs/changelog and can be removed after deprecation.VERSION
has been equal to"1.0.0 pil"
since 2013,PIL.__version__
should be used instead.FLAGS
is based on LCMS1,Flags
added in Add LCMS2 flags to ImageCms #7676 uses names from LCMS2.versions()
is undocumented and returns values already available elsewhere.