resizing small text, keep it centered?

Started by spyrule, July 23, 2013, 07:24:43 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


Hey guys,

I'm doing a very large data-center diagramming and because of the sheer amount of information I have to track(1 rack per 8x11" sheet), I'm stuck using very small 6pt fonts.
One of the issues I'm running into, and I do not know how to avoid it; is resizing text area so that the text remains centered in the resized box (see attached image for reference).

Now, the only reason I'm doing this is because I am creating some of my own shapes, and it's easier to move around a group of shapes if their areas are more easily discernable. If I put a text over a circle for example, with the normal sized box, I have a huge left-side of the text box that I can grab with, however I don't WANT that extra space.

Any help is appreciated on how to avoid this.


When you go into the textformat or texttransform section of the shapesheet of such a shape, you can see that there are cells for padding. Left, right, top, bottom. Maybe a too big value there is the problem?


yeah, I changed that, and set them all to zero... not sure why it was set that high (4pt), however it still ends up with the text at the bottom, with a really high space above the text. Although that's easier to work with.


You could try adjusting the height of the texbox using a formula ala =Textheight(TheText)...


It looks like the textbox is too small for the font size to behave in a predictable fashion.  Adding to what Jumpy said, place the following formula to the Txtwidth cell (in TextTransform section):  textwidth(TheText).  Then, you need to play with the formulas for TxTLocPinX and TxtLocPinY.

For example, the TxtLocPinX might get a formula:  =MAX(Char.Size/4,TxtWidth/2).  This should correct for single or multiple characters.  There may be issues with single char, hence Char.Size/4.  Oh, you may also have to work with the TxtPinX settings too.

Since the behavior is less than predictable, you may have to adjust the entries to get an acceptable solution.  Don't be surprised if it's also sensitive to the font selected.

Good text behavior reference:

Visio 2019 Pro