sumatrapdf icon indicating copy to clipboard operation
sumatrapdf copied to clipboard

Further optimize startup time with many documents (incl approach)

Open hpvd opened this issue 9 months ago • 1 comments

Is your feature request related to a problem? Please describe.

Having many documents/tabs open in Sumatra, closing Sumatra and triggering the re-opening of Sumatra via clicking a new pdf in explorer, the time to be visible/usable of this new PDF is far far slower than having no other previously opened PDFs in Sumatra.

There was already a good approach to speed things up https://github.com/sumatrapdfreader/sumatrapdf/issues/1497

but maybe it can be done better...

Describe the solution you'd like Since, at this point of time, the new PDF is probably the most import one (its the one the user would like to see/read/use) -> would it be possible to turn the opening sequence around, so that the new document is completely loaded the very first, as if it is the only one and only then the other tabs (history) are loaded?

Maybe/if needed with this, also the order of tabs could to be turned around to have the newest one on the left, to don’t having to touch the previous open ones, not even to get their file names and build their tabs...

Since not everyone may like this (if tab-order change is involved) maybe a option to select behaviour would help...

Describe alternatives you've considered non, since leaving Sumatra is no option :-)

Additional context User of Sumatra for hundreds of years...

hpvd avatar Feb 13 '25 09:02 hpvd

I have used 3.5.2 and latest pre-release 16779

-> maybe lazy loading is not active when reopening Sumatra with new file?

it was disabled in 3.5.1 and in 16779, in advanced settings it was set default to true, but I could not find this setting in SumatraPDF-settings.txt which opens from the menu, and adding it manually doesn’t make any difference on start up time

see

https://www.sumatrapdfreader.org/docs/Version-history

3.5.1 (2023-10-24) # .... -> disable lazy loading of files when restoring a session

next (3.6) # Changes in pre-release builds: .... -> add LazyLoading advanced setting, defaults to true.

hpvd avatar Feb 13 '25 16:02 hpvd