Viewing multiple documents

Asked by bendikro

Being able to view multiple documents simultaneously is a feature I miss from all the PDF viewers I've tried. Opening each document in a separate instance and aligning the windows gets troublesome with many documents. Also, switching windows with tab makes a mess of it.

One solution would be to have a new class between the current mainwindow and documentview, lets call it splitview. mainwindow would have one instance of splitview which contains one or more documentview objects. The splitview would be able to split multiple times either horizontally or vertically.

Thoughts?

Question information

Language:
English Edit question
Status:
Answered
For:
qpdfview Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Adam Reichold (adamreichold) said :
#1

Hello bendirko,

thanks for sharing your idea! Towards implementing a split view, the main problem I see is making it so that the idea of a current tab stays applicable to the main window, i.e. the split view should implement more or less the same interface as the document view does, so that all the assumptions currently made by the main window still hold.
So it might be more elegant to look towards extending the tab widget, so that it can not just handle tabs in a stacked manner but would also be able to merge them into split views (of course, using an appropriate helper widget). In this way, one could keep the document views in a flat list with a current index towards the main window, hence side-stepping the problem of deepening the class hierarchy. The resulting widget would probably be of more general use as well (but also more difficult to implement).
What IMHO is a bit smelly here, is that this would really push qpdfview towards window-manager-like behaviour, but of course tabs are firmly within that category already. So to decide whether the use case merits the additional complexity, one should probably look at a proof-of-concept implementation.

Best regards, Adam.

Revision history for this message
Benjamin Eltzner (b-eltzner) said :
#2

@Adam: The tab-merging idea (if I understand it correctly) sounds really interesting (could be realized in terms of shift + drag & drop).

bendikro: If you whip up a prototype, I will be happy to test it and give feedback.

Revision history for this message
Razi Alavizadeh (srazi) said :
#3

+1 for this.
@Adam: If you think about extending the QTabWidget then maybe you want to see what I done for tabbar of QupZilla [1] it's somethings like Firefox's tabbar (scrollable tabbar+pinned bar) and can be used as a start point (with a little code cleanup).

But I think about a simpler* idea (I didn't read the code of qpdfview, yet :) ) a splitView with just two widget:
1) main tabWidget
2) a clone of main tabWidget

*: The simpler idea will be implemented sooner ;)

[1] https://github.com/QupZilla/qupzilla/blob/master/src/lib/tabwidget/combotabbar.cpp + https://github.com/QupZilla/qupzilla/blob/master/src/lib/tabwidget/tabstackedwidget.cpp

Can you help with this problem?

Provide an answer of your own, or ask bendikro for more information if necessary.

To post a message you must log in.