SkRect rect = SkRect::MakeLTRB(0, 0, 100, 50); rect.offset(10, 20);
SkRect rect = SkRect::MakeLTRB(50, 50, 100, 100); rect.offset(-20, -30);This will move the rectangle 20 units to the left and 30 units up, resulting in a new rectangle with coordinates (30, 20, 80, 70). Both examples are part of the Skia Graphics Library.