View Single Post
Old 03-30-2017, 03:55 PM   #6
RbnJrg
Wizard
RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.
 
Posts: 1,827
Karma: 8700631
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
Quote:
Originally Posted by NikaZhenya View Post
What I am trying to solve is that in spanish poetry when a verse is larger that the box's size, it has to be a break and the next line has to be right aligned with a bracket:

Code:
A short verse.
A very very long
         [verse.
I figured out how to make this change. The issue is that when the user changes the font, the calculation has to be done again. I tried to solve this by doing a fixed EPUB, but iBooks and ebook-viewer allow the font increase.

So I was wondering how I can detect that change, I cant catch it with resize listener or inspecting the font size with a timer. So I think it is something related with some sort of scale, but the ways I have found to detect a change in the viewport scale doesnt work either.

The link that you send it seems that have the same issue to detect that kind of change, at least in iBooks and ebook-viewer.
Hi;

The script in the post I sent you, does detect font changes in ADE 4.5 (that supports jscript and epub3). As you know, ADE is the norm regarding epub, so the fact the script works fine there, is a plus. However I couldn't get a way to detect font-size changes in others ereaders, mainly, due to the limitations of suchs ereaders. I'm afraid it'll be very difficult for you to find something to work fine in iOS

El script que te indiqué, puede detectar (de hecho lo hace) cambios en el tamaño de fuente en ADE 4.5 (y si mal no recuerdo, también lo hacía en Calibre). Dado que ADE es el estándar respecto a epubs, el que funcione bien en esa plataforma es una ventaja. Pero veo muy difícil que puedas encontrar algo que funcione bien en iOS; los lectores para esa plataforma tienen muchas limitaciones respecto a javascript

Saludos
Rubén
RbnJrg is offline   Reply With Quote