Runtime

## Deprecated API

Contents

- Deprecated Classes
- Deprecated Methods
- Deprecated Constructors

Deprecated Classes
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel This class has been deprecated and may be removed in the future. Use `WrappingLabel` instead. This class now extends from `WrappingLabel` so the behavior should be the same. If client code is calling one of the methods on `WrapLabel` that no longer exists, evaluate whether this is necessary or not.

Deprecated Methods
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.calculateSubStringTextSize() If this behavior is required then a request can be made (with justification) for the WrappingLabel.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.calculateTextSize(int, int) If this behavior is required then a request can be made (with justification) for the WrappingLabel.
org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance.ColorsAndFontsPropertySection.changeColor(SelectionEvent, Button, String, String, String, ImageDescriptor) The preference is not being retrieved from the correct preference store so it is not needed, use the other `changeColor` method.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getEllipse() Renamed to `WrapLabel.getTruncationString()`
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getIconBounds() The icon location can be retrieved with `WrappingLabel.getIconLocation()` and the icon(s) size can be retrieved with `WrappingLabel.getTotalIconSize()`.
org.eclipse.gmf.runtime.notation.impl.NotationFactoryImpl.getPackage()
org.eclipse.gmf.runtime.diagram.core.util.ViewUtil.getPropertyValue(View, Object) use `ViewUtil.getStructuralFeatureValue(View, EStructuralFeature)` instead
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getSubStringText() If this behavior is required then a request can be made (with justification) for the WrappingLabel.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getSubStringTextSize() If this behavior is required then a request can be made (with justification) for the WrappingLabel.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getTextLocation() Use `getTextBounds().getLocation()` instead.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getTextSize(int, int) If this behavior is required then a request can be made (with justification) for the WrappingLabel.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.getTextWrapAlignment() Renamed to `WrappingLabel.getTextJustification()`
org.eclipse.gmf.runtime.emf.ui.services.modelingassistant.ModelingAssistantService.getTypesForActionBar(IAdaptable) Renamed to `ModelingAssistantService.getTypesForPopupBar(IAdaptable)`
org.eclipse.gmf.runtime.common.core.command.AbstractCommand.internalSetResult(CommandResult) internal API
org.eclipse.gmf.runtime.emf.commands.core.command.CompositeTransactionalCommand.internalSetResult(CommandResult) internal API
org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand.internalSetResult(CommandResult) internal API
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.isTextTruncated() If this behavior is required then a request can be made (with justification) for the WrappingLabel.
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.isTextWrapped() Use `WrappingLabel.isTextWrapOn()` instead. This method was renamed because it never indicated if the text was actually wrapped, but whether text wrapping was turned on in the label.
org.eclipse.gmf.runtime.common.ui.services.properties.extended.PropertySource.setEditableValue(Object)
org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.setLabelAlignment(int) This never worked properly anyways. Call `WrappingLabel.setAlignment(int)` instead to position the icon and text within the label.
org.eclipse.gmf.runtime.diagram.core.util.ViewUtil.setPropertyValue(View, Object, Object) use `ViewUtil#setStructuralFeatureValue(View, EStructuralFeature, Object`} instead

org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.setTextWrapAlignment(int)
Call `WrappingLabel.setTextJustification(int)` and `WrappingLabel.setAlignment(int)` instead. This method was somewhat controlling text justification and label alignment, but they are really two independent settings. Previously, setTextWrapAlignment(CENTER) would not only center-justifies the text, but also put the label in the center. Now, you need to call `WrappingLabel.setTextJustification(int)` to justify the text (this only affects text when it is wrapped) and `WrappingLabel.setAlignment(int)` to position the text correctly in the label. If you want the text in the center of the label than call `setAlignment(PositionConstants.CENTER)`. Look at the implementation of this method to see how your code needs to be migrated.

org.eclipse.gmf.runtime.draw2d.ui.figures.WrapLabel.setTextWrapWidth(int) this method was empty and never called

Deprecated Constructors
org.eclipse.gmf.runtime.diagram.ui.properties.sections.appearance.ColorPalettePopup(Shell, String, int) Use the other constructor. This one does not retrieve the default value from the correct preference store.

Runtime

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp., Borland Software Corp., and others 2005,2006. All rights reserved.