TencentMapSDK_iOS_3D_v6.7.0

QMarkerView.h
1 //
2 // QMarkerView.h
3 // QMapKit
4 //
5 // Created by Keith Cao on 2024/1/29.
6 // Copyright © 2024 tencent. All rights reserved.
7 //
8
9 #import <UIKit/UIKit.h>
10 #import "QMarker.h"
11 #import "QOverlayView.h"
12 #import "QMarkerViewDefines.h"
13 #import "QMarkerViewAnimationLayer.h"
14
15 NS_ASSUME_NONNULL_BEGIN
16
17
19 @interface QMarkerView : QOverlayView
20
25 - (instancetype)initWithMarker:(QMarker *)marker;
26
30 @property (nonatomic, assign) BOOL isHidden;
31
37 @property (nonatomic, assign) CGPoint centerOffset;
38
42 @property (nonatomic, assign) CGFloat alpha;
43
49 @property (nonatomic, assign) CGPoint scale;
50
54 @property (nonatomic, assign) CGFloat rotation;
55
59 @property (nonatomic, nullable, copy) NSString *title;
60
64 @property (nonatomic, nullable, copy) NSString *subtitle;
65
69 @property (nonatomic, assign) BOOL userInteractionEnabled;
70
74 @property (nonatomic, assign) BOOL draggable;
75
80 @property (nonatomic, nullable, strong) UIImage *image;
81
85 @property (nonatomic, assign) QMarkerViewCollisionType collisionType;
86
90 @property (nonatomic, assign) QMarkerViewDragState dragState;
91
95 @property (nonatomic, assign) BOOL canshowCallout;
96
100 @property (nonatomic, strong, nullable) UIView *customCalloutView;
101
104 - (void)updateCenterCoordinate:(CLLocationCoordinate2D)location;
105
108 - (void)showCalloutView:(BOOL)toShow;
109
110
112 - (void)refreshCalloutView;
113
117 @property (nonatomic, strong, readonly) QMarkerViewAnimationLayer *animationLayer;
118
119 @end
120
121 NS_ASSUME_NONNULL_END
QMarkerView::image
UIImage * image
marker 的图标 图标最大尺寸限制为 1024 * 1024像素，超出时按等比例缩小至有效尺寸内
Definition: QMarkerView.h:80
QMarkerView::collisionType
QMarkerViewCollisionType collisionType
QMarkerView的碰撞类型
Definition: QMarkerView.h:85
QMarkerView::dragState
QMarkerViewDragState dragState
QMarkerView的拖动状态
Definition: QMarkerView.h:90
QMarkerView::title
NSString * title
marker 的标题
Definition: QMarkerView.h:59
QMarkerView::draggable
BOOL draggable
覆盖物拖拽开关, 默认: NO
Definition: QMarkerView.h:74
QMarkerView::alpha
CGFloat alpha
marker 的透明度, 取值范围[0,1] 默认：1
Definition: QMarkerView.h:42
QMarkerView::userInteractionEnabled
BOOL userInteractionEnabled
覆盖物交互开关, 默认: YES
Definition: QMarkerView.h:69
QMarkerView::customCalloutView
UIView * customCalloutView
自定义UIView类型的callout, 赋值后，优先展示
Definition: QMarkerView.h:100
QMarkerViewAnimationLayer
Definition: QMarkerViewAnimationLayer.h:35
QMarkerView::rotation
CGFloat rotation
marker 的旋转角度值, 默认：0
Definition: QMarkerView.h:54
QMarker
标记覆盖物.
Definition: QMarker.h:23
QMarkerView::subtitle
NSString * subtitle
marker 的副标题
Definition: QMarkerView.h:64
QMarkerView::centerOffset
CGPoint centerOffset
marker 的锚点, 根据marker图片的宽高进行等比例平移，默认值[0.5, 0.5] x 左右平移比例, 取值范围 [0, 1] y 上下平移比例, 取值范围 [0,...
Definition: QMarkerView.h:37
QMarkerView
此类是QMarker用于显示标记覆盖物的view
Definition: QMarkerView.h:20
QMarkerView::scale
CGPoint scale
marker 的缩放比例值, 默认：[1,1] x 表示 宽度比例, 有效值>=0 y 表示 高度比例, 有效值>=0
Definition: QMarkerView.h:49
QOverlayView
该类是地图覆盖物View的基类, 提供了绘制overlay的接口, 但是没有实际实现。希望不要直接实例化
Definition: QOverlayView.h:17
QMarkerView::canshowCallout
BOOL canshowCallout
是否允许展示callout, 默认值 NO
Definition: QMarkerView.h:95
QMarkerView::isHidden
BOOL isHidden
marker 是否可见, 默认: NO
Definition: QMarkerView.h:30
-[QMarkerView refreshCalloutView]
void refreshCalloutView()
刷新callout
QMarkerView::animationLayer
QMarkerViewAnimationLayer * animationLayer
QMarkerView的动画layer
Definition: QMarkerView.h:117