Revert "Convert font image straight to QIcons"
This reverts commit 7cd632b4e2.
The commit would cause the font icons to be inverted sometimes. This
reversion is altered to return the font bitmaps as a QPixmap instead of a
QBitmap to be compatible with Qt6.
This commit is contained in:
6
render.h
6
render.h
@@ -20,9 +20,10 @@
|
||||
#ifndef RENDER_H
|
||||
#define RENDER_H
|
||||
|
||||
#include <QBitmap>
|
||||
#include <QColor>
|
||||
#include <QIcon>
|
||||
#include <QImage>
|
||||
#include <QPixmap>
|
||||
|
||||
#include "decode.h"
|
||||
|
||||
@@ -33,10 +34,11 @@ public:
|
||||
~TeletextFontBitmap();
|
||||
|
||||
QImage *image() const { return s_fontImage; }
|
||||
QIcon charIcon(int c, int s) const;
|
||||
QPixmap charBitmap(int c, int s) const { return s_fontBitmap->copy((c-32)*12, s*10, 12, 10); }
|
||||
|
||||
private:
|
||||
static int s_instances;
|
||||
static QBitmap* s_fontBitmap;
|
||||
static QImage* s_fontImage;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user