|
Replies:
19
-
Pages:
2
[
1
2
| Next
]
-
Last Post:
14 Jul 25, 16:33
Last Post By: brainpro
|
|
|
Posts:
11
Registered:
20-Jan-2025
|
|
|
|
embedded pdf viewer
Posted:
20 Jan 25, 23:07
|
|
|
|
I'm considering using jAlbum. I want to include some pdf files in amongst images and videos. Is there a way to view the contents of a pdf "in place" in an album? I did a quick test locally and the pdf opened separately in the browser. Perhaps there is a pdf-viewer plugin? I tried to find one, but could not find a complete list of available plugins. Lastly, is this the kind of thing that could be done in a plugin? I am an experienced java developer, perhaps I could give it a shot. Thanks.
|
|
|
Posts:
8,098
Registered:
31-Jan-2006
|
|
|
Posts:
8,098
Registered:
31-Jan-2006
|
|
|
|
Re: embedded pdf viewer
Posted:
21 Jan 25, 00:00
in response to: JeffTucker
|
 |
Helpful |
|
|
I believe that all of the bundled skins show PDF's in the album, not in a new browser window.
Had to double-check that. There are several bundled skins that don't handle this gracefully, to wit, Minimal, Plain, and Zigzag.
|
|
|
Posts:
11
Registered:
20-Jan-2025
|
|
|
|
Re: embedded pdf viewer
Posted:
21 Jan 25, 01:01
in response to: JeffTucker
|
|
|
|
I was originally thinking of something that would work in the "grid" view, but now that I think about it more, I see that is not very practical. The examples you point to are very helpful, thanks.
|
|
|
Posts:
8,098
Registered:
31-Jan-2006
|
|
|
|
Re: embedded pdf viewer
Posted:
21 Jan 25, 01:57
in response to: breisachers
|
|
|
I was originally thinking of something that would work in the "grid" view, but now that I think about it more, I see that is not very practical. The examples you point to are very helpful, thanks.
The "grid" view refers to the layout of the thumbnails. Those are just JPG thumbnails, regardless of what they take the visitor to. An image has a thumbnail, a video has a thumbnail, a PDF has a thumbnail, and so on. But the visitor doesn't see "the real thing" until he clicks on the thumbnail.
|
|
|
Posts:
11
Registered:
20-Jan-2025
|
|
|
|
Re: embedded pdf viewer
Posted:
21 Jan 25, 02:11
in response to: JeffTucker
|
|
|
|
Thanks for the clarification.
|
|
|
Posts:
3,711
Registered:
18-Oct-2002
|
|
|
|
Re: embedded pdf viewer
Posted:
21 Jan 25, 12:17
in response to: breisachers
|
|
|
|
That’s naturally room for improvement. I might put it on the todo to generate thumbnail images of the first page of pdf documents.
|
|
|
Posts:
11
Registered:
20-Jan-2025
|
|
|
|
Re: embedded pdf viewer
Posted:
8 Jun 25, 16:48
in response to: davidekholm
|
|
|
I might put it on the todo to generate thumbnail images of the first page of pdf
I'm a bit surprised this doesn't exist. Is there maybe a plugin for it? Or even something outside of jAlbum? Does anyone know of such a thing?
|
|
|
Posts:
8,098
Registered:
31-Jan-2006
|
|
|
|
Re: embedded pdf viewer
Posted:
8 Jun 25, 17:47
in response to: breisachers
|
|
|
There are plenty of online conversion tools that can convert a PDF into a series of JPG's, one image per page, like this site:
https://convertio.co/
But there probably isn't a Java utility for doing it, which is what jAlbum must have.
|
|
|
Posts:
11
Registered:
20-Jan-2025
|
|
|
|
Re: embedded pdf viewer
Posted:
9 Jun 25, 01:48
in response to: JeffTucker
|
|
|
Actually, there is: https://pdfbox.apache.org/. It includes a command line utility that seems to (basically) work, so I can use it to generate jpg/thm files.
But I'm wondering how difficult this would be to integrate into jAlbum. I am a Java developer -- is this the kind of thing that could be done in a skin? Or in a plugin?
|
|
|
Posts:
3,950
Registered:
4-Aug-2006
|
|
|
|
Re: embedded pdf viewer
Posted:
9 Jun 25, 12:53
in response to: breisachers
|
|
|
|
The easiest way would be to make an external tool to run on a project before making the album. Next would be to make a plugin. Doing it within a skin would not be easy, need the developer to adopt it and would only work, if it did at all, for that skin (or family of skins).
|
|
|
Posts:
3,711
Registered:
18-Oct-2002
|
|
|
|
Re: embedded pdf viewer
Posted:
10 Jun 25, 13:03
in response to: RobM
|
|
|
|
I think we'd need to integrate this functionality within jAlbum itself. I can have a peek at pdfbox. Would it be fine to simply have jAlbum generate a thumbnail image from the 1:st page of a pdf file?
|
|
|
Posts:
3,950
Registered:
4-Aug-2006
|
|
|
|
Re: embedded pdf viewer
Posted:
10 Jun 25, 14:33
in response to: davidekholm
|
|
|
I think we'd need to integrate this functionality within jAlbum itself. I can have a peek at pdfbox. Would it be fine to simply have jAlbum generate a thumbnail image from the 1:st page of a pdf file?
Pdfbox doesn’t seem to be able to generate an image of a page with no images, I might have missed an api call for that but didn’t see anything obvious.
|
|
|
Posts:
11
Registered:
20-Jan-2025
|
|
|
|
Re: embedded pdf viewer
Posted:
10 Jun 25, 15:04
in response to: davidekholm
|
|
|
I can have a peek at pdfbox.
I have a few lines of java code that use pdfbox to generate an image (and rename it to .thm) from the first page of all the pdf files in a directory. I'm happy to 'donate' it to you. It's quite simple.
Would it be fine to simply have jAlbum generate a thumbnail image from the 1:st page of a pdf file?
I think so. See above.
|
|
|
Posts:
8,098
Registered:
31-Jan-2006
|
|
|
|
Re: embedded pdf viewer
Posted:
10 Jun 25, 15:06
in response to: davidekholm
|
|
|
|
|
Would it be fine to simply have jAlbum generate a thumbnail image from the 1:st page of a pdf file?
I suppose that would be better than nothing, but I suspect that in a lot of cases, it wouldn't really be an improvement. A page of text like the attached PDF would yield a thumbnail that was little more than a smudge.
A cleaner mechanism for assigning a representing image to any album object would be preferrable.
|
|
|
|
Legend
|
|
Forum admins
|
|
Helpful Answer
|
|
Correct Answer
|
|