diff --git a/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/GFDirectEditManager.java b/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/GFDirectEditManager.java
index b43e1c4..daf1717 100644
--- a/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/GFDirectEditManager.java
+++ b/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/GFDirectEditManager.java
@@ -251,12 +251,14 @@
 
 				// if auto code completion disabled then open code completion on
 				// CTRL+Space
-				KeyStroke keyStroke = directEditingFeature.isAutoCompletionEnabled() ? null : KeyStroke.getInstance(SWT.CTRL, 32);
+				KeyStroke keyStroke = directEditingFeature.isAutoCompletionEnabled() ? null : KeyStroke.getInstance(
+						SWT.CTRL, 32);
 
-				ContentProposalAdapter contentProposalAdapter = new ContentProposalAdapter(getCellEditor().getControl(),
-						controlContentAdapter, contentProposalProvider, keyStroke, null);
+				ContentProposalAdapter contentProposalAdapter = new ContentProposalAdapter(
+						getCellEditor().getControl(), controlContentAdapter, contentProposalProvider, keyStroke, null);
 				contentProposalAdapter.setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_REPLACE);
-				contentProposalAdapter.addContentProposalListener(new ContentProposalListener((TextCellEditor) getCellEditor()));
+				contentProposalAdapter.addContentProposalListener(new ContentProposalListener(
+						(TextCellEditor) getCellEditor()));
 
 				// <sw03072008> removed to avoid direct closing of cell editor
 				// after value selection from value help
@@ -283,7 +285,8 @@
 		// Hook the cell editor's copy/paste actions to the actionBars so that
 		// they can
 		// be invoked via keyboard shortcuts.
-		actionBars = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor().getEditorSite().getActionBars();
+		actionBars = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getActiveEditor()
+				.getEditorSite().getActionBars();
 		saveCurrentActions(actionBars);
 		actionHandler = new CellEditorActionHandler(actionBars);
 		actionHandler.addCellEditor(getCellEditor());
diff --git a/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/TextCellLocator.java b/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/TextCellLocator.java
index 907829b..5018f95 100644
--- a/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/TextCellLocator.java
+++ b/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/parts/directedit/TextCellLocator.java
@@ -120,14 +120,14 @@
 			if (rect.width > minWidth) {
 				minWidth = rect.width;
 			}
-			
+
 			if (directEditingFeature.stretchFieldToFitText()) {
 				CCombo combo = (CCombo) control;
 				Point pref = combo.computeSize(-1, -1);
-				if (minWidth < pref.x) 
+				if (minWidth < pref.x)
 					minWidth = pref.x;
-			}			
-			
+			}
+
 			control.setBounds(rect.x, rect.y, minWidth, 14);
 		}
 	}
diff --git a/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/policy/DefaultDirectEditPolicy.java b/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/policy/DefaultDirectEditPolicy.java
index d8e1c8a..d7a0275 100644
--- a/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/policy/DefaultDirectEditPolicy.java
+++ b/plugins/org.eclipse.graphiti.ui/src/org/eclipse/graphiti/ui/internal/policy/DefaultDirectEditPolicy.java
@@ -77,7 +77,8 @@
 		CellEditor cellEditor = request.getCellEditor();
 		final String message = cellEditor.getErrorMessage();
 		if (message != null && message.length() != 0) {
-			MessageDialog.openError(GraphitiUiInternal.getWorkbenchService().getShell(), Messages.DefaultDirectEditPolicy_0_xmsg, message);
+			MessageDialog.openError(GraphitiUiInternal.getWorkbenchService().getShell(),
+					Messages.DefaultDirectEditPolicy_0_xmsg, message);
 			return null;
 		}
 
@@ -108,7 +109,8 @@
 				if (directEditHolder.isSimpleMode()) {
 					value = directEditingFeature.getPossibleValues(directEditingContext)[index];
 				} else {
-					acceptedProposal = directEditingFeature.getProposalSupport().getPossibleValues(directEditingContext)[index];
+					acceptedProposal = directEditingFeature.getProposalSupport()
+							.getPossibleValues(directEditingContext)[index];
 				}
 			}
 
@@ -118,10 +120,12 @@
 			return null;
 		}
 
-		final ICommand cmd = new DirectEditingFeatureCommandWithContext(directEditingFeature, directEditingContext, value, acceptedProposal);
+		final ICommand cmd = new DirectEditingFeatureCommandWithContext(directEditingFeature, directEditingContext,
+				value, acceptedProposal);
 
 		final IFeatureProvider fp = directEditingFeature.getFeatureProvider();
-		final DiagramEditorInternal diagramEditor = (DiagramEditorInternal) fp.getDiagramTypeProvider().getDiagramEditor();
+		final DiagramEditorInternal diagramEditor = (DiagramEditorInternal) fp.getDiagramTypeProvider()
+				.getDiagramEditor();
 		final CommandStack commandStack = diagramEditor.getEditDomain().getCommandStack();
 		commandStack.execute(new GefCommandWrapper(cmd, diagramEditor.getEditingDomain()));
 		// CommandExec.getSingleton().executeCommand(cmd, fp.getConnection());
