View Full Version : Tutorial/Walkthrough system on top of a Qt application

15th August 2014, 16:27
Hi guys,

I wanted to know if someone has ever done something like a tutorial/walkthrough in a Qt application - the type you see in games or complex applications. Basically, what I want is a feature that opens up the first time you open the app and it blacks out the screen except for a the New button and has an text with an arrow pointing to the button saying "Click here to create a new file". Once the user does that, it would enable another part of the screen and thus guide them through step by step. Hope I'm explaining this well enough. Something like this:
I know Qt probably does not have such an in-built system but I am looking for pointers on how to get started. Any tips appriciated. Thanks in advance

15th August 2014, 17:09
I have in fact created something a bit like that for a demo once.

If I remember correctly I created a custom widget that would resize itself to match the size of the thing it was covering, using an event filter.

It would receive "allowed" area via signal and adjust its painting accordingly.
The painting was done using QPainterPath, first adding a rectangle that is the whole area and then adding the "hole". The painter path fill rules would then fill everything that is not the whole with a semi transparent color.

I think mouse events need to be received and forward to the actual window as well, but I am a bit fuzzy on that, been quite a while :)


19th August 2014, 00:55
It sounds to me like the OP means a "wizard" of some sort maybe. Have a look at QWizard, maybe that has the basis of what you need. You could connect to the currentIdChanged() signal to implement the progressive enabling of the UI you refer to. Wizards are QDialog-based, so they don't have to be modal.

18th September 2014, 12:48
What about this solution?
(github source link inside)



It seems eyecandy and easy to implement as it is just a widget ;)