QT中的数据类型qint8、qint16、qint32、qint64、qintptr、qlonglong、qttrdiff、qreal等的定义

发布于:2021-12-03 07:30:32

typedef qint8

Typedef for signed char. This type is guaranteed to be 8-bit on all platforms supported by Qt.


typedef for signed char,在Qt支持的所有*台上,此类型保证为8位。


typedef qint16

Typedef for signed short. This type is guaranteed to be 16-bit on all platforms supported by Qt.


typedef for signed short,在Qt支持的所有*台上,此类型保证为16位。


typedef qint32

Typedef for signed int. This type is guaranteed to be 32-bit on all platforms supported by Qt.


typedef for signed int,在Qt支持的所有*台上,此类型保证为32位。


typedef qint64

Typedef for long long int (__int64 on Windows). This type is guaranteed to be 64-bit on all platforms supported by Qt.


Literals of this type can be created using the Q_INT64_C() macro:


qint64 value = Q_INT64_C(932838457459459);


Typedef for long long int (__int64 on Windows).在Qt支持的所有*台上,此类型保证为64位。


typedef qintptr

Integral type for representing pointers in a signed integer (useful for hashing, etc.).


Typedef for either qint32 or qint64. This type is guaranteed to be the same size as a pointer on all platforms supported by Qt. On a system with 32-bit pointers, qintptr is a typedef for qint32; on a system with 64-bit pointers, qintptr is a typedef for qint64.


Note that qintptr is signed. Use quintptr for unsigned values.


typedef qlonglong

Typedef for long long int (__int64 on Windows). This is the same as qint64.


typedef qptrdiff

Integral type for representing pointer differences.


Typedef for either qint32 or qint64. This type is guaranteed to be the same size as a pointer on all platforms supported by Qt. On a system with 32-bit pointers, quintptr is a typedef for quint32; on a system with 64-bit pointers, quintptr is a typedef for quint64.


Note that qptrdiff is signed. Use quintptr for unsigned values.


typedef qreal

Typedef for double unless Qt is configured with the -qreal float option.


typedef quint8

Typedef for unsigned char. This type is guaranteed to be 8-bit on all platforms supported by Qt.


typedef quint16

Typedef for unsigned short. This type is guaranteed to be 16-bit on all platforms supported by Qt.


typedef quint32

Typedef for unsigned int. This type is guaranteed to be 32-bit on all platforms supported by Qt.


typedef quint64

Typedef for unsigned long long int (unsigned __int64 on Windows). This type is guaranteed to be 64-bit on all platforms supported by Qt.


Literals of this type can be created using the Q_UINT64_C() macro:



?

quint64 value = Q_UINT64_C(932838457459459);


?

See also Q_UINT64_C(), qint64, and qulonglong.


typedef quintptr

Integral type for representing pointers in an unsigned integer (useful for hashing, etc.).


Typedef for either quint32 or quint64. This type is guaranteed to be the same size as a pointer on all platforms supported by Qt. On a system with 32-bit pointers, quintptr is a typedef for quint32; on a system with 64-bit pointers, quintptr is a typedef for quint64.


Note that quintptr is unsigned. Use qptrdiff for signed values.


typedef qulonglong

Typedef for unsigned long long int (unsigned __int64 on Windows). This is the same as quint64.


See also quint64 and qlonglong.


typedef uchar

Convenience typedef for unsigned char.


typedef uint

Convenience typedef for unsigned int.


typedef ulong

Convenience typedef for unsigned long.


typedef ushort

Convenience typedef for unsigned short.

相关推荐

最新更新

猜你喜欢