|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.cau.cs.kieler.core.kivi.AbstractEffect
de.cau.cs.kieler.kiml.ui.diagram.LayoutEffect
public class LayoutEffect
Performs automatic layout on a diagram editor for a given selection. The layout
can be customized using #setOption(EObject, IProperty, Object)
, which
sets specific layout options only for this instance of the layout effect.
Constructor Summary | |
---|---|
LayoutEffect(IWorkbenchPart workbenchPart,
EObject object)
Create a new layout effect for the given diagram editor and EObject. |
|
LayoutEffect(IWorkbenchPart workbenchPart,
EObject object,
boolean zoomToFit)
Create a new layout effect for the given diagram editor and EObject. |
|
LayoutEffect(IWorkbenchPart workbenchPart,
EObject object,
boolean zoomToFit,
boolean progressBar)
Create a new layout effect for the given diagram editor and EObject. |
|
LayoutEffect(IWorkbenchPart workbenchPart,
EObject object,
boolean zoomToFit,
boolean progressBar,
boolean ancestors)
Create a new layout effect for the given diagram editor and EObject. |
|
LayoutEffect(IWorkbenchPart workbenchPart,
EObject object,
boolean zoomToFit,
boolean progressBar,
boolean ancestors,
boolean animation)
Create a new layout effect for the given diagram editor and EObject. |
Method Summary | |
---|---|
void |
dontMerge()
Constrain this layout effect not to be merged with any other effect. |
void |
execute()
Execute the effect. |
LayoutMapping<?> |
getMapping()
Returns the layout mapping that was used for this layout effect, or null if
the effect has not been executed yet. |
boolean |
isMergeable()
Determines whether this effect can be merged with previously scheduled effects. |
IEffect |
merge(IEffect otherEffect)
Merge this effect with another effect. |
void |
setOption(Object object,
IProperty<?> option,
Object value)
Set a layout option value for this layout effect. |
void |
undo()
Undo a layout effect. |
Methods inherited from class de.cau.cs.kieler.core.kivi.AbstractEffect |
---|
schedule, scheduleUndo, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public LayoutEffect(IWorkbenchPart workbenchPart, EObject object)
null
is given as top-level object, layout is performed for the whole diagram.
workbenchPart
- the workbench part containing the diagram to layoutobject
- the top-level domain model object to layout, or null
UnsupportedPartException
- if layout is not supported for the given workbench partpublic LayoutEffect(IWorkbenchPart workbenchPart, EObject object, boolean zoomToFit)
null
is given as top-level object, layout is performed for the whole diagram.
workbenchPart
- the workbench part containing the diagram to layoutobject
- the top-level domain model object to layout, or null
zoomToFit
- whether zoom to fit shall be performed
UnsupportedPartException
- if layout is not supported for the given workbench partpublic LayoutEffect(IWorkbenchPart workbenchPart, EObject object, boolean zoomToFit, boolean progressBar)
null
is given as top-level object, layout is performed for the whole diagram.
workbenchPart
- the workbench part containing the diagram to layoutobject
- the top-level domain model object to layout, or null
zoomToFit
- whether zoom to fit shall be performedprogressBar
- whether a progress bar shall be displayed
UnsupportedPartException
- if layout is not supported for the given workbench partpublic LayoutEffect(IWorkbenchPart workbenchPart, EObject object, boolean zoomToFit, boolean progressBar, boolean ancestors)
null
is given as top-level object, layout is performed for the whole diagram.
workbenchPart
- the workbench part containing the diagram to layoutobject
- the top-level domain model object to layout, or null
zoomToFit
- whether zoom to fit shall be performedprogressBar
- whether a progress bar shall be displayedancestors
- whether to include the ancestors in the layout process
UnsupportedPartException
- if layout is not supported for the given workbench partpublic LayoutEffect(IWorkbenchPart workbenchPart, EObject object, boolean zoomToFit, boolean progressBar, boolean ancestors, boolean animation)
null
is given as top-level object, layout is performed for the whole diagram.
workbenchPart
- the workbench part containing the diagram to layoutobject
- the top-level domain model object to layout, or null
zoomToFit
- whether zoom to fit shall be performedprogressBar
- whether a progress bar shall be displayedancestors
- whether to include the ancestors in the layout processanimation
- whether the layout shall be animated
UnsupportedPartException
- if layout is not supported for the given workbench partMethod Detail |
---|
public void dontMerge()
public void setOption(Object object, IProperty<?> option, Object value)
object
- the domain model element or edit part for which the option shall be setoption
- the layout option to set (see LayoutOptions
)value
- the value for the layout optionpublic void execute()
public void undo()
undo
in interface IEffect
undo
in class AbstractEffect
public LayoutMapping<?> getMapping()
null
if
the effect has not been executed yet.
public boolean isMergeable()
isMergeable
in interface IEffect
isMergeable
in class AbstractEffect
public IEffect merge(IEffect otherEffect)
merge
in interface IEffect
merge
in class AbstractEffect
otherEffect
- the effect to merge with
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |