[FTW] Refactor Direct2D code to follow Cairo's model to support modern WebKit