Changeset 585:83eeed69793f in documentViewer for zpt
- Timestamp:
- Nov 13, 2012, 4:33:34 PM (11 years ago)
- Branch:
- default
- Location:
- zpt
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
zpt/viewer_images.zpt
r543 r585 3 3 <html xmlns="http://www.w3.org/1999/xhtml" 4 4 tal:define="docinfo options/docinfo; pageinfo options/pageinfo; viewMode pageinfo/viewMode; 5 viewLayer pageinfo/viewLayer; viewLayers pageinfo/viewLayers; 6 availableLayers python:here.getAvailableLayers().get('images', None); 5 7 tocMode pageinfo/tocMode; viewerUrl docinfo/viewerUrl; 6 8 numPages docinfo/numPages | nothing; dlBaseUrl docinfo/digilibBaseUrl | nothing;"> … … 27 29 'scalerInsets' : {'x':300, 'y':100}\n 28 30 };\n'''%(dlBaseUrl,docinfo.get('imagePath',''),pageinfo.get('pn','1'))"></script> 31 32 <!-- layer headers (rendered always) --> 33 <tal:block tal:repeat="layer availableLayers"> 34 <tal:block tal:define="mpath string:here/template/layer_images_${layer}/macros/html_head" tal:condition="python:exists(mpath)"> 35 <metal:block metal:use-macro="python:path(mpath)" /> 36 </tal:block> 37 </tal:block> 29 38 30 39 <script type="text/javascript"> … … 57 66 <metal:block metal:use-macro="python:path('here/template/toc_%s/macros/main'%tocMode)" /> 58 67 </div> 59 <!-- col-main: text page -->68 <!-- col-main: document page --> 60 69 <div class="col main"> 61 70 <div class="ruler top"> … … 70 79 </div> 71 80 <!-- /col-main --> 81 72 82 <div class="col buttons"> 83 <!-- layer switcher --> 84 <div class="options" tal:condition="availableLayers"> 85 <h4>Image layer</h4> 86 <form tal:attributes="action viewerUrl" class="autosubmit"> 87 <input type="hidden" tal:define="params python:here.getParams(params={'viewLayer':None})" 88 tal:repeat="param params" tal:attributes="name param; value python:params[param]" /> 89 <ul> 90 <!-- layer select buttons (rendered always) --> 91 <tal:block tal:repeat="layer availableLayers"> 92 <tal:block tal:define="mpath string:here/template/layer_images_${layer}/macros/layer_select_li" 93 tal:condition="python:exists(mpath)"> 94 <li metal:use-macro="python:path(mpath)" /> 95 </tal:block> 96 </tal:block> 97 </ul> 98 <input type="submit" value="Go!" /> 99 </form> 100 </div> 101 102 <!-- digilib options --> 73 103 <div class="options digilib"> 74 104 <ul> … … 105 135 </ul> 106 136 </div> 137 138 <!-- layer option boxes (rendered if active) --> 139 <tal:block tal:repeat="layer availableLayers"> 140 <tal:block tal:define="mpath string:here/template/layer_images_${layer}/macros/options_box" 141 tal:condition="python:exists(mpath)"> 142 <metal:block metal:use-macro="python:path(mpath)" /> 143 </tal:block> 144 </tal:block> 107 145 </div> 108 </div> 109 <!-- page-body -->146 </div><!-- /page-body --> 147 110 148 <div class="page-body" tal:condition="python:not here.isAccessible(docinfo)"> 111 149 <div class="errortext">Sorry, access to this document is restricted.</div> -
zpt/viewer_text.zpt
r571 r585 74 74 <!-- right-side options --> 75 75 <div class="col buttons"> 76 <!-- "BEGIN TEXT DISPLAY"-->76 <!--BEGIN TEXT LAYERS --> 77 77 <div class="options" tal:condition="availableLayers"> 78 78 <h4>Text layer</h4> … … 92 92 </form> 93 93 </div> 94 <!-- "END TEXT DISPLAY"-->94 <!--END TEXT LAYERS--> 95 95 96 96 <!--"BEGIN TEXT SIZE"-->
Note: See TracChangeset
for help on using the changeset viewer.