Принудительно подогнать высоту шрифта с помощью CSS или JS [дубликат] ⇐ CSS

Разбираемся в CSS
Anonymous
Принудительно подогнать высоту шрифта с помощью CSS или JS [дубликат]

Сообщение Anonymous »


This has been asked long ago in about 2010, but the answers are outdated. I would like to force a font to fit in both height and width.

Currently I have this code:

MY TEXT Using one of the suggestions found: textFit or any of the other similar scripts.
I can do the following:


Изображение


What I would like to achieve is to be able to force it (even though it's unproportional) to do something like this:


Изображение


It can be in js or css. Whichever this way could be accomplished. Any ideas?


Источник: https://stackoverflow.com/questions/585 ... -css-or-js

Вернуться в «CSS»