Changeset 13128 in josm for trunk/src/org


Ignore:
Timestamp:
2017-11-19T00:41:36+01:00 (7 years ago)
Author:
Don-vip
Message:

see #15550, see #11217 - better detection of URLs in notes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/layer/NoteLayer.java

    r13126 r13128  
    271271                htmlText = htmlText.replace("&#xA;", "<br>");
    272272                // convert URLs to proper HTML links
    273                 htmlText = htmlText.replaceAll("(https?://\\S+)", "<a href=\"$1\">$1</a>");
     273                htmlText = htmlText.replaceAll("(https?://[^\\s\\(\\)<>]+)", "<a href=\"$1\">$1</a>");
    274274                sb.append(htmlText);
    275275            }
Note: See TracChangeset for help on using the changeset viewer.