Hi,
How do I Center the title text of a main window ?
It seems that the title text is always justified left.
I'm using PB2019 R2 /Windows 10
Thanks
Steen :-)
Hi,
How do I Center the title text of a main window ?
It seems that the title text is always justified left.
I'm using PB2019 R2 /Windows 10
Thanks
Steen :-)
With no role of ours, in a client's computer the title is CENTERED. In all other places the title is left aligned. We are trying to find out the settings that makes this change, not succeeded. Should be some settings in the windows, as we have done nothing to center it and also in all other places, it is left aligned.
As mentioned in another post, Ultimate Suite has window objects that allow you to do this:
https://www.pbultimatesuite.com/EN/modernize-pb-interface/single-page-application.html
Hi Steen;
As John correctly stated, it's an MS-Windows O/S controlled area and always left justified.
However, with a little creative PowerScripting on the ReSize event to Left Pad the title with spaces you should be able to "emulate" the centering. Just take the NewWidth argument value and calculate the Title Text length to compute the number of Space(nn) values that you need for padding.
Food for thought. HTH
Regards ... Chris
Greetings, Steen -
The text in a window title (the Windows O/S refers to this as the "caption") is left-justified because that is the default style as defined by Windows. There is an extended window style bit for right-justified, but there is no window style or extended window style bit for centering the caption that I could find in the Windows API documentation.
If you know of an application that does this, the app is likely rendering its own title/caption area.
Regards, John