the fair gds editor MacroClassCell

Cell Class Reference

A single cell of a design with all features to modify it. More...

See also: List of Classes


Member

  1. addBox(int x,int y,int b, int h,int layer)
  2. addBox(pointArray points,int layer)
  3. addCellrefArray(cell *c,pointArray array,int nx,int ny)
  4. addCellrefArray(cell *c,point pos1,point pos2,int nx,int ny)
  5. addCellref(cell *c,point pos)
  6. addChamferedBox(int x,int y,int b, int h,int chamfer, int layer)
  7. addCircleBox(point p1, point p2,int layer)
  8. addCircle(int layer,point center,int radius, int numPoints=0)
  9. addCircle(int layer,point center,point circlePoint, int numPoints=0)
  10. addCornerAreaSelect(double value1,double value2,int angleInt)
  11. addEllipse(int layer,point center,int rx,int ry)
  12. addPath(pointArray points,int layer)
  13. addPath(pointArray points,int layer,int width)
  14. addPolygon(pointArray points,int layer)
  15. addPolygonArc(point center, int radiusInner, int radiusOuter, double angleStart, double angleStop,int layer)
  16. addRoundedBox(int x,int y,int b, int h,int radius, int layer)
  17. addSector(point center, int radius, double angleStart, double angleStop,int layer)
  18. addText(int layer,point pos, string text)
  19. areaLayer(int layer)
  20. areaSelect()
  21. areaSelected()
  22. boxDeselect()
  23. boxSelectVisible()
  24. cDeselect(rect select)
  25. cellName
  26. chamferSelect(double value,int type,int angleInt)
  27. circumferenceSelect()
  28. circumferenceSelected()
  29. clearProperties()
  30. closeToPolygon()
  31. closeToPolygonSelect()
  32. compare(cell* Cell)
  33. convertToPolygonIfClosed()
  34. convertToPolygonIfClosedSelect()
  35. copy()
  36. copySelect(point p)
  37. countSelectCellref()
  38. countSelectCellrefarray()
  39. countSelectBox()
  40. countSelectPath()
  41. countSelectPoints()
  42. countSelectPolygon()
  43. countSelectText()
  44. cropSharpAnglesSelect(int i)
  45. cropWithSelection()
  46. cSelect(rect select)
  47. cutSelect(point p1, point p2)
  48. deleteElement(element *e)
  49. deleteLayer(int layer)
  50. deleteRefs(cell *c)
  51. deleteSelect()
  52. depend(cell *Cell)
  53. deselectAll()
  54. deselectLabeledShapesOnLayer(int layerText,string label, int layerShape=-1)
  55. deselectLayer(int layer)
  56. deselectNodeOnLayer(int node,int layer)
  57. deselectNode(int node)
  58. deselectShapeWithArea(double min,double max)
  59. deselectText(string text,int layer=-1)
  60. detachHolesSelect(int outlineLayer, int holeLayer)
  61. edgeRemoveSelect(int i)
  62. fAllDeselect(rect select)
  63. fAllSelect(rect select)
  64. fDeselectLayer(rect select, int layer)
  65. fDeselect(rect select)
  66. filletRoundSelect(double value,int type,int angleInt)
  67. filletRoundBezier(double value,int type,int angleInt)
  68. firstElement
  69. flatAllSelect()
  70. flatCellrefArray()
  71. flatLayer(int layer)
  72. flatAllLayer(int layer)
  73. flatSelect()
  74. fSelectLayer(rect select, int layer)
  75. fSelect(rect select)
  76. fractureBoxSelect(int maxSize)
  77. fractureLineSelect(int lineWidth, int overlap=0, bool keepSmallShapes=false)
  78. fractureTrapezoidSelect(int maxSize)
  79. fractureTriangleSelect(int maxSize)
  80. getDensityLayer(int layer,bool merge)
  81. getDensityLayer(int layer, point pos, int sizeX, int sizeY, int stepX, int stepY, int nx, int ny)
  82. groupStructure(cell *cell_)
  83. group(cell *cell_)
  84. identical(cell *Cell)
  85. incircleSelect(int layer)
  86. invertSelect()
  87. mapLayer(layerTranslator *t)
  88. maximum(point *pos)
  89. maximumSelect(point *pos)
  90. maximum()
  91. maximumSelect()
  92. mergeSelect()
  93. minimum(point *pos)
  94. minimumSelect(point *pos)
  95. minimum()
  96. minimumSelect()
  97. minkowskiSumSelect(pointArray polygon)
  98. mirrorSelect(point p1,point p2)
  99. modifyCornersSelect(double value1,double value2)
  100. move(point pos)
  101. moveSelect(point pos)
  102. moveToLayerSelect(int layer)
  103. nearestElement(point p)
  104. pDeselect(rect select)
  105. pSelect(rect select)
  106. pathDeselect()
  107. pathSelectVisible()
  108. polygonDeselect()
  109. polygonSelectVisible()
  110. punchWithSelection()
  111. relinkSelect(cell *Cellnew)
  112. relink(cell *Cellold,cell *Cellnew)
  113. replaceText(string text1,string text2)
  114. resize(double scale)
  115. rotateSelect(double angle,point pos)
  116. roundSelect(int i)
  117. scaleSelect(point origin,double scale)
  118. scaleSelect(point p1,point p2,point p3)
  119. selectAll()
  120. selectCellref(string cellname)
  121. selectDatatype(int i)
  122. selectedElement(element *e=NULL)
  123. selectLabeledShapesOnLayer(int layerText,string label, int layerShape=-1)
  124. selectLayer(int layer)
  125. selectNodeOnLayer(int node,int layer)
  126. selectNode(int node)
  127. selectShapeWithArea(double min,double max)
  128. selectText(string text, int layer=-1)
  129. selectTouchingOrOverlapping(element *)
  130. selectTouchingOrOverlapping(pointArray pa)
  131. selectTouchingOrOverlapping(rect)
  132. selectVisible()
  133. setCapSelect(int w)
  134. setDatatypeSelect(int i)
  135. setWidthSelect(int w)
  136. sizeAdjustSelect(int value,int type)
  137. sizeAdjustSelect(int valueX, int valueY,int type)
  138. slotSelect(int slotWidth, int minSlotLength, int maxSlotLength, int edgeSpacing, int minSlotspacing )
  139. snapShapeSelect(int i)
  140. stripIdenticalElements()
  141. swapLayerSelect(int i,int k)
  142. swapLayer(int i,int k)
  143. textDeselect()
  144. textSelectVisible()
  145. textToPolygon(int defaultWidth)
  146. toBox()
  147. toBoxSelect()
  148. toCircleSelect()
  149. toLines()
  150. toLinesSelect()
  151. toMeshSelect(int width,int spaceing)
  152. toPolygon()
  153. toPolygonSelect()
  154. toPath()
  155. toPathSelect()
  156. triangulateSelect(int layer)
  157. useCell(cell *Cell)
  158. sizeadjustSelect(int value)
  159. sizeadjustSelect(int valueX, int valueY)

