diff options
author | nyamatongwe <devnull@localhost> | 2000-05-10 11:53:11 +0000 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2000-05-10 11:53:11 +0000 |
commit | 256989e8407879dbacdfb618c2cad67de160ac00 (patch) | |
tree | 722bc4ebdab9d5e760b31d87854695c25fecc294 /src/Indicator.cxx | |
parent | 8d20ab7b6e45c33d073b53638c60d4348712be09 (diff) | |
download | scintilla-mirror-256989e8407879dbacdfb618c2cad67de160ac00.tar.gz |
Added underline attribute to styles.
Added diagonal and strike-through indicators.
Diffstat (limited to 'src/Indicator.cxx')
-rw-r--r-- | src/Indicator.cxx | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/Indicator.cxx b/src/Indicator.cxx index fb6ad0915..05bdf66b5 100644 --- a/src/Indicator.cxx +++ b/src/Indicator.cxx @@ -37,6 +37,22 @@ void Indicator::Draw(Surface *surface, PRectangle &rc) { surface->MoveTo(x-3, ymid); surface->LineTo(x-3, ymid+2); } + } else if (style == INDIC_DIAGONAL) { + int x = rc.left; + while (x < rc.right) { + surface->MoveTo(x, rc.top+2); + int endX = x+3; + int endY = rc.top - 1; + if (endX > rc.right) { + endY += endX - rc.right; + endX = rc.right; + } + surface->LineTo(endX, endY); + x += 4; + } + } else if (style == INDIC_STRIKE) { + surface->MoveTo(rc.left, rc.top - 4); + surface->LineTo(rc.right, rc.top - 4); } else { // Either INDIC_PLAIN or unknown surface->MoveTo(rc.left, ymid); surface->LineTo(rc.right, ymid); |