Solved

How to add a footnote into a RichEdit?

Posted on 1998-04-26
4
354 Views
Last Modified: 2013-11-22
When I load a *.rtf file with footnote into the richedit, the footnote displays right. And then, if I copy the
footnote and paste it to the other place of the RichEdit
the result is right again. It's Fine. But how I make
the footnote myself, and then put it into the clean richedit?
It is easy to set usual styles like Bold, Italic ext.
but how about the footnote? I think, there must be some
solution becouse the footnote will display right if
I copy exists footnote or load it from the rtf-file.

- Rauno -
0
Comment
Question by:raunol
  • 2
  • 2
4 Comments
 
LVL 8

Accepted Solution

by:
ZifNab earned 100 total points
Comment Utility
Hi raunol,

I found this on the net :

Peter Below wrote :

Steve,

                           the richedit control supports only a subset of RTF and footnotes are not
                           among them. So you would need to post-process the produced RTF file. You can
                           find the RTF specs as far as it is supported by the help compiler in the
                           hcw.hlp file in your help\tools directory under the Delphi root. The full RTF
                           specs can be found on Microsofts website or the MSDN Library CD.

                           Peter Below (TeamB) 100113.1101@compuserve.com)

Regards, ZiF.
0
 

Author Comment

by:raunol
Comment Utility
Hi,

Thank's about Your answer. Do it mean in practic that
I first save rtf-file, and then I manipulate the file and
add footnote-code? It will work, but is complicated.

Rtf-specks I have, but the problem was
how to get the TRichEdit working straight so that
it understand footnotes? Like I asked, the
control reads footnotes from the file and after
then also displays them correctly, but do You know
how I can just write footnotes my self? If I
write rtf-code "/footnote" to richedit it
will display as text, not like it should.
Also SaveToFile-method adds double "//" mark for
my "/footnote", so the code I wrote corrupted.

Stupid that there are in TTextAttributes only bold,
italic and single underlying. Can I add more styles?

RichEdit-component doesn't display correctly for example double-underlying, but footnotes it displays correctly!
So I think there must be some way to write text with footnotes self too, so that they display correctly in the control, not only then when I read them from the file. Hopeless I explaned understandably, mostly I speak Finnish ;-)

- Rauno -

0
 
LVL 8

Expert Comment

by:ZifNab
Comment Utility
Hi raunol,

As far as I know, you've to make an enhanced TRichEdit, if you want these functions. Maybe some authors already made such a RichEdit.... Look at Delphi Super Page and Torries for example..

Regards, ZiF.
0
 

Author Comment

by:raunol
Comment Utility
Hi, zif

Ok, thanks for Your comment and answer.
(Btw, in the pages You mentioned, there are a lot of
 interesting for delphi)

- Rauno -
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
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…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

744 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

13 Experts available now in Live!

Get 1:1 Help Now