gzz-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gzz-commits] gzz ./Gzz.py gzz/modules/pp/ImageCell.java gzz/...


From: Benja Fallenstein
Subject: [Gzz-commits] gzz ./Gzz.py gzz/modules/pp/ImageCell.java gzz/...
Date: Sat, 23 Nov 2002 08:44:21 -0500

CVSROOT:        /cvsroot/gzz
Module name:    gzz
Changes by:     Benja Fallenstein <address@hidden>      02/11/23 08:44:20

Modified files:
        .              : Gzz.py 
        gzz/modules/pp : ImageCell.java 
        gzz/view       : BoxCellView.java CellHBox.java CellInBox.java 
                         CellInBoxPlugin.java CoordinatePlaneView.java 
                         DimDecorator.java LollipopCellView.java 
                         MarkDecorator.java 
                         MultitypeCellContentView.java 
                         PlainVanishing.java RowColView.java 
                         TextCellContentView.java 
                         VobVanishingClient.java 

Log message:
        Get AWT client into shape again, refactor

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/Gzz.py.diff?tr1=1.46&tr2=1.47&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/modules/pp/ImageCell.java.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/BoxCellView.java.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/CellHBox.java.diff?tr1=1.10&tr2=1.11&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/CellInBox.java.diff?tr1=1.5&tr2=1.6&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/CellInBoxPlugin.java.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/CoordinatePlaneView.java.diff?tr1=1.6&tr2=1.7&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/DimDecorator.java.diff?tr1=1.17&tr2=1.18&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/LollipopCellView.java.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/MarkDecorator.java.diff?tr1=1.14&tr2=1.15&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/MultitypeCellContentView.java.diff?tr1=1.9&tr2=1.10&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/PlainVanishing.java.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/RowColView.java.diff?tr1=1.13&tr2=1.14&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/TextCellContentView.java.diff?tr1=1.25&tr2=1.26&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gzz/view/VobVanishingClient.java.diff?tr1=1.22&tr2=1.23&r1=text&r2=text

Patches:
Index: gzz/Gzz.py
diff -u gzz/Gzz.py:1.46 gzz/Gzz.py:1.47
--- gzz/Gzz.py:1.46     Mon Nov 18 05:28:15 2002
+++ gzz/Gzz.py  Sat Nov 23 08:44:20 2002
@@ -31,7 +31,7 @@
     bindings_type = 'java'
 
     def run(self):
-        self.style = self.graphicsAPI.getTextStyle("SansSerif", 
java.awt.Font.PLAIN, 10);
+        self.style = self.graphicsAPI.getTextStyle("SansSerif", 
java.awt.Font.PLAIN, 13);
         self.views = [gzz.view.VobVanishingClient(), 
                       gzz.view.RowColView(0), gzz.view.RowColView(1),
                       ]
Index: gzz/gzz/modules/pp/ImageCell.java
diff -u gzz/gzz/modules/pp/ImageCell.java:1.2 
gzz/gzz/modules/pp/ImageCell.java:1.3
--- gzz/gzz/modules/pp/ImageCell.java:1.2       Tue Nov  5 04:52:14 2002
+++ gzz/gzz/modules/pp/ImageCell.java   Sat Nov 23 08:44:20 2002
@@ -91,10 +91,10 @@
 
     }
 
