自定义 MKPinAnnotation 标注气泡与默认标注气泡类似

发布于 2024-08-26 18:34:09 字数 439 浏览 3 评论 0原文

我想在 MKMapView 上创建自定义标注气泡。但我想以与默认气泡相同的方式创建标注气泡。那么如何创建一个看起来像这张图片中的注释的视图 替代文本
(来源:objectgraph.com

我想要一个自定义视图,如下图中的“停车位置”注释所示。使用自定义宽度、高度等。P

我无法在默认气泡中添加所需的详细信息。这就是为什么我要创建自定义气泡。

I want to create a custom callout bubble on MKMapView. But I want to create the call out bubble in the same manner of default bubble. So how to create a View look like annotaion in this image
alt text
(source: objectgraph.com)

I want a custom custom view which look like "Parked Location" annotaion in the following image. With custom width, height etc. P

I am not able to add required details in Default bubble. That's why am creating custom bubble.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

逆光下的微笑 2024-09-02 18:34:09

我开发了一个自定义标注气泡,它与系统标注气泡几乎相同,但在高度和内容上提供了更大的灵活性。调整外观以满足您的需要应该是相当简单的。请参阅我在异步解决方案博客 例如代码以及实现良好标注替换所需的步骤。

I have developed a custom callout bubble that is nearly identical to the system callout bubble, but gives more flexibility over the height and content. It should be fairly trivial to adjust the appearance to suit your needs. See my post on the Asynchrony Solutions blog for example code and the steps required to implement a good callout replacement.

凌乱心跳 2024-09-02 18:34:09

您需要使用 MKCircle 和 MKCircleView。

You need to use MKCircle and MKCircleView.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文