var initWordCloudSetting = function(canvas) {

	var wfl = 1, fgec = false;
	if ($(canvas).attr('width') < 700) {
		wfl = $(canvas).attr('width') / 500;
	}
	
	var wordColorScheme = ['random-normal', 'random-impress'];
	var wordColorType = wordColorScheme[Math.floor(Math.random() * wordColorScheme.length)];
	
	var mySettings = { 
		wordList: [],
		ellipticity: 0.65, 
		gridSize: 4,
		adjustX: function() { return ($.browser.msie ? 0 : -1 * $(canvas).offset().left); },
		adjustY: function() { return ($.browser.msie ? 0 : -1 * $(canvas).offset().top); },
		weightFactorLevel: wfl,
		weightFactor: function(weight) {
			var fontSize = weight * (this.weightFactorLevel);
			fontSize *= 1.6 - ((80 - fontSize) / 80 );
			if (fontSize <= 20) {
				fontSize = 18;
			}
			
			if (mySettings.wordList.length <= 20)
				fontSize *= 1.5;
			else if (mySettings.wordList.length <= 40)
				fontSize *= 1.25;
			return fontSize;
		},
		zoomToFit: false,
		shadowType: 5,
		wordColor: wordColorType,
		startCallback: function() {
				var x = $(canvas).offset().left;
				var y = $(canvas).offset().top;
				$("#LoadingImage").css({left:x,top:y}); 
				$("#LoadingImage").show();
			},
		fasterGridEmptyChecker: fgec,
		finishCallback: function() {
				$("#LoadingImage").hide();
			},
		};
	return mySettings;
};
		
