// Início do código de Aumentar/ Diminuir a letra
 
// Para usar coloque o comando: "javascript:mudaTamanho('tag_ou_id_alvo', -1);" para diminuir
// e o comando "javascript:mudaTamanho('tag_ou_id_alvo', +1);" para aumentar
 
var tagAlvo = new Array('p'); //pega todas as tags p//
 
// Especificando os possíveis tamanhos de fontes, poderia ser: x-small, small...
var tamanhos = new Array( '12px','13px','14px','15px','16px','17px','18px' );
var tamanhoInicial = 2;
 
function mudaTamanho( idAlvo,acao ){
  if (!document.getElementById) return
  var selecionados = null,tamanho = tamanhoInicial,i,j,tagsAlvo;
  tamanho += acao;
  if ( tamanho < 0 ) tamanho = 0;
  if ( tamanho > 6 ) tamanho = 6;
  tamanhoInicial = tamanho;
  if ( !( selecionados = document.getElementById( idAlvo ) ) ) selecionados = document.getElementsByTagName( idAlvo )[ 0 ];
  
  selecionados.style.fontSize = tamanhos[ tamanho ];
  
  for ( i = 0; i < tagAlvo.length; i++ ){
    tagsAlvo = selecionados.getElementsByTagName( tagAlvo[ i ] );
    for ( j = 0; j < tagsAlvo.length; j++ ) tagsAlvo[ j ].style.fontSize = tamanhos[ tamanho ];
  }
}
// Fim do código de Aumentar/ Diminuir a letra
 
function imprimindo( id,pg ) {
    var oPrint, oJan;
    oPrint     = window.document.getElementById(id).innerHTML;
    oJan     = window.open(pg);
    oJan.document.write(oPrint);
    oJan.history.go();
    oJan.window.print();
}


function setFontSize(fontVal) {
var fontSet = document.getElementById('fontSet');
var docBase = new Array(); docBase = document.getElementsByTagName('table');
if (!fontVal) {fontVal = document.getElementById('fontSet').value;}
var docSize = fontVal+'px';
for(var i=0;i<docBase.length;i++)
docBase[i].style.fontSize = docSize;
var docBase = new Array(); docBase = document.getElementsByTagName('body');
docBase[0].style.fontSize = docSize;
docSize = (fontVal)+'px';
document.getElementById('materia').style.fontSize = docSize;
if (fontSet) {fontSet.value = fontVal;}
}


/*SCROLLER */

/* Vertical Slide © John Davenport Scheuer
 * This credit must remain for legal use */
/////////////////// No Need to Edit Main Script /////////////////
function vslide(){
if(!document.createElement)
return;
vslide.num=vslide.num? vslide.num+1 : 1; 
this.speed=arguments[2];
this.m1=[document.getElementById(arguments[0])], this.m=this.m1[0].parentNode, this.m2=[document.createElement('div')];
this.m2[0].innerHTML=this.m1[0].innerHTML.replace(/(\bsrc\b)/gi, ' onerror="this.er=1;"$1');
this.m.className=this.m2[0].className=this.m1[0].className;
this.m.style.height=arguments[1]+'px';
this.m.style.overflow='hidden';
this.m.appendChild(this.m2[0]);
this.m1[0].style.top=this.m2[0].style.top=0;
this.d=arguments[3];
var cacheobj=this;
if(arguments[4]){
this.m.onmouseover=function(){cacheobj.pause=1};
this.m.onmouseout=function(){cacheobj.pause=0};
}
if(arguments[5]){
vslide['reverse'+vslide.num]=function(){cacheobj.d=!cacheobj.d};
vslide['stop'+vslide.num]=function(){cacheobj.pause=1};
vslide['go'+vslide.num]=function(){cacheobj.pause=0};
vslide['up'+vslide.num]=function(){cacheobj.pause=cacheobj.d=0;};
vslide['down'+vslide.num]=function(){cacheobj.pause=0;cacheobj.d=1;};
vslide['obj'+vslide.num]=function(){return cacheobj};
vslide['slow'+vslide.num]=function(){cacheobj.speed=cacheobj.speed-2>0? cacheobj.speed-2 : 0;cacheobj.pause=cacheobj.speed>0? 0 : 1;}
vslide['fast'+vslide.num]=function(){cacheobj.speed=cacheobj.speed+2<9? cacheobj.speed+2 : 9;cacheobj.pause=0;}
vslide['top'+vslide.num]=function(){cacheobj.pause=1;cacheobj.m1[0].style.top=cacheobj.m2[0].style.top=0}
vslide['end'+vslide.num]=function(){cacheobj.pause=1;cacheobj.m1[0].style.top=cacheobj.m2[0].style.top=cacheobj.h+cacheobj.m.offsetHeight+'px'}
vslide['r'+vslide.num]=function(){var el=this;setTimeout(function(){el.onmouseout=function(){cacheobj.pause=1};},300);}
}
this.geth();
}
Array.prototype.gt=function(){
return parseInt(this[0].style.top);
}
vslide.prototype.geth=function(){
var cacheobj=this;
this.imgs=this.m2[0].getElementsByTagName('img');
for (var i = 0,c='complete',b='boolean'; i < this.imgs.length; i++)
if(typeof this.imgs[i][c]==b&&!this.imgs[i][c]&&!this.imgs[i].er){
setTimeout(function(){cacheobj.geth();},300);
return;
}
this.h=this.m2[0].offsetHeight*-1;
this.slide();
}
vslide.prototype.slide=function(){
var cacheobj=this;
if(window.opera)
this.h=this.m2[0].offsetHeight*-1;
if(!this.pause){
var s='style',t='top',m=this.m1,n=this.m2,d=this.d,h=this.h,p='px';
m[0][s][t]=n[0][s][t]=d&&m.gt()+1>0? h+p : d? m.gt()+1+p : m.gt()-1<h? 0 : m.gt()-1+p;

}

setTimeout(function(){cacheobj.slide()}, Math.max(10-this.speed, 1)*10);

}



/* Explanation of options used with each individual call in the BODY (nothing to edit here):

 * id - This will be the id and class name of a slides division - Not the optional container division.

 * height - This is the height of the slider - the width is set in the style section.

 * speed - This is the speed of the slider (1-9).

 * direction - Use 0 for up, 1 for down.

 * pause - Use 0 for no pause, 1 for pause onmouseover.

 * create functions - Use 0 for no added functions, 1 for additional functions to use with controls. */


