Changeset 778 for cpp/common/2d.h
 Timestamp:
 05/11/18 23:38:10 (2 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

cpp/common/2d.h
r766 r778 62 62 T horizontal() const {return left+right;} 63 63 T vertical() const {return top+bottom;} 64 bool operator==(const XYMargin &other) const {return left==other.left && top==other.top && right==other.right && bottom==other.bottom;} 65 XYMargin normalized() const {return XYMargin(max(left,T(0)),max(top,T(0)),max(right,T(0)),max(bottom,T(0)));} 64 66 }; 65 67 … … 128 130 XYMargin<T> marginTowards(const XYRect &r) const 129 131 { 130 return XYMargin<T>(r.p.x , r.p.y,132 return XYMargin<T>(r.p.xp.x, r.p.yp.y, 131 133 (p.x+size.x)(r.p.x+r.size.x), (p.y+size.y)(r.p.y+r.size.y)); 132 134 }
Note: See TracChangeset
for help on using the changeset viewer.