芝麻web文件管理V1.00
编辑当前文件:/home2/sdektunc/.trash/media.4/vendor/codemirror/addon/wrap/hardwrap.min.js
!function(t){"object"==typeof exports&&"object"==typeof module?t(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define(["../../lib/codemirror"],t):t(CodeMirror)}((function(t){"use strict";var r=t.Pos;function e(t,r,e){for(var n=e.paragraphStart||t.getHelper(r,"paragraphStart"),o=r.line,a=t.firstLine();o>a;--o){var i=t.getLine(o);if(n&&n.test(i))break;if(!/\S/.test(i)){++o;break}}for(var f=e.paragraphEnd||t.getHelper(r,"paragraphEnd"),l=r.line+1,h=t.lastLine();l<=h;++l){i=t.getLine(l);if(f&&f.test(i)){++l;break}if(!/\S/.test(i))break}return{from:o,to:l}}function n(t,r,e,n,o){for(var a=r;a
0&&!e.test(t.slice(a-1,a+1));--a);if(!o&&a<=t.match(/^[ \t]*/)[0].length)for(a=r+1;a
=f&&(f=u.length+1);for(var v=0;v
f&&u==k&&n(g,f,l,s,h);S&&S.from==b&&S.to==b+x?(g=u+d,++p):c.push({text:[x?" ":""],from:r(p,b),to:r(p+1,k.length)})}for(;g.length>f;){var E=n(g,f,l,s,h);if(!(E.from!=E.to||h&&u!==g.slice(0,E.to)))break;c.push({text:["",u],from:r(p,E.from),to:r(p,E.to)}),g=u+g.slice(E.to),++p}}return c.length&&e.operation((function(){for(var r=0;r
=0;i--){var f,l=n[i];if(l.empty()){var h=e(t,l.head,{});f={from:r(h.from,0),to:r(h.to-1)}}else f={from:l.from(),to:l.to()};f.to.line>=a||(a=f.from.line,o(t,f.from,f.to,{}))}}))},t.defineExtension("wrapRange",(function(t,r,e){return o(this,t,r,e||{})})),t.defineExtension("wrapParagraphsInRange",(function(t,n,a){a=a||{};for(var i=this,f=[],l=t.line;l<=n.line;){var h=e(i,r(l,0),a);f.push(h),l=h.to}var s=!1;return f.length&&i.operation((function(){for(var t=f.length-1;t>=0;--t)s=s||o(i,r(f[t].from,0),r(f[t].to-1),a)})),s}))}));