function ba(bu, num) {
  document[bu].src = eval(bu + num + ".src");
}

function bia(bu,num) {
  document[bu].src = eval(bu + num + ".src");
}

function checkpic(bu,num) {
}

//--------- Menu Button Definitionen ---------------
//
// Fuer jeden Meoglich Menubutton wird auch ein Array
// angelegt, der zusaetzlich Daten enthalt, unter anderem 
// Die StatusMeldung falls der Benutzer ueber den Knopf 
// faehrt, der ALT Text, das start image und das mouse
// out image, nur die Nummern:
// 1=violett, 2=gelb, 3=grau, 4=orange
// und der URL, auf den das Bild zeigt.
// Ausserdem sind die Daten enthalten, die beim
// OnMouseover im Statusbalken und unter der Maus
// zu sehen sind.
//
///////////////////////////////////////////////
// REWIND Button (<<)
c_re1=new Image();c_re1.src= ROOTP + "gfx/control/cont-rew-v.gif";
c_re2=new Image();c_re2.src= ROOTP + "gfx/control/cont-rew-y.gif";
c_re3=new Image();c_re3.src= ROOTP + "gfx/control/cont-rew-g.gif";
c_re4=new Image();c_re4.src= ROOTP + "gfx/control/cont-rew-o.gif";
c_re_a=new Array(1,
                 2,
                 new Array("Zum Anfang","Back to start","start","start"),
                 new Array("Zum Ersten Bild dieses Experiments",
                           "Back to the first frame of this experiment",
                           "",
                           "Back"),
                 "error.html")
///////////////////////////////////////////////
// PREVIOUS Button (<)
c_pr1=new Image();c_pr1.src= ROOTP + "gfx/control/cont-prev-v.gif";
c_pr2=new Image();c_pr2.src= ROOTP + "gfx/control/cont-prev-y.gif";
c_pr3=new Image();c_pr3.src= ROOTP + "gfx/control/cont-prev-g.gif";
c_pr4=new Image();c_pr4.src= ROOTP + "gfx/control/cont-prev-o.gif";
c_pr_a=new Array(1,
                 2,
                 new Array("Vorhergehendes Bild","Previous Frame","pre","pre"),
                 new Array("Zur&uuml;ck zum vorhergehenden Bild",
                           "Display the previous image and text",
                           "Previous",
                           "Previous"),
                 "error.html")
///////////////////////////////////////////////
// NEXT Button (>)
c_ne1=new Image();c_ne1.src= ROOTP + "gfx/control/cont-next-v.gif";
c_ne2=new Image();c_ne2.src= ROOTP + "gfx/control/cont-next-y.gif";
c_ne3=new Image();c_ne3.src= ROOTP + "gfx/control/cont-next-g.gif";
c_ne4=new Image();c_ne4.src= ROOTP + "gfx/control/cont-next-o.gif";
c_ne_a=new Array(1,
                 2,
                 new Array("N&auml;chstes Bild","Next Frame","next","next"),
                 new Array("Anzeigen des n&auml;chsten Bildes",
                           "Display the next image and text",
                           "next",
                           "next"),
                 "error.html")
///////////////////////////////////////////////
// FAST FORWARD Button (>>)
c_ff1=new Image();c_ff1.src= ROOTP + "gfx/control/cont-ff-v.gif";
c_ff2=new Image();c_ff2.src= ROOTP + "gfx/control/cont-ff-y.gif";
c_ff3=new Image();c_ff3.src= ROOTP + "gfx/control/cont-ff-g.gif";
c_ff4=new Image();c_ff4.src= ROOTP + "gfx/control/cont-ff-o.gif";
c_ff_a=new Array(1,
                 2,
                 new Array("Zum Ende","Last Frame","last","last"),
                 new Array("Vorw&auml;rts zum letzten Bild dieses Experiments",
                           "Go forward to the last frame of this experiment",
                           "last",
                           "last"),
                 "error.html")
