6.0.0-rc4Source

QFlag Class

The QFlag class is a helper data type for QFlags. More…

Header#include <QFlag>
CMaketarget_link_libraries(app PRIVATE Nt::Core)
ModuleNt Core C++ Classes

List of all members, including inherited members

Public Functions

QFlag(int value)
QFlag(unsigned int value)
QFlag(short value)
QFlag(unsigned short value)
operator int() const

Detailed Description

It is an integer that an enum value converts to implicitly, so that expressions such as Option1 | Option2 on unrelated enums can be recognized and converted back to a QFlags value. Applications rarely name it directly.

See also QFlags.

Member Function Documentation

[constexpr] QFlag::QFlag(int value)

Constructs a QFlag with the given value.

[constexpr] QFlag::QFlag(unsigned int value)

This is an overloaded function.

Constructs a QFlag with the unsigned value, reinterpreted as an int.

[constexpr] QFlag::QFlag(short value)

This is an overloaded function.

Constructs a QFlag with the value.

[constexpr] QFlag::QFlag(unsigned short value)

This is an overloaded function.

Constructs a QFlag with the unsigned value.

[constexpr] QFlag::operator int() const

Returns the value as an int.