I use Qt designer to make an interface and I have an QWebView in it. I would like to reimplement the fonction mouseDoubleClickEvent of my QWebView.
Can I do that? I know I have to use ui->webview to access it, I know I can use the signals easily with on_webView_selectionChanged for example, but what about other methods like mouseDoubleClickEvent?
Since
mouseDoubleCLickEventis a virtual protected function, you will need to subclassQWebViewand re-implement the method in your subclass. The documentation formouseDoubleClickEvent, a method ofQWidget, can be found here. After this, you will probably want to integrate your custom widget with Qt Designer. I am not familiar with the program, but this documentation might prove useful. (Edit: it appears that promoting a custom subclass ofQWebViewrequires additional steps which are documented here and here) I do not know of any pure GUI method for creating the custom subclass you need.