在Eclipse为Android定制GUI组件 [英] Customized GUI components for Android in eclipse
问题描述
您知道如何在Eclipse中你可以使用编辑XML文件的内置的Eclipse GUI添加GUI组件?我期待创建自己的组件,我可以添加这样我可以拖放像其他组件。我找了一个教程不得要领,无法找到任何东西。有谁知道如何做到这一点?
You know how in eclipse you can edit the XML file using the built-in eclipse GUI for adding GUI components? I'm looking to create my own component that I can add so I can drag and drop like the rest of the components. I've looked for a tutorial to no avail and couldn't find anything. Does anyone know how to do this?
提醒你,我正在使用Java。
Mind you I am using Java.
推荐答案
您可以通过创建一个扩展的ViewGroup或组件类创建自定义布局或组件。要创建
You can create custom layout or component by creating a class that extends ViewGroup or the component (Ex: Button) that you want to create.
这将在XML的图形布局视图中显示选项卡下的自定义和库视图自定义组件。
This will display your custom component under "Custom and Library Views" tab in graphical layout view of the xml.
这篇关于在Eclipse为Android定制GUI组件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!