Detailed Description

This class represents a single cell. Most important data will be firstElement that is a linked list of all elements of this cell nad can be used to step though all elements.

   1        cell *myCell=layout->drawing->currentCell;
   2        elementList *el= myCell->firstElement;
   3        // loop over all elements
   4        while (el!=NULL) {
   5            if (el->thisElement!=NULL) {
   6               if ( el->thisElement->isPath() ){
   7               // ...
   8               }
   9            }
  10          el=el->nextElement;
  11        }

Member Function Documentation

element* cell::addBox(int x,int y,int b, int h,int layer)

A box is added to this cell. The box is defined by one of the corner points and the width and the height. For positive width and height the point will be the lower left corner of the box.

Parameter:

x

X value of the anchor point

y

Y value of the anchor point

b

width of the box

h

width of the box

layer

the number of the layer the new box is added to

Returns: a pointer to the new element is returned.

element* cell::addBox(pointArray points,int layer)

A box is added to this cell. The box is defined by an array of 5 points. The first and the last point have to be the same. If the box is rotated, a polygon is added instead of a box.

Parameter:

points

An array of 5 points.

layer

the layer number which will be used for the box.

Returns: a pointer to the new element is returned.

element* cell::addCellrefArray(cell *c,pointArray array,int nx,int ny)

