MODULE; IMPORT VertexSizeAnim, Obliq, ObValue, ObLibAnim, GraphVBT; PROCEDURE ObliqExtension VertexSizeAnimLinear (<* UNUSED *> self: Closure; READONLY args: Obliq.Vals; loc : Obliq.Location): Obliq.Val RAISES {ObValue.Error} = VAR v: GraphVBT.Vertex; newW, newH: REAL; BEGIN IF NUMBER(args) # 3 THEN Obliq.RaiseError("VertexSizeAnim.Linear: Expecting 3 arguments", loc); END; TYPECASE args[0] OF ObLibAnim.ValVertex (oblV) => v := oblV.vertex ELSE Obliq.RaiseError("VertexSizeAnim.Linear: First arg not a vertex", loc) END; newW := FLOAT(Obliq.ToReal(args[1], loc)); (* Obliq uses LONGREAL *) newH := FLOAT(Obliq.ToReal(args[2], loc)); (* Obliq uses LONGREAL *) VertexSizeAnim.Linear(v, newW, newH); RETURN ObValue.valOk END VertexSizeAnimLinear; TYPE Closure = Obliq.SysCallClosure OBJECT OVERRIDES SysCall := VertexSizeAnimLinear; END; BEGIN Obliq.PackageSetup(); Obliq.RegisterSysCall("VertexSizeAnim.Linear", NEW(Closure)); END ObliqExtension.