/* This script and many more are available free online at The JavaScript Source!! http://javascript.internet.com */
/* script modif. by Klaus Wagner 2001 */

var hmsg = new Array();
hmsg["a1"] = new helpmsg("", "", "", hi[1]);hmsg["a2"] = new helpmsg("", "", "", hi[2]);
hmsg["a3"] = new helpmsg("", "", "", hi[3]);hmsg["a4"] = new helpmsg("", "", "", hi[4]);
hmsg["a5"] = new helpmsg("", "", "", hi[5]);hmsg["a6"] = new helpmsg("", "", "", hi[6]);
hmsg["a7"] = new helpmsg("", "", "", hi[7]);hmsg["a8"] = new helpmsg("", "", "", hi[8]);
hmsg["a9"] = new helpmsg("", "", "", hi[9]);hmsg["a10"] = new helpmsg("", "", "", hi[10]);
hmsg["a11"] = new helpmsg("", "", "", hi[11]);hmsg["a12"] = new helpmsg("", "", "", hi[12]);
hmsg["a13"] = new helpmsg("", "", "", hi[13]);hmsg["a14"] = new helpmsg("", "", "", hi[14]);
hmsg["a15"] = new helpmsg("", "", "", hi[15]);hmsg["a16"] = new helpmsg("", "", "", hi[16]);
hmsg["a17"] = new helpmsg("", "", "", hi[17]);hmsg["a18"] = new helpmsg("", "", "", hi[18]);
hmsg["a19"] = new helpmsg("", "", "", hi[19]);hmsg["a20"] = new helpmsg("", "", "", hi[20]);

var myPopup = new helpbox("myPopup", hmsg, breit, hoch, "#fdf5e6");

function helpmsg(header, hstyle, mstyle, message) {
this.DEFAULTMSTYLE = "plain";
this.message = message;
if (mstyle) this.mstyle = mstyle; else this.mstyle = this.DEFAULTMSTYLE;return this;
}

new helpmsg();helpmsg.prototype.show = show;

function show() {
var M = "<FONT FACE='VERDANA,ARIAL' SIZE=-1>"+ this.message + "\n</FONT>";
if (this.mstyle == "plain") {}
if (this.mstyle == "italics") M = M.italics();
else if (this.mstyle == "bold") M = M.bold();
var htmlpage=M;return htmlpage;
}

function helpbox(name, hm, width, height, bgcolor) {
this.name = name;
this.helpmessage = hm;
this.timerHandle = null;
this.windowHandle = null;
this.DEFAULTWIDTH = 250;
this.DEFAULTHEIGHT = 150;
this.DEFAULTBGCOLOR = "#fdf5e6";
this.POPUPDELAY = 100;
if (width) this.width = width;
else this.width = this.DEFAULTWIDTH;
if (height) this.height = height;
else this.height = this.DEFAULTHEIGHT;
if (bgcolor) this.bgcolor = bgcolor;
else this.bgcolor = this.DEFAULTBGCOLOR;
return this;
}

function startHelp(msgindex) {
var cmdstr="top." + this.name + ".showHelp('" + msgindex + "')";
this.timerHandle = setTimeout(cmdstr, this.POPUPDELAY);
}

function showHelp(msgindex) {
if (!this.frameHandle || !this.frameHandle.name || this.frameHandle.name=="")
this.frameHandle = window.open("","subWindow","toolbar=no," +"location=no," +"directories=no," +"status=no," +"menubar=no," +
"scrollbars=no," +"resizable=no," +"width=" + this.width + "," +"height=" + this.height);
else
this.frameHandle.focus();
this.frameHandle.document.open();
var to_page = "<HTML>\n" +"<BODY BGCOLOR='" + this.bgcolor + "'><P>" +this.helpmessage[msgindex].show() +"</BODY></HTML>\n";
this.frameHandle.document.write(to_page);
this.frameHandle.document.close();
}

function clearHelp() {
clearTimeout(this.timerHandle);
if (this.frameHandle && this.frameHandle.name) {this.frameHandle.close();this.frameHandle=null;}
}

new helpbox();
helpbox.prototype.startHelp = startHelp;
helpbox.prototype.showHelp = showHelp;
helpbox.prototype.clearHelp = clearHelp;
/* end of popups */
