-
Notifications
You must be signed in to change notification settings - Fork 0
[Idea] Individually named pages #197
Description
Currently pages are just numbered. There already was a request to add a feature name pages several years ago (see issue 366) and I think this could be quite useful. Also the UBThumbnailTextItem has already provisions to support an arbitrary label for a page.
Here some thoughts about this idea:
From the user perspective the user should be able to edit the name either in Document mode or in the Board thumbnail sidebar. Editing should be started by a double-click on the name. The label then changes to an editable field. If the user clears this field, then the page number is again used. When the user clicks outside the field, then editing is finished.
Edit: Double-click is not a good idea, as it already jumps from Document mode to Board mode. Think about better ways! What if the caption is editable by default? Let's just provide a two-line text edit field below the pixmap and use the QTextDocument text options to set alignment to centered!
From an implementation perspective: For editing, note that QGraphicsTextItem already has the capability to be editable. To ease handling of the names I propose to embed the name to the image using the QImageWriter::setText() and QImageReader::text() functions. I have verified that this works for the jpg format we're using for the thumbnails. The name is inserted as Comment in the EXIF information for the image.