I would like to bind my mouse wheel click to the pan function. I'm not sure how to get the location of the mouse wheel click to the hiPan() function.
hiSetBindKey("Layout" "<Btn2Down>" "hiPan(hiGetCurrentWindow() hiGetCommandPoint())")
The way this would normally be to bind <Btn4Down> to geScroll(nil "n" nil) and <Btn5Down> to geScroll(nil "s" nil) (and maybe the shift<Btn4Down> to a scroll w and e respectively. Not quite a pan, but probably a bit more intuitive.
would do what you're asking, but if you try it, the behaviour is extremely weird! It's the kind of thing that is fine for a single key press, but not sure it makes any sense for a scroll wheel.
Have you considered or tried the mouse gestures (a.k.a."strokes") which can be entered while pressing the right mouse button down and drawing in the Layout or Schematic window? You will need to load a few files to set this up, something like the following should work:
setSkillPath( append( list(prependInstallPath("etc/sted")) getSkillPath()))
Now you can draw with the right mouse button depressed to make stroke shapes or mouse gestures in the Layout window (it can work for Schematic and Symbol too). A straight line to the right or to the left will pan, likewise for a stroke up or down. A "w" shape will do a "window fit" operation and so on. There is an executable, "stroke_editor" (for the IC61x releases, for older releases you might be able to use "sted" instead [excuse the pun]) which can be used to view or (re)define the strokes.
Hope this helps you and anyone else interested in strokes.