Details
-
Bug
-
Resolution: Fixed
-
P3: Somewhat important
-
6.7
-
727d23503 (dev)
-
Foundation Sprint 122, Foundation Sprint 123, Foundation Sprint 124, Foundation Sprint 125, Foundation Sprint 126
Description
Qt 6.7 added properties for topLeftRadius, topRightRadius, bottomLeftRadius, bottomRightRadius. However, it uses -1 to denote “no specific radius” for that corner and falls back to using the generic radius.
This leads to unexpected results when using e.g. a calculation or animation that happens to animate via -1 where for a split frame it goes from “no radius” to “global radius” and then starts animating up from zero.
Setting a negative radius has no effect on the Rectagle, and (needlessly) prints a warning for the corner radii.
What it could to (to avoid four additional bool ...RadiusExplicitlySet members is to use qNaN as an indication of “no value provided”, or use a bitfield I suppose. If one wants to unset the radius, undefined will do the job via the RESET property anyway.
-1 should be treated as if the radius was explicitly set to 0 to match the behavior of radius.