rem: tr = doc.createElement("tr"); tbody.appendChild(tr); td = doc.createElement("td"); td.className = "label"; tr.appendChild(td); td.innerHTML = i18n["Width"] + ":"; td = doc.createElement("td"); tr.appendChild(td); input = doc.createElement("input"); input.type = "text"; input.value = TableOperations.getLength(el.style.width); input.size = "5"; input.name = "f_st_width"; input.style.marginRight = "0.5em"; td.appendChild(input); select = doc.createElement("select"); select.name = "f_st_widthUnit"; option = doc.createElement("option"); option.innerHTML = i18n["percent"]; option.value = "%"; option.selected = /%/.test(el.style.width); select.appendChild(option); option = doc.createElement("option"); option.innerHTML = i18n["pixels"]; option.value = "px"; option.selected = /px/.test(el.style.width); select.appendChild(option); td.appendChild(select); 
add: tr = doc.createElement("tr"); tbody.appendChild(tr); td = doc.createElement("td"); td.className = "label"; tr.appendChild(td); td.innerHTML = i18n["Width"] + ":"; td = doc.createElement("td"); tr.appendChild(td); input = doc.createElement("input"); input.type = "text"; input.value = TableOperations.getLength(el.style.width); input.size = "5"; input.name = "f_st_width"; input.style.marginRight = "0.5em"; td.appendChild(input); select = doc.createElement("select"); select.name = "f_st_widthUnit"; option = doc.createElement("option"); option.innerHTML = i18n["percent"]; option.value = "%"; option.selected = /%/.test(el.style.width); select.appendChild(option); option = doc.createElement("option"); option.innerHTML = i18n["pixels"]; option.value = "px"; option.selected = /px/.test(el.style.width); select.appendChild(option); td.appendChild(select); 
context: TableOperations.createStyleLayoutFieldset = function(doc, editor, el) {	var i18n = TableOperations.I18N;	var fieldset = doc.createElement("fieldset");	var legend = doc.createElement("legend");	fieldset.appendChild(legend);	legend.innerHTML = i18n["Layout"];	var table = doc.createElement("table");	fieldset.appendChild(table);	table.style.width = "100%";	var tbody = doc.createElement("tbody");	table.appendChild(tbody);	var tagname = el.tagName.toLowerCase();	var tr, td, input, select, option, options, i;	if (tagname != "td" && tagname != "tr" && tagname != "th") {		tr = doc.createElement("tr");		tbody.appendChild(tr);		td = doc.createElement("td");		td.className = "label";		tr.appendChild(td);		td.innerHTML = i18n["Float"] + ":";		td = doc.createElement("td");		tr.appendChild(td);		select = doc.createElement("select");		td.appendChild(select);		select.name = "f_st_float";		options = ["None", "Left", "Right"];		for (i in options) {			var Val = options[i];			var val = options[i].toLowerCase();			option = doc.createElement("option");			option.innerHTML = i18n[Val];			option.value = val;			option.selected = (("" + el.style.cssFloat).toLowerCase() == val);			select.appendChild(option);		}	}	tr = doc.createElement("tr");	tbody.appendChild(tr);	td = doc.createElement("td");	td.className = "label";	tr.appendChild(td);	td.innerHTML = i18n["Width"] + ":";	td = doc.createElement("td");	tr.appendChild(td);	input = doc.createElement("input");	input.type = "text";	input.value = TableOperations.getLength(el.style.width);	input.size = "5";	input.name = "f_st_width";	input.style.marginRight = "0.5em";	td.appendChild(input);	select = doc.createElement("select");	select.name = "f_st_widthUnit";	option = doc.createElement("option");	option.innerHTML = i18n["percent"];	option.value = "%";	option.selected = /%/.test(el.style.width);	select.appendChild(option);	option = doc.createElement("option");	option.innerHTML = i18n["pixels"];	option.value = "px";	option.selected = /px/.test(el.style.width);	select.appendChild(option);	td.appendChild(select);	select.style.marginRight = "0.5em";	td.appendChild(doc.createTextNode(i18n["Text align"] + ":"));	select = doc.createElement("select");	select.style.marginLeft = select.style.marginRight = "0.5em";	td.appendChild(select);	select.name = "f_st_textAlign";	options = ["Left", "Center", "Right", "Justify"];	if (tagname == "td") {		options.push("Char");	}	input = doc.createElement("input");	input.name = "f_st_textAlignChar";	input.size = "1";	input.style.fontFamily = "monospace";	td.appendChild(input);	for (i in options) {		var Val = options[i];		var val = Val.toLowerCase();		option = doc.createElement("option");		option.value = val;		option.innerHTML = i18n[Val];		option.selected = (el.style.textAlign.toLowerCase() == val);		select.appendChild(option);	}	function setCharVisibility(value) {		input.style.visibility = value ? "visible" : "hidden";		if (value) {			input.focus();			input.select();		}	};	select.onchange = function() { setCharVisibility(this.value == "char"); };	setCharVisibility(select.value == "char");	tr = doc.createElement("tr");	tbody.appendChild(tr);	td = doc.createElement("td");	td.className = "label";	tr.appendChild(td);	td.innerHTML = i18n["Height"] + ":";	td = doc.createElement("td");	tr.appendChild(td);	input = doc.createElement("input");	input.type = "text";	input.value = TableOperations.getLength(el.style.height);	input.size = "5";	input.name = "f_st_height";	input.style.marginRight = "0.5em";	td.appendChild(input);	select = doc.createElement("select");	select.name = "f_st_heightUnit";	option = doc.createElement("option");	option.innerHTML = i18n["percent"];	option.value = "%";	option.selected = /%/.test(el.style.height);	select.appendChild(option);	option = doc.createElement("option");	option.innerHTML = i18n["pixels"];	option.value = "px";	option.selected = /px/.test(el.style.height);	select.appendChild(option);	td.appendChild(select);	select.style.marginRight = "0.5em";	td.appendChild(doc.createTextNode(i18n["Vertical align"] + ":"));	select = doc.createElement("select");	select.name = "f_st_verticalAlign";	select.style.marginLeft = "0.5em";	td.appendChild(select);	options = ["Top", "Middle", "Bottom", "Baseline"];	for (i in options) {		var Val = options[i];		var val = Val.toLowerCase();		option = doc.createElement("option");		option.value = val;		option.innerHTML = i18n[Val];		option.selected = (el.style.verticalAlign.toLowerCase() == val);		select.appendChild(option);	}	return fieldset;};
meta: 752	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/752/b95cfe0a8ebbc3a21a218afd124442c6ec979137/table-operations.js/buggy/lib/editor/plugins/TableOperations/table-operations.js