This repository was archived by the owner on Sep 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 19
/
Copy pathQtHelper.h
48 lines (44 loc) · 1.71 KB
/
QtHelper.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/***************************************************************************//**
* @brief libQt+
* Librairie de fonctions usuelles.
*
* @file libQt+.h
*
* @author Quentin Rousseau\n
* @note Copyright: Quentin Rousseau (c) 2011 2010, Quentin Rousseau\n
* Sous licence: Creative Commons GNU GPL - http://creativecommons.org/licenses/GPL/3.0/\n
* email: [email protected]
*
* @version 1.0
* @date 2010 - 2011
*******************************************************************************/
#ifndef LIBQT_H
#define LIBQT_H
#include <QListWidget>
#include <QApplication>
#include <QFrame>
#include <QDesktopWidget>
#include <QFontDatabase>
#include <QDir>
#include <QTime>
#include <QSettings>
#include <QStringList>
//#include "mtn/mtn.h"
class QtHelper
{
public:
static QFrame *addHSeparator();
static QFrame *addVSeparator();
static void centerWidget(QWidget *widget);
static QStringList getItemsListWidget(QListWidget *listWidget);
static QStringList getItemsListWidget(QListWidget *listWidget, Qt::CheckState state);
static bool removeSelectedItems(QListWidget *listWidget);
static QString qColor2rgbNoSharp(QColor color);
static QColor rgbNoSharp2qColor(QString rgbNoSharp);
//static rgb_color qColor2RGB(QColor color);
static QString msecs2Hmn(qint64 msecs);
static QString secs2Hmn(int secs);
static QMap <QString,QString> exploreTTFDir(QStringList dirPath);
static QStringList readPathsFontsValueIni(QSettings *settings);
};
#endif // LIBQT_H