
///font1 variables
var font1_selector = "#interior h1"; //font color
var font1_font = "trajan1.swf"; //source swf for font display
var font1_color = "#324564"; //font color
var font1_link_color = "#000000";  //font color for link tag
var font1_hover_color = "#fa8300";   //font color on hover
var font1_bg_color = "0"; //background color
var font1_offset_left = 0;
var font1_offset_right = 0;
var font1_offset_top = 0;
var font1_offset_bottom = 0;
var font1_flash_vars = "null"; // additional flash properties
var font1_wmode = "transparent"; // flash background (null, transparent or opaque)
var font1_leading = "0";
var font1_kerning = "0";
var font1_letter_spacing = "0";
var font1_opacity = "100";
var font1_text_transform = "0";
var font1_font_size = "0";
var font1_cursor = "default";
var font1_display = "block";
var font1_text_align = "left";
var font1_font_weight = "normal";
var font1_text_decoration = "none";
var font1_preventWrap = true;
var font1_forceWidth = true;
var font1_fitExactly = false;
var font1_forceSingleLine = true;
var font1_forceClear = true;
var font1_tuneWidth = 0;
var font1_tuneHeight = 0;
var font1_antiAliasType = "normal"
var max_width_multiplier = 2;
var offsetTop_multiplier = 5.5;
//////////////////////////////////

///font2 variables
var font2_selector = "#home h1"; //font color
var font2_font = "trajan1.swf"; //source swf for font display
var font2_color = "#273F28"; //font color
var font2_link_color = "#000000";  //font color for link tag
var font2_hover_color = "#fa8300";   //font color on hover
var font2_bg_color = "0"; //background color
var font2_offset_left = 0;
var font2_offset_right = 0;
var font2_offset_top = 0;
var font2_offset_bottom = 0;
var font2_flash_vars = "null"; // additional flash properties
var font2_wmode = "transparent"; // flash background (null, transparent or opaque)
var font2_leading = "0";
var font2_kerning = "0";
var font2_letter_spacing = "0";
var font2_opacity = "100";
var font2_text_transform = "0";
var font2_font_size = "0";
var font2_cursor = "default";
var font2_display = "block";
var font2_text_align = "left";
var font2_font_weight = "normal";
var font2_text_decoration = "none";
var font2_preventWrap = false;
var font2_forceWidth = true;
var font2_fitExactly = false;
var font2_forceSingleLine = false;
var font2_forceClear = true;
var font2_tuneWidth = 0;
var font2_tuneHeight = 0;
var font2_antiAliasType = "normal"





