Scrolltext
by Dr. Mohan Noone (August, 2000)
Instructions
Scrolltext displays a vertical scroll of stylized hypertext, which can be controlled using the mouse.
How to load:
Parameters:
All the parameters are optional.
1. target : The frame / window to show the hyperlinks.
To show in the same page set it to "_self". (default)
To show in a new window set it to "_blank".
To show in another frame, in the same window, set it to "{name of the frame}".
2. hfont, basefont : Fonts for the heading and text.
Specify the font as {fontface},{fontstyle},{fontsize} e.g., "SansSerif,plain,15" (default basefont)
*The main faces are Serif, SansSerif and Monospaced.
(Try ZapfDingBats if you're crazy. Two others are Dialog and DialogInput)
*Whichever fontface you specify, don't mess with the CapItaLizaTion! (i.e., SansSerif, NOT Sanserif)
*The styles are plain, bold, italic and bolditalic.
3. bgcolor, text, urlcolor and urlhovercolor : Colors for the background, text and urls.
Specify them as their hex codes e.g., FF0000 for red (default url color).
(Note that there is no default urlhovercolor - hovering is enabled for all links when
the parameter is specified. This may also be done for individual links, as given below
in the MnTML specification.)
4. plainurl : Set to "true" if you do not want the urls to be underlined.
5. speed : Speed of the scroller. (Default value is 3. Range : 1 to 5).
6. urlpause : Time to pause when the mouse is over a url, in milliseconds (default is 2500).
7. sourcefile : File containing the text to
display. Default is "Scrolltext.data".
How to write the textfile:
The text to be displayed should be in the sourcefile, as defined in the "sourcefile" parameter.
(If the parameter is not defined, the applet looks for a file named "Sourcefile.data".)
The text should be written using a simple markup language. (MnTML, if you please!)
MnTML specification:
1. Each portion of text should be contained in tags, like html.
The tags SHOULD be in lowercase, unlike html.
2. Unlike html, tags may not be nested: I told you it was a simple language!
3. The following tags are used :
<h>...</h> for headings
<p>...</p> for paragraph text
<u>...</u> for hypertext
4. Each tag starts a new line of text.
5. The headings and hyperlinks, and the default colors may be modified using the
parameters mentioned above ^ .
6. Add 'l' to the tag to underline. e.g, <hl>...</h> gives an underlined heading.
7. By default, all text is left aligned.
To center align, add 'c' to the tag.
To right align, add 'r'.
e.g.,
<hlc>...</h> gives an underlined center aligned heading.
<pr>...</p> gives a right aligned non-underlined paragraph.
<uc>...</u> gives a center aligned link.
(Whether it is underlined or not is decided by the parameter "plainurl" as detailed above. Note that using <ulc>..</u> will underline the link even if plainurls are enabled.)
8. The <h...> tag may contain a color. e.g., <h FF0000> for a red heading.
9. The <p...> tag may contain a color and/or a font (in any order)
e.g., <p Serif,italic,15 FFFF00> for a cyan, italicized paragraph.10. The <u...> tag MUST contain a link WITHIN doublequotes-
e.g. <u "index.htm"> (to an internal file)
or <u "http://www.lifebeyond.com/"> (to an external file).AFTER the url, the <u...> tag may contain a target to show the link
(this overrides the target parameter).
The target must be within doublequotes, and separated from the link by a space
e.g. <u "index.htm" "_blank"> (shows the link in a new window).
AFTER the target (or the url, if no target is mentined),
the <u...> tag may also contain a font and/or a color, as mentioned above.
e.g. <u "index.htm" "_blank" Serif,italic,15 FFE0D0>To get a different color when the mouse hovers the link, use a "/", as shown below :
<u "index.htm" "_blank" Serif,italic,15 FF0000/FFFFFF> (The red link turns white).
11. Special tags:
<w [time]> The scroll will wait, so that the person gets time to read.
The milliseconds to wait must be specified.
e.g., <w 4000> waits for 4 seconds.<b> Introduces a line break.
12. There are no more tags.
13. Escape sequences:
The following escapes are allowed in the text:
Escape sequence
Displayed as
\\
\
\n
new line
\t
tab (7 spaces)
\<
<
\>
>
Copyright and distribution:
I, Dr. Mohan L Noone am the author and owner of Scrolltext. You can freely use the applet. It will not nag or embarass you in any way!Warranty and limitation of liability:
This software and the accompanying files are provided "AS IS," without a warranty of any kind.How to contact me:
Any comments, suggestions or queries are welcome.
My e-mail is mln@gjt.org
All my applets are at http://opnoone.members.easyspace.com/
Good luck!
Dr. Mohan Noone