Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在mapkit标注中,我们可以为标注的左右配件添加图像。
mapkit
在IOS7中,如果这些附件是按钮,则似乎预期的格式与 for toolbarortab bar按钮相同。IOS6下图显示了和之间的区别IOS7。
IOS7
toolbar
tab bar
IOS6
图片链接
有谁知道如何保持相同的行为IOS7?
更改按钮类型无济于事:
例如,UIButtonTypeCustom根本不显示图像。
UIButtonTypeCustom
在 IOS 7 中,您必须使用新例程将图像重新渲染为原始图像,否则它只会将其用作模板,为您提供蓝色斑点,如您在图片中看到的那样……这是调用。
image = [image imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];