As a simplification, hyphenation is not performed on words consisting of multiple styles (e.g. "complicated"). This is a rare case, and I therefore skipped implementing it.
If needed, it can be implemented in the current code without needing to overhaul the typesetting algorithm