1 // Scintilla source code edit control
3 ** Defines the look of a line marker in the margin .
5 // Copyright 1998-2011 by Neil Hodgson <neilh@scintilla.org>
6 // The License.txt file describes the conditions under which this software may be distributed.
15 typedef void (*DrawLineMarkerFn
)(Surface
*surface
, PRectangle
&rcWhole
, Font
&fontForCharacter
, int tFold
, int marginStyle
, const void *lineMarker
);
21 enum typeOfFold
{ undefined
, head
, body
, tail
, headWithTail
};
26 ColourDesired backSelected
;
30 /** Some platforms, notably PLAT_CURSES, do not support Scintilla's native
31 * Draw function for drawing line markers. Allow those platforms to override
32 * it instead of creating a new method(s) in the Surface class that existing
33 * platforms must implement as empty. */
34 DrawLineMarkerFn customDraw
;
36 markType
= SC_MARK_CIRCLE
;
37 fore
= ColourDesired(0,0,0);
38 back
= ColourDesired(0xff,0xff,0xff);
39 backSelected
= ColourDesired(0xff,0x00,0x00);
40 alpha
= SC_ALPHA_NOALPHA
;
45 LineMarker(const LineMarker
&) {
46 // Defined to avoid pxpm being blindly copied, not as a complete copy constructor
47 markType
= SC_MARK_CIRCLE
;
48 fore
= ColourDesired(0,0,0);
49 back
= ColourDesired(0xff,0xff,0xff);
50 backSelected
= ColourDesired(0xff,0x00,0x00);
51 alpha
= SC_ALPHA_NOALPHA
;
60 LineMarker
&operator=(const LineMarker
&other
) {
61 // Defined to avoid pxpm being blindly copied, not as a complete assignment operator
63 markType
= SC_MARK_CIRCLE
;
64 fore
= ColourDesired(0,0,0);
65 back
= ColourDesired(0xff,0xff,0xff);
66 backSelected
= ColourDesired(0xff,0x00,0x00);
67 alpha
= SC_ALPHA_NOALPHA
;
76 void SetXPM(const char *textForm
);
77 void SetXPM(const char *const *linesForm
);
78 void SetRGBAImage(Point sizeRGBAImage
, float scale
, const unsigned char *pixelsRGBAImage
);
79 void Draw(Surface
*surface
, PRectangle
&rc
, Font
&fontForCharacter
, typeOfFold tFold
, int marginStyle
) const;