| 1 | // This file is generated. Do not edit. |
| 2 | |
| 3 | #pragma once |
| 4 | |
| 5 | #include <mbgl/style/layer.hpp> |
| 6 | #include <mbgl/style/filter.hpp> |
| 7 | #include <mbgl/style/property_value.hpp> |
| 8 | #include <mbgl/style/data_driven_property_value.hpp> |
| 9 | |
| 10 | #include <mbgl/util/color.hpp> |
| 11 | |
| 12 | #include <vector> |
| 13 | |
| 14 | namespace mbgl { |
| 15 | namespace style { |
| 16 | |
| 17 | class TransitionOptions; |
| 18 | |
| 19 | class SymbolLayer : public Layer { |
| 20 | public: |
| 21 | SymbolLayer(const std::string& layerID, const std::string& sourceID); |
| 22 | ~SymbolLayer() final; |
| 23 | |
| 24 | // Source |
| 25 | const std::string& getSourceID() const; |
| 26 | const std::string& getSourceLayer() const; |
| 27 | void setSourceLayer(const std::string& sourceLayer); |
| 28 | |
| 29 | void setFilter(const Filter&); |
| 30 | const Filter& getFilter() const; |
| 31 | |
| 32 | // Visibility |
| 33 | void setVisibility(VisibilityType) final; |
| 34 | |
| 35 | // Zoom range |
| 36 | void setMinZoom(float) final; |
| 37 | void setMaxZoom(float) final; |
| 38 | |
| 39 | // Layout properties |
| 40 | |
| 41 | static PropertyValue<SymbolPlacementType> getDefaultSymbolPlacement(); |
| 42 | PropertyValue<SymbolPlacementType> getSymbolPlacement() const; |
| 43 | void setSymbolPlacement(PropertyValue<SymbolPlacementType>); |
| 44 | |
| 45 | static PropertyValue<float> getDefaultSymbolSpacing(); |
| 46 | PropertyValue<float> getSymbolSpacing() const; |
| 47 | void setSymbolSpacing(PropertyValue<float>); |
| 48 | |
| 49 | static PropertyValue<bool> getDefaultSymbolAvoidEdges(); |
| 50 | PropertyValue<bool> getSymbolAvoidEdges() const; |
| 51 | void setSymbolAvoidEdges(PropertyValue<bool>); |
| 52 | |
| 53 | static PropertyValue<bool> getDefaultIconAllowOverlap(); |
| 54 | PropertyValue<bool> getIconAllowOverlap() const; |
| 55 | void setIconAllowOverlap(PropertyValue<bool>); |
| 56 | |
| 57 | static PropertyValue<bool> getDefaultIconIgnorePlacement(); |
| 58 | PropertyValue<bool> getIconIgnorePlacement() const; |
| 59 | void setIconIgnorePlacement(PropertyValue<bool>); |
| 60 | |
| 61 | static PropertyValue<bool> getDefaultIconOptional(); |
| 62 | PropertyValue<bool> getIconOptional() const; |
| 63 | void setIconOptional(PropertyValue<bool>); |
| 64 | |
| 65 | static PropertyValue<AlignmentType> getDefaultIconRotationAlignment(); |
| 66 | PropertyValue<AlignmentType> getIconRotationAlignment() const; |
| 67 | void setIconRotationAlignment(PropertyValue<AlignmentType>); |
| 68 | |
| 69 | static DataDrivenPropertyValue<float> getDefaultIconSize(); |
| 70 | DataDrivenPropertyValue<float> getIconSize() const; |
| 71 | void setIconSize(DataDrivenPropertyValue<float>); |
| 72 | |
| 73 | static PropertyValue<IconTextFitType> getDefaultIconTextFit(); |
| 74 | PropertyValue<IconTextFitType> getIconTextFit() const; |
| 75 | void setIconTextFit(PropertyValue<IconTextFitType>); |
| 76 | |
| 77 | static PropertyValue<std::array<float, 4>> getDefaultIconTextFitPadding(); |
| 78 | PropertyValue<std::array<float, 4>> getIconTextFitPadding() const; |
| 79 | void setIconTextFitPadding(PropertyValue<std::array<float, 4>>); |
| 80 | |
| 81 | static DataDrivenPropertyValue<std::string> getDefaultIconImage(); |
| 82 | DataDrivenPropertyValue<std::string> getIconImage() const; |
| 83 | void setIconImage(DataDrivenPropertyValue<std::string>); |
| 84 | |
| 85 | static DataDrivenPropertyValue<float> getDefaultIconRotate(); |
| 86 | DataDrivenPropertyValue<float> getIconRotate() const; |
| 87 | void setIconRotate(DataDrivenPropertyValue<float>); |
| 88 | |
| 89 | static PropertyValue<float> getDefaultIconPadding(); |
| 90 | PropertyValue<float> getIconPadding() const; |
| 91 | void setIconPadding(PropertyValue<float>); |
| 92 | |
| 93 | static PropertyValue<bool> getDefaultIconKeepUpright(); |
| 94 | PropertyValue<bool> getIconKeepUpright() const; |
| 95 | void setIconKeepUpright(PropertyValue<bool>); |
| 96 | |
| 97 | static DataDrivenPropertyValue<std::array<float, 2>> getDefaultIconOffset(); |
| 98 | DataDrivenPropertyValue<std::array<float, 2>> getIconOffset() const; |
| 99 | void setIconOffset(DataDrivenPropertyValue<std::array<float, 2>>); |
| 100 | |
| 101 | static DataDrivenPropertyValue<SymbolAnchorType> getDefaultIconAnchor(); |
| 102 | DataDrivenPropertyValue<SymbolAnchorType> getIconAnchor() const; |
| 103 | void setIconAnchor(DataDrivenPropertyValue<SymbolAnchorType>); |
| 104 | |
| 105 | static PropertyValue<AlignmentType> getDefaultIconPitchAlignment(); |
| 106 | PropertyValue<AlignmentType> getIconPitchAlignment() const; |
| 107 | void setIconPitchAlignment(PropertyValue<AlignmentType>); |
| 108 | |
| 109 | static PropertyValue<AlignmentType> getDefaultTextPitchAlignment(); |
| 110 | PropertyValue<AlignmentType> getTextPitchAlignment() const; |
| 111 | void setTextPitchAlignment(PropertyValue<AlignmentType>); |
| 112 | |
| 113 | static PropertyValue<AlignmentType> getDefaultTextRotationAlignment(); |
| 114 | PropertyValue<AlignmentType> getTextRotationAlignment() const; |
| 115 | void setTextRotationAlignment(PropertyValue<AlignmentType>); |
| 116 | |
| 117 | static DataDrivenPropertyValue<std::string> getDefaultTextField(); |
| 118 | DataDrivenPropertyValue<std::string> getTextField() const; |
| 119 | void setTextField(DataDrivenPropertyValue<std::string>); |
| 120 | |
| 121 | static DataDrivenPropertyValue<std::vector<std::string>> getDefaultTextFont(); |
| 122 | DataDrivenPropertyValue<std::vector<std::string>> getTextFont() const; |
| 123 | void setTextFont(DataDrivenPropertyValue<std::vector<std::string>>); |
| 124 | |
| 125 | static DataDrivenPropertyValue<float> getDefaultTextSize(); |
| 126 | DataDrivenPropertyValue<float> getTextSize() const; |
| 127 | void setTextSize(DataDrivenPropertyValue<float>); |
| 128 | |
| 129 | static DataDrivenPropertyValue<float> getDefaultTextMaxWidth(); |
| 130 | DataDrivenPropertyValue<float> getTextMaxWidth() const; |
| 131 | void setTextMaxWidth(DataDrivenPropertyValue<float>); |
| 132 | |
| 133 | static PropertyValue<float> getDefaultTextLineHeight(); |
| 134 | PropertyValue<float> getTextLineHeight() const; |
| 135 | void setTextLineHeight(PropertyValue<float>); |
| 136 | |
| 137 | static DataDrivenPropertyValue<float> getDefaultTextLetterSpacing(); |
| 138 | DataDrivenPropertyValue<float> getTextLetterSpacing() const; |
| 139 | void setTextLetterSpacing(DataDrivenPropertyValue<float>); |
| 140 | |
| 141 | static DataDrivenPropertyValue<TextJustifyType> getDefaultTextJustify(); |
| 142 | DataDrivenPropertyValue<TextJustifyType> getTextJustify() const; |
| 143 | void setTextJustify(DataDrivenPropertyValue<TextJustifyType>); |
| 144 | |
| 145 | static DataDrivenPropertyValue<SymbolAnchorType> getDefaultTextAnchor(); |
| 146 | DataDrivenPropertyValue<SymbolAnchorType> getTextAnchor() const; |
| 147 | void setTextAnchor(DataDrivenPropertyValue<SymbolAnchorType>); |
| 148 | |
| 149 | static PropertyValue<float> getDefaultTextMaxAngle(); |
| 150 | PropertyValue<float> getTextMaxAngle() const; |
| 151 | void setTextMaxAngle(PropertyValue<float>); |
| 152 | |
| 153 | static DataDrivenPropertyValue<float> getDefaultTextRotate(); |
| 154 | DataDrivenPropertyValue<float> getTextRotate() const; |
| 155 | void setTextRotate(DataDrivenPropertyValue<float>); |
| 156 | |
| 157 | static PropertyValue<float> getDefaultTextPadding(); |
| 158 | PropertyValue<float> getTextPadding() const; |
| 159 | void setTextPadding(PropertyValue<float>); |
| 160 | |
| 161 | static PropertyValue<bool> getDefaultTextKeepUpright(); |
| 162 | PropertyValue<bool> getTextKeepUpright() const; |
| 163 | void setTextKeepUpright(PropertyValue<bool>); |
| 164 | |
| 165 | static DataDrivenPropertyValue<TextTransformType> getDefaultTextTransform(); |
| 166 | DataDrivenPropertyValue<TextTransformType> getTextTransform() const; |
| 167 | void setTextTransform(DataDrivenPropertyValue<TextTransformType>); |
| 168 | |
| 169 | static DataDrivenPropertyValue<std::array<float, 2>> getDefaultTextOffset(); |
| 170 | DataDrivenPropertyValue<std::array<float, 2>> getTextOffset() const; |
| 171 | void setTextOffset(DataDrivenPropertyValue<std::array<float, 2>>); |
| 172 | |
| 173 | static PropertyValue<bool> getDefaultTextAllowOverlap(); |
| 174 | PropertyValue<bool> getTextAllowOverlap() const; |
| 175 | void setTextAllowOverlap(PropertyValue<bool>); |
| 176 | |
| 177 | static PropertyValue<bool> getDefaultTextIgnorePlacement(); |
| 178 | PropertyValue<bool> getTextIgnorePlacement() const; |
| 179 | void setTextIgnorePlacement(PropertyValue<bool>); |
| 180 | |
| 181 | static PropertyValue<bool> getDefaultTextOptional(); |
| 182 | PropertyValue<bool> getTextOptional() const; |
| 183 | void setTextOptional(PropertyValue<bool>); |
| 184 | |
| 185 | // Paint properties |
| 186 | |
| 187 | static DataDrivenPropertyValue<float> getDefaultIconOpacity(); |
| 188 | DataDrivenPropertyValue<float> getIconOpacity() const; |
| 189 | void setIconOpacity(DataDrivenPropertyValue<float>); |
| 190 | void setIconOpacityTransition(const TransitionOptions&); |
| 191 | TransitionOptions getIconOpacityTransition() const; |
| 192 | |
| 193 | static DataDrivenPropertyValue<Color> getDefaultIconColor(); |
| 194 | DataDrivenPropertyValue<Color> getIconColor() const; |
| 195 | void setIconColor(DataDrivenPropertyValue<Color>); |
| 196 | void setIconColorTransition(const TransitionOptions&); |
| 197 | TransitionOptions getIconColorTransition() const; |
| 198 | |
| 199 | static DataDrivenPropertyValue<Color> getDefaultIconHaloColor(); |
| 200 | DataDrivenPropertyValue<Color> getIconHaloColor() const; |
| 201 | void setIconHaloColor(DataDrivenPropertyValue<Color>); |
| 202 | void setIconHaloColorTransition(const TransitionOptions&); |
| 203 | TransitionOptions getIconHaloColorTransition() const; |
| 204 | |
| 205 | static DataDrivenPropertyValue<float> getDefaultIconHaloWidth(); |
| 206 | DataDrivenPropertyValue<float> getIconHaloWidth() const; |
| 207 | void setIconHaloWidth(DataDrivenPropertyValue<float>); |
| 208 | void setIconHaloWidthTransition(const TransitionOptions&); |
| 209 | TransitionOptions getIconHaloWidthTransition() const; |
| 210 | |
| 211 | static DataDrivenPropertyValue<float> getDefaultIconHaloBlur(); |
| 212 | DataDrivenPropertyValue<float> getIconHaloBlur() const; |
| 213 | void setIconHaloBlur(DataDrivenPropertyValue<float>); |
| 214 | void setIconHaloBlurTransition(const TransitionOptions&); |
| 215 | TransitionOptions getIconHaloBlurTransition() const; |
| 216 | |
| 217 | static PropertyValue<std::array<float, 2>> getDefaultIconTranslate(); |
| 218 | PropertyValue<std::array<float, 2>> getIconTranslate() const; |
| 219 | void setIconTranslate(PropertyValue<std::array<float, 2>>); |
| 220 | void setIconTranslateTransition(const TransitionOptions&); |
| 221 | TransitionOptions getIconTranslateTransition() const; |
| 222 | |
| 223 | static PropertyValue<TranslateAnchorType> getDefaultIconTranslateAnchor(); |
| 224 | PropertyValue<TranslateAnchorType> getIconTranslateAnchor() const; |
| 225 | void setIconTranslateAnchor(PropertyValue<TranslateAnchorType>); |
| 226 | void setIconTranslateAnchorTransition(const TransitionOptions&); |
| 227 | TransitionOptions getIconTranslateAnchorTransition() const; |
| 228 | |
| 229 | static DataDrivenPropertyValue<float> getDefaultTextOpacity(); |
| 230 | DataDrivenPropertyValue<float> getTextOpacity() const; |
| 231 | void setTextOpacity(DataDrivenPropertyValue<float>); |
| 232 | void setTextOpacityTransition(const TransitionOptions&); |
| 233 | TransitionOptions getTextOpacityTransition() const; |
| 234 | |
| 235 | static DataDrivenPropertyValue<Color> getDefaultTextColor(); |
| 236 | DataDrivenPropertyValue<Color> getTextColor() const; |
| 237 | void setTextColor(DataDrivenPropertyValue<Color>); |
| 238 | void setTextColorTransition(const TransitionOptions&); |
| 239 | TransitionOptions getTextColorTransition() const; |
| 240 | |
| 241 | static DataDrivenPropertyValue<Color> getDefaultTextHaloColor(); |
| 242 | DataDrivenPropertyValue<Color> getTextHaloColor() const; |
| 243 | void setTextHaloColor(DataDrivenPropertyValue<Color>); |
| 244 | void setTextHaloColorTransition(const TransitionOptions&); |
| 245 | TransitionOptions getTextHaloColorTransition() const; |
| 246 | |
| 247 | static DataDrivenPropertyValue<float> getDefaultTextHaloWidth(); |
| 248 | DataDrivenPropertyValue<float> getTextHaloWidth() const; |
| 249 | void setTextHaloWidth(DataDrivenPropertyValue<float>); |
| 250 | void setTextHaloWidthTransition(const TransitionOptions&); |
| 251 | TransitionOptions getTextHaloWidthTransition() const; |
| 252 | |
| 253 | static DataDrivenPropertyValue<float> getDefaultTextHaloBlur(); |
| 254 | DataDrivenPropertyValue<float> getTextHaloBlur() const; |
| 255 | void setTextHaloBlur(DataDrivenPropertyValue<float>); |
| 256 | void setTextHaloBlurTransition(const TransitionOptions&); |
| 257 | TransitionOptions getTextHaloBlurTransition() const; |
| 258 | |
| 259 | static PropertyValue<std::array<float, 2>> getDefaultTextTranslate(); |
| 260 | PropertyValue<std::array<float, 2>> getTextTranslate() const; |
| 261 | void setTextTranslate(PropertyValue<std::array<float, 2>>); |
| 262 | void setTextTranslateTransition(const TransitionOptions&); |
| 263 | TransitionOptions getTextTranslateTransition() const; |
| 264 | |
| 265 | static PropertyValue<TranslateAnchorType> getDefaultTextTranslateAnchor(); |
| 266 | PropertyValue<TranslateAnchorType> getTextTranslateAnchor() const; |
| 267 | void setTextTranslateAnchor(PropertyValue<TranslateAnchorType>); |
| 268 | void setTextTranslateAnchorTransition(const TransitionOptions&); |
| 269 | TransitionOptions getTextTranslateAnchorTransition() const; |
| 270 | |
| 271 | // Private implementation |
| 272 | |
| 273 | class Impl; |
| 274 | const Impl& impl() const; |
| 275 | |
| 276 | Mutable<Impl> mutableImpl() const; |
| 277 | SymbolLayer(Immutable<Impl>); |
| 278 | std::unique_ptr<Layer> cloneRef(const std::string& id) const final; |
| 279 | }; |
| 280 | |
| 281 | template <> |
| 282 | inline bool Layer::is<SymbolLayer>() const { |
| 283 | return getType() == LayerType::Symbol; |
| 284 | } |
| 285 | |
| 286 | } // namespace style |
| 287 | } // namespace mbgl |
| 288 | |