2002-02-05 16:34:33 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: private.h
|
2002-02-08 12:00:11 +00:00
|
|
|
// Purpose: Private declarations for X11 port
|
2002-02-05 16:34:33 +00:00
|
|
|
// Author: Julian Smart
|
|
|
|
// Modified by:
|
|
|
|
// Created: 17/09/98
|
|
|
|
// RCS-ID: $Id$
|
|
|
|
// Copyright: (c) Julian Smart
|
2004-05-23 20:53:33 +00:00
|
|
|
// Licence: wxWindows licence
|
2002-02-05 16:34:33 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef _WX_PRIVATE_H_
|
|
|
|
#define _WX_PRIVATE_H_
|
|
|
|
|
|
|
|
#include "wx/defs.h"
|
2002-02-10 16:42:42 +00:00
|
|
|
#include "wx/utils.h"
|
2003-05-09 10:53:52 +00:00
|
|
|
#if defined( __cplusplus ) && defined( __VMS )
|
|
|
|
#pragma message disable nosimpint
|
|
|
|
#endif
|
2002-02-08 17:44:23 +00:00
|
|
|
#include "X11/Xlib.h"
|
2002-02-11 12:04:35 +00:00
|
|
|
#include "X11/Xatom.h"
|
|
|
|
#include "X11/Xutil.h"
|
2003-05-09 10:53:52 +00:00
|
|
|
#if defined( __cplusplus ) && defined( __VMS )
|
|
|
|
#pragma message enable nosimpint
|
|
|
|
#endif
|
2002-02-05 16:34:33 +00:00
|
|
|
|
2002-02-13 16:17:29 +00:00
|
|
|
// Include common declarations
|
2002-02-13 17:23:13 +00:00
|
|
|
#include "wx/x11/privx.h"
|
2002-02-13 16:17:29 +00:00
|
|
|
|
2002-12-04 14:11:26 +00:00
|
|
|
#if wxUSE_UNICODE
|
|
|
|
#include "pango/pango.h"
|
|
|
|
#endif
|
|
|
|
|
2002-02-05 16:34:33 +00:00
|
|
|
class wxMouseEvent;
|
|
|
|
class wxKeyEvent;
|
2002-02-10 16:42:42 +00:00
|
|
|
class wxWindow;
|
2002-02-05 16:34:33 +00:00
|
|
|
|
2002-12-04 14:11:26 +00:00
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
// Some Unicode <-> UTF8 macros stolen from GTK
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
#if wxUSE_UNICODE
|
|
|
|
#define wxGTK_CONV(s) wxConvUTF8.cWX2MB(s)
|
|
|
|
#define wxGTK_CONV_BACK(s) wxConvUTF8.cMB2WX(s)
|
|
|
|
#else
|
|
|
|
#define wxGTK_CONV(s) s.c_str()
|
|
|
|
#define wxGTK_CONV_BACK(s) s
|
|
|
|
#endif
|
|
|
|
|
2002-02-05 16:34:33 +00:00
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
// we maintain a hash table which contains the mapping from Widget to wxWindow
|
|
|
|
// corresponding to the window for this widget
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
|
2002-02-08 12:00:11 +00:00
|
|
|
extern void wxDeleteWindowFromTable(Window w);
|
|
|
|
extern wxWindow *wxGetWindowFromTable(Window w);
|
|
|
|
extern bool wxAddWindowToTable(Window w, wxWindow *win);
|
2002-02-05 16:34:33 +00:00
|
|
|
|
2002-03-24 22:17:53 +00:00
|
|
|
extern void wxDeleteClientWindowFromTable(Window w);
|
|
|
|
extern wxWindow *wxGetClientWindowFromTable(Window w);
|
|
|
|
extern bool wxAddClientWindowToTable(Window w, wxWindow *win);
|
|
|
|
|
2002-02-05 16:34:33 +00:00
|
|
|
// ----------------------------------------------------------------------------
|
2002-02-13 16:17:29 +00:00
|
|
|
// TranslateXXXEvent() functions - translate X event to wxWindow one
|
2002-02-05 16:34:33 +00:00
|
|
|
// ----------------------------------------------------------------------------
|
2002-02-08 12:00:11 +00:00
|
|
|
extern bool wxTranslateMouseEvent(wxMouseEvent& wxevent, wxWindow *win, Window window, XEvent *xevent);
|
2002-12-04 14:11:26 +00:00
|
|
|
extern bool wxTranslateKeyEvent(wxKeyEvent& wxevent, wxWindow *win, Window window, XEvent *xevent, bool isAscii = FALSE);
|
2002-02-05 16:34:33 +00:00
|
|
|
|
2002-02-10 01:03:45 +00:00
|
|
|
extern Window wxGetWindowParent(Window window);
|
|
|
|
|
2002-02-11 11:06:50 +00:00
|
|
|
// Set the window manager decorations according to the
|
2004-05-23 14:56:36 +00:00
|
|
|
// given wxWidgets style
|
2002-02-11 11:06:50 +00:00
|
|
|
bool wxSetWMDecorations(Window w, long style);
|
|
|
|
bool wxMWMIsRunning(Window w);
|
|
|
|
|
2002-02-05 16:34:33 +00:00
|
|
|
#endif
|
|
|
|
// _WX_PRIVATE_H_
|