Feature Request: Option to add bookmarks based on the folder structure #206

Open
opened 2025-02-09 14:43:54 +00:00 by Anangaya · 1 comment

I'm using the following command to create pdf containing all the images of all the chapters of webtoons I want to read. (I then use foxit to read pdfs generated this way even when they become ~2gb in size 😉).

fd -e jpg -e jpeg -e png -0 | sort -V -z | img2pdf -s 7.5in --rotation=ifvalid --from-file - -o ${webtoon_name}.pdf

The issue is that after the pdf is created it's hard to find which images belonged to which chapter as the pdf doesn't contain any information about the original folder structure. And it's not possible to automate recreating the original folder structure from a pdf created this way using a program.

This can be fixed if there is an option to specify multilevel bookmarks based on the folder structure. For my case final bookmark level would be the parent folder of each image.

I'm using the following command to create pdf containing all the images of all the chapters of webtoons I want to read. (I then use foxit to read pdfs generated this way even when they become ~2gb in size 😉). `fd -e jpg -e jpeg -e png -0 | sort -V -z | img2pdf -s 7.5in --rotation=ifvalid --from-file - -o ${webtoon_name}.pdf` The issue is that after the pdf is created it's hard to find which images belonged to which chapter as the pdf doesn't contain any information about the original folder structure. And it's not possible to automate recreating the original folder structure from a pdf created this way using a program. This can be fixed if there is an option to specify multilevel bookmarks based on the folder structure. For my case final bookmark level would be the parent folder of each image.
Owner

I think as a first step, img2pdf would require any sort of support for PDF bookmarks. Patches welcome!

I think as a first step, img2pdf would require any sort of support for PDF bookmarks. Patches welcome!
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: josch/img2pdf#206
No description provided.