Changes between Version 5 and Version 6 of MapGuideRfc31
- Timestamp:
- 08/30/07 12:18:30 (17 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
MapGuideRfc31
v5 v6 1 = !MapGuide RFC 31 - SymbolDefinition Support for Edit Controls and Rich Text Support (Markup) =1 = !MapGuide RFC 31 - !SymbolDefinition Support for Edit Controls and Rich Text Support (Markup) = 2 2 3 3 This page contains an change request (RFC) for the !MapGuide Open Source project. … … 23 23 == Overview == 24 24 The purpose of this RFC is two-fold. 25 26 # One is to allow for rich text Labels from a variety of defined input formats. 27 # The second is to allow SymbolDefinitions to describe their parameter information in usage context terms, thus allowing consuming applications to present more sophisticated workflows and customized user interfaces. 25 * One is to allow for rich text Labels from a variety of defined input formats. 26 * The second is to allow !SymbolDefinitions to describe their parameter information in usage context terms, thus allowing consuming applications to present more sophisticated workflows and customized user interfaces. 28 27 29 28 == Motivation == 30 The next logical evolution of text/labeling in MapGuide is to permit rich text (multi-font, multi-line) capabilities. This facilitates the customization of labels in a variety of ways, allowing for a higher degree of customization. For example, if a particular label was too long to fit in its space (say, a short cul-de-sac having a very long name) a "narrow" variant of the font used might be selected to permit it to fit, or the geometry of the font might be appropriately condensed.31 32 Additionally, the rich new functionality from the usage of SymbolDefinitions as presented byCompositeSymbolization presents a challenge due to its inherent flexibility (read complexity). To enable users to harness its capabilities without getting lost in the myriad possibilities, a mechanism to allow for customizable User Interfaces and simplified workflows based on active options is highly desired.29 The next logical evolution of text/labeling in !MapGuide is to permit rich text (multi-font, multi-line) capabilities. This facilitates the customization of labels in a variety of ways, allowing for a higher degree of customization. For example, if a particular label was too long to fit in its space (say, a short cul-de-sac having a very long name) a "narrow" variant of the font used might be selected to permit it to fit, or the geometry of the font might be appropriately condensed. 30 31 Additionally, the rich new functionality from the usage of !SymbolDefinitions as presented by !CompositeSymbolization presents a challenge due to its inherent flexibility (read complexity). To enable users to harness its capabilities without getting lost in the myriad possibilities, a mechanism to allow for customizable User Interfaces and simplified workflows based on active options is highly desired. 33 32 34 33 == Proposed Solution == 35 34 The proposed solution contains modifications to: 36 * The MDF Model,37 * The MDF Parser,38 * The Vector Symbolization Font Engine.35 * The MDF Model, 36 * The MDF Parser, 37 * The Vector Symbolization Font Engine. 39 38 40 39 === MDF Model Schema Modifications === 41 The proposed modifications to the MDF Model schema lie in the SymbolDefinition specification. While the current version of the SymbolDefinition schema is 1.0.0, if these changes are adopted then they will be present in theSymbolDefinition schema version 1.1.0.40 The proposed modifications to the MDF Model schema lie in the !SymbolDefinition specification. While the current version of the !SymbolDefinition schema is 1.0.0, if these changes are adopted then they will be present in the !SymbolDefinition schema version 1.1.0. 42 41 43 42 The proposed changes can be divided into two distinct categories. … … 82 81 }}} 83 82 84 ''to'' one that includes the '''<Markup>''' element, as follows: {{AnnoDL|TextSchema}}83 ''to'' one that includes the '''<Markup>''' element, as follows: 85 84 {{{ 86 85 <xs:complexType name="Text"> … … 89 88 <xs:extension base="GraphicBase"> 90 89 <xs:sequence> 91 <xs:element name="Markup" type="xs:string" default="'Plain'" minOccurs="0" />92 <xs:annotation><xs:documentation>The markup format of the string content.</xs:documentation></xs:annotation></xs:element>93 90 <xs:element name="Content" type="xs:string" /> 94 91 <xs:element name="FontName" type="xs:string" default="'Arial'" /> … … 108 105 <xs:element name="GhostColor" type="xs:string" minOccurs="0" /> 109 106 <xs:element name="Frame" type="TextFrame" minOccurs="0" /> 107 <xs:element name="Markup" type="xs:string" default="'Plain'" minOccurs="0" /> 108 <xs:annotation><xs:documentation>The markup format of the string content.</xs:documentation></xs:annotation></xs:element> 110 109 <xs:element name="ExtendedData1" type="ExtendedDataType" minOccurs="0" /> 111 110 </xs:sequence> … … 117 116 ==== <Parameter> Modifications ==== 118 117 119 The second modification proposed is the set of values that can be present in the '''< DataType>''' element.<br>120 Currently the meaning for '''< DataType>''' is121 * '''"An optional data type declaration for the parameter."'''.118 The second modification proposed is the set of values that can be present in the '''<!DataType>''' element.<br> 119 Currently the meaning for '''<!DataType>''' is 120 * '''"An optional data type declaration for the parameter."'''. 122 121 The proposed change would extend that meaning to be 123 * '''"An optional explicit declaration of data type or ''data usage context''"124 125 In layman terms, that would imply that the DataType element could be used to define a value such as "Angle" which describes the usage of a more basic type like "double".<br>Furthermore, this rich description of the data type can allow consuming applications to afford more targeted user worklows and UI controls.126 127 The following documented values are proposed for the < DataType> element.122 * '''"An optional explicit declaration of data type or ''data usage context''" 123 124 In layman terms, that would imply that the !DataType element could be used to define a value such as "Angle" which describes the usage of a more basic type like "double". Furthermore, this rich description of the data type can allow consuming applications to afford more targeted user worklows and UI controls. 125 126 The following documented values are proposed for the <!DataType> element. 128 127 * Angle: ''a Real counterclockwise rotation, in degrees'' 129 * FillColor: ''a Color applied to the interior of a polygon or symbol''130 * LineColor: ''a Color applied to the edge of a polygon or symbol, or to a line''131 * LineWeight: ''a Real line thickness, in millimeters''128 * !FillColor: ''a Color applied to the interior of a polygon or symbol'' 129 * !LineColor: ''a Color applied to the edge of a polygon or symbol, or to a line'' 130 * !LineWeight: ''a Real line thickness, in millimeters'' 132 131 * Content: ''a String that is displayed in a symbol'' 133 132 * Markup: ''a String name of a rich text format used to interpret Content'' 134 * FontName: ''a String determining the font for text''133 * !FontName: ''a String determining the font for text'' 135 134 * Bold: ''a Boolean determining if text is displayed in bold font'' 136 135 * Italic: ''a Boolean determining if text is displayed in italic font'' 137 136 * Underlined: ''a Boolean determining if text is displayed underlined'' 138 * FontHeight: ''a Real height for text, in millimeters''139 * HorizontalAlignment: ''a String evaluating to a horizontal alignment enumeration''140 * VerticalAlignment: ''a String evaluating to a vertical alignment enumeration''137 * !FontHeight: ''a Real height for text, in millimeters'' 138 * !HorizontalAlignment: ''a String evaluating to a horizontal alignment enumeration'' 139 * !VerticalAlignment: ''a String evaluating to a vertical alignment enumeration'' 141 140 * Justification: ''a String evaluating to a justification enumeration'' 142 * LineSpacing: ''a Real vertical distance between text lines, in millimeters''143 * TextColor: ''a Color applied to text''144 * GhostColor: ''a Color applied to the background in the neighborhood of text''145 * FrameLineColor: ''a Color applied to the edge of a rectangle surrounding text''146 * FrameFillColor: ''a Color applied to the interior of a rectangle surrounding text''147 * StartOffset: ''a Real distance from a line feature's start to its first label, in millimeters''148 * EndOffset: ''a Real distance from a line feature's end to its last label, in millimeters''141 * !LineSpacing: ''a Real vertical distance between text lines, in millimeters'' 142 * !TextColor: ''a Color applied to text'' 143 * !GhostColor: ''a Color applied to the background in the neighborhood of text'' 144 * !FrameLineColor: ''a Color applied to the edge of a rectangle surrounding text'' 145 * !FrameFillColor: ''a Color applied to the interior of a rectangle surrounding text'' 146 * !StartOffset: ''a Real distance from a line feature's start to its first label, in millimeters'' 147 * !EndOffset: ''a Real distance from a line feature's end to its last label, in millimeters'' 149 148 * RepeatX: ''a Real distance between a line feature's labels or an area feature's labels (horizontally), in millimeters'' 150 149 * RepeatY: ''a Real distance between an area feature's labels (vertically), in millimeters'' 151 150 152 The changes proposed above affect the DataType values. <br>153 The schema for '''< DataType>''' changes from the current version.154 {{{ 155 <xs:simpleType name=" DataType">151 The changes proposed above affect the !DataType values. <br> 152 The schema for '''<!DataType>''' changes from the current version. 153 {{{ 154 <xs:simpleType name="!DataType"> 156 155 <xs:annotation> 157 156 <xs:documentation>Enumerates the allowed DataType values.</xs:documentation> … … 167 166 }}} 168 167 169 To include the new '''< DataType>''' values.168 To include the new '''<!DataType>''' values. 170 169 {{{ 171 170 <xs:simpleType name="DataType"> … … 205 204 }}} 206 205 207 Note: Vec Sym ''will'' add some more values to the above enumeration.208 206 209 207 ==== Example ==== … … 257 255 * Text class to store text element information. 258 256 The above class would require new methods to get and set the markup contents. 259 * There is no code change required for the DataType changes as it only affects the documentation/usage of the element.257 * There is no code change required for the !DataType changes as it only affects the documentation/usage of the element. 260 258 261 259 The MDF Parser uses the IOText class to read and write the XML text definitions. It would be updated to handle reading and writing of the new Markup element, including proper versioning support.