Numbers aside (and we can live with them not being processed correctly until Bidi is adopted). The question still stands on how to modify the above noted logic/code to redisplay the characters in "rightleft" mode.
Unfortunately, I'm not that familiar with the code to offer a solution (I need to see Arabic examples.... lots of them).
Well, I would suggest downloading our work-in-progress code,
http://www.arabeyes.org/cgi-bin/cvsweb/arabeyes/vim -or- http://www.arabeyes.org/~nadim/vim/vim-shaping.tar.gz