Not a direct solution, but because @poire-z worked on this, I can say that doing complex shaping and layout right is not easy

.
We've got pretty solid Hebrew support in KOReader, FWIW (and one active contributor who actually reads it, which is very helpful, hi @yparitcher

).