[OpenLayers-Users] mouse cursor position when using e.g. EditingToolbar

Lehtonen, Mika mika at digikartta.net
Tue Sep 30 16:18:20 EDT 2008


Answering to myself:

Now, after a while, when I started to dig this again and wrote something 
down, I realized that I had style setting:
html, body {margin: 10px; ........}
on my html. Removing html from that setting fixed my problem although IE 
is still a bit inaccurate on this issue. I can live with it (and without 
it.. ;-) ).

Sorry for mailing my problems without first checking and double checking 
my code.
- mika -

Lehtonen, Mika kirjoitti:
> Hi,
>
> this problem has been disturbing me for a long time now. If I set an 
> EditingToolbar on my page and set e.g. style of the 'html,body' to be 
> .... margin: 10 px; ...., the drawing of the vector features isn't so 
> easy anymore because the mouse cursor will be also 10 px aside from its 
> right position. So if I set my cursor to be crosshair cursor, the start 
> of the line isn't the cross but 14 px south-east from it. This is a 
> Firefox (3.03 current version) issue. I was wondering just right now, 
> whether the lines are also drawn with the same error? I mean, are they 
> there where they should be, compared to the map under them or is it just 
> the cursor which isn't at the right place?
>
> In IE7, the margin setting doesn't effect at all. The "error" is always 
> the same, some 2-4 px to south-east, nevertheless the margin setting.
>
> What can I do to prevent this? In EditingToolbar example the cursor 
> seems to be behaving properly, although with the "normal" cursor, you 
> can't be for sure. I can't find any style setting anymore, which might 
> influence on my problem. I am using 2.7 RC in this demo, if I recall 
> right, but the problem is the same with the latest also.
>
>
> - mika -
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>   



More information about the Users mailing list