Originally posted by @mahlzahn in #4 (comment) :
Description
Currently, the content of all pages is read into memory before displaying the first page. Should implement some lazy or at least asynchronous loading of pages.
Idea for asynchronous and retarded loading of pages 2, 3, 4, ...:
- load page 1
- show page 1
- load pages 2, 3, 4 ...
n- may be interrupt by choosing a page
k, then:- load page
k(if not yet loaded) - show page
k - load pages
k+1,k+2, ...
- load page
- may be interrupt by choosing a page
Also, might use multiple CPUs for loading the pages in parallel!
Maybe, also restrict used memory, for too big files.
_Originally posted by @mahlzahn in https://codeberg.org/censor/Censor/issues/4#issue-2791839_:
## Description
Currently, the content of all pages is read into memory before displaying the first page. Should implement some lazy or at least asynchronous loading of pages.
Idea for asynchronous and retarded loading of pages 2, 3, 4, ...:
1. load page 1
2. show page 1
3. load pages 2, 3, 4 ... $n$
- may be interrupt by choosing a page $k,ドル then:
1. load page $k$ (if not yet loaded)
2. show page $k$
3. load pages $k+1,ドル $k+2,ドル ...
Also, might use multiple CPUs for loading the pages in parallel!
Maybe, also restrict used memory, for too big files.