libSBML C API  5.18.0
BoundingBox_t Class Reference

Detailed Description

layout A bounding box for an item in a diagram.

Public Member Functions

BoundingBox_tBoundingBox_clone (const BoundingBox_t *bb)
 
BoundingBox_tBoundingBox_create (void)
 Function that creates a BoundingBox_t structure with position set to (0.0,0.0,0.0) and dimensions set to (0.0,0.0,0.0). More...
 
BoundingBox_tBoundingBox_createWith (const char *sid)
 Function that creates a BoundingBox_t structure with position set to (0.0,0.0,0.0) and dimensions set to (0.0,0.0,0.0). More...
 
BoundingBox_tBoundingBox_createWithCoordinates (const char *sid, double x, double y, double z, double width, double height, double depth)
 Function that creates a BoundingBox_t structure with the coordinates and sizes given as arguments. More...
 
double BoundingBox_depth (BoundingBox_t *bb)
 Returns the depth of the bounding box. More...
 
void BoundingBox_free (BoundingBox_t *bb)
 Frees all memory taken by the given BoundingBox_t structure. More...
 
Dimensions_tBoundingBox_getDimensions (BoundingBox_t *bb)
 Returns the dimensions as a Dimensions_t structure. More...
 
const char * BoundingBox_getId (const BoundingBox_t *bb)
 Returns the id. More...
 
Point_tBoundingBox_getPosition (BoundingBox_t *bb)
 Returns the position as a Point_t structure. More...
 
double BoundingBox_height (BoundingBox_t *bb)
 Returns the height of the bounding box. More...
 
void BoundingBox_initDefaults (BoundingBox_t *bb)
 Does nothing since no defaults are defined for BoundingBox_t. More...
 
int BoundingBox_isSetId (const BoundingBox_t *bb)
 Returns 1 (true) if the id is set. More...
 
void BoundingBox_setDepth (BoundingBox_t *bb, double depth)
 Sets the depth of the bounding box. More...
 
void BoundingBox_setDimensions (BoundingBox_t *bb, const Dimensions_t *d)
 Sets the dimensions to a copy of the Dimensions_t structure given. More...
 
void BoundingBox_setHeight (BoundingBox_t *bb, double height)
 Sets the height of the bounding box. More...
 
int BoundingBox_setId (BoundingBox_t *bb, const char *sid)
 Sets the id. More...
 
void BoundingBox_setPosition (BoundingBox_t *bb, const Point_t *p)
 Sets the position to a copy of the Point_t structure given as argument. More...
 
void BoundingBox_setWidth (BoundingBox_t *bb, double width)
 Sets the width of the bounding box. More...
 
void BoundingBox_setX (BoundingBox_t *bb, double x)
 Sets the x offset of the bounding box. More...
 
void BoundingBox_setY (BoundingBox_t *bb, double y)
 Sets the y offset of the bounding box. More...
 
void BoundingBox_setZ (BoundingBox_t *bb, double z)
 Sets the z offset of the bounding box. More...
 
void BoundingBox_unsetId (BoundingBox_t *bb)
 Unsets the id. More...
 
double BoundingBox_width (BoundingBox_t *bb)
 Returns the width of the bounding box. More...
 
double BoundingBox_x (BoundingBox_t *bb)
 Returns the x offset of the bounding box. More...
 
double BoundingBox_y (BoundingBox_t *bb)
 Returns the y offset of the bounding box. More...
 
double BoundingBox_z (BoundingBox_t *bb)
 Returns the z offset of the bounding box. More...
 

Member Function Documentation

BoundingBox_t * BoundingBox_clone ( const BoundingBox_t bb)
Returns
a (deep) copy of this BoundingBox_t.
Parameters
bbthe BoundingBox_t structure.
BoundingBox_t * BoundingBox_create ( void  )

Function that creates a BoundingBox_t structure with position set to (0.0,0.0,0.0) and dimensions set to (0.0,0.0,0.0).

The id is set to the empty string.

BoundingBox_t * BoundingBox_createWith ( const char *  sid)

Function that creates a BoundingBox_t structure with position set to (0.0,0.0,0.0) and dimensions set to (0.0,0.0,0.0).

The id is set to the given string.

Parameters
sidthe id of the created BoundingBox_t.
BoundingBox_t * BoundingBox_createWithCoordinates ( const char *  sid,
double  x,
double  y,
double  z,
double  width,
double  height,
double  depth 
)

