简体   繁体   English

在swt / jface应用程序中使用的属性编辑器Ui

[英]Properties editor Ui to use in swt/jface application

I am currently working on a project where i have a need to integrate/build a properties editor (like Jboss tools properties editor open in eclipse for editing hibernate configuration files) in my desktop application. 我目前正在一个项目中,需要在我的桌面应用程序中集成/构建属性编辑器(例如,在eclipse中打开的Jboss工具属性编辑器,用于编辑休眠配置文件)。 I was looking for some good ready to use UI plugin to just integrate in my application or with small changes in the source code of the plugin to make that working according to my needs. 我一直在寻找一些易于使用的UI插件,以便仅将其集成到我的应用程序中,或者在插件的源代码中进行少量更改以使其能够根据我的需要工作。 Can someone please redirect me to the right way. 有人可以将我重定向到正确的方式。

Thanks 谢谢

Take a look at http://www.eclipse.org/sapphire/ 看看http://www.eclipse.org/sapphire/

In the past, I was using Eclipse Structured Source Editing framework . 过去,我使用的是Eclipse Structured Source Editing框架 It gives you extensible XML source editor (eg you get most source editor features like syntax highlight, code completion - but you can extend and customize those features) - and you can create an Eclipse Forms-based visual editor that would use the SSE XML DOM as a model (eg you may add listeners to DOM nodes - to keep your visual editor in sync with the modifications user makes to the source code. 它为您提供了可扩展的XML源代码编辑器(例如,您获得了大多数源代码编辑器功能,例如语法突出显示,代码完成-但您可以扩展和定制这些功能),并且可以创建基于Eclipse Forms的可视化编辑器,该可视化编辑器将使用SSE XML DOM作为模型(例如,您可以将侦听器添加到DOM节点-以使可视编辑器与用户对源代码所做的修改保持同步。

I found a good SWT wrapper, which has provided some ready to use widgets, PropertyTable is one of them. 我找到了一个很好的SWT包装器,它提供了一些随时可用的小部件,PropertyTable就是其中之一。

https://code.google.com/a/eclipselabs.org/p/opal/wiki/PropertyTable https://code.google.com/a/eclipselabs.org/p/opal/wiki/PropertyTable

Hope this will help others. 希望这对其他人有帮助。

Hibernate configuration files are xml so you should be able to edit them with the standalone Eclipse IDE. Hibernate配置文件是xml,因此您应该能够使用独立的Eclipse IDE对其进行编辑。 When creating a Hibernate Configuration file you would just save it as configuration.cfg.xml and for hibernate class mapping files you would do className.hbm.xml. 创建Hibernate Configuration文件时,只需将其另存为configuration.cfg.xml即可;对于hibernate类映射文件,只需执行className.hbm.xml。

I wouldn't say you would need a plugin to create and edit hibernate configuration files. 我不会说您需要一个插件来创建和编辑休眠配置文件。 Hibernate will know what to do with the file when it runs as long as they are in the correct build path. 只要文件在正确的构建路径中,Hibernate就会知道在文件运行时该如何处理。

I hope this helps or at least points you in the right direction. 我希望这有助于或至少为您指明了正确的方向。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM