Mercurial > hg > digilib-old
annotate client/digitallibrary/oldskin/dlMenu.html @ 643:c108607e1bc0 jquery
zoomin and -out works now
gotopage resets (some) parameters
reload takes changed parameters (to put in url)
getParamString omits parameters with default values (for shorter urls)
author | robcast |
---|---|
date | Wed, 19 Jan 2011 20:03:44 +0100 |
parents | e01e9112adc3 |
children |
rev | line source |
---|---|
314 | 1 <html> |
2 <head> | |
3 <style type="text/css"> | |
4 .menu {position:absolute; visibility:hidden} | |
5 | |
6 .item1 {position:absolute; left:33; width:50; height:14; clip:rect(0,50,14,0); visibility:hidden} | |
7 .item2 {position:absolute; left:43; width:40; height:14; clip:rect(0,40,14,0); visibility:hidden} | |
8 .item3 {position:absolute; left:3; width:80; height:14; clip:rect(0,80,14,0); visibility:hidden} | |
372 | 9 .logo { margin-left: 5px; margin-top: 10px; } |
314 | 10 |
11 .text {font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; color: #FFFFFF; text-decoration: none} | |
12 </style> | |
13 <script language="JavaScript" src="buttons/menu.js"></script> | |
14 | |
15 <script language="JavaScript"> | |
16 // because on a netscape 4.xx bug (messing up with layers on resize) we cache the window | |
17 // resize event and redisplay the navigation frame | |
18 if (document.layers && !document.getElementById) { | |
19 window.onresize = function() {parent.rightFrame.location.reload();} | |
20 } | |
21 | |
22 /** | |
23 * overriding 'page' in navigation.js | |
24 */ | |
449
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
25 function page(page, keep) { |
314 | 26 |
449
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
27 parent.mainFrame.gotoPage(page, keep); |
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
28 if (parent.pageFrame.show) { |
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
29 parent.pageFrame.show(); |
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
30 } else { |
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
31 parent.pageFrame.location.reload(); |
314 | 32 } |
33 } | |
34 | |
35 /* | |
36 * new display function to refresh the pagesTotal frame | |
37 */ | |
38 | |
39 function display(detail) { | |
448
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
40 if (parent.pageFrame.show) { |
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
41 parent.pageFrame.show(); |
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
42 } else { |
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
43 parent.pageFrame.location.reload(); |
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
44 } |
314 | 45 parent.mainFrame.display(detail); |
46 } | |
47 | |
48 | |
49 function askPage() { | |
50 do { | |
51 p = prompt("Goto Page:", 1); | |
52 } while ((p != null) && (p < 1)); | |
53 page(p); | |
54 } | |
55 | |
56 function showRef(select) { | |
57 var hyperlinkRef = parent.mainFrame.baseUrl + "/digilib.jsp?"; | |
58 hyperlinkRef += parent.mainFrame.getAllParameters(); | |
59 if ( select == 0 ) { | |
60 prompt("Link for LaTeX-documents", "\\href{" + hyperlinkRef + "}{TEXT}"); | |
61 } else if ( select == 1 ) { | |
62 prompt("Link for HTML-documents", hyperlinkRef); | |
63 } | |
64 } | |
65 | |
66 function setSize(size) { | |
67 parent.mainFrame.setParameter('ws', size); | |
68 display(); | |
69 } | |
70 | |
71 function digicat() { | |
72 var fn = parent.mainFrame.getParameter("fn"); | |
73 var pn = parent.mainFrame.getParameter("pn"); | |
74 var url = parent.mainFrame.baseUrl + "/digicat.jsp?fn=" + fn + "&pn=" + pn; | |
75 win = window.open(url, "digicat"); | |
76 win.focus(); | |
77 } | |
78 | |
79 // boolean variable to either show or not show the additional help | |
80 // change in the menuitem its original mark | |
81 var showHelp = false; | |
82 | |
83 // variable to tell if while changing to another page it should keep the area | |
448
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
84 // change in the menuitem its original mark |
449
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
85 var keepArea = false; |
314 | 86 |
87 | |
88 // variable that store the texts for contexthelp | |
89 var helpText = new Array(); | |
90 | |
91 helpText[0] = "'back'-button|Click on this button to load the previous image (usually the next page from a manuscript)."; | |
92 helpText[1] = "'next'-button|Click on this button to load the next image (usually the next page from a manuscript)."; | |
93 helpText[2] = "'page'-button|After clicking 'page' you will be prompted for a specific page you want to see.<br>Note that the page number refers to the same serie you are in now."; | |
94 helpText[3] = "'digicat'-button|Click here to open a new window containing thumbnails of the current series pages to navigate."; | |
95 helpText[4] = "'mark'-button|You can set marks into the picture. After hitting 'mark' you have to click on the desired picures location, a numbered mark appears.<br>Check out 'reference' to make these marks (up to 8) visible for others."; | |
96 helpText[5] = "'reference'-button|Choose LaTeX or HTML mode to get a link for the actual (zoomed) picture with all set marks.<br>This link can easily be included in a TeX- or HTML-formatted document/page."; | |
97 helpText[6] = "'zoom area'-button|With 'zoom area' you can zoom into any rectangular field for the current picture.<br>After clicking on the button click on the image to set any corner (ex. topleft), release the mousebutton and move the mouse until you have the desired size, then click again."; | |
98 helpText[7] = "'zoom in'-button|Clicking on 'zoom in' zooms in around the current center."; | |
99 helpText[8] = "'zoom out'-button|Clicking on 'zoom out' zooms out around the current center."; | |
100 helpText[9] = "'full page'-button|To gain the original unzoomed picture, click on 'full page'.<br>Note that any set marks are still saved at their positions."; | |
101 helpText[10] = "'size'-button|By clicking on one of the menu entries you can select the size of the currently displayed picture in relation to your browser window.<br>Note: a scale factor of '1.0' means that the picture fits right into the working area, while '2.0' means that it will be twice as high and wide."; | |
102 helpText[11] = "'?'-button|In its menu you are able change options like the visibility of this contextsensitive help, with 'Keep area' digilib keeps its current zoom area when changing to another page."; | |
103 | |
104 </script> | |
105 </head> | |
106 | |
107 <body bgcolor="#CCCCCC" leftmargin="8" marginwidth="8" topmargin="5" marginheight="5" onload="preloadImages()" onunload="closeContextHelp()"> | |
108 | |
109 <a href="javascript:page('-1', keepArea)" onmouseover="overButton(0)" onmouseout="awayButton(0)"><img src="buttons/back0.gif" width="73" height="30" border="0"></a><br> | |
110 <a href="javascript:page('+1', keepArea)" onmouseover="overButton(1)" onmouseout="awayButton(1)"><img src="buttons/next0.gif" width="73" height="30" border="0"></a><br> | |
111 <a href="javascript:askPage()" onmouseover="overButton(2)" onmouseout="awayButton(2)"><img src="buttons/page0.gif" width="73" height="30" border="0"></a><br> | |
112 <a href="javascript:digicat()" onmouseover="overButton(3)" onmouseout="awayButton(3)"><img src="buttons/digicat0.gif" width="73" height="30" border="0"></a><br><br> | |
113 <a href="javascript:parent.mainFrame.setMark(false);" onmouseover="overButton(4)" onmouseout="awayButton(4)"><img src="buttons/mark0.gif" width="73" height="30" border="0"></a><br> | |
114 <a href="javascript:hideMenu(); showMenu(1)" onmouseover="overButton(5)" onmouseout="awayButton(5)"><img src="buttons/reference0.gif" width="73" height="30" border="0"></a><br><br> | |
115 <a href="javascript:parent.mainFrame.zoomArea()" onmouseover="overButton(6)" onmouseout="awayButton(6)"><img src="buttons/zoomarea0.gif" width="73" height="30" border="0"></a><br> | |
116 <a href="javascript:parent.mainFrame.zoomBy(1.4142)" onmouseover="overButton(7)" onmouseout="awayButton(7)"><img src="buttons/zoomin0.gif" width="73" height="30" border="0"></a><br> | |
117 <a href="javascript:parent.mainFrame.zoomBy(0.7071)" onmouseover="overButton(8)" onmouseout="awayButton(8)"><img src="buttons/zoomout0.gif" width="73" height="30" border="0"></a><br> | |
118 <a href="javascript:parent.mainFrame.zoomFullpage()" onmouseover="overButton(9)" onmouseout="awayButton(9)"><img src="buttons/fullpage0.gif" width="73" height="30" border="0"></a><br><br> | |
119 <a href="javascript:hideMenu(); showMenu(2)" onmouseover="overButton(10)" onmouseout="awayButton(10)"><img src="buttons/scale0.gif" width="73" height="30" border="0"></a><br><br> | |
120 <a href="javascript:hideMenu(); showMenu(3)" onmouseover="overButton(11)" onmouseout="awayButton(11)"><img src="buttons/questionmark0.gif" width="73" height="30" border="0"></a><br><br> | |
121 | |
122 <div id="menu1" class="menu" style="top:201; left:31; width:54; height:33; clip:rect(0,54,33,0)"></div> | |
123 <div id="menu11" class="item1" style="top:203"><center><a href="#" class="text" onClick="hideMenu(); showRef(0); return false;" onmouseover="overItem(11)" onmouseout="awayItem(11)">LaTeX</a></center></div> | |
124 <div id="menu12" class="item1" style="top:218"><center><a href="#" class="text" onClick="hideMenu(); showRef(1); return false;" onmouseover="overItem(12)" onmouseout="awayItem(12)">HTML</a></center></div> | |
125 | |
126 <div id="menu2" class="menu" style="top:379; left:41; width:44; height:93; clip:rect(0,44,93,0)"></div> | |
127 <div id="menu21" class="item2" style="top:381"><center><a href="#" class="text" onClick="hideMenu(); setSize(0.7); return false;" onmouseover="overItem(21)" onmouseout="awayItem(21)">0.7</a></center></div> | |
128 <div id="menu22" class="item2" style="top:396"><center><a href="#" class="text" onClick="hideMenu(); setSize(1.0); return false;" onmouseover="overItem(22)" onmouseout="awayItem(22)">1.0</a></center></div> | |
129 <div id="menu23" class="item2" style="top:411"><center><a href="#" class="text" onClick="hideMenu(); setSize(1.5); return false;" onmouseover="overItem(23)" onmouseout="awayItem(23)">1.5</a></center></div> | |
130 <div id="menu24" class="item2" style="top:426"><center><a href="#" class="text" onClick="hideMenu(); setSize(2.0); return false;" onmouseover="overItem(24)" onmouseout="awayItem(24)">2.0</a></center></div> | |
131 <div id="menu25" class="item2" style="top:441"><center><a href="#" class="text" onClick="hideMenu(); setSize(2.5); return false;" onmouseover="overItem(25)" onmouseout="awayItem(25)">2.5</a></center></div> | |
132 <div id="menu26" class="item2" style="top:456"><center><a href="#" class="text" onClick="hideMenu(); setSize(3.0); return false;" onmouseover="overItem(26)" onmouseout="awayItem(26)">3.0</a></center></div> | |
133 | |
134 <div id="menu3" class="menu" style="top:430; left:1; width:84; height:33; clip:rect(0,84,33,0)"></div> | |
135 <div id="menu31" class="item3" style="top:432"><center><a href="#" class="text" onclick="changeMark(31); hideMenu(); changeHelp(); return false;" onmouseover="overItem(31)" onmouseout="awayItem(31)"><img id="mark31" src="buttons/nomark.gif" border="0">Contexthelp</a></center></div> | |
449
e01e9112adc3
a little nicer implementation of back/next page in oldskin
robcast
parents:
448
diff
changeset
|
136 <div id="menu32" class="item3" style="top:447"><center><a href="#" class="text" onclick="changeMark(32); keepArea = (keepArea) ? false : true; return false;" onmouseover="overItem(32)" onmouseout="awayItem(32)"><img id="mark32" src="buttons/nomark.gif" border="0">Keep area</a></center></div> |
448
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
137 <!-- <div id="logo" class="logo"> |
372 | 138 <a href="http://digilib.berlios.de" target="_blank" > |
139 <img border="0" src="../img/digilib-logo-text1.png" title="digilib"></img> | |
140 </a> | |
448
e96757237406
fixed problem with next/prev page button in oldskin
robcast
parents:
372
diff
changeset
|
141 </div> --> |
314 | 142 |
143 <script language="Javascript"> | |
144 // initial background color of the menues (has to be done like this, | |
145 // otherwise menues in ns4 you will have wrong dimensions) | |
146 changeBc("menu1", "#666666"); | |
147 changeBc("menu2", "#666666"); | |
148 changeBc("menu3", "#666666"); | |
149 </script> | |
150 </body> | |
151 </html> |