Changeset 74:5c9837484085 in documentViewer
- Timestamp:
- Nov 4, 2008, 8:36:51 PM (16 years ago)
- Branch:
- default
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
documentViewer.py
r73 r74 140 140 141 141 security.declareProtected('View','index_html') 142 def index_html(self,mode,url,viewMode="auto",start=None,pn=1 ):142 def index_html(self,mode,url,viewMode="auto",start=None,pn=1,mk=None): 143 143 ''' 144 144 view it … … 168 168 viewMode="images" 169 169 170 return pt(docinfo=docinfo,pageinfo=pageinfo,viewMode=viewMode )170 return pt(docinfo=docinfo,pageinfo=pageinfo,viewMode=viewMode,marks=self.generateMarks(mk)) 171 171 172 172 def generateMarks(self,mk): 173 ret="" 174 for m in mk: 175 ret+="mk=%s"%mk 176 return ret 177 173 178 def getLink(self,param=None,val=None): 174 179 """link to documentviewer with parameter param set to val""" -
zpt/image_main.zpt
r52 r74 1 1 <tal:block tal:define="docinfo options/docinfo; pageinfo options/pageinfo; mode python:options.get('viewMode','images')"> 2 <iframe tal:condition="python:mode=='images'" height="100%" width="100%" tal:attributes="src string:${here/imageViewerUrl}fn=${docinfo/imagePath}&pn=${pageinfo/current} "/>2 <iframe tal:condition="python:mode=='images'" height="100%" width="100%" tal:attributes="src string:${here/imageViewerUrl}fn=${docinfo/imagePath}&pn=${pageinfo/current}${options/marks}"/> 3 3 <iframe tal:condition="python:mode=='text'" height="100%" width="100%" tal:attributes="src string:${here/textViewerUrl}fn=${docinfo/textURL}&pn=${pageinfo/current}&lang=${docinfo/lang}"/> 4 4 </tal:block> -
zpt/viewer_main.zpt
r49 r74 13 13 </td> 14 14 <td width="100%" valign="top"> 15 <tal:block tal:content="structure python:here.template.image_main(docinfo=docinfo,pageinfo=pageinfo,viewMode=viewMode )" />15 <tal:block tal:content="structure python:here.template.image_main(docinfo=docinfo,pageinfo=pageinfo,viewMode=viewMode,mk=mk)" /> 16 16 </td> 17 17 </tr>
Note: See TracChangeset
for help on using the changeset viewer.