Sha256: df928c0233d5784d3cc38cbd9e4405764a5e9b5ce298f244c1a49c7ecccfc8b7

Contents?: true

Size: 573 Bytes

Versions: 25

Compression:

Stored size: 573 Bytes

Contents

function codemirrorHighlight(target_id) {
  modes = CodeMirror.listModes();
  for (var x = 0; x < modes.length; x++){
    if (modes[x] != 'null'){
      target_div = document.getElementById(target_id);
      if (target_div != null){
        tags = target_div.getElementsByTagName(modes[x]);
        for (var i = 0; i < tags.length; i++) {
          output = tags[i];
          output.className += ' cm-s-default';
          output.style.cssText = "white-space: pre;";
          CodeMirror.runMode(tags[i].innerHTML, modes[x],  output);
        }        
      }
    }
  }
}

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
erp_app-3.1.16 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.15 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.14 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.13 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.12 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.11 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.10 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.9 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.8 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.7 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.6 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.5 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.4 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.3 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.2 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.0.16 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.0.15 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.1 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.1.0 public/javascripts/erp_app/codemirror_highlight.js
erp_app-3.0.14 public/javascripts/erp_app/codemirror_highlight.js