49 #include "private/qdebug_p.h"
51 #include <private/qtextstream_p.h>
52 #include <private/qtools_p.h>
71 for (
int i = 0;
i < qMin(
len, maxSize); ++
i) {
201 if (
stream->message_output) {
213 void QDebug::putUcs4(
uint ucs4)
218 }
else if (ucs4 < 0x80) {
233 static inline bool isPrintable(
uint ucs4)
235 static inline bool isPrintable(
ushort uc)
237 static inline bool isPrintable(
uchar c)
238 {
return c >=
' ' &&
c < 0x7f; }
240 template <
typename Char>
246 bool lastWasHexEscape =
false;
256 lastWasHexEscape =
false;
262 while (
p + runLength !=
end &&
263 isPrintable(
p[runLength]) &&
p[runLength] !=
'\\' &&
p[runLength] !=
'"')
266 d->write(
reinterpret_cast<const QChar *
>(
p), runLength);
270 }
else if (isPrintable(*
p) && *
p !=
'\\' && *
p !=
'"') {
308 lastWasHexEscape =
true;
315 if (isPrintable(ucs4)) {
343 d->write(
reinterpret_cast<QChar *
>(
buf), buflen);
362 stream->ts.d_ptr->params.reset();
371 void QDebug::putByteArray(
const char *
begin,
size_t length, Latin1Content content)
377 stream->ts.d_ptr->putString(
string);
381 stream->ts.d_ptr->params.reset();
382 putEscapedString(
stream->ts.d_ptr.data(),
reinterpret_cast<const uchar *
>(
begin),
383 int(
length), content == ContainsLatin1);
984 const bool currentSpaces =
m_stream->space;
1042 qt_QMetaEnum_flagDebugOperator<int>(
debug, sizeofT,
value);
1045 #ifndef QT_NO_QOBJECT
1090 if (
const char *scope = me.
scope())
1091 dbg << scope <<
u"::";
1095 const bool scoped = me.
isScoped() || verbosity & 1;
1102 dbg <<
value <<
')';
1138 const int verbosity =
debug.verbosity();
1141 debug.resetFormat();
1151 if (
const char *scope = me.
scope())
1163 debug << me.valueToKeys(value);
1170 #endif // !QT_NO_QOBJECT
small capitals from c petite p scientific f u
small capitals from c petite p scientific i
[1]
The QByteArray class provides an array of bytes.
The QChar class provides a 16-bit Unicode character.
static constexpr char32_t surrogateToUcs4(char16_t high, char16_t low) noexcept
constexpr bool isLowSurrogate() const noexcept
bool isPrint() const noexcept
constexpr bool isHighSurrogate() const noexcept
The QDebug class provides an output stream for debugging information.
QDebug & verbosity(int verbosityLevel)
QDebug & maybeQuote(char c='"')
Convenience class for custom QDebug operators.
QDebugStateSaver(QDebug &dbg)
const QTextStreamPrivate::Params m_streamParams
QDebug::Stream * m_stream
QDebugStateSaverPrivate(QDebug::Stream *stream)
The QString class provides a Unicode character string.
static QString fromLatin1(QByteArrayView ba)
qsizetype fromUtf8(uchar b, OutputPtr &dst, InputPtr &src, InputPtr end)
Q_CORE_EXPORT QByteArray toPrintable(const char *data, int len, int maxSize)
QTextStream & hex(QTextStream &stream)
QTextStream & reset(QTextStream &stream)
constexpr char toHexUpper(uint value) noexcept
constexpr char toHexLower(uint value) noexcept
constexpr int fromHex(uint c) noexcept
QDebug qt_QMetaEnum_debugOperator(QDebug &dbg, qint64 value, const QMetaObject *meta, const char *name)
void qt_QMetaEnum_flagDebugOperator(QDebug &debug, size_t sizeofT, int value)
EGLOutputLayerEXT EGLint EGLAttrib value
QT_BEGIN_INCLUDE_NAMESPACE typedef unsigned char uchar
unsigned long long quint64
Q_CORE_EXPORT void qt_message_output(QtMsgType, const QMessageLogContext &context, const QString &message)
GLenum GLuint GLenum GLsizei length
GLenum GLuint GLenum GLsizei const GLchar * buf
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
QtPrivate::QRegularExpressionMatchIteratorRangeBasedForIterator begin(const QRegularExpressionMatchIterator &iterator)
QT_BEGIN_NAMESPACE typedef char Char
QTextStreamManipulator qSetPadChar(QChar ch)
QTextStreamManipulator qSetFieldWidth(int width)
QTextStream out(stdout)
[7]
The QLatin1Char class provides an 8-bit ASCII/Latin-1 character.