|
|
|
@ -2247,7 +2247,7 @@ void Editor::DrawLine(Surface *surface, ViewStyle &vsDraw, int line, int lineVis
|
|
|
|
|
// the color for the highest numbered one is used.
|
|
|
|
|
bool overrideBackground = false; |
|
|
|
|
ColourAllocated background; |
|
|
|
|
if (caret.active && vsDraw.showCaretLineBackground && (vsDraw.caretLineAlpha == SC_ALPHA_NOALPHA) && ll->containsCaret) { |
|
|
|
|
if ((caret.active || vsDraw.showCaretLineBackgroundAlways) && vsDraw.showCaretLineBackground && (vsDraw.caretLineAlpha == SC_ALPHA_NOALPHA) && ll->containsCaret) { |
|
|
|
|
overrideBackground = true; |
|
|
|
|
background = vsDraw.caretLineBackground.allocated; |
|
|
|
|
} |
|
|
|
@ -2630,7 +2630,7 @@ void Editor::DrawLine(Surface *surface, ViewStyle &vsDraw, int line, int lineVis
|
|
|
|
|
// Draw any translucent whole line states
|
|
|
|
|
rcSegment.left = xStart; |
|
|
|
|
rcSegment.right = rcLine.right - 1; |
|
|
|
|
if (caret.active && vsDraw.showCaretLineBackground && ll->containsCaret) { |
|
|
|
|
if ((caret.active || vsDraw.showCaretLineBackgroundAlways) && vsDraw.showCaretLineBackground && ll->containsCaret) { |
|
|
|
|
SimpleAlphaRectangle(surface, rcSegment, vsDraw.caretLineBackground.allocated, vsDraw.caretLineAlpha); |
|
|
|
|
} |
|
|
|
|
int marks = pdoc->GetMark(line); |
|
|
|
@ -3174,6 +3174,7 @@ long Editor::FormatRange(bool draw, RangeToFormat *pfr) {
|
|
|
|
|
vsPrint.whitespaceBackgroundSet = false; |
|
|
|
|
vsPrint.whitespaceForegroundSet = false; |
|
|
|
|
vsPrint.showCaretLineBackground = false; |
|
|
|
|
vsPrint.showCaretLineBackgroundAlways = false; |
|
|
|
|
|
|
|
|
|
// Set colours for printing according to users settings
|
|
|
|
|
for (size_t sty = 0;sty < vsPrint.stylesSize;sty++) { |
|
|
|
@ -6983,6 +6984,13 @@ sptr_t Editor::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam) {
|
|
|
|
|
vs.showCaretLineBackground = wParam != 0; |
|
|
|
|
InvalidateStyleRedraw(); |
|
|
|
|
break; |
|
|
|
|
case SCI_GETCARETLINEVISIBLEALWAYS: |
|
|
|
|
return vs.showCaretLineBackgroundAlways; |
|
|
|
|
case SCI_SETCARETLINEVISIBLEALWAYS: |
|
|
|
|
vs.showCaretLineBackgroundAlways = wParam != 0; |
|
|
|
|
InvalidateStyleRedraw(); |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case SCI_GETCARETLINEBACK: |
|
|
|
|
return vs.caretLineBackground.desired.AsLong(); |
|
|
|
|
case SCI_SETCARETLINEBACK: |
|
|
|
|