ThinkGeo.com    |     Documentation    |     Premium Support

Labels and features cut off/disappear at certain zoom levels

I notice that sometimes features will cut off/disappear at certain zoom levels and then appear again when zooming in further. Same thing with labels. Is there a common issue that could cause this?

For the map itself, I am setting a bunch of custom levels in a zoomlevelset and then doing:
myMap.ZoomLevelSet = customZoomLevelSet;

My first question is, do I have to do anything to the individual layers (or overlays) for these zoom levels to apply? I am also doing this for each layer:

myLayer.DrawingQuality = DrawingQuality.HighSpeed;
myLayer.ZoomLevelSet.ZoomLevel01.DefaultTextStyle.OverlappingRule = LabelOverlappingRule.AllowOverlapping;
myLayer.ZoomLevelSet.ZoomLevel01.DefaultTextStyle.DrawingLevel = DrawingLevel.LabelLevel;
myLayer.ZoomLevelSet.ZoomLevel01.DefaultTextStyle.DuplicateRule = LabelDuplicateRule.UnlimitedDuplicateLabels;
myLayer.ZoomLevelSet.ZoomLevel01.DefaultTextStyle.FittingLineInScreen = true;
myLayer.ZoomLevelSet.ZoomLevel01.DefaultTextStyle.SuppressPartialLabels = false;
myLayer.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20;

Would any of those settings be preventing the custom zoom levels from applying and possibly causing the cut off/disappearing issue I’m seeing? A lot of this code is a remnant from thinkgeo 10.0 versions.

Also, the overlay containing this specific layer is set to TileType.MultiTile. This layer just contains a single feature (polygon or line) that is updated rapidly, being moved across the map.’’

Edit: I should mention that the “feature” being cut off is actually a point but uses a custom pointstyle which draws a line behind it in the shape of a rectangle. In the overridden drawcore I’m doing this for the line:

canvas.DrawLine(lineShape, GeoPens.Red, DrawingLevel.LevelOne); // lineShape is the line behind the point.

Here is an example:
image ![image|491x134]

So this is at a higher zoom level. The arrow is the “point”, and the rectangle behind it is the line I was drawing above. If I zoom in once, the left side disappears:
image

If I zoom in again, the right side disappears:
image ![image|686x312]

Basically more and more of it disappears the more I zoom in.

Update: If I instead override the DrawCore in the layer itself instead of the style, but using the exact same code, it does not get cut off. Is there a reason for this? I assume the inner-workings of a layer’s drawcore vs style’s drawcore are different.

Hi @Dan_Weaver,

Are you in singletile mode or multitile? Also, are you able to put together a sample app to attach to this post that shows the issue. That will speed the process quite a bit since these types of data/user specific issues are sometimes difficult to reproduce.

Thanks,
john