A cell-reference-array is added to this cell.

Parameter:

c

a pointer to the cell to be referred

array

A pointArray with three points defining the position of the array. The first coordinate is the array reference point (origin point). The second coordinate locates a position that is displaced from the reference point by the inter-column spacing times the number of columns. The third coordinate locates a position that is displaced from the reference point by the inter-row spacing times the number of rows. That means the spacing will be calculated like: space_x=(array.point(1)-array.point(0))/anzx; space_y=(array.point(2)-array.point(0))/anzy;

nx

number of entries in the X-axis

ny

number of entries in the X-axis

Returns: a pointer to the new element is returned.

element* cell::addCellrefArray(cell *c,point pos1,point pos2,int nx,int ny)

A cell-reference-array is added to this cell.

Parameter:

c

a pointer to the cell to be referred

pos1

is the array reference point (origin point)

pos2

will define x and y spacing. The x-value will be the x-spacing and the y-value will be the y-spacing. So only vertical and horizontal spacing is possible

nx

number of entries in the X-axis

ny

number of entries in the X-axis

Returns: a pointer to the new element is returned.

element* cell::addCellref(cell *c,point pos)

A cell-reference is added to this cell.

Parameter:

c

a pointer to the cell to be referred

pos

is the array reference point (origin point)

Returns: a pointer to the new element is returned.

element* cell::addChamferedBox(int x,int y,int b, int h,int chamfer, int layer)

Adds a chamfered box to the cell. x, y, b, h is identical to the addBox method. chamfer is the retraction in x or y for each corner. So the length of the chamfer will be sqrt(2)*chamfer. The resulting shape is a polygon (introduced with version 20130307)

element* cell::addCircleBox(point p1, point p2,int layer)

A circle is added to this cell. p1 and p2 are the edges of the bounding box of the circle. If the dimension in one direction is smaller, the circle is place in the centre of the box with the lower diameter. The circle resolution is used from the setup.

element* cell::addCircle(int layer,point center,int radius, int numPoints=0)

A circle is added to this cell. The default circle resolution fron the setup is used, if numPoints is equal 0. (numPoints was introduced with version 20130309)

element* cell::addCircle(int layer,point center,point circlePoint, int numPoints=0)

Adds a circle to the cell. The circle is defined by its center and a point an the radius. The default circle resolution from the setup is used, if numPoints is equal 0. (the numPoints option was introduced with version 20130309)

void cell::addCornerAreaSelect(double value1,double value2,int angleInt)

All corners of selected elements will be modified. A addition area will be added/substracted in the corner region. The amount of the area will be calculation in dependence with the corner angles. sharp corner will add more area than small angles. The first parameter will give the square of amount for a 90° angle. The second parameter will modify the shape of the added area. angleInt will limit the modification on some angles (positive/negative, sharp angle). 0 will modify all angles.

element* cell::addEllipse(int layer,point center,int rx,int ry)

A ellipse is added to this cell.

element* cell::addPath(pointArray points,int layer)

A path is added to this cell. The default path width from the setup is used. A pointer to the new created element is returned.

element* cell::addPath(pointArray points,int layer,int width)

A path with a defined width is added to this cell. A pointer to the new created element is returned. (introduced with version 20140325)

element* cell::addPolygon(pointArray points,int layer)

A polygon is added to this cell.

element* cell::addPolygonArc(point center, int radiusInner, int radiusOuter, double angleStart, double angleStop,int layer)

