This file is indexed.

/usr/include/cairomm-1.0/cairomm/win32_font.h is in libcairomm-1.0-dev 1.12.2-3.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
/* Copyright (C) 2008 Jonathon Jongsma
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
 * 02110-1301, USA.
 */
#ifndef __CAIROMM_WIN32_FONT_H
#define __CAIROMM_WIN32_FONT_H

#include <cairo-features.h>

#ifdef CAIRO_HAS_WIN32_FONT
#include <cairo-win32.h>
#include <cairomm/fontface.h>
#include <cairomm/scaledfont.h>

namespace Cairo
{

/** Font support for Microsoft Windows.
 *
 * @since 1.8
 */
class Win32FontFace : public FontFace
{
public:

  /** Creates a new font for the Win32 font backend based on a LOGFONT. This
   * font can then be used with Context::set_font_face() or
   * Win32ScaledFont::create().
   *
   * @param logfont A LOGFONTW structure specifying the font to use. The
   * lfHeight, lfWidth, lfOrientation and lfEscapement fields of this structure
   * are ignored.
   *
   * @since 1.8
   */
  static RefPtr<Win32FontFace> create(LOGFONTW* logfont);

  /** Creates a new font for the Win32 font backend based on a HFONT. This font
   * can then be used with Context::set_font_face() or Win32ScaledFont::create().
   *
   * @param font An HFONT structure specifying the font to use.
   *
   * @since 1.8
   */
  static RefPtr<Win32FontFace> create(HFONT font);

  /** Creates a new font for the Win32 font backend based on a LOGFONT. This
   * font can then be used with Context::set_font_face() or
   * Win32ScaledFont::create().
   *
   * @param logfont A LOGFONTW structure specifying the font to use. If hfont is
   * null then the lfHeight, lfWidth, lfOrientation and lfEscapement fields of
   * this structure are ignored. Otherwise lfWidth, lfOrientation and
   * lfEscapement must be zero.
   * @param font An HFONT that can be used when the font matrix is a scale by
   * -lfHeight and the CTM is identity. 
   *
   * @since 1.8
   */
  static RefPtr<Win32FontFace> create(LOGFONTW* logfont, HFONT font);

protected:
  Win32FontFace(LOGFONTW* logfont);
  Win32FontFace(HFONT font);
  Win32FontFace(LOGFONTW* logfont, HFONT font);
};


/** Scaled Font implementation for Microsoft Windows fonts.
 *
 * @since 1.8
 */
class Win32ScaledFont : public ScaledFont
{
public:

  /** Creates a scaled font for the given Win32FontFace.
   *
   * @since 1.8
   */
  static RefPtr<Win32ScaledFont> create(const RefPtr<Win32FontFace>& font_face,
                                        const Matrix& font_matrix,
                                        const Matrix& ctm,
                                        const FontOptions& options = FontOptions());

  /** Selects the font into the given device context and changes the map mode
   * and world transformation of the device context to match that of the font.
   * This function is intended for use when using layout APIs such as Uniscribe
   * to do text layout with the cairo font. After finishing using the device
   * context, you must call done_font() to release any resources allocated by
   * this function.
   *
   * See get_metrics_factor() for converting logical coordinates from the device
   * context to font space.
   *
   * Normally, calls to SaveDC() and RestoreDC() would be made around the use of
   * this function to preserve the original graphics state.
   *
   * @param scaled_font A cairo_scaled_font_t from the Win32 font backend. Such
   * an object can be created with Win32FontFace::create_for_logfontw().
   * @param hdc a device context
   *
   * @since 1.8
   */
  void select_font(HDC hdc);

  /** Releases any resources allocated by select_font()
   *
   * @since 1.8
   */
  void done_font();

  /** Gets a scale factor between logical coordinates in the coordinate space
   * used by select_font() (that is, the coordinate system used by the Windows
   * functions to return metrics) and font space coordinates.
   *
   * @return factor to multiply logical units by to get font space coordinates.
   *
   * @since 1.8
   */
  double get_metrics_factor() const;

  /** Gets the transformation mapping the logical space used by this scaled font
   * to device space.
   *
   * @param logical_to_device matrix to return
   *
   * @since 1.8
   */
  void get_logical_to_device(Matrix& logical_to_device) const;

  /** Gets the transformation mapping device space to the logical space used by
   * this scaled font.
   *
   * @param device_to_logical matrix to return
   *
   * @since 1.8
   */
  void get_device_to_logical(Matrix& device_to_logical) const;

protected:
  Win32ScaledFont(const RefPtr<Win32FontFace>& font_face,
                  const Matrix& font_matrix,
                  const Matrix& ctm,
                  const FontOptions& options = FontOptions());
};

}

#endif // CAIRO_HAS_WIN32_FONT

#endif // __CAIROMM_WIN32_FONT_H