From f9bcd0a47cbdf0806c35a82856efdbe06279fb82 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Mon, 19 Sep 2011 16:38:07 +0200 Subject: Rough draft for getting back the header for the details-view --- src/kitemviews/kitemlistheader.cpp | 42 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 src/kitemviews/kitemlistheader.cpp (limited to 'src/kitemviews/kitemlistheader.cpp') diff --git a/src/kitemviews/kitemlistheader.cpp b/src/kitemviews/kitemlistheader.cpp new file mode 100644 index 000000000..89b28bcce --- /dev/null +++ b/src/kitemviews/kitemlistheader.cpp @@ -0,0 +1,42 @@ +/*************************************************************************** + * Copyright (C) 2011 by Peter Penz * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * + ***************************************************************************/ + +#include "kitemlistheader_p.h" + +#include + +KItemListHeader::KItemListHeader(QGraphicsWidget* parent) : + QGraphicsWidget(parent) +{ + resize(0, 20); // TODO... +} + +KItemListHeader::~KItemListHeader() +{ +} + +void KItemListHeader::paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget) +{ + Q_UNUSED(option); + Q_UNUSED(widget); + painter->setPen(Qt::red); + painter->drawRect(rect()); +} + +#include "kitemlistheader_p.moc" -- cgit v1.3