Halliday & Matthiessen (2014: 163-4):
In the selection of the WH- element, the category of Complement can extend to include the minor Complement of a prepositional phrase. Here the WH- element is conflated with the minor Complement of a prepositional phrase serving as a circumstantial Adjunct in the clause. Since the WH- element is thematic, the minor Complement of the prepositional phrase is given the status of Theme, while the minor Predicator appears within the Rheme, in the position the Adjunct has when it is not thematic; for example:
Who were you talking to?