Update snap.py

added analysis function to determine max window size
added support for a margin that indicates how soon snapping can occur
updated TODO list
snapping left/right now has priority over snapping to top/maximizing