home *** CD-ROM | disk | FTP | other *** search
- package webeq3.schema;
-
- import java.util.Vector;
- import webeq3.app.Equation;
- import webeq3.util.OutputHandler;
-
- public class MFenced extends MRow {
- Vector children_orig = null;
-
- public MFenced(Box var1) {
- super(var1);
- super.type = 68;
- }
-
- public MFenced() {
- super.type = 68;
- }
-
- public MFenced(Equation var1) {
- super(var1);
- super.type = 68;
- }
-
- public void size() {
- if (super.attributes[42] != null) {
- super.attribute_stack[42].pop();
- }
-
- if (super.attributes[43] != null) {
- super.attribute_stack[43].pop();
- }
-
- if (super.attributes[52] != null) {
- super.attribute_stack[52].pop();
- }
-
- super.fgcolor = ((Box)this).resolveColor(4);
- super.bgcolor = ((Box)this).resolveColor(17);
- super.atomic = false;
- if (this.children_orig == null) {
- this.children_orig = super.children;
- super.children = new Vector();
- String var1 = ((Box)this).getAttributeByIndex(42);
- MO var2 = new MO(this);
- ((Box)var2).addData(var1);
- ((Box)this).addChild(var2);
- var1 = ((Box)this).getAttributeByIndex(52);
- int var3 = var1.length();
- Object var4 = null;
- Object var5 = null;
-
- for(int var6 = 0; var6 < this.children_orig.size() - 1; ++var6) {
- Box var10 = (Box)this.children_orig.elementAt(var6);
- var10.setParent(this);
- ((Box)this).addChild(var10);
- if (var3 > 0) {
- MO var12 = new MO(this);
- if (var6 < var3) {
- ((Box)var12).addData(var1.substring(var6, var6 + 1));
- } else {
- ((Box)var12).addData(var1.substring(var3 - 1));
- }
-
- ((Box)this).addChild(var12);
- }
- }
-
- if (this.children_orig.size() > 0) {
- Box var11 = (Box)this.children_orig.elementAt(this.children_orig.size() - 1);
- var11.setParent(this);
- ((Box)this).addChild(var11);
- }
-
- var1 = ((Box)this).getAttributeByIndex(43);
- MO var7 = new MO(this);
- ((Box)var7).addData(var1);
- ((Box)this).addChild(var7);
- }
-
- super.size();
- }
-
- public void position() {
- if (super.attributes[42] != null) {
- super.attribute_stack[42].push(super.attributes[42]);
- }
-
- if (super.attributes[43] != null) {
- super.attribute_stack[43].push(super.attributes[43]);
- }
-
- if (super.attributes[52] != null) {
- super.attribute_stack[52].push(super.attributes[52]);
- }
-
- super.position();
- }
-
- public void printSelected(String var1, OutputHandler var2, boolean var3, boolean var4, String var5, boolean var6, int var7) {
- if (var3 && !super.reverse_video) {
- for(int var9 = 0; var9 < super.children.size(); ++var9) {
- ((Box)this).getChild(var9).printSelected(var1, var2, var3, var4, var5, var6, var7);
- }
- } else if (var6 && super.cpeer != null) {
- super.cpeer.printSelected(var1, var2, var3, var4, var5, var6, var7);
- } else {
- Vector var8 = super.children;
- super.children = this.children_orig;
- super.printSelected(var1, var2, var3, var4, var5, var6, var7);
- super.children = var8;
- }
-
- }
- }
-