Hello list!

Many thanks to Jacques Paris, Patrick Phillips, Alex Teleshev and Ahmet Dabanli who 
answered to my
question quoted below.

In the end it turned out that my MapBasic code was OK. The "distortions" I observed 
have not been
caused by a wrong code but by the map`s projection. I include the answers of Jacques 
Paris which
have been very helpful to me.

Thanks a lot!

Holger Sternad
[EMAIL PROTECTED]

------------------------------------------------------------------------

Here is what I did in the Mapbasic window, with the original map as
frontwindow()

dim win as integer
win=frontwindow()
run command windowinfo(win,15)

That will clone the map. The clone is the front window, rerun
win=frontwindow(). Then a long one

set map window win center((mapperinfo(win,3)+mapperinfo(win,5))/2,
(mapperinfo(win,4)+mapperinfo(win,6))/2) zoom mapperinfo(win,1)/2

Et voil�!

Jacques PARIS



Jacques,

... But as you can see from the screenshot attached to this e-mail (not attached in 
this summary!)
the content of the smaller window does not exactly coincide with the map shown by the 
original
window. (You can clearly see it by looking at the vertical lines.) Somehow the content 
of the cloned
window gets distorted. ...

Holger



Holger,

I will make a guess that your map is in some kind of un-projected coordinate system 
(degrees of
lon/lat). That would explain your "distortions". To display them, MI must project 
those maps on the
screen somewhat and as the centre of the 2 mappers are not the same ... Ah! why don't 
we live on a
flat world? ...



------------------------------------------------------------------------

original question:

I have tried to solve this problem - without success. Hopefully anyone has a solution 
for this:

What I`m trying to do is to generate a new map window which displays an area limited 
by the
coordinate values of the lower left corner of an existing map window on the one hand 
and the center
of the existing window on the other hand (i.e. the area displayed in the new window 
will be a
quarter of the original area):

*********
*       *
*---|   *
*   |   *
*********

*: existing map window
-: new map window

I can create a new window, set the new window size and use the "set map zoom"-command 
without
problems and therefore I am able to generate a map window which has the same scale as 
the original
window and the size that I need. But as soon as I use "set map pan" to move the map 
view the map in
the new window gets somehow distorted and does not coincide with the corresponding 
part of the
original view any more.





----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]

Reply via email to