Advertisement
TankorSmash

Untitled

Aug 14th, 2012
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.62 KB | None | 0 0
  1.             //the size of the entire button
  2.             borderRectangle = buttonSize;
  3.             //the inner portion will be 90 percent the size of the button, leaving a 10 percent border
  4.             double innerW = borderRectangle.Width * .9;
  5.             double innerH = borderRectangle.Height * .9;
  6.             double innerX = borderRectangle.Center.X - (innerW / 2);
  7.             double innerY = borderRectangle.Center.Y - (innerH / 2);
  8.             //it'll be set to having the same center point as the borderRect            
  9.             innerRectangle = new Rectangle((int)innerX, (int)innerY, (int)innerW, (int)innerH );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement