Questions tagged [trichedit]

TRichEdit is a VCL control that wraps the Windows Rich Edit common control. It is defined in the ComCtrls.pas unit.

TRichEdit is a VCL control that wraps the Windows Rich Edit common control. It is defined in the ComCtrls.pas unit.

68 questions
1
vote
1 answer

How do I insert new, unformatted, lines at the top of a TRichEdit

I am using TRichEdit to hold the body of an emailing client. I've given the user simple formatting capabilities (bold, italic, underline, left, centre and right paragraph alignment and bullets. This works well to email formatted text as html using…
user2834566
  • 775
  • 9
  • 22
1
vote
2 answers

Delphi Copy Memo to Richedit problem

I am having a problem copying the contents of a memo to a richedit component. I thought it would be Richedit.text := memo.text; However if I use this the Richedit starts a new line when the memo text wraps to a new a new line (not CR/LF) but just…
colin
  • 2,983
  • 6
  • 41
  • 49
1
vote
2 answers

TRichEdit - How to add an empty line with size change?

I have array of strings and i want to add an empty line of lesser size between some of them. So i have a code: const _n=#13#10; //... r1.Lines.Clear; r1.SelAttributes.Size:=18; r1.SelText:='TEST'; r1.SelAttributes.Size:=6; …
Markus_13
  • 328
  • 2
  • 14
1
vote
0 answers

How to render and zoom RTF on canvas in Delphi

Hello I need to integrate formatted text into an older application written in Delphi where it would be rendered into the canvas (GDI - yes prehistoric technology, need to support Win Vista and later). I've tried to accomplish this with html and rtf…
Michal Vašut
  • 187
  • 2
  • 8
1
vote
0 answers

Delphi : Create a RichText in a formless unit

How do you mimick a TRichEdit in a formless unit? I want to be able to add formatted text to it. After all processes have been processes have been perform then the finally will pass the formatted data as a param to an actual TRichEdit... TIA
1
vote
4 answers

Delphi: Center Specific Line in TRichEdit by Scrolling

I have a Delphi 2007 TRichEdit with several lines in it. I want to scroll the richedit vertically such that a specific line number if approximately centered in the visible/display area of the richedit. For example, I want to write the code for…
Anagoge
  • 933
  • 1
  • 14
  • 23
1
vote
1 answer

Append formated text from SQL to TRichEdit

Can you help with this problem? How do I append a formatted txt from database field to a TRichEdit ? Just to clarify: I need to get the contents of 2 database fields that have formatted text (RTF) and put them in TrichEdit preserving the…
Sardukar
  • 247
  • 6
  • 16
1
vote
1 answer

How to change the font smoothing (anti-aliasing) quality of a RichEdit in Delphi?

I have a Delphi 7 application where I'm drawing text to a TBitmap. I need to be able to control the anti-aliasing quality of the text. For this purpose I'm using the following procedure: procedure SetFontQuality(Font: TFont; Quality: Byte); var …
jedivader
  • 828
  • 10
  • 23
1
vote
2 answers

TRichEdit not scrolling line-by-line

I first had a TMemo and when I grabbed the scrollbar thumb, the Memo content scrolled Line-by-line, meaning not smooth pixel-by-pixel. Then I switched over to use a TRichEdit control instead. But now it scrolls smooth, pixel-by-pixel. Is there a way…
Max Kielland
  • 5,627
  • 9
  • 60
  • 95
1
vote
1 answer

RichEdit paint background

I know how to change the background on a single row in a TRichEdit control. But because this is applied to the selected text only, I can't set the background color of the whole line (client left to client right), only to the text part. I tried to…
Max Kielland
  • 5,627
  • 9
  • 60
  • 95
1
vote
1 answer

delphi TRichEdit Set background color excluding spaces

I found this code over the net. This puts background color to the selected texts on Trichedit: uses RichEdit; procedure RE_SetSelBgColor(RichEdit: TRichEdit; AColor: TColor); var Format: CHARFORMAT2; begin FillChar(Format, SizeOf(Format), 0); …
junmats
  • 1,894
  • 2
  • 23
  • 36
1
vote
1 answer

How to call TRichEdit methods inside delphi procedures

I'm saluting everyone once again, of course, having another problem while coding. I written the following snippet: procedure add_text(text : String); begin MsgBox.SetFocus; MsgBox.SelStart := MsgBox.GetTextLen; MsgBox.Perform(EM_SCROLLCARET,…
Eduard
  • 3,395
  • 8
  • 37
  • 62
1
vote
1 answer

Multi-line control in VCL forms

I am using C++ Builder to create a VCL forms application and am wanting a multiline editbox. Am I correct in saying that I have to use a TRichEdit control to accomplish this? If so, (and I have added one just to try out), how do I set the text in…
user1690531
  • 231
  • 1
  • 6
  • 17
0
votes
1 answer

Richedit 2.0 control ignores WParam for WM_PAINT messages?

I've read a lot of issues with trying to double-buffer a richedit control, but have not seen any direct answers to this specific question (would be really great to have a quote/link where Microsoft has an official statement). Here is some code…
eselk
  • 6,764
  • 7
  • 60
  • 93
0
votes
0 answers

Print Richedit's contents with zoom <> 100% with Delphi 11.3

The TRichEdit control renders its contents on screen at various zoom values eg. 130% I want to do the same on any canvas eg. of a picture or on printer's canvas. Is there a way to do this programmatically ?
JimPapas
  • 715
  • 2
  • 12
  • 27