This file is indexed.

/usr/include/Nux-4.0/Nux/Nux.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
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
/*
 * 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 NUX_H
#define NUX_H

#include "NuxCore/NuxCore.h"
#include "NuxCore/Error.h"
#include "NuxCore/FilePath.h"
#include "NuxCore/Color.h"
#include "NuxCore/Rect.h"
#include "NuxCore/Point.h"
#include "NuxCore/Size.h"

#include "NuxCore/ObjectPtr.h"

#include "NuxCore/Math/Constants.h"
#include "NuxCore/Math/Vector3.h"
#include "NuxCore/Math/Vector4.h"
#include "NuxCore/Math/Matrix3.h"
#include "NuxCore/Math/Matrix4.h"
#include "NuxCore/Math/Spline.h"

#include <sigc++/trackable.h>
#include <sigc++/signal.h>
#include <sigc++/functors/ptr_fun.h>
#include <sigc++/functors/mem_fun.h>
#include <sigc++/adaptors/bind.h>
#include <sigc++/functors/slot.h>

#include <glib.h>

#define NUX_USE_GLIB_LOOP_ON_WINDOWS
//#define NUX_DISABLE_GLIB_LOOP

#if defined(NUX_OS_LINUX)
#include "Features.h"
#endif

#include "Utils.h"
#include "WidgetMetrics.h"
#include "Area.h"
#include "InputArea.h"
#include "Theme.h"
#include "Painter.h"
#include "View.h"
#include "BasicView.h"
#include "AbstractThread.h"
#include "WindowThread.h"
#include "WindowCompositor.h"
#if !defined(NUX_MINIMAL)
#  include "Timeline.h"
#endif
#include "SystemThread.h"



namespace nux
{
  class WindowThread;
  class SystemThread;
  class WindowCompositor;
  class TimerHandler;

  void NuxInitialize(const char *CommandLine);

  //! Create a Nux window.
  /*!
      Create a Nux window. The window 

      @param window_title The window title.
      @param width The window width.
      @param height The window height.
      @param parent The window height parent. Should be NULL.
      @param user_init_func Initialization function to be called before starting the window loop.
      @param data Parameter to the initialization function.
  */
  WindowThread *CreateGUIThread(const char *window_title,
                                int width,
                                int height,
                                WindowThread *parent = NULL,
                                ThreadUserInitFunc user_init_func = NULL,
                                void *data = NULL);

  //! Create the only Nux window for the current system thread.
  /*!
      There can be only one NuxWindow per system thread. This function creates the only Nux window allowed in the current thread. \n
      The first time this function is called in the current system thread, it returns a valid pointer
      to a NuxWindow object. The next time it is called, the system detects that a NuxWindow has already
      been created in the thread and it returns NULL. \n
      When CreateNuxWindow successfully returns, the NuxWindow internals (GraphicsDisplay, Compositor, Painter, TimerManager)
      have been initialized. Calling nux::GetThreadNuxWindow() returns a pointer to the NuxWindow that has been successfully created
      in the current thread. \n
      To start the main loop of a NuxWindow created with CreateNuxWindow, call NuxWindow::Run(); \n
      The modal parameter specifies if the window is blocking while it is active. This is valid only if the parent thread is a WindowThread.

      @param window_title The window title.
      @param width The window width.
      @param height The window height.
      @param window_border_style The window border style.
      @param parent The window parent.
      @param modal Modality of the window.
      @param user_init_func Initialization function to be called before starting the window loop.
      @param data Parameter to the initialization function.

      @return A valid pointer to a NuxWindow if the window has been successfully created. NULL otherwise.
  */
  WindowThread *CreateNuxWindow(const char *window_title,
    int width,
    int height,
    WindowStyle window_border_style = WINDOWSTYLE_NORMAL,
    AbstractThread *parent = NULL,
    bool modal = false,
    ThreadUserInitFunc user_init_func = NULL,
    void *data = NULL);

  //! Create a Nux window to be run in a new thread.
  /*!
      Create a Nux window that will run in a new thread. 
      Unlike CreateNuxWindow, CreateNuxWindowNewThread should always successfully return a valid NuxWindow pointer.
      However, the internal objects of the NuxWindow (GraphicsDisplay, Compositor, Painter, TimerManager) have not been initialized yet.
      So, calling NuxWindow::GetWindowCompositor(), NuxWindow::GetGraphicsDisplay() will fail. \n
      To start the main loop of a NuxWindow created with CreateNuxWindow, call NuxWindow::Run(); \n
      The modal parameter specifies if the window is blocking its parent window while it is active. This is valid only if the parent thread is a WindowThread.


      @param window_title The window title.
      @param width The window width.
      @param height The window height.
      @param window_border_style The window border style.
      @param parent The window parent.
      @param modal Modality of the window.
      @param user_init_func Initialization function to be called before starting the window loop.
      @param data Parameter to the initialization function.

      @return A valid pointer to a NuxWindow if the window has been successfully created. NULL otherwise.
  */
  WindowThread *CreateNuxWindowNewThread(const char *window_title,
    int width,
    int height,
    WindowStyle window_border_style = WINDOWSTYLE_NORMAL,
    AbstractThread *parent = NULL,
    bool modal = false,
    ThreadUserInitFunc user_init_func = NULL,
    void *data = NULL);

