* Initialize the panel with pre-existing values.
*
* @param ruleWrapper the {@link RuleWrapper}.
*/
public void init( RuleWrapper ruleWrapper ) {
SymbolizerWrapper symbolizersWrapper = ruleWrapper.getGeometrySymbolizersWrapper();
mainComposite = new Composite(parent, SWT.NONE);
mainComposite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
mainComposite.setLayout(new GridLayout(3, true));
// rule name
Label nameLabel = new Label(mainComposite, SWT.NONE);
nameLabel.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false));
nameLabel.setText(Messages.LineGeneralParametersComposite_0);
nameText = new Text(mainComposite, SWT.SINGLE | SWT.LEAD | SWT.BORDER);
GridData nameTextGD = new GridData(SWT.FILL, SWT.CENTER, true, false);
nameTextGD.horizontalSpan = 2;
nameText.setLayoutData(nameTextGD);
nameText.setText(ruleWrapper.getName());
nameText.addFocusListener(this);
Label offsetLabel = new Label(mainComposite, SWT.NONE);
GridData offsetLabelGD = new GridData(SWT.FILL, SWT.CENTER, true, false);
offsetLabel.setLayoutData(offsetLabelGD);
offsetLabel.setText(Messages.LineGeneralParametersComposite_1);
String xOffset = symbolizersWrapper.getxOffset();
String yOffset = symbolizersWrapper.getyOffset();
Integer tmpXOffset = Utilities.isNumber(xOffset, Integer.class);
Integer tmpYOffset = Utilities.isNumber(yOffset, Integer.class);
if (tmpXOffset == null || tmpYOffset == null) {
tmpXOffset = 0;
tmpYOffset = 0;