Adds a polygon arc to the cell. The resulting shape is a polygon (introduced with version 20130307)

element* cell::addRoundedBox(int x,int y,int b, int h,int radius, int layer)

A rectangular polygon with rounded corners is added to this cell. The polygon is defined by one of the corner points and the width and the height. For positive width and height the point will be the lower left corner of the box.

Parameter:

x

X value of the anchor point.

y

Y value of the anchor point.

b

width of the box.

h

width of the box.

radius

radius of the corners

layer

the layer number which will be used for the box.

Returns: a pointer to the new element is returned.

element* cell::addSector(point center, int radius, double angleStart, double angleStop,int layer)

Adds a sector to the cell. The resulting shape is a polygon (introduced with version 20130307)

element* cell::addText(int layer,point pos, string text)

A text is added to this cell.

double cell::areaLayer(int layer)

Returns: a area of all shapes on layer including overlaps and area on layer in referred cells. (introduced with version 20130408)

double cell::areaSelect()

The area of all selected elements is calculated.

double cell::areaSelected()

The area of all elements is calculated.

void cell::boxDeselect()

All boxes are deselected.

void cell::boxSelectVisible()

All visible boxes are selected.

void cell::cDeselect(rect select)

Deselects a cell, if the base point is in the rect.

string cell::cellName

The name of this cell.

void cell::chamferSelect(double value,int type,int angleInt)

Corners in selected shapes will get a chamfer. type specifies the how the value is defined. angleInt will limit the modification on some angles (positive/negative, sharp angle). 0 will modify all angles.

double cell::circumferenceSelect()

The circumference of all selected elements is calculated.

double cell::circumferenceSelected()

The circumference of all elements is calculated.

void cell::clearProperties()

All properties in this cell are removed.

void cell::closeToPolygon()

Closes path elements to a polygon.

void cell::closeToPolygonSelect()

Closes selected path elements to a polygon.

void cell::compare(cell* Cell)

Tests, if this cell is the same as Cell. Non identical elements will be selected in both cells. All other elements will be deselected.

void cell::convertToPolygonIfClosed()

Converts all path elements to polygons, if the first point is identical with the last point..

void cell::convertToPolygonIfClosedSelect()

Converts selected path elements to a polygon, if the first point is identical with the last point.

cell* cell::copy()

Returns: a copy of this cell

void cell::copySelect(point p)

Selected elements are copyed and move by p

Parameter:

p movement

int cell::countSelectCellref()

Returns: number of selected cellrefs (introduced with version 20141017)

int cell::countSelectCellrefarray()

Returns: number of selected cellrefarrays (introduced with version 20141017)

int cell::countSelectBox()

Returns: number of selected boxes (introduced with version 20141017)

int cell::countSelectPath()

Returns: number of selected paths (introduced with version 20141017)

int cell::countSelectPoints()

Returns: number of selected points in not completely selected shapes (introduced with version 20141017)

int cell::countSelectPolygon()

Returns: number of selected polygons (introduced with version 20141017)

int cell::countSelectText()

Returns: number of selected text (introduced with version 20141017)

void cell::cropSharpAnglesSelect(int i)

Angles smaler than 90° are removed by inserting additional points

void cell::cropWithSelection()

Selected elements are used to crop the complete cell.

void cell::cSelect(rect select)

Selects a cell, if the base point is in the rect.

void cell::cutSelect(point p1, point p2)

Cut selected elements between p1 and p2.

void cell::deleteElement(element *e)

Delete the element e.

void cell::deleteLayer(int layer)

All shapes on layer in this cell will be deleted. (introduced with version 20120824)

void cell::deleteRefs(cell *c)

Cellrefs and cellrefarrays on the cell c are deleted.

Parameter:

*c cell

void cell::deleteSelect()

Selected element are deleted.

bool cell::depend(cell *Cell)

Returns: true if this cell or its cellrefs has a cellref to cell.

void cell::deselectAll()

