• 笙默考试管理系统-MyExamTest----codemirror(30)


    笙默考试管理系统-MyExamTest----codemirror(30

    目录

    一、 笙默考试管理系统-MyExamTest

    二、 笙默考试管理系统-MyExamTest

    三、 笙默考试管理系统-MyExamTest

    四、 笙默考试管理系统-MyExamTest

    五、 笙默考试管理系统-MyExamTest

    • 笙默考试管理系统-MyExamTest

     },

            backUp: function(n) {this.pos -= n;},

            column: function() {return countColumn(this.string, this.start, this.tabSize);},

            indentation: function() {return countColumn(this.string, null, this.tabSize);},

            match: function(pattern, consume, caseInsensitive) {

                if (typeof pattern == "string") {

                    function cased(str) {return caseInsensitive ? str.toLowerCase() : str;}

                    if (cased(this.string).indexOf(cased(pattern), this.pos) == this.pos) {

                        if (consume !== false) this.pos += pattern.length;

                        return true;

                    }

                }

    • 笙默考试管理系统-MyExamTest

                else {

                    var match = this.string.slice(this.pos).match(pattern);

                    if (match && consume !== false) this.pos += match[0].length;

                    return match;

                }

            },

            current: function(){return this.string.slice(this.start, this.pos);}

        };

        CodeMirror.StringStream = StringStream;

    • 笙默考试管理系统-MyExamTest

        function MarkedText(from, to, className, set) {

            this.from = from; this.to = to; this.style = className; this.set = set;

        }

        MarkedText.prototype = {

            attach: function(line) { this.set.push(line); },

            detach: function(line) {

                var ix = indexOf(this.set, line);

                if (ix > -1) this.set.splice(ix, 1);

            },

    • 笙默考试管理系统-MyExamTest

            split: function(pos, lenBefore) {

                if (this.to <= pos && this.to != null) return null;

                var from = this.from < pos || this.from == null ? null : this.from - pos + lenBefore;

                var to = this.to == null ? null : this.to - pos + lenBefore;

                return new MarkedText(from, to, this.style, this.set);

            },

    • 笙默考试管理系统-MyExamTest

            dup: function() { return new MarkedText(null, null, this.style, this.set); },

            clipTo: function(fromOpen, from, toOpen, to, diff) {

                if (this.from != null && this.from >= from)

                    this.from = Math.max(to, this.from) + diff;

                if (this.to != null && this.to > from)

                    this.to = to < this.to ? this.to + diff : from;

                if (fromOpen && to > this.from && (to < this.to || this.to == null))

                    this.from = null;

                if (toOpen && (from < this.to || this.to == null) && (from > this.from || this.from == null))

                    this.to = null;

  • 相关阅读:
    信息通信企业开展数据安全管理工作的指引与实践
    Python数据结构——树
    vue异步加载数据 传递给 子组件,触发mounted方法,子组件修改父组件值
    基础 | JVM - [Object & 锁升级]
    无人化微波产品智能测试系统
    【二分查找】【键值皆有序】1840最高建筑高度
    Istio学习笔记-体验istio
    python+vue+elementui中小银行客户信息管理系统
    (论文阅读31/100)Stacked hourglass networks for human pose estimation
    方法引用与构造器引用(Method References)第三版
  • 原文地址:https://blog.csdn.net/N201871643/article/details/133880668