Rewrite alpha colorspaces using templates and make them correct
- Non-U8 alpha color spaces were not connected to the color conversion system. Therefore, one couldn't convert to/from them any data
- The code of their methods were blindly copied from U8 color space, therefore all the functions (incl. toQColor/fromQColor/difference) just read wrong values from pointers (quint8 instead of quint16 or bigger).
- Now all the alpha color spaces are rewritten using a common template and the same code reused for all of them, with correct pointer conversions using KoColorSpaceMaths.
- The new color spaces are converted to the conversion system using existing Factory::colorConversionLinks() framework. Yes, they are created using factories.
Open Questions:
- In KoColorSpaceRegistry there are some special cases about persistent storage of d->alphaCs and 'OwnedByRegistryRegistryDeletes' flags. I couldn't find any info about it, so it might be incorrect.
Other patches included
- Implement reading of zipped layer transparency masks from PSD
- Fix writing of 16-bit transparency masks to a PSD file
BUG:376836