Exclude brackets at the end of a URL in LinkifyHTML()

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/20347
This commit is contained in:
wh201906 2025-04-16 00:37:23 +08:00 committed by Seth Hillbrand
parent a3fae053c4
commit 6d2b728fb1
2 changed files with 2 additions and 1 deletions

View File

@ -622,6 +622,7 @@ static void buildKicadAboutBanner( EDA_BASE_FRAME* aParent, ABOUT_APP_INFO& aInf
ADD_DEV( wxT( "Nick Østergaard" ), CONTRIB_DEV );
ADD_DEV( wxT( "木 王" ), CONTRIB_DEV );
ADD_DEV( wxT( "wh201906" ), CONTRIB_DEV );
// The document writers
#define DOC_TEAM _( "Documentation Team" )

View File

@ -667,7 +667,7 @@ wxString RemoveHTMLTags( const wxString& aInput )
wxString LinkifyHTML( wxString aStr )
{
static wxRegEx regex( wxS( "\\b(https?|ftp|file)://([-\\w+&@#/%?=~|!:,.;]*[^.,:;<>\\s\u00b6])" ),
static wxRegEx regex( wxS( "\\b(https?|ftp|file)://([-\\w+&@#/%?=~|!:,.;]*[^.,:;<>\\(\\)\\s\u00b6])" ),
wxRE_ICASE );
regex.ReplaceAll( &aStr, "<a href=\"\\0\">\\0</a>" );