Solved

About Line Spacing in TRichEdit

Posted on 1998-10-15
6
1,110 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

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…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

728 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