summaryrefslogtreecommitdiff
path: root/docview/components/richtext/README.txt
blob: df0ed03e6e0fe3f300f72a9e9cec96c9d771ea66 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
TRichTextView component
for fpGUI Toolkit

Summary
-------

This component displays 'rich' text, with various fonts, colors, 
styles and alignment.

The major features are:
  Fast, accurate drawing of text

Features to come...
  Selection and copy
  Built-in default popup menu


Using the component
-------------------

Put a component on your form. Adjust the properties as you see fit.
At runtime, load the text into the control using AddText, AddParagraph, 
and Clear. 

Formatting syntax

This is a HTML-like set of tags. But note that tag pairs don't have to
match up.

  <b> </b>       bold on, off
  <u> </u>       underline on, off
  <i> </i>       italic on, off
  <h1> <h2> <h3> heading 1-3, set with Heading1Font etc
  </h>           normal text
  <tt> </tt>     fixed font 
  <red> etc      colors
  <left>         left alignment (word wrap)
  <unaligned>    no right margin
  <center>       centered
  <right>        right alignment
  <justify>      full justification (not implemented)
  <defaultalign> default alignment
  <margin x>     set left margin to x pixels
  <link linktext> </link>
    start, end link. 
    The OnClickLink and OnOverLink events are called with linktext
  <image x>      Display image x from associated TImageList
    

Example

RichText.AddParagraph( '<h1>This is a big heading</h>' );  
RichText.AddParagraph( 'Here is some <b>bold</b> text' );  
  

Problems/limitations
--------------------
Yes, there probably are some. :)