本文整理汇总了C++中CPDF_PageObject::AsText方法的典型用法代码示例。如果您正苦于以下问题:C++ CPDF_PageObject::AsText方法的具体用法?C++ CPDF_PageObject::AsText怎么用?C++ CPDF_PageObject::AsText使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CPDF_PageObject
的用法示例。
在下文中一共展示了CPDF_PageObject::AsText方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: IsSameAsPreTextObject
bool CPDF_TextPage::IsSameAsPreTextObject(
CPDF_TextObject* pTextObj,
const CPDF_PageObjectList* pObjList,
CPDF_PageObjectList::const_iterator iter) {
int i = 0;
while (i < 5 && iter != pObjList->begin()) {
--iter;
CPDF_PageObject* pOtherObj = iter->get();
if (pOtherObj == pTextObj || !pOtherObj->IsText())
continue;
if (IsSameTextObject(pOtherObj->AsText(), pTextObj))
return true;
++i;
}
return false;
}
示例2: ProcessFormObject
void CPDF_TextPage::ProcessFormObject(CPDF_FormObject* pFormObj,
const CFX_Matrix& formMatrix) {
const CPDF_PageObjectList* pObjectList =
pFormObj->form()->GetPageObjectList();
if (pObjectList->empty())
return;
CFX_Matrix curFormMatrix = pFormObj->form_matrix() * formMatrix;
for (auto it = pObjectList->begin(); it != pObjectList->end(); ++it) {
CPDF_PageObject* pPageObj = it->get();
if (!pPageObj)
continue;
if (pPageObj->IsText())
ProcessTextObject(pPageObj->AsText(), curFormMatrix, pObjectList, it);
else if (pPageObj->IsForm())
ProcessFormObject(pPageObj->AsForm(), curFormMatrix);
}
}
示例3: ProcessObject
void CPDF_TextPage::ProcessObject() {
if (m_pPage->GetPageObjectList()->empty())
return;
m_TextlineDir = FindTextlineFlowOrientation();
const CPDF_PageObjectList* pObjList = m_pPage->GetPageObjectList();
for (auto it = pObjList->begin(); it != pObjList->end(); ++it) {
CPDF_PageObject* pObj = it->get();
if (!pObj)
continue;
CFX_Matrix matrix;
if (pObj->IsText())
ProcessTextObject(pObj->AsText(), matrix, pObjList, it);
else if (pObj->IsForm())
ProcessFormObject(pObj->AsForm(), matrix);
}
for (const auto& obj : m_LineObj)
ProcessTextObject(obj);
m_LineObj.clear();
CloseTempLine();
}