Function that creates a BoundingBox_t structure with the coordinates and sizes given as arguments.

The id is set to the empty string.

Parameters
sidthe id of the created BoundingBox_t.
xthe value of the x coordinate of the position Point_t.
ythe value of the y coordinate of the position Point_t.
zthe value of the z coordinate of the position Point_t.
widththe value of the width.
heightthe value of the height.
depththe value of the depth.
double BoundingBox_depth ( BoundingBox_t bb)

Returns the depth of the bounding box.

Parameters
bbthe BoundingBox_t structure.
void BoundingBox_free ( BoundingBox_t bb)

Frees all memory taken by the given BoundingBox_t structure.

Parameters
bbthe BoundingBox_t structure.
Dimensions_t * BoundingBox_getDimensions ( BoundingBox_t bb)

Returns the dimensions as a Dimensions_t structure.

Parameters
bbthe BoundingBox_t structure.
const char * BoundingBox_getId ( const BoundingBox_t bb)

Returns the id.

Parameters
bbthe BoundingBox_t structure.
Point_t * BoundingBox_getPosition ( BoundingBox_t bb)

Returns the position as a Point_t structure.

Parameters
bbthe BoundingBox_t structure.
double BoundingBox_height ( BoundingBox_t bb)

Returns the height of the bounding box.

Parameters
bbthe BoundingBox_t structure.
void BoundingBox_initDefaults ( BoundingBox_t bb)

Does nothing since no defaults are defined for BoundingBox_t.

Parameters
bbthe BoundingBox_t structure.
int BoundingBox_isSetId ( const BoundingBox_t bb)

Returns 1 (true) if the id is set.

Parameters
bbthe BoundingBox_t structure.
void BoundingBox_setDepth ( BoundingBox_t bb,
double  depth 
)

Sets the depth of the bounding box.

Parameters
bbthe BoundingBox_t structure.
depththe value of the depth.
void BoundingBox_setDimensions ( BoundingBox_t bb,
const Dimensions_t d 
)

Sets the dimensions to a copy of the Dimensions_t structure given.

Parameters
bbthe BoundingBox_t structure.
dthe Dimensions_t to use as the dimensions of the BoundingBox_t.
void BoundingBox_setHeight ( BoundingBox_t bb,
double  height 
)

Sets the height of the bounding box.

Parameters
bbthe BoundingBox_t structure.
heightthe value of the height.
int BoundingBox_setId ( BoundingBox_t bb,
const char *  sid 
)

Sets the id.

Parameters
bbthe BoundingBox_t structure.
sidthe value of the id.
void BoundingBox_setPosition ( BoundingBox_t bb,
const Point_t p 
)

Sets the position to a copy of the Point_t structure given as argument.

Parameters
bbthe BoundingBox_t structure.
pthe Point_t to use as the position of the BoundingBox_t.
void BoundingBox_setWidth ( BoundingBox_t bb,
double  width 
)

Sets the width of the bounding box.

Parameters
bbthe BoundingBox_t structure.
widththe value of the width.
void BoundingBox_setX ( BoundingBox_t bb,
double  x 
)

Sets the x offset of the bounding box.

Parameters
bbthe BoundingBox_t structure.
xthe value of the x coordinate.
void BoundingBox_setY ( BoundingBox_t bb,
double  y 
)

Sets the y offset of the bounding box.

Parameters
bbthe BoundingBox_t structure.
ythe value of the y coordinate.
void BoundingBox_setZ ( BoundingBox_t bb,
double  z 
)

Sets the z offset of the bounding box.

Parameters
bbthe BoundingBox_t structure.
zthe value of the z coordinate.
void BoundingBox_unsetId ( BoundingBox_t bb)

Unsets the id.

Parameters
bbthe BoundingBox_t structure.
double BoundingBox_width ( BoundingBox_t bb)

Returns the width of the bounding box.

Parameters
bbthe BoundingBox_t structure.
double BoundingBox_x ( BoundingBox_t bb)

Returns the x offset of the bounding box.

Parameters
bbthe BoundingBox_t structure.
double BoundingBox_y ( BoundingBox_t bb)

Returns the y offset of the bounding box.

Parameters
bbthe BoundingBox_t structure.
double BoundingBox_z ( BoundingBox_t bb)

Returns the z offset of the bounding box.

Parameters
bbthe BoundingBox_t structure.