mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-53596 Soft wrap for editors
Added explicit check for invalid (non-positive) tabulation size (occurs at least at tests).
This commit is contained in:
@@ -407,6 +407,9 @@ public class EditorUtil {
|
||||
}
|
||||
|
||||
public static int nextTabStop(int x, Editor editor, int tabSize) {
|
||||
if (tabSize <= 0) {
|
||||
return x + getSpaceWidth(Font.PLAIN, editor);
|
||||
}
|
||||
tabSize *= getSpaceWidth(Font.PLAIN, editor);
|
||||
|
||||
int nTabs = x / tabSize;
|
||||
|
||||
Reference in New Issue
Block a user