All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.objectplanet.NewsTicker

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----java.applet.Applet
                                   |
                                   +----com.objectplanet.NewsTicker

public class NewsTicker
extends Applet
implements Runnable
The news ticker applet displvays a list of news scrolling vertically, with the ability to scroll up and down interactivly and click on a link to open a page with more news.

APPLET PARAMETERS

<param name=header value="applet header">
<param name=headerFont value="Arial,bold,16">
<param name=headerColor value="#c07f00">
<param name=headerAlignment value="left,center,right">
<param name=newsHeaderFont value="Courier,plain,12">
<param name=newsHeaderColor value="blue">
<param name=newsFont value="Arial,plain,11">
<param name=newsColor value="gray">
<param name=moreLinkText value="read more...">
<param name=moreLinkColor value="red">
<param name=target value="browserwindowname">
<param name=newsXMLTag value="news">
<param name=newsHeaderXMLTag value="header">
<param name=newsBodyXMLTag value="body">
<param name=newsLinkXMLTag value="link">
<param name=scrollSpeed value="7">
<param name=border value="solid,up,down,grooved,embossed">
<param name=background value="orange">

Author:
Bjorn J. Kvande

Constructor Index

 o NewsTicker()
Constructs the news ticker.

Method Index

 o handleEvent(Event)
Processes the mouse events.
 o init()
Initializes the news ticker, reading the news parameters.
 o paint(Graphics)
Renders the news ticker.
 o run()
Thread that scrolls the news.
 o setParameter(String, String)
Sets a parameter.
 o start()
Starts the news ticker scroller.
 o stop()
Stops the news ticker scroller.
 o update(Graphics)
Overridden to avoid flickering.

Constructors

 o NewsTicker
 public NewsTicker()
Constructs the news ticker.

Methods

 o init
 public void init()
Initializes the news ticker, reading the news parameters.

Overrides:
init in class Applet
 o start
 public void start()
Starts the news ticker scroller.

Overrides:
start in class Applet
 o stop
 public void stop()
Stops the news ticker scroller.

Overrides:
stop in class Applet
 o setParameter
 public void setParameter(String name,
                          String value)
Sets a parameter.

Parameters:
name - The name of the parameter.
value - The value of the parameter to set.
 o update
 public void update(Graphics g)
Overridden to avoid flickering.

Overrides:
update in class Container
 o paint
 public void paint(Graphics g)
Renders the news ticker.

Parameters:
g - The graphics object used to paint with.
Overrides:
paint in class Container
 o handleEvent
 public boolean handleEvent(Event event)
Processes the mouse events.

Overrides:
handleEvent in class Component
 o run
 public void run()
Thread that scrolls the news. Do not call directly.


All Packages  Class Hierarchy  This Package  Previous  Next  Index