diff --git a/Meta/Lagom/Contrib/MacPDF/LagomPDFView.h b/Meta/Lagom/Contrib/MacPDF/LagomPDFView.h index 27ac77c0d5..cf8c08d579 100644 --- a/Meta/Lagom/Contrib/MacPDF/LagomPDFView.h +++ b/Meta/Lagom/Contrib/MacPDF/LagomPDFView.h @@ -7,7 +7,10 @@ #pragma once +// Several AK types conflict with MacOS types. +#define FixedPoint FixedPointMacOS #import +#undef FixedPoint @interface LagomPDFView : NSView { diff --git a/Meta/Lagom/Contrib/MacPDF/LagomPDFView.mm b/Meta/Lagom/Contrib/MacPDF/LagomPDFView.mm index eff269651a..567487bd7c 100644 --- a/Meta/Lagom/Contrib/MacPDF/LagomPDFView.mm +++ b/Meta/Lagom/Contrib/MacPDF/LagomPDFView.mm @@ -7,8 +7,6 @@ #import "LagomPDFView.h" -// #define USING_AK_GLOBALLY 0 - #include #include #include @@ -70,9 +68,7 @@ static NSBitmapImageRep* ns_from_gfx(NonnullRefPtr bitmap_p) auto source_root = DeprecatedString("/Users/thakis/src/serenity"); Gfx::FontDatabase::set_default_fonts_lookup_path(DeprecatedString::formatted("{}/Base/res/fonts", source_root)); - NSLog(@"before file"); - _file = TRY(Core::MappedFile::map("/Users/thakis/src/hack/sample.pdf"sv)); - NSLog(@"got file"); + _file = TRY(Core::MappedFile::map("/Users/thakis/Downloads/pdf_reference_1-7.pdf"sv)); auto document = TRY(PDF::Document::create(_file->bytes())); TRY(document->initialize()); return document;