

$(document).ready(function() 
{
	// create div which will contain out transparent layout grid.
	$('body').append('<div id="t-layout-grid" style="position: fixed; display: none; background: url(/js/Tangerine/layout-grid.png); width: 100%; height: 100%; top: 0px; left: 0px; z-index: 1000;">&nbsp;</div>');
	// create a keyboard handler to show/hide the layout grid.
	$(document).keypress(function(event) 
	{
		// press the 'g' key (103) to toggle visibility of the layout grid.
		if (event.which == 103)
		{
			var grid = $('#t-layout-grid');
			if (grid.is(':hidden'))
			{
				grid.show();
			}
			else {
				grid.hide();
			}
		}
    });	
});
	
