summaryrefslogtreecommitdiffstats
path: root/WebCore/editing/SelectionController.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/editing/SelectionController.cpp')
-rw-r--r--WebCore/editing/SelectionController.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/WebCore/editing/SelectionController.cpp b/WebCore/editing/SelectionController.cpp
index 00672f2..af89ccb 100644
--- a/WebCore/editing/SelectionController.cpp
+++ b/WebCore/editing/SelectionController.cpp
@@ -994,11 +994,14 @@ void SelectionController::paintCaret(GraphicsContext* p, int tx, int ty, const I
IntRect caret = intersection(drawingRect, clipRect);
if (!caret.isEmpty()) {
Color caretColor = Color::black;
+ ColorSpace colorSpace = DeviceColorSpace;
Element* element = rootEditableElement();
- if (element && element->renderer())
+ if (element && element->renderer()) {
caretColor = element->renderer()->style()->color();
+ colorSpace = element->renderer()->style()->colorSpace();
+ }
- p->fillRect(caret, caretColor);
+ p->fillRect(caret, caretColor, colorSpace);
}
}