ArcGIS Runtime SDK for iOS
100.15
|
A line symbol based on simple patterns.
Instances of this class represent simple line symbols. Symbols describe how graphics and features look on a map. Different symbols are used with different geometry types. Line symbols are used to display graphics and features which are based on polyline geometries. Simple line symbols display predefined line style patterns such as solid, dash, dot, etc.
Instance Methods | |
(id< AGSCancelable >) | - createSwatchWithBackgroundColor:screen:completion: |
(id< AGSCancelable >) | - createSwatchWithCompletion: |
(id< AGSCancelable >) | - createSwatchWithGeometry:width:height:screen:backgroundColor:completion: |
(nullable id< AGSCancelable >) | - createSwatchWithWidth:height:screen:backgroundColor:completion: |
(instancetype) | - initWithStyle:color:width: |
(instancetype) | - initWithStyle:color:width:markerStyle:markerPlacement: |
(BOOL) | - isEqualToSymbol: |
(nullable id) | - toJSON: |
(AGSMultilayerPolylineSymbol *) | - toMultilayerSymbol |
Class Methods | |
(nullable id< AGSJSONSerializable >) | + fromJSON:error: |
(instancetype) | + simpleLineSymbolWithStyle:color:width: |
(instancetype) | + simpleLineSymbolWithStyle:color:width:markerStyle:markerPlacement: |
Properties | |
BOOL | antialias |
AGSColor * | color |
AGSSimpleLineSymbolMarkerPlacement | markerPlacement |
AGSSimpleLineSymbolMarkerStyle | markerStyle |
AGSSimpleLineSymbolStyle | style |
NSDictionary< NSString *, id > * | unknownJSON |
NSDictionary< NSString *, id > * | unsupportedJSON |
CGFloat | width |
- (id<AGSCancelable>) createSwatchWithBackgroundColor: | (nullable AGSColor *) | backgroundColor | |
screen: | (nullable AGSScreen *) | screen | |
completion: | (void(^)(AGSImage *__nullable swatch, NSError *__nullable error)) | completion | |
Creates swatch with provided background color.
backgroundColor | Desired background color of the image. |
screen | Screen that the swatch will be rendered for. If you specify nil then the main screen will be used. |
completion | A block that is invoked when the operation completes. |
- (id<AGSCancelable>) createSwatchWithCompletion: | (void(^)(AGSImage *__nullable swatch, NSError *__nullable error)) | completion |
Creates a swatch with a clear background color. This method uses main screen's scale to determine the size of the image.
completion | block that is invoked when operation completes. |
- (id<AGSCancelable>) createSwatchWithGeometry: | (AGSGeometry *) | geometry | |
width: | (NSInteger) | width | |
height: | (NSInteger) | height | |
screen: | (nullable AGSScreen *) | screen | |
backgroundColor: | (nullable AGSColor *) | backgroundColor | |
completion: | (void(^)(AGSImage *__nullable swatch, NSError *__nullable error)) | completion | |
Creates a swatch using the provided geometry and other parameters. This is the most configurable of the methods to create swatches. You can pass the pixels per inch that you would like the image to be rendered at. This will determine how many pixels are used to render symbols of sizes that are specified in points.
geometry | The geometry of the symbol to be drawn in the swatch image. The specified geometry is in DIPs, with the point {0,0} located at the center of the swatch image. The X-axis increases towards the right side of the swatch image. The Y-axis increases towards the top of the swatch image. For example: when creating a swatch for an AGSMarkerSymbol , specifying a geometry of {10,10} will draw the marker 10 DIPs up and to the right of the center of the swatch. The geometry type (AGSPoint , AGSPolyline , AGSPolygon ) should correspond to the symbol type (AGSMarkerSymbol , AGSLineSymbol , AGSFillSymbol ). The geometry's spatial reference is ignored. |
width | Desired width of the image in pixels. |
height | Desired height of the image in pixels. |
screen | The screen that the swatch will be rendered for. If you specify nil then the main screen will be used. |
backgroundColor | The desired background color of the image. |
completion | A block that is invoked when operation completes. |
- (nullable id<AGSCancelable>) createSwatchWithWidth: | (NSInteger) | width | |
height: | (NSInteger) | height | |
screen: | (nullable AGSScreen *) | screen | |
backgroundColor: | (nullable AGSColor *) | backgroundColor | |
completion: | (void(^)(AGSImage *__nullable swatch, NSError *__nullable error)) | completion | |
|
staticrequiredinherited |
Initializes and returns an object from its JSON representation.
JSONObject | NSDictionary or NSArray containing the JSON. |
error | encountered during the operation, if any. |
- (instancetype) initWithStyle: | (AGSSimpleLineSymbolStyle) | style | |
color: | (AGSColor *) | color | |
width: | (CGFloat) | width | |
Initialize a simple line symbol with the provided parameters
style | of the line |
color | of the line |
width | of the line in points (not pixels) |
- (instancetype) initWithStyle: | (AGSSimpleLineSymbolStyle) | style | |
color: | (AGSColor *) | color | |
width: | (CGFloat) | width | |
markerStyle: | (AGSSimpleLineSymbolMarkerStyle) | markerStyle | |
markerPlacement: | (AGSSimpleLineSymbolMarkerPlacement) | markerPlacement | |
Initialize a simple line symbol with the provided parameters
style | of the line |
color | of the line |
width | of the line in points (not pixels) |
markerStyle | specifying the type of markers for the line |
markerPlacement | specifying the placement of markers for the line endings |
- (BOOL) isEqualToSymbol: | (AGSSymbol *) | other |
Compares this symbol to another for equality.
other | The other symbol to compare this one to. |
YES
if the two symbols are equal, otherwise NO
. + (instancetype) simpleLineSymbolWithStyle: | (AGSSimpleLineSymbolStyle) | style | |
color: | (AGSColor *) | color | |
width: | (CGFloat) | width | |
Initialize a simple line symbol with the provided parameters
style | of the line |
color | of the line |
width | of the line in points (not pixels) |
+ (instancetype) simpleLineSymbolWithStyle: | (AGSSimpleLineSymbolStyle) | style | |
color: | (AGSColor *) | color | |
width: | (CGFloat) | width | |
markerStyle: | (AGSSimpleLineSymbolMarkerStyle) | markerStyle | |
markerPlacement: | (AGSSimpleLineSymbolMarkerPlacement) | markerPlacement | |
Initialize a simple line symbol with the provided parameters
style | of the line |
color | of the line |
width | of the line in points (not pixels) |
markerStyle | specifying the type of markers for the line endings |
markerPlacement | specifying the placement of markers for the line endings |
|
requiredinherited |
Returns JSON representation for this object.
error | encountered during the operation, if any. |
NSDictionary
or NSArray
containing the JSON. Reimplemented in AGSPortalItem.
- (AGSMultilayerPolylineSymbol *) toMultilayerSymbol |
Returns the multilayer polyline symbol generated from simple line symbol. The resulting symbol contains a single AGSSolidStrokeSymbolLayer
to represent the line symbol. An effect is applied to the symbol if a dash pattern is used.
|
readwritenonatomicassigninherited |
Whether the line should be anti-aliased. Defaults to true.
|
readwritenonatomicstronginherited |
The color for the line symbol.
When getting the color (or tint color) from a symbol, the consensus value (for all layers) is reported. If there is no consensus (one or more layers have different colors), a nil
value is reported for the color. Likewise, setting a value for color on a symbol will apply that color to all layers the symbol contains.
If you don't want changes to the symbol color to propagate to some of the symbol layers it contains, you can lock the color (or tint color) for those layers. If a symbol layer is color-locked, changes to the parent symbol will not affect the symbol layer. This also means that the layer will not be considered when determining a consensus color for the symbol as a whole.
|
readwritenonatomicassign |
The placement of markers on the line endings
|
readwritenonatomicassign |
The style of markers on the line endings
|
readwritenonatomicassign |
The line style
|
readrequirednonatomiccopyinherited |
A dictionary of values that was in the source JSON but was unparsed by API.
NSDictionary
containing the unknown JSON.
|
readnonatomiccopyinherited |
A dictionary of values that are supported by the REST API, but not exposed through the SDK API.
NSDictionary
containing the unsupported JSON.
|
readwritenonatomicassigninherited |
Width of the line, in points (not pixels)