Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
5.5.0
-
None
Description
Qt Quick appears to require that enums in registered types start with a capital letter.
This isn't mentioned anywhere I could find.
Working enum definition
enum EnStyle
{
STYLE_RADIAL,
STYLE_ENVELOPE,
STYLE_FILLED
};
Q_ENUMS(EnStyle)
Non-functional enum definition
enum EnStyle
{
styleRADIAL,
styleENVELOPE,
styleFILLED
};
Q_ENUMS(EnStyle)
This should be added to the pages that talk about this:
http://doc.qt.io/qt-5/qtqml-cppintegration-definetypes.html
http://doc.qt.io/qt-5/qqmlengine.html#qmlRegisterType-4
http://doc.qt.io/qt-5/qqmlengine.html#qmlRegisterUncreatableType
(Not sure if this is all, but it's most)
Attachments
For Gerrit Dashboard: QTBUG-48050 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
139076,5 | Doc: added spec on defining enums register.types | 5.6 | qt/qtdeclarative | Status: MERGED | +2 | 0 |