📄 ogr_feature_style.html
字号:
<B>Applicable geometry types:</B><UL><LI>Point: Not applicable.</LI><LI>Polyline: Not applicable.</LI><LI>Polygon: Defines the way the surface of a polygon is filled.</LI></UL>Here is the current list of BRUSH tool parameters. Note again that thislist can eventually grow and that all parameters are optional:<TABLE BORDER WIDTH="100%" ><TR><TH>param_name</TH><TH>Description</TH></TR><TR><TD ALIGN=CENTER>fc</TD> <TD> <P><B>Brush ForeColor</B>, expressed in hexadecimal (#RRGGBB[AA])<BR> [AA] the last 2 digits define the alpha channel value, with 0 being transparent and FF being opaque. The default for [AA] is FF (opaque)<BR> Suggested default brush color: 50% grey (c:#808080)<BR> Example: BRUSH(fc:#FF0000)<BR> Predefined color names may be allowed in future versions of the specification.</P> </TD></TR><TR><TD ALIGN=CENTER>bc</TD> <TD> <P><B>Brush BackColor</B>, expressed in hexadecimal (#RRGGBB[AA])<BR> [AA] the last 2 digits define the alpha channel value, with 0 being transparent and FF being opaque. The default for [AA] is FF (opaque)<BR> Suggested default brush color: 50% grey (c:#808080)<BR> Example: BRUSH(bc:#FF0000)<BR> Predefined color names may be allowed in future versions of the specification.</P> </TD></TR><TR><TD ALIGN=CENTER>id</TD><TD> <P><B>Brush Name or Brush Id</B> - Comma-delimited list of brush names or ids. The names in the comma-delimited list of ids are scanned until one is recognized by the target system.</P> <P>Brush Ids can be either system-specific ids (see further below) or be oneof the pre-defined OGR brush ids for well known brush patterns. The idparameter should always include one of the OGR ids at the end of the comma-delimited list of ids so that an application never has to rely on understanding system-specific ids. <P>Here is the current list of OGR brush ids (this could grow over time):<BR> <UL> <LI>ogr-brush-0: solid (the default when no id is provided) <LI>ogr-brush-1: null brush (transparent - no fill) <LI>ogr-brush-2: horizontal hatch /* ------ */ <LI>ogr-brush-3: vertical hatch /* |||||| */ <LI>ogr-brush-4: fdiagonal hatch /* \\\\\\ */ <LI>ogr-brush-5: bdiagonal hatch /* ////// */ <LI>ogr-brush-6: cross hatch /* ++++++ */ <LI>ogr-brush-7: diagcross hatch /* xxxxxx */ </UL> <P>Like with Pen Ids, system-specific brush ids are very likely to be meaningful only to that specific system that created them. The ids should start with the system's name, followed by a dash (-), followed by whatever information is meaningful to that system (a number, a name, a filename, etc.). <P>The following conventions will be used for common system-specific brush ids:</P> <UL> <LI>"bmp-filename.bmp" for Windows BMP patterns <LI>??? any others, e.g. vector symbols, WMF, ??? </UL> </TD></TR><TR><TD ALIGN=CENTER>a</TD><TD><B>Angle</B> - Rotation angle (in degrees, counterclockwise) to applyto the brush pattern.</TD></TR><TR><TD ALIGN=CENTER>s</TD><TD><B>Size or Scaling Factor</B> - Numeric value with or without units.<BR>If units are specified, then this value is the absolute size to drawthe brush or symbol.<BR>If no units are specified then it is taken as a scaling factor relativeto the symbol's default size.</TD></TR><TR><TD ALIGN=CENTER>dx, dy</TD><TD><B>Spacing</B> - If filling an area using point symbols, these valueswill define the spacing to use between them. "dx" is the horizontal distancebetween the center of 2 adjacent symbols and "dy" is the vertical distance.<BR>The default is to use the symbol's MBR width for dx, and the symbol'sheight for dy.</TD></TR><TR><TD ALIGN=CENTER>l</TD><TD><B>Priority Level</B> - Numeric value defining the order in which styleparts should be drawn. Lower priority style parts are drawn first, andhigher priority ones are drawn on top.<BR>If priority level is unspecified, the default is 1.</TD></TR></TABLE><H2>2.5 Symbol Tool Parameters</H2><B>Applicable geometry types:</B><UL><LI>Point: Place a symbol at the point's location</LI><LI>Polyline: Place symbols along the polyline, either at each vertex, or equallyspaced.</LI><LI>Polygon: Place the symbols on the outline of the polygon.</LI></UL>Here is the current list of SYMBOL tool parameters. Note again that thislist can eventually grow and that all parameters are optional:<TABLE BORDER WIDTH="100%" ><TR><TH>param_name</TH><TH>Description</TH></TR><TR><TD ALIGN=CENTER>id</TD> <TD> <P><B>Symbol Name or Id</B> - Comma-delimited list of symbol names or ids. The names in the comma-delimited list of ids are scanned until one is recognized by the target system.</P> <P>Symbol Ids can be either system-specific ids (see further below) or be oneof the pre-defined OGR symbol ids for well known symbols. The idparameter should always include one of the OGR ids at the end of the comma-delimited list of ids so that an application never has to rely on understanding system-specific ids. <P>Here is the current list of OGR symbol ids (this could grow over time):<BR> <UL> <LI>ogr-sym-0: cross (+) <LI>ogr-sym-1: diagcross (X) <LI>ogr-sym-2: circle (not filled) <LI>ogr-sym-3: circle (filled) <LI>ogr-sym-4: square (not filled) <LI>ogr-sym-5: square (filled) <LI>ogr-sym-6: triangle (not filled) <LI>ogr-sym-7: triangle (filled) <LI>ogr-sym-8: star (not filled) <LI>ogr-sym-9: star (filled) <LI>ogr-sym-10: vertical bar (can be rotated using angle attribute to produce diag bar) <LI>??? should any other common be included ??? </UL> <P>Like with Pen Ids, system-specific symbol ids are very likely to be meaningful only to that specific system that created them. The ids should start with the system's name, followed by a dash (-), followed by whatever information is meaningful to that system (a number, a name, a filename, etc.). <P>The following conventions will be used for common system-specific symbol ids:</P> <UL> <LI>"bmp-filename.bmp" for Windows BMP symbols <LI>??? any others, e.g. vector symbols, WMF, ??? </UL> </TD></TR><TR><TD ALIGN=CENTER>a</TD><TD><B>Angle</B> - Rotation angle (in degrees, counterclockwise) to applyto the symbol.</TD></TR><TR><TD ALIGN=CENTER>c</TD><TD> <P><B>Symbol Color</B>, expressed in hexadecimal (#RRGGBB[AA])<BR> [AA] the last 2 digits define the alpha channel value, with 0 being transparent and FF being opaque. The default for [AA] is FF (opaque)<BR> Suggested default symbol color: black (c:#000000)<BR> Example: SYMBOL(c:#FF0000)<BR> Predefined color names may be allowed in future versions of the specification.</P> </TD></TR><TR><TD ALIGN=CENTER>s</TD><TD><B>Size or Scaling Factor</B> - Numeric value with or without units.<BR>If units are specified, then this value is the absolute size to drawthe symbol.<BR>If no units are specified then it is taken as a scaling factor relativeto the symbol's default size.</TD></TR><TR><TD ALIGN=CENTER>dx, dy</TD><TD><B>X and Y offset</B> of the symbol's insertion point.<BR>Applies to point geometries, and to symbols placed at each vertex ofa polyline.</TD></TR><TR><TD ALIGN=CENTER>ds, dp, di</TD><TD><B>Spacing</B> - For symbols spaced along a line.<BR>"ds" is the step to use when placing symbols along the line.<BR>By default, symbols applied to a feature with a line geometry are placedat each vertex, but setting "ds" triggers the placement of symbols at anequal distance along the line. "ds" has no effect for a feature with apoint geometry.<BR>"dp" can be used together with "ds" to specifiy the perpendicular distancebetween the symbols' center and the line along which they're placed.<BR>Finally, "di" can be used to specifiy an initial offset from the beginningof the line.<BR>Example:<BR>SYMBOL(id:123, s:5, di:5px, ds:50px)</TD></TR><TR><TD ALIGN=CENTER>l</TD><TD><B>Priority Level</B> - Numeric value defining the order in which styleparts should be drawn. Lower priority style parts are drawn first, andhigher priority ones are drawn on top.<BR>If priority level is unspecified, the default is 1.</TD></TR></TABLE><H2>2.6 Label Tool Parameters</H2><B>Applicable geometry types:</B><UL><LI>Point: Place a text label at the point's location</LI><LI>Polyline: Place text along the polyline.</LI><LI>Polygon: Place a label at the centroid of the polygon. All parameters behaveexactly as if the geometry was a point located at the polygon's centroid.</LI></UL>Here is the current list of LABEL tool parameters. Note again that thatthis list can eventually grow and all parameters are optional:<TABLE BORDER WIDTH="100%" > <TR> <TH>param_name</TH> <TH>Description</TH> </TR> <TR> <TD ALIGN=CENTER>f</TD> <TD><B>Font Name</B> - <BR> Comma-delimited list of fonts names. works like the HTML FONT tag: the list of font names is scanned until a supported font name is encountered.<BR> Example: LABEL(f:"Arial, Helvetica", s:12pt, t:"Hello World!") </TD> </TR> <TR> <TD ALIGN=CENTER>s</TD> <TD><B>Font Size</B> - Numeric value with units.</TD> </TR> <TR> <TD ALIGN=CENTER>t</TD> <TD><B>Text String</B> - Can be a constant string, or a reference to anattribute field's value.<BR> Examples:<BR> LABEL(f:"Arial, Helvetica", s:12pt, t:"Hello World!")<BR> LABEL(f:"Arial, Helvetica", s:12pt, t:{text_value})</TD> </TR> <TR> <TD ALIGN=CENTER>a</TD> <TD><B>Angle</B> - Rotation angle (in degrees, counterclockwise).</TD> </TR> <TR> <TD ALIGN=CENTER>c</TD> <TD><B>Text Foreground Color</B>, expressed in hexadecimal (#RRGGBB[AA])<BR> Suggested default: black (c:#000000)<BR> Predefined color names may be allowed in future versions of the specification.</TD> </TR> <TR> <TD ALIGN=CENTER>b</TD> <TD><B>Text Background Color</B> - For text styles that use a second colorsuch as halo and box.</TD> </TR> <TR> <TD ALIGN=CENTER>h</TD> <TD><B>Shadow Color</B> - Color of the text shadow.</TD> </TR> <TR> <TD ALIGN=CENTER>w</TD> <TD><B>Stretch</B> - The stretch factor changes the width of all characters in the font by factor percent. For example, setting factor to 150 results in all characters in the font being 1.5 times (ie. 150%) wider. The default stretch factor is 100.</TD> </TR> <TR> <TD ALIGN=CENTER>st</TD> <TD><B>Strike out text</B></TD> </TR> <TR> <TD ALIGN=CENTER>m</TD> <TD><B>Label Placement Mode</B> - How is the text drawn relative to thefeature's geometry.<BR> "m:p" - The default, simple label attached to a point or to the firstvertex of a polyline.<BR> "m:l" - Text is attached to the last vertex of a polyline. A PEN toolcan be combined with this LABEL tool to draw the polyline as a leader tothe label.<BR> "m:s" - Strech text string along polyline, with an equal spacing betweeneach character.<BR> "m:m" - Place text as a single label at the middle of a polyline (basedon total line length).<BR> "m:w" - One word per line segment in a polyline.<BR><BR> "m:h" - Every word of text attached to polyline is placed horizontallyin its segment, anchor point is a center of segment.<BR><BR> "m:a" - Every word of text attached to polyline is stretched to fitthe segment of polyline and placed along that segment. The anchor point isa start of a segment.<BR> </TR> <TR> <TD ALIGN=CENTER>p</TD> <TD> <TABLE BORDER=0 WIDTH="100%" > <TR> <TD><B>Anchor Position</B> - A value from 1 to 12 defining the label's position relative to the point to which it is attached. There are four vertical alignmend modes: <i>baseline</i>, <i>center</i>, <i>top</i> and <i>bottom</i>; and three horizontal modes: <i>left</i>, <i>center</i> and <i>right</i>. See the scheme: </TD> <TD><IMG SRC="style_textanchor.gif"></TD> </TR> </TABLE> </TD> </TR> <TR> <TD ALIGN=CENTER>dx, dy</TD> <TD><B>X and Y offset</B> of the label's insertion point.<BR> Applies to text placed on a point, or at each vertex of a polyline.</TD> </TR> <TR> <TD ALIGN=CENTER>dp</TD> <TD><B>Perpendicular Offset</B> - For labels placed along a line.<BR> "dp" specifies the perpendicular distance between the label and theline along which it is placed. If the offset is negative then the label will be shifted left of the main segment and right otherwise.</TD> </TR> <TR> <TD ALIGN=CENTER>bo</TD> <TD><B>Bold</B> - <BR> If specified, then text will be bold.</TD> </TR> <TR> <TD ALIGN=CENTER>it</TD> <TD><B>Italic - </B></TD> </TR> <TR> <TD ALIGN=CENTER>un</TD> <TD><B>Underline</B> -</TD> </TR> <TR> <TD ALIGN=CENTER>l</TD>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -