//var scale=screen.availWidth/1024
var scale=1;


scrollOn=0;

function maximizeWindow () {
  newSizeW = 1024;
  newSizeH = 750;

  myHorPos =0;
  myVertPos=0;
  availW =screen.availWidth;
  availH =screen.availHeight;
  //document.write("Screen size: " +availW+ " / " +availH+ "<br>");
     
  if (availW>newSizeW)
  {
    myHorPos =((availW-newSizeW)/2);
    myVertPos=((availH-newSizeH)/2);
  }

  if (document.all) 
  {
     top.window.resizeTo(newSizeW,newSizeH);	 
     top.window.moveTo(myHorPos,myVertPos);
     //document.write("Moving To: " +myHorPos+ " / " +myVertPos+ "<br>");
     //document.write("in if clause");
  } 
  else
  { 
     top.window.outerHeight= newSizeH;
     top.window.outerWidth = newSizeW;
     top.window.moveTo(myHorPos,myVertPos);
     //document.write("Moving To: " +myHorPos+ " / " +myVertPos+ "<br>");
     //document.write("in else clause");
  }

}



//uitgeschakeld
function writeInfo()
{
//document.write('<MARQUEE direction="left" loop="30" width="100%">');
//document.write('  <STRONG>Reiki Doe avond: iedere laatste maandag van de maand; Reiki 1 cursus: 2e weekend van de oneven maanden; Reiki Introductie avond: 2e maandag van de even maanden; Kijk in de agenda voor meer informatie.</STRONG>');
//document.write('</MARQUEE>');
}





//VARIABELEN VOOR ONDERSTAANDE FUNCTIES. 
//deze variabelen worden als onderstaand ingevuld bij de aanroep van create frames
urlPrefix='../html';

var titelPag=urlPrefix+'titel'+name+'.html';
var textPag=urlPrefix+'text'+name+'.html' ;
var menuPag=urlPrefix+'menu_'+name+'.html'; 


textW=Math.round(510*scale);

function getImgScale(){ 
  return scale;
}

function writeLogo(){
  var scale=1; //getScale();
  var logoH=Math.round(100*scale);
  document.write('<image src="images/shine_logo_zon.gif" height='+logoH+'>');
}


