Improve URI parser (according to RFC 3986)
I don't know if URI parser is implemented in Nautilus/GNOME, but validator is not very user-friendly now.
When paste correct URI, if it contains leading/trailing ASCII whitespace symbols, or URI wrapped within double-quotes "http://example.com/", angle brackets <http://example.com/\>, there is no way to connect to server except to strip string manually.
Parse URL with double quotes ("") or angle brackets (<>). I think it's need to check string by "parts_of_uri" or <parts_of_uri> patterns, and don't allow "parts"_of_uri", <parts_of_uri>>, etc.
Cut leading/trailing ASCII whitespace symbols in string.
- Cut others extra whitespace symbols.
In such cases, it is important to be able to delimit the URI from the rest of the text, and in particular from punctuation marks that might be mistaken for part of the URI.
These wrappers do not form part of the URI.
In some cases, extra whitespace (spaces, line-breaks, tabs, etc.) may have to be added to break a long URI across lines. The whitespace should be ignored when the URI is extracted.