Enabling the devtools inspector when using Oxide in an Ubuntu SDK QML app

A tiny post for something I’ve just worked out. If you’re using Oxide, the Ubuntu web rendering engine (based on Chrome’s Blink) in an Ubuntu SDK QML app, it’d be useful to have access to the devtools inspector so you can debug it. Well, you can, although this doesn’t seem to be documented anywhere. Adnane “daker” Belmadiaf wrote a useful post describing how to use Oxide in your Ubuntu QML application but unaccountably didn’t explain how to turn on the dev tools1 so this is how to do it.

Give your WebView a WebContext and set its devtoolsEnabled and devtoolsPort properties. That’s it.

import com.canonical.Oxide 1.0
WebView {


    context: WebContext {
        devtoolsEnabled: true
        devtoolsPort: 9232
  1. possibly because you couldn’t when he wrote the post :)
I'm currently available for hire, to help you plan, architect, and build new systems, and for technical writing and articles. You can take a look at some projects I've worked on and some of my writing. If you'd like to talk about your upcoming project, do get in touch.

More in the discussion (powered by webmentions)

  • Chris Coulson responded at twitter.com @sil That's not changed - it should still work. I just checked with webbrowser-app --inspector, which does basically the same thing
  • Stuart Langridge responded at twitter.com @chrisccoulson that's what I thought... but it isn't. Something weird happens on my chosen port, but I can't connect to it :(
  • Chris Coulson responded at twitter.com @sil Interesting. Are you trying to connect from Chrome (and, which version)? Are you connecting from a different device?