Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webreader: Double-page support #61

Closed
waz1500 opened this issue Jan 6, 2020 · 10 comments
Closed

Webreader: Double-page support #61

waz1500 opened this issue Jan 6, 2020 · 10 comments
Labels
enhancement New feature or request released

Comments

@waz1500
Copy link

waz1500 commented Jan 6, 2020

Running version which is v0.11.0-master in docker format.

I love the new right to left feature that was implemented in this version.
Would it be possible for komga to support double-page view or at least load up 2 pages side by side?
This would help with content/artwork that's split across 2 images as a double spread.

@gotson gotson changed the title Double-page support Webreader: Double-page support Jan 7, 2020
@gotson
Copy link
Owner

gotson commented Jan 7, 2020

That's a good idea, I have a few questions about the behaviour :

  • should pages move 2 by 2?
  • if yes, and let's say you have a cover (single), then you would see pages 1-2 then 3-4 etc. Wouldn't it make more sense to see 2-3, then 4-5 etc?

@gotson gotson added the enhancement New feature or request label Jan 7, 2020
@waz1500
Copy link
Author

waz1500 commented Jan 7, 2020

Thanks for taking an interest in this idea gotson.

Pages should be moved 2 by 2 except the first page which is usually the cover. This should be the only page that should be shown as just 1.

Then clicking on next page will load up 2 pages and move by 2 pages until the end and if it can't load up 2 pages then just 1 which is usually the credits page.

So yes, it should be 1 and then 2-3, 4-5, 6-7 and then 8 (credits page). I hope this makes sense.

@gotson
Copy link
Owner

gotson commented Jan 7, 2020

I hope this makes sense.

It does :)

@gotson
Copy link
Owner

gotson commented Jan 9, 2020

I tried my best, but i can't get something working that would display the first and last page as single, and the rest as double.

I added an option to display double pages, but the prev/next (click or keyboard) will only move by one page. Hitting the keyboard twice is doable, and that makes things much simpler.

Please test and give me your feedback!

@waz1500
Copy link
Author

waz1500 commented Jan 9, 2020

Thanks for trying! I'm really impressed with your desire to work on every issue. I hope this project remains fun for you!

I can see this issue being a lot more harder and certainly requires a lot more code than I initially thought.

The reason why the first page ( usually the cover often called page 1 or in my content 01) should be shown as a single is because it keeps the visual integrity of the book.
Scanlators will often produce 1:1 rips of a manga including any blank pages because that also helps keep the visual integrity of the book.

When using double-page mode, if the cover is included with any other page then it shifts everything by 1. So with double-spreads the artist deliberately makes something like pages 4 and 5 a double spread but because the cover was included the double spread is going to half on pages 4 and 5 and the second part on pages 6 and 7.

The user may get lucky and things may align right with the cover being included with the main page of the manga. The way I like to approach the idea is the idea of having an actual book in my hands and the cover is always on it's own. Then when you flip the cover, you get the actual main content on 2 pages even though we are reading one page at a time. If its a art based heavy content then the visual integrity remains true and should throughout.

The idea of the last page usually the back of the manga/book being on it's own was to help with this idea of visual integrity. For my content, a lot of it is some artwork or a note from the author of the manga.

I was looking through some of my content and have noticed that some scanlation groups will combine a double-spread as a single image file. In that case your going to get 3 pages worth when double page is enabled. (The double-spread and then another page because double-page mode is enabled)
On the other hand, I feel like most of my content, the scanlators have separated the double spread as single jpeg image files.

I will wait for the next release and do some more testing. At the moment, I'm basing this on the way Lanraragi does its double-pages.

@gotson
Copy link
Owner

gotson commented Jan 9, 2020

You can try the docker beta image, it's released continuously.

At some point I want Komga to analyze images to check the orientation (portrait or landscape), and use that to adjust automatically the display.

@waz1500
Copy link
Author

waz1500 commented Jan 9, 2020

I love how fast you got a working prototype of this feature so relatively quickly.

I don't like how when I click next, it slides across and one image appears twice because of that. I was hoping for something where when I click, it would load up the next 2 pages at once (not one at a time). At the moment it sort of forces the user to read on the left side of the screen for all images in the book and really only utilizing half a viewer's monitor.

Or if they are in fact reading both images, utilizing a viewer's full monitor but then when they click next, they are gonna see the same panel again.

I talk about visual order and correct page naming in my above post. #61 (comment)

At the moment, it's running into problems I thought would happen when the cover is included where 2 pages that should be read as one are split into multiple pages.

Have you tried something like the cover or page 1 always remains in single page mode regardless and then have it switch to double page mode when the user clicks next?

@gotson
Copy link
Owner

gotson commented Jan 10, 2020

Have you tried something like the cover or page 1 always remains in single page mode regardless and then have it switch to double page mode when the user clicks next?

I tried, but faced issues with the underlying carousel, and the layout.

@gotson
Copy link
Owner

gotson commented Jan 10, 2020

I'm in the progress of testing a new carousel to replace the existing one. It should make things easier for the layout management, hopefully I should be able to handle double pages more easily and better.

gotson added a commit that referenced this issue Jan 14, 2020
double pages setting is remembered via cookies (#66)
better double pages management, first and last are shown as single pages, RTL is respected (#61)
jump to previous/next book(closes #64)
gotson added a commit that referenced this issue Jan 14, 2020
double pages setting is remembered via cookies (#66)
better double pages management, first and last are shown as single pages, RTL is respected (#61)
jump to previous/next book(closes #64)
@gotson gotson closed this as completed in 77c9004 Jan 14, 2020
gotson pushed a commit that referenced this issue Jan 14, 2020
# [0.12.0](v0.11.0...v0.12.0) (2020-01-14)

### Bug Fixes

* **scanner:** compare file extensions with case insensitive ([91c9cdd](91c9cdd)), closes [#59](#59)
* **web reader:** conditional webp support ([ad21152](ad21152)), closes [#65](#65)

### Features

* **api:** add endpoints to get previous/next book of a book ([54f583f](54f583f))
* **api:** on-th-fly thumbnail generation for any page ([7167f3e](7167f3e))
* **web reader:** double page support ([77c9004](77c9004)), closes [#61](#61)
* **web reader:** remember fit and rtl ([78c181e](78c181e)), closes [#66](#66)
* **web reader:** thumbnails explorer ([ec06955](ec06955)), closes [#62](#62)
* better management of book analysis errors ([8c26a31](8c26a31))
@gotson
Copy link
Owner

gotson commented Jan 14, 2020

🎉 This issue has been resolved in version 0.12.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 7, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request released
Projects
None yet
Development

No branches or pull requests

2 participants