Changeset 1622
- Timestamp:
- 07/11/07 23:47:54 (1 year ago)
- Files:
-
- gaphas/branches/hw/gaphas/examples.py (modified) (2 diffs)
- gaphas/branches/hw/gaphas/view.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
gaphas/branches/hw/gaphas/examples.py
r1611 r1622 14 14 from geometry import point_on_rectangle, distance_rectangle_point 15 15 from util import text_extents, text_align, text_multiline, path_ellipse 16 from cairo import Matrix 16 17 17 18 class Box(Element): … … 168 169 169 170 # Make glue distance depend on the zoom ratio (should be about 10 pixels) 170 glue_distance, dummy = view.transform_distance_c2w(10, 0) 171 inverse = Matrix(*view.matrix) 172 inverse.invert() 173 glue_distance, dummy = inverse.transform_distance(10, 0) 171 174 glue_point = None 172 175 glue_item = None gaphas/branches/hw/gaphas/view.py
r1611 r1622 47 47 self._dirty_matrix_items = set() 48 48 49 matrix = property(lambda s: s._matrix) 49 matrix = property(lambda s: s._matrix, 50 doc="Canvas to view transformation matrix") 50 51 51 52 def _set_canvas(self, canvas):
