This file is indexed.

/usr/share/ada/adainclude/gtkada/pango-matrix.ads is in libgtkada16.1.0-dev 17.0.2017-2.

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
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
------------------------------------------------------------------------------
--                                                                          --
--      Copyright (C) 1998-2000 E. Briot, J. Brobecker and A. Charlet       --
--                     Copyright (C) 2000-2017, AdaCore                     --
--                                                                          --
-- This library is free software;  you can redistribute it and/or modify it --
-- under terms of the  GNU General Public License  as published by the Free --
-- Software  Foundation;  either version 3,  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 MERCHAN- --
-- TABILITY or FITNESS FOR A PARTICULAR PURPOSE.                            --
--                                                                          --
--                                                                          --
--                                                                          --
--                                                                          --
--                                                                          --
-- You should have received a copy of the GNU General Public License and    --
-- a copy of the GCC Runtime Library Exception along with this program;     --
-- see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see    --
-- <http://www.gnu.org/licenses/>.                                          --
--                                                                          --
------------------------------------------------------------------------------

--  <description>
--  A structure specifying a transformation between user-space coordinates and
--  device coordinates. The transformation is given by
--
--    x_device = x_user * matrix->xx + y_user * matrix->xy + matrix->x0;
--    y_device = x_user * matrix->yx + y_user * matrix->yy + matrix->y0;
--
--  </description>
pragma Ada_2005;

pragma Warnings (Off, "*is already use-visible*");
with Glib; use Glib;

