NRectangle::NRectangle(const NPoint &position, const NSize &size) { NPoint *p = (NPoint *)&position; NSize *s = (NSize *)&size; x = p->GetX(); y = p->GetY(); width = s->GetWidth(); height = s->GetHeight(); }
bool NRectangle::Contains(const NPoint &p) { NPoint *pp = (NPoint *)&p; return Contains(pp->GetX(), pp->GetY()); }
GraphicsPatternRadial::GraphicsPatternRadial(const NPoint &a, double radiusa, const NPoint &b, double radiusb) { NPoint *aa = (NPoint *)&a; NPoint *bb = (NPoint *)&b; pattern = cairo_pattern_create_radial(aa->GetX(), aa->GetY(), radiusa, bb->GetX(), bb->GetY(), radiusb); }