/[gzz]/gzz/gzz/view/pagespanview.py
ViewVC logotype

Diff of /gzz/gzz/view/pagespanview.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by benja, Tue Oct 1 17:40:36 2002 UTC revision 1.7 by tjl, Wed Oct 2 10:32:04 2002 UTC
# Line 5  from gfx.libutil import nvcode Line 5  from gfx.libutil import nvcode
5  from gfx.libutil import effects  from gfx.libutil import effects
6  import gzz  import gzz
7  import java  import java
8    from jarray import zeros
9    
10  papermill = gfx.libpaper.papermill.ThePaperMill()  papermill = gfx.libpaper.papermill.ThePaperMill()
11    
# Line 136  class CellPDFView: Line 137  class CellPDFView:
137                      cliprect = None,                      cliprect = None,
138                      fancy = 1,                      fancy = 1,
139                      showTessel = 0):                      showTessel = 0):
140            self.papercoordsys = cs1into
141            self.cliprect = cliprect
142          key = self.cell.getId()          key = self.cell.getId()
143          # The height in coords          # The height in coords
144          papers = self.pap          papers = self.pap
# Line 211  class CellPDFView: Line 214  class CellPDFView:
214          return (          return (
215              page * self.scaledsheetsize[0] + self.scale * pointx/72.0/6, self.scale * pointy/72.0/6              page * self.scaledsheetsize[0] + self.scale * pointx/72.0/6, self.scale * pointy/72.0/6
216          )          )
217        def hitClip(self, coords, point3, cliprect):
218            src = zeros(3, 'f') # assume only one point
219            coords.inverseTransformPoints3(self.papercoordsys, point3, src)
220            x = src[0]
221            y = src[1]
222            print "hitclip: ",point3, src, x, y
223            if not cliprect:
224                cliprect = (0, 0, self.scaledsize, 1)
225            if cliprect[0] < x < cliprect[2] and cliprect[1] < y < cliprect[3]:
226                return (x,y)
227            return None
228            
229    
230  class KEY: pass  class KEY: pass
231    

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26