///////////////////////////////////////////////
// UP Button (^)
c_up1=new Image();c_up1.src= ROOTP + "gfx/control/cont-up-v.gif";
c_up2=new Image();c_up2.src= ROOTP + "gfx/control/cont-up-y.gif";
c_up3=new Image();c_up3.src= ROOTP + "gfx/control/cont-up-g.gif";
c_up4=new Image();c_up4.src= ROOTP + "gfx/control/cont-up-o.gif";
c_up_a=new Array(1,
                 2,
                 new Array("Aufw&auml;rts","Up","Up","Up"),
                 new Array("Aufw&auml;rts zur &uuml;bergeordneten Ebene",
                           "Go to the upper level",
                           "up",
                           "up"),
                 "error.html")
///////////////////////////////////////////////
// Question Button (?)
c_qu1=new Image();c_qu1.src= ROOTP + "gfx/control/cont-qu-v.gif";
c_qu2=new Image();c_qu2.src= ROOTP + "gfx/control/cont-qu-y.gif";
c_qu3=new Image();c_qu3.src= ROOTP + "gfx/control/cont-qu-g.gif";
c_qu4=new Image();c_qu4.src= ROOTP + "gfx/control/cont-qu-o.gif";
c_qu_a=new Array(1,
                 2,
                 new Array("Aufgabe","Exercise","Exercise","Exercise"),
                 new Array("Aufgaben zum Thema",
                           "Exercise for the matter",
                           "Exercise for the matter",
                           "Exercise for the matter"),
                 "error.html")
///////////////////////////////////////////////
// ANSWER Button (=)
c_at1=new Image();c_at1.src= ROOTP + "gfx/control/cont-at-v.gif";
c_at2=new Image();c_at2.src= ROOTP + "gfx/control/cont-at-y.gif";
c_at3=new Image();c_at3.src= ROOTP + "gfx/control/cont-at-g.gif";
c_at4=new Image();c_at4.src= ROOTP + "gfx/control/cont-at-o.gif";
c_at_a=new Array(1,
                 2,
                 new Array("L&ouml;sung","Solution","solution","soluzione"),
                 new Array("L&ouml;sung der Aufgabe",
                           "Result of the exercise",
                           "result",
                           "result"),
                 "error.html")

///////////////////////////////////////////////
// GOTO Button  (>)
c_go1=new Image();c_go1.src= ROOTP + "gfx/control/arrv.gif";
c_go2=new Image();c_go2.src= ROOTP + "gfx/control/arry.gif";
c_go_a=new Array(1,
                 2,
                 new Array("Weiter", "Continue", "", "Continua"),
                 new Array("n&auml;chste Seite",
                           "next page",
                           "",
                           "Continua"),
                 "error.html")
///////////////////////////////////////////////
// VERTIEFUNG Button 1  (>)
c_v11=new Image();c_v11.src= ROOTP + "gfx/control/arrv.gif";
c_v12=new Image();c_v12.src= ROOTP + "gfx/control/arry.gif";
c_v1_a=new Array(1,
                 2,
                 new Array("Vertiefung", "More Info","","Continua"),
                 new Array("Vertiefung anzeigen",
                           "Show more information",
                           "",
                           "Continua"),
                 "error.html")
///////////////////////////////////////////////
// VIDEO Button  (>)
c_v21=new Image();c_v21.src= ROOTP + "gfx/control/arrv.gif";
c_v22=new Image();c_v22.src= ROOTP + "gfx/control/arry.gif";
c_v2_a=new Array(1,
                 2,
                 new Array("Video", "Video", "Video", "Video"),
                 new Array("volle Gr&ouml;sse",
                           "full size",
                           "",
                           ""),
                 "error.html")
///////////////////////////////////////////////
// ANWENDUNG Button  (>)
c_an1=new Image();c_an1.src= ROOTP + "gfx/control/arrv.gif";
c_an2=new Image();c_an2.src= ROOTP + "gfx/control/arry.gif";
c_an_a=new Array(1,
                 2,
                 new Array("Anwendungen", "Applications", "", "Applicazione"),
                 new Array("Einige m&ouml;gliche Anwendungen",
                           "Some possible applications",
                           "",
                           "Applicazione"),
                 "error.html")
///////////////////////////////////////////////
// SICHERHEIT Button  (>)
c_si1=new Image();c_si1.src= ROOTP + "gfx/control/arrv.gif";
c_si2=new Image();c_si2.src= ROOTP + "gfx/control/arry.gif";
c_si_a=new Array(1,
                 2,
                 new Array("Sicherheit", "Safety","","Sicurezza"),
                 new Array("Einige Informationen zur Sicherheit",
                           "Some safety related information",
                           "",
                           "Sicurezza"),
                 "error.html")
