| View previous topic :: View next topic |
| Author |
Message |
Neil Guest
|
Posted: Wed Dec 24, 2003 9:29 am Post subject: Form's Caption |
|
|
Is there any way to check if a Form's Caption is too long i.e. not all the
caption will be displayed so I can change to caption to something shorter?
Thanks
Neil
|
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Wed Dec 24, 2003 9:26 pm Post subject: Re: Form's Caption |
|
|
"Neil" <no address> wrote
| Quote: | Is there any way to check if a Form's Caption is too long i.e.
not all the caption will be displayed so I can change to caption
to something shorter?
|
There is no direct way to query that. You will have to calculate it
manually. Have a look at the GetDC() and GetTextExtentPoint32() functions
in the Win32 API. You might also need to use GetSystemMetrics() to take
window and caption borders into account as well.
Gambit
|
|
| Back to top |
|
 |
|