On 02/25/2017 07:30 PM, Ken Springer wrote: > Scribus 1.4.6 > Windows 7 > > I want to center a line of text in a frame. But so far have not found a > reliable way to do this. > > I didn't find any easily selectable option, but for a couple of frames I > could "fake it" by using the baseline offset in advanced settings. > > But with frames of a lower height, it doesn't work. > > I found a script here that claimed to do it, > http://superuser.com/questions/231576/scribus-vertically-align-text-within-a-text-framed, > but it doesn't. > > Is it even possible in 1.4.6? What about 1.5.2? For the current > project, 1.5.2 is not an option but I would like to know if it can be done. > > In the 1.5.x series, there is now a setting for this. In the text tab or Properties or Text Properties palette (1.5.3svn), under Columns and Text Distances, at the top you will see Vertical Alignment, with choices of Top, Middle, and Bottom.
For the 1.4.x versions, I did create a script that will center text vertically: https://wiki.scribus.net/canvas/Centering_text_vertically_in_a_frame which works pretty well. What it does is use the linespacing, the number of lines of text, the height of the frame, and divides the leftover space in two and uses that to set the Top Distance. It can also be recursive, for example, if you run it, but then add some more text, you can rerun the script to reset the Top Distance. Greg