Solved

About Line Spacing in TRichEdit

Posted on 1998-10-15
6
1,092 Views
Last Modified: 2008-03-17
Is it possible to change line spacing in TRichEdit, from 1.0
  to 1.5 or 2.0?
  If it is possible, then would you give me the example (in
  source code) of how to do it?
  I use Delphi 3, so please keep the source code work in Delphi 3.

Thanks anyway for the help and attention ^_^

Stinger
0
Comment
Question by:stinger_60284
  • 2
  • 2
  • 2
6 Comments
 
LVL 4

Accepted Solution

by:
BoRiS earned 50 total points
ID: 1343103
stinger_60284

here is the code to do just that, only selected text...

var
  format: TCharFormat;
 begin                      
  FillChar( DblSpace, sizeof(DblSpace), 0);
    with format do begin
      cbSize:= Sizeof(DblSpace);
      dwMask:= CFM_OFFSET;
      yOffset:= 60;
    end;
  RichEdit1.Perform( EM_SETCHARFORMAT, SCF_SELECTION,
                    LongInt(@DblSpace));

Later
BoRiS
0
 
LVL 10

Expert Comment

by:viktornet
ID: 1343104
Hello BoRiS :->

.And what type is DblSpace is suppose to be??? Integer?? //just an example
0
 

Author Comment

by:stinger_60284
ID: 1343105
Is it just for the selected text?
How to convert it to the everyline in TRichEdit?
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 4

Expert Comment

by:BoRiS
ID: 1343106
stinger_60284

RichEdit1.SelectAll; //will select all the lines and text then call the procedure I gave you

viktornet

Sorry :-)

that should be

var
 DblSpace: TCharFormat;
begin
..

Later
BoRiS
0
 
LVL 10

Expert Comment

by:viktornet
ID: 1343107
10x :-)
0
 

Author Comment

by:stinger_60284
ID: 1343108
Great!!! Thanks for the answer!!!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Windows Drag & Drop Location 2 94
Delphi with SQL Natvie Client 15 85
build html 5 client that connect to indy Tidtcpserver 3 350
Adoquery sql  left join does not work 25 80
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…
Send secure, cloud-based, encrypted alerts and maintain HIPAA compliant messaging. Integrates priority & secure messaging into one application. Ensures IT, emergency respondents and healthcare professionals that their critical messages are never mis…

911 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

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now