VisualPosition () { int offset = getOffset(); VisualPosition pos = myEditor.offsetToVisualPosition(offset); List<Inlay<?>> inlays = myEditor.getInlayModel().getInlineElementsInRange(offset, offset); int order = inlays.indexOf(this); return new VisualPosition(pos.line, pos.column + order, true); }