使用 XML 定义 SmartGWT UI

发布于 2024-09-03 21:34:51 字数 537 浏览 9 评论 0原文

我在 SmartGWT 小部件上使用 UIBinder 相当成功。 但是,我必须扩展我使用的每个 SmartGWT 小部件以满足 UIBinder 的要求。有时,我必须将 SmartGWT 小部件伪装成 com.google.gwt 命名空间,或者将非 GWT 小部件伪装成 GWT 小部件。我根据需要扩展小部件。

所以,我开始怀疑,也许 SmartGWT 已经有了 UI XML 格式,而我可能正在做所有这些 UIBinder 适应工作,只是为了重新发明 SmartGWT 的轮子。

我已经阅读并重读了展示的源代码,并深入研究了一些 SmartGWT 源代码,并阅读了 javadocs。

我发现的只是用于服务器和客户端之间通信的 XML 或 Json。

是否有任何可用于 SmartGWT 的 UI def XML,无论是 gwt 编译为客户端 javascript 还是像 Vaadin 的服务器端生成的 UIDL?

如果您碰巧是同构代理,您能否告诉我们是否有任何计划让 SmartGWT 与 UIBinder 一起使用(以防止我必须再自己处理 SmartGWT 小部件)?

I have been using UIBinder on SmartGWT widgets rather successfully.
However, I have to extend each SmartGWT widget that I use to comply with UIBinder's requirement. Occasionally, I have to masquerade a SmartGWT widget into com.google.gwt namespace, or masquerade a non-GWT-widget as a GWT widget. I extend widgets on as-needed basis.

So, I am starting to wonder, may be SmartGWT already has a UI XML format and I might be doing all this UIBinder acclimatization just to reinvent SmartGWT's wheel.

I have read and reread source codes of the showcase and delved into some of the SmartGWT source code, as well as reading the javadocs.

All I found is XML or Json for communication between server and client.

Is there any UI def XML available for SmartGWT whether gwt-compiled to client-side javascript or like Vaadin's server-side generated UIDL?

And if you happen to be an Isomorphic agent, could you tell us if there are any plans to let SmartGWT play with UIBinder (to preclude me from having to massage SmartGWT widgets on my own anymore)?

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

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

发布评论

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

评论(2

我爱人 2024-09-10 21:34:51

是的,有一个 SmartGWT XML 组件定义 - Visual Builder 和 Reify 使用的定义,您也可以直接编写它。请参阅这些文档和此常见问题解答项目:

http: //www.smartclient.com/smartgwtee-latest/javadoc/com/smartgwt/client/docs/ComponentXML.html
http://forums.smartclient.com/showthread.php?t=8159# loadVBScreen

正如常见问题解答所阐明的那样,我们建议在一组与 UIBinder 用途严重重叠的用例中使用此 XML 格式,即,将布局和基本组件定义保持为设计人员可以编辑和编辑的声明性格式。它可以通过可视化工具进行编辑,并将实际的 Java 事件处理和其他编程代码分开。

然而,我们强烈建议不要将声明性格式设置为 HTML(正如 UIBinder 所做的那样),因为这会引入很多跨浏览器布局问题。

我们很可能最终也会支持 UIBinder,因为它与我们自己的 XML 格式并不多余。如果您需要更快地实现这一目标,请考虑功能赞助:

http://www.smartclient。 com/services/index.jsp#features

Yes, there is a SmartGWT XML component definition - the one used by Visual Builder and Reify, and which you can also write directly. See these docs and this FAQ item:

http://www.smartclient.com/smartgwtee-latest/javadoc/com/smartgwt/client/docs/ComponentXML.html
http://forums.smartclient.com/showthread.php?t=8159#loadVBScreen

As the FAQ clarifies, we recommend using this XML format for a set of use cases that heavily overlaps with what UIBinder is for, that is, keeping your layout and basic component definitions in a declarative format that designers can edit and which can be edited by visual tools, and having your actual Java event handling and other programmatic code separate.

However we strongly recommend against having that declarative format be HTML (as UIBinder does it) because that introduces lots and lots of cross-browser layout issues.

We are likely to eventually support UIBinder as well for the few use cases where it is not redundant with our own XML format. If you need that to happen sooner, consider Feature Sponsorship:

http://www.smartclient.com/services/index.jsp#features

妄断弥空 2024-09-10 21:34:51

对于 XML smartclient 有 componentxml,它是基于 XML 的 ui 设计并使用 JavaScript 来具有客户端逻辑。您无需每次在开发环境中编译您的应用程序,只需重新加载浏览器即可包含更改,您可以对其进行测试。

For XML smartclient has the componentxml which is XML based ui design and use JavaScript to have client side logics. You need not compile your app every time in development environment and just reloading of the browser will have the change included and you can test it.

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