Overview   Project   Class   Tree   Index 
CEF3 C++ API Docs - Version 80.1.4+g8927396+chromium-80.0.3987.149
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

(default)
Typedef cef_referrer_policy_t

   in cef_types.h

Options that can be passed to CefParseJSON.




Details

cef_referrer_policy_t

public typedef enum {///// Parses the input strictly according to RFC 4627. See comments in Chromium's
  // base/json/json_reader.h file for known limitations/deviations from the RFC.
  ///
  JSON_PARSER_RFC = 0,

  ///
  // Allows commas to exist after the last element in structures.
  ///
  JSON_PARSER_ALLOW_TRAILING_COMMAS = 1 << 0,
} cef_json_parser_options_t;

///
// Error codes that can be returned from CefParseJSONAndReturnError.
///
typedef enum {
  JSON_NO_ERROR = 0,
  JSON_INVALID_ESCAPE,
  JSON_SYNTAX_ERROR,
  JSON_UNEXPECTED_TOKEN,
  JSON_TRAILING_COMMA,
  JSON_TOO_MUCH_NESTING,
  JSON_UNEXPECTED_DATA_AFTER_ROOT,
  JSON_UNSUPPORTED_ENCODING,
  JSON_UNQUOTED_DICTIONARY_KEY,
  JSON_PARSE_ERROR_COUNT
} cef_json_parser_error_t;

///
// Options that can be passed to CefWriteJSON.
///
typedef enum {
  ///
  // Default behavior.
  ///
  JSON_WRITER_DEFAULT = 0,

  ///
  // This option instructs the writer that if a Binary value is encountered,
  // the value (and key if within a dictionary) will be omitted from the
  // output, and success will be returned. Otherwise, if a binary value is
  // encountered, failure will be returned.
  ///
  JSON_WRITER_OMIT_BINARY_VALUES = 1 << 0,

  ///
  // This option instructs the writer to write doubles that have no fractional
  // part as a normal integer (i.e., without using exponential notation
  // or appending a '. 0') as long as the value is within the range of a
  // 64-bit int.
  ///
  JSON_WRITER_OMIT_DOUBLE_TYPE_PRESERVATION = 1 << 1,

  ///
  // Return a slightly nicer formatted json string (pads with whitespace to
  // help with readability).
  ///
  JSON_WRITER_PRETTY_PRINT = 1 << 2,
} cef_json_writer_options_t;

///
// Margin type for PDF printing.
///
typedef enum {
  ///
  // Default margins.
  ///
  PDF_PRINT_MARGIN_DEFAULT,

  ///
  // No margins.
  ///
  PDF_PRINT_MARGIN_NONE,

  ///
  // Minimum margins.
  ///
  PDF_PRINT_MARGIN_MINIMUM,

  ///
  // Custom margins using the |margin_*| values from cef_pdf_print_settings_t.
  ///
  PDF_PRINT_MARGIN_CUSTOM,
} cef_pdf_print_margin_type_t;

///
// Structure representing PDF print settings.
///
typedef struct _cef_pdf_print_settings_t {
  ///
  // Page title to display in the header. Only used if |header_footer_enabled|
  // is set to true (1).
  ///
  cef_string_t header_footer_title;

  ///
  // URL to display in the footer. Only used if |header_footer_enabled| is set
  // to true (1).
  ///
  cef_string_t header_footer_url;

  ///
  // Output page size in microns. If either of these values is less than or
  // equal to zero then the default paper size (A4) will be used.
  ///
  int page_width;
  int page_height;

  ///
  // The percentage to scale the PDF by before printing (e.g. 50 is 50%).
  // If this value is less than or equal to zero the default value of 100
  // will be used.
  ///
  int scale_factor;

  ///
  // Margins in millimeters. Only used if |margin_type| is set to
  // PDF_PRINT_MARGIN_CUSTOM.
  ///
  double margin_top;
  double margin_right;
  double margin_bottom;
  double margin_left;

  ///
  // Margin type.
  ///
  cef_pdf_print_margin_type_t margin_type;

  ///
  // Set to true (1) to print headers and footers or false (0) to not print
  // headers and footers.
  ///
  int header_footer_enabled;

  ///
  // Set to true (1) to print the selection only or false (0) to print all.
  ///
  int selection_only;

  ///
  // Set to true (1) for landscape mode or false (0) for portrait mode.
  ///
  int landscape;

  ///
  // Set to true (1) to print background graphics or false (0) to not print
  // background graphics.
  ///
  int backgrounds_enabled;

} cef_pdf_print_settings_t;

