]> www.fi.muni.cz Git - evince.git/blob - NOTES
Massive changes. We now support text selection of pdfs, and not just
[evince.git] / NOTES
1
2 SOME RANDOM COMMENTS:
3 =====================
4
5  * We assume that all documents can be broken down into a linear
6    collection of pages.
7
8  * If a document type doesn't break down in such a way (like web pages)
9    then it's probably not a good fit for this application.
10
11  * Each page has a natural page size in pixels.  This is generally
12    ignored in favor of a scale-to-fit mode, but is occasionally
13    important for backends like the image backend.
14
15  * Each page is not necessarily the same size.
16
17  * We refer to pages by page number.  This number ranges from 1 to
18    document->n_pages.  A page index of -1 means the current set page,
19    and a page index of 0 is not used.
20
21
22 --
23
24 Thoughts on threading:
25
26  * The primary thing we are trying to do is minimize switching pages, as
27    doing so is slow for backends.  Additionally, some operations on the
28    backend are slow, leaving poor interactivity.
29
30 --
31
32 Thoughts on selection:
33
34  * On button_press, we record selection_start, and set in_selection.
35
36  * selection_list must be ordered!!!
37
38  * On motion_notify, we update selection_end and call compute_selection,
39    that keeps an ordered list of the selections.  
40
41  * If any of the selection changes, we notify the pixbuf_cache right
42    away.
43
44  * On button_release, we unset in_selection, and trim all the current
45    pixbufs.
46
47  * If a resize (somehow) occurs, during a selection, we clear
48    in_selection and abort.
49
50  * I'd like to support shift-click to handle extending the selection,
51    but for that to survive resizing, I might need to store the points as
52    doubles, etc.  It should be possible to reconstruct it from the
53    existing EvViewSelection structs, so maybe I don't need it.