?
Solved

About Line Spacing in TRichEdit

Posted on 1998-10-15
6
Medium Priority
?
1,114 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 200 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
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
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

Technology Partners: 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

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses
Course of the Month8 days, 12 hours left to enroll

764 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