

//Specify affected tags. Add or remove from list:
var tgs = new Array( 'span','font','p');

//Specify spectrum of different font sizes:
var szs = new Array( '12pt','14pt','16pt','18pt','20pt' );
var lhs = new Array( '3','5','7','9','14' );
var startSz = 2;
var startlh = 2;

function ts( trgt,inc ) {
	if (!document.getElementById) return
	var d = document,cEl = null,sz = startSz,i,j,cTags,lh=startlh;
	
	sz += inc;
	if ( sz < 0 ) sz = 0;
	if ( sz > 6 ) sz = 6;
	startSz = sz;
	lh += inc;
	if ( lh < 0 ) lh = 0;
	if ( lh > 6 ) lh = 6;
	startlh = lh;


		
	if ( !( cEl = d.getElementById( trgt ) ) ) cEl = d.getElementsByTagName( trgt )[ 0 ];

	cEl.style.fontSize = szs[ sz ];
	cEl.style.lineheight = lhs[ lh ];

	for ( i = 0 ; i < tgs.length ; i++ ) {
		cTags = cEl.getElementsByTagName( tgs[ i ] );
		
for ( j = 0 ; j < cTags.length ; j++ ) cTags[ j ].style.fontSize = szs[ sz ];



		for ( j = 0 ; j < cTags.length ; j++ ) cTags[ j ].style.lineheight = "2";


	}
}