All elements are deselected.

void cell::deselectLabeledShapesOnLayer(int layerText,string label, int layerShape=-1)

All shapes (polygons, pathes, boxes) on layerShape having a touching element with the text label on layerText are deselected. If label is an empty string all labeled shapes on layerShape are deselected. If layerShape is not given, shapes on layerText are deselected. (introduced with version 20130201, the optional parameter layerShape was added with verison 20131212)

void cell::deselectLayer(int layer)

All elements on layer are deselected.

void cell::deselectNodeOnLayer(int node,int layer)

All elements on layer connected with node are deselected

void cell::deselectNode(int node)

All elements connected with node are deselected.

void cell::deselectShapeWithArea(double min,double max)

All shapes with an surface area between min and max are deselected. (introduced with version 20170108)

void cell::deselectText(string text,int layer=-1)

All text elements with text are deselected. If the optional parameter layer is used, only text on that layer will be deselected. The layer parameter was indroduced with version 20140319.

void cell::detachHolesSelect(int outlineLayer, int holeLayer)

Selected polygons will be decomposed. The outline will be copied on the outlineLayer. Holes will be copied on the holeLayer. The original shapes will be deselected. If outlineLayer or holeLayer is negative, the corresponding shape will not be created.

(introduced with version 20131221)

void cell::edgeRemoveSelect(int i)

Edges smaller than i are removed.

void cell::fAllDeselect(rect select)

Deselects a complete element, if all points are inside rect.

void cell::fAllSelect(rect select)

Selects a complete element, if all points are inside rect.

void cell::fDeselectLayer(rect select, int layer)

Deselects a complete element, if one point is inside rect and it is on layer

void cell::fDeselect(rect select)

Deselects a complete element, if one point is inside rect.

void cell::filletRoundSelect(double value,int type,int angleInt)

Corners in selected shapes will be rounded. type specifies the how the value is defined. angleInt will limit the modification on some angles (positive/negative, sharp angle). 0 will modify all angles.

void cell::filletRoundBezier(double value,int type,int angleInt)

Corners in selected shapes will get a bezier shape. type specifies the how the value is defined. angleInt will limit the modification on some angles (positive/negative, sharp angle). 0 will modify all angles.

elementList* cell::firstElement

This is a list of all elements in this cell.

void cell::flatAllSelect()

Selected cellrefs and cellrefarrays are flatten. If the the cellrefs contain more cellrefs, they are flatten as well.

void cell::flatCellrefArray()

all cellrefarrays are flatten.

void cell::flatLayer(int layer)

All element on layer are flatten from the first hierarchie leel. They are not removed in the cell reference and double exists afterwards (in the cell and in the cell reference).

void cell::flatAllLayer(int layer)

All element on layer are flatten in all hierarchie levels. They are not removed in the cell reference and double exists afterwards (in the cell and in all cell references).

(introduced with version 20130301)

void cell::flatSelect()

Selected cellrefs and cellrefarrays are flatten.

void cell::fSelectLayer(rect select, int layer)

Selects a complete element, if one point is inside rect and it is on layer

void cell::fSelect(rect select)

Selects a complete element, if one point is inside rect.

void cell::fractureBoxSelect(int maxSize)

splits selected shapes into retangular boxes with a maximal size of maxSize. Boxes can overlap and may be non orthogonal to the axis. (introduced with version 20120824)

void cell::fractureLineSelect(int lineWidth, int overlap=0, bool keepSmallShapes=false)

splits selected shapes into lines with a exact size of lineWidth. Lines can overlap and may be non orthogonal to the axis. (introduced with version 20141128) The optional overlap parameter defines a minimum overlap of the lines. The overlap parameter was introduced with version 20141206. if the optional keepSmallShapes parameter is true, no shapes will be deleted in the case it is smaller than the lines width. Instead these shapes will be scale so that it can be fractured. The keepSmallShapes parameter was introduced with version 20150129.

