joseph / Monocle

A silky, tactile browser-based ebook JavaScript library.
http://monocle.inventivelabs.com.au
MIT License
743 stars 200 forks source link

Vertical reading, and ebook with different direction #80

Closed siuying closed 12 years ago

siuying commented 12 years ago

I'm working on a chinese ebook with Monocle. For CJK (chinese, japanese, korean) text, we have a tradition of reading from top to down, right to left. Safari support this via css3:

#content {
  -webkit-writing-mode: vertical-rl;
}

the difference can be illustrated with this sample:

http://dev.w3.org/csswg/css3-writing-modes/vert-horiz-comparison.png

It seems Monocle assume only the left screen, aka reading from left to right, top to bottom. The right screen would require support of reading from top to bottom, right to left.

My question is, is it possible to add this feature? I'm new to this project, but if I would like to add this, are there any advise on how should i implement?

Thanks.

joseph commented 12 years ago

You're right that Monocle makes a lot of interface decisions based on the reading direction, so this work would be non-trivial. I believe that @timdream got well down this path in his Monocle fork — that would be a good place to start investigating.

It'd be great to have a contribution for this, but — since many of us working on Monocle aren't familiar with the writing-mode problem domain — a bunch of solid tests would be crucial. Thanks!

timdream commented 12 years ago

Yes, please take my fork.

The fork was a research project for my previous job, therefore it's no longer maintained. I was trying to combine Monocle with taketori.js - a Javascript shim for vertical layout, and it was only successful to a degree as taketori does not detect the boundary to the page area in Monocle well. I think it would be much better with native writing mode support.

siuying commented 12 years ago

Thank you for advice! Will check it out and see if I could make it work.

david-innover commented 11 years ago

Hi Siuying,

We are facing exactly the same reading direction issue with Monocle now. Could you kindly share your solution, if you found any?

Thank you!!