3

I need to fit the size of the text automatically within a box with predefined sizes. I have a minimum font size for little text and I want to reduce the size for large texts, as can be seen in the figure below.

P.S. I do not know how many words the text will have.

enter image description here

  • 1
    (1) Resizing text like this is officially evil. (2) What have you tried? (3) I can't see your picture, only 'enter image description here'. – cfr Jun 08 '17 at 23:46
  • Of course, you mean that you have a maximum font size for short text and you want to reduce the size for longer texts. I see essentially only one way, using a loop: typeset the text in a temporary parbox, measure its height, if it is too high then reduce the font size and start over, otherwise you are done, place the box (or “unvbox” it) where it is meant to go. – GuM Jun 08 '17 at 23:57
  • 4
    https://tex.stackexchange.com/search?q=text+fit+box+ – egreg Jun 09 '17 at 00:05
  • Related: https://tex.stackexchange.com/questions/123614/making-the-text-fit-in-a-specific-space-in-latex – Steven B. Segletes Jun 09 '17 at 00:50

0 Answers0