~ubuntu-branches/ubuntu/utopic/critcl/utopic

« back to all changes in this revision

Viewing changes to lib/critcl/critcl_c/tcl8.5/tclPlatDecls.h

  • Committer: Package Import Robot
  • Author(s): Andrew Shadura
  • Date: 2013-05-11 00:08:06 UTC
  • Revision ID: package-import@ubuntu.com-20130511000806-7hq1zc3fnn0gat79
Tags: upstream-3.1.9
ImportĀ upstreamĀ versionĀ 3.1.9

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * tclPlatDecls.h --
 
3
 *
 
4
 *      Declarations of platform specific Tcl APIs.
 
5
 *
 
6
 * Copyright (c) 1998-1999 by Scriptics Corporation.
 
7
 * All rights reserved.
 
8
 *
 
9
 * RCS: @(#) $Id: tclPlatDecls.h,v 1.27.2.3 2010/11/16 14:57:46 nijtmans Exp $
 
10
 */
 
11
 
 
12
#ifndef _TCLPLATDECLS
 
13
#define _TCLPLATDECLS
 
14
 
 
15
#undef TCL_STORAGE_CLASS
 
16
#ifdef BUILD_tcl
 
17
#   define TCL_STORAGE_CLASS DLLEXPORT
 
18
#else
 
19
#   ifdef USE_TCL_STUBS
 
20
#      define TCL_STORAGE_CLASS
 
21
#   else
 
22
#      define TCL_STORAGE_CLASS DLLIMPORT
 
23
#   endif
 
24
#endif
 
25
 
 
26
/*
 
27
 *  Pull in the typedef of TCHAR for windows.
 
28
 */
 
29
#if defined(__WIN32__) && !defined(_TCHAR_DEFINED)
 
30
#   include <tchar.h>
 
31
#   ifndef _TCHAR_DEFINED
 
32
        /* Borland seems to forget to set this. */
 
33
        typedef _TCHAR TCHAR;
 
34
#       define _TCHAR_DEFINED
 
35
#   endif
 
36
#   if defined(_MSC_VER) && defined(__STDC__)
 
37
        /* VS2005 SP1 misses this. See [Bug #3110161] */
 
38
        typedef _TCHAR TCHAR;
 
39
#   endif
 
40
#endif
 
41
 
 
42
/* !BEGIN!: Do not edit below this line. */
 
43
 
 
44
/*
 
45
 * Exported function declarations:
 
46
 */
 
47
 
 
48
#ifdef __WIN32__ /* WIN */
 
49
#ifndef Tcl_WinUtfToTChar_TCL_DECLARED
 
50
#define Tcl_WinUtfToTChar_TCL_DECLARED
 
51
/* 0 */
 
52
EXTERN TCHAR *          Tcl_WinUtfToTChar(CONST char *str, int len,
 
53
                                Tcl_DString *dsPtr);
 
54
#endif
 
55
#ifndef Tcl_WinTCharToUtf_TCL_DECLARED
 
56
#define Tcl_WinTCharToUtf_TCL_DECLARED
 
57
/* 1 */
 
58
EXTERN char *           Tcl_WinTCharToUtf(CONST TCHAR *str, int len,
 
59
                                Tcl_DString *dsPtr);
 
60
#endif
 
61
#endif /* WIN */
 
62
#ifdef MAC_OSX_TCL /* MACOSX */
 
63
#ifndef Tcl_MacOSXOpenBundleResources_TCL_DECLARED
 
64
#define Tcl_MacOSXOpenBundleResources_TCL_DECLARED
 
65
/* 0 */
 
66
EXTERN int              Tcl_MacOSXOpenBundleResources(Tcl_Interp *interp,
 
67
                                CONST char *bundleName, int hasResourceFile,
 
68
                                int maxPathLen, char *libraryPath);
 
69
#endif
 
70
#ifndef Tcl_MacOSXOpenVersionedBundleResources_TCL_DECLARED
 
71
#define Tcl_MacOSXOpenVersionedBundleResources_TCL_DECLARED
 
72
/* 1 */
 
73
EXTERN int              Tcl_MacOSXOpenVersionedBundleResources(
 
74
                                Tcl_Interp *interp, CONST char *bundleName,
 
75
                                CONST char *bundleVersion,
 
76
                                int hasResourceFile, int maxPathLen,
 
77
                                char *libraryPath);
 
78
#endif
 
79
#endif /* MACOSX */
 
80
 
 
81
typedef struct TclPlatStubs {
 
82
    int magic;
 
83
    struct TclPlatStubHooks *hooks;
 
84
 
 
85
#ifdef __WIN32__ /* WIN */
 
86
    TCHAR * (*tcl_WinUtfToTChar) (CONST char *str, int len, Tcl_DString *dsPtr); /* 0 */
 
87
    char * (*tcl_WinTCharToUtf) (CONST TCHAR *str, int len, Tcl_DString *dsPtr); /* 1 */
 
88
#endif /* WIN */
 
89
#ifdef MAC_OSX_TCL /* MACOSX */
 
90
    int (*tcl_MacOSXOpenBundleResources) (Tcl_Interp *interp, CONST char *bundleName, int hasResourceFile, int maxPathLen, char *libraryPath); /* 0 */
 
91
    int (*tcl_MacOSXOpenVersionedBundleResources) (Tcl_Interp *interp, CONST char *bundleName, CONST char *bundleVersion, int hasResourceFile, int maxPathLen, char *libraryPath); /* 1 */
 
92
#endif /* MACOSX */
 
93
} TclPlatStubs;
 
94
 
 
95
#ifdef __cplusplus
 
96
extern "C" {
 
97
#endif
 
98
extern const TclPlatStubs *tclPlatStubsPtr;
 
99
#ifdef __cplusplus
 
100
}
 
101
#endif
 
102
 
 
103
#if defined(USE_TCL_STUBS) && !defined(USE_TCL_STUB_PROCS)
 
104
 
 
105
/*
 
106
 * Inline function declarations:
 
107
 */
 
108
 
 
109
#ifdef __WIN32__ /* WIN */
 
110
#ifndef Tcl_WinUtfToTChar
 
111
#define Tcl_WinUtfToTChar \
 
112
        (tclPlatStubsPtr->tcl_WinUtfToTChar) /* 0 */
 
113
#endif
 
114
#ifndef Tcl_WinTCharToUtf
 
115
#define Tcl_WinTCharToUtf \
 
116
        (tclPlatStubsPtr->tcl_WinTCharToUtf) /* 1 */
 
117
#endif
 
118
#endif /* WIN */
 
119
#ifdef MAC_OSX_TCL /* MACOSX */
 
120
#ifndef Tcl_MacOSXOpenBundleResources
 
121
#define Tcl_MacOSXOpenBundleResources \
 
122
        (tclPlatStubsPtr->tcl_MacOSXOpenBundleResources) /* 0 */
 
123
#endif
 
124
#ifndef Tcl_MacOSXOpenVersionedBundleResources
 
125
#define Tcl_MacOSXOpenVersionedBundleResources \
 
126
        (tclPlatStubsPtr->tcl_MacOSXOpenVersionedBundleResources) /* 1 */
 
127
#endif
 
128
#endif /* MACOSX */
 
129
 
 
130
#endif /* defined(USE_TCL_STUBS) && !defined(USE_TCL_STUB_PROCS) */
 
131
 
 
132
/* !END!: Do not edit above this line. */
 
133
 
 
134
#undef TCL_STORAGE_CLASS
 
135
#define TCL_STORAGE_CLASS DLLIMPORT
 
136
 
 
137
#endif /* _TCLPLATDECLS */
 
138
 
 
139