///////////////////////////////////////////////
// EXPERIMENT Button  (>)
c_ex1=new Image();c_ex1.src= ROOTP + "gfx/control/arrv.gif";
c_ex2=new Image();c_ex2.src= ROOTP + "gfx/control/arry.gif";
c_ex_a=new Array(1,
                 2,
                 new Array("Experimentauswahl", "Experiment selection","","Esperimento"),
                 new Array("Demonstration mit Bildern und Video",
                           "demonstration with pictures and video",
                           "",
                           "imagini e video"),
                 "error.html")
///////////////////////////////////////////////
// BACK Button (<)
c_ba1=new Image();c_ba1.src= ROOTP + "gfx/control/arlv.gif";
c_ba2=new Image();c_ba2.src= ROOTP + "gfx/control/arly.gif";
c_ba_a=new Array(1,
                 2,
                 new Array("Zur&uuml;ck", "Back", "retour", "Torna indietro"),
                 new Array("eine Seite zur&uuml;ck",
                           "one page back",
                           "retour a la page precedente",
                           "Torna alla pagina precedente"),
                 "error.html")
// Makros fuer die Vorwaerts und Rueckwaerts Buttons:
// Wenn man nicht zurueck kann, dann 
FIRSTPIC=0
LASTPIC=1
BETWEENPIC=2

REW=1
PREV=2
NEXT=3
FF=4
UP=5
QU=6
AN=7

////////////////////////////////////////////
// function setControlUrl()
//
// Diese Funktion wird benutzt, um nur den URL eines 
// Kontrollfeldes bei Einzelbildern
// ( << < > >> ) einzustellen. 
//
// Die Parameter sind wie die Bilder, das heisst, dass
// das erste Argument eine Bildidentifikation sein muss.
//
// Der erste uebergebene Wert muss der Name des Arrays ohne die
// Endung _a sein.
function setControlUrl() {
  narg = setControlUrl.arguments.length;
  if (narg == 0) {
    // Do nothing
    return;
  }
  ar = setControlUrl.arguments[0];    // welcher Array
  url = "error.html";
  
  if (narg > 1) {
    url = setControlUrl.arguments[1];
  }
  if(ar == "c_re") {
    c_re_a[4] = url;
  }
  if(ar == "c_pr") {
    c_pr_a[4] = url;
  }
  if(ar == "c_ne") {
    c_ne_a[4] = url;
  }
  if(ar == "c_ff") {
    c_ff_a[4] = url;
  }
}




