The current version of VIM (vi improved) does not handle bidirectionality correctly, as does vi.iv. It is therefore necessary to transfer the bi-directional behavior of vi.iv to VIM. This will allow VIM to be used for editing Arabic, Hebrew, Persian, and Urdu.
Habusha, U. and Berry, D.M. ``vi.iv, a Bi-Directional Version of the vi Full-Screen Editor,'' Electronic Publishing, Origination, Dissemination, and Design, 3:2, pp. 65--91, 1990 PDF preprint