Home » U++ Library support » RichText,QTF,RTF... » QTF Centered in ArrayCtrl header
QTF Centered in ArrayCtrl header [message #56872] |
Fri, 23 April 2021 16:42 |
mdelfede
Messages: 1307 Registered: September 2007
|
Ultimate Contributor |
|
|
Hi,
this ljne
kCtrl.AddColumn(t_("\1[G1= Service&class]")).Margin(0).NoEdit().HeaderTab();
Should add a centered text inside a ArrayCtrl column header... it used to work last time I
compiled my application; now it doesn't and displays a blank line.
Something is happening, because if I change text size (example G6) it does increase the cell,
but the content is blank.
If I remove the '=' :
kCtrl.AddColumn(t_("\1[G1 Service&class]")).Margin(0).NoEdit().HeaderTab();
it works, but of course the text is left-justified.
It's a bug or am I missing something ?
EDIT: I tested also with < (left align) and it works; > (right align) doesn't. It seems that the cell width
is wrong when calculating text position.
EDIT2:
Modifying the code as:
kCtrl.AddColumn(t_("\1[G1 Service&class]")).Margin(0).NoEdit().HeaderTab().SetAlign(ALIGN_CENTER);
(so, semove the '=' and add SetAlign() call) the text is 'centered', i.e. the first line ('Service') is centered
but the second is left aligned with 'Service' word:
and not
[Updated on: Fri, 23 April 2021 16:54] Report message to a moderator
|
|
|
|
|
|
|
Goto Forum:
Current Time: Sat Apr 20 05:16:01 CEST 2024
Total time taken to generate the page: 0.02480 seconds
|