diff options
author | Henrik Hank <unknown> | 2018-06-06 08:55:59 +1000 |
---|---|---|
committer | Henrik Hank <unknown> | 2018-06-06 08:55:59 +1000 |
commit | 2cfe83dc91dbbdd195b17b5446ce595f0c658db2 (patch) | |
tree | 89439af44aff139af5579281200c48fa9c1e1e20 /src/EditView.cxx | |
parent | c823cbe5c809df5f84a2ef0b867a0733f7568cf0 (diff) | |
download | scintilla-mirror-2cfe83dc91dbbdd195b17b5446ce595f0c658db2.tar.gz |
Backport: SC_WRAPINDENT_DEEPINDENT added to indent two tabs from previous line.
Backport of changeset 7024:72c92ed3dc10.
Diffstat (limited to 'src/EditView.cxx')
-rw-r--r-- | src/EditView.cxx | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/EditView.cxx b/src/EditView.cxx index 7616324f1..10a264d27 100644 --- a/src/EditView.cxx +++ b/src/EditView.cxx @@ -522,10 +522,16 @@ void EditView::LayoutLine(const EditModel &model, Sci::Line line, Surface *surfa width -= static_cast<int>(vstyle.aveCharWidth); // take into account the space for end wrap mark } XYPOSITION wrapAddIndent = 0; // This will be added to initial indent of line - if (vstyle.wrapIndentMode == SC_WRAPINDENT_INDENT) { - wrapAddIndent = model.pdoc->IndentSize() * vstyle.spaceWidth; - } else if (vstyle.wrapIndentMode == SC_WRAPINDENT_FIXED) { + switch (vstyle.wrapIndentMode) { + case SC_WRAPINDENT_FIXED: wrapAddIndent = vstyle.wrapVisualStartIndent * vstyle.aveCharWidth; + break; + case SC_WRAPINDENT_INDENT: + wrapAddIndent = model.pdoc->IndentSize() * vstyle.spaceWidth; + break; + case SC_WRAPINDENT_DEEPINDENT: + wrapAddIndent = model.pdoc->IndentSize() * 2 * vstyle.spaceWidth; + break; } ll->wrapIndent = wrapAddIndent; if (vstyle.wrapIndentMode != SC_WRAPINDENT_FIXED) |