Skip to content

[Feature]: Zoom modes "Content Fit"/"Content Width" #20574

@xieve

Description

@xieve

Is the feature relevant to the Firefox PDF Viewer?

Yes

Feature description

What

Similar to the zoom modes "Page Fit" and "Page Width", I'd like to have modes that zoom to the content of the PDF, automatically cropping (most of) the (typically white) margins.

Why

This would be useful in settings where screen real estate is scarce, eg. when using PDF.js in any sort of split screen/window tiling configuration, on mobile, etc. I know this particular use case is very rare, but I am an Obsidian user who uses it to view PDFs with internal links, and they have hover previews. If those previews were cropped to the content, they would be way more useful.

Alternatives/Workarounds

Currently, I have to zoom in manually, which oftentimes is quite tedious to get just right. The proposed marquee zoom (#1260) would yield an improvement in this use case.

Other PDF viewers

KOReader has this feature, although the scope and usecase of KOReader is quite different to PDF.js (it is primarily meant to run on e-readers). Link to documentation

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions