diff --git a/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionCloseBracketSegment.java b/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionCloseBracketSegment.java index 40ede51a..a7ebb9d0 100644 --- a/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionCloseBracketSegment.java +++ b/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionCloseBracketSegment.java @@ -60,7 +60,7 @@ public void render(final GC gc, final int currentCaretOffset) { // educated guess: int endPadding = gc.getAdvanceWidth(symbol) / 4; y = (invocationLine + lineInSuggestion + 1) * lineHt - fontHt; - x = gc.textExtent(text).x + endPadding; + x = gc.textExtent(text).x; if (lineInSuggestion == 0) { x += widget.getLocationAtOffset(invocationOffset).x; } diff --git a/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionNormalSegment.java b/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionNormalSegment.java index c1b2e77e..de7481dc 100644 --- a/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionNormalSegment.java +++ b/plugin/src/software/aws/toolkits/eclipse/amazonq/util/QInlineSuggestionNormalSegment.java @@ -66,7 +66,7 @@ public void render(final GC gc, final int currentCaretOffset) { textToRender = text; x = widget.getLeftMargin(); } else { - x = gc.textExtent(text.substring(0, idxInLine)).x + gc.textExtent(" ").x / 4; + x = gc.textExtent(text.substring(0, idxInLine)).x; textToRender = text.substring(idxInLine); }