| 813 | } |
| 814 | |
| 815 | db::DBox |
| 816 | LayerPropertiesNode::bbox () const |
| 817 | { |
| 818 | tl_assert (mp_view); |
| 819 | lay::CellView cv = mp_view->cellview (cellview_index ()); |
| 820 | |
| 821 | if (! cv.is_valid ()) { |
| 822 | |
| 823 | return db::DBox (); |
| 824 | |
| 825 | } else if (is_cell_box_layer ()) { |
| 826 | |
| 827 | return overall_bbox (); |
| 828 | |
| 829 | } else { |
| 830 | |
| 831 | db::DBox b; |
| 832 | double dbu = cv->layout ().dbu (); |
| 833 | for (std::vector<db::DCplxTrans>::const_iterator t = trans ().begin (); t != trans ().end (); ++t) { |
| 834 | b += (*t * db::CplxTrans (dbu) * cv.context_trans ()) * cv.cell ()->bbox (layer_index ()); |
| 835 | } |
| 836 | return b; |
| 837 | |
| 838 | } |
| 839 | } |
| 840 | |
| 841 | void |
| 842 | LayerPropertiesNode::attach_view (LayoutViewBase *view, unsigned int list_index) |
nothing calls this directly
no test coverage detected