void cell::fractureTrapezoidSelect(int maxSize)

splits selected shapes into trapezoid with a maximal hight of maxSize. (introduced with version 20120824)

void cell::fractureTriangleSelect(int maxSize)

splits selected shapes into triangles with a maximal edge length of maxSize. (introduced with version 20120824)

double cell::getDensityLayer(int layer,bool merge)

Returns: the density of the given layer. 1 mean that all shapes on the layer have together the same area than the bounding box of the cell. If merge is true, overlapping area will only be counted once. (introduced with version 20130902)

doubleList cell::getDensityLayer(int layer, point pos, int sizeX, int sizeY, int stepX, int stepY, int nx, int ny)

The layer density is calculted. The density in squares of the size sizeXxsizeY is calculated. For a complete fill square 1 is returned. Overlapping area is calculated double. (introduced with version 20130714)

   1 int nx=4,ny=4, spaceX=1000, spaceY=1000, sizeX=500,sizeY=500;
   2 doubleList a=layout->drawing->currentCell->getDensityLayer(1,p,sizeX,sizeY,spaceX,spaceY,nx,ny);
   3 debug->clear();
   4 int x,y;
   5 for (x=0; x < nx;x++){
   6   for (y=0; y < ny;y++){
   7       debug(a.at(x*ny+y));
   8       }
   9     }
  10 debug->show();

int cell::groupStructure(cell *cell_)

Searchs structures identical to cell_ and replace it with a cellref to this cell. The number of replaced structures is returned.

void cell::group(cell *cell_)

Selected elements are moved to cell_

bool cell::identical(cell *Cell)

Returns: true if this cell is identical to Cell; Non identical elements will be selected.

void cell::incircleSelect(int layer)

adds a circle inside any selected shapes with the maximum possible radius without intersection any edge of the selected shape. As the result the centre of circle is located at the pole of inaccessibility. The circles are added to layer. (introduced with version 20170429)

void cell::invertSelect()

The selection of this cell is inverted.

void cell::mapLayer(layerTranslator *t)

all elements in this cell are maped with layerTranslator t.

void cell::maximum(point *pos)

The maximum coordinates is returned, if bigger than pos. pos will keep unchanged, if the design does not contain any element.

void cell::maximumSelect(point *pos)

The maximum coordinates of all selected elements is returned, if less than pos. pos will keep unchanged, if no element is selected.

point cell::maximum()

The maximum coordinates is returned. The maximum possible coordinate is returned, if the design does not contain any element.

(introduced with version 20130120)

point cell::maximumSelect()

The maximum coordinates of all selected elements is returned. The maximum possible coordinate is returned, if the design does not contain any selected element.

(introduced with version 20130120)

void cell::mergeSelect()

Selected elements on the same layer are merged.

void cell::minimum(point *pos)

The minimum coordinates is returned, if less than pos. pos will keep unchanged, if the design does not contain any element.

void cell::minimumSelect(point *pos)

The minimum coordinates of all selected elements is returned, if bigger than pos. pos will keep unchanged, if no element is selected.

point cell::minimum()

The minimum coordinates is returned. The minimum possible coordinate is returned, if the design does not contain any element.

(introduced with version 20130120)

point cell::minimumSelect()

The minimum coordinates of all selected elements is returned. The minimum possible coordinate is returned, if the design does not contain any selected element.

(introduced with version 20130120)

void cell::minkowskiSumSelect(pointArray polygon)

With all selected polygons the Minkowki Sum with polygon will be calulated. Original shapes will be replaced by the sum shapes on the same layer. All shapes will be converted to a polygon by this operation. (introduced with version 20130714)

   1 pointArray pa;
   2 pa.attach(200,200);
   3 pa.attach(100,100);
   4 pa.attach(100,0);
   5 pa.attach(200,200);
   6 layout->drawing->currentCell->minkowskiSumSelect(pa);

void cell::mirrorSelect(point p1,point p2)

