====== Differences ====== This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
|
script_minimalistic_page_indicator [2014/04/21 13:47] trianguloy created |
script_minimalistic_page_indicator [2014/10/19 15:27] (current) trianguloy [Script code] |
||
|---|---|---|---|
| Line 16: | Line 16: | ||
| ====== Script code ====== | ====== Script code ====== | ||
| - | <code> | + | <sxh javascript> |
| //The special characters | //The special characters | ||
| var fill = "➊❷❸❹❺❻❼❽❾❿"; | var fill = "➊❷❸❹❺❻❼❽❾❿"; | ||
| Line 26: | Line 26: | ||
| var left = Math.round(cont.getBoundingBox().getLeft()/width); | var left = Math.round(cont.getBoundingBox().getLeft()/width); | ||
| - | var right = Math.round(cont.getBoundingBox().getRight()/width)-1; - | + | var right = Math.round(cont.getBoundingBox().getRight()/width)-1; |
| var page = Math.round(cont.getPositionX()/width); | var page = Math.round(cont.getPositionX()/width); | ||
| Line 52: | Line 52: | ||
| alert("Item not found. You need to label an item 'indicator'"); | alert("Item not found. You need to label an item 'indicator'"); | ||
| } | } | ||
| - | </code> | + | </sxh> |