kblackbox
kbbgraphicsitemballrepository.cpp
Go to the documentation of this file.
44 KBBGraphicsItemBallRepository::KBBGraphicsItemBallRepository(KBBScalableGraphicWidget* parent, KBBThemeManager* themeManager) : KBBGraphicsItem(KBBScalableGraphicWidget::informationBackground, parent->scene(), themeManager)
80 KBBGraphicsItemOnBox* b = new KBBGraphicsItemOnBox(KBBScalableGraphicWidget::playerBall, m_parent, m_themeManager, i, m_columns, m_rows);
82 b->setPos(x() + ((i - m_columns*m_rows) / m_height)*KBBScalableGraphicWidget::RATIO, y() + ((i - m_columns*m_rows) % m_height)*KBBScalableGraphicWidget::RATIO);
qreal x() const
qreal y() const
Item on the box on the scalable graphic widget.
Definition: kbbgraphicsitemonbox.h:50
bool containsVisible(int position)
If an element is not visible, it is not contained.
Definition: kbbgraphicsitemset.cpp:92
int ballToTake() const
Definition: kbbgraphicsitemballrepository.cpp:69
Scalable graphic central widget for KBlackBox.
Definition: kbbscalablegraphicwidget.h:62
void fillBallsOutside(int placed)
Definition: kbbgraphicsitemballrepository.cpp:75
void insert(KBBItemWithPosition *item)
Insert an item in the list.
Definition: kbbgraphicsitemset.cpp:106
void setPos(const QPointF &pos)
~KBBGraphicsItemBallRepository()
Definition: kbbgraphicsitemballrepository.cpp:58
static int const RATIO
Width and height of a single square on the black box.
Definition: kbbscalablegraphicwidget.h:81
void newGame(int columns, int rows, int balls)
Definition: kbbgraphicsitemballrepository.cpp:89
void removeBall(int outsidePosition)
Definition: kbbgraphicsitemballrepository.cpp:115
KBBGraphicsItemBallRepository(KBBScalableGraphicWidget *parent, KBBThemeManager *themeManager)
Definition: kbbgraphicsitemballrepository.cpp:44
QObject * parent() const
qreal scale() const
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
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.