Things You Should Know
TFrameViewer, THtmlViewer, and TFrameBrowser
The HTML component set consists of the THtmlViewer, TFrameViewer, and TFrameBrowser components. All three are HTML document display components:
THtmlViewer | The basic component. THtmlViewer displays single (non-frame) documents. It also forms
the basis for the other two components. |
|
---|---|---|
TFrameViewer | Displays both Frame and single HTML documents. TFrameViewer is oriented more for local
disk file use. |
|
TFrameBrowser | Also displays Frame and single HTML documents. However, TFrameBrower is oriented
toward Internet style protocols and URL usage. Additional code and/or components are generally required to use
TFrameBrowser. |
If you know that your application will not be using Frames, you can save a fair amount of code overhead by using THtmlViewer rather than one of the Frame components. Many operations are also simpler using THtmlViewer.
Starting with version 9.4, the HTML Components will use the GDIPLUS.DLL
for displaying
PNG images if that DLL is present. This will allow proper rendering of PNG images with
Alpha transparency. If the GDIPLUS.DLL
is not present, PNG images will still be displayed
but without the Alpha transparency capability.
The GDIPLUS.DLL
is present on all WinXP systems and has often been loaded on other systems
by other applications. If it is not present on your system, it can be downloaded
(at no charge) here.
Version 11.4 has several possible compile time options controlled by defining symbols. You can find these in the
HTMLCONS.INC
file. None of these symbols are initially defined. To make any one (or all) of these
symbols active, remove the "." from the {$.Define XXXX}
sequence and recompile the
code.
The possibilities are:
The gdiplus.dll provides alpha transparency support for PNG images. If, for some reason the use of the gdiplus.dll is undesirable, define NoGDIPlus. Defining NoGDIPlus will remove support for PNG images entirely.
Metafiles may be displayed by undefining this constant. NoMetaFile is defined by default to emphasize the fact that Metafile display and some printing operations are currently incompatible in Win98. For applications where printing is unimportant or Win98/95/ME need not be supported, undefining this constant will allow Metafiles to be displayed.
Defining NoTabLink disables the ability to Tab between Links. This may be desirable for documents with a great many links.
if you have a form with a great many radio buttons, you may want to define FastRadio to help speed the action. Note that this option changes the way tabbing works. With FastRadio off, tabs move only to the next control that is visible. With FastRadio on, tabs move to the next control even if it is not visible.
Without this definition, the <select> form controls (TListbox and TCombobox) will issue the OnObjectChange event only when the control loses the focus which is according to HTML specs. Defining OpOnChange simulates the way IExplorer does it, issuing the OnChange event immediately when a change is made.
A Mouseover Image is one that changes when the mouse passes over it. The HTML components use a special syntax to implement mouseover images. It's done with the <img> tag as follows:
With the Active attribute, the GIF will normally just display the first frame. When the mouse passes over, it will display the second frame and when left clicked will show the third frame. If there are more than 3 frames, the GIF will animate when the mouse passes over.
Printing Table Headers and Footers
Starting with Version 9.3, <thead>, <tbody>, and <tfoot> are supported when printing with some restrictions. In a table definition, these tags define header, body, and footer sections of the table. If the table is split between pages when printing, the table portion on each page will have its own header and footer section.
For best results, note the following hints and restrictions.
tr {page-break-inside: avoid;}
to avoid splitting rows at page boundaries.