1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef PPAPI_CPP_PRIVATE_PDF_H_
6 #define PPAPI_CPP_PRIVATE_PDF_H_
10 #include "ppapi/c/private/ppb_pdf.h"
12 struct PP_BrowserFont_Trusted_Description
;
22 // Returns true if the required interface is available.
23 static bool IsAvailable();
25 static Var
GetLocalizedString(const InstanceHandle
& instance
,
26 PP_ResourceString string_id
);
27 static PP_Resource
GetFontFileWithFallback(
28 const InstanceHandle
& instance
,
29 const PP_BrowserFont_Trusted_Description
* description
,
30 PP_PrivateFontCharset charset
);
31 static bool GetFontTableForPrivateFontFile(PP_Resource font_file
,
34 uint32_t* output_length
);
35 static void SearchString(const InstanceHandle
& instance
,
36 const unsigned short* string
,
37 const unsigned short* term
,
39 PP_PrivateFindResult
** results
,
41 static void DidStartLoading(const InstanceHandle
& instance
);
42 static void DidStopLoading(const InstanceHandle
& instance
);
43 static void SetContentRestriction(const InstanceHandle
& instance
,
45 static void UserMetricsRecordAction(const InstanceHandle
& instance
,
47 static void HasUnsupportedFeature(const InstanceHandle
& instance
);
48 static void SaveAs(const InstanceHandle
& instance
);
49 static void Print(const InstanceHandle
& instance
);
50 static bool IsFeatureEnabled(const InstanceHandle
& instance
,
51 PP_PDFFeature feature
);
52 static void SetSelectedText(const InstanceHandle
& instance
,
53 const char* selected_text
);
54 static void SetLinkUnderCursor(const InstanceHandle
& instance
,
56 static void GetV8ExternalSnapshotData(const InstanceHandle
& instance
,
57 const char** natives_data_out
,
58 int* natives_size_out
,
59 const char** snapshot_data_out
,
60 int* snapshot_size_out
);
65 #endif // PPAPI_CPP_PRIVATE_PDF_H_