// Diese Funktion erstellt eine Tabelle mit den Buttons
// zum Vor und zurueckwechseln bei den Texten und Bildern
// Je nach Argument werden einige Daten grau, also
// inaktiv, dargestellt. Und die Sprache kann auch ausge-
// waehlt werden.
//
// Parameter:
// arguments[0] = 0 : Es handelt sich offenbar um das erste
//                    Bild, deshalb werden die Arrows nach 
//                    links nur in grau dargestellt. Einstellungen
//                    in den defaults arrays werden nicht beruecksichtigt!
//
// arguments[0] = 1 : Es handelt sich um das letzte Bild, die Pfeile
//                    nach rechts werden in grau dargestellt.
//
// arguments[0] = 2 : Standardfall, sowohl Pfeile nach links wie 
//                    auch solche nach rechts koennen angewaehlt 
//                    werden. 
//
// arguments[1] = 1 : Als Sprache werden die deutschen Beschriftungen 
//                    genommen, ist der Wert 0, so werden die englischen
//                    benutzt.
//
// Die Breite und Hoehe der Buttons wird am Anfang der Funktion
// definiert, sie koennen nicht uebergeben werden.
//
// Mehr als zwei Argumente werden nicht beachtet. Sollen die Farben
// oder die Beschriftungen zur Laufzeit veraendert werden, so muss
// die Funktion setControlValues benutzt werden.
//
function showControls() {
  narg = showControls.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
  l = 0
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showControls.arguments[1] > 3) || (showControls.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showControls.arguments[1];
    }
  }
  
  // hoehe und breite der einzelnen Buttons setzen
  h = 28;
  w1 = 26;
  w2 = 42;
  w3 = 10; //Abstandshalter
  tw = w1 + w1 + w2 + w2 + w3;  // Ohne Umrandung...
  w4 = tw;       // Breite ohne Umrandung

  if ((showControls.arguments[0] > 2) || showControls.arguments[0] < 0) {
    // Nur Schrottwert
    return;
  }
  this.doc.writeln("<form><input type=\"HIDDEN\" value=1 name=\"piccount\"><\/form>");
  // And now the real stuff, zuerst den oberen Rahmen, dieser ist fuer
  // alle Varianten gleich
  this.doc.write("&nbsp;<br><center><table width=" + tw +
                 " border=0 cellpadding=0 cellspacing=0>" );

  // The following definitions are for the different images..  
  alt1  = c_re_a[2][l];                   // alternate text
  stat1 = c_re_a[3][l];                   // statusmessage
  url1  = c_re_a[4];                     // url when clicked (used?)
  //url1  = "displayhead.html?control=1";
  col1  = c_re_a[0];                     // normal color 
  over1 = c_re_a[1];                     // mouse over color
  srcs1 = eval("c_re" + col1 + ".src");  // url to normal image
  alt2  = c_pr_a[2][l];
  stat2 = c_pr_a[3][l];
  url2  = c_pr_a[4];
  //url2  = "displayhead.html?control=2";
  col2  = c_pr_a[0]; 
  over2 = c_pr_a[1]; 
  srcs2 = eval("c_pr" + col2 + ".src");
  alt3  = c_ne_a[2][l];
  stat3 = c_ne_a[3][l];
  url3  = c_ne_a[4];
  //url3  = "displayhead.html?control=3";
  col3  = c_ne_a[0]; 
  over3 = c_ne_a[1]; 
  srcs3 = eval("c_ne" + col3 + ".src");
  alt4  = c_ff_a[2][l];
  stat4 = c_ff_a[3][l];
  url4  = c_ff_a[4];
  //url4  = "displayhead.html?control=4";
  col4  = c_ff_a[0]; 
  over4 = c_ff_a[1]; 
  srcs4 = eval("c_ff" + col2 + ".src");

  // And now depending on arg[0] the arrows:
  if (showControls.arguments[0] == FIRSTPIC) {
    // Erstes Bild einer Serie, also Pfeile nach links grau machen.
    // Zuerst aber den Inhalt der Arrays und die Sprache berueck-
    // sichtigen. Das Hidden Form ist fuer den Bilderzaehler
    this.doc.write("<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w2 +
                   " height=" + h + " border=0>" +
                   "<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w1 +
                   " height=" + h + " border=0>" +
                   "<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w3 +
                   " height=" + h + " border=0>" +
                   "<a href=\"" + url3 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_ne\'," + over3 + "\);window.status=\'" + stat3 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_ne\'," + col3 + "\)\">" +
                   "<img src=\"" + srcs3 + "\"alt=\"" + alt3 + "\"width=" + w1 +
                   " height=" + h + " border=0 name=\"c_ne\"><\/a>" +
                   "<a href=\"" + url4 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_ff\'," + over4 + "\);window.status=\'" + stat4 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_ff\'," + col4 + "\)\">" +
                   "<img src=\"" + srcs4 + "\"alt=\"" + alt4 + "\"width=" + w2 +
                   " height=" + h + " border=0 name=\"c_ff\"><\/a>");
  }
  if (showControls.arguments[0] == LASTPIC) {
    // Letzes Bild einer Serie, also Pfeile nach rechts grau machen.
    // Zuerst aber den Inhalt der Arrays und die Sprache berueck-
    // sichtigen.
    this.doc.write("<a href=\"" + url1 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_re\'," + over1 + "\);window.status=\'" + stat1 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_re\'," + col1 + "\)\">" +
                   "<img src=\"" + srcs1 + "\"alt=\"" + alt1 + "\"width=" + w2 +
                   " height=" + h + " border=0 name=\"c_re\"><\/a>" +
                   "<a href=\"" + url2 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_pr\'," + over2 + "\);window.status=\'" + stat2 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_pr\'," + col2 + "\)\">" +
                   "<img src=\"" + srcs2 + "\"alt=\"" + alt2 + "\"width=" + w1 +
                   " height=" + h + " border=0 name=\"c_pr\"><\/a>" +
                   "<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w3 +
                   " height=" + h + " border=0>" +
                   "<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w1 +
                   " height=" + h + " border=0>" +
                   "<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w2 +
                   " height=" + h + " border=0>");
  }
  if (showControls.arguments[0] == BETWEENPIC) {
    // Weder erstes noch letztes Bild einer Serie, also Pfeile nach
    // beiden Seiten machen.  Zuerst aber den Inhalt der Arrays und die
    // Sprache beruecksichtigen.
    this.doc.write("<a href=\"" + url1 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_re\'," + over1 + "\);window.status=\'" + stat1 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_re\'," + col1 + "\)\">" +
                   "<img src=\"" + srcs1 + "\"alt=\"" + alt1 + "\"width=" + w2 +
                   " height=" + h + " border=0 name=\"c_re\"><\/a>" +
                   "<a href=\"" + url2 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_pr\'," + over2 + "\);window.status=\'" + stat2 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_pr\'," + col2 + "\)\">" +
                   "<img src=\"" + srcs2 + "\"alt=\"" + alt2 + "\"width=" + w1 +
                   " height=" + h + " border=0 name=\"c_pr\"><\/a>" +
                   "<img src=\"" + ROOTP + "gfx/control/white1.jpg\"width=" + w3 +
                   " height=" + h + " border=0>" +
                   "<a href=\"" + url3 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_ne\'," + over3 + "\);window.status=\'" + stat3 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_ne\'," + col3 + "\)\">" +
                   "<img src=\"" + srcs3 + "\"alt=\"" + alt3 + "\"width=" + w1 +
                   " height=" + h + " border=0 name=\"c_ne\"><\/a>" +
                   "<a href=\"" + url4 + "\"target=\"ccidisphead\" onmouseover=\"" +
                   "ba\(\'c_ff\'," + over4 + "\);window.status=\'" + stat4 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_ff\'," + col4 + "\)\">" +
                   "<img src=\"" + srcs4 + "\"alt=\"" + alt4 + "\"width=" + w2 +
                   " height=" + h + " border=0 name=\"c_ff\"><\/a>");
  }
  this.doc.write("<\/td><\/tr><\/table><\/center>")

}

