Skip to content

Commit

Permalink
update version
Browse files Browse the repository at this point in the history
  • Loading branch information
corymickelson committed Apr 8, 2018
1 parent 380d635 commit 70e870b
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 4 deletions.
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ set(CMAKE_VISIBILITY_INLINES_HIDDEN)
#set(CMAKE_CXX_FLAGS "-fsanitize=address")

# set(CMAKE_CXX_FLAGS -fPIC)
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE RELEASE)
endif()
set(CMAKE_CXX_FLAGS_DEBUG "-g")
set(CMAKE_CXX_FLAGS_RELEASE "-O3")
set(NAPI_CPP_EXCEPTIONS "yes")
if (MSVC)
set(PODOFO_LIBRARY "C:\\Users\\micke\\CMakeBuilds\\4c25184c-e5d2-673f-92ce-a630b81f074c\\build\\x86-Release\\src\\Release\\podofo.lib")
Expand Down
5 changes: 3 additions & 2 deletions lib/page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import { IFieldInfo, Field } from './field'
import { Rect } from './rect';
import { Obj } from './object';
import { Annotation, NPDFAnnotationType, NPDFAnnotation } from './annotation';
import { Annotation, NPDFAnnotation } from './annotation';

export interface IPage {
rotation: number
Expand Down Expand Up @@ -102,7 +102,8 @@ export class Page implements IPage {
getMediaBox(): Rect {
const mediaBoxPositions = this._instance.getMediaBox()
const mediaBoxRect = new Rect([mediaBoxPositions.left, mediaBoxPositions.bottom, mediaBoxPositions.width, mediaBoxPositions.height])
return mediaBoxPositions
// return mediaBoxPositions
return mediaBoxRect
}
getBleedBox(): Rect {
const positions = this._instance.getBleedBox()
Expand Down
5 changes: 5 additions & 0 deletions lib/setup.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
export function setup() {
const libSource = `${process.env[ 'LAMBDA_TASK_ROOT' ]}/node_modules/commonpdf_podofo`
process.env[ 'PATH' ] = `${process.env[ 'PATH' ]}:${libSource}`
process.env[ 'LD_LIBRARY_PATH' ] = `${libSource}`
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "nopodofo",
"version": "0.3.0",
"version": "0.3.1",
"description": "Node.js native module bindings for PoDoFo",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion src/doc/Rect.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ namespace NoPoDoFo {
class Rect : public Napi::ObjectWrap<Rect>
{
public:
Rect(const Napi::CallbackInfo& callbackInfo);
explicit Rect(const Napi::CallbackInfo& callbackInfo);
~Rect();
static Napi::FunctionReference constructor;
static void Initialize(Napi::Env& env, Napi::Object& target);
Expand Down
Binary file added test-documents/default_wab.pdf
Binary file not shown.

0 comments on commit 70e870b

Please sign in to comment.