addCaption method
Caption?
addCaption({
- required String caption,
- double strokeWidth = 2.0,
- int strokeColor = 0xffffffff,
- int fillColor = 0xff000000,
- double fontSize = 10.0,
- int minZoomLevel = 0,
- int maxZoomLevel = 65535,
- Position position = Position.BELOW,
- double dy = 0,
- int strokeMinZoomLevel = DisplayModel.STROKE_MIN_ZOOMLEVEL_TEXT,
- required DisplayModel displayModel,
Implementation
Caption? addCaption({
required String caption,
double strokeWidth = 2.0,
int strokeColor = 0xffffffff,
int fillColor = 0xff000000,
double fontSize = 10.0,
int minZoomLevel = 0,
int maxZoomLevel = 65535,
Position position = Position.BELOW,
double dy = 0,
int strokeMinZoomLevel = DisplayModel.STROKE_MIN_ZOOMLEVEL_TEXT,
required DisplayModel displayModel,
}) {
if (caption.isEmpty) return null;
Caption cp = Caption(
caption: caption,
strokeWidth: strokeWidth,
strokeColor: strokeColor,
fillColor: fillColor,
fontSize: fontSize,
minZoomLevel: minZoomLevel,
maxZoomLevel: maxZoomLevel,
position: position,
dy: dy,
strokeMinZoomLevel: strokeMinZoomLevel,
displayModel: displayModel,
symbolFinder: symbolFinder);
_captions.add(cp);
return cp;
}