Merge branch 'master' of https://source.jalview.org/git/jalviewjs.git
[jalviewjs.git] / site / j2s / swingjs / JSPlainDocument.js
index e11ce3d..5a11b91 100644 (file)
@@ -1,57 +1,57 @@
-Clazz.declarePackage ("swingjs");\r
-Clazz.load (["swingjs.JSAbstractDocument"], "swingjs.JSPlainDocument", ["java.util.Hashtable", "JU.SB", "swingjs.JSPosition"], function () {\r
-c$ = Clazz.declareType (swingjs, "JSPlainDocument", swingjs.JSAbstractDocument);\r
-Clazz.makeConstructor (c$, \r
-function () {\r
-Clazz.superConstructor (this, swingjs.JSPlainDocument);\r
-this.sb =  new JU.SB ();\r
-this.root = Clazz.innerTypeInstance (swingjs.JSAbstractDocument.JSElement, this, null);\r
-});\r
-Clazz.overrideMethod (c$, "getLength", \r
-function () {\r
-return this.sb.length ();\r
-});\r
-Clazz.defineMethod (c$, "getText", \r
-function (offset, length) {\r
-this.checkLoc (offset, offset + length);\r
-return this.sb.substring2 (offset, offset + length);\r
-}, "~N,~N");\r
-Clazz.defineMethod (c$, "getText", \r
-function (offset, length, chars) {\r
-this.checkLoc (offset, offset + length);\r
-if (this.tempChar == null) {\r
-this.tempChar =  Clazz.newCharArray (this.sb.length (), '\0');\r
-for (var i = this.tempChar.length; --i >= 0; ) this.tempChar[i] = this.sb.charAt (i);\r
-\r
-}chars.array = this.tempChar;\r
-chars.offset = offset;\r
-chars.count = length;\r
-}, "~N,~N,javax.swing.text.Segment");\r
-Clazz.overrideMethod (c$, "getStartPosition", \r
-function () {\r
-return  new swingjs.JSPosition (0);\r
-});\r
-Clazz.overrideMethod (c$, "getEndPosition", \r
-function () {\r
-return  new swingjs.JSPosition (this.sb.length ());\r
-});\r
-Clazz.overrideMethod (c$, "createPosition", \r
-function (offs) {\r
-this.checkLoc (offs, offs);\r
-var i = Integer.$valueOf (offs);\r
-if (this.positions == null) this.positions =  new java.util.Hashtable ();\r
-var p = this.positions.get (i);\r
-if (p == null) this.positions.put (i, p =  new swingjs.JSPosition (offs));\r
-return p;\r
-}, "~N");\r
-Clazz.overrideMethod (c$, "getDefaultRootElement", \r
-function () {\r
-return this.root;\r
-});\r
-Clazz.overrideMethod (c$, "render", \r
-function (r) {\r
-}, "Runnable");\r
-Clazz.defineStatics (c$,\r
-"tabSizeAttribute", "tabSize",\r
-"lineLimitAttribute", "lineLimit");\r
-});\r
+Clazz.declarePackage ("swingjs");
+Clazz.load (["swingjs.JSAbstractDocument"], "swingjs.JSPlainDocument", ["java.util.Hashtable", "JU.SB", "swingjs.JSPosition"], function () {
+c$ = Clazz.declareType (swingjs, "JSPlainDocument", swingjs.JSAbstractDocument);
+Clazz.makeConstructor (c$, 
+function () {
+Clazz.superConstructor (this, swingjs.JSPlainDocument);
+this.sb =  new JU.SB ();
+this.root = Clazz.innerTypeInstance (swingjs.JSAbstractDocument.JSElement, this, null);
+});
+Clazz.overrideMethod (c$, "getLength", 
+function () {
+return this.sb.length ();
+});
+Clazz.defineMethod (c$, "getText", 
+function (offset, length) {
+this.checkLoc (offset, offset + length);
+return this.sb.substring2 (offset, offset + length);
+}, "~N,~N");
+Clazz.defineMethod (c$, "getText", 
+function (offset, length, chars) {
+this.checkLoc (offset, offset + length);
+if (this.tempChar == null) {
+this.tempChar =  Clazz.newCharArray (this.sb.length (), '\0');
+for (var i = this.tempChar.length; --i >= 0; ) this.tempChar[i] = this.sb.charAt (i);
+
+}chars.array = this.tempChar;
+chars.offset = offset;
+chars.count = length;
+}, "~N,~N,javax.swing.text.Segment");
+Clazz.overrideMethod (c$, "getStartPosition", 
+function () {
+return  new swingjs.JSPosition (0);
+});
+Clazz.overrideMethod (c$, "getEndPosition", 
+function () {
+return  new swingjs.JSPosition (this.sb.length ());
+});
+Clazz.overrideMethod (c$, "createPosition", 
+function (offs) {
+this.checkLoc (offs, offs);
+var i = Integer.$valueOf (offs);
+if (this.positions == null) this.positions =  new java.util.Hashtable ();
+var p = this.positions.get (i);
+if (p == null) this.positions.put (i, p =  new swingjs.JSPosition (offs));
+return p;
+}, "~N");
+Clazz.overrideMethod (c$, "getDefaultRootElement", 
+function () {
+return this.root;
+});
+Clazz.overrideMethod (c$, "render", 
+function (r) {
+}, "Runnable");
+Clazz.defineStatics (c$,
+"tabSizeAttribute", "tabSize",
+"lineLimitAttribute", "lineLimit");
+});