marble
MapThemeDownloadDialog.cpp
Go to the documentation of this file.
31 void paint( QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index ) const;
35 bool editorEvent( QEvent *event, QAbstractItemModel *model, const QStyleOptionViewItem &option, const QModelIndex &index );
79 d->m_model.setRegistryFile( MarbleDirs::localPath() + "/newstuff/marble-map-themes.knsregistry", Marble::NewstuffModel::NameTag );
94 MapItemDelegate::MapItemDelegate( QListView *view , NewstuffModel *newstuffModel, MarbleWidget* marbleWidget ) :
105 void MapItemDelegate::paint( QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index ) const
174 QSize MapItemDelegate::sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const
180 doc.setTextWidth( qMax( 200, m_view->contentsRect().width() - iconSize.width() - buttonWidth( option ) - 3 * m_margin ) );
189 bool MapItemDelegate::editorEvent(QEvent *event, QAbstractItemModel *, const QStyleOptionViewItem &option, const QModelIndex &index)
257 QStyleOptionButton MapItemDelegate::button( Element element, const QStyleOptionViewItem &option ) const
303 QPoint const topLeftCol3 = topLeftCol2 + QPoint( option.rect.width() - 3 * m_margin - width - option.decorationSize.width(), 0 );
315 QSize buttonSize = QApplication::style()->sizeFromContents( QStyle::CT_PushButton, &optionButton, size );
324 QSize buttonSize = QApplication::style()->sizeFromContents( QStyle::CT_PushButton, &optionButton, size );
326 return QRect( topLeftCol3 + QPoint( 0, option.fontMetrics.height() + 8 + m_margin ), buttonSize );
345 return QString("<p><b>%1</b><br />%2</p><p>Author: %3<br />License: %4<br />Version %5 (%6) %7</p>")
qlonglong toLongLong(bool *ok) const
QSize size() const
Type type() const
int width() const
Definition: NewstuffModel.h:26
int size() const
void save()
T value() const
int height() const
int x() const
QPixmap pixmap(const QSize &size, Mode mode, State state) const
A widget class that displays a view of the earth.
Definition: MarbleWidget.h:104
MapThemeDownloadDialog(MarbleWidget *marbleWidget)
Definition: MapThemeDownloadDialog.cpp:71
QString number(int n, int base)
Definition: tools/osm-addresses/OsmParser.h:40
Definition: NewstuffModel.h:39
void drawPixmap(const QRectF &target, const QPixmap &pixmap, const QRectF &source)
void setWidth(int width)
int row() const
QAbstractTextDocumentLayout * documentLayout() const
bool endsWith(const QString &s, Qt::CaseSensitivity cs) const
bool contains(const QPoint &point, bool proper) const
Definition: NewstuffModel.h:38
bool cdUp()
const QSize iconSize(16, 16)
void setDefaultFont(const QFont &font)
Definition: NewstuffModel.h:40
void restore()
void setTextWidth(qreal width)
int width() const
void setClipRect(const QRectF &rectangle, Qt::ClipOperation operation)
QString mid(int position, int n) const
QStringList toStringList() const
QVariant data(int role) const
QStyle * style()
QString absolutePath() const
virtual void drawControl(ControlElement element, const QStyleOption *option, QPainter *painter, const QWidget *widget) const =0
int height() const
QPoint topLeft() const
int column() const
bool toBool() const
void translate(const QPointF &offset)
void setHtml(const QString &html)
virtual void draw(QPainter *painter, const PaintContext &context)=0
QString left(int n) const
This file contains the headers for MarbleWidget.
Definition: NewstuffModel.h:41
const QPoint & pos() const
Wraps a Marble::MarbleWidget, providing access to important properties and methods.
Definition: MarbleDeclarativeWidget.h:50
~MapThemeDownloadDialog()
Definition: MapThemeDownloadDialog.cpp:89
QString arg(qlonglong a, int fieldWidth, int base, const QChar &fillChar) const
QString toString() const
virtual QSize sizeFromContents(ContentsType type, const QStyleOption *option, const QSize &contentsSize, const QWidget *widget) const =0
Definition: NewstuffModel.h:58
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:40 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:13:40 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.