summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdfview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'fpdfsdk/fpdfview.cpp')
-rw-r--r--fpdfsdk/fpdfview.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/fpdfsdk/fpdfview.cpp b/fpdfsdk/fpdfview.cpp
index aad29462cc..cec44a48f9 100644
--- a/fpdfsdk/fpdfview.cpp
+++ b/fpdfsdk/fpdfview.cpp
@@ -726,6 +726,19 @@ FPDF_EXPORT double FPDF_CALLCONV FPDF_GetPageHeight(FPDF_PAGE page) {
return pPage ? pPage->GetPageHeight() : 0.0;
}
+FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDF_GetPageBoundingBox(FPDF_PAGE page,
+ FS_RECTF* rect) {
+ if (!rect)
+ return false;
+
+ CPDF_Page* pPage = CPDFPageFromFPDFPage(page);
+ if (!pPage)
+ return false;
+
+ FSRECTFFromCFXFloatRect(pPage->GetPageBBox(), rect);
+ return true;
+}
+
#if defined(_WIN32)
namespace {