// radi pomoću style dokumenta, dosta problema pri pretrazi na klik
var doc = document.implementation.createHTMLDocument("");
var styleElement = document.createElement("style");
styleElement.textContent = editors.ace.session.getValue();
doc.body.appendChild(styleElement);
var rules = styleElement.sheet.cssRules;
if(!rules) return;
for(var i=0; i<rules.length; i++) {
	var rule = rules[i];
	var txt = rule.selectorText;
	var ic = '&gt;';
	var cssBody = rule.cssBody;
	if(txt == "") continue;
	if(txt[0] == '.') ic = '&#119914;';
	if(txt[0] == '#') ic = '&num;';
	if(txt[0] == '@') ic = '&commat;';
	//ul, tx, ar, ln, ic, ti='', mclick, sr
	var li = outline.addItem(ul, txt, "", i, ic, txt, outline.itmClickAlt, txt);
	console.log(rule);
}
styleElement.remove();
doc = null;
rules = null;
