Important: Please read the Qt Code of Conduct -

[SOLVED] QTextBrowser anchorClicked() signal ?

  • I have a QTextBrowser for my application and I have set the urls such as

    @textBrowser->append("< href=\>Google</>"); //removed <a> as it was not showining in preview

    and connecting using


    but when i click on the link the achorClicked signal is not called but the links opens in the browser, what am i doing wrong ?

  • bq. Note that the browser will automatically handle navigation to the location specified by link unless the openLinks property is set to false or you call setSource() in a slot connected. This mechanism is used to override the default navigation features of the browser.

  • Thanks Lucas ,

    I didnt check that, I used setOpenLinks(false) and works perfect.

Log in to reply