diff options
| author | Neil <nyamatongwe@gmail.com> | 2018-05-14 14:13:13 +1000 | 
|---|---|---|
| committer | Neil <nyamatongwe@gmail.com> | 2018-05-14 14:13:13 +1000 | 
| commit | c4aa7826f3d2178e39e5bff2f6886d7d3d3f46d7 (patch) | |
| tree | e5f93f314c700da99e6c54f590d034645c73a111 /include/Platform.h | |
| parent | 3fc8c97d80a6797e60e6b203c9b4aa9d553df8a7 (diff) | |
| download | scintilla-mirror-c4aa7826f3d2178e39e5bff2f6886d7d3d3f46d7.tar.gz | |
Modernize Platform.h (3) - update Surface to delete WidthChar, use size_t for
Polygon and delete the standard copy and assignment methods.
Diffstat (limited to 'include/Platform.h')
| -rw-r--r-- | include/Platform.h | 13 | 
1 files changed, 6 insertions, 7 deletions
diff --git a/include/Platform.h b/include/Platform.h index d020db883..f50aca431 100644 --- a/include/Platform.h +++ b/include/Platform.h @@ -257,12 +257,12 @@ public:   * A surface abstracts a place to draw.   */  class Surface { -private: -	// Private so Surface objects can not be copied -	Surface(const Surface &) {} -	Surface &operator=(const Surface &) { return *this; }  public: -	Surface() {} +	Surface() noexcept = default; +	Surface(const Surface &) = delete; +	Surface(Surface &&) = delete; +	Surface &operator=(const Surface &) = delete; +	Surface &operator=(Surface &&) = delete;  	virtual ~Surface() {}  	static Surface *Allocate(int technology); @@ -277,7 +277,7 @@ public:  	virtual int DeviceHeightFont(int points)=0;  	virtual void MoveTo(int x_, int y_)=0;  	virtual void LineTo(int x_, int y_)=0; -	virtual void Polygon(Point *pts, int npts, ColourDesired fore, ColourDesired back)=0; +	virtual void Polygon(Point *pts, size_t npts, ColourDesired fore, ColourDesired back)=0;  	virtual void RectangleDraw(PRectangle rc, ColourDesired fore, ColourDesired back)=0;  	virtual void FillRectangle(PRectangle rc, ColourDesired back)=0;  	virtual void FillRectangle(PRectangle rc, Surface &surfacePattern)=0; @@ -293,7 +293,6 @@ public:  	virtual void DrawTextTransparent(PRectangle rc, Font &font_, XYPOSITION ybase, const char *s, int len, ColourDesired fore)=0;  	virtual void MeasureWidths(Font &font_, const char *s, int len, XYPOSITION *positions)=0;  	virtual XYPOSITION WidthText(Font &font_, const char *s, int len)=0; -	virtual XYPOSITION WidthChar(Font &font_, char ch)=0;  	virtual XYPOSITION Ascent(Font &font_)=0;  	virtual XYPOSITION Descent(Font &font_)=0;  	virtual XYPOSITION InternalLeading(Font &font_)=0;  | 
