This file is indexed.

/usr/include/libgoffice-0.8/goffice/utils/go-geometry.h is in libgoffice-0.8-dev 0.8.17-8.

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
/* vim: set sw=8: -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
 * go-geometry.h : A collection of geometry related functions.
 *
 * Copyright (C) 2005 Emmanuel Pacaud (emmanuel.pacaud@univ-poitiers.fr)
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of version 2 of the GNU General Public
 * License as published by the Free Software Foundation.
 *
 * This program 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 General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301
 * USA
 */

#ifndef GO_GEOMETRY_H
#define GO_GEOMETRY_H

#include <goffice/goffice.h>

G_BEGIN_DECLS

#define GO_GEOMETRY_ANGLE_TOLERANCE 1E-3

typedef enum {
	GO_SIDE_LEFT		= 1 << 0,
	GO_SIDE_RIGHT		= 1 << 1,
	GO_SIDE_LEFT_RIGHT	= 3 << 0,
	GO_SIDE_TOP		= 1 << 2,
	GO_SIDE_BOTTOM		= 1 << 3,
	GO_SIDE_TOP_BOTTOM	= 3 << 2,
	GO_SIDE_AUTO		= 15
} GOGeometrySide;

typedef enum {
	GO_DIRECTION_UP    = 0,
	GO_DIRECTION_DOWN  = 1,
	GO_DIRECTION_LEFT  = 2,
	GO_DIRECTION_RIGHT = 3,
	GO_DIRECTION_NONE  = 4
} GODirection;

typedef enum {
	GO_ROTATE_NONE = 0,
	GO_ROTATE_COUNTERCLOCKWISE = 1,
	GO_ROTATE_UPSIDEDOWN = 2,
	GO_ROTATE_CLOCKWISE = 3,
	GO_ROTATE_FREE = 4
} GOGeometryRotationType;

typedef struct {
        double x,y;     /* Center */
        double w,h;     /* Edges */
        double alpha;   /* Angle from x axis to w edge, in radians */
} GOGeometryOBR;

typedef struct _GogViewAllocation GOGeometryAABR;

void 		go_geometry_cartesian_to_polar 	(double x, double y, double *rho, double *theta);
double 		go_geometry_point_to_segment	(double xp, double yp, double xs, double ys, double w, double h);

void 		go_geometry_AABR_add 		(GOGeometryAABR *aabr0, GOGeometryAABR const *aabr1);
void		go_geometry_OBR_to_AABR 	(GOGeometryOBR const *obr, GOGeometryAABR *aabr);
gboolean 	go_geometry_test_OBR_overlap 	(GOGeometryOBR const *obr0, GOGeometryOBR const *obr1);

GOGeometryRotationType	go_geometry_get_rotation_type	(double alpha);
GOGeometrySide 		go_geometry_calc_label_anchor 	(GOGeometryOBR *obr, double alpha);
GOGeometrySide		go_geometry_calc_label_position	(GOGeometryOBR *obr, double alpha, double offset,
							 GOGeometrySide side, GOGeometrySide anchor);

#define  GO_TYPE_DIRECTION (go_direction_get_type())
GType    go_direction_get_type	    (void) G_GNUC_CONST;
gboolean go_direction_is_horizontal (GODirection d);
gboolean go_direction_is_forward    (GODirection d);
char const *go_direction_get_name   (GODirection d);

G_END_DECLS

#endif /* GO_GEOMETRY_H */