Changeset 2874
- Timestamp:
- 2001-12-02T10:25:14+13:00 (22 years ago)
- Location:
- trunk/niupepa
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/niupepa/macros/npepa.dm
r2690 r2874 125 125 _imageviewtext_ [c=niupepa] {_gsimage_(_httpcurrentdocument_&gg=text,_document:httpiconetextof_,_document:httpiconetexton_,etext,_document:texticonviewtext_)} 126 126 127 _imagepdf_ [c=niupepa] {_gsimage_(_httpcurrentpdf_,_document:httpiconepdfof_,_document:iconepdfon_,epdf,_document:texticonpdf_)} 128 129 _httpcurrentpdf_ [c=niupepa] {_httpprefix_/collect/niupepa/index/assoc/_thisOID_/paper.pdf} 130 127 131 _imageviewabstract_ [c=niupepa] {_gsimage_(_httpdocument_&gg=text&cl=_cgiargcl_&d=_1_,_document:httpiconeabstrof_,_document:httpiconeabstron_,eabstr,_document:texticonviewabstract_)} 128 132 … … 163 167 _heightetextx_ [c=niupepa] {30} 164 168 169 _httpiconepdfof_ [c=niupepa] {_httpprefix_/collect/niupepa/images/epdfof.gif} 170 _httpiconepdfon_ [c=niupepa] {_httpprefix_/collect/niupepa/images/epdfon.gif} 171 165 172 _httpiconeabstrof_ [c=niupepa] {_httpprefix_/collect/niupepa/images/eabstrof.gif} 166 173 _httpiconeabstrof_ [c=niupepa,l=mi] {_httpprefix_/collect/niupepa/images/mi/eabstrof.gif} … … 194 201 _texticonprevimage_ [c=niupepa] {View preview image of this page} 195 202 _texticonviewtext_ [c=niupepa] {View the text of this page} 203 _texticonpdf_ [c=niupepa] {View the PDF version of this paper} 196 204 _texticoncommentary_ [c=niupepa] {View the commentary of this paper} 197 205 _texticonviewabstract_ [c=niupepa] {View the English abstract of this issue} -
trunk/niupepa/perllib/plugins/NPPlug.pm
r2614 r2874 202 202 $doc_obj->set_utf8_metadata_element ($topsection, 'abstract', $abstract) if defined $abstract; 203 203 $self->set_main_metadata ($doc_obj, $dir); 204 205 # process issue's pdf if one exists 206 my ($pdffile) = $file =~ /^([^\.]*)\.issue/i; 207 $pdffile .= ".pdf"; 208 $pdffile = &util::filename_cat($dir, "pdf", $pdffile); 209 if (-e $pdffile) { 210 $doc_obj->set_utf8_metadata_element ($topsection, "haspdf", "1"); 211 $doc_obj->associate_file($pdffile, "paper.pdf"); 212 } else { 213 $doc_obj->set_utf8_metadata_element ($topsection, "haspdf", "0"); 214 } 204 215 205 216 open (ISSUEFILE, $filename) || die "couldn't open $filename\n"; -
trunk/niupepa/src/recpt/niupepabrowsetools.cpp
r1023 r2874 36 36 ostream &logout) { 37 37 38 bool hastxt = false, hasimg = false, hasprevimg = false ;38 bool hastxt = false, hasimg = false, hasprevimg = false, haspdf = false; 39 39 text_tarray buttons; 40 40 text_t &arg_gg = args["gg"]; … … 46 46 metadata.insert ("hasimg"); 47 47 metadata.insert ("hasprevimg"); 48 metadata.insert ("haspdf"); 48 49 metadata.insert ("doctype"); 49 50 if (!get_info (arg_d, args["c"], metadata, false, collectproto, response, logout)) … … 53 54 if (response.docInfo[0].metadata["hasimg"].values[0] == "1") hasimg = true; 54 55 if (response.docInfo[0].metadata["hasprevimg"].values[0] == "1") hasprevimg = true; 56 if (response.docInfo[0].metadata["haspdf"].values[0] == "1") haspdf = true; 55 57 56 58 MetadataInfo_tmap::iterator it = response.docInfo[0].metadata.find ("doctype"); … … 90 92 if (get_info (abstract, args["c"], metadata, false, collectproto, response, logout)) 91 93 buttons.push_back ("_document:imageviewabstract_(" + abstract + "&gg=text)"); 94 95 if (haspdf) buttons.push_back ("_document:imagepdf_"); 96 92 97 } 93 98 -
trunk/niupepa/src/recpt/niupepadocaction.cpp
r1945 r2874 51 51 52 52 niupepadocaction::~niupepadocaction () { 53 }54 55 void niupepadocaction::set_java_macros (cgiargsclass &args, displayclass &disp) {56 57 text_t javaimagescontent = "_javaextras__javacommentary__javaviewabstract__javaviewpaper__javaabstractintro_";58 59 text_t &arg_gg = args["gg"];60 61 if (arg_gg == "full")62 javaimagescontent += "_javaprevimage__javaviewtext_";63 else if (arg_gg == "prev")64 javaimagescontent += "_javafullimage__javaviewtext_";65 else66 javaimagescontent += "_javafullimage__javaprevimage_";67 68 69 int arg_gt = args.getintarg("gt");70 int arg_hl = args.getintarg("hl");71 72 text_tarray::const_iterator button_here = formatinfo.DocumentButtons.begin();73 text_tarray::const_iterator button_end = formatinfo.DocumentButtons.end();74 75 while (button_here != button_end) {76 if (*button_here == "Detach")77 javaimagescontent += "_javadetach_";78 else if (*button_here == "Expand Text" && arg_gg == "text") {79 if (arg_gt == 1)80 javaimagescontent += "_javacontracttext__javacontinue_";81 else if (arg_gt == 2)82 javaimagescontent += "_javacontracttext_";83 else84 javaimagescontent += "_javaexpandtext_";85 } else if (*button_here == "Highlight" && arg_gg == "text") {86 if (arg_hl == 1)87 javaimagescontent += "_javanohighlighting_";88 else89 javaimagescontent += "_javahighlighting_";90 }91 button_here ++;92 }93 disp.setmacro ("javaimagescontent", "document", javaimagescontent);94 53 } 95 54 -
trunk/niupepa/src/recpt/niupepadocaction.h
r1023 r2874 36 36 protected: 37 37 38 void set_java_macros (cgiargsclass &args, displayclass &disp);39 40 38 void output_document (const text_t &OID, cgiargsclass &args, 41 39 recptproto *collectproto, displayclass &disp,
Note:
See TracChangeset
for help on using the changeset viewer.