window.onresize = function(){
	var area = document.getElementById("area");
	{
		var text = document.getElementById("text");
		{
			var height = parseInt(area.offsetHeight || area.scrollHeight);
			{
				var bottom = parseInt(text.style.bottom) || 0;
				{
					height = height - bottom;
				}
				
				var top = parseInt(text.style.top) || 0;
				{
					height = height - top;
				}
				
				text.style.height = height + "px";
			}
		}
	}
}

window.onload = function(){
	onresize();
	
	{
		var text = document.getElementById("text");
		{
			text.style.overflow = "scroll";
		}
	}
}