This file is indexed.

/usr/include/Nux-4.0/Nux/Theme.h is in libnux-4.0-dev 4.0.6+14.04.20140409-0ubuntu1.

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
/*
 * Copyright 2010 Inalogic® Inc.
 *
 * This program is free software: you can redistribute it and/or modify it
 * under the terms of the GNU Lesser General Public License, as
 * published by the  Free Software Foundation; either version 2.1 or 3.0
 * of the License.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranties of
 * MERCHANTABILITY, SATISFACTORY QUALITY or FITNESS FOR A PARTICULAR
 * PURPOSE.  See the applicable version of the GNU Lesser General Public
 * License for more details.
 *
 * You should have received a copy of both the GNU Lesser General Public
 * License along with this program. If not, see <http://www.gnu.org/licenses/>
 *
 * Authored by: Jay Taoko <jaytaoko@inalogic.com>
 *
 */


#ifndef UXTHEME_H
#define UXTHEME_H


namespace nux
{
  enum UXStyleImageRef
  {
    eIMAGE_STYLE_NONE = 0,
    eSTROKE_CORNER_SQUARE,
    eSTROKE_CORNER_ROUND1,
    eSTROKE_CORNER_ROUND2,
    eSTROKE_CORNER_ROUND4,
    eSTROKE_CORNER_ROUND10,

    eSHAPE_CORNER_SQUARE,
    eSHAPE_CORNER_ROUND1,
    eSHAPE_CORNER_ROUND2,
    eSHAPE_CORNER_ROUND4,
    eSHAPE_CORNER_ROUND5,
    eSHAPE_CORNER_ROUND6,
    eSHAPE_CORNER_ROUND10,

    eSHAPE_CORNER_ROUND10_SHADOW,
    eSHAPE_CORNER_ROUND4_SHADOW,
    eSHAPE_CORNER_SHADOW,

    eTRIANGLE_UP,
    eTRIANGLE_DOWN,
    eTRIANGLE_LEFT,
    eTRIANGLE_RIGHT,

    eWINDOW_SIZEGRIP,

    eSHAPE_CHECK_MARK,
    eSHAPE_CHECK_BOX_FOCUS,
    eSHAPE_CHECK_BOX_PRELIGHT,
    eSHAPE_CHECK_BOX,

    eCHECKBOX_NORMAL_ON,
    eCHECKBOX_NORMAL_OFF,
    eCHECKBOX_FOCUS_ON,
    eCHECKBOX_FOCUS_OFF,
    eCHECKBOX_PRELIGHT_ON,
    eCHECKBOX_PRELIGHT_OFF,

    eRADIO_NORMAL_ON,
    eRADIO_NORMAL_OFF,
    eRADIO_FOCUS_ON,
    eRADIO_FOCUS_OFF,
    eRADIO_PRELIGHT_ON,
    eRADIO_PRELIGHT_OFF,

    eBUTTON_NORMAL,
    eBUTTON_FOCUS,
    eBUTTON_PRELIGHT,

    eSPINNERUP,
    eSPINNERDOWN,

    eCOMBOBOX_OPEN_BUTTON,
    eTAB_LEFT,
    eTAB_RIGHT,
    eSPINER_UP,
    eSPINER_DOWN,
    eTREE_NODE_OPEN,
    eTREE_NODE_CLOSE,

    eSCROLLBAR_TRIANGLE_UP,
    eSCROLLBAR_TRIANGLE_DOWN,
    eSCROLLBAR_TRIANGLE_LEFT,
    eSCROLLBAR_TRIANGLE_RIGHT,

    eVECTORXLABEL,
    eVECTORYLABEL,
    eVECTORZLABEL,
    eVECTORWLABEL,

    eVALUATORVERTICALMOVE,
    eVALUATORHORIZONTALMOVE,
    eVALUATORMOVE,

    eHSCROLLBAR,
    eVSCROLLBAR,

    eMATRIX3PREVIEW,
    eMATRIX4PREVIEW,

    eDOT6x6,

    eGraphIcon,
    eGraphBarIcon,

    eWindowCloseButton,
  };

  struct PainterImage
  {
    BaseTexture* texture;
    UXStyleImageRef style;

    int border_left;
    int border_right;
    int border_top;
    int border_bottom;
    bool draw_borders_only;
    std::string filename;

    PainterImage()
    {
      texture = NULL;
    }
  };

  //! Load textures and other data for user interface rendering.
  /*!
      Load textures and other data for user interface rendering.
  */
  class UXTheme
  {
  public:
    UXTheme();
    ~UXTheme();

    const PainterImage *GetImage(UXStyleImageRef style);
    Rect GetImageGeometry(UXStyleImageRef style);

  private:
#if defined(NUX_OS_LINUX)
    static void ParseStartImage(GMarkupParseContext* context,
      const gchar*  element_name,
      const gchar** attribute_names,
      const gchar** attribute_values,
      gpointer      user_data,
      GError**      error);

    static void ParseEndImage(GMarkupParseContext* context,
      const gchar*  element_name,
      gpointer      user_data,
      GError**      error);
#endif

    void LoadPainterImages();
    BaseTexture* Load2DTextureFile(const char* filename);
    BaseTexture* Load2DTextureFileGenerateAlpha(const char* filename, int red, int green, int blue);
    std::list<PainterImage*> painter_image_list_;

  };
}

#endif // UXTHEME_H