-    public void getSize(Cell c, float[] out) {
+    public void getSize(Cell c, ViewContext context, float[] out) {
        Im r = get(c);
        if(r == null) {
-           def.getSize(c, out);
+           def.getSize(c, context, out);
            return;
        }
        out[0] = r.w; out[1] = r.h;
Index: gzz/gzz/view/BoxCellView.java
diff -u gzz/gzz/view/BoxCellView.java:1.2 gzz/gzz/view/BoxCellView.java:1.3
--- gzz/gzz/view/BoxCellView.java:1.2   Fri Nov 22 19:35:21 2002
+++ gzz/gzz/view/BoxCellView.java       Sat Nov 23 08:44:20 2002
@@ -45,51 +45,22 @@
  */
 
 public class BoxCellView extends CellView {
-public static final String rcsid = "$Id: BoxCellView.java,v 1.2 2002/11/23 
00:35:21 benja Exp $";
+public static final String rcsid = "$Id: BoxCellView.java,v 1.3 2002/11/23 
13:44:20 benja Exp $";
     public static boolean dbg = false;
     private static void p(String s) { if(dbg) pa(s); }
     private static void pa(String s) { System.err.println(s); }
 
     static Object CONTENT_KEY = new Object();
     static Object BOX_KEY = new Object();
-    static TextStyle style =
-       GraphicsAPI.getInstance().getTextStyle("SansSerif", Font.PLAIN, 10);
+    static Object UNCLIP = new Object();
+
+    static Rectangle rect = new Rectangle();
+    static float[] boxwh = new float[2];
 
-    //CellContentView ccv = new TextCellContentView(style);
-    //CellContentView ccv = new SpanCellContentView(style);
-    //CellContentView ccv = new LinebrokenCellContentView(style);
-    
-    /** The ccv to use, if any. XXX hack for demo, remove 
-     */
-    CellContentView cellContentView = null; // use viewcontext's by default
-    public BoxCellView() {}
-    public BoxCellView(CellContentView ccv) { cellContentView = ccv; }
-    
     Dim d_clone;
-    /*
-    Dim d_cursor;
-    Dim d_spaces;
-    Dim d_mark;
-    */
-
-    // CompoundSpace space;
-
-    /** @see #getSliceId.
-     * To be compared using ==
-     **/
-    Object sliceId = null;
 
     public void setSpace(Space s) {
        d_clone = s.getCloneDim();
-       /*
-       d_cursor = s.getDim(Dims.d_cursor_id);
-       d_spaces = s.getDim(Dims.d_spaces_id);
-       d_mark = s.getDim(Dims.d_mark_id);
-       */
-       /*
-       if(s instanceof CompoundSpace)
-           space = (CompoundSpace)s;
-       */
     }
 
     Cell center;
@@ -97,31 +68,15 @@
         if(center == this.center || center.equals(this.center)) return;
        this.center = center;
        setSpace(center.space);
-       sliceId = getSliceId(center);
     }
 
-    public void getSize(Cell c, float scale, float[] into) {
-       into[0] = style.getWidth("XXXXXXXXXX", scale)/scale+10;
-       into[1] = style.getHeight(scale)/scale + 10;
+    public void getSize(Cell c, float scale, ViewContext context,
+                       float[] into) {
+       context.getCellContentView().getSize(c, scale, context, into);
+       into[0] += 10; 
+       into[1] += 10;
     }
 
-    static Object UNCLIP = new Object();
-
-    /** Get an Id for the slice this Cell is in.
-     *  Iff getSliceId(c).equals(getSliceId(d)), c and d are in the same slice.
-     */
-    public Object getSliceId(Cell c) {
-       return null;
-       /*
-       if(space == null) return null;
-       return space.getSpace(c);
-       */
-    }
-
-    static Rectangle rect = new Rectangle();
-
-    float[] boxwh = new float[2];
-
     public void place(final Cell c, final VobScene vs, 
                        final int box,
                       final ViewContext context) {
@@ -129,8 +84,7 @@
        if(d_clone == null)
            throw new NullPointerException("clone dim not set in BoxCellView");
             
-        final CellInBox ccv = 
-            cellContentView != null ? cellContentView : 
context.getCellContentView();
+        final CellInBox ccv = context.getCellContentView();
 
        final RectBgVob bg = new RectBgVob();
 
@@ -146,13 +100,6 @@
 
        if (context.isMarked(c)) // if marked
            bg.addColor(new Color(0xff0000));
-
-       Object sliceId2 = getSliceId(c);
-       if((sliceId==null && sliceId2!=null)
-          || (sliceId != null && !sliceId.equals(sliceId2))
-          ) { // if different slice
-           bg.setBg(bg.getBg().darker().darker());
-       }
 
        float pad = 5;
 
Index: gzz/gzz/view/CellHBox.java
diff -u gzz/gzz/view/CellHBox.java:1.10 gzz/gzz/view/CellHBox.java:1.11
--- gzz/gzz/view/CellHBox.java:1.10     Fri Nov  1 20:23:45 2002
+++ gzz/gzz/view/CellHBox.java  Sat Nov 23 08:44:20 2002
@@ -43,7 +43,7 @@
         this.cell = cell;
        this.view = view;
        this.context = context;
-       view.getSize(cell, size);
+       view.getSize(cell, context, size);
        w = size[0];
        h = size[1];
     }
Index: gzz/gzz/view/CellInBox.java
diff -u gzz/gzz/view/CellInBox.java:1.5 gzz/gzz/view/CellInBox.java:1.6
--- gzz/gzz/view/CellInBox.java:1.5     Fri Nov  1 20:23:45 2002
+++ gzz/gzz/view/CellInBox.java Sat Nov 23 08:44:20 2002
@@ -35,7 +35,7 @@
  * the default implementations call each other.
  */
 public abstract class CellInBox {
-public static final String rcsid = "$Id: CellInBox.java,v 1.5 2002/11/02 
01:23:45 benja Exp $";
+public static final String rcsid = "$Id: CellInBox.java,v 1.6 2002/11/23 
13:44:20 benja Exp $";
     /** Place the contents of one cell into the given coord system.
      * The coordsys given shall be a mapping from the rectangle
      * (0,w)x(0,h) onto the screen.
@@ -49,8 +49,8 @@
     /** Get the default size of the cell.
      * @param c The cell to get size for, or null for a default size.
      */
-    public void getSize(Cell c, float[] out) {
-       getSize(c, 1, out);
+    public void getSize(Cell c, ViewContext context, float[] out) {
+       getSize(c, 1, context, out);
     }
 
     /** Get the default size of the cell at a given scale.
@@ -61,7 +61,8 @@
      * they are not multiplied by the scale parameter.
      * @param c The cell to get size for, or null for a default size.
      */
-    public void getSize(Cell c, float scale, float[] out) {
-       getSize(c, out);
+    public void getSize(Cell c, float scale, ViewContext context,
+                       float[] out) {
+       getSize(c, context, out);
     }
 }
Index: gzz/gzz/view/CellInBoxPlugin.java
diff -u gzz/gzz/view/CellInBoxPlugin.java:1.4 
gzz/gzz/view/CellInBoxPlugin.java:1.5
--- gzz/gzz/view/CellInBoxPlugin.java:1.4       Fri Nov  1 20:23:45 2002
+++ gzz/gzz/view/CellInBoxPlugin.java   Sat Nov 23 08:44:20 2002
@@ -40,11 +40,12 @@
        sub.place(c, sc, box, context);
        hook.placed(c, sc, box, context);
     }
-    public void getSize(Cell c, float[] out) {
-       sub.getSize(c, out);
+    public void getSize(Cell c, ViewContext context, float[] out) {
+       sub.getSize(c, context, out);
     }
-    public void getSize(Cell c, float scale, float[] out) {
-       sub.getSize(c, scale, out);
+    public void getSize(Cell c, float scale, ViewContext context,
+                       float[] out) {
+       sub.getSize(c, scale, context, out);
     }
 
 }
Index: gzz/gzz/view/CoordinatePlaneView.java
diff -u gzz/gzz/view/CoordinatePlaneView.java:1.6 
gzz/gzz/view/CoordinatePlaneView.java:1.7
--- gzz/gzz/view/CoordinatePlaneView.java:1.6   Wed Nov  6 12:41:22 2002
+++ gzz/gzz/view/CoordinatePlaneView.java       Sat Nov 23 08:44:20 2002
@@ -35,7 +35,7 @@
  */
 
 public class CoordinatePlaneView implements View {
-public static final String rcsid = "$Id: CoordinatePlaneView.java,v 1.6 
2002/11/06 17:41:22 benja Exp $";
+public static final String rcsid = "$Id: CoordinatePlaneView.java,v 1.7 
2002/11/23 13:44:20 benja Exp $";
     public static boolean dbg = true;
     private static void pa(String s) { System.err.println(s); }
 
@@ -64,7 +64,7 @@
            if(dbg) pa("CPV: "+item+" "+firstCoord);
            if(firstCoord != null) {
                int[] place = gzz.client.Params.getInts(firstCoord, d_coords, 
2, null);
-               cv.getSize(item, bs);
+               cv.getSize(item, context, bs);
 
                if(dbg) pa("CPV PLACE: "+place[0]+" "+place[1]+" "+
                                bs[0]+" "+bs[1]);
Index: gzz/gzz/view/DimDecorator.java
diff -u gzz/gzz/view/DimDecorator.java:1.17 gzz/gzz/view/DimDecorator.java:1.18
--- gzz/gzz/view/DimDecorator.java:1.17 Fri Nov 22 20:28:15 2002
+++ gzz/gzz/view/DimDecorator.java      Sat Nov 23 08:44:20 2002
@@ -34,28 +34,31 @@
  *  vob scene.
  */
 public class DimDecorator implements FallbackSceneDecorator {
-String rcsid = "$Id: DimDecorator.java,v 1.17 2002/11/23 01:28:15 humppake Exp 
$";
+String rcsid = "$Id: DimDecorator.java,v 1.18 2002/11/23 13:44:20 benja Exp $";
     public static boolean dbg = true;
     private static void p(String s) { if(dbg) pa(s); }
     private static void pa(String s) { System.err.println(s); }
 
-    static BoxCellView cvf = new BoxCellView();
-    static TextStyle style = cvf.style;
-    static float[] size = new float[2];
-    static {
-       cvf.getSize(null, size);
-    }
+    static TextStyle style = 
+       GraphicsAPI.getInstance().getTextStyle("SansSerif", 
java.awt.Font.PLAIN, 12);
 
     static Vob bg = new RectBgVob();
-    static Vob conn = new SimpleConnection(0, 0, 0, 0, Color.red);
+    static Vob conn = new SimpleConnection(0.5f, 0.5f, 0.5f, 0.5f, Color.red);
 
     static Object origKey = new Object(), viewKey = new Object();
     static Object boxKey = new Object(), whKey = new Object();
     static Object[] dimKeys = { new Object(), new Object(), new Object() };
 
+    /** The spacing between the boxes with the different dimensions.
+     */
+    int space = 2;
+
     public void render(VobScene sc, int into, Fallback fallback, Fallback.Win 
win) {
         //p("Placing DimDecorations");
 
+       float[] size = new float[2];
+       win.getCellView().getSize(null, win, size);
+
        int ndims = win.dimsIndices.length;
        Fallback.FallbackDim[] dims = new Fallback.FallbackDim[ndims];
 
@@ -65,19 +68,18 @@
        float w = size[0], h = size[1];
 
        // The coordinate system where the lines start
-       int orig = sc.orthoCS(into, origKey, 0, 0, 0, 1, 1);
+       int orig = sc.orthoBoxCS(into, origKey, 0, 0, 0, 1, 1, w, h);
 
        // The coordinate systems of the dimensions
        int[] targ = {
-           sc.translateCS(into, dimKeys[0], w, 0),
-           sc.translateCS(into, dimKeys[1], 0, h),
-           sc.translateCS(into, dimKeys[2], w, h)
+           sc.orthoBoxCS(into, dimKeys[0], 0, w+space, 0, 1, 1, w, h),
+           sc.orthoBoxCS(into, dimKeys[1], 0, 0, h+space, 1, 1, w, h),
+           sc.orthoBoxCS(into, dimKeys[2], 0, w+space, h+space, 1, 1, w, h)
        };
 
        for(int i=0; i<3; i++) {
            sc.map.put(conn, targ[i], orig);
-            int cs_box = sc.orthoCS(targ[i], boxKey, 1, 0, 0, w, h);
-           sc.map.put(bg, cs_box);
+           sc.map.put(bg, targ[i]);
             
            int cs = sc.orthoCS(targ[i], dimKeys[i], 0, 5, 5, h-10, h-10);
            sc.map.put(new TextVob(style, dims[i].name), cs);
Index: gzz/gzz/view/LollipopCellView.java
diff -u gzz/gzz/view/LollipopCellView.java:1.4 
gzz/gzz/view/LollipopCellView.java:1.5
--- gzz/gzz/view/LollipopCellView.java:1.4      Fri Nov 22 19:53:08 2002
+++ gzz/gzz/view/LollipopCellView.java  Sat Nov 23 08:44:20 2002
@@ -38,7 +38,7 @@
 /** A factory for making ball-and-stick aka lollipop cell vobs. */
 
 public class LollipopCellView extends BoxCellView {
-public static final String rcsid = "$Id: LollipopCellView.java,v 1.4 
2002/11/23 00:53:08 humppake Exp $";
+public static final String rcsid = "$Id: LollipopCellView.java,v 1.5 
2002/11/23 13:44:20 benja Exp $";
     float[] boxwh = new float[2];
 
     /** Add the vobs that make up an image of a cell 
@@ -56,8 +56,7 @@
        if(d_clone == null)
            throw new NullPointerException("clone dim not set in 
LollipopCellView");
             
-        final CellInBox ccv = 
-            cellContentView != null ? cellContentView : 
context.getCellContentView();
+        final CellInBox ccv = context.getCellContentView();
 
        /** Uses OvalBgVob as the ball. */
        final OvalBgVob bg = new OvalBgVob();
@@ -74,13 +73,6 @@
 
        if (context.isMarked(c)) // if marked
            bg.addColor(new Color(0xff0000));
-
-       Object sliceId2 = getSliceId(c);
-       if((sliceId==null && sliceId2!=null)
-          || (sliceId != null && !sliceId.equals(sliceId2))
-          ) { // if different slice
-           bg.setBg(bg.getBg().darker().darker());
-       }
 
 
        float pad = 5;
Index: gzz/gzz/view/MarkDecorator.java
diff -u gzz/gzz/view/MarkDecorator.java:1.14 
gzz/gzz/view/MarkDecorator.java:1.15
--- gzz/gzz/view/MarkDecorator.java:1.14        Thu Nov 21 22:55:20 2002
+++ gzz/gzz/view/MarkDecorator.java     Sat Nov 23 08:44:20 2002
@@ -43,7 +43,7 @@
                        Fallback.Win win) {
        float[] size = new float[2];
 
-       cv.getSize(null, size);
+       cv.getSize(null, win, size);
 
        int n = DefaultBinder.marks.size();
        if(n == 0) return;
Index: gzz/gzz/view/MultitypeCellContentView.java
diff -u gzz/gzz/view/MultitypeCellContentView.java:1.9 
gzz/gzz/view/MultitypeCellContentView.java:1.10
--- gzz/gzz/view/MultitypeCellContentView.java:1.9      Tue Nov  5 03:21:02 2002
+++ gzz/gzz/view/MultitypeCellContentView.java  Sat Nov 23 08:44:20 2002
@@ -58,8 +58,8 @@
        v(c).place(c, sc, box, context);
     }
 
-    public void getSize(Cell c, float[] out) {
-       v(c).getSize(c, out);
+    public void getSize(Cell c, float scale, ViewContext context, float[] out) 
{
+       v(c).getSize(c, scale, context, out);
     }
 
 }
Index: gzz/gzz/view/PlainVanishing.java
diff -u gzz/gzz/view/PlainVanishing.java:1.3 
gzz/gzz/view/PlainVanishing.java:1.4
--- gzz/gzz/view/PlainVanishing.java:1.3        Fri Nov  1 20:23:45 2002
+++ gzz/gzz/view/PlainVanishing.java    Sat Nov 23 08:44:20 2002
@@ -42,19 +42,19 @@
  */
 
 public class PlainVanishing {
-public static final String rcsid = "$Id: PlainVanishing.java,v 1.3 2002/11/02 
01:23:45 benja Exp $";
+public static final String rcsid = "$Id: PlainVanishing.java,v 1.4 2002/11/23 
13:44:20 benja Exp $";
     public static boolean dbg = false;
     protected static void p(String s) { if(dbg) pa(s); }
     protected static void pa(String s) { System.err.println(s); }
 
     // XXX Assume single-threaded
 
-    // public float[] shrink = new float[] {0.9f, 0.9f, 0.9f, 0.9f};
+    //public float[] shrink = new float[] {0.9f, 0.9f, 0.9f, 0.9f};
     public float[] shrink = new float[] {0.8f, 0.8f, 0.8f, 0.8f};
 
-    public float initmul = 1.6f; // 3f;
+    public float initmul = 1.3f; // 3f;
 
-    public float xgapmult = 1.5f;
+    public float xgapmult = 1.3f;
     public float ygapmult = 1.5f;
 
 
Index: gzz/gzz/view/RowColView.java
diff -u gzz/gzz/view/RowColView.java:1.13 gzz/gzz/view/RowColView.java:1.14
--- gzz/gzz/view/RowColView.java:1.13   Sat Nov 23 07:24:58 2002
+++ gzz/gzz/view/RowColView.java        Sat Nov 23 08:44:20 2002
@@ -53,7 +53,7 @@
         Dimension cellSize = new Dimension();
 
        float[] foosize = new float[2]; // XXX cleanup
-        fact.getSize(null, foosize);
+        fact.getSize(null, context, foosize);
        cellSize.width = (int)foosize[0];
        cellSize.height = (int)foosize[1];
 
Index: gzz/gzz/view/TextCellContentView.java
diff -u gzz/gzz/view/TextCellContentView.java:1.25 
gzz/gzz/view/TextCellContentView.java:1.26
--- gzz/gzz/view/TextCellContentView.java:1.25  Sat Nov 23 07:24:58 2002
+++ gzz/gzz/view/TextCellContentView.java       Sat Nov 23 08:44:20 2002
@@ -39,7 +39,7 @@
  */
 
 public class TextCellContentView extends CellContentView {
-public static final String rcsid = "$Id: TextCellContentView.java,v 1.25 
2002/11/23 12:24:58 benja Exp $";
+public static final String rcsid = "$Id: TextCellContentView.java,v 1.26 
2002/11/23 13:44:20 benja Exp $";
     public static boolean dbg = false;
     private static void pa(String s) { System.err.println(s); }
 
@@ -52,10 +52,15 @@
         this.style = style;
     }
 
-    public void getSize(Cell c, float[] out) {
-       String s = c.t();
-       out[0] = style.getWidth(s, 1);
-       out[1] = style.getHeight(1);
+    public void getSize(Cell c, float scale, ViewContext context, 
+                       float[] out) {
+       String s;
+       if(c != null)
+           s = c.t();
+       else
+           s = "XXXXXXXXXXXX";
+       out[0] = style.getWidth(s, scale) / scale;
+       out[1] = style.getHeight(scale) / scale;
     }
 
     float[] boxwh = new float[2];
Index: gzz/gzz/view/VobVanishingClient.java
diff -u gzz/gzz/view/VobVanishingClient.java:1.22 
gzz/gzz/view/VobVanishingClient.java:1.23
--- gzz/gzz/view/VobVanishingClient.java:1.22   Fri Nov  1 20:23:45 2002
+++ gzz/gzz/view/VobVanishingClient.java        Sat Nov 23 08:44:20 2002
@@ -42,31 +42,6 @@
     VobScene into;
     int intoCS;
 
-    /** The zoom level.
-     * Currently, three levels: 0 = usual cell size, 1 = half-zoomed,
-     * 2 = pixel-pixel.
-     */
-    public static int zoom = 0;
-
-    public static void toggleZoom() {
-        zoom++;
-       zoom %= 3;
-    }
-
-    /** Whether to apply zoom to this view.
-     */
-    public boolean usezoom = true;
-
-    /** Which page to show on multipage spans
-     * XXX We might want this to be reset when the span changes
-     */
-    static int page = 0;
-
-    static public void changePage(int offs) {
-       page += offs;
-       if(page < 0) page = 0;
-    }
-
 
     /** The SimpleConnection objects we use to connect cells */
     SimpleConnection[][] connections = new SimpleConnection[2][2];
@@ -105,7 +80,7 @@
 
     float[] s = new float[2];
     public Object getVobSize(Cell c, float fract, int flags, Dimension outDim) 
{
-       cvf.getSize(null, fract, s);
+       cvf.getSize(null, fract, context, s);
        outDim.width = (int)(s[0] * fract);
        outDim.height = (int)(s[1] * fract);
        return null;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]