Selected elements are mirror at a Line made by p1 and p2. If p1==p2, it is mirrored at this single point.

void cell::modifyCornersSelect(double value1,double value2)

Obsolete, please use addCornerAreaSelect instead!

All corners of selected elements will be modified. A addition area will be added/substracted in the corner region. The amount of the area will be calculation in dependence with the corner angles. sharp corner will add more area than small angles. The first parameter will give the squart of amount for a 90° angle. The second parameter will modify the shape of the added area.

void cell::move(point pos)

All element are moved by pos

void cell::moveSelect(point pos)

Selected element are moved by pos

void cell::moveToLayerSelect(int layer)

Selected elements are moved to the layer

Parameter:

layer new layer

elementList* cell::nearestElement(point p)

Returns: the nearest element to the point p.

void cell::pDeselect(rect select)

Deselects point in the rect.

void cell::pSelect(rect select)

Selects point in the rect.

void cell::pathDeselect()

All path elements are deselected.

void cell::pathSelectVisible()

All visible path elements are selected.

void cell::polygonDeselect()

All polygons are deselected.

void cell::polygonSelectVisible()

All visible polygons are selected.

void cell::punchWithSelection()

All shapes and part of shapes located inside of a selected shapes is remove from the cell. Referred cell are adjust if required.

void cell::relinkSelect(cell *Cellnew)

Selected cellref are relinked to Cellnew.

void cell::relink(cell *Cellold,cell *Cellnew)

Cellreferences to Cellold are relink to Cellnew.

int cell::replaceText(string text1,string text2)

If text element are named text1, it is replaced with text2.

Returns: number of replacements

void cell::resize(double scale)

Multiply all elements with the factor scale. As result this will be a scaling for any basic shape (path, box, polygon, text). On cell references and cell array references only origin point and the spaceing will be multiplied. The magnification will kept untouched. So calling resize on any cell of a design will be a complete scaling of the design. Calling it for a single cell will not. To scale a single cell please use the scale feautre

void cell::rotateSelect(double angle,point pos)

Selected elements are rotated.

Parameter:

angle

angle counterclock

pos

center of rotation

void cell::roundSelect(int i)

Selected elements/point are rounded to a multiply of i.

void cell::scaleSelect(point origin,double scale)

Selected elements are scaled. origin the the point which will no moved. scale is the scaling factor. (introduced with version 20141112)

void cell::scaleSelect(point p1,point p2,point p3)

Selected elements are scaled. p2 is scale to p3.

Parameter:

p1

orgin

p2

old point

p3

new point

void cell::selectAll()

All elements are selected.

void cell::selectCellref(string cellname)

All cellref to cells named cellname are selected

void cell::selectDatatype(int i)

All element with the datatype i are selected.

element * cell::selectedElement(element *e=NULL)

Returns: the first complete selected element after e. If e is NULL, the first selected element in the element list is returned. This method can be used to perform a loop over all selected shapes: (introduced with version 20140319)

   1  cell *c=layout->drawing->currentCell;
   2  int count=0;
   3  element *e=NULL;
   4  do {
   5    e=c->selectedElement(e);
   6    if (e!=NULL) count++;
   7  } while (e!=NULL);
   8  debug(count);
   9  debug.show();

void cell::selectLabeledShapesOnLayer(int layerText,string label, int layerShape=-1)

All shapes (polygons, pathes, boxes) on layerShape having a touching element with the text label on the layerText are selected. If label is an empty string all labeled shapes on layer are selected. If layerShape is not given, shapes on layerText are selected. (introduced with version 20130201, the optional parameter layerShape was added with version 20131212)

void cell::selectLayer(int layer)

All elements on layer are selected.

void cell::selectNodeOnLayer(int node,int layer)

All elements on layer connected with node are selected

void cell::selectNode(int node)

All elements connected with node are selected.

void cell::selectShapeWithArea(double min,double max)

All shapes with an surface area between min and max are selected. (introduced with version 20170108)

