add width()/height() getters
git-svn-id: http://skia.googlecode.com/svn/trunk@226 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
90e764e3d9
commit
086f2896e0
@ -27,6 +27,9 @@ template <typename T> struct SkTSize {
|
||||
void setEmpty() {
|
||||
fWidth = fHeight = 0;
|
||||
}
|
||||
|
||||
T width() const { return fWidth; }
|
||||
T height() const { return fHeight; }
|
||||
|
||||
/** If width or height is < 0, it is set to 0 */
|
||||
void clampNegToZero() {
|
||||
|
Loading…
Reference in New Issue
Block a user