function createQuoteArea(){
   var borderOnOff=0;
   var spaceW=Math.round(30*scale);
   document.write('<frameset cols="'+spaceW+',*, '+spaceW+'" border="'+borderOnOff+'" marginwidth=0 marginheight=0 spacing=0 frameborder="'+borderOnOff+'" framespacing=0>');      	        
	  document.write('<frame src="'+urlPrefix+'empty.html" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
	  document.write('<frame src="'+urlPrefix+'quote.html" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>'); 
	  document.write('<frame src="'+urlPrefix+'empty.html" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');	 
   document.write('</frameset>');
}

function createTitleArea(name){
   var borderOnOff=0;
   var titelW=Math.round(textW-(50*scale));
   document.write('<frameset cols="'+titelW+',*">');      	  
      //col1 4 rijen 
	  var titelH=Math.round(60*scale);
	  var subTitleH=Math.round(30*scale);
	  document.write('<frameset rows="'+titelH+','+subTitleH+',* " border="'+borderOnOff+'" marginwidth=0 marginheight=0 spacing=0 frameborder="'+borderOnOff+'" framespacing=0>');
	     document.write('<frame src="'+urlPrefix+'empty.html" name="leeg" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
		 document.write('<frame src="'+titelPag+'" name="titelframe" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
                 document.write('<frame src="'+urlPrefix+'empty.html" name="undertitelframe" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');		 
	  document.write('</frameset>');
	  document.write('<frame src="'+urlPrefix+'empty.html" name="" scrolling=no noresize >');	 
   document.write('</frameset>');	
}

function createKopArea(name){
   var borderOnOff=0;
   document.write('<frameset cols="'+textW+',*" border="'+borderOnOff+'" marginwidth=0 marginheight=0 spacing=0 frameborder="'+borderOnOff+'" framespacing=0>');      	  
      createTitleArea(name); 
	  createQuoteArea();	  	 
   document.write('</frameset>');
}

function createTextArea(name){
  var shineTxtW=Math.round(30*scale);
  var scrollW=Math.round(100*scale);
  var borderOnOff=0;
  document.write('<frameset cols="'+textW+','+scrollW+','+shineTxtW+',*" border="'+borderOnOff+'">');
     document.write('<frame src="'+textPag+'" name="page_contents" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
	    
	if (scrollOn) {
	  document.write('<frame src="'+urlPrefix+'scroll.html" name="scroll" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
	} else {
	  document.write('<frame src="'+urlPrefix+'empty.html" name="scroll" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
	}
	document.write('<frame src="'+urlPrefix+'logo_text.html" name="logo_tekst" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=0 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
        var vrijbovenlogo=Math.round(95*scale);
	document.write('<frameset rows="'+vrijbovenlogo+',*" border="'+borderOnOff+'">');
	   document.write('<frame src="'+urlPrefix+'empty.html" name="leegbovenlogo" scrolling=no noresize >');
	   document.write('<frame src="'+urlPrefix+'logo.html" noresize scrolling=no border="'+borderOnOff+'" marginwidth=0 marginheight=20 spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
	document.write('</frameset>');
  document.write('</frameset>');	
}

function createMenuArea(name){
  var menuH=Math.round(520*scale);
  var reikidoeTxtH=Math.round(30*scale);
  var borderOnOff=0;
  document.write('<frameset rows="'+menuH+',*,'+reikidoeTxtH+'" border="'+borderOnOff+'">');
    document.write('<frame src="'+menuPag+'" name="menu" scrolling=no noresize>');	
	document.write('<frame src="'+urlPrefix+'empty.html" name="menu" scrolling=no noresize >');
	var spaceW=Math.round(10*scale);
	document.write('<frameset cols="'+spaceW+',*,'+spaceW+'">');
	  document.write('<frame src="'+urlPrefix+'empty.html" name="" scrolling=no noresize >'); 
	  document.write('<frame src="'+urlPrefix+'hint.html" name="" scrolling=no noresize >');
	  document.write('<frame src="'+urlPrefix+'empty.html" name="" scrolling=no noresize >');
	document.write('</frameset>'); 
  document.write('</frameset>');
}

//testfunctie voor create frames, hernoem de hoofdfunctie om deze aan te zetten. 
function TVDcreateFrames(name, urlPref, scrollSet){
  scrollOn=scrollSet;
  urlPrefix=urlPref;
  titelPag=urlPrefix+'titel_'+name+'.html';
  textPag=urlPrefix+'text_'+name+'.html';
  menuPag=urlPrefix+'menu_'+name+'.html'; 
  

  var bovensteFrameH=Math.round(30*scale);
  var borderOnOff=0;
  
  //first maximize the window
  maximizeWindow ();
  
  document.write('titelpag: '+titelPag+'<br>');
  document.write('textpag: '+textPag+'<br>'); 
  document.write('menupag: '+menuPag+'<br>'); 
  document.write('<br><br>'); 
  
} 


function createFrames(name, urlPref, scrollSet){
  //stel alle variabelen in op basis van de meegegeven parameters. 
  scrollOn=scrollSet;
  urlPrefix=urlPref;
  titelPag=urlPrefix+'titel_'+name+'.html';
  textPag=urlPrefix+'text_'+name+'.html';
  menuPag=urlPrefix+'menu_'+name+'.html'; 

  var bovensteFrameH=Math.round(30*scale);
  var borderOnOff=0;
  
  //first maximize the window
  maximizeWindow ();
  
  document.write('<frameset rows="'+bovensteFrameH+',*" border="'+borderOnOff+'" marginwidth=0 marginheight=0 spacing=0 frameborder="'+borderOnOff+'" framespacing=0>');
  document.write('<noframes>');
    document.write('<body>');
    document.write('<br><br>');
	document.write('Helaas, deze browser ondersteunt geen frames, klik ');
	document.write('<a href="'+ urlPrefix +' '+ name +'_text.html" target="_top" title="click voor de no-frames versie" onMouseOver="window.status="click voor de no-frames versie"; onMouseOut="window.status=" ">hier</a>');
	document.write(' voor de versie zonder frames<br><br>');
	document.write('Deze versie heeft niet alle mogelijkheden van de "normale" site.<br>');
	document.write('Je kunt proberen of het wel werkt wanneer je een recente update van je browser installeert.<br><br><br><br><br><br><br>');
	document.write('</body>');
  document.write('</noframes>');
 
    document.write('<frame src="'+urlPrefix+'empty.html" name="baseframe" scrolling=no border="'+borderOnOff+'" spacing=0 frame-border="'+borderOnOff+'" frame-spacing=0>');
   //rij2, 3 kolommen
   //var menuW=Math.round(186*scale);
var menuW=Math.round(210*scale);
   var spaceW=Math.round(24*scale);
   document.write('<frameset cols="'+menuW+','+spaceW+',*">');
      //col1
      createMenuArea(name);
	  //col2
	  document.write('<frame src="'+urlPrefix+'empty.html" name="menu" scrolling=no noresize >');
      //col3 2 rijen 	  
	  var titelH=Math.round(140*scale); 
	  document.write('<frameset rows="'+titelH+',*">');
	     createKopArea(name);
		 createTextArea(name);
	  document.write('</frameset>');	 
   document.write('</frameset>');	  
  document.write('</frameset>'); 
} 