///
// Supported UI scale factors for the platform. SCALE_FACTOR_NONE is used for
// density independent resources such as string, html/js files or an image that
// can be used for any scale factors (such as wallpapers).
///
typedef enum {
  SCALE_FACTOR_NONE = 0,
  SCALE_FACTOR_100P,
  SCALE_FACTOR_125P,
  SCALE_FACTOR_133P,
  SCALE_FACTOR_140P,
  SCALE_FACTOR_150P,
  SCALE_FACTOR_180P,
  SCALE_FACTOR_200P,
  SCALE_FACTOR_250P,
  SCALE_FACTOR_300P,
} cef_scale_factor_t;

///
// Plugin policies supported by CefRequestContextHandler::OnBeforePluginLoad.
///
typedef enum {
  ///
  // Allow the content.
  ///
  PLUGIN_POLICY_ALLOW,

  ///
  // Allow important content and block unimportant content based on heuristics.
  // The user can manually load blocked content.
  ///
  PLUGIN_POLICY_DETECT_IMPORTANT,

  ///
  // Block the content. The user can manually load blocked content.
  ///
  PLUGIN_POLICY_BLOCK,

  ///
  // Disable the content. The user cannot load disabled content.
  ///
  PLUGIN_POLICY_DISABLE,
} cef_plugin_policy_t;

///
// Policy for how the Referrer HTTP header value will be sent during navigation.
// If the `--no-referrers` command-line flag is specified then the policy value
// will be ignored and the Referrer value will never be sent.
// Must be kept synchronized with net::URLRequest::ReferrerPolicy from Chromium.
///
typedef enum {
  ///
  // Clear the referrer header if the header value is HTTPS but the request
  // destination is HTTP. This is the default behavior.
  ///
  REFERRER_POLICY_CLEAR_REFERRER_ON_TRANSITION_FROM_SECURE_TO_INSECURE,
  REFERRER_POLICY_DEFAULT =
      REFERRER_POLICY_CLEAR_REFERRER_ON_TRANSITION_FROM_SECURE_TO_INSECURE,

  ///
  // A slight variant on CLEAR_REFERRER_ON_TRANSITION_FROM_SECURE_TO_INSECURE:
  // If the request destination is HTTP, an HTTPS referrer will be cleared. If
  // the request' s destination is cross- origin with the referrer( but does not// downgrade ), the referrer's granularity will be stripped down to an origin
  // rather than a full URL. Same-origin requests will send the full referrer.
  ///
  REFERRER_POLICY_REDUCE_REFERRER_GRANULARITY_ON_TRANSITION_CROSS_ORIGIN,

  ///
  // Strip the referrer down to an origin when the origin of the referrer is
  // different from the destination' s origin./// REFERRER_POLICY_ORIGIN_ONLY_ON_TRANSITION_CROSS_ORIGIN,///// Never change the referrer./// REFERRER_POLICY_NEVER_CLEAR_REFERRER,///// Strip the referrer down to the origin regardless of the redirect location./// REFERRER_POLICY_ORIGIN,///// Clear the referrer when the request's referrer is cross-origin with the
  // request' s destination./// REFERRER_POLICY_CLEAR_REFERRER_ON_TRANSITION_CROSS_ORIGIN,///// Strip the referrer down to the origin, but clear it entirely if the// referrer value is HTTPS and the destination is HTTP./// REFERRER_POLICY_ORIGIN_CLEAR_ON_TRANSITION_FROM_SECURE_TO_INSECURE,///// Always clear the referrer regardless of the request destination./// REFERRER_POLICY_NO_REFERRER, REFERRER_POLICY_LAST_VALUE = REFERRER_POLICY_NO_REFERRER, } cef_referrer_policy_t;

 Overview   Project   Class   Tree   Index 
CEF3 C++ API Docs - Version 80.1.4+g8927396+chromium-80.0.3987.149
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

Chromium Embedded Framework (CEF) Copyright © 2016 Marshall A. Greenblatt