You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm writing text into a canvas (using it as part of a terminal solution, so with a terminal font) but can't seem to find a consistantly accurate way of calculating the screen size to readjust the canvas size to the content. Am I missing something that would automatically snap the canvas size to the content size or maybe a maximum width/height used in the canvas? Alternatively, has anyone a suggestion as to how to accurately calculate the required width/height based on the font size?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I'm writing text into a canvas (using it as part of a terminal solution, so with a terminal font) but can't seem to find a consistantly accurate way of calculating the screen size to readjust the canvas size to the content. Am I missing something that would automatically snap the canvas size to the content size or maybe a maximum width/height used in the canvas? Alternatively, has anyone a suggestion as to how to accurately calculate the required width/height based on the font size?
Beta Was this translation helpful? Give feedback.
All reactions