resloveMetaData() only matched Q_CLASSINFO against the first segment of
the property path (e.g. "ptPosition" from "ptPosition.x"), so child
handles like x/y under a QPointF tree never picked up Min/Max/Step
metadata declared with Q_CLASSINFO("x", ...). This caused the x/y
NumberBox editors to fall back to numeric_limits min/max, clamping
negative values to ~0.
Now iterates path segments from most specific (last) to least specific
(first), so child property names correctly match their Q_CLASSINFO
annotations.
Also add Q_CLASSINFO("x"/"y", "Min=-1000,Max=1000,Step=1") on
GraphicsTextItem to constrain position editing to a reasonable range.
|
||
|---|---|---|
| .. | ||
| graphicsBaseItem.h | ||
| graphicsItemGroup.h | ||
| graphicsPolygonItem.h | ||
| graphicsRectItem.h | ||
| graphicsTextItem.h | ||
| itemControlHandle.h | ||