[Chameleon] PanMap widget update.

Paul Spencer pspencer at dmsolutions.ca
Thu Jul 7 09:04:03 EDT 2005


I think I have finally figured out what the problem is.  If you are 
using a valid doctype in your template, it can force browsers into 
standards compliance mode instead of quirks mode.  This is not 
necessarily a bad thing, but it means that any css styles or js code 
that sets styles related to positioning MUST INCLUDE "px" ... so if you 
set the top position of an element through js
var top = 100;
myDiv.style.top = top;

this becomes invalid and is ignored.  To do it properly, you must do:

myDiv.style.top = top + "px";

The code that handles the ruler and the pan does not do this properly 
due to its age.

Now that I understand the problem, I've been  able to fix it for Bart. 
He will be doing some further testing and committing the changes to CVS 
at some point soon (I hope).

The immediate workaround would be to remove the doctype if that is a 
possibility for you



|Paul Spencer                           pspencer at dmsolutions.ca   |
|Applications & Software Development                              |
|DM Solutions Group Inc                 http://www.dmsolutions.ca/|

More information about the Chameleon mailing list