diff options
| author | Neil <nyamatongwe@gmail.com> | 2021-03-20 12:53:27 +1100 | 
|---|---|---|
| committer | Neil <nyamatongwe@gmail.com> | 2021-03-20 12:53:27 +1100 | 
| commit | 921df6efca5b385790a2806f8b8844becb36e773 (patch) | |
| tree | d84a6c8801e83a972485c052559ab9997e8073d2 /qt/ScintillaEditBase/PlatQt.h | |
| parent | 2813306346e4087679915c2b30f1be4949f0228a (diff) | |
| download | scintilla-mirror-921df6efca5b385790a2806f8b8844becb36e773.tar.gz | |
Add AllocatePixMap method on Surface to create a pixmap surface.
Diffstat (limited to 'qt/ScintillaEditBase/PlatQt.h')
| -rw-r--r-- | qt/ScintillaEditBase/PlatQt.h | 17 | 
1 files changed, 10 insertions, 7 deletions
| diff --git a/qt/ScintillaEditBase/PlatQt.h b/qt/ScintillaEditBase/PlatQt.h index 8f4d2c51d..1fc476129 100644 --- a/qt/ScintillaEditBase/PlatQt.h +++ b/qt/ScintillaEditBase/PlatQt.h @@ -73,25 +73,28 @@ constexpr PRectangle RectangleInset(PRectangle rc, XYPOSITION delta) noexcept {  class SurfaceImpl : public Surface {  private: -	QPaintDevice *device; -	QPainter *painter; -	bool deviceOwned; -	bool painterOwned; -	float x, y; +	QPaintDevice *device = nullptr; +	QPainter *painter = nullptr; +	bool deviceOwned = false; +	bool painterOwned = false; +	float x = 0; +	float y = 0;  	SurfaceMode mode; -	const char *codecName; -	QTextCodec *codec; +	const char *codecName = nullptr; +	QTextCodec *codec = nullptr;  	void Clear();  public:  	SurfaceImpl(); +	SurfaceImpl(int width, int height, SurfaceMode mode_);  	virtual ~SurfaceImpl();  	void Init(WindowID wid) override;  	void Init(SurfaceID sid, WindowID wid) override;  	void InitPixMap(int width, int height,  		Surface *surface, WindowID wid) override; +	std::unique_ptr<Surface> AllocatePixMap(int width, int height) override;  	void SetMode(SurfaceMode mode) override; | 
