aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/LineMarker.h
diff options
context:
space:
mode:
authornyamatongwe <unknown>2002-10-02 03:26:47 +0000
committernyamatongwe <unknown>2002-10-02 03:26:47 +0000
commit3ce653c5dca296d9280a1a6f60a5d53423ac5fe2 (patch)
tree07a566b2912ab1d77d3e859687a05f806651c87a /src/LineMarker.h
parentc0da3d705622cbea4033e1226e2e37502c2977d2 (diff)
downloadscintilla-mirror-3ce653c5dca296d9280a1a6f60a5d53423ac5fe2.tar.gz
PixMap marker support.
Diffstat (limited to 'src/LineMarker.h')
-rw-r--r--src/LineMarker.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/LineMarker.h b/src/LineMarker.h
index 7897aa775..50194d65c 100644
--- a/src/LineMarker.h
+++ b/src/LineMarker.h
@@ -8,6 +8,27 @@
#ifndef LINEMARKER_H
#define LINEMARKER_H
+class XPM {
+ int height;
+ int width;
+ int nColours;
+ char *data;
+ char codeTransparent;
+ char *codes;
+ ColourPair *colours;
+ void Init(const char * const *linesForm);
+ ColourAllocated ColourFromCode(char ch);
+ void FillRun(Surface *surface, char code, int startX, int y, int x);
+public:
+ XPM(const char *textForm);
+ XPM(const char * const *linesForm);
+ ~XPM();
+ // Similar to same named method in ViewStyle:
+ void RefreshColourPalette(Palette &pal, bool want);
+ // Decompose image into runs and use FillRectangle for each run:
+ void Draw(Surface *surface, PRectangle &rc);
+};
+
/**
*/
class LineMarker {
@@ -15,11 +36,19 @@ public:
int markType;
ColourPair fore;
ColourPair back;
+ XPM *pxpm;
LineMarker() {
markType = SC_MARK_CIRCLE;
fore = ColourDesired(0,0,0);
back = ColourDesired(0xff,0xff,0xff);
+ pxpm = NULL;
+ }
+ ~LineMarker() {
+ delete pxpm;
}
+ void RefreshColourPalette(Palette &pal, bool want);
+ void SetXPM(const char *textForm);
+ void SetXPM(const char * const *linesForm);
void Draw(Surface *surface, PRectangle &rc, Font &fontForCharacter);
};