Open main menu

CDOT Wiki β

Changes

Teams Winter 2011/team1/RCP/Define and use editors

630 bytes removed, 17:47, 4 March 2011
no edit summary
=== 1. Show Data in Application ===
1.1 Columns data in a JFace table can be hold in <code>ModelProvider</code> and it is defined via instances of <code>TableViewerColumn</code>object:<br/>
<code>viewer.setInput(ModelProvider.INSTANCE.getStudents());</code><br/>
and
<code>TableViewerColumn col = createTableViewerColumn(titles[0], bounds[0], 0);</code>
1.2 Add the following lines to <code>StudentsView.java</code> class:<br/>
Private variable: <br/>
<code>private TableViewer viewer;</code><br/>
Change the <code>createColumns()method:<br/>
<pre>
String[] titles = { "Id", "First name", "Last name", "Program" };
</pre>
 
 
=== 3. Define and Use Editors ===
1
edit