btnStepNumber = new Button( grpScale, SWT.RADIO ); { btnStepNumber.setText( Messages.getString( "AbstractScaleSheet.Label.StepNumber" ) ); btnStepNumber.setSelection( getScale( ).isSetStepNumber( ) ); btnStepNumber.addListener( SWT.Selection, this ); }  spnStepNumber = new Spinner( grpScale, SWT.BORDER ); { spnStepNumber.setLayoutData( new GridData( GridData.FILL_HORIZONTAL ) ); spnStepNumber.setMinimum( 2 ); spnStepNumber.setMaximum( 100 ); spnStepNumber.setSelection( getScale( ).getStepNumber( ) ); spnStepNumber.addListener( SWT.Selection, this ); }  new Label( grpScale, SWT.NONE ); new Label( grpScale, SWT.NONE );  lblMin = new Label( cmpContent, SWT.NONE ); lblMin.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Minimum" ) );  txtScaleMin = new TextEditorComposite( cmpContent, SWT.BORDER | SWT.SINGLE, getValueType( ) ); { GridData gd = new GridData( GridData.FILL_HORIZONTAL ); gd.widthHint = 80; txtScaleMin.setLayoutData( gd ); txtScaleMin.setText( getValue( getScale( ).getMin( ) ) ); txtScaleMin.addListener( this ); txtScaleMin.setDefaultValue( "" ); }         lblMax = new Label( cmpContent, SWT.NONE ); lblMax.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Maximum" ) );  txtScaleMax = new TextEditorComposite( cmpContent, SWT.BORDER | SWT.SINGLE, getValueType( ) ); { GridData gd = new GridData( GridData.FILL_HORIZONTAL ); gd.widthHint = 80; txtScaleMax.setLayoutData( gd ); txtScaleMax.setText( getValue( getScale( ).getMax( ) ) ); txtScaleMax.addListener( this ); txtScaleMax.setDefaultValue( "" ); }  setState( );
	protected Composite getComponent( Composite parent )	{		ChartUIUtil.bindHelp( parent, ChartHelpContextIds.POPUP_AXIS_SCALE );		GridLayout glContent = new GridLayout( 2, true );		glContent.marginHeight = 7;		glContent.marginWidth = 7;		glContent.horizontalSpacing = 2;		glContent.verticalSpacing = 5;		Composite cmpContent = new Composite( parent, SWT.NONE );		cmpContent.setLayout( glContent );		Group grpScale = new Group( cmpContent, SWT.NONE );		{			GridData gdGRPScale = new GridData( GridData.FILL_BOTH );			gdGRPScale.horizontalSpan = 4;			grpScale.setLayoutData( gdGRPScale );			GridLayout glScale = new GridLayout( );			glScale.numColumns = 4;			glScale.horizontalSpacing = 5;			glScale.verticalSpacing = 5;			glScale.marginHeight = 2;			glScale.marginWidth = 7;			grpScale.setLayout( glScale );			grpScale.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Scale" ) ); //$NON-NLS-1$		}		lblMin = new Label( grpScale, SWT.NONE );		GridData gdLBLMin = new GridData( );		lblMin.setLayoutData( gdLBLMin );		lblMin.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Minimum" ) ); //$NON-NLS-1$		txtScaleMin = new TextEditorComposite( grpScale, SWT.BORDER				| SWT.SINGLE, getValueType( ) );		{			GridData gd = new GridData( GridData.FILL_HORIZONTAL );			gd.widthHint = 100;			txtScaleMin.setLayoutData( gd );			txtScaleMin.setText( getValue( getScale( ).getMin( ) ) );			txtScaleMin.addListener( this );			txtScaleMin.setDefaultValue( "" ); //$NON-NLS-1$		}		lblMax = new Label( grpScale, SWT.NONE );		lblMax.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Maximum" ) ); //$NON-NLS-1$		txtScaleMax = new TextEditorComposite( grpScale, SWT.BORDER				| SWT.SINGLE, getValueType( ) );		{			GridData gd = new GridData( GridData.FILL_HORIZONTAL );			gd.widthHint = 100;			txtScaleMax.setLayoutData( gd );			txtScaleMax.setText( getValue( getScale( ).getMax( ) ) );			txtScaleMax.addListener( this );			txtScaleMax.setDefaultValue( "" ); //$NON-NLS-1$		}		lblStep = new Label( grpScale, SWT.NONE );		lblStep.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Step" ) ); //$NON-NLS-1$		txtScaleStep = new TextEditorComposite( grpScale, SWT.BORDER				| SWT.SINGLE, TextEditorComposite.TYPE_NUMBERIC );		{			GridData gd = new GridData( GridData.FILL_HORIZONTAL );			gd.widthHint = 100;			txtScaleStep.setLayoutData( gd );			String str = ""; //$NON-NLS-1$			if ( getScale( ).eIsSet( ComponentPackage.eINSTANCE.getScale_Step( ) ) )			{				str = String.valueOf( getScale( ).getStep( ) );			}			txtScaleStep.setText( str );			txtScaleStep.addListener( this );			txtScaleStep.setDefaultValue( "" ); //$NON-NLS-1$		}		//Use the type of input box to indicate the axis type.		if ( getValueType( ) == TextEditorComposite.TYPE_DATETIME )		{			lblUnit = new Label( grpScale, SWT.NONE );			GridData gdLBLUnit = new GridData( );			lblUnit.setLayoutData( gdLBLUnit );			lblUnit.setText( Messages.getString( "BaseAxisDataSheetImpl.Lbl.Unit" ) ); //$NON-NLS-1$			cmbScaleUnit = new Combo( grpScale, SWT.DROP_DOWN | SWT.READ_ONLY );			GridData gdCMBScaleUnit = new GridData( GridData.FILL_HORIZONTAL );			cmbScaleUnit.setLayoutData( gdCMBScaleUnit );			cmbScaleUnit.addListener( SWT.Selection, this );			// Populate origin types combo			NameSet ns = LiteralHelper.scaleUnitTypeSet;			cmbScaleUnit.setItems( ns.getDisplayNames( ) );			cmbScaleUnit.select( ns.getSafeNameIndex( getScale( ).getUnit( )					.getName( ) ) );		}		return cmpContent;	}