@@ -1138,7 +1138,11 @@ <h2>Programming API</h2>
11381138 shouldn't worry too much about sanitizing your coordinates. If you
11391139 give < code > ch</ code > a value of < code > null</ code > , or don't
11401140 specify it, it will be replaced with the length of the specified
1141- line.</ p >
1141+ line. Such positions may also have a < code > sticky</ code > property
1142+ holding < code > "before"</ code > or < code > "after"</ code > , whether the
1143+ position is associated with the character before or after it. This
1144+ influences, for example, where the cursor is drawn on a
1145+ line-break or bidi-direction boundary.</ p >
11421146
11431147 < p > Methods prefixed with < code > doc.</ code > can, unless otherwise
11441148 specified, be called both on < code > CodeMirror</ code > (editor)
@@ -2162,9 +2166,12 @@ <h3 id="api_static">Static properties</h3>
21622166 whenever the given < code > predicate</ code > returns true when
21632167 called with the local mode and editor.</ dd >
21642168
2165- < dt id ="Pos "> < code > < strong > CodeMirror.Pos</ strong > (line: integer, ?ch: integer)</ code > </ dt >
2166- < dd > A constructor for the < code > {line, ch}</ code > objects that
2167- are used to represent positions in editor documents.</ dd >
2169+ < dt id ="Pos "> < code > < strong > CodeMirror.Pos</ strong > (line: integer, ?ch: integer, ?sticky: string)</ code > </ dt >
2170+ < dd > A constructor for the objects that are used to represent
2171+ positions in editor documents. < code > sticky</ code > defaults to
2172+ null, but can be set to < code > "before"</ code >
2173+ or < code > "after"</ code > to make the position explicitly
2174+ associate with the character before or after it.</ dd >
21682175
21692176 < dt id ="changeEnd "> < code > < strong > CodeMirror.changeEnd</ strong > (change: object) → {line, ch}</ code > </ dt >
21702177 < dd > Utility function that computes an end position from a change
0 commit comments