P
P
pcdesign2018-07-16 12:18:44
Algorithms
pcdesign, 2018-07-16 12:18:44

How to choose the font size depending on the length of the text?

If the text length is more than 10 thousand characters - font size 14 (this is the minimum)
If the text length is less than 50 characters - font size 32 (this is the maximum)
What will the font size be if the text comes in 2000 characters?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander Movchan, 2018-07-16
@pcdesign

Interpolation .

R
Roman Mirilaczvili, 2018-07-16
@2ord

With interpolation, you will need to choose a font, say 14.7pt (so choose 14 or 16 pt?).
If in CSS + JS, then you can do this:
https://css-tricks.com/set-font-size-based-on-word...
bigandsmallquote.png

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question