summaryrefslogtreecommitdiff
path: root/iup/include/iuplua.h
blob: 854a858de6b08513eeaac162da87525f54c548e9 (plain)
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
/** \file
 * \brief IUP Binding for Lua.
 *
 * See Copyright Notice in "iup.h"
 */
 
#ifndef __IUPLUA_H 
#define __IUPLUA_H

#ifdef __cplusplus
extern "C" {
#endif

#ifdef LUA_NOOBJECT  /* Lua 3 */
int iuplua_open (void);
int iupkey_open (void);

/* utilities */
Ihandle* iuplua_checkihandle(int pos);
void iuplua_pushihandle(Ihandle *n);
int iuplua_dofile (char *filename);
#endif

#ifdef LUA_TNONE  /* Lua 5 */
int iuplua_open(lua_State *L);
int iupkey_open(lua_State *L);  /* does nothing, kept for backward compatibility */
int iuplua_close(lua_State * L);

/* utilities */
Ihandle* iuplua_checkihandle(lua_State *L, int pos);
void iuplua_pushihandle(lua_State *L, Ihandle *n);
int iuplua_dofile(lua_State *L, const char *filename);
int iuplua_dostring(lua_State *L, const char *string, const char *chunk_name);

#endif

#ifdef __cplusplus
}
#endif

#endif