Tuesday, July 21, 2015

Porting Drawpile to QML - part 1

Drawpile 1.0 is now out and development of version 2.0 is in progress. One of the milestones for version 2.0 is the Qt Quick based canvas.

In version 1.0, the canvas view is implemented as a customized QGraphicsScene/View. It has worked fairly well (surprisingly well, even) but Qt Quick has some irresistible advantages:

  • OpenGL acceleration
  • Declarative UI markup language! (QML)
  • Much easier to port to mobile platforms

Since I had never used QML before, I decided to start by porting the playback dialog over first to get some practice. I chose this part because the dialog is fairly self contained and could therefore be rewritten without touching much else (yay, low coupling!)