Changeset 577:9251719154a3 in documentViewer
- Timestamp:
- Oct 18, 2012, 3:53:09 PM (12 years ago)
- Branch:
- default
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
MpiwgXmlTextServer.py
r576 r577 160 160 161 161 docinfo['pageNumbers'] = pages 162 logging.debug("got pageNumbers=%s"%repr(pages))163 162 164 163 # toc … … 296 295 if punditMode: 297 296 self._addPunditAttributes(pagediv, pageinfo, docinfo) 297 298 # TODO: move empty page text 299 ep = dom.find(".//div[@class='emptyPage']") 300 if ep is not None: 301 pagediv.append(ep) 298 302 299 303 s = serialize(pagediv) … … 545 549 start = (pn - 1) * size 546 550 547 #fullresult = ET.fromstring(resultxml)548 #fullresult = resultxml549 #logging.debug("resultxml=%s"%repr(resultxml))550 551 551 if resultxml is not None: 552 552 # paginate … … 554 554 last = first+size 555 555 tocdivs = resultxml[first:last] 556 #del fullresult[:first]557 #del fullresult[len:]558 #tocdivs = fullresult559 556 560 557 toc = ET.Element('div', attrib={'class':'queryResultPage'}) … … 621 618 tocs = fulltoc[first:last] 622 619 tp = '<div>' 620 label = {'figures': 'Figure', 'handwritten': 'Handwritten note'}.get(mode, 'Item') 623 621 for toc in tocs: 624 622 pageurl = self.getLink('pn', toc['pn']) … … 628 626 tp += '<div class="toc name">[%s] %s</div>'%(toc['level-string'], toc['content']) 629 627 else: 630 tp += '<div class="toc name">[ Figure %s]</div>'%(toc['level-string'])628 tp += '<div class="toc name">[%s %s]</div>'%(label, toc['level-string']) 631 629 632 630 if toc.get('no', None): … … 659 657 660 658 def manage_addMpiwgXmlTextServer(self,id,title="",serverUrl="http://mpdl-text.mpiwg-berlin.mpg.de/mpdl/interface/",timeout=40,RESPONSE=None): 661 #def manage_addMpiwgXmlTextServer(self,id,title="",serverUrl="http://mpdl-text.mpiwg-berlin.mpg.de:30030/mpdl/interface/",timeout=40,RESPONSE=None): 662 """add zogiimage""" 659 """add MpiwgXmlTextServer""" 663 660 newObj = MpiwgXmlTextServer(id=id,title=title,serverUrl=serverUrl,timeout=timeout) 664 661 self.Destination()._setObject(id, newObj) -
css/docuviewer.css
r576 r577 99 99 -o-transform-origin: top left; 100 100 left: 7px; 101 top: 3 2em;101 top: 34em; 102 102 width: 40em; 103 103 padding: 0px; … … 269 269 margin-bottom: 0.25em; 270 270 } 271 /* normalization forms *272 div.col.main div.content.text div.text.orig span.w span.reg,273 div.col.main div.content.text div.text.orig span.w span.norm {274 display: none;275 }276 div.col.main div.content.text div.text.reg span.w span.orig,277 div.col.main div.content.text div.text.reg span.w span.norm {278 display: none;279 }280 div.col.main div.content.text div.text.norm span.w span.orig,281 div.col.main div.content.text div.text.norm span.w span.reg {282 display: none;283 }284 /* dictionary forms *285 div.col.main div.content.text div.text.plain span.w a.dictionary {286 display: none;287 }288 div.col.main div.content.text div.text.dict span.w span.nodictionary {289 display: none;290 }291 */292 271 /* page break */ 293 272 div.col.main div.content.text span.pb span.n, … … 311 290 } 312 291 div.col.main div.content.text span.note span.noteSign { 292 display: none; 293 /* font-size: 70%; 294 vertical-align: super; */ 295 } 296 /* handwritten */ 297 div.col.main div.content.text span.handwritten { 298 display: block; 299 /* float: left; */ 300 margin-top: 0.5em; 301 margin-bottom: 0.5em; 302 padding: 5px; 303 border: 1px dashed silver; 304 } 305 div.col.main div.content.text span.handwritten span.figureNum { 313 306 display: none; 314 307 /* font-size: 70%; -
documentViewer.py
r571 r577 150 150 toc_figures = PageTemplateFile('zpt/toc_figures', globals()) 151 151 toc_concordance = PageTemplateFile('zpt/toc_concordance', globals()) 152 toc_handwritten = PageTemplateFile('zpt/toc_handwritten', globals()) 152 153 toc_none = PageTemplateFile('zpt/toc_none', globals()) 153 154 # other templates -
zpt/common_template.zpt
r571 r577 113 113 tal:condition="python:docpath and docinfo.get('pageNumbers', None)"><span><a 114 114 tal:omit-tag="python:tocMode=='concordance'" tal:attributes="href python:here.getLink('tocMode','concordance')">Concordance</a></span></li> 115 <li tal:attributes="class python:here.getStyle(tocMode, 'handwritten')" 116 tal:condition="python:docpath and docinfo.get('numHandwritten', None)"><span><a 117 tal:omit-tag="python:tocMode=='handwritten'" tal:attributes="href python:here.getLink('tocMode','handwritten')">Notes</a></span></li> 115 118 <li tal:attributes="class python:here.getStyle(tocMode, 'figures')" 116 119 tal:condition="python:docpath and docinfo.get('numFigureEntries', None)"><span><a
Note: See TracChangeset
for help on using the changeset viewer.