Package org.jzy3d.maths
Class Margin
java.lang.Object
org.jzy3d.maths.Margin
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
int
int
Return the sum of left and right marginint
getLeft()
int
getRight()
int
getTop()
int
getWidth()
Return the sum of left and right marginint
hashCode()
void
set
(int width, int height) Set left and right margin to width/2, top and bottom margin to height/2.void
set
(int left, int right, int top, int bottom) void
setBottom
(int bottom) void
setHeight
(int height) Set top and bottom margin to height/2.void
setLeft
(int left) void
setRight
(int right) void
setTop
(int top) void
setWidth
(int width) Set left and right margin to width/2.toString()
-
Field Details
-
left
protected int left -
right
protected int right -
top
protected int top -
bottom
protected int bottom
-
-
Constructor Details
-
Margin
public Margin() -
Margin
public Margin(int width, int height) -
Margin
public Margin(int left, int right, int top, int bottom) -
Margin
public Margin(float left, float right, float top, float bottom)
-
-
Method Details
-
set
public void set(int width, int height) Set left and right margin to width/2, top and bottom margin to height/2. -
set
public void set(int left, int right, int top, int bottom) -
setHeight
public void setHeight(int height) Set top and bottom margin to height/2. -
setWidth
public void setWidth(int width) Set left and right margin to width/2. -
getWidth
public int getWidth()Return the sum of left and right margin -
getHeight
public int getHeight()Return the sum of left and right margin -
getLeft
public int getLeft() -
setLeft
public void setLeft(int left) -
getRight
public int getRight() -
setRight
public void setRight(int right) -
getTop
public int getTop() -
setTop
public void setTop(int top) -
getBottom
public int getBottom() -
setBottom
public void setBottom(int bottom) -
toString
-
hashCode
public int hashCode() -
equals
-