snow Posted March 23, 2022 Share Posted March 23, 2022 Hello, I have a TUniDBGrid where RowHeight and FontSize are changed during runtime. Changing RowHeight works for the normal rows but not for the header row. 1.) Is it possible to change RowHeight for the header during runtime as well? If yes, how? 2.) After changing RowHeight/Font, the text inside the cells isn't displayed correctly anymore (see attached picture). How can this be solved (for header and normal cells)? Using Professional Edition v1.90.0.1545 Thanks in advance. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted March 23, 2022 Share Posted March 23, 2022 1 hour ago, snow said: 2.) After changing RowHeight/Font, the text inside the cells isn't displayed correctly anymore (see attached picture). How can this be solved (for header and normal cells)? Hello, Can you try this CSSs? .x-column-header { line-height: normal; } .x-column-header-text-wrapper { vertical-align: top; } Quote Link to comment Share on other sites More sharing options...
snow Posted March 23, 2022 Author Share Posted March 23, 2022 Hi Sherzod, thanks for the reply. Using .x-column-header { line-height: normal; } the header looks like its supposed to be. But the text in normal cells is not vertically centered and it's also not showing properly (lower part is cut). How can this be solved? Quote Link to comment Share on other sites More sharing options...
snow Posted March 23, 2022 Author Share Posted March 23, 2022 Quote Link to comment Share on other sites More sharing options...
Sherzod Posted March 23, 2022 Share Posted March 23, 2022 1 hour ago, snow said: But the text in normal cells is not vertically centered and it's also not showing properly (lower part is cut). How can this be solved? Can you please make a simple testcase to check? Quote Link to comment Share on other sites More sharing options...
snow Posted March 23, 2022 Author Share Posted March 23, 2022 I made a simple testcase (see attachment)... but as it is a DBGrid you have to fill it with data somehow. Thanks in advance. example.zip Quote Link to comment Share on other sites More sharing options...
Sherzod Posted March 23, 2022 Share Posted March 23, 2022 Ok thanks. I will try to check. Quote Link to comment Share on other sites More sharing options...
snow Posted March 24, 2022 Author Share Posted March 24, 2022 Hi Sherzod, I've created another test project (including a SQLite database) so the problem should be immediately reproducable. As you can see, the text in the normal cells isn't displayed properly... should be vertically centered and not cut. Thanks in advance for your help. Regards Project1.zip Quote Link to comment Share on other sites More sharing options...
Hayri ASLAN Posted March 24, 2022 Share Posted March 24, 2022 59 minutes ago, snow said: Hi Sherzod, I've created another test project (including a SQLite database) so the problem should be immediately reproducable. As you can see, the text in the normal cells isn't displayed properly... should be vertically centered and not cut. Thanks in advance for your help. Regards Project1.zip 7.7 kB · 0 downloads Hello Please use below css .x-grid-td { line-height: normal; } Quote Link to comment Share on other sites More sharing options...
snow Posted March 24, 2022 Author Share Posted March 24, 2022 Thanks! Text in normal cells is now not cut anymore but still showing with a vertical top alignment. You can see that when you set grdAuswahl.Font.Size to e.g. 15 in UniFormBeforeShow. How to accomplish a vertically centered alignment? Regards Quote Link to comment Share on other sites More sharing options...
snow Posted March 24, 2022 Author Share Posted March 24, 2022 That did the trick: .x-grid-td { line-height: normal; vertical-align: middle; } Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.