开发者

iOS: Alert-View with RTF (Bold, URLs etc)

开发者 https://www.devze.com 2023-03-21 16:19 出处:网络
I need to display a message to the user. However, it is quite a long message.Really to be clear I need to split it into paragraphs and use Bold for headings.Also I need to supply a web link for \'mor

I need to display a message to the user.

However, it is quite a long message. Really to be clear I need to split it into paragraphs and use Bold for headings. Also I need to supply a web link for 'more information'.

What is my best solution path?

All I can think of at the moment is to create an analogue of a UIAlertView that uses a UIWebView + a UIButton

And the web view loads an RTF file from the bundle.

If I create this inside a full-screen view set to 50% Alpha, it will fade out whatever window is behind... b开发者_高级运维ut I would rather not code up my own component if there is something already available.


You are on the right track. Create a UIViewController with a UIView, UIWebView and UIButton(s) to present the transparent view. You may be able to use UIPopoverController.

The web view content will need to also set a transparent background.

0

精彩评论

暂无评论...
验证码 换一张
取 消