PDF规格VS创建的Acrobat(QuadPoints) [英] PDF Spec vs Acrobat creation (QuadPoints)

查看:232
本文介绍了PDF规格VS创建的Acrobat(QuadPoints)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建在Acrobat一些注释(下划线,高亮,删除,弯弯曲曲的)和我挖掘出QuadPoints阵列渲染。在PDF规范PDF 32000-1:2008说,他们是在逆时针顺序,X1,Y1 - > X2,Y2指定四边形的底

I've created some annotations (Underline, Highlight, Strikeout, Squiggly) in Acrobat and am digging out the QuadPoints array to render with. The pdf spec PDF 32000-1:2008 says they are in counter clockwise order, and x1,y1 -> x2,y2 specifies the base of the quadrilateral.

这应该是这样的:BOTTOMLEFT,BottomRight,TopRight,左上

This should look like: BottomLeft, BottomRight, TopRight, TopLeft

不幸的是,似乎Acrobat中以不同的(和非合规的方式)来创建它们。

Unfortunately, Acrobat seems to create them in a different (and non compliant manner).

这看起来好像顺序为:左上,TopRight,BOTTOMLEFT,BottomRight。

It appears as if the order is: TopLeft, TopRight, BottomLeft, BottomRight.

任何人都有洞察到这一现象?是不是一致?我缺少的东西吗?

Anyone have insight into this phenomenon? Is it consistent? Am I missing something?

推荐答案

我已经写了iOS版PDF批注lib和发现了同样的打击最规范的Acrobat行为。

I've written a PDF annotation lib for iOS and found the same against-the-spec Acrobat behavior.

作为一个位进一步的信息,文本标记注释中还包含一个矩形条目以及在 QuadPoints 项。在矩形项是每规范, [LLX,LLY,URX,URY] 。所以在Acrobat生成文本标记注释,在矩形(LLX,LLY)大约是一样的 QuadPoints (X3 ,Y3):当旋转= 0。进入数字。

As a bit of further info, the Text Markup annotation also contains an Rect entry as well as the QuadPoints entry. The Rect entry is per the spec, [llx, lly, urx, ury]. So in Acrobat generated Text Markup annotations, the Rect point (llx,lly) is approx the same as the QuadPoints point (x3, y3) when rotation=0. Go figure.

有趣,当规范背后的主要公司写道,不遵循规范的软件,它可以被浪费的时间!

Interesting the amount of time that can be wasted when the primary company behind a spec writes software that doesn't follow that spec!

这篇关于PDF规格VS创建的Acrobat(QuadPoints)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