Back to index

wims  3.65+svn20090927
sHotEqn.java
Go to the documentation of this file.
00001 package atp;
00002 
00003 import java.awt.*;
00004 import java.awt.event.*;
00005 import java.util.Hashtable;
00006 
00007 // Referenced classes of package atp:
00008 //            f, b, a, c, 
00009 //            e
00010 
00011 public class sHotEqn
00012 {
00013 
00014        Component PC; // container panel
00015        
00016     private int width;
00017     private int height;
00018     private String h;
00019     private String _fldcase;
00020     private String _fldint;
00021     ActionListener G;
00022     private b S;
00023     private e D;
00024     private Font d;
00025     private Font b;
00026     private Font _fldnull;
00027     private Font _fldlong;
00028     private static final float k = 2F;
00029     private static final int _fldvoid[] = {
00030         8, 10, 12, 14, 18
00031     };
00032     private static final int O[] = {
00033         2, 3, 4, 5, 6
00034     };
00035     private int j[] = {
00036         14, 12, 10, 8
00037     };
00038     private int _fldfor[] = {
00039         3, 3, 3, 3
00040     };
00041     private static final int _fldgoto[] = {
00042         9, 11, 14, 16, 22
00043     };
00044     private Image s;
00045     private boolean Q;
00046     private int f;
00047     private int H;
00048     private Color _fldbyte;
00049     private Color N;
00050     private Color _fldtry;
00051     private Color C;
00052     private boolean K;
00053     private boolean u;
00054     private int g;
00055     private String z;
00056     private String E;
00057     private int M;
00058     private int i;
00059     private boolean e;
00060     private f _flddo;
00061     private MediaTracker B;
00062     private Hashtable w;
00063     public boolean r;
00064     public boolean L;
00065     public boolean q;
00066     private boolean A;
00067     private boolean t;
00068     private int _fldelse;
00069     private int _fldchar;
00070     private int J;
00071     private int I;
00072     private int v;
00073     private int P;
00074     private int a;
00075     private int m;
00076     private int R;
00077     private int l;
00078     private int F;
00079     private boolean c;
00080     private int p;
00081     private int o;
00082     private Image _fldnew;
00083 
00084      public sHotEqn (Component PC)
00085     {
00086         width = 0;
00087         height = 0;
00088         h = null;
00089         _fldcase = null;
00090         _fldint = "Helvetica";
00091         Q = false;
00092         f = 0;
00093         H = 0;
00094         _fldbyte = Color.white;
00095         N = Color.white;
00096         _fldtry = Color.black;
00097         C = Color.red;
00098         K = false;
00099         u = false;
00100         g = 0;
00101         z = "left";
00102         E = "top";
00103         M = 0;
00104         i = 0;
00105         e = false;
00106         w = new Hashtable(13);
00107         r = false;
00108         L = false;
00109         q = true;
00110         A = false;
00111         t = true;
00112         _fldelse = 0;
00113         _fldchar = 0;
00114         J = 0;
00115         I = 0;
00116         v = 0;
00117         P = 0;
00118         a = 0;
00119         m = 0;
00120         R = 0;
00121         l = 0;
00122         F = 5;
00123         c = false;
00124         p = 0;
00125         o = 0;
00126         _flddo = new f();
00127         B = new MediaTracker(PC);
00128         S = new b("");
00129     }
00130      
00131      public void setEquation(String s1)
00132     {
00133         _fldcase = s1;
00134         S.a(s1);
00135         e = false;
00136         Q = false;
00137     }
00138 
00139     public String getEquation()
00140     {
00141         return _fldcase;
00142     }
00143     
00144     public String Status;
00145 
00146     public void printStatus(String s1)
00147     {
00148        Status =s1;   
00149     }
00150 
00151     private void a(String s1)
00152     {
00153        Status = s1;
00154        
00155     }
00156 
00157     public Image getImage()
00158     {
00159         if(Q)
00160         {
00161             return s;
00162         } else
00163         {
00164             return null;
00165         }
00166     }
00167 
00168     public void setDebug(boolean flag)
00169     {
00170         q = flag;
00171     }
00172 
00173     public boolean isDebug()
00174     {
00175         return q;
00176     }
00177 
00178     public void setFontname(String s1)
00179     {
00180         _fldint = s1;
00181     }
00182 
00183     public String getFontname()
00184     {
00185         return _fldint;
00186     }
00187 
00188     int i10,j10,k10,l10;
00189     boolean bold0,fonts=false;
00190     
00191     public void setHAlign(String s1)
00192     {
00193         z = s1;
00194         e = false;
00195         Q = false;
00196     }
00197 
00198     public String getHAlign()
00199     {
00200         return z;
00201     }
00202 
00203     public void setVAlign(String s1)
00204     {
00205         E = s1;
00206         e = false;
00207         Q = false;
00208     }
00209 
00210     public String getVAlign()
00211     {
00212         return E;
00213     }
00214 
00215     public void setEditable(boolean flag)
00216     {
00217         t = flag;
00218     }
00219 
00220     public boolean isEditable()
00221     {
00222         return t;
00223     }
00224 
00225     public String getSelectedArea()
00226     {
00227         return S.a(p, o);
00228     }
00229 
00230     public Dimension getPreferredSize()
00231     {
00232         if((width == 0) & (height == 0))
00233         {
00234             Graphics g1 = PC.getGraphics();
00235             if(g1 != null)
00236             {
00237                 g1.setFont(d);
00238                 S._mthdo();
00239                 c c1 = _mthnew(0, 150, false, g1, 1);
00240                 if(K)
00241                 {
00242                     g = 5;
00243                 } else
00244                 {
00245                     g = 0;
00246                 }
00247                 f = 1 + c1._flddo + 2 * g;
00248                 H = 1 + c1._fldif + c1.a + 2 * g;
00249             }
00250         }
00251         width = f;
00252         height = H;
00253         if(f <= 1)
00254         {
00255             return new Dimension(100, 100);
00256         } else
00257         {
00258             return new Dimension(f, H);
00259         }
00260     }
00261 
00262     final int ff1=8,ff2=6;
00263     
00264     public Dimension getSizeof (String s1, Graphics g1)
00265     {
00266        if (d!=g1.getFont())
00267        {      d=g1.getFont();
00268                      int fs=d.getSize();
00269               b=new Font(d.getFamily(),d.getStyle(),fs*ff1/10);;
00270               _fldnull=_fldlong=new Font(d.getFamily(),d.getStyle(),fs*ff2/10);
00271        }
00272        
00273         S.a(s1);
00274         c c1 = _mthnew(0, 150, false, g1, 1);
00275         byte byte0;
00276         if(K)
00277         {
00278             byte0 = 5;
00279         } else
00280         {
00281             byte0 = 0;
00282         }
00283         return new Dimension(1 + c1._flddo + 2 * byte0, 1 + c1._fldif + c1.a + 2 * byte0);
00284     }
00285 
00286     public int getAscent (String s1, Graphics g1)
00287     {
00288        if (d!=g1.getFont())
00289        {      d=g1.getFont();
00290                      int fs=d.getSize();
00291               b=new Font(d.getFamily(),d.getStyle(),fs*ff1/10);;
00292               _fldnull=_fldlong=new Font(d.getFamily(),d.getStyle(),fs*ff2/10);
00293        }
00294        
00295         S.a(s1);
00296         c c1 = _mthnew(0, 150, false, g1, 1);
00297         byte byte0;
00298         if(K)
00299         {
00300             byte0 = 5;
00301         } else
00302         {
00303             byte0 = 0;
00304         }
00305         return c1._fldif+byte0;
00306     }
00307 
00308     public Dimension getMinimumSize()
00309     {
00310         return getPreferredSize();
00311     }
00312 
00313     private void a (Graphics g1)
00314     {
00315         int i1 = height / 2 - 10;
00316         int j1 = i1 + 20;
00317         int k1 = width / 2 - 5;
00318         int l1 = k1 + 10;
00319         Polygon polygon = new Polygon();
00320         polygon.addPoint(k1, i1);
00321         polygon.addPoint(l1, j1);
00322         polygon.addPoint(k1, j1);
00323         polygon.addPoint(l1, i1);
00324         g1.fillPolygon(polygon);
00325     }
00326 
00327     public synchronized int paint (int cc, int rr, Graphics g2)
00328     {
00329        if (d!=g2.getFont())
00330        {      d=g2.getFont();
00331                      int fs=d.getSize();
00332               b=new Font(d.getFamily(),d.getStyle(),fs*ff1/10);;
00333               _fldnull=_fldlong=new Font(d.getFamily(),d.getStyle(),fs*ff2/10);
00334        }
00335        //rr-=g2.getFontMetrics().getAscent();
00336        
00337         c c1 = new c();
00338         g2.setFont(d);
00339         g = 0;
00340         S._mthdo();
00341         c1 = _mthnew(cc, rr, false, g2, 1);
00342         int hh=c1._fldif;
00343         c1 = new c();
00344         S._mthdo();
00345         c1 = _mthnew(cc, rr+hh, true, g2, 1);
00346         a(" ");
00347         M = 0;
00348         if(z.equals("center"))
00349         {
00350             M = 1;
00351         } else
00352         if(z.equals("right"))
00353         {
00354             M = 2;
00355         }
00356         i = 0;
00357         if(E.equals("middle"))
00358         {
00359             i = 1;
00360         } else
00361         if(E.equals("bottom"))
00362         {
00363             i = 2;
00364         }
00365         f = 1 + c1._flddo + 2 * g;
00366         H = 1 + c1._fldif + c1.a + 2 * g;
00367         boolean flag = false;
00368         if(f > width)
00369         {
00370             flag = true;
00371             M = 0;
00372         }
00373         if(H > height)
00374         {
00375             flag = true;
00376             i = 1;
00377         }
00378         int i1 = g;
00379         int j1 = g;
00380         switch(M)
00381         {
00382         case 1: // '\001'
00383             i1 = (width - c1._flddo) / 2;
00384             break;
00385 
00386         case 2: // '\002'
00387             i1 = width - g - c1._flddo - 1;
00388             break;
00389         }
00390         switch(i)
00391         {
00392         case 1: // '\001'
00393             j1 = g - (H - height) / 2;
00394             break;
00395 
00396         case 2: // '\002'
00397             j1 = height - g - c1.a - c1._fldif;
00398             break;
00399         }
00400         Q = true;
00401         e = true;
00402         v = i1;
00403         P = j1 + c1._fldif;
00404         notify();
00405         return c1._fldif + c1.a;
00406     }
00407 
00408     private c _mthnew(int i1, int j1, boolean flag, Graphics g1, int k1)
00409     {
00410         return _mthtry(i1, j1, flag, g1, k1, true);
00411     }
00412 
00413     private c _mthtry(int i1, int j1, boolean flag, Graphics g1, int k1, boolean flag1)
00414     {
00415         c c1 = new c();
00416         c c2 = new c();
00417         boolean flag2 = true;
00418         boolean flag3 = false;
00419         boolean flag5 = false;
00420         int l1 = 0;
00421         boolean flag6 = false;
00422         while(!S._mthnew() && flag2) 
00423         {
00424             D = S._mthint();
00425             if(A && flag)
00426             {
00427                 l1 = S._mthif();
00428             }
00429             boolean flag4 = false;
00430             int i2 = l1;
00431             int j2 = D.y;
00432             switch(D.y)
00433             {
00434             case 4: // '\004'
00435             case 7: // '\007'
00436             case 8: // '\b'
00437             case 17: // '\021'
00438             case 51: // '3'
00439                 if(c && flag)
00440                 {
00441                     if(l1 > o)
00442                     {
00443                         o = l1;
00444                     }
00445                     if(l1 < p)
00446                     {
00447                         p = l1;
00448                     }
00449                 }
00450                 return c2;
00451 
00452             case 22: // '\026'
00453                 c1 = _mthbyte(i1 + c2._flddo, j1, flag, g1, k1);
00454                 break;
00455 
00456             case 5: // '\005'
00457                 c1 = a(i1 + c2._flddo, j1, flag, g1);
00458                 break;
00459 
00460             case 15: // '\017'
00461                 if(c && flag)
00462                 {
00463                     flag5 = true;
00464                 }
00465                 c1 = _mthif(i1 + c2._flddo, j1, flag, g1, k1);
00466                 break;
00467 
00468             case 50: // '2'
00469                 if(c && flag)
00470                 {
00471                     flag5 = true;
00472                 }
00473                 c1 = _mthgoto(i1 + c2._flddo, j1, flag, g1, k1);
00474                 break;
00475 
00476             case 3: // '\003'
00477                 c1 = _mthtry(i1 + c2._flddo, j1, flag, g1, k1, true);
00478                 break;
00479 
00480              case 123: // '{'
00481                 if(c && flag)
00482                 {
00483                     flag5 = true;
00484                 }
00485                 c1 = _mthelse(i1 + c2._flddo, j1, flag, g1, k1);
00486                 break;
00487 
00488             case 1: // '\001'
00489                 c1 = _mthnew(i1 + c2._flddo, j1, flag, g1);
00490                 break;
00491 
00492             case 110: // 'n'
00493                 c1 = _mthtry(i1 + c2._flddo, j1, flag, g1, k1);
00494                 break;
00495 
00496             case 108: // 'l'
00497                 c1 = _mthint(i1 + c2._flddo, j1, flag, g1);
00498                 break;
00499 
00500             case 12: // '\f'
00501                 c1 = _mthfor(i1 + c2._flddo, j1, flag, g1, k1, true);
00502                 break;
00503             
00504             case 1001: // '\f'
00505                 c1 = _mthfor(i1 + c2._flddo, j1, flag, g1, k1-1, true);
00506                 break;
00507             
00508             case 115: // 's'
00509                 c1 = _mthfor(i1 + c2._flddo, j1, flag, g1, k1, false);
00510                 break;
00511 
00512             case 2: // '\002'
00513             case 9: // '\t'
00514                 c1 = _mthif(i1 + c2._flddo, j1, flag, g1);
00515                 break;
00516 
00517             case 18: // '\022'
00518                 c1 = _mthif(i1 + c2._flddo, j1, flag, g1, k1, false);
00519                 break;
00520 
00521             case 19: // '\023'
00522                 c1 = _mthif(i1 + c2._flddo, j1, flag, g1, k1, true);
00523                 break;
00524 
00525             case 16: // '\020'
00526                 if(c && flag)
00527                 {
00528                     flag5 = true;
00529                 }
00530                 c1 = _mthnull(i1 + c2._flddo, j1, flag, g1, k1);
00531                 break;
00532 
00533             case 24: // '\030'
00534                 c1 = _mthfor(i1 + c2._flddo, j1, flag, g1, k1);
00535                 break;
00536 
00537             case 124: // '|'
00538                 c1 = _mthdo(i1 + c2._flddo, j1, flag, g1);
00539                 break;
00540 
00541             case 118: // 'v'
00542                 c1 = a(i1 + c2._flddo, j1, flag, g1, k1);
00543                 break;
00544 
00545             case 119: // 'w'
00546                 c1 = _mthlong(i1 + c2._flddo, j1, flag, g1, k1);
00547                 break;
00548 
00549             case 116: // 't'
00550                 c1 = a(i1 + c2._flddo, j1, flag, g1, k1, true);
00551                 break;
00552 
00553             case 117: // 'u'
00554                 c1 = a(i1 + c2._flddo, j1, flag, g1, k1, false);
00555                 break;
00556 
00557             case 109: // 'm'
00558                 c1 = _mthtry(i1 + c2._flddo, j1, flag, g1);
00559                 break;
00560 
00561             case 113: // 'q'
00562                 c1 = _mthfor(i1 + c2._flddo, j1, flag, g1);
00563                 break;
00564 
00565             case 13: // '\r'
00566                 if(c && flag)
00567                 {
00568                     flag5 = true;
00569                 }
00570                 c1 = _mthcase(i1 + c2._flddo, j1, flag, g1, k1);
00571                 break;
00572 
00573             case 120: // 'x'
00574                 c1 = _mthchar(i1 + c2._flddo, j1, flag, g1, k1);
00575                 break;
00576 
00577             case 10: // '\n'
00578                 c1 = _mthint(i1 + c2._flddo, j1, flag, g1, k1, true);
00579                 break;
00580 
00581             case 11: // '\013'
00582                 c1 = _mthdo(i1 + c2._flddo, j1, flag, g1, k1, true);
00583                 break;
00584 
00585             case 20: // '\024'
00586                 c1 = _mthdo(i1 + c2._flddo, j1, flag, g1, k1);
00587                 break;
00588 
00589             case 14: // '\016'
00590                 c1 = _mthint(i1 + c2._flddo, j1, flag, g1, k1);
00591                 break;
00592 
00593             case 25: // '\031'
00594                 c1 = new c(0, 0, 0);
00595                 flag4 = true;
00596                 break;
00597 
00598             case 99: // 'c'
00599             case 100: // 'd'
00600                 c1 = new c(0, 0, 0);
00601                 break;
00602 
00603             case 6: // '\006'
00604             case 21: // '\025'
00605             case 23: // '\027'
00606             case 26: // '\032'
00607             case 27: // '\033'
00608             case 28: // '\034'
00609             case 29: // '\035'
00610             case 30: // '\036'
00611             case 31: // '\037'
00612             case 32: // ' '
00613             case 33: // '!'
00614             case 34: // '"'
00615             case 35: // '#'
00616             case 36: // '$'
00617             case 37: // '%'
00618             case 38: // '&'
00619             case 39: // '\''
00620             case 40: // '('
00621             case 41: // ')'
00622             case 42: // '*'
00623             case 43: // '+'
00624             case 44: // ','
00625             case 45: // '-'
00626             case 46: // '.'
00627             case 47: // '/'
00628             case 48: // '0'
00629             case 49: // '1'
00630             case 52: // '4'
00631             case 53: // '5'
00632             case 54: // '6'
00633             case 55: // '7'
00634             case 56: // '8'
00635             case 57: // '9'
00636             case 58: // ':'
00637             case 59: // ';'
00638             case 60: // '<'
00639             case 61: // '='
00640             case 62: // '>'
00641             case 63: // '?'
00642             case 64: // '@'
00643             case 65: // 'A'
00644             case 66: // 'B'
00645             case 67: // 'C'
00646             case 68: // 'D'
00647             case 69: // 'E'
00648             case 70: // 'F'
00649             case 71: // 'G'
00650             case 72: // 'H'
00651             case 73: // 'I'
00652             case 74: // 'J'
00653             case 75: // 'K'
00654             case 76: // 'L'
00655             case 77: // 'M'
00656             case 78: // 'N'
00657             case 79: // 'O'
00658             case 80: // 'P'
00659             case 81: // 'Q'
00660             case 82: // 'R'
00661             case 83: // 'S'
00662             case 84: // 'T'
00663             case 85: // 'U'
00664             case 86: // 'V'
00665             case 87: // 'W'
00666             case 88: // 'X'
00667             case 89: // 'Y'
00668             case 90: // 'Z'
00669             case 91: // '['
00670             case 92: // '\\'
00671             case 93: // ']'
00672             case 94: // '^'
00673             case 95: // '_'
00674             case 96: // '`'
00675             case 97: // 'a'
00676             case 98: // 'b'
00677             case 101: // 'e'
00678             case 102: // 'f'
00679             case 103: // 'g'
00680             case 104: // 'h'
00681             case 105: // 'i'
00682             case 106: // 'j'
00683             case 107: // 'k'
00684             case 111: // 'o'
00685             case 112: // 'p'
00686             case 114: // 'r'
00687             default:
00688                 printStatus("Parser: unknown token: " + D.y + " " + D.w);
00689                 break;
00690             }
00691             if(flag)
00692             {
00693                 if(A)
00694                 {
00695                     if(!c && i1 + c2._flddo <= _fldelse && _fldelse <= i1 + c2._flddo + c1._flddo && j1 - c1._fldif <= _fldchar && _fldchar <= j1 + c1.a)
00696                     {
00697                         m = l = _fldelse;
00698                         a = R = _fldchar;
00699                         c = true;
00700                         p = l1;
00701                         o = l1;
00702                     }
00703                     if(!c && i1 + c2._flddo <= J && J <= i1 + c2._flddo + c1._flddo && j1 - c1._fldif <= I && I <= j1 + c1.a)
00704                     {
00705                         m = l = J;
00706                         a = R = I;
00707                         c = true;
00708                         p = l1;
00709                         o = l1;
00710                         int k2 = J;
00711                         int l2 = I;
00712                         J = _fldelse;
00713                         I = _fldchar;
00714                         _fldelse = k2;
00715                         _fldchar = l2;
00716                     }
00717                     if(c)
00718                     {
00719                         m = Math.min(m, i1 + c2._flddo);
00720                         l = Math.max(l, i1 + c2._flddo + c1._flddo);
00721                         a = Math.min(a, j1 - c1._fldif);
00722                         R = Math.max(R, j1 + c1.a);
00723                         if(F > k1)
00724                         {
00725                             F = k1;
00726                         }
00727                         switch(j2)
00728                         {
00729                         case 13: // '\r'
00730                         case 15: // '\017'
00731                         case 16: // '\020'
00732                         case 50: // '2'
00733                         case 123: // '{'
00734                         case 124: // '|'
00735                             flag5 = true;
00736                             if(i2 > o)
00737                             {
00738                                 o = i2;
00739                             }
00740                             if(i2 < p)
00741                             {
00742                                 p = i2;
00743                             }
00744                             l1 = S._mthif();
00745                             break;
00746                         }
00747                         if(l1 > o)
00748                         {
00749                             o = l1;
00750                         }
00751                         if(l1 < p)
00752                         {
00753                             p = l1;
00754                         }
00755                         if(i1 + c2._flddo <= J && J <= i1 + c2._flddo + c1._flddo && j1 - c1._fldif <= I && I <= j1 + c1.a && F == k1)
00756                         {
00757                             A = false;
00758                             c = false;
00759                         }
00760                     }
00761                 }
00762                 if(flag5)
00763                 {
00764                     m = Math.min(m, i1 + c2._flddo);
00765                     l = Math.max(l, i1 + c2._flddo + c1._flddo);
00766                     a = Math.min(a, j1 - c1._fldif);
00767                     R = Math.max(R, j1 + c1.a);
00768                     switch(j2)
00769                     {
00770                     case 13: // '\r'
00771                     case 15: // '\017'
00772                     case 16: // '\020'
00773                     case 50: // '2'
00774                     case 123: // '{'
00775                     case 124: // '|'
00776                         if(i2 > o)
00777                         {
00778                             o = i2;
00779                         }
00780                         if(i2 < p)
00781                         {
00782                             p = i2;
00783                         }
00784                         l1 = S._mthif();
00785                         break;
00786                     }
00787                     if(l1 > o)
00788                     {
00789                         o = l1;
00790                     }
00791                     if(l1 < p)
00792                     {
00793                         p = l1;
00794                     }
00795                     flag5 = false;
00796                 }
00797             }
00798             c2._flddo += c1._flddo;
00799             c2._fldif = Math.max(c2._fldif, c1._fldif);
00800             c2.a = Math.max(c2.a, c1.a);
00801             if(!flag1 && !flag4)
00802             {
00803                 flag2 = false;
00804             }
00805         }
00806         return c2;
00807     }
00808 
00809     private c _mthbyte(int i1, int j1, boolean flag, Graphics g1, int k1)
00810     {
00811         c c1 = new c();
00812         int l1 = 0;
00813         FontMetrics fontmetrics = g1.getFontMetrics();
00814         String s1 = D.w;
00815         if(flag)
00816         {
00817             l1 = S._mthif();
00818         }
00819         c1 = _mthtry(i1, j1, false, g1, k1, false);
00820         int i2 = Math.max(c1._flddo, fontmetrics.stringWidth(s1));
00821         int j2 = c1._fldif + fontmetrics.getAscent() / 2;
00822         int k2 = c1.a;
00823         if(flag)
00824         {
00825             S.a(l1);
00826             c c2 = _mthtry(i1, j1, true, g1, k1, false);
00827             int l2 = 3 * ((i2 - fontmetrics.stringWidth(s1)) / 4);
00828             if(s1.equals(".") | s1.equals(".."))
00829             {
00830                 g1.drawString(s1, i1 + l2, j1 - fontmetrics.getAscent());
00831             } else
00832             if(s1.equals("\264") | s1.equals("`"))
00833             {
00834                 g1.drawString(s1, i1 + l2, j1 - fontmetrics.getAscent() / 3);
00835             } else
00836             {
00837                 g1.drawString(s1, i1 + l2, j1 - (fontmetrics.getAscent() * 2) / 3);
00838             }
00839         }
00840         return new c(i2, j2, k2);
00841     }
00842 
00843     private c a(int i1, int j1, boolean flag, Graphics g1)
00844     {
00845         c c1 = new c();
00846         FontMetrics fontmetrics = g1.getFontMetrics();
00847         int k1 = g1.getFont().getSize() / 2;
00848         int l1 = fontmetrics.getHeight() - fontmetrics.getDescent();
00849         int i2 = fontmetrics.getDescent();
00850         if(flag)
00851         {
00852             int j2 = (j1 - l1) + 1;
00853             int k2 = (j1 + i2) - 1;
00854             int l2 = (j2 + k2) / 2;
00855             if(D.w.equals("<"))
00856             {
00857                 g1.drawLine(i1 + k1, j2, i1, l2);
00858                 g1.drawLine(i1, l2, i1 + k1, k2);
00859             } else
00860             {
00861                 g1.drawLine(i1, j2, i1 + k1, l2);
00862                 g1.drawLine(i1 + k1, l2, i1, k2);
00863             }
00864         }
00865         return new c(k1, l1, i2);
00866     }
00867 
00868     private c _mthif(int i1, int j1, boolean flag, Graphics g1, int k1)
00869     {
00870         boolean flag1 = false;
00871         boolean flag2 = false;
00872         boolean flag3 = false;
00873         int l2 = 0;
00874         int ai[] = new int[100];
00875         int ai1[] = new int[100];
00876         int ai2[] = new int[100];
00877         c c1 = new c();
00878         int i3 = 0;
00879         FontMetrics fontmetrics = g1.getFontMetrics();
00880         int j3 = g1.getFont().getSize();
00881         if(flag)
00882         {
00883             i3 = S._mthif();
00884         }
00885         if(!a(3, "ARRAY: BeginSym"))
00886         {
00887             return new c(0, 0, 0);
00888         }
00889         for(int k3 = 0; k3 < 99; k3++)
00890         {
00891             int i2 = 0;
00892             int k2 = 0;
00893             for(int l3 = 0; l3 < 99; l3++)
00894             {
00895                 c c2 = _mthnew(i1, j1, false, g1, k1);
00896                 i2 = Math.max(i2, c2._fldif);
00897                 k2 = Math.max(k2, c2.a);
00898                 ai[l3] = Math.max(ai[l3], c2._flddo + j3);
00899                 if(D.y == 8 || D.y == 4)
00900                 {
00901                     break;
00902                 }
00903             }
00904 
00905             ai1[k3] = Math.max(ai1[k3], i2);
00906             ai2[k3] = Math.max(ai2[k3], k2);
00907             l2 += i2 + k2;
00908             if(D.y == 4)
00909             {
00910                 break;
00911             }
00912         }
00913 
00914         int i4 = 0;
00915         for(int j4 = 0; j4 < 99; j4++)
00916         {
00917             i4 += ai[j4];
00918         }
00919 
00920         if(flag)
00921         {
00922             S.a(i3);
00923             a(3, "ARRAY: Begin");
00924             int j2 = 0;
00925             for(int k4 = 0; k4 < 99; k4++)
00926             {
00927                 int l1 = 0;
00928                 if(k4 == 0)
00929                 {
00930                     j2 = ai1[k4];
00931                 } else
00932                 {
00933                     j2 += ai2[k4 - 1] + ai1[k4];
00934                 }
00935                 for(int l4 = 0; l4 < 99; l4++)
00936                 {
00937                     c c3 = _mthnew(i1 + l1, (j1 - l2 / 2 - fontmetrics.getDescent()) + j2, true, g1, k1);
00938                     l1 += ai[l4];
00939                     if(D.y == 8 || D.y == 4)
00940                     {
00941                         break;
00942                     }
00943                 }
00944 
00945                 if(D.y == 4)
00946                 {
00947                     break;
00948                 }
00949             }
00950 
00951         }
00952         return new c(i4 - j3, l2 / 2 + fontmetrics.getDescent(), l2 / 2 - fontmetrics.getDescent());
00953     }
00954 
00955     private c _mthgoto(int i1, int j1, boolean flag, Graphics g1, int k1)
00956     {
00957         int i2 = 0;
00958         int j3 = 0;
00959         int ai[] = new int[100];
00960         int ai1[] = new int[100];
00961         int ai2[] = new int[100];
00962         int ai3[] = new int[100];
00963         int ai4[] = new int[100];
00964         int k3 = 0;
00965         int l3 = 0;
00966         int i4 = 0;
00967         c c1 = new c();
00968         int j4 = 0;
00969         FontMetrics fontmetrics = g1.getFontMetrics();
00970         int k5 = g1.getFont().getSize();
00971         int l5 = 0;
00972         boolean flag1 = false;
00973         boolean flag3 = false;
00974         boolean flag4 = true;
00975         boolean flag5 = true;
00976         boolean flag6 = false;
00977         boolean flag7 = false;
00978         if(!a(3))
00979         {
00980             return new c(0, 0, 0);
00981         }
00982         if(S._mthint().w.equals("eqnarray"))
00983         {
00984             flag5 = false;
00985         }
00986         if(!a(4, "BEGIN: EndSym"))
00987         {
00988             return new c(0, 0, 0);
00989         }
00990         if(flag5)
00991         {
00992             j4 = S._mthif();
00993             if(!a(3))
00994             {
00995                 flag4 = false;
00996                 S.a(j4);
00997             }
00998         }
00999         if(flag5 && flag4)
01000         {
01001             e e1 = new e();
01002             for(e e2 = S._mthint(); e2.y != 4; e2 = S._mthint())
01003             {
01004                 StringBuffer stringbuffer = new StringBuffer(e2.w);
01005                 for(int i7 = 0; i7 < stringbuffer.length(); i7++)
01006                 {
01007                     switch(stringbuffer.charAt(i7))
01008                     {
01009                     case 108: // 'l'
01010                         ai3[l5] = 1;
01011                         if(l5 < 99)
01012                         {
01013                             l5++;
01014                         }
01015                         break;
01016 
01017                     case 99: // 'c'
01018                         ai3[l5] = 2;
01019                         if(l5 < 99)
01020                         {
01021                             l5++;
01022                         }
01023                         break;
01024 
01025                     case 114: // 'r'
01026                         ai3[l5] = 3;
01027                         if(l5 < 99)
01028                         {
01029                             l5++;
01030                         }
01031                         break;
01032 
01033                     case 64: // '@'
01034                         ai3[l5] = 4;
01035                         ai4[l5] = S._mthif();
01036                         c c2 = _mthtry(i1, j1, false, g1, k1, false);
01037                         k3 += c2._flddo;
01038                         l3 = Math.max(l3, c2._fldif);
01039                         i4 = Math.max(i4, c2.a);
01040                         if(l5 < 99)
01041                         {
01042                             l5++;
01043                         }
01044                         break;
01045 
01046                     case 42: // '*'
01047                         a(3, "Begin *{");
01048                         int j6;
01049                         try
01050                         {
01051                             j6 = Integer.parseInt(S._mthint().w);
01052                         }
01053                         catch(NumberFormatException numberformatexception)
01054                         {
01055                             j6 = 0;
01056                         }
01057                         a(4, 3, "Begin }{");
01058                         int l7 = S._mthif();
01059                         for(int j8 = 0; j8 < j6; j8++)
01060                         {
01061                             S.a(l7);
01062                             for(e2 = S._mthint(); e2.y != 4; e2 = S._mthint())
01063                             {
01064                                 StringBuffer stringbuffer1 = new StringBuffer(e2.w);
01065                                 for(int l8 = 0; l8 < stringbuffer1.length(); l8++)
01066                                 {
01067                                     switch(stringbuffer1.charAt(l8))
01068                                     {
01069                                     case 108: // 'l'
01070                                         ai3[l5] = 1;
01071                                         if(l5 < 99)
01072                                         {
01073                                             l5++;
01074                                         }
01075                                         break;
01076 
01077                                     case 99: // 'c'
01078                                         ai3[l5] = 2;
01079                                         if(l5 < 99)
01080                                         {
01081                                             l5++;
01082                                         }
01083                                         break;
01084 
01085                                     case 114: // 'r'
01086                                         ai3[l5] = 3;
01087                                         if(l5 < 99)
01088                                         {
01089                                             l5++;
01090                                         }
01091                                         break;
01092 
01093                                     case 64: // '@'
01094                                         ai3[l5] = 4;
01095                                         ai4[l5] = S._mthif();
01096                                         c c3 = _mthtry(i1, j1, false, g1, k1, false);
01097                                         k3 += c3._flddo;
01098                                         l3 = Math.max(l3, c3._fldif);
01099                                         i4 = Math.max(i4, c3.a);
01100                                         if(l5 < 99)
01101                                         {
01102                                             l5++;
01103                                         }
01104                                         break;
01105 
01106                                     default:
01107                                         printStatus("P: begin: illegal format 2");
01108                                         break;
01109                                     }
01110                                 }
01111 
01112                             }
01113 
01114                         }
01115 
01116                         break;
01117 
01118                     default:
01119                         printStatus("P: begin: illegal format 1");
01120                         break;
01121                     }
01122                 }
01123 
01124             }
01125 
01126         }
01127         if(!flag5)
01128         {
01129             ai3[0] = 3;
01130             ai3[1] = 2;
01131             ai3[2] = 1;
01132             l5 = 3;
01133         }
01134         for(int k6 = 0; k6 < l5 - 1; k6++)
01135         {
01136             if(ai3[k6] != 4 && ai3[k6 + 1] != 4)
01137             {
01138                 i2 += k5 / 2;
01139             }
01140         }
01141 
01142         if(flag)
01143         {
01144             j4 = S._mthif();
01145         }
01146         for(int l6 = 0; l6 < 99; l6++)
01147         {
01148             int j2 = 0;
01149             int l2 = 0;
01150             for(int j7 = 0; j7 < 99; j7++)
01151             {
01152                 c c4 = _mthnew(i1, j1, false, g1, k1);
01153                 j2 = Math.max(j2, c4._fldif);
01154                 l2 = Math.max(l2, c4.a);
01155                 ai[j7] = Math.max(ai[j7], c4._flddo);
01156                 if(D.y == 8 || D.y == 51)
01157                 {
01158                     break;
01159                 }
01160             }
01161 
01162             j2 = Math.max(j2, l3);
01163             l2 = Math.max(l2, i4);
01164             ai1[l6] = j2;
01165             ai2[l6] = l2;
01166             j3 += j2 + l2;
01167             if(D.y == 51)
01168             {
01169                 break;
01170             }
01171         }
01172 
01173         for(int i6 = 0; i6 < 99; i6++)
01174         {
01175             i2 += ai[i6];
01176         }
01177 
01178         i2 += (2 * k5) / 2;
01179         if(flag)
01180         {
01181             S.a(j4);
01182             int k2 = 0;
01183             int i3 = j3 / 2 + fontmetrics.getDescent();
01184             for(int k7 = 0; k7 < 99; k7++)
01185             {
01186                 int l1 = k5 / 2;
01187                 if(k7 == 0)
01188                 {
01189                     k2 = ai1[k7];
01190                 } else
01191                 {
01192                     k2 += ai2[k7 - 1] + ai1[k7];
01193                 }
01194                 int i8 = 0;
01195                 for(int k8 = 0; k8 < 99; k8++)
01196                 {
01197                     while(ai3[i8] == 4) 
01198                     {
01199                         int k4 = S._mthif();
01200                         S.a(ai4[i8]);
01201                         c c5 = _mthtry(i1 + l1, (j1 - i3) + k2, true, g1, k1, false);
01202                         l1 += c5._flddo;
01203                         S.a(k4);
01204                         i8++;
01205                     }
01206                     switch(ai3[i8])
01207                     {
01208                     case 0: // '\0'
01209                     case 1: // '\001'
01210                         c c6 = _mthnew(i1 + l1, (j1 - i3) + k2, true, g1, k1);
01211                         i8++;
01212                         break;
01213 
01214                     case 2: // '\002'
01215                         int l4 = S._mthif();
01216                         c c7 = _mthnew(i1, j1, false, g1, k1);
01217                         S.a(l4);
01218                         c7 = _mthnew(i1 + l1 + (ai[k8] - c7._flddo) / 2, (j1 - i3) + k2, true, g1, k1);
01219                         i8++;
01220                         break;
01221 
01222                     case 3: // '\003'
01223                         int i5 = S._mthif();
01224                         c c8 = _mthnew(i1, j1, false, g1, k1);
01225                         S.a(i5);
01226                         c8 = _mthnew((i1 + l1 + ai[k8]) - c8._flddo, (j1 - i3) + k2, true, g1, k1);
01227                         i8++;
01228                         break;
01229                     }
01230                     if(ai3[i8] != 4)
01231                     {
01232                         l1 += k5 / 2;
01233                     }
01234                     l1 += ai[k8];
01235                     boolean flag2 = false;
01236                     flag3 = false;
01237                     if(D.y == 8)
01238                     {
01239                         flag2 = true;
01240                     } else
01241                     if(D.y == 51)
01242                     {
01243                         flag2 = true;
01244                         flag3 = true;
01245                     }
01246                     for(; ai3[i8] == 4; i8++)
01247                     {
01248                         int j5 = S._mthif();
01249                         S.a(ai4[i8]);
01250                         c c9 = _mthtry(i1 + l1, (j1 - i3) + k2, true, g1, k1, false);
01251                         l1 += c9._flddo;
01252                         S.a(j5);
01253                     }
01254 
01255                     if(flag2)
01256                     {
01257                         break;
01258                     }
01259                 }
01260 
01261                 if(flag3)
01262                 {
01263                     break;
01264                 }
01265             }
01266 
01267         }
01268         if(!a(3, "BEGIN 2: begin"))
01269         {
01270             return new c(0, 0, 0);
01271         }
01272         S._mthint();
01273         if(!a(4, "BEGIN 2: end"))
01274         {
01275             return new c(0, 0, 0);
01276         } else
01277         {
01278             return new c(i2 + k3, j3 / 2 + fontmetrics.getDescent(), j3 / 2 - fontmetrics.getDescent());
01279         }
01280     }
01281 
01282     private c _mthelse(int i1, int j1, boolean flag, Graphics g1, int k1)
01283     {
01284         c c1 = new c();
01285         int l1 = g1.getFont().getSize() / 2;
01286         c1 = _mthtry(i1 + l1, j1, flag, g1, k1, false);
01287         if(flag)
01288         {
01289             g1.drawRect(i1 + l1 / 2, j1 - c1._fldif - l1 / 2, c1._flddo + l1, c1._fldif + c1.a + l1);
01290         }
01291         return new c(c1._flddo + l1 + l1, c1._fldif + l1, c1.a + l1);
01292     }
01293 
01294     private c _mthfor(int i1, int j1, boolean flag, Graphics g1, int k1, boolean flag1)
01295     {
01296         int l1 = 0;
01297         c c1 = new c();
01298         c c3 = new c();
01299         c c4 = new c();
01300         int i2 = 0;
01301         Font font = g1.getFont();
01302         int j2 = font.getSize();
01303         a(g1, k1 + 1);
01304         FontMetrics fontmetrics = g1.getFontMetrics();
01305         if(flag)
01306         {
01307             i2 = S._mthif();
01308         }
01309         c3 = _mthtry(i1, j1, false, g1, k1 + 1, false);
01310         int k2 = c3._fldif + c3.a;
01311         c4 = _mthtry(i1, j1, false, g1, k1 + 1, false);
01312         int l2 = Math.max(c3._flddo, c4._flddo);
01313         int i3 = c4._fldif + c4.a;
01314         Font font1 = g1.getFont();
01315         int j3 = (3 * font1.getSize()) / 18;
01316         l2 += 2 * j3;
01317         if(fontmetrics.getAscent() < i3)
01318         {
01319             l1 = fontmetrics.getAscent() / 2;
01320         }
01321         k2 += 2 + l1;
01322         i3 += 1 - l1;
01323         if(flag)
01324         {
01325             S.a(i2);
01326             if(flag1)
01327             {
01328                 g1.drawLine(i1 + j3, j1 - l1, (i1 + l2) - j3, j1 - l1);
01329             }
01330             c c2 = _mthtry(i1 + (l2 - c3._flddo) / 2, j1 - 2 - c3.a - l1, true, g1, k1 + 1, false);
01331             if(c && k1 < F)
01332             {
01333                 F = k1;
01334             }
01335             c2 = _mthtry(i1 + (l2 - c4._flddo) / 2, (j1 + 1 + c4._fldif) - l1, true, g1, k1 + 1, false);
01336         }
01337         a(g1, k1);
01338         return new c(l2, k2, i3);
01339     }
01340 
01341     private c _mthnew(int i1, int j1, boolean flag, Graphics g1)
01342     {
01343         FontMetrics fontmetrics = g1.getFontMetrics();
01344         if(flag)
01345         {
01346             g1.drawString(D.w, i1, j1);
01347             //System.out.println(g1.getFont());
01348             //System.out.println("5: "+D.w);            
01349         }
01350         int k1 = fontmetrics.stringWidth(D.w);
01351         int l1 = fontmetrics.getHeight() - fontmetrics.getDescent();
01352         int i2 = fontmetrics.getDescent();
01353         return new c(k1, l1, i2);
01354     }
01355 
01356     private void a(Graphics g1, int i1, int j1, int k1, int l1, int i2)
01357     {
01358         g1.drawArc(i1 - k1, j1 - k1, 2 * k1, 2 * k1, l1, i2);
01359     }
01360 
01361     private void a(Graphics g1, String s1, int i1, int j1, int k1, int l1, int i2, 
01362             int j2)
01363     {
01364         int k2 = j1 / 2;
01365         int l2 = i1 + k2;
01366         int i3 = i1 + j1;
01367         int j3 = i1 + k2 / 2;
01368         int k3 = l2 + k2 / 2;
01369         int l3 = (k1 + l1) / 2;
01370         int i4 = (int)((double)k2 * 0.86602540378444004D);
01371         int j4 = k1 + i4;
01372         int k4 = l1 - i4;
01373         if(s1.equals("["))
01374         {
01375             g1.drawLine(j3, k1, j3, l1);
01376             g1.drawLine(j3, l1, k3, l1);
01377             g1.drawLine(j3, k1, k3, k1);
01378         } else
01379         if(s1.equals("]"))
01380         {
01381             g1.drawLine(k3, k1, k3, l1);
01382             g1.drawLine(j3, l1, k3, l1);
01383             g1.drawLine(j3, k1, k3, k1);
01384         } else
01385         if(s1.equals("|"))
01386         {
01387             g1.drawLine(l2, k1, l2, l1);
01388         } else
01389         if(s1.equals("||"))
01390         {
01391             int l4 = l2 + i2 / 4;
01392             g1.drawLine(l2, k1, l2, l1);
01393             g1.drawLine(l4, k1, l4, l1);
01394         } else
01395         if(s1.equals("("))
01396         {
01397             for(int i5 = j2; i5 < 2 + j2; i5++)
01398             {
01399                 int i6 = j3 + i5;
01400                 a(g1, k3 + i5, j4, k2, 180, -60);
01401                 g1.drawLine(i6, j4, i6, k4);
01402                 a(g1, k3 + i5, k4, k2, 180, 60);
01403             }
01404 
01405         } else
01406         if(s1.equals(")"))
01407         {
01408             for(int j5 = j2; j5 < 2 + j2; j5++)
01409             {
01410                 int j6 = k3 + j5;
01411                 a(g1, j3 + j5, j4, k2, 0, 60);
01412                 g1.drawLine(j6, j4, j6, k4);
01413                 a(g1, j3 + j5, k4, k2, 0, -60);
01414             }
01415 
01416         } else
01417         if(s1.equals("<"))
01418         {
01419             g1.drawLine(j3, l3, k3, k1);
01420             g1.drawLine(j3, l3, k3, l1);
01421         } else
01422         if(s1.equals(">"))
01423         {
01424             g1.drawLine(k3, l3, j3, k1);
01425             g1.drawLine(k3, l3, j3, l1);
01426         } else
01427         if(s1.equals("{"))
01428         {
01429             for(int k5 = j2; k5 < 2 + j2; k5++)
01430             {
01431                 int k6 = l2 + k5;
01432                 a(g1, i3 + k5, j4, k2, 180, -60);
01433                 g1.drawLine(k6, j4, k6, l3 - k2);
01434                 a(g1, i1 + k5, l3 - k2, k2, 0, -90);
01435                 a(g1, i1 + k5, l3 + k2, k2, 0, 90);
01436                 g1.drawLine(k6, l3 + k2, k6, k4);
01437                 a(g1, i3 + k5, k4, k2, 180, 60);
01438             }
01439 
01440         } else
01441         if(s1.equals("}"))
01442         {
01443             for(int l5 = j2; l5 < 2 + j2; l5++)
01444             {
01445                 int l6 = l2 + l5;
01446                 a(g1, i1 + l5, j4, k2, 0, 60);
01447                 g1.drawLine(l6, j4, l6, l3 - k2);
01448                 a(g1, i3 + l5, l3 - k2, k2, -180, 90);
01449                 a(g1, i3 + l5, l3 + k2, k2, 180, -90);
01450                 g1.drawLine(l6, l3 + k2, l6, k4);
01451                 a(g1, i1 + l5, k4, k2, 0, -60);
01452             }
01453 
01454         }
01455     }
01456 
01457     private c _mthnull(int i1, int j1, boolean flag, Graphics g1, int k1)
01458     {
01459         int l1 = 0;
01460         int i2 = 0;
01461         c c1 = new c();
01462         int j2 = 0;
01463         Font font = g1.getFont();
01464         int k2 = font.getSize();
01465         int l2 = (int)(2.0F * (float)k2);
01466         int i3 = k2 / 9;
01467         if(flag)
01468         {
01469             j2 = S._mthif();
01470         }
01471         String s1 = S._mthint().w;
01472         c1 = _mthnew(i1, j1, false, g1, k1);
01473         int j3 = c1._flddo;
01474         int k3 = c1._fldif;
01475         int l3 = c1.a;
01476         int i4 = (j1 - k3) + 1;
01477         int j4 = (j1 + l3) - 1;
01478         String s3 = S._mthint().w;
01479         int k4 = (k3 + l3) - 2;
01480         Font font1=new Font(font.getFamily(), font.getStyle(), k4);
01481         g1.setFont(font1);
01482         FontMetrics fontmetrics = g1.getFontMetrics();
01483         if(s1.equals("<") || s1.equals(">"))
01484         {
01485             l1 = k2;
01486         } else
01487         if(k4 < l2)
01488         {
01489             l1 = fontmetrics.stringWidth(s1);
01490             if("([{)]}".indexOf(s1) >= 0)
01491             {
01492                 l1 += i3;
01493             }
01494         } else
01495         {
01496             l1 = k2;
01497         }
01498         if(s3.equals("<") || s3.equals(">"))
01499         {
01500             i2 = k2;
01501         } else
01502         if(k4 < l2)
01503         {
01504             i2 = fontmetrics.stringWidth(s3);
01505             if("([{)]}".indexOf(s3) >= 0)
01506             {
01507                 i2 += i3;
01508             }
01509         } else
01510         {
01511             i2 = k2;
01512         }
01513         g1.setFont(font);
01514         int l4 = S._mthif();
01515         int j5 = 0;
01516         int k5 = 0;
01517         if(S._mthint().y == 11)
01518         {
01519             c c2 = _mthdo(i1, j1, false, g1, k1, false);
01520             j5 = c2._flddo;
01521             k5 = (j4 + c2._fldif) - (c2._fldif + c2.a) / 2;
01522             l3 += (c2._fldif + c2.a) / 2;
01523         } else
01524         {
01525             S.a(l4);
01526         }
01527         int l5 = S._mthif();
01528         int j6 = 0;
01529         int k6 = 0;
01530         if(S._mthint().y == 10)
01531         {
01532             c c3 = _mthint(i1, j1, false, g1, k1, false);
01533             j6 = c3._flddo;
01534             k6 = (i4 + c3._fldif) - (c3._fldif + c3.a) / 2;
01535             k3 += (c3._fldif + c3.a) / 2;
01536         } else
01537         {
01538             S.a(l5);
01539         }
01540         j5 = Math.max(j5, j6);
01541         if(flag)
01542         {
01543             S.a(j2);
01544             String s2 = S._mthint().w;
01545             if(!s2.equals("."))
01546             {
01547                 if(k4 < l2 && !s2.equals("<") && !s2.equals(">"))
01548                 {
01549                     g1.setFont(font1);
01550                     g1.drawString(s2, i1, j4 - fontmetrics.getDescent() - fontmetrics.getLeading() / 2);
01551                     g1.setFont(font);
01552                 } else
01553                 {
01554                     a(g1, s2, i1, l1, i4, j4, k2, 0);
01555                 }
01556             }
01557             c c4 = _mthnew(i1 + l1, j1, true, g1, k1);
01558             String s4 = S._mthint().w;
01559             if(!s4.equals("."))
01560             {
01561                 if(k4 < l2 && !s4.equals("<") && !s4.equals(">"))
01562                 {
01563                     g1.setFont(font1);
01564                     if("([{)]}".indexOf(s4) < 0)
01565                     {
01566                         i3 = 0;
01567                     }
01568                     g1.drawString(s4, i1 + j3 + l1 + i3, j4 - fontmetrics.getDescent() - fontmetrics.getLeading() / 2);
01569                     //System.out.println("2: "+s4);            
01570                     g1.setFont(font);
01571                 } else
01572                 {
01573                     a(g1, s4, i1 + j3 + l1, i2, i4, j4, -k2, -1);
01574                 }
01575             }
01576             int i5 = S._mthif();
01577             if(a(11))
01578             {
01579                 c4 = _mthdo(i1 + j3 + l1 + i2, k5, true, g1, k1, false);
01580             } else
01581             {
01582                 S.a(i5);
01583             }
01584             int i6 = S._mthif();
01585             if(a(10))
01586             {
01587                 c4 = _mthint(i1 + j3 + l1 + i2, k6, true, g1, k1, false);
01588             } else
01589             {
01590                 S.a(i6);
01591             }
01592         }
01593         return new c(j3 + l1 + i2 + j5, k3 + 2, l3 + 2);
01594     }
01595 
01596     private c _mthfor(int i1, int j1, boolean flag, Graphics g1, int k1)
01597     {
01598         int l1 = 0;
01599         c c1 = new c();
01600         int i2 = 0;
01601         int j2 = 0;
01602         FontMetrics fontmetrics = g1.getFontMetrics();
01603         String s1 = D.w;
01604         int k2 = S._mthif();
01605         int l2 = l1 = fontmetrics.stringWidth(s1);
01606         int i3 = fontmetrics.getHeight() - fontmetrics.getDescent();
01607         int j3 = fontmetrics.getDescent();
01608         if(a(11))
01609         {
01610             c c2 = _mthdo(i1, j1, false, g1, k1, false);
01611             i2 = c2._flddo;
01612             l1 = Math.max(l1, c2._flddo);
01613             j2 = c2._fldif;
01614             j3 = c2._fldif + c2.a;
01615         } else
01616         {
01617             S.a(k2);
01618         }
01619         if(flag)
01620         {
01621             S.a(k2);
01622             g1.drawString(s1, i1 + (l1 - l2) / 2, j1);
01623             //System.out.println("4: "+s1);            
01624             c c3;
01625             if(a(11))
01626             {
01627                 c3 = _mthdo(i1 + (l1 - i2) / 2, j1 + j2, true, g1, k1, false);
01628             } else
01629             {
01630                 S.a(k2);
01631             }
01632         }
01633         return new c(l1, i3, j3);
01634     }
01635 
01636     private c _mthdo(int i1, int j1, boolean flag, Graphics g1)
01637     {
01638         int k1 = 0;
01639         int l1 = 0;
01640         int i2 = 0;
01641         c c1 = new c();
01642         if(!a(3))
01643         {
01644             return new c(0, 0, 0);
01645         }
01646         while(!S._mthnew()) 
01647         {
01648             D = S._mthint();
01649             if(D.y == 4)
01650             {
01651                 break;
01652             }
01653             c c2 = _mthif(i1 + k1, j1, flag, g1);
01654             k1 += c2._flddo;
01655             l1 = Math.max(l1, c2._fldif);
01656             i2 = Math.max(i2, c2.a);
01657         }
01658         return new c(k1, l1, i2);
01659     }
01660 
01661     private c _mthtry(int i1, int j1, boolean flag, Graphics g1, int k1)
01662     {
01663         c c1 = new c();
01664         c1 = _mthtry(i1, j1, flag, g1, k1, false);
01665         if(flag)
01666         {
01667             g1.drawLine(i1 + c1._flddo / 4, j1 + c1.a, i1 + (c1._flddo * 3) / 4, j1 - c1._fldif);
01668         }
01669         return c1;
01670     }
01671 
01672     private c _mthint(int i1, int j1, boolean flag, Graphics g1)
01673     {
01674         FontMetrics fontmetrics = g1.getFontMetrics();
01675         if(flag)
01676         {
01677             g1.drawString(D.w, i1 + 1, j1);
01678             //System.out.println("3: "+D.w);            
01679         }
01680         return new c(fontmetrics.stringWidth(D.w) + 2, fontmetrics.getHeight() - fontmetrics.getDescent(), fontmetrics.getDescent());
01681     }
01682 
01683     private c a(int i1, int j1, boolean flag, Graphics g1, int k1)
01684     {
01685         int l1 = 0;
01686         c c1 = new c();
01687         int i2 = g1.getFont().getSize() / 4;
01688         int j2 = i2 / 2;
01689         int k2 = 0;
01690         int l2 = 0;
01691         int i3 = 0;
01692         if(flag)
01693         {
01694             l1 = S._mthif();
01695         }
01696         c1 = _mthtry(i1, j1, false, g1, k1, false);
01697         int j3 = c1._flddo;
01698         int k3 = j3 / 2;
01699         int l3 = k3;
01700         int i4 = c1._fldif;
01701         int j4 = c1.a;
01702         int k4 = S._mthif();
01703         if(a(10))
01704         {
01705             c c2 = _mthint(i1, j1, false, g1, k1, false);
01706             k2 = c2._flddo;
01707             l3 = Math.max(l3, k2 / 2);
01708             l2 = i4 + c2.a;
01709             i3 = c2._fldif + c2.a;
01710         } else
01711         {
01712             S.a(k4);
01713         }
01714         if(flag)
01715         {
01716             S.a(l1);
01717             int i5 = (i1 + l3) - k3;
01718             c c3 = _mthtry(i5, j1, true, g1, k1, false);
01719             int j5 = (int)((double)i2 * 0.86602540378444004D);
01720             for(int k5 = 0; k5 < 2; k5++)
01721             {
01722                 int l5 = (j1 - i4 - j2) + k5;
01723                 a(g1, i5 + j5, l5 + i2, i2, 90, 60);
01724                 g1.drawLine(i5 + j5, l5, (i5 + k3) - i2, l5);
01725                 a(g1, (i5 + k3) - i2, l5 - i2, i2, 0, -90);
01726                 a(g1, i5 + k3 + i2, l5 - i2, i2, -90, -90);
01727                 g1.drawLine(i5 + k3 + i2, l5, (i5 + j3) - j5, l5);
01728                 a(g1, (i5 + j3) - j5, l5 + i2, i2, 90, -60);
01729             }
01730 
01731             int l4 = S._mthif();
01732             if(a(10))
01733             {
01734                 c3 = _mthint((i1 + l3) - k2 / 2, j1 - l2 - i2 - j2, true, g1, k1, false);
01735             } else
01736             {
01737                 S.a(l4);
01738             }
01739         }
01740         i4 += i3 + i2 + j2;
01741         j3 = Math.max(j3, k2);
01742         return new c(j3, i4, j4);
01743     }
01744 
01745     private c _mthlong(int i1, int j1, boolean flag, Graphics g1, int k1)
01746     {
01747         int l1 = 0;
01748         c c1 = new c();
01749         int i2 = g1.getFont().getSize() / 4;
01750         int j2 = i2 / 2;
01751         int k2 = 0;
01752         int l2 = 0;
01753         int i3 = 0;
01754         if(flag)
01755         {
01756             l1 = S._mthif();
01757         }
01758         c1 = _mthtry(i1, j1, false, g1, k1, false);
01759         int j3 = c1._flddo;
01760         int k3 = j3 / 2;
01761         int l3 = k3;
01762         int i4 = c1._fldif;
01763         int j4 = c1.a;
01764         int k4 = S._mthif();
01765         if(a(11))
01766         {
01767             c c2 = _mthdo(i1, j1, false, g1, k1, false);
01768             k2 = c2._flddo;
01769             l3 = Math.max(l3, k2 / 2);
01770             l2 = j4 + c2._fldif;
01771             i3 = c2._fldif + c2.a;
01772         } else
01773         {
01774             S.a(k4);
01775         }
01776         if(flag)
01777         {
01778             S.a(l1);
01779             int i5 = (i1 + l3) - k3;
01780             c c3 = _mthtry(i5, j1, true, g1, k1, false);
01781             int j5 = (int)((double)i2 * 0.86602540378444004D);
01782             for(int k5 = 0; k5 < 2; k5++)
01783             {
01784                 int l5 = (j1 + j4 + j2) - k5;
01785                 a(g1, i5 + j5, l5 - i2, i2, -90, -60);
01786                 g1.drawLine(i5 + j5, l5, (i5 + k3) - i2, l5);
01787                 a(g1, (i5 + k3) - i2, l5 + i2, i2, 90, -90);
01788                 a(g1, i5 + k3 + i2, l5 + i2, i2, 90, 90);
01789                 g1.drawLine(i5 + k3 + i2, l5, (i5 + j3) - j5, l5);
01790                 a(g1, (i5 + j3) - j5, l5 - i2, i2, -90, 60);
01791             }
01792 
01793             int l4 = S._mthif();
01794             if(S._mthint().y == 11)
01795             {
01796                 c3 = _mthdo((i1 + l3) - k2 / 2, j1 + l2 + i2 + j2, true, g1, k1, false);
01797             } else
01798             {
01799                 S.a(l4);
01800             }
01801         }
01802         j4 += i3 + i2 + j2;
01803         j3 = Math.max(j3, k2);
01804         return new c(j3, i4, j4);
01805     }
01806 
01807     private c a(int i1, int j1, boolean flag, Graphics g1, int k1, boolean flag1)
01808     {
01809         int l1 = 0;
01810         c c1 = new c();
01811         if(flag)
01812         {
01813             l1 = S._mthif();
01814         }
01815         c1 = _mthtry(i1, j1, false, g1, k1, false);
01816         if(flag1)
01817         {
01818             c1._fldif += 2;
01819         } else
01820         {
01821             c1.a += 2;
01822         }
01823         int i2 = c1._fldif;
01824         int j2 = c1.a;
01825         if(flag)
01826         {
01827             S.a(l1);
01828             if(flag1)
01829             {
01830                 g1.drawLine(i1 + 1, (j1 - i2) + 2, (i1 + c1._flddo) - 1, (j1 - i2) + 2);
01831             } else
01832             {
01833                 g1.drawLine(i1, (j1 + j2) - 2, i1 + c1._flddo, (j1 + j2) - 2);
01834             }
01835             c1 = _mthtry(i1, j1, true, g1, k1, false);
01836         }
01837         return new c(c1._flddo, i2, j2);
01838     }
01839 
01840     private c _mthtry(int i1, int j1, boolean flag, Graphics g1)
01841     {
01842         FontMetrics fontmetrics = g1.getFontMetrics();
01843         int k1 = g1.getFont().getSize() / 9;
01844         int l1 = fontmetrics.stringWidth(D.w);
01845         int i2 = "([{)]}".indexOf(D.w);
01846         if(i2 >= 0)
01847         {
01848             l1 += k1;
01849             if(i2 > 2)
01850             {
01851                 i1 += k1;
01852             }
01853         }
01854         if(flag)
01855         {
01856             g1.drawString(D.w, i1, j1);
01857             //System.out.println("2: "+D.w);            
01858         }
01859         return new c(l1, fontmetrics.getHeight() - fontmetrics.getDescent(), fontmetrics.getDescent());
01860     }
01861 
01862     private c _mthif(int i1, int j1, boolean flag, Graphics g1)
01863     {
01864         FontMetrics fontmetrics = g1.getFontMetrics();
01865         if(flag)
01866         {
01867             g1.drawString(D.w, i1, j1);
01868             //System.out.println(g1.getFont());
01869             //System.out.println("1: "+D.w);            
01870         }
01871         return new c(fontmetrics.stringWidth(D.w), fontmetrics.getHeight() - fontmetrics.getDescent(), fontmetrics.getDescent());
01872     }
01873 
01874     private c _mthfor(int i1, int j1, boolean flag, Graphics g1)
01875     {
01876         int k1 = 0;
01877         Font font = g1.getFont();
01878         try
01879         {
01880             k1 = Integer.parseInt(D.w);
01881         }
01882         catch(NumberFormatException numberformatexception)
01883         {
01884             k1 = 0;
01885         }
01886         k1 = (k1 * font.getSize()) / 18;
01887         return new c(k1, 0, 0);
01888     }
01889 
01890     private c _mthcase(int i1, int j1, boolean flag, Graphics g1, int k1)
01891     {
01892         c c1 = new c();
01893         int l1 = 0;
01894         FontMetrics fontmetrics = g1.getFontMetrics();
01895         int i2 = 0;
01896         boolean flag1 = false;
01897         int k2 = 0;
01898         int l2 = 0;
01899         boolean flag2 = false;
01900         if(flag)
01901         {
01902             l1 = S._mthif();
01903         }
01904         int i3 = fontmetrics.stringWidth("A");
01905         int j3 = i3 / 2;
01906         int k3 = S._mthif();
01907         e e1 = new e();
01908         e1 = S._mthint();
01909         if(e1.w.equals("["))
01910         {
01911             a(g1, k1 + 1);
01912             c1 = _mthtry(i1, j1, false, g1, k1 + 1, true);
01913             a(g1, k1);
01914             i2 = c1._flddo;
01915             int j2 = c1._fldif;
01916             k2 = c1.a;
01917             l2 = k2 + j2;
01918             flag2 = true;
01919         } else
01920         {
01921             S.a(k3);
01922         }
01923         c1 = _mthtry(i1, j1, false, g1, k1, false);
01924         int l3 = c1._flddo + i3;
01925         int i4 = c1._fldif + 2;
01926         int j4 = c1.a;
01927         if(flag2 & (i2 > j3))
01928         {
01929             l3 += i2 - j3;
01930         }
01931         if(flag)
01932         {
01933             S.a(l1);
01934             int k4 = 0;
01935             if(flag2 & (i2 > j3))
01936             {
01937                 k4 = i2 - j3;
01938             }
01939             g1.drawLine(i1 + k4 + 1, j1 - i4 / 2, i1 + k4 + j3, (j1 + j4) - 1);
01940             g1.drawLine(i1 + k4 + j3, (j1 + j4) - 1, (i1 + k4 + i3) - 2, (j1 - i4) + 2);
01941             g1.drawLine((i1 + k4 + i3) - 2, (j1 - i4) + 2, i1 + l3, (j1 - i4) + 2);
01942             if(flag2)
01943             {
01944                 e e2 = S._mthint();
01945                 a(g1, k1 + 1);
01946                 c c3;
01947                 if(i2 >= j3)
01948                 {
01949                     g1.drawLine(i1 + 1, j1 - i4 / 2, i1 + k4 + 1, j1 - i4 / 2);
01950                     c c2 = _mthtry(i1 + 1, j1 - i4 / 2 - k2 - 1, true, g1, k1 + 1, true);
01951                 } else
01952                 {
01953                     c3 = _mthtry(i1 + 1 + (j3 - i2), j1 - i4 / 2 - k2 - 1, true, g1, k1 + 1, true);
01954                 }
01955                 a(g1, k1);
01956             }
01957             c c4 = _mthtry(i1 + k4 + i3, j1, true, g1, k1, false);
01958         }
01959         if(flag2 & (i4 / 2 < l2))
01960         {
01961             i4 = i4 / 2 + l2;
01962         }
01963         return new c(l3, i4, j4);
01964     }
01965 
01966     private c _mthchar(int i1, int j1, boolean flag, Graphics g1, int k1)
01967     {
01968         c c1 = new c();
01969         int l1 = 0;
01970         int i2 = g1.getFontMetrics().getLeading();
01971         if(flag)
01972         {
01973             l1 = S._mthif();
01974         }
01975         c1 = _mthint(i1, j1, false, g1, k1, true);
01976         int j2 = c1._flddo;
01977         int k2 = c1._flddo;
01978         int l2 = (c1._fldif + c1.a) - i2;
01979         int i3 = c1.a - i2;
01980         c1 = _mthtry(i1, j1, false, g1, k1, false);
01981         j2 = Math.max(j2, c1._flddo);
01982         int j3 = j2 / 2;
01983         int k3 = c1._flddo;
01984         l2 += c1._fldif;
01985         int l3 = c1.a;
01986         i3 += c1._fldif;
01987         if(flag)
01988         {
01989             S.a(l1);
01990             c c2 = _mthint((i1 + j3) - k2 / 2, j1 - i3, true, g1, k1, false);
01991             c2 = _mthtry((i1 + j3) - k3 / 2, j1, true, g1, k1, false);
01992         }
01993         return new c(j2, l2, l3);
01994     }
01995 
01996     private c _mthdo(int i1, int j1, boolean flag, Graphics g1, int k1, boolean flag1)
01997     {
01998         int l1 = 0;
01999         int i2 = 0;
02000         c c1 = new c();
02001         int j2 = 0;
02002         int l2 = g1.getFontMetrics().getAscent() / 2;
02003         if(flag)
02004         {
02005             j2 = S._mthif();
02006         }
02007         a(g1, k1 + 1);
02008         c1 = _mthtry(i1, j1, false, g1, k1 + 1, false);
02009         int i3 = c1._flddo;
02010         if(flag1)
02011         {
02012             l1 = l2 - 1;
02013             i2 = (c1._fldif + c1.a) - l1;
02014         } else
02015         {
02016             i2 = c1._fldif + c1.a;
02017         }
02018         if(flag)
02019         {
02020             S.a(j2);
02021             if(flag1)
02022             {
02023                 c1 = _mthtry(i1, (j1 + c1._fldif) - l1, true, g1, k1 + 1, false);
02024             } else
02025             {
02026                 c1 = _mthtry(i1, j1 + c1._fldif, true, g1, k1 + 1, false);
02027             }
02028         }
02029         a(g1, k1);
02030         if(flag1)
02031         {
02032             int k2 = S._mthif();
02033             if(a(10))
02034             {
02035                 c c2 = _mthint(i1, j1, flag, g1, k1, true);
02036                 i3 = Math.max(i3, c2._flddo);
02037                 l1 = Math.max(l1, c2._fldif);
02038             } else
02039             {
02040                 S.a(k2);
02041             }
02042         }
02043         return new c(i3, l1, i2);
02044     }
02045 
02046     private c _mthint(int i1, int j1, boolean flag, Graphics g1, int k1, boolean flag1)
02047     {
02048         int l1 = 0;
02049         int i2 = 0;
02050         c c1 = new c();
02051         int j2 = 0;
02052         int l2 = g1.getFontMetrics().getAscent() / 2;
02053         if(flag)
02054         {
02055             j2 = S._mthif();
02056         }
02057         a(g1, k1 + 1);
02058         c1 = _mthtry(i1, j1, false, g1, k1 + 1, false);
02059         int i3 = c1._flddo;
02060         if(flag1)
02061         {
02062             i2 = -l2 - 1;
02063             l1 = (c1._fldif + c1.a) - i2;
02064         } else
02065         {
02066             l1 = c1._fldif + c1.a;
02067         }
02068         if(flag)
02069         {
02070             S.a(j2);
02071             if(flag1)
02072             {
02073                 c1 = _mthtry(i1, (j1 - c1.a) + i2, true, g1, k1 + 1, false);
02074             } else
02075             {
02076                 c1 = _mthtry(i1, j1 - c1.a, true, g1, k1 + 1, false);
02077             }
02078         }
02079         a(g1, k1);
02080         if(flag1)
02081         {
02082             int k2 = S._mthif();
02083             if(a(11))
02084             {
02085                 c c2 = _mthdo(i1, j1, flag, g1, k1, true);
02086                 i3 = Math.max(i3, c2._flddo);
02087                 i2 = Math.max(i2, c2.a);
02088             } else
02089             {
02090                 S.a(k2);
02091             }
02092         }
02093         return new c(i3, l1, i2);
02094     }
02095 
02096     private Image _mthif(Graphics g1, int i1)
02097     {
02098         String s1 = D.w + j[i1 - 1] + g1.getColor().getRGB();
02099         if(!w.containsKey(s1))
02100         {
02101             String s2 = "Fonts/Greek" + j[i1 - 1] + "/" + D.w + ".gif";
02102             Image image = _flddo.a(s2, g1);
02103             int j1 = S._mthif();
02104             B.addImage(image, j1);
02105             a("Loading " + D.w);
02106             try
02107             {
02108                 B.waitForID(j1, 10000L);
02109             }
02110             catch(InterruptedException interruptedexception) { }
02111             if(B.isErrorID(j1))
02112             {
02113                 a("Error loading " + D.w);
02114             } else
02115             {
02116                 w.put(s1, image);
02117             }
02118             return image;
02119         } else
02120         {
02121             return (Image)w.get(s1);
02122         }
02123     }
02124 
02125     private c _mthif(int i1, int j1, boolean flag, Graphics g1, int k1, boolean flag1)
02126     {
02127         FontMetrics fontmetrics = g1.getFontMetrics();
02128         k1 = Math.min(k1, j.length);
02129         Image image = _mthif(g1, k1);
02130         int l1 = image.getWidth(PC);
02131         if(l1 < 0)
02132         {
02133             l1 = fontmetrics.getMaxAdvance();
02134         }
02135         if(flag)
02136         {
02137             int i2 = 0;
02138             if(flag1)
02139             {
02140                 i2 = _fldfor[k1 - 1];
02141             }
02142             g1.drawImage(image, i1, (j1 - image.getHeight(PC)) + i2, PC);
02143         }
02144         return new c(l1, fontmetrics.getHeight() - fontmetrics.getDescent(), fontmetrics.getDescent());
02145     }
02146 
02147     private c _mthdo(int i1, int j1, boolean flag, Graphics g1, int k1)
02148     {
02149         int l1 = 0;
02150         c c1 = new c();
02151         int i2 = 0;
02152         int j2 = 0;
02153         int k2 = 0;
02154         int l2 = 0;
02155         int i3 = 0;
02156         int j3 = g1.getFontMetrics().getAscent();
02157         k1 = Math.min(k1, j.length);
02158         Image image = _mthif(g1, k1);
02159         int k3 = l1 = image.getWidth(PC);
02160         int l3 = image.getHeight(PC);
02161         if(l3 < 0)
02162         {
02163             l3 = 2 * j3;
02164             k3 = l1 = j3;
02165         }
02166         int i4 = (int)((double)(l3 / 2) - 0.40000000000000002D * (double)j3);
02167         int j4 = i3 = l3 - i4;
02168         int k4 = S._mthif();
02169         if(a(11))
02170         {
02171             c c2 = _mthdo(i1, j1, false, g1, k1, false);
02172             k2 = c2._flddo;
02173             l1 = Math.max(l1, c2._flddo);
02174             i2 = i4 + c2._fldif;
02175             i4 += c2._fldif + c2.a;
02176         } else
02177         {
02178             S.a(k4);
02179         }
02180         int l4 = S._mthif();
02181         if(a(10))
02182         {
02183             c c3 = _mthint(i1, j1, false, g1, k1, false);
02184             l2 = c3._flddo;
02185             l1 = Math.max(l1, c3._flddo);
02186             j2 = j4 + c3.a;
02187             j4 += c3._fldif + c3.a;
02188         } else
02189         {
02190             S.a(l4);
02191         }
02192         if(flag)
02193         {
02194             S.a(k4);
02195             g1.drawImage(image, i1 + (l1 - k3) / 2, j1 - i3, PC);
02196             c c4;
02197             if(a(11))
02198             {
02199                 c4 = _mthdo(i1 + (l1 - k2) / 2, j1 + i2, true, g1, k1, false);
02200             } else
02201             {
02202                 S.a(k4);
02203             }
02204             int i5 = S._mthif();
02205             if(a(10))
02206             {
02207                 c4 = _mthint(i1 + (l1 - l2) / 2, j1 - j2, true, g1, k1, false);
02208             } else
02209             {
02210                 S.a(i5);
02211             }
02212         }
02213         return new c(l1, j4, i4);
02214     }
02215 
02216     private c _mthint(int i1, int j1, boolean flag, Graphics g1, int k1)
02217     {
02218         c c1 = new c();
02219         int l1 = g1.getFont().getSize();
02220         String s1 = D.w;
02221         c1 = _mthtry(i1, j1, flag, g1, k1, false);
02222         int i2 = c1._flddo;
02223         int j2 = i2 / 2;
02224         int k2 = l1 / 4;
02225         int l2 = c1._fldif + k2;
02226         int i3 = c1.a;
02227         if(flag)
02228         {
02229             int j3 = (j1 - l2) + k2;
02230             int k3 = l1 / 8;
02231             int l3 = i1 + i2;
02232             int i4 = i1 + j2;
02233             if(s1.equals(""))
02234             {
02235                 g1.drawLine(i1, j3, l3, j3);
02236                 g1.drawLine(i1 + (int)((double)i2 * 0.80000000000000004D), j3 - k3, l3, j3);
02237                 g1.drawLine(i1 + (int)((double)i2 * 0.80000000000000004D), j3 + k3, l3, j3);
02238             } else
02239             if(s1.equals("bar"))
02240             {
02241                 g1.drawLine(i1, j3, l3, j3);
02242             } else
02243             if(s1.equals("widehat"))
02244             {
02245                 g1.drawLine(i1, j3, i4, j3 - k2);
02246                 g1.drawLine(i4, j3 - k2, l3, j3);
02247             } else
02248             if(s1.equals("widetilde"))
02249             {
02250                 boolean flag1 = false;
02251                 int k4 = 0;
02252                 for(int l4 = 1; l4 < j2; l4++)
02253                 {
02254                     int j4 = k4;
02255                     k4 = (int)((double)k3 * Math.sin((4.0840704496667311D * (double)l4) / (double)j2));
02256                     g1.drawLine((i4 + l4) - 1, j3 + j4, i4 + l4, j3 + k4);
02257                     g1.drawLine((i4 - l4) + 1, j3 - j4, i4 - l4, j3 - k4);
02258                 }
02259 
02260             }
02261         }
02262         return new c(i2, l2 + 2, i3);
02263     }
02264 
02265     private boolean a(int i1)
02266     {
02267         return a(i1, "");
02268     }
02269 
02270     private boolean a(int i1, String s1)
02271     {
02272         int j1;
02273         while((j1 = S._mthint().y) == 25) ;
02274         if(j1 == i1)
02275         {
02276             return true;
02277         }
02278         if(!s1.equals(""))
02279         {
02280             printStatus("Parser: " + s1 + " not found");
02281         }
02282         return false;
02283     }
02284 
02285     private boolean a(int i1, int j1)
02286     {
02287         return a(i1, j1, "");
02288     }
02289 
02290     private boolean a(int i1, int j1, String s1)
02291     {
02292         int k1;
02293         while((k1 = S._mthint().y) == 25) ;
02294         boolean flag = k1 == i1;
02295         while((k1 = S._mthint().y) == 25) ;
02296         flag = k1 == j1;
02297         if(!flag && !s1.equals(""))
02298         {
02299             printStatus("Parser: " + s1 + " not found");
02300         }
02301         return flag;
02302     }
02303 
02304     private void a(Graphics g1, int i1)
02305     {
02306         if(i1 <= 1)
02307         {
02308             g1.setFont(d);
02309         } else
02310         if(i1 == 2)
02311         {
02312             g1.setFont(b);
02313         } else
02314         if(i1 == 3)
02315         {
02316             g1.setFont(_fldnull);
02317         } else
02318         {
02319             g1.setFont(_fldlong);
02320         }
02321     }
02322 
02323 }