Vertical alignment in a single-line TextEditor


#1

Hi,

We use an automatically computed layout in a few places, which causes some text editors to be slightly taller than others. If we use the default indents for the editors this causes the text to be vertically off-centre, which looks weird.

Is there support for vertically aligning text in a single-line text editor? Right now we can use the indents but then we need to keep the indent, font size and editor size in sync. Maybe we can add some automatic mode for the vertical inset which keeps the text centred.


Roeland


#2

No explicit support for changing the Y position, but could be something we can add… Maybe suggest a change that does what you need?


#3

This is a feature request that dates back to 2009, I think it is time to implement this already (mentioned at least here, there and there again

I think the most general approach would also be the simplest one: provide a setJustification() method in analogy with the one in Label


#4

Bumping this thread as I just hit this issue again…


#5

…and once again.
The lack becomes obvious especially when you use it beside a label where you can set a “layout” property to “centred right” etc.

or did I miss something? Am on Projucer 5.3.1…