|
Re: Implement FormEditor for own XML format / Java model [message #1003638 is a reply to message #1002770] |
Mon, 21 January 2013 17:06 |
Curtis Windatt Messages: 166 Registered: July 2009 |
Senior Member |
|
|
There are articles and examples found online. I couldn't tell you why you end up getting an empty page.
The PDE code is all open source so you can examine how we implement the forms API. Most of the PDE editors have extra framework code that you wouldn't need, but it does give you a working example. Note that PDE has a lot of form editors, Plug-in, Schema, Product, Target, Context Help, Table of Contents, Category, Update Site, Feature, etc.
|
|
|
|
Re: Implement FormEditor for own XML format / Java model [message #1053643 is a reply to message #1003645] |
Tue, 07 May 2013 06:18 |
akhil gupta Messages: 13 Registered: November 2012 |
Junior Member |
|
|
Hi Johan,
if you are looking to implement form based editor in eclipse then you will have to extend your editor class to FormEditor and for the tab like plugin.xml, you will have to create separate classes for each and each one should extend the FormPage.
In your editor class, override the addPage() just like:
@Override
protected void addPages() {
firstPage();
secondPage();
.....
.....
}
and above each page should have definition like:
private void firstPage() {
//add 'first' page
firstFormObj = new FirstPage(this, "FirstPage","FirstTab");
try {
addPage(firstFormObj);
} catch (PartInitException e) {
e.printStackTrace();
}
}
In above code, FirstPage is class related to First tab,
now, In class FirstPage, extend it from FormPage class and override the "createFormContent(IManagedForm managedForm)" method. Within this method you can define UI of your first tab.
This is too late for you.. but hope this will help to others.
Regards,
Akhil
|
|
|
Powered by
FUDForum. Page generated in 0.02406 seconds