Displaying Page Number on a widget
Hi,
I'm working on an application which requires page numbers to be displayed at the bottom corner of the pages. I'm actually using widget, which has QImage filled with, RGB = 255, i.e. a white space, wherein I'm scribbling using QPainter.
Now I want to display page number of each of the pages, since I'm navigating to and fro, while scribbling on the pages. Its a linked list of scribbled pages.
any help in this regard will be appreciated alot.
Thanks
Re: Displaying Page Number on a widget
You could create a container widget with a vertical layout.
You should add in it your canvas widget and just below a QLabel that will display the page number. You could also add two buttons for next/prev page:
< PageNumber >.
Of course, you will need to make some connections: when you change the page also update the label text. You can use the QLabel::setText slot.
Regards