-function Colourise(line, entity) {
+qwebirc.ui.Colourise = function(line, entity, execfn, cmdfn, window) {
var fg;
var bg;
var underline = false;
function emitEndToken() {
if(out.length > 0) {
- urlificate(element, out.join(""));
+ qwebirc.ui.urlificate(element, out.join(""), execfn, cmdfn, window);
entity.appendChild(element);
out = [];
}
element = document.createElement("span");
}
function emitStartToken() {
- classes = []
+ var classes = []
if(fg != undefined)
classes.push("Xc" + fg);
if(bg != undefined)
element.className = classes.join(" ");
}
- for(i=0;i<xline.length;i++) {
+ for(var i=0;i<xline.length;i++) {
var lc = xline[i];
if(lc == "\x02") {
emitEndToken();
}
emitEndToken();
-}
\ No newline at end of file
+}