Changes between Version 42 and Version 43 of MapGuideRfc14
- Timestamp:
- 02/19/07 17:01:53 (18 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
MapGuideRfc14
v42 v43 169 169 This time the line weight for the path has been parametrized. Its default value is 1 mm, as specified in the !ParameterDefinition element, and this can be overridden at the symbol instance level. We’ve also changed the path’s line cap and line join styles to round. 170 170 171 Note that when the line weight is modified the spacing between the vertical ticks does *not* change. The path geometry is fixed. If you want the symbol to get bigger / smaller to account for the line weight then this would be done using the symbol instance scales. For example, setting the scales to “1 + !LineWeight/ 5” would ensure that there is always 5 mm of empty horizontal space between adjacent vertical ticks.171 Note that when the line weight is modified the spacing between the vertical ticks does *not* change. The path geometry is fixed. If you want the symbol to get bigger / smaller to account for the line weight then this would be done using the symbol instance scales. For example, setting the scales to “1 + %LINE_WEIGHT% / 5” would ensure that there is always 5 mm of empty horizontal space between adjacent vertical ticks. 172 172 173 173 '''Example 4:''' line style with start / end symbols … … 249 249 }}} 250 250 251 In this version of the schemathe order of the symbols in the compound determines the draw order. Here, the start and end symbols are drawn on top of the dashing. For the start symbol the !StartOffset and Repeat are set to 0. This ensures the symbol is only drawn once at the start of the feature. Likewise, for the end symbol we set the !EndOffset and Repeat to 0. We also want !OverlapNoWrap for the !VertexControl. The symbol can overlap a vertex, but we simply want to “stamp” it – no bending around vertices.251 In this case the order of the symbols in the compound determines the draw order. Here, the start and end symbols are drawn on top of the dashing. For the start symbol the !StartOffset and Repeat are set to 0. This ensures the symbol is only drawn once at the start of the feature. Likewise, for the end symbol we set the !EndOffset and Repeat to 0. We also want !OverlapNoWrap for the !VertexControl. The symbol can overlap a vertex, but we simply want to “stamp” it – no bending around vertices. 252 252 253 253 One other note: the default !AngleControl behavior is !FromGeometry. This means the angle of the start / end symbol will be computed from the geometry, as shown here. … … 335 335 }}} 336 336 337 This means that the parameter named 1 can be set to an expression in the Layer Definition, based on style choices made by the map author. The !SymbolDefinition must also declare this parameter in its !ParameterDefinition element. Here it can describe what that parameter does and also providea default value for the parameter. Here is a sample !SymbolDefinition with this !ParameterDefinition element:337 This means that the parameter named 1 can be set to an expression in the Layer Definition, based on style choices made by the map author. The !SymbolDefinition must also declare this parameter in its !ParameterDefinition element. Here it describes what that parameter does and also provides a default value for the parameter. Here is a sample !SymbolDefinition with this !ParameterDefinition element: 338 338 339 339 {{{ … … 375 375 }}} 376 376 377 For translation of this symbol other languages, our solution is to create a translated parameter section and attach that to the !SymbolDefinition resource in the !MapGuide repository as Resource Data. The name of the attached resource will contain the locale of the translation. For example, if the original symbol is called Symbol.xml, the German translated section would be called Symbol.xml.de. Here is what it would look like:377 For translation of this symbol into other languages, our solution is to create a translated parameter section and attach that to the !SymbolDefinition resource in the !MapGuide repository as Resource Data. The name of the attached resource will contain the locale of the translation. For example, if the original symbol is called Symbol.xml, the German translated section would be called Symbol.xml.de. Here is what it would look like: 378 378 379 379 {{{ … … 382 382 <Name>DickeEisenBahnShiene</Name> 383 383 <Description>Das ist ein Eisenbahnschienen Symbol</Description> 384 ...385 384 <ParameterDefinition> 386 385 <Parameter>