Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Rap10M2 News"

m (RWT)
(Replaced content with "This page was obsolete and has been deleted. Please see the history if you need to access the content.")
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
| [[RAP|RAP wiki home]] | [http://eclipse.org/rap RAP project home] |
+
This page was obsolete and has been deleted. Please see the history if you need to access the content.
 
+
===RAP 1.0 M2 - New and Noteworthy===
+
 
+
Here are some of the more noteworthy things available in milestone build M2 (March 2, 2007) which is now available for [http://www.eclipse.org/rap/downloads.php download].
+
 
+
<!--
+
Here are some of the more noteworthy things available in milestone build M2 which will be available for download on March 2, 2007. If You don't want to wait, all the listed features are available in [http://www.eclipse.org/rap/cvs.php CVS] HEAD.
+
-->
+
 
+
==JFace==
+
{|
+
|-valign="top" align="left"
+
|width="20%"|'''Dialogs'''
+
|width="80%"|RAP JFace now includes the base classes to implement dialogs like Window, WindowManager, Dialog, and IconAndMessageDialog and provides the most often used dialogs.
+
* InputDialog
+
[[Image:RapInputDialog.png]]
+
* MessageDialog
+
[[Image:RapQuestionDialog.png]]
+
* ErrorDialog
+
[[Image:RapErrorDialog.png]]
+
 
+
Due to the distributed nature of RAP, the way how the result is passed back to the caller
+
differs from JFace. RAP JFace provides an <code>IWindowCallback</code> interface whose <code>windowClosed</code> method is called with the returnCode as a parameter when a dialog was closed.
+
 
+
 
+
|}
+
 
+
==RWT==
+
{|
+
|-valign="top" align="left"
+
|width="20%"|'''ModifyEvent'''
+
|width="80%"|RWT now supports the <code>ModifyEvent</code>. The two widgets that benefit from this are <code>Text</code> and <code>Spinner</code>.  
+
Though implementing a <code>ModifyListener</code> does not differ from SWT as You can see below, the inner workings do differ. In contrary to SWT that sends a ModifyEvent immediately, RWT uses a delay of currently 500 ms after which the server is notified about changes.
+
 
+
<pre>
+
  Text text = new Text( parent, RWT.SINGLE );
+
  text.addModifyListener( new ModifyListener() {
+
    public void modifyText( ModifyEvent event ) {
+
      // update model with changed text
+
    }
+
  } );
+
 
+
</pre>
+
|-valign="top" align="left"
+
|'''Spinner'''
+
|Now there exists a <code>Spinner</code> widget that works much the same as in SWT.
+
[[Image:RapSpinner.png]]
+
|-valign="top" align="left"
+
|'''Default Button'''
+
|The default button was implemented, that You can now tell the Shell which of its buttons should behave as the default button. Just to have something to write for the next milestone news, the default button is not yet highlighted;)
+
 
+
|-valign="top" align="left"
+
|'''Shell enhancements'''
+
|For dependent shells (aka dialog shells, those created with the <code>Shell( Shell )</code> or <code>Shell( Shell, int )</code> constructor), the '''escape''' key closes the shell.
+
|-valign="top" align="left"
+
|'''Double click'''
+
|For <code>List</code>, <code>Tree</code>, and <code>CTabFolder</code> RWT now recognizes a double-click that is reported via the <code>widgetDefaultSelected</code> method of the <code>SelectionEvent</code>.
+
The screenshot below is taken from the RWT online demo, feel free to try it out yourself.
+
[[Image:RapDoubleClick.png]]
+
|-valign="top" align="left"
+
|'''Focus control and FocusEvent'''
+
|In this development cycle we also put our focus on the focus. The methods <code>setFocus</code>, <code>forceFocus</code>, and <code>isFocusControl</code> of the <code>Control</code> class allow You to focus a control and query whether the control has the input focus. The <code>getFocusControl</code> on class <code>Display</code> tells You which control currently has the input focus.
+
When adding a <code>FocusListener</code> to a control, it will be notified about <code>focusLost</code> and <code>focusGained</code> events.
+
 
+
As of now, not all controls do visually indicate that they currently are focused.
+
|-valign="top" align="left"
+
|'''Text enhancements'''
+
|The text widget has two new mini-features:
+
* The <code>setTextLimit</code> and <code>getTextLimit</code> methods can be use to control and query the number of characters that may be entered.
+
* All methods to control the text selection like <code>setSelection</code> and <code>getSelection</code> are implemented.
+
The following snippet, taken from the SelectionListener of the Show Selection button,
+
<pre>
+
  Point sel= result.getSelection();
+
  String selText = text.getSelectionText();
+
  String msg = "Selection from " + sel.x + " to " + sel.y + " is " + selText;
+
  label.setText( msg );       
+
</pre>
+
leads to what is shown below
+
 
+
[[Image:RapTextSelection.png]]
+
|}
+
 
+
 
+
The above features are just the ones that are new since the previous milestone build.
+

Latest revision as of 07:10, 8 January 2014

This page was obsolete and has been deleted. Please see the history if you need to access the content.

Back to the top