chromium/printing/print_job_constants.cc

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "printing/print_job_constants.h"

#include <limits>

#include "build/build_config.h"

namespace printing {

// True if this is the first preview request.
const char kIsFirstRequest[] =;

// Unique ID sent along every preview request.
const char kPreviewRequestID[] =;

// Unique ID to identify a print preview UI.
const char kPreviewUIID[] =;

// If true, tell the printer to print without margins.
const char kSettingBorderless[] =;

// Capabilities option. Contains the capabilities in CDD format.
const char kSettingCapabilities[] =;

// Print job setting 'collate'.
const char kSettingCollate[] =;

// Print out color. Value is an int from ColorModel enum.
const char kSettingColor[] =;

// Default to color on or not.
const char kSettingSetColorAsDefault[] =;

// Key that specifies the height of the content area of the page.
const char kSettingContentHeight[] =;

// Key that specifies the width of the content area of the page.
const char kSettingContentWidth[] =;

// Number of copies.
const char kSettingCopies[] =;

// Device name: Unique printer identifier.
const char kSettingDeviceName[] =;

// Option to disable scaling. True if scaling is disabled else false.
const char kSettingDisableScaling[] =;

// Default DPI
const char kSettingDpiDefault[] =;

// Horizontal DPI
const char kSettingDpiHorizontal[] =;

// Vertical DPI
const char kSettingDpiVertical[] =;

// Print job duplex mode. Value is an int from DuplexMode enum.
const char kSettingDuplexMode[] =;

// Option to print headers and Footers: true if selected, false if not.
const char kSettingHeaderFooterEnabled[] =;

// Interstice or gap between different header footer components. Hardcoded to
// about 0.5cm, match the value in PrintSettings::SetPrinterPrintableArea.
const float kSettingHeaderFooterInterstice =;

// Key that specifies the date of the page that will be printed in the headers
// and footers.
const char kSettingHeaderFooterDate[] =;

// Key that specifies the title of the page that will be printed in the headers
// and footers.
const char kSettingHeaderFooterTitle[] =;

// Key that specifies the URL of the page that will be printed in the headers
// and footers.
const char kSettingHeaderFooterURL[] =;

// Page orientation: true for landscape, false for portrait.
const char kSettingLandscape[] =;

// Key that specifies the requested media size.
const char kSettingMediaSize[] =;

// Key that specifies the requested media height in microns.
const char kSettingMediaSizeHeightMicrons[] =;

// Key that specifies the requested media width in microns.
const char kSettingMediaSizeWidthMicrons[] =;

// Key that specifies the left side of the bounding box for the requested
// media's printable area.
const char kSettingsImageableAreaLeftMicrons[] =;

// Key that specifies the bottom side of the bounding box for the requested
// media's printable area.
const char kSettingsImageableAreaBottomMicrons[] =;

// Key that specifies the right side of the bounding box for the requested
// media's printable area.
const char kSettingsImageableAreaRightMicrons[] =;

// Key that specifies the top side of the bounding box for the requested
// media's printable area.
const char kSettingsImageableAreaTopMicrons[] =;

// Key that specifies the requested media platform specific vendor id.
const char kSettingMediaSizeVendorId[] =;

// Key that specifies whether the requested media is a default one.
const char kSettingMediaSizeIsDefault[] =;

// Key that specifies the requested media type (plain, photo paper, etc.)
const char kSettingMediaType[] =;

// Key that specifies the bottom margin of the page.
const char kSettingMarginBottom[] =;

// Key that specifies the left margin of the page.
const char kSettingMarginLeft[] =;

// Key that specifies the right margin of the page.
const char kSettingMarginRight[] =;

// Key that specifies the top margin of the page.
const char kSettingMarginTop[] =;

// Key that specifies the dictionary of custom margins as set by the user.
const char kSettingMarginsCustom[] =;

// Key that specifies the type of margins to use.  Value is an int from the
// MarginType enum.
const char kSettingMarginsType[] =;

// Number of pages to print.
const char kSettingPreviewPageCount[] =;

// A page range.
const char kSettingPageRange[] =;

// The first page of a page range. (1-based)
const char kSettingPageRangeFrom[] =;

// The last page of a page range. (1-based)
const char kSettingPageRangeTo[] =;

// Page size of document to print.
const char kSettingPageWidth[] =;
const char kSettingPageHeight[] =;

// PIN code entered by the user.
const char kSettingPinValue[] =;

// Policies affecting printing destination.
const char kSettingPolicies[] =;

// Whether the source page content is from ARC or not.
const char kSettingPreviewIsFromArc[] =;

// Whether the source page content is modifiable. True for web content.
// i.e. Anything from Blink. False for everything else. e.g. PDF/Flash.
const char kSettingPreviewModifiable[] =;

// Keys that specifies the printable area details.
const char kSettingPrintableAreaX[] =;
const char kSettingPrintableAreaY[] =;
const char kSettingPrintableAreaWidth[] =;
const char kSettingPrintableAreaHeight[] =;

// Printer description.
const char kSettingPrinterDescription[] =;

// Printer name.
const char kSettingPrinterName[] =;

// Additional printer options.
const char kSettingPrinterOptions[] =;

// The printer type is an enum PrinterType.
const char kSettingPrinterType[] =;

// Print to Google Drive option: true if selected, false if not.
const char kSettingPrintToGoogleDrive[] =;

// Scaling factor
const char kSettingScaleFactor[] =;

// Scaling type
const char kSettingScalingType[] =;

// Number of pages per sheet.
const char kSettingPagesPerSheet[] =;

// Whether to rasterize the PDF for printing.
const char kSettingRasterizePdf[] =;

// The DPI override to use when rasterize the PDF for printing.
const char kSettingRasterizePdfDpi[] =;

// Ticket option. Contains the ticket in CJT format.
const char kSettingTicket[] =;

// Whether to sent user info to the printer.
const char kSettingSendUserInfo[] =;

// Whether to print CSS backgrounds.
const char kSettingShouldPrintBackgrounds[] =;

// Whether to print selection only.
const char kSettingShouldPrintSelectionOnly[] =;

// Whether to print using the system dialog.
const char kSettingShowSystemDialog[] =;

// Username to be sent to printer.
const char kSettingUsername[] =;

// Advanced settings items.
const char kSettingAdvancedSettings[] =;

// Indices used to represent first preview page and complete preview document.
const int FIRST_PAGE_INDEX =;
const int COMPLETE_PREVIEW_DOCUMENT_INDEX =;

// Whether to show PDF in view provided by OS. Implemented for MacOS only.
const char kSettingOpenPDFInPreview[] =;

const uint32_t kInvalidPageIndex =;
const uint32_t kMaxPageCount =;

#if BUILDFLAG(IS_CHROMEOS)
// If set, contains OAuth token that must be used during communication with the
// printer.
const char kSettingChromeOSAccessOAuthToken[] = "chromeos-access-oauth-token";

// These correspond to IPP 'client-info' attribute and member attributes. If
// set, 'client-info' will be sent in the IPP print job.
const char kSettingIppClientInfo[] = "ipp-client-info";
const char kSettingIppClientName[] = "ipp-client-name";
const char kSettingIppClientPatches[] = "ipp-client-patches";
const char kSettingIppClientStringVersion[] = "ipp-client-string-version";
const char kSettingIppClientType[] = "ipp-client-type";
const char kSettingIppClientVersion[] = "ipp-client-version";

// True if the user selects to print to a different printer than the original
// destination shown when Print Preview opens.
const char kSettingPrinterManuallySelected[] = "printerManuallySelected";

// The printer status reason shown for the selected printer at the time print
// is requested. Only local CrOS printers set printer statuses.
const char kSettingPrinterStatusReason[] = "printerStatusReason";
#endif  // BUILDFLAG(IS_CHROMEOS)

}  // namespace printing