• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdegames API Reference
  • KDE Home
  • Contact Us
 

kblackbox

  • sources
  • kde-4.14
  • kdegames
  • kblackbox
kbbthememanager.h
Go to the documentation of this file.
1 //
2 // KBlackBox
3 //
4 // A simple game inspired by an emacs module
5 //
6 /***************************************************************************
7  * Copyright (c) 2007, Nicolas Roffet *
8  * nicolas-kde@roffet.com *
9  * *
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  * This program is distributed in the hope that it will be useful, *
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
19  * GNU General Public License for more details. *
20  * *
21  * You should have received a copy of the GNU General Public License *
22  * along with this program; if not, write to the *
23  * Free Software Foundation, Inc., *
24  * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA *
25  ***************************************************************************/
26 
27 
28 
29 #ifndef KBBTHEMEMANAGER_H
30 #define KBBTHEMEMANAGER_H
31 
32 
33 #include <QDomElement>
34 class QString;
35 
36 
37 #include <qsvgrenderer.h>
38 
39 
40 #include "kbbscalablegraphicwidget.h"
41 
42 
43 
51 class KBBThemeManager
52 {
53  public:
60  KBBThemeManager(const QString &svgzFileName);
61 
62 
69  QColor color(const KBBScalableGraphicWidget::itemType itemType);
70 
80  QString elementId(const KBBScalableGraphicWidget::itemType itemType);
81 
88  Qt::PenStyle style(const KBBScalableGraphicWidget::itemType itemType);
89 
95  QSvgRenderer* svgRenderer();
96 
103  qreal width(const KBBScalableGraphicWidget::itemType itemType);
104 
113  int zValue(const KBBScalableGraphicWidget::itemType itemType);
114 
115 
116  private:
133  QString value(const KBBScalableGraphicWidget::itemType itemType, const QString &styleElement);
134 
138  QDomElement m_root;
139 
145  QSvgRenderer m_svgRenderer;
146 };
147 
148 #endif // KBBTHEMEMANAGER_H
KBBThemeManager::width
qreal width(const KBBScalableGraphicWidget::itemType itemType)
Get the width of the item.
Definition: kbbthememanager.cpp:191
QSvgRenderer
KBBThemeManager::zValue
int zValue(const KBBScalableGraphicWidget::itemType itemType)
Get the relative height of the item.
Definition: kbbthememanager.cpp:197
KBBThemeManager::svgRenderer
QSvgRenderer * svgRenderer()
Get the shared SVG renderer.
Definition: kbbthememanager.cpp:185
kbbscalablegraphicwidget.h
QString
QColor
KBBThemeManager::color
QColor color(const KBBScalableGraphicWidget::itemType itemType)
Get the color of the item.
Definition: kbbthememanager.cpp:75
KBBThemeManager::elementId
QString elementId(const KBBScalableGraphicWidget::itemType itemType)
Get the XML "id" value of the item.
Definition: kbbthememanager.cpp:81
KBBThemeManager
Theme manager of the scalable graphic widget.
Definition: kbbthememanager.h:51
QDomElement
KBBThemeManager::style
Qt::PenStyle style(const KBBScalableGraphicWidget::itemType itemType)
Get the pen style of the item.
Definition: kbbthememanager.cpp:176
KBBScalableGraphicWidget::itemType
itemType
Every graphic items.
Definition: kbbscalablegraphicwidget.h:89
KBBThemeManager::KBBThemeManager
KBBThemeManager(const QString &svgzFileName)
Constructor.
Definition: kbbthememanager.cpp:49
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:18:20 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kblackbox

Skip menu "kblackbox"
  • Main Page
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdegames API Reference

Skip menu "kdegames API Reference"
  • granatier
  • kapman
  • kblackbox
  • kgoldrunner
  • kigo
  • kmahjongg
  • KShisen
  • ksquares
  • libkdegames
  •   highscore
  •   libkdegamesprivate
  •     kgame
  • libkmahjongg
  • palapeli
  •   libpala

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal