summaryrefslogtreecommitdiff
path: root/noncore/settings/appearance2/fontlistitem.h
blob: 73f1d5485eefbf25ad981884ff6b388f4dff9b35 (plain)
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
#ifndef FONTLISTITEM_H
#define FONTLISTITEM_H

#include <qlistbox.h>

class FontListItem : public QListBoxText {
public:
	FontListItem ( const QString &t, const QStringList &styles, const QValueList<int> &sizes ) : QListBoxText ( )
	{
		m_name = t;
		m_styles = styles;
		m_sizes = sizes;
		
		QString str = t;
		str [0] = str [0]. upper ( );
		setText ( str );
	}

	QString family ( ) const
	{
		return m_name;
	}
	
	const QStringList &styles ( ) const
	{
		return m_styles;
	}
	
	const QValueList<int> &sizes ( ) const
	{
		return m_sizes;
	}
	
private:
	QStringList m_styles;
	QValueList<int> m_sizes;
	QString m_name;
};

#endif