aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2020-06-17 11:06:15 +1000
committerNeil <nyamatongwe@gmail.com>2020-06-17 11:06:15 +1000
commit5fc1282d6d4a18f8018bbdd769991eb93171757a (patch)
tree4d82ba7eeb38c2f52f204baa650c8f1226f7b9fc
parent0f0a8c1db9ef9909a93a94e008fbaf96e02ad78d (diff)
downloadscintilla-mirror-5fc1282d6d4a18f8018bbdd769991eb93171757a.tar.gz
Feature [feature-requests:1361]. Allow caret width to be up to 20 pixels.
-rw-r--r--doc/ScintillaDoc.html6
-rw-r--r--doc/ScintillaHistory.html4
-rw-r--r--src/Editor.cxx2
3 files changed, 8 insertions, 4 deletions
diff --git a/doc/ScintillaDoc.html b/doc/ScintillaDoc.html
index 786b6f27f..f4dfb1e06 100644
--- a/doc/ScintillaDoc.html
+++ b/doc/ScintillaDoc.html
@@ -3323,9 +3323,9 @@ struct Sci_TextToFind {
<p><b id="SCI_SETCARETWIDTH">SCI_SETCARETWIDTH(int pixelWidth)</b><br />
<b id="SCI_GETCARETWIDTH">SCI_GETCARETWIDTH &rarr; int</b><br />
The width of the line caret can be set with <code>SCI_SETCARETWIDTH</code> to a value of
- 0, 1, 2 or 3 pixels. The default width is 1 pixel. You can read back the current width with
- <code>SCI_GETCARETWIDTH</code>. A width of 0 makes the caret invisible (added at version
- 1.50), similar to setting the caret style to CARETSTYLE_INVISIBLE (though not interchangeable).
+ between 0 and 20 pixels. The default width is 1 pixel. You can read back the current width with
+ <code>SCI_GETCARETWIDTH</code>. A width of 0 makes the caret invisible,
+ similar to setting the caret style to CARETSTYLE_INVISIBLE (though not interchangeable).
This setting only affects the width of the cursor when the cursor style is set to line caret
mode, it does not affect the width for a block caret.</p>
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html
index 10e88fd2a..e8880ec71 100644
--- a/doc/ScintillaHistory.html
+++ b/doc/ScintillaHistory.html
@@ -588,6 +588,10 @@
<a href="https://sourceforge.net/p/scintilla/feature-requests/1355/">Feature #1355</a>.
</li>
<li>
+ Allow caret width to be up to 20 pixels.
+ <a href="https://sourceforge.net/p/scintilla/feature-requests/1361/">Feature #1361</a>.
+ </li>
+ <li>
Fix printing on Windows to use correct text size.
<a href="https://sourceforge.net/p/scintilla/bugs/2185/">Bug #2185</a>.
</li>
diff --git a/src/Editor.cxx b/src/Editor.cxx
index 12688da66..ad41b518d 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -7389,7 +7389,7 @@ sptr_t Editor::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam) {
return vs.caretStyle;
case SCI_SETCARETWIDTH:
- vs.caretWidth = std::clamp(static_cast<int>(wParam), 0, 3);
+ vs.caretWidth = std::clamp(static_cast<int>(wParam), 0, 20);
InvalidateStyleRedraw();
break;