fix #775 popup widget positioning

Allow mixing of absolute and relative positioning for popups.

If a domReference/referenceId is given and an absolutePosition configuration,
then the given absolute positions will overwrite the ones calculated based on the given reference.

Added tests for the new behavior.

Close #792