#if defined(NUX_OS_WINDOWS)
  //! Create a main graphics thread. This thread has a window and no parent window.
  WindowThread *CreateFromForeignWindow(HWND WindowHandle, HDC WindowDCHandle,
                                        HGLRC OpenGLRenderingContext,
                                        ThreadUserInitFunc user_init_func,
                                        void *data);
#elif defined(NO_X11)
#elif defined(NUX_OS_LINUX)
  //! Create a main graphics thread. This thread has a window and no parent window.
#ifdef NUX_OPENGLES_20
  WindowThread *CreateFromForeignWindow (Window X11Window, EGLContext OpenGLContext,
                                         ThreadUserInitFunc user_init_func,
                                         void *data);
#else
  WindowThread *CreateFromForeignWindow (Window X11Window, GLXContext OpenGLContext,
                                         ThreadUserInitFunc user_init_func,
                                         void *data);
#endif
#endif

  // Create a window thread that is a child of the Parent. This thread has a window.
  /*!
      @param window_style The window style.
      @param window_title The window title.
      @param width The window width.
      @param height The window height.
      @param parent The window parent.
      @param user_init_func Initialization function to be called before starting the window loop.
      @param data Parameter to the initialization function.
  */
  WindowThread *CreateWindowThread(WindowStyle window_style,
                                   const char *window_title,
                                   int width,
                                   int height,
                                   WindowThread *parent,
                                   ThreadUserInitFunc user_init_func = NULL,
                                   void *data = NULL);

  // Create a Modal window thread that is a child of the Parent. This thread has a window.
  /*!
      @param window_style The window style.
      @param window_title The window title.
      @param width The window width.
      @param height The window height.
      @param parent The window height parent. Should be NULL.
      @param user_init_func Initialization function to be called before starting the window loop.
      @param data Parameter to the initialization function.
  */
  WindowThread *CreateModalWindowThread(WindowStyle window_style,
                                        const char *window_title,
                                        int width,
                                        int height,
                                        WindowThread *parent,
                                        ThreadUserInitFunc user_init_func = NULL,
                                        void *data = NULL);

// Create a simple thread
  SystemThread *CreateSystemThread(AbstractThread *parent = NULL,
                                   ThreadUserInitFunc user_init_func = NULL,
                                   void *data = NULL);

/*  ThreadState GetThreadState(unsigned int ThreadID);*/


  ObjectPtr<FontTexture> GetSysFont();
  ObjectPtr<FontTexture> GetSysBoldFont();

  WindowThread      *GetWindowThread();
  WindowThread      *GetThreadNuxWindow();

  WindowCompositor  &GetWindowCompositor();
  BasePainter       &GetPainter();
  UXTheme           &GetTheme();
  TimerHandler      &GetTimer();

#define  gPainter nux::GetPainter() // deprecated
#define  gTheme   nux::GetTheme()   // deprecated

  inlDeclareThreadLocalStorage(NThread *, 0, ThreadLocal_InalogicAppImpl);

}

#endif // NUX_H