Skip to content

Commit

Permalink
Move "show wrap symbol in line number margin" to "show visual indicat…
Browse files Browse the repository at this point in the history
…ors after wrap" ComboBox.
  • Loading branch information
zufuliu committed Dec 2, 2018
1 parent a267648 commit a51d360
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions src/Edit.h
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,14 @@ enum {
EditWrapSymbolBeforeNone = 0,
EditWrapSymbolBeforeNearText = 1,
EditWrapSymbolBeforeNearBorder = 2,
EditWrapSymbolLineNumberMargin = 3,

EditWrapSymbolAfterNone = 0,
EditWrapSymbolAfterNearText = 1,
EditWrapSymbolAfterNearBorder = 2,
EditWrapSymbolLineNumberMargin = 3,

EditWrapSymbolBeforeMaxValue = EditWrapSymbolLineNumberMargin,
EditWrapSymbolAfterMaxValue = EditWrapSymbolAfterNearBorder,
EditWrapSymbolBeforeMaxValue = EditWrapSymbolBeforeNearBorder,
EditWrapSymbolAfterMaxValue = EditWrapSymbolLineNumberMargin,

EditWrapSymbolMaxValue = EditWrapSymbolBeforeMaxValue + 10 * EditWrapSymbolAfterMaxValue,
EditWrapSymbolDefaultValue = EditWrapSymbolBeforeNearBorder,
Expand Down
14 changes: 7 additions & 7 deletions src/Notepad2.c
Original file line number Diff line number Diff line change
Expand Up @@ -1524,13 +1524,6 @@ void SetWrapVisualFlags(void) {
case EditWrapSymbolBeforeNearBorder:
wrapVisualFlags |= SC_WRAPVISUALFLAG_END;
break;
case EditWrapSymbolLineNumberMargin:
wrapVisualFlags |= SC_WRAPVISUALFLAG_MARGIN;
if (!bShowLineNumbers) {
bShowLineNumbers = TRUE;
UpdateLineNumberWidth();
}
break;
}
switch (iWordWrapSymbols / 10) {
case EditWrapSymbolAfterNearText:
Expand All @@ -1540,6 +1533,13 @@ void SetWrapVisualFlags(void) {
case EditWrapSymbolAfterNearBorder:
wrapVisualFlags |= SC_WRAPVISUALFLAG_START;
break;
case EditWrapSymbolLineNumberMargin:
wrapVisualFlags |= SC_WRAPVISUALFLAG_MARGIN;
if (!bShowLineNumbers) {
bShowLineNumbers = TRUE;
UpdateLineNumberWidth();
}
break;
}
SendMessage(hwndEdit, SCI_SETWRAPVISUALFLAGSLOCATION, wrapVisualFlagsLocation, 0);
SendMessage(hwndEdit, SCI_SETWRAPVISUALFLAGS, wrapVisualFlags, 0);
Expand Down
4 changes: 2 additions & 2 deletions src/Notepad2.rc
Original file line number Diff line number Diff line change
Expand Up @@ -1176,8 +1176,8 @@ BEGIN
DEFPUSHBUTTON "OK",IDOK,137,79,50,14
PUSHBUTTON "Cancel",IDCANCEL,193,79,50,14
LTEXT "No wrap indent|Wrap indent by 1 character|Wrap indent by 2 characters|Wrap indent by 1 level|Wrap indent by 2 levels|Wrap indent same as first subline|Wrap indent 1 level more than first subline|Wrap indent 2 levels more than first subline",IDC_WRAP_INDENT_OPTIONS,0,0,615,8,NOT WS_VISIBLE
LTEXT "No visual indicators before wrap|Show visual indicators before wrap (near text)|Show visual indicators before wrap (near borders)|Show visual indicators in line number margin",IDC_WRAP_SYMBOL_BEFORE_OPTIONS,0,0,418,8,NOT WS_VISIBLE
LTEXT "No visual indicators after wrap|Show visual indicators after wrap (near text)|Show visual indicators after wrap (near borders)",IDC_WRAP_SYMBOL_AFTER_OPTIONS,0,0,402,8,NOT WS_VISIBLE
LTEXT "No visual indicators before wrap|Show visual indicators before wrap (near text)|Show visual indicators before wrap (near borders)",IDC_WRAP_SYMBOL_BEFORE_OPTIONS,0,0,418,8,NOT WS_VISIBLE
LTEXT "No visual indicators after wrap|Show visual indicators after wrap (near text)|Show visual indicators after wrap (near borders)|Show visual indicators after wrap (in line number margin)",IDC_WRAP_SYMBOL_AFTER_OPTIONS,0,0,402,8,NOT WS_VISIBLE
LTEXT "No wrap|Wrap text between words|Wrap text between any characters|Wrap text on whitespace",IDC_WRAP_MODE_OPTIONS,0,0,187,8,NOT WS_VISIBLE
END

Expand Down

0 comments on commit a51d360

Please sign in to comment.