]> git.saurik.com Git - wxWidgets.git/blame - include/wx/x11/private.h
Patch #514729 applied - adds missing RTTIs to wxToolLayoutItem
[wxWidgets.git] / include / wx / x11 / private.h
CommitLineData
83df96d6
JS
1/////////////////////////////////////////////////////////////////////////////
2// Name: private.h
1b0fb34b 3// Purpose: Private declarations for X11 port
83df96d6
JS
4// Author: Julian Smart
5// Modified by:
6// Created: 17/09/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_PRIVATE_H_
13#define _WX_PRIVATE_H_
14
15#include "wx/defs.h"
16
17class wxMouseEvent;
18class wxKeyEvent;
19
83df96d6
JS
20// ----------------------------------------------------------------------------
21// common callbacks
22// ----------------------------------------------------------------------------
23
1b0fb34b 24#if 0
83df96d6
JS
25// All widgets should have this as their resize proc.
26extern void wxWidgetResizeProc(Widget w, XConfigureEvent *event, String args[], int *num_args);
27
28// For repainting arbitrary windows
29void wxUniversalRepaintProc(Widget w, XtPointer WXUNUSED(c_data), XEvent *event, char *);
1b0fb34b 30#endif
83df96d6
JS
31
32// ----------------------------------------------------------------------------
33// we maintain a hash table which contains the mapping from Widget to wxWindow
34// corresponding to the window for this widget
35// ----------------------------------------------------------------------------
36
1b0fb34b
JS
37extern void wxDeleteWindowFromTable(Window w);
38extern wxWindow *wxGetWindowFromTable(Window w);
39extern bool wxAddWindowToTable(Window w, wxWindow *win);
83df96d6
JS
40
41// ----------------------------------------------------------------------------
42// key events related functions
43// ----------------------------------------------------------------------------
44
45extern char wxFindMnemonic(const char* s);
46
47extern char * wxFindAccelerator (const char *s);
1b0fb34b 48//extern XmString wxFindAcceleratorText (const char *s);
83df96d6
JS
49
50extern int wxCharCodeXToWX(KeySym keySym);
51extern KeySym wxCharCodeWXToX(int id);
52
53// ----------------------------------------------------------------------------
54// TranslateXXXEvent() functions - translate Motif event to wxWindow one
55// ----------------------------------------------------------------------------
1b0fb34b
JS
56extern bool wxTranslateMouseEvent(wxMouseEvent& wxevent, wxWindow *win, Window window, XEvent *xevent);
57extern bool wxTranslateKeyEvent(wxKeyEvent& wxevent, wxWindow *win, Window window, XEvent *xevent);
83df96d6
JS
58
59int wxGetBestMatchingPixel(Display *display, XColor *desiredColor, Colormap cmap);
60Pixmap XCreateInsensitivePixmap( Display *display, Pixmap pixmap );
61
62extern XColor g_itemColors[];
63extern int wxComputeColours (Display *display, wxColour * back, wxColour * fore);
64
65extern void wxDoChangeForegroundColour(WXWidget widget, wxColour& foregroundColour);
66extern void wxDoChangeBackgroundColour(WXWidget widget, wxColour& backgroundColour, bool changeArmColour = FALSE);
67
68#define wxNO_COLORS 0x00
69#define wxBACK_COLORS 0x01
70#define wxFORE_COLORS 0x02
71
72extern XColor itemColors[5] ;
73
74#define wxBACK_INDEX 0
75#define wxFORE_INDEX 1
76#define wxSELE_INDEX 2
77#define wxTOPS_INDEX 3
78#define wxBOTS_INDEX 4
79
83df96d6
JS
80// ----------------------------------------------------------------------------
81// accessors for C modules
82// ----------------------------------------------------------------------------
83
1b0fb34b 84// extern "C" XtAppContext wxGetAppContext();
83df96d6
JS
85
86#endif
87// _WX_PRIVATE_H_