This repository has been archived by the owner on Apr 1, 2020. It is now read-only.
Fix #453: Prevent text from wrapping in editor elements #469
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue: In some cases, the spans for text content are sized just a bit too small, causing the text to wrap
Defect: It seems that in some cases, with fractional fonts, there are fractional errors in the calculation that cause the element to be sized just a bit too small. This does not reproduce for all fonts / environments.
Fix: Experimented with a few different ways to fix this:
Math.ceil
for the calculation). This didn't work in all caseswhitespace: nowrap
to the elements to prevent wrappingThe latter fix seemed to work reliably, and there was not a performance regression based on my testing, so I went with that scoped fix.