String.extend({deCamelize:function(){
return this.replace(/([a-z])([A-Z])/g,"$1 $2");
}});
function $getText(el){
return el.innerText||el.textContent||"";
}
Element.extend({injectWrapper:function(el){
while(el.firstChild){
this.appendChild(el.firstChild);
}
el.appendChild(this);
return this;
},visible:function(){
var el=this;
while($type(el)=="element"){
if(el.getStyle("visibility")=="hidden"){
return false;
}
if(el.getStyle("display")=="none"){
return false;
}
el=el.getParent();
}
return true;
},hide:function(){
this.style.display="none";
return this;
},show:function(){
this.style.display="";
return this;
},toggle:function(){
this.visible()?this.hide():this.show();
return this;
},scrollTo:function(x,y){
this.scrollLeft=x;
this.scrollTop=y;
},getPosition:function(_6){
_6=_6||[];
var el=this,_8=0,_9=0;
do{
_8+=el.offsetLeft||0;
_9+=el.offsetTop||0;
el=el.offsetParent;
}while(el);
_6.each(function(_a){
_8-=_a.scrollLeft||0;
_9-=_a.scrollTop||0;
});
return {"x":_8,"y":_9};
}});

var WikiPrettify={onPageLoad:function(){
var els=$$(".prettify pre, .prettify code");
if(!els){
return;
}
els.addClass("prettyprint");
prettyPrint();
}};
window.addEvent("load",function(){
WikiPrettify.onPageLoad();
});

