42 |
def compare(self, r1, r2): |
def compare(self, r1, r2): |
43 |
return [t,r,s,v,u].index(r1) - [t,r,s,v,u].index(r2) |
return [t,r,s,v,u].index(r1) - [t,r,s,v,u].index(r2) |
44 |
|
|
45 |
view = gzz.loom.SimpleView(Cmp(), NodeView()) |
view = gzz.loom.SimpleView(NodeView()) |
46 |
|
|
47 |
def testSimple(): |
def testSimple(): |
48 |
r.addProperty(p, s) |
r.addProperty(p, s) |
51 |
r.addProperty(p, v) |
r.addProperty(p, v) |
52 |
|
|
53 |
vs = getvs() |
vs = getvs() |
54 |
cursor = gzz.loom.Cursor(r, s) |
cursor = gzz.loom.Cursor(Cmp(), r, s) |
55 |
view.render(vs, 0, cursor) |
view.render(vs, 0, cursor) |
56 |
|
|
57 |
cs_r, cs_s, cs_t, cs_u, cs_v = [vs.matcher.getCS(0, x) |
cs_r, cs_s, cs_t, cs_u, cs_v = [vs.matcher.getCS(0, x) |