added method to get the region of a widget from a node