function initSwfReplacement(){
	var active_dir;
	if(active_dir == undefined){
		if (document.getElementById("home")) { 
			active_dir = "";
		}else{
			active_dir = "../";
		}
	}
	/*****************************************************************************
	It is adviced to place the sIFR JavaScript calls in this file, keeping it
	separate from the `sifr.js` file. That way, you can easily swap the `sifr.js`
	file for a new version, while keeping the configuration.
	
	You must load this file *after* loading `sifr.js`.
	
	That said, you're of course free to merge the JavaScript files. Just make sure
	the copyright statement in `sifr.js` is kept intact.
	*****************************************************************************/
	
	// Make an object pointing to the location of the Flash movie on your web server.
	// Try using the font name as the variable name, makes it easy to remember which
	// object you're using. As an example in this file, we'll use Futura.
	var font1 = { src: active_dir + "_swf_replacement/" + font1_font };
	var font2 = { src: active_dir + "_swf_replacement/" + font2_font };
	
	// Now you can set some configuration settings.
	// See also <http://wiki.novemberborn.net/sifr3/JavaScript+Configuration>.
	// One setting you probably want to use is `sIFR.useStyleCheck`. Before you do that,
	// read <http://wiki.novemberborn.net/sifr3/DetectingCSSLoad>.
	
	// sIFR.useStyleCheck = true;
	
	// Next, activate sIFR:
	sIFR.activate(font1, font2);
	
	
	// If you want, you can use multiple movies, like so:
	//
	//    var futura = { src: '/path/to/futura.swf' };
	//    var garamond = { src '/path/to/garamond.swf' };
	//    var rockwell = { src: '/path/to/rockwell.swf' };
	//    
	//    sIFR.activate(futura, garamond, rockwell);
	//
	// Remember, there must be *only one* `sIFR.activate()`!
	
	// Now we can do the replacements. You can do as many as you like, but just
	// as an example, we'll replace all `<h1>` elements with the Futura movie.
	// 
	// The first argument to `sIFR.replace` is the `futura` object we created earlier.
	// The second argument is another object, on which you can specify a number of
	// parameters or "keyword arguemnts". For the full list, see "Keyword arguments"
	// under `replace(kwargs, mergeKwargs)` at 
	// <http://wiki.novemberborn.net/sifr3/JavaScript+Methods>.
	// 
	// The first argument you see here is `selector`, which is a normal CSS selector.
	// That means you can also do things like '#content h1' or 'h1.title'.
	//
	// The second argument determines what the Flash text looks like. The main text
	// is styled via the `.sIFR-root` class. Here we've specified `background-color`
	// of the entire Flash movie to be a light grey, and the `color` of the text to
	// be red. Read more about styling at <http://wiki.novemberborn.net/sifr3/Styling>.
	
sIFR.replace(font1, {
	  selector: font1_selector,
	  wmode: font1_wmode,
	  offsetTop : font1_offset_top,
	  offsetRight : font1_offset_right,
	  offsetLeft : font1_offset_left,
	  offsetBottom : font1_offset_bottom,
	  preventWrap: font1_preventWrap,
	  forceWidth: font1_forceWidth,
	  fitExactly: font1_fitExactly,
	  forceSingleLine: font1_forceSingleLine,
	  forceClear: font1_forceClear,
	  tuneWidth: font1_tuneWidth,
	  tuneHeight: font1_tuneHeight,
	  antiAliasType: font1_antiAliasType,
	  css: ['.sIFR-root { background-color: '+font1_bg_color+'; color: '+font1_color+'; text-align: '+font1_text_align+'; font-weight: '+font1_font_weight+';leading: '+font1_leading+'; kerning: '+font1_kerning+'; letter-spacing: '+font1_letter_spacing+';opacity: '+font1_opacity+';text-transform: '+font1_text_transform+';font-size: '+font1_font_size+';cursor: '+font1_cursor+';display: '+font1_display+';}'
			,'a { text-decoration: '+font1_text_decoration+'; }'
			,'a:link { color: '+font1_link_color+'; }'
			,'a:hover { color: '+font1_hover_color+'; }'
			
			]
	});
	
	sIFR.replace(font2, {
	  selector: font2_selector,
	  wmode: font2_wmode,
	  offsetTop : font2_offset_top,
	  offsetRight : font2_offset_right,
	  offsetLeft : font2_offset_left,
	  offsetBottom : font2_offset_bottom,
	  preventWrap: font2_preventWrap,
	  forceWidth: font2_forceWidth,
	  fitExactly: font2_fitExactly,
	  forceSingleLine: font2_forceSingleLine,
	  forceClear: font2_forceClear,
	  tuneWidth: font2_tuneWidth,
	  tuneHeight: font2_tuneHeight,
	  antiAliasType: font2_antiAliasType,
	  css: ['.sIFR-root { background-color: '+font2_bg_color+'; color: '+font2_color+'; text-align: '+font2_text_align+'; font-weight: '+font2_font_weight+';leading: '+font2_leading+'; kerning: '+font2_kerning+'; letter-spacing: '+font2_letter_spacing+';opacity: '+font2_opacity+';text-transform: '+font2_text_transform+';font-size: '+font2_font_size+';cursor: '+font2_cursor+';display: '+font2_display+';}'
			,'a { text-decoration: '+font2_text_decoration+'; }'
			,'a:link { color: '+font2_link_color+'; }'
			,'a:hover { color: '+font2_hover_color+'; }'
			
			]
	});
}
