mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-05 13:26:21 +00:00
replace depreciated bitBlt() with calls to qpainter's drawPixmap()
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14691 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
22a3512110
commit
e305fdea55
@ -16,6 +16,7 @@
|
||||
#include "support/filetools.h"
|
||||
|
||||
#include <QPixmap>
|
||||
#include <QPainter>
|
||||
|
||||
#include <boost/assert.hpp>
|
||||
|
||||
@ -86,7 +87,8 @@ void BulletsModule::setupPanel(QListWidget * lw, QString panelname, std::string
|
||||
for (int col = 0; col < 6; ++col) {
|
||||
QPixmap small(w,h);
|
||||
small.fill();
|
||||
bitBlt(&small, 0, 0, &pixmap, col * w, row * h, w, h);
|
||||
QPainter painter(&small);
|
||||
painter.drawPixmap(small.rect(), pixmap, QRect(col * w, row * h, w, h));
|
||||
new QListWidgetItem(QIcon(small), "" , lw, (6*row + col));
|
||||
}
|
||||
}
|
||||
|
@ -41,7 +41,8 @@ QSetBorder::QSetBorder(QWidget * parent, char const * name, Qt::WFlags fl)
|
||||
void QSetBorder::paintEvent(QPaintEvent * e)
|
||||
{
|
||||
QWidget::paintEvent(e);
|
||||
bitBlt(this, 0, 0, &buffer, 0, 0, width(), height());
|
||||
QPainter painter(this);
|
||||
painter.drawPixmap(0, 0, buffer);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user