/////////////////////////////////////////////
// function setArrowUrl()
//
// Diese Funktion wird benutzt, um nur den URL eines 
// Pfeilfeldes (GoTo oder Back)
// ( < oder > ) einzustellen. 
//
// Die Parameter sind wie die Bilder, das heisst, dass
// das erste Argument eine Bildidentifikation sein muss.
//
// Der erste uebergebene Wert muss der Name des Arrays ohne die
// Endung _a sein.
function setArrowUrl() {
  narg = setArrowUrl.arguments.length;
  if (narg == 0) {
    // Do nothing
    return;
  }
  ar = setArrowUrl.arguments[0];    // welcher Array
  url = "error.html";
  
  if (narg > 1) {
    url = setArrowUrl.arguments[1];
  }
  if(ar == "c_ba") {
    c_ba_a[4] = url;
  }
  if(ar == "c_go") {
    c_go_a[4] = url;
  }
  if(ar == "c_v1") {
    c_v1_a[4] = url;
  }
  if(ar == "c_v2") {
    c_v2_a[4] = url;
  }
  if(ar == "c_an") {
    c_an_a[4] = url;
  }
  if(ar == "c_si") {
    c_si_a[4] = url;
  }
  if(ar == "c_ex") {
    c_ex_a[4] = url;
  }
}

