Answer the question
In order to leave comments, you need to log in
How to force the user to read the license agreement?
The idea is this:
There is a QTextBrowser whose source is set to the text of the license agreement. Right after the QTextBrowser is a QCheckBox("I agree to the terms and conditions set forth in the license agreement"). It is necessary to make the checkbox clickable ( "qCheckBoxSampleObject.setEnabled(true)" ) only after the user has read the convention, in other words, move the QSlider inside the QTextBrowser all the way down.
How can this be implemented? What can you get hooked on? Please describe in general terms.
Tried to manipulate via QTextBrowser->verticalScrollBar()->setSliderPosition(QtextBrowser->verticalScrollBar()->maximum()), and directly via QSlider with no success. In my opinion, I read the documentation thoughtfully and carefully, now I'm re-reading it.
Please help. Thank you all in advance!
Answer the question
In order to leave comments, you need to log in
Doesn't it work through SliderChange and slider->maximim == slider->value? Show code.
In general, your approach to reading the license agreement is unreliable.
Obviously, it is better to test the user after he has agreed, and each time it is necessary to change the questions in places, and ideally, create a database of questions so that several new ones appear each time, while blocking the possibility of agreeing with the license text, first for 5 minutes, then by 10 and so on, so that the user is motivated to read the agreement.
UPD: you didn't upload the code, so it's hard to understand what doesn't work for you. The scrollbar has a valueChanged event, and inside this event you already check the current value of the scrollbar and the maximum value, if the maximum value is equal to the current one, then allow the user to go further, if not, do not allow it.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question