| 103 | ===== !StartOffset and !EndOffset Default Values in !LineUsage ===== |
| 104 | The !LineUsage element defines !StartOffset and !EndOffset elements which are used to control the offset of the symbol distribution at the start and end of a polyline. The current !SymbolDefinition schema uses default values of zero for these elements. The corrected behavior will be to not specify default values for these elements. Here's an example where the original default values cause a problem: |
| 105 | |
| 106 | {{{ |
| 107 | <LineUsage> |
| 108 | <EndOffset>0.0</EndOffset> |
| 109 | <Repeat>1.0</Repeat> |
| 110 | </LineUsage> |
| 111 | }}} |
| 112 | |
| 113 | In this case the user wants the symbol distribution to repeat at an interval of 1 mm, and end exactly at the end of the polyline. The !StartOffset is unspecified, and should therefore not be taken into account when computing the distribution. The current schema documentation, however, indicates that the !StartOffset has a default value of zero if not specified, which implies that it actually should be taken into account. |
| 114 | |
| 115 | The proposed change in behavior is to only take into account the !StartOffset and/or !EndOffset elements if they are specified in the XML instance document. In general here is the behavior: |
| 116 | |
| 117 | Repeat specified and greater than zero: |
| 118 | * !StartOffset and !EndOffset both unspecified |
| 119 | * symbols are distributed along the polyline using the Repeat value, with equal start and end offsets |
| 120 | * the effective start and end offsets vary per polyline depending on its length |
| 121 | * !StartOffset specified and !EndOffset unspecified |
| 122 | * the symbol distribution has the specified start offset and repeats at the specified value |
| 123 | * the effective end offset varies per polyline depending on its length |
| 124 | * !StartOffset unspecified and !EndOffset specified |
| 125 | * the symbol distribution has the specified end offset and repeats at the specified value |
| 126 | * the effective start offset varies per polyline depending on its length |
| 127 | * !StartOffset and !EndOffset both specified |
| 128 | * the symbol distribution has the specified start and end offsets, and repeats at approximately the specified value |
| 129 | |
| 130 | Repeat less than or equal to zero (or unspecified): |
| 131 | * !StartOffset and !EndOffset both unspecified |
| 132 | * no symbols are drawn |
| 133 | * !StartOffset specified and !EndOffset unspecified |
| 134 | * a single symbol is drawn at the specified offset relative to the start of the polyline |
| 135 | * !StartOffset unspecified and !EndOffset specified |
| 136 | * a single symbol is drawn at the specified offset relative to the end of the polyline |
| 137 | * !StartOffset and !EndOffset both specified |
| 138 | * symbols are drawn at the specified offsets relative to the start and end of the polyline |
| 139 | |
| 140 | |