// Diese Funktion erstellt einen Pfeil nach rechts oder links
// fuer die Vertiefungen bei den Texten. Im Prinzip nur
// ein Pfeil nach rechts.
function showRightOrLeft() {
  narg = showRightOrLeft.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
  l = 1
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showRightOrLeft.arguments[1] > 3) || (showRightOrLeft.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showRightOrLeft.arguments[1];
    }
  }
  
  // hoehe und breite der einzelnen Buttons setzen
  h = 30;
  w = 30;

  if ((showRightOrLeft.arguments[0] > 2) || showRightOrLeft.arguments[0] < 1) {
    // Nur Schrottwert
    return;
  }
  // The following definitions are for the different images..  
  alt2  = c_go_a[2][l];
  stat2 = c_go_a[3][l];
  url2  = c_go_a[4];
  col2  = c_go_a[0]; 
  over2 = c_go_a[1]; 
  srcs2 = eval("c_go" + col2 + ".src");
  alt3  = c_ba_a[2][l];
  stat3 = c_ba_a[3][l];
  url3  = c_ba_a[4];
  col3  = c_ba_a[0]; 
  over3 = c_ba_a[1]; 
  srcs3 = eval("c_ba" + col3 + ".src");

  if (showRightOrLeft.arguments[0] == 1) {
    this.doc.write("<table cellspacing=4 border=0 cellpadding=4><tr><td>" +
                   "<a href=\"" + url2 + "\" onmouseover=\"" +
                   "ba\(\'c_go\'," + over2 + "\);window.status=\'" + stat2 + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_go\'," + col2 + "\)\">" +
                   "<img src=\"" + srcs2 + "\"alt=\"" + alt2 + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_go\"><\/a><\/td><td>" +
                   alt2 + "<\/td><\/tr><\/table>");
  }
  if (showRightOrLeft.arguments[0] == 2) {
    this.doc.write("<table cellspacing=4 border=0 cellpadding=4><tr><td>" +
                   "<a href=\"" + url3 + "\" onmouseover=\"" +
                   "ba\(\'c_ba\'," + over3 + "\);window.status=\'" + stat3 + "\'" +
                   ";return true\"onclick=\"window.back\(\);return true\""+
                   "onmouseout=\"bia\(\'c_ba\'," + col3 + "\)\">" +
                   "<img src=\"" + srcs3 + "\"alt=\"" + alt3 + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_ba\"><\/a><\/td><td>" +
                   alt3 + "<\/td><\/tr><\/table>");
  }
}


// Diese Funktion erstellt einen Pfeil nach rechts
// fuer die Anwendungen bei den Texten
// ein Pfeil nach rechts.
function showAnw() {
  narg = showAnw.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
  l = 1
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showAnw.arguments[1] > 3) || (showAnw.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showAnw.arguments[1];
    }
  }
  // hoehe und breite der einzelnen Buttons setzen
  h = 30;  w = 30;

  if ((showAnw.arguments[0] > 2) || showAnw.arguments[0] < 1) {
    // Nur Schrottwert
    return;
  }
  alt  = c_an_a[2][l];  stat = c_an_a[3][l];  url  = c_an_a[4];
  col  = c_an_a[0];   over = c_an_a[1]; srcs = eval("c_an" + col + ".src");

  if (showAnw.arguments[0] == 1) {
    this.doc.write("<a href=\"" + url + "\" onmouseover=\"" +
                   "ba\(\'c_an\'," + over + "\);window.status=\'" + stat + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_an\'," + col + "\)\">" +
                   "<img src=\"" + srcs + "\"alt=\"" + alt + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_an\"><\/a>");
  }
}

// Diese Funktion erstellt einen Pfeil nach rechts
// fuer die Sicherheit bei den Texten
// ein Pfeil nach rechts.
function showSec() {
  narg = showSec.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
  l = 1
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showSec.arguments[1] > 3) || (showSec.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showSec.arguments[1];
    }
  }
  // hoehe und breite der einzelnen Buttons setzen
  h = 30;  w = 30;

  if ((showSec.arguments[0] > 2) || showSec.arguments[0] < 1) {
    // Nur Schrottwert
    return;
  }
  alt  = c_si_a[2][l];  stat = c_si_a[3][l];  url  = c_si_a[4];
  col  = c_si_a[0];   over = c_si_a[1]; srcs = eval("c_si" + col + ".src");

  if (showSec.arguments[0] == 1) {
    this.doc.write("<a href=\"" + url + "\" onmouseover=\"" +
                   "ba\(\'c_si\'," + over + "\);window.status=\'" + stat + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_si\'," + col + "\)\">" +
                   "<img src=\"" + srcs + "\"alt=\"" + alt + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_si\"><\/a>");
  }
}
// Diese Funktion erstellt einen Pfeil nach rechts
// als Experimentverweis im Vorlesungsmanuskript
// Argumente: url, Sprache (optional)
// ein Pfeil nach rechts.
function showExp() {
  narg = showExp.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
l = 1
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showExp.arguments[1] > 3) || (showExp.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showExp.arguments[1];
    }
  }
  // hoehe und breite der einzelnen Buttons setzen
  h = 30;  w = 30;

  alt  = c_ex_a[2][l];  stat = c_ex_a[3][l];  url  = c_ex_a[4];
  col  = c_ex_a[0];   over = c_ex_a[1]; srcs = eval("c_ex" + col + ".src");
   this.doc.write("<a href=\"" + document.location + "\" onClick=\"extern\(url\)\"" +
                    "\" onmouseover=\"" +
                   "ba\(\'c_ex\'," + over + "\);window.status=\'" + stat + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_ex\'," + col + "\)\">" +
                   "<img src=\"" + srcs + "\"alt=\"" + alt + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_ex\"><\/a>");
}

