[mapguide-users] FW: Problems while labeling polylines

Traian Stanev traian.stanev at autodesk.com
Sun Dec 30 17:33:25 EST 2007


For your item 3:
============
3) To get it looking GoogleMaps-alike, you'll have to use at least two
separate layers: one for borders, the other (one pixel narrower, above it)
for continuous fill. In my case, both of them are stored in base layer
group.
=============

You do not need to use separate layers to achieve this style. You can use a composite line style, consisting of two thick lines (one 2 pixels thicker than the other) to achieve the same effect. MapGuide has code to detect this situation and automatically render so that the result looks the same as what you have on the picture.

For item 4:

===========
4) Road labels (street names) were generated dinamically, they're not part
of base layer group. It turns out that they're best fit that way, don't
overlap too much and never get displayed upside-down.
===========

This is actually a good idea -- using dynamic overlay labels allows the labeling algorithm more freedom when placing labels (as opposed to when labeling tiles in a base layer) and it is more likely to get it right, especially when it has to stitch up line segments that make up the same street so that it can label them together (it makes up what you call NaN on the fly).

Traian


-----Original Message-----
From: mapguide-users-bounces at lists.osgeo.org [mailto:mapguide-users-bounces at lists.osgeo.org] On Behalf Of Maksim Sestic
Sent: Saturday, December 29, 2007 8:32 AM
To: mapguide-users at lists.osgeo.org
Subject: Re: [mapguide-users] FW: Problems while labeling polylines


Road network stylization sometimes turns out to be a challenging task,
especially if you have Google Maps in mind. Take a look at the attachment,
and the steps to reproduce visuals/behaviour:

1) First of all, you need to prepare your network topology in a NaN fashion
(Node-Arc-Node), and stick to that rule: roads are continuos LineStrings, if
there's a crossing - LineString ends. Each arc in a topology needs to get
properly coded (road code) and named.

2) Road network represents a layer being updated rarely (more or less), so
it's one of the candidates for one of the base layer groups.

3) To get it looking GoogleMaps-alike, you'll have to use at least two
separate layers: one for borders, the other (one pixel narrower, above it)
for continuous fill. In my case, both of them are stored in base layer
group.

4) Road labels (street names) were generated dinamically, they're not part
of base layer group. It turns out that they're best fit that way, don't
overlap too much and never get displayed upside-down.

I hope this helps.

Regards,
Maksim Sestic

http://www.nabble.com/file/p14537519/ROADS.jpg
--
View this message in context: http://www.nabble.com/FW%3A-Problems-while-labeling-polylines-tp14525210s16610p14537519.html
Sent from the MapGuide Users mailing list archive at Nabble.com.

_______________________________________________
mapguide-users mailing list
mapguide-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapguide-users


More information about the mapguide-users mailing list