LWUIT:图像作为表单背景

发布于 2024-11-26 10:18:02 字数 107 浏览 0 评论 0原文

我已经开始使用 LWUIT,这听起来很有趣,我制作了一个表单并简单地在其背景中添加了一个图像,我的问题是图像被拉伸并且看起来很糟糕:D 有没有办法设置图像不让 strtshd 在表单或任何其他组件上?

I have started using LWUIT which sounds interesting , i have made a form and has simply added an image to its background , my problem is that the image is getting streched and looks bad :D
is there any way to set an image not to get stretshd on a form or any other component ?

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

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

发布评论

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

评论(1

冷默言语 2024-12-03 10:18:02

这取决于您使用的 LWUIT 版本。在1.4中,您可以将样式中的bgType定义为BACKGROUND_IMAGE_ALIGNED,然后将bgAlign值定义为您想要的任何值(有许多类型/对齐方式)。

最新的 SVN 和即将推出的 1.5 通过删除 bgAlign 并将所有对齐/平铺可能性添加到 bgType 来简化此操作,例如 BACKGROUND_IMAGE_TILE_VERTICAL_ALIGN_RIGHTBACKGROUND_IMAGE_ALIGNED_TOP_LEFT 等...

您可以直观地编辑所有这些在资源编辑器中使用主题。

This depends on the version of LWUIT you are using. In 1.4 you could define bgType in the Style to be BACKGROUND_IMAGE_ALIGNED and then define the bgAlign value to whatever you want (there are many types/alignments).

The latest SVN and upcoming 1.5 simplifies this by removing bgAlign and adding to bgType all the alignment/tiling possibilities e.g. BACKGROUND_IMAGE_TILE_VERTICAL_ALIGN_RIGHT or BACKGROUND_IMAGE_ALIGNED_TOP_LEFT etc...

You can edit all of these visually in the resource editor using the theme.

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