chromium/tools/privacy_budget/font_indexer/font_indexer.h

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

#ifndef TOOLS_PRIVACY_BUDGET_FONT_INDEXER_FONT_INDEXER_H_
#define TOOLS_PRIVACY_BUDGET_FONT_INDEXER_FONT_INDEXER_H_

#include <string>
#include <utility>

#include "base/functional/callback.h"
#include "base/values.h"
#include "third_party/blink/renderer/platform/fonts/font_cache.h"
#include "third_party/blink/renderer/platform/fonts/font_description.h"
#include "third_party/blink/renderer/platform/fonts/font_selection_types.h"
#include "third_party/blink/renderer/platform/wtf/text/wtf_string.h"

namespace privacy_budget {

// Note that in the following constants, we prioritize the more common values as
// we later associate each unique digest with the first set of settings for
// which that digest is found.
extern const std::pair<blink::FontSelectionValue, std::string> kFontWeights[];
extern const std::pair<blink::FontSelectionValue, std::string> kFontWidths[];

// Not as thorough as above, given its rarity and to reduce the speed impact.
extern const std::pair<blink::FontSelectionValue, std::string> kFontSlopes[];

// Following only used if |more_slope_checks_|
extern const std::pair<blink::FontSelectionValue, std::string>
    kAdditionalFontSlopes[];

extern const char kOutputHeader[];
extern const char kOutputSeparator[];

// FontIndexer allows for enumerating all locally installed fonts and computing
// identifiability digests of each typeface.
class FontIndexer {};

}  // namespace privacy_budget

#endif  // TOOLS_PRIVACY_BUDGET_FONT_INDEXER_FONT_INDEXER_H_