code: function handle2pan(e){
              var v = {
                x: e.originalEvent.pageX - $panner.offset().left - $panner.width()/2,
                y: e.originalEvent.pageY - $panner.offset().top - $panner.height()/2
              }
  
              var r = options.panDragAreaSize;
              var d = Math.sqrt( v.x*v.x + v.y*v.y );
              var percent = Math.min( d/r, 1 );
  
              if( d < options.panInactiveArea ){
                return {
                  x: NaN,
                  y: NaN
                };
              }
  
              v = {
                x: v.x/d,
                y: v.y/d
              };
  
              percent = Math.max( options.panMinPercentSpeed, percent );
  
              var vnorm = {
                x: -1 * v.x * (percent * options.panDistance),
                y: -1 * v.y * (percent * options.panDistance)
              };
  
              return vnorm;
            }
docs: functions for calculating panning //////////////////////////////////