如何在我的应用程序中添加超链接?

发布于 2024-08-19 06:58:51 字数 276 浏览 1 评论 0原文

我尝试了多种方法:

  • UIWebView 不起作用,因为我有纹理背景,而 UIWebView 不做透明背景。
  • UITextView - 似乎是一个非常好的选择。我已经让它自动检测我的超链接,但它用蓝色覆盖我的链接颜色。 :(
  • 我看过 Three20 代码 - 这看起来过于复杂。

我在想,有没有办法让 UIButton 看起来像文本?这可能是完美的。

这真的很烦人,似乎几乎每个应用程序都这样做这个,但我不知道它是如何完成的。

I've tried a number of methods:

  • A UIWebView doesn't do the trick because I've got a textured background, and the UIWebView doesn't do transparent backgrounds.
  • A UITextView - seems like a really good option. I've got it auto detecting my hyperlink, but it overrides my link colour with blue. :(
  • I've looked at the Three20 code - this looks overly complex.

I was thinking, is there a way to make a UIButton look like text? This'd probably be perfect.

This is really annoying, seems that almost every app does this, yet I can't find out how it's done.

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

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

发布评论

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

评论(1

旧街凉风 2024-08-26 06:58:51

UIWebView 确实允许透明背景。

我在我的应用程序 Pocket Tabs 中使用它。

webView.opaque = NO;
webView.backgroundColor = [UIColor clearColor];

UIWebView does allow transparent backgrounds.

I use this in my app, Pocket Tabs.

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