Make mate-terminal --tab open a tab when applicable

Hi,

`mate-terminal --tab` should open a tab when all of the following conditions are met:

* The window in which the tab is to be opened is in the current screen.
* The window in which the tab is to be opened is in the current workspace.

Of all open `mate-terminal` windows that fullfil the above criteria, the latest focussed window must be chosen. If none of the above is true, a new window should be opened instead of a tab.

The workspace from which the command is executed is considered the current workspace and passed on to the factory. If there is no existing `mate-terminal` instance running, a new window is created.

The patch is adapted from one that was originally submitted to the GNOME buzilla.

 * [Bug 83203 - Command-line option to make factory open a tab in last-used existing window](https://bugzilla.gnome.org/show_bug.cgi?id=83203)
 * [attachment 209421 from comment 65 of the above bug](https://bug83203.bugzilla-attachments.gnome.org/attachment.cgi?id=209421) (the original `gnome-terminal` patch)

The intended behaviour this patch adds is described in comment 57 of the original bug.

 * <https://bugzilla.gnome.org/show_bug.cgi?id=83203#c57>

This patch applies cleanly to `mate-terminal` 1.7.90 and `:master`, builds correctly, implements the intended behaviour and fixes #45. Go on, merge it and fix a 12 year old bug ;-)