Warning, file /frameworks/kwidgetsaddons/tests/kratingwidgettest.cpp was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 /*
0002     This file is part of the KDE Libraries
0003     SPDX-FileCopyrightText: 2013 Kevin Ottens <ervin+bluesystems@kde.org>
0004 
0005     SPDX-License-Identifier: LGPL-2.0-or-later
0006 */
0007 #include <QApplication>
0008 #include <QVBoxLayout>
0009 
0010 #include <kratingwidget.h>
0011 
0012 int main(int argc, char **argv)
0013 {
0014     QApplication app(argc, argv);
0015     app.setAttribute(Qt::AA_UseHighDpiPixmaps, true);
0016 
0017     QWidget window;
0018     auto *layout = new QVBoxLayout(&window);
0019 
0020     KRatingWidget *enabled = new KRatingWidget(&window);
0021     layout->addWidget(enabled);
0022 
0023     KRatingWidget *disabled = new KRatingWidget(&window);
0024     disabled->setEnabled(false);
0025     layout->addWidget(disabled);
0026 
0027     window.show();
0028 
0029     return app.exec();
0030 }