void cell::selectText(string text, int layer=-1)

All text elements with text are selected. If the optional parameter layer is used, only text on that layer will be selected. The layer parameter was indroduced with version 20140319.

int cell::selectTouchingOrOverlapping(element *)

int cell::selectTouchingOrOverlapping(pointArray pa)

int cell::selectTouchingOrOverlapping(rect)

Any shape touching or overlapping the given element, pointArray or rect is selected. The number of selected shapes is returned. (introduced with version 20130514)

void cell::selectVisible()

All visible elements are selected.

void cell::setCapSelect(int w)

In selected path elements the caps is set to w. (0 for no cap, 1 for round caps, 2 for square caps)

void cell::setDatatypeSelect(int i)

The datatype of selected element is set to i.

void cell::setWidthSelect(int w)

In selected path and text elements the width is set to w.

void cell::sizeAdjustSelect(int value,int type)

Selected elements grow/shrink with value. With type sizing style can be set. (introduced with version 20170108)

type

style

0

linear edge move

1

rounded corners

2

octagon sizing

3

like 0 with cutting sharp angles corners

void cell::sizeAdjustSelect(int valueX, int valueY,int type)

Selected elements grow/shrink with value. With type sizing style can be set, in the moment only type 0 is supported. (introduced with version 20170108)

void cell::slotSelect(int slotWidth, int minSlotLength, int maxSlotLength, int edgeSpacing, int minSlotspacing )

In selected shapes slots will be added. This is usually used the reduce film stress problems in wide metall layers. (introduced with version 20140110)

See also: InsertSlots

void cell::snapShapeSelect(int i)

Selected elements/point will snap to near elements with a search radius of i.

void cell::stripIdenticalElements()

If a cell contains two identical elements at the same position, it is impossible to see it. This function will detect this and remove one of the element.

void cell::swapLayerSelect(int i,int k)

This function swap the layers i and k of the selected elements in the this cell.

void cell::swapLayer(int i,int k)

This function swap the layers i and k in the this cell.

void cell::textDeselect()

All text elements are deselected.

void cell::textSelectVisible()

All visible text elements are selected.

void cell::textToPolygon(int defaultWidth)

all text elements are converted to polygon. defaultWidth will be used for text element with a scale independent size. If defaultWidth is 0, scale independent text elements are unchanged. This function works on all text elements including non selected text elements.

void cell::toBox()

Converts element to a box element if possible.

void cell::toBoxSelect()

Converts selected element to a box element if possible.

void cell::toCircleSelect()

Converts selected element polygon and box element to a circle. The circle is fitted in all existing points of the element.

void cell::toLines()

Converts all path elements to a path for each segment of the path.

See also: ConvertToLines

void cell::toLinesSelect()

Converts selected path elements to a path for each segment of the path.

See also: ConvertToLines

void cell::toMeshSelect(int width,int spaceing)

Selected elements are converted to a mesh of path elements with the width and spacing.

void cell::toPolygon()

Converts element to a polygon if possible.

void cell::toPolygonSelect()

Converts selected element to a polygon if possible.

void cell::toPath()

Converts element to a pathes with its outline.

void cell::toPathSelect()

Converts selected element to a pathes with its outline.

void cell::triangulateSelect(int layer)

Selected polygon are triangulated. The result is added to layer.

bool cell::useCell(cell *Cell)

Returns: true if this cell has a cell-reference to Cell. otherwise false is returned.

Obsolete Members

void cell::sizeadjustSelect(int value)

Selected elements grow/shrink with value.

OBSOLETE: Please use cell->sizeAdjustSelect(int value,int type=0) instead.

void cell::sizeadjustSelect(int valueX, int valueY)

Selected elements grow/shrink with different values in x and y.

OBSOLETE: Please use cell->sizeAdjustSelect(int valueX, int valueY, int type=0) instead.

See also


CategoryMacroClass


MacroClassCell (last edited 2017-05-08 14:19:48 by JurgenThies)