Skip to content

Round the completion item text width correctly#9032

Merged
mbien merged 1 commit intoapache:masterfrom
mbien:correctly-round-completion-item-width
Nov 22, 2025
Merged

Round the completion item text width correctly#9032
mbien merged 1 commit intoapache:masterfrom
mbien:correctly-round-completion-item-width

Conversation

@mbien
Copy link
Member

@mbien mbien commented Nov 22, 2025

Text does sometimes not fit into the computed bounds of the completion item using certain fonts.

Store the width as double and round the sum up to the nearest int.

before:
image

after:
image

font: Source Code Pro Medium 13

Text does sometimes not fit into the computed bounds of the completion
item using certain fonts.

Store the width as double and round the sum up to the nearest int.
@mbien mbien added this to the NB29 milestone Nov 22, 2025
@mbien mbien added Editor ci:dev-build [ci] produce a dev-build zip artifact (7 days expiration, see link on workflow summary page) Java [ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form) labels Nov 22, 2025
@apache apache locked and limited conversation to collaborators Nov 22, 2025
@apache apache unlocked this conversation Nov 22, 2025
Copy link
Member

@neilcsmith-net neilcsmith-net left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So, not just one rounding down error, but multiple!

Looks good at glance. Thanks.

@mbien mbien merged commit 105a1e4 into apache:master Nov 22, 2025
36 of 62 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:dev-build [ci] produce a dev-build zip artifact (7 days expiration, see link on workflow summary page) Editor Java [ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants