Alkimia API

alkdebug.cpp
1/*
2 SPDX-FileCopyrightText: 2024 Ralf Habacker ralf.habacker @freenet.de
3
4 This file is part of libalkimia.
5
6 SPDX-License-Identifier: LGPL-2.1-or-later
7*/
8
9#include "alkdebug.h"
10
11#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
12#include <QLoggingCategory>
13static Q_LOGGING_CATEGORY(alkimia, "Alkimia")
14QDebug _alkDebug(const char *file, int line, const char *func)
15{
16 return QMessageLogger(file, line, func, alkimia().categoryName()).debug() << func;
17}
18#else
19#include <KDebug>
20
21static int dbgArea()
22{
23 static int s_area = KDebug::registerArea("Alkimia");
24 return s_area;
25}
26
27QDebug _alkDebug(const char *file, int line, const char *func)
28{
29 return kDebugStream(QtDebugMsg, dbgArea(), file, line, func);
30}
31#endif
Wrapper for debug output.
QDebug debug() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:01:13 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.