标签栏图标问题

发布于 2024-09-10 07:43:53 字数 232 浏览 3 评论 0原文

我的应用程序是一个基于选项卡栏的应用程序,我有 5 个选项卡,每个选项卡都需要自定义 图标的图像。我尝试加载每个选项卡的图像,并且它有效。问题是 我看到其中一个图标是一个灰色圆圈,而不是足球图像。这些图像中的每一个都是 在 .png 即透明中。足球艺术基本上是黑色和白色的。像任何足球一样白色,图像 加载,但我看到一个纯灰色的圆圈。我尝试从 PSD 中提取图像 几次。我不确定是否需要在界面生成器或 Photoshop 中调整图像?请帮忙。谢谢

My application is a tab bar based app, I have 5 tabs each of which requires to have a customized
image for the icon. I tried loading the image for each of the tabs, and it works. The problem is
I see a greyish circle for one of the icons, instead of a football image. Each of these images are
in .png i.e transparent. The football art is basically black & white like any football, the image
loads but I see a circle that has a solid grey color. I tried extracting the image from the PSD
several times. I am not sure if I need to tweak images in the interface builder or photoshop? please help. Thanks

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

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

发布评论

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

评论(1

晨光如昨 2024-09-17 07:43:53

工具栏和选项卡栏图标仅根据图像的 Alpha 通道创建。如果您想提供不同的灰色阴影,您的图像文件必须在 Alpha 通道中包含这些阴影(即,将像素的不透明度设置为 0% 到 100% 之间的值)。

Toolbar and tab bar icons are created just from the alpha channel of an image. If you want to provide different shades of grey, your image file must contain these shades in the alpha channel (i.e., set the opacity of the pixels to something between 0% and 100%).

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