// Increasing and Decreasing the font
var min=0.7;
var max=1.5;
function increaseFontSize() {
   var p = document.getElementsByTagName('p');
   for(i=0;i<p.length;i++) {
	  if(p[i].style.fontSize) {
		 var s = parseFloat(p[i].style.fontSize.replace("em",""));
	  } else {
		 var s = 1;
	  }
	  if(s!=max) {
		 s += 0.1;
	  }
	  p[i].style.fontSize = ""+s+"em";
	  p[i].style.lineHeight = ""+(s+0.4)+"em"
   }
   
   var b = document.getElementsByTagName('span');
   for(i=0;i<b.length;i++) {
	  if(b[i].style.fontSize) {
		 var s = parseFloat(b[i].style.fontSize.replace("em",""));
	  } else {
		 var s = 1;
	  }
	  if(s!=max) {
		 s += 0.1;
	  }
	  b[i].style.fontSize = ""+s+"em";
	  b[i].style.lineHeight = ""+(s+0.4)+"em"
   }

}


function decreaseFontSize() {
   var p = document.getElementsByTagName('p');
   for(i=0;i<p.length;i++) {
	  if(p[i].style.fontSize) {
		 var s = parseFloat(p[i].style.fontSize.replace("em",""));
	  } else {
		 var s = 1;
	  }
	  if(s!=min) {
		 s -= 0.1;
	  }
	  p[i].style.fontSize = ""+s+"em";
	  p[i].style.lineHeight = ""+(s+0.4)+"em"
   }   
   
   var b = document.getElementsByTagName('span');
   for(i=0;i<b.length;i++) {
	  if(b[i].style.fontSize) {
		 var s = parseFloat(b[i].style.fontSize.replace("em",""));
	  } else {
		 var s = 1;
	  }
	  if(s!=min) {
		 s -= 0.1;
	  }
	  b[i].style.fontSize = ""+s+"em";
	  b[i].style.lineHeight = ""+(s+0.4)+"em"
   }  
}
