mirror of
https://github.com/pdf2htmlEX/pdf2htmlEX.git
synced 2024-12-22 13:00:08 +00:00
don't mess with draw_ty when we cannot merge the line
This commit is contained in:
parent
188ce4f997
commit
a5757d578b
@ -196,23 +196,28 @@ void HTMLRenderer::check_state_change(GfxState * state)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
double dy = cur_ty + cur_rise - draw_ty;
|
double dy = cur_ty + cur_rise - draw_ty;
|
||||||
draw_ty += dy;
|
|
||||||
|
|
||||||
double tdx = old_ctm[4] - cur_ctm[4] - cur_ctm[2] * dy;
|
double tdx = old_ctm[4] - cur_ctm[4] - cur_ctm[2] * dy;
|
||||||
double tdy = old_ctm[5] - cur_ctm[5] - cur_ctm[3] * dy;
|
double tdy = old_ctm[5] - cur_ctm[5] - cur_ctm[3] * dy;
|
||||||
|
|
||||||
if(_equal(cur_ctm[0] * tdy, cur_ctm[1] * tdx))
|
if(_equal(cur_ctm[0] * tdy, cur_ctm[1] * tdx))
|
||||||
{
|
{
|
||||||
if(abs(cur_ctm[0]) > EPS)
|
if(abs(cur_ctm[0]) > EPS)
|
||||||
|
{
|
||||||
draw_tx += tdx / cur_ctm[0];
|
draw_tx += tdx / cur_ctm[0];
|
||||||
|
draw_ty += dy;
|
||||||
|
}
|
||||||
else if (abs(cur_ctm[1]) > EPS)
|
else if (abs(cur_ctm[1]) > EPS)
|
||||||
|
{
|
||||||
draw_tx += tdy / cur_ctm[1];
|
draw_tx += tdy / cur_ctm[1];
|
||||||
|
draw_ty += dy;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if((abs(tdx) < EPS) && (abs(tdy) < EPS))
|
if((abs(tdx) < EPS) && (abs(tdy) < EPS))
|
||||||
{
|
{
|
||||||
// free
|
// free
|
||||||
draw_tx = cur_tx;
|
draw_tx = cur_tx;
|
||||||
|
draw_ty += dy;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user