Layer and Map Definition FAQ
Submitted by Admin on Sat, 2006-12-09 01:40.
- What map authoring tools are available for MapGuide Open Source?
- What are base layers? How are they different from regular layers?
- I've added base layers to my map. Why don't they don't display correctly?
- How do I force floating point values to appear as integers in my feature labels?
- How do I use the Text Expression Editor to combine property values and text constants to form a URL or feature label?
- I have defined an extension in my feature source that joins a primary feature source with a secondary feature source that has multiple matching records to the primary features. Can I specify which record from the secondary feature to retrieve from the join?
- 1. What map authoring tools are available for MapGuide Open Source?
-
There are 2 main authoring tools for MapGuide
- MapGuide Maestro, a free and open-source authoring tool
- Autodesk Infrastructure Studio (formerly known as MapGuide Studio) a commercial authoring tool bundled with Autodesk Infrastructure Map Server (formerly known as MapGuide Enterprise)
- 2. What are base layers? How are they different from regular layers?
- The map content for base layers is displayed using tiles. These tiles are rendered on demand and stored in a server-side cache. As you pan and zoom, any newly visible tiles are requested from the server. Assuming the cache for your map is reasonably populated, these pan and zoom operations should work smoothly. Note that this tile behavior applies only to the AJAX viewer. DWF Viewer handles base layers the same as regular layers.
Base layers are best used to display map content which doesn't change frequently, e.g. static data such as geographical features. - 3. I've added base layers to my map. Why don't they don't display correctly?
- Verify that the map contains a proper set of finite scales at which to render the base layers. The minimum and maximum finite scales should roughly match the limits at which you want your map to be viewed. Also, the relative factor between intermediate finite scales should not be too large (a factor of 2 is a good starting point).
- 4. How do I force floating point values to appear as integers in my feature labels?
- Feature labels may include number expressions, which can simply be the name of a number-bearing feature property, or can be a complex calculation involving multiple properties and constants. The numerical type (integer or real) for these expressions is taken from the first property or constant in the expression. If the feature property AREA contains real numbers, the label “AREA” will display real numbers. If the label expression is altered to first reference an integer, integer values will be displayed: “(0 + AREA)”.
For MapGuide Open Source 2.0 onwards, you can use the ToInt32() expression function to achieve the same purpose. - 5. How do I use the Text Expression Editor to combine property values and text constants to form a URL or feature label?
- A text expression is a concatenation of multiple string items. When the Text Expression Editor is in “Builder” mode, click “New” to add an item to the expression. Select each item and define its Text Value to be a property name, a constant string, or a number expression. The “Builder” editor converts this input into the text expression that is saved with a layer. Click the “Advanced” button to view and edit the text expression in its native format. The syntax for text expressions is:
Expression = “‹Property›”
| ´‹Constant›´
| (‹NumberExpression›)
| concat(‹Expression›, ‹Expression›)
As of MapGuide Open Source 2.2 the above expression can be simplified to this:
Expression = concat(‹Expression1›, ‹Expression2›, ..., ‹ExpressionN›) - 6. I have defined an extension in my feature source that joins a primary feature source with a secondary feature source that has multiple matching records to the primary features. Can I specify which record from the secondary feature to retrieve from the join?
- The result of a join defined by the feature source extension will be an extension that consists of the primary feature properties and the secondary feature properties. The secondary properties will be populated with values from the first matching record from the secondary feature source.