I'm looking for a quick way to cap a String to a x number of characters, and at the same time, if the said String has less than x characters I would like to fill up the String with blanks so that its length becomes x.
Some examples (x = 20 chars):
"The brown fox"
should say: "The brown fox_______"
"The brown fox jumps over jumps over the lazy dog."
should say: "The brown fox jumps "