// Diese Funktion erstellt einen Pfeil nach rechts
// fuer die Vertiefungen bei den Texten
// ein Pfeil nach rechts.
function showVert1() {
  narg = showVert1.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
  l = 0
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showVert1.arguments[1] > 3) || (showVert1.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showVert1.arguments[1];
    }
  }
  // hoehe und breite der einzelnen Buttons setzen
  h = 30;  w = 30;

  if ((showVert1.arguments[0] > 2) || showVert1.arguments[0] < 1) {
    // Nur Schrottwert
    return;
  }
  alt  = c_v1_a[2][l];  stat = c_v1_a[3][l];  url  = c_v1_a[4];
  col  = c_v1_a[0];   over = c_v1_a[1]; srcs = eval("c_v1" + col + ".src");

  if (showVert1.arguments[0] == 1) {
    this.doc.write("<a href=\"" + url + "\" onmouseover=\"" +
                   "ba\(\'c_v1\'," + over + "\);window.status=\'" + stat + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_v1\'," + col + "\)\">" +
                   "<img src=\"" + srcs + "\"alt=\"" + alt + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_v1\"><\/a>");
  }
}
// Diese Funktion erstellt einen Pfeil nach rechts
// fuer die Vertiefungen bei den Texten
// ein Pfeil nach rechts.
function showVideo2() {
  narg = showVideo2.arguments.length
  // Test auf narg:
  if (narg == 0) {
     return;
  }
  l = 1
  if (narg == 1) {
    // Default Sprache ist deutsch, dieser Wert ist als offset zu betrachten
    l = 0;
  }
  else {
    if ( (showVideo2.arguments[1] > 3) || (showVideo2.arguments[1] < 0 )) {
      l = 0;
    }
    else {
      l = showVideo2.arguments[1];
    }
  }
  // hoehe und breite der einzelnen Buttons setzen
  h = 30;  w = 30;

  if ((showVideo2.arguments[0] > 2) || showVideo2.arguments[0] < 1) {
    // Nur Schrottwert
    return;
  }
  alt  = c_v2_a[2][l];  stat = c_v2_a[3][l];  url  = c_v2_a[4];
  col  = c_v2_a[0];   over = c_v2_a[1]; srcs = eval("c_v2" + col + ".src");

  if (showVideo2.arguments[0] == 1) {
    this.doc.write("<a href=\"" + url + "\" onmouseover=\"" +
                   "ba\(\'c_v2\'," + over + "\);window.status=\'" + stat + "\'" +
                   ";return true\"onmouseout=\"bia\(\'c_v2\'," + col + "\)\">" +
                   "<img src=\"" + srcs + "\"alt=\"" + alt + "\"width=" + w +
                   " height=" + h + " border=0 name=\"c_v2\"><\/a>");
  }
}

function makeControls(doc) {
  this.doc = doc;
  this.display = showControls;
  this.disparrow = showRightOrLeft;
  this.dispvertiefung1 = showVert1; 
  this.dispvideo2 = showVideo2;
  this.dispanwendung = showAnw;
  this.dispsicherheit =  showSec;
  this.dispexperiment =  showExp;
  this.setControlUrl = setControlUrl;
  this.setArrowUrl = setArrowUrl;
}



