public class HomeDoorOrWindow extends HomePieceOfFurniture implements DoorOrWindow
Modifier and Type | Class and Description |
---|---|
static class |
HomeDoorOrWindow.Property
The properties of a door or window that may change.
|
HomePieceOfFurniture.SortableProperty
EMPTY_PROPERTY_ARRAY
DEFAULT_CUT_OUT_SHAPE, HIDE_EDGE_COLOR_MATERIAL, IDENTITY_ROTATION, SHOW_BACK_FACE
Constructor and Description |
---|
HomeDoorOrWindow(DoorOrWindow doorOrWindow)
Creates a home door or window from an existing one.
|
HomeDoorOrWindow(DoorOrWindow doorOrWindow,
java.lang.String[] copiedProperties)
Creates a home door or window from an existing one.
|
HomeDoorOrWindow(java.lang.String id,
DoorOrWindow doorOrWindow)
Creates a home door or window from an existing one.
|
HomeDoorOrWindow(java.lang.String id,
DoorOrWindow doorOrWindow,
java.lang.String[] copiedProperties)
Creates a home door or window from an existing one.
|
Modifier and Type | Method and Description |
---|---|
HomeObject |
duplicate()
Returns a copy of this door or window.
|
java.lang.String |
getCutOutShape()
Returns the shape used to cut out walls that intersect this door or window.
|
Sash[] |
getSashes()
Returns a copy of the sashes attached to this door or window.
|
float |
getWallDistance()
Returns the distance between the back side of this door or window and the wall where it's located.
|
float |
getWallHeight()
Returns the height of the wall part in which this door or window should be placed.
|
float |
getWallLeft()
Returns the distance between the left side of this door or window and the wall part where it should be placed.
|
float |
getWallThickness()
Returns the thickness of the wall in which this door or window should be placed.
|
float |
getWallTop()
Returns the distance between the left side of this door or window and the wall part where it should be placed.
|
float |
getWallWidth()
Returns the width of the wall part in which this door or window should be placed.
|
boolean |
isBoundToWall()
Returns
true if the location and the size of this door or window
were bound to a wall, last time they were updated. |
boolean |
isDoorOrWindow()
Returns always
true . |
boolean |
isWallCutOutOnBothSides()
Returns
true if this door or window should cut out the both sides
of the walls it intersects, even if its front or back side are within the wall thickness. |
boolean |
isWidthDepthDeformable()
Returns
false if the width and depth of this door or window may
not be changed independently from each other. |
void |
setAngle(float angle)
Sets the angle of this door or window and
resets its
boundToWall flag if the angle changed. |
void |
setBoundToWall(boolean boundToWall)
Sets whether the location and the size of this door or window
were bound to a wall, last time they were updated.
|
void |
setCutOutShape(java.lang.String cutOutShape)
Sets the shape used to cut out walls that intersect this door or window.
|
void |
setDepth(float depth)
Sets the depth of this door or window and
resets its
boundToWall flag if the depth changed. |
void |
setSashes(Sash[] sashes)
Sets the sashes attached to this door or window.
|
void |
setWallCutOutOnBothSides(boolean wallCutOutOnBothSides)
Sets whether the width and depth of the new door or window may
be changed independently from each other.
|
void |
setWallDistance(float wallDistance)
Sets the distance between the back side of this door or window and the wall where it's located.
|
void |
setWallHeight(float wallHeight)
Sets the height of the wall part in which this door or window should be placed.
|
void |
setWallLeft(float wallLeft)
Sets the distance between the left side of this door or window and the wall part where it should be placed.
|
void |
setWallThickness(float wallThickness)
Sets the thickness of the wall in which this door or window should be placed.
|
void |
setWallTop(float wallTop)
Sets the distance between the top side of this door or window and the wall part where it should be placed.
|
void |
setWallWidth(float wallWidth)
Sets the width of the wall part in which this door or window should be placed.
|
void |
setWidthDepthDeformable(boolean widthDepthDeformable)
Sets whether the width and depth of the new door or window may
be changed independently from each other.
|
void |
setX(float x)
Sets the abscissa of this door or window and
resets its
boundToWall flag if the abscissa changed. |
void |
setY(float y)
Sets the ordinate of this door or window and
resets its
boundToWall flag if the ordinate changed. |
clone, containsPoint, getAngle, getCatalogId, getColor, getCreator, getCurrency, getDepth, getDepthInPlan, getDescription, getDropOnTopElevation, getElevation, getFurnitureComparator, getGroundElevation, getHeight, getHeightInPlan, getIcon, getInformation, getLevel, getLicense, getModel, getModelFlags, getModelMaterials, getModelRotation, getModelSize, getModelTransformations, getName, getNameAngle, getNameStyle, getNameXOffset, getNameYOffset, getPitch, getPlanIcon, getPoints, getPrice, getPriceValueAddedTaxIncluded, getRoll, getShininess, getStaircaseCutOutShape, getTexture, getValueAddedTax, getValueAddedTaxPercentage, getWidth, getWidthInPlan, getX, getY, intersectsRectangle, isAtLevel, isBackFaceShown, isBottomLeftPointAt, isBottomRightPointAt, isDeformable, isHorizontallyRotatable, isHorizontallyRotated, isModelCenteredAtOrigin, isModelMirrored, isMovable, isNameCenterPointAt, isNameVisible, isParallelToWall, isPointAt, isResizable, isTexturable, isTopLeftPointAt, isTopRightPointAt, isVisible, move, scale, setBackFaceShown, setCatalogId, setColor, setCreator, setCurrency, setDepthInPlan, setDescription, setElevation, setHeight, setHeightInPlan, setIcon, setInformation, setLevel, setLicense, setModel, setModelCenteredAtOrigin, setModelFlags, setModelMaterials, setModelMirrored, setModelRotation, setModelSize, setModelTransformations, setMovable, setName, setNameAngle, setNameStyle, setNameVisible, setNameXOffset, setNameYOffset, setPitch, setPlanIcon, setPrice, setRoll, setShininess, setStaircaseCutOutShape, setTexture, setValueAddedTaxPercentage, setVisible, setWidth, setWidthInPlan
addPropertyChangeListener, addPropertyChangeListener, createId, firePropertyChange, getContentProperty, getId, getProperty, getPropertyNames, isContentProperty, removePropertyChangeListener, removePropertyChangeListener, setProperty, setProperty
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getColor, getContentProperty, getCreator, getCurrency, getDepth, getDescription, getDropOnTopElevation, getElevation, getHeight, getIcon, getInformation, getLicense, getModel, getModelFlags, getModelRotation, getModelSize, getName, getPlanIcon, getPrice, getProperty, getPropertyNames, getStaircaseCutOutShape, getValueAddedTaxPercentage, getWidth, isBackFaceShown, isContentProperty, isDeformable, isHorizontallyRotatable, isMovable, isResizable, isTexturable
public HomeDoorOrWindow(DoorOrWindow doorOrWindow)
doorOrWindow
- the door or window from which data are copiedpublic HomeDoorOrWindow(DoorOrWindow doorOrWindow, java.lang.String[] copiedProperties)
doorOrWindow
- the door or window from which data are copiedcopiedProperties
- the names of the additional properties which should be copied from the existing piece
or null
if all properties should be copied.public HomeDoorOrWindow(java.lang.String id, DoorOrWindow doorOrWindow)
id
- the ID of the objectdoorOrWindow
- the door or window from which data are copiedpublic HomeDoorOrWindow(java.lang.String id, DoorOrWindow doorOrWindow, java.lang.String[] copiedProperties)
id
- the ID of the objectdoorOrWindow
- the door or window from which data are copiedcopiedProperties
- the names of the additional properties which should be copied from the existing piece
or null
if all properties should be copied.public float getWallThickness()
getWallThickness
in interface DoorOrWindow
public void setWallThickness(float wallThickness)
wallThickness
- a value in percentage of the depth of the door or the window.public float getWallDistance()
getWallDistance
in interface DoorOrWindow
public void setWallDistance(float wallDistance)
wallDistance
- a distance in percentage of the depth of the door or the window.public float getWallWidth()
public void setWallWidth(float wallWidth)
wallWidth
- a value in percentage of the width of the door or the window.public float getWallLeft()
public void setWallLeft(float wallLeft)
wallLeft
- a distance in percentage of the width of the door or the window.public float getWallHeight()
public void setWallHeight(float wallHeight)
wallHeight
- a value in percentage of the height of the door or the window.public float getWallTop()
public void setWallTop(float wallTop)
wallTop
- a distance in percentage of the height of the door or the window.public Sash[] getSashes()
getSashes
in interface DoorOrWindow
public void setSashes(Sash[] sashes)
sashes
- sashes of this window.public java.lang.String getCutOutShape()
getCutOutShape
in interface DoorOrWindow
null
or a shape defined with the syntax of the d attribute of a
SVG path element
that fits in a square spreading from (0, 0) to (1, 1) which will be
scaled afterwards to the real size of this door or window.public void setCutOutShape(java.lang.String cutOutShape)
cutOutShape
- a SVG path element.public boolean isWallCutOutOnBothSides()
true
if this door or window should cut out the both sides
of the walls it intersects, even if its front or back side are within the wall thickness.isWallCutOutOnBothSides
in interface DoorOrWindow
public void setWallCutOutOnBothSides(boolean wallCutOutOnBothSides)
public boolean isWidthDepthDeformable()
false
if the width and depth of this door or window may
not be changed independently from each other. When false
, this door or window
will also make a hole in the wall when it's placed whatever its depth if its
bouldToWall
flag is true
.isWidthDepthDeformable
in interface DoorOrWindow
isWidthDepthDeformable
in interface PieceOfFurniture
isWidthDepthDeformable
in class HomePieceOfFurniture
public void setWidthDepthDeformable(boolean widthDepthDeformable)
public boolean isBoundToWall()
true
if the location and the size of this door or window
were bound to a wall, last time they were updated.public void setBoundToWall(boolean boundToWall)
public void setX(float x)
boundToWall
flag if the abscissa changed.setX
in class HomePieceOfFurniture
public void setY(float y)
boundToWall
flag if the ordinate changed.setY
in class HomePieceOfFurniture
public void setAngle(float angle)
boundToWall
flag if the angle changed.setAngle
in class HomePieceOfFurniture
public void setDepth(float depth)
boundToWall
flag if the depth changed.setDepth
in class HomePieceOfFurniture
public boolean isDoorOrWindow()
true
.isDoorOrWindow
in interface PieceOfFurniture
isDoorOrWindow
in class HomePieceOfFurniture
public HomeObject duplicate()
duplicate
in class HomeObject
© Copyright 2024 Space Mushrooms
Distributed under GNU General Public License