package Pango.Matrix is

   type Pango_Matrix is record
      Xx : Gdouble;
      Xy : Gdouble;
      Yx : Gdouble;
      Yy : Gdouble;
      X0 : Gdouble;
      Y0 : Gdouble;
   end record;
   pragma Convention (C, Pango_Matrix);

   function From_Object_Free (B : access Pango_Matrix) return Pango_Matrix;
   pragma Inline (From_Object_Free);
   --  A structure specifying a transformation between user-space coordinates
   --  and device coordinates. The transformation is given by
   --
   --    x_device = x_user * matrix->xx + y_user * matrix->xy + matrix->x0;
   --    y_device = x_user * matrix->yx + y_user * matrix->yy + matrix->y0;

   ------------------
   -- Constructors --
   ------------------

   function Get_Type return Glib.GType;
   pragma Import (C, Get_Type, "pango_matrix_get_type");

   -------------
   -- Methods --
   -------------

   procedure Concat (Self : Pango_Matrix; New_Matrix : Pango_Matrix);
   pragma Import (C, Concat, "pango_matrix_concat");
   --  Changes the transformation represented by Matrix to be the
   --  transformation given by first applying transformation given by
   --  New_Matrix then applying the original transformation.
   --  Since: gtk+ 1.6
   --  "new_matrix": a Pango.Matrix.Pango_Matrix

   function Copy (Self : Pango_Matrix) return Pango_Matrix;
   pragma Import (C, Copy, "pango_matrix_copy");
   --  Copies a Pango.Matrix.Pango_Matrix.
   --  Since: gtk+ 1.6

   procedure Free (Self : Pango_Matrix);
   pragma Import (C, Free, "pango_matrix_free");
   --  Free a Pango.Matrix.Pango_Matrix created with Pango.Matrix.Copy.
   --  Since: gtk+ 1.6

   function Get_Font_Scale_Factor (Self : Pango_Matrix) return Gdouble;
   pragma Import (C, Get_Font_Scale_Factor, "pango_matrix_get_font_scale_factor");
   --  Returns the scale factor of a matrix on the height of the font. That
   --  is, the scale factor in the direction perpendicular to the vector that
   --  the X coordinate is mapped to.
   --  Since: gtk+ 1.12

   procedure Rotate (Self : in out Pango_Matrix; Degrees : Gdouble);
   pragma Import (C, Rotate, "pango_matrix_rotate");
   --  Changes the transformation represented by Matrix to be the
   --  transformation given by first rotating by Degrees degrees
   --  counter-clockwise then applying the original transformation.
   --  Since: gtk+ 1.6
   --  "degrees": degrees to rotate counter-clockwise

   procedure Scale
      (Self    : in out Pango_Matrix;
       Scale_X : Gdouble;
       Scale_Y : Gdouble);
   pragma Import (C, Scale, "pango_matrix_scale");
   --  Changes the transformation represented by Matrix to be the
   --  transformation given by first scaling by Sx in the X direction and Sy in
   --  the Y direction then applying the original transformation.
   --  Since: gtk+ 1.6
   --  "scale_x": amount to scale by in X direction
   --  "scale_y": amount to scale by in Y direction

   procedure Transform_Distance
      (Self : Pango_Matrix;
       Dx   : in out Gdouble;
       Dy   : in out Gdouble);
   pragma Import (C, Transform_Distance, "pango_matrix_transform_distance");
   --  Transforms the distance vector (Dx,Dy) by Matrix. This is similar to
   --  Pango.Matrix.Transform_Point except that the translation components of
   --  the transformation are ignored. The calculation of the returned vector
   --  is as follows:
   --    dx2 = dx1 * xx + dy1 * xy;
   --    dy2 = dx1 * yx + dy1 * yy;
   --  Affine transformations are position invariant, so the same vector
   --  always transforms to the same vector. If (X1,Y1) transforms to (X2,Y2)
   --  then (X1+Dx1,Y1+Dy1) will transform to (X1+Dx2,Y1+Dy2) for all values of
   --  X1 and X2.
   --  Since: gtk+ 1.16
   --  "dx": in/out X component of a distance vector
   --  "dy": in/out Y component of a distance vector

   procedure Transform_Pixel_Rectangle
      (Self : Pango_Matrix;
       Rect : in out Pango_Rectangle);
   pragma Import (C, Transform_Pixel_Rectangle, "pango_matrix_transform_pixel_rectangle");
   --  First transforms the Rect using Matrix, then calculates the bounding
   --  box of the transformed rectangle. The rectangle should be in device
   --  units (pixels).
   --  This function is useful for example when you want to draw a rotated
   --  Pangolayout to an image buffer, and want to know how large the image
   --  should be and how much you should shift the layout when rendering.
   --  For better accuracy, you should use Pango.Matrix.Transform_Rectangle on
   --  original rectangle in Pango units and convert to pixels afterward using
   --  pango_extents_to_pixels's first argument.
   --  Since: gtk+ 1.16
   --  "rect": in/out bounding box in device units, or null

   procedure Transform_Point
      (Self : Pango_Matrix;
       X    : in out Gdouble;
       Y    : in out Gdouble);
   pragma Import (C, Transform_Point, "pango_matrix_transform_point");
   --  Transforms the point (X, Y) by Matrix.
   --  Since: gtk+ 1.16
   --  "x": in/out X position
   --  "y": in/out Y position

   procedure Transform_Rectangle
      (Self : Pango_Matrix;
       Rect : in out Pango_Rectangle);
   pragma Import (C, Transform_Rectangle, "pango_matrix_transform_rectangle");
   --  First transforms Rect using Matrix, then calculates the bounding box of
   --  the transformed rectangle. The rectangle should be in Pango units.
   --  This function is useful for example when you want to draw a rotated
   --  Pangolayout to an image buffer, and want to know how large the image
   --  should be and how much you should shift the layout when rendering.
   --  If you have a rectangle in device units (pixels), use
   --  Pango.Matrix.Transform_Pixel_Rectangle.
   --  If you have the rectangle in Pango units and want to convert to
   --  transformed pixel bounding box, it is more accurate to transform it
   --  first (using this function) and pass the result to
   --  pango_extents_to_pixels, first argument, for an inclusive rounded
   --  rectangle. However, there are valid reasons that you may want to convert
   --  to pixels first and then transform, for example when the transformed
   --  coordinates may overflow in Pango units (large matrix translation for
   --  example).
   --  Since: gtk+ 1.16
   --  "rect": in/out bounding box in Pango units, or null

   procedure Translate
      (Self : in out Pango_Matrix;
       Tx   : Gdouble;
       Ty   : Gdouble);
   pragma Import (C, Translate, "pango_matrix_translate");
   --  Changes the transformation represented by Matrix to be the
   --  transformation given by first translating by (Tx, Ty) then applying the
   --  original transformation.
   --  Since: gtk+ 1.6
   --  "tx": amount to translate in the X direction
   --  "ty": amount to translate in the Y direction

end Pango.Matrix;