Solved

Delphi Multiple Line Form Caption

Posted on 2006-11-12
4
698 Views
Last Modified: 2010-08-05
Good day,

Is it possible to add a multiple line caption to my form.

I tried to use  : form1.Caption := 'Top line'+#13#10+'Bottom Line';
But it does not work.

Can you also center text exactly on a form caption e.g. I need text on my left and exaclty in the middle some other text, and on my right some text.

Thanx

Henry
0
Comment
Question by:henryreynolds
  • 2
4 Comments
 
LVL 9

Expert Comment

by:sun4sunday
ID: 17928275
It is not possible to multiple line on a the form.

>>Can you also center text exactly on a form caption
Do you mean to center the caption of the from in the middle. That can be done at runtime.
First take the width of the text, take almost half of its width then put spaces beofre the caption of the form. It will come almost the middle.

sun4sunday
0
 
LVL 10

Accepted Solution

by:
atul_parmar earned 50 total points
ID: 17928356
It is possible. However, the caption should have enough space to accomodate the lines. or you need to smaller the font size.
see http://delphi.about.com/od/adptips2006/qt/draw_captionbar.htm
0
 

Author Comment

by:henryreynolds
ID: 17928461
Hi sun4sunday , atul_parmar

Thank you both for your reply, but I must give the points to atul_parmar, because it work's 100% for me.

Enjoy your day

Henry

0
 
LVL 9

Expert Comment

by:sun4sunday
ID: 17928792
Thanks Atul for the info and Henry for asking this question. This getting update my delphi knowledge

sun4sunday
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question