This file is indexed.

/usr/include/unagi/structs.h is in unagi-dev 0.3.4-1ubuntu1.

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
/* -*-mode:c;coding:utf-8; c-basic-offset:2;fill-column:70;c-file-style:"gnu"-*-
 *
 * Copyright (C) 2009 Arnaud "arnau" Fontaine <arnau@mini-dweeb.org>
 *
 * This  program is  free  software: you  can  redistribute it  and/or
 * modify  it under the  terms of  the GNU  General Public  License as
 * published by the Free Software  Foundation, either version 3 of the
 * License, or (at your option) any later version.
 *
 * 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,      see
 *  <http://www.gnu.org/licenses/>.
 */

/** \file
 *  \brief General structures definitions
 */

#ifndef STRUCTS_H
#define STRUCTS_H

#include <xcb/xcb.h>
#include <xcb/xcb_keysyms.h>
#include <xcb/xcb_ewmh.h>
#include <xcb/xfixes.h>

#include <confuse.h>
#include <ev.h>

#include "window.h"
#include "rendering.h"
#include "plugin.h"
#include "atoms.h"
#include "util.h"

/** Hold information related to the X extension */
typedef struct _display_extensions_t
{
  /** The Composite extension information */
  const xcb_query_extension_reply_t *composite;
  /** The XFixes extension information */
  const xcb_query_extension_reply_t *xfixes;
  /** The Damage extension information */
  const xcb_query_extension_reply_t *damage;
  /** The RandR extension information */
  const xcb_query_extension_reply_t *randr;
} display_extensions_t;

/** Repaint interval to 20ms (50Hz) if  it could not have been obtained
    from RandR */
#define DEFAULT_REPAINT_INTERVAL 0.02

/** Minimum value for the repaint interval, 10ms (200Hz), used on
    startup if the refresh rate is too high and when determining the
    repaint interval according to the painting time */
#define MINIMUM_REPAINT_INTERVAL 0.01

/** Global structure holding variables used all across the program */
typedef struct _conf_t
{
  /** libev event loop */
  struct ev_loop *event_loop;
  /** libev I/O watcher on XCB FD, invoked in paint callback to ensure
      that no events have been queued while calling the callback */
  ev_io event_io_watcher;
  /** libev paint timer watcher to be reset according to the painting
      average time */
  ev_timer event_paint_timer_watcher;

  /** The XCB connection structure */
  xcb_connection_t *connection;
  /** The screen number as defined by the protocol */
  int screen_nbr;
  /** The screen information */
  xcb_screen_t *screen;
  /** If the background has been reset */
  bool background_reset;
  /** Maximum painting interval in seconds (from screen refresh rate) */
  float refresh_rate_interval;
  /** Repaint interval computed from the painting time average */
  float repaint_interval;
  /** Sum of all painting times (for calculating the global average) */
  float paint_time_sum;
  /** Numbre of paintings (for calculating the global average) */
  unsigned int paint_counter;
  /** EWMH-related information */
  xcb_ewmh_connection_t ewmh;
  /** The X extensions information */
  display_extensions_t extensions;
  /** The Window specific to the compositing manager */
  xcb_window_t cm_window;
  /** The list of all windows as objects */
  window_t *windows;
  /** Binary Trees used for lookups (The list is still useful for stack order) */
  util_itree_t *windows_itree;
  /** Damaged region which must be repainted */
  xcb_xfixes_region_t damaged;
  /** Confuse configuration file options */
  cfg_t *cfg;
  /** List of KeySyms, only updated when receiving a KeyboardMapping event */
  xcb_key_symbols_t *keysyms;

  /** Hold _NET_SUPPORTED atom */
  struct
  {
    /** _NET_SUPPORTED reply value */
    xcb_ewmh_get_atoms_reply_t value;
    /** _NET_SUPPORTED request cookie */
    xcb_get_property_cookie_t cookie;
    /** Specify whether this property has been set */
    bool initialised;
  } atoms_supported;

  /** Path to the rendering backends directory */
  char *rendering_dir;
  /** dlopen() opaque structure for the rendering backend */
  void *rendering_dlhandle;
  /** */
  rendering_t *rendering;

  /** Path to the effects plugins directory */
  char *plugins_dir;
  /** List of plugins enabled in the configuration file */
  plugin_t *plugins;

  /** Keyboard masks values meaningful on KeyPress/KeyRelease event */
  struct
  {
    uint16_t numlock;
    uint16_t shiftlock;
    uint16_t capslock;
    uint16_t modeswitch;
  } key_masks;

} conf_t;

extern conf_t globalconf;

#endif