Package cz.vutbr.fit.layout.segm.op
Class MultiLineOperator
- java.lang.Object
-
- cz.vutbr.fit.layout.impl.BaseService
-
- cz.vutbr.fit.layout.impl.BaseParametrizedOperation
-
- cz.vutbr.fit.layout.impl.BaseOperator
-
- cz.vutbr.fit.layout.segm.op.MultiLineOperator
-
- All Implemented Interfaces:
AreaTreeOperator,ParametrizedOperation,Service
public class MultiLineOperator extends BaseOperator
Detects sequences of aligned lines and joins them to a single area.- Author:
- burgetr
-
-
Field Summary
Fields Modifier and Type Field Description protected floatmaxLineEmSpaceThe maximal distance of two areas allowed within a single line (in 'em' units)protected booleanuseConsistentStyleShould the lines have a consistent visual style?
-
Constructor Summary
Constructors Constructor Description MultiLineOperator()MultiLineOperator(boolean useConsistentStyle, float maxLineEmSpace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapply(AreaTree atree)voidapply(AreaTree atree, Area root)List<Parameter>defineParams()StringgetCategory()StringgetDescription()StringgetId()floatgetMaxLineEmSpace()StringgetName()booleangetUseConsistentStyle()protected voidjoinAreas(Area a)Goes through the grid of areas and joins the adjacent visual areas that are not separated by anythingprotected voidrecursiveJoinAreas(Area root)Goes through all the areas in the tree and tries to join their sub-areas into single areas.voidsetMaxLineEmSpace(float maxLineEmSpace)voidsetUseConsistentStyle(boolean useConsistentStyle)-
Methods inherited from class cz.vutbr.fit.layout.impl.BaseOperator
toString
-
Methods inherited from class cz.vutbr.fit.layout.impl.BaseParametrizedOperation
getParam, getParams, getParamString, setParam
-
Methods inherited from class cz.vutbr.fit.layout.impl.BaseService
getServiceManager, setServiceManager
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface cz.vutbr.fit.layout.api.ParametrizedOperation
getParam, getParams, getParamString, setParam
-
Methods inherited from interface cz.vutbr.fit.layout.api.Service
setServiceManager
-
-
-
-
Method Detail
-
getId
public String getId()
-
getName
public String getName()
-
getDescription
public String getDescription()
-
getCategory
public String getCategory()
-
defineParams
public List<Parameter> defineParams()
- Overrides:
defineParamsin classBaseParametrizedOperation
-
getUseConsistentStyle
public boolean getUseConsistentStyle()
-
setUseConsistentStyle
public void setUseConsistentStyle(boolean useConsistentStyle)
-
getMaxLineEmSpace
public float getMaxLineEmSpace()
-
setMaxLineEmSpace
public void setMaxLineEmSpace(float maxLineEmSpace)
-
apply
public void apply(AreaTree atree)
-
recursiveJoinAreas
protected void recursiveJoinAreas(Area root)
Goes through all the areas in the tree and tries to join their sub-areas into single areas.
-
joinAreas
protected void joinAreas(Area a)
Goes through the grid of areas and joins the adjacent visual areas that are not separated by anything
-
-