File: os-dep.h

package info (click to toggle)
gcin 2.8.8%2Bdfsg1-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 22,672 kB
  • sloc: cpp: 33,774; ansic: 9,313; makefile: 652; sh: 558
file content (49 lines) | stat: -rw-r--r-- 1,304 bytes parent folder | download | duplicates (3)
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
#ifndef OS_DEP_H
#define OS_DEP_H
#if WIN32
#include <windows.h>
#include "win32-key.h"
//typedef HWND Window;
typedef unsigned int Window; // HWND is actual a pointer, this breaks 64-bit IME & 32-bit gcin
typedef void Display;
typedef u_int KeySym;
typedef unsigned int CARD32;
typedef unsigned int u_int;
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef __int64 u_int64_t;
bool win32exec(char *s);
int win32exec_script(char *s, char *para=NULL);
int win32exec_script_va(char *s, ...);
int win32exec_va(char *s, ...);
bool win32exec_para(char *s, char *para);
extern char *gcin_program_files_path;
extern char *gcin_script_path;
typedef struct {
	int x, y;
} XPoint;
// #define snprintf sprintf_s
#define bzero ZeroMemory
// #define true 1
#define True 1
// #define false 0
int utf8_to_16(char *text, wchar_t *wtext, int wlen);
int utf16_to_8(wchar_t *in, char *out, int outN);
inline void *GDK_DISPLAY() { return NULL;}
//typedef wchar_t unich_t;
#define _L(x)      L ## x
#pragma execution_character_set("utf-8")
#else
typedef char unich_t;
void unix_exec(char *fmt,...);
#define _L(x) x
#include <X11/Xlib.h>
#include <X11/Xlocale.h>
#include <X11/keysym.h>
#include <glib.h>
#if GLIB_CHECK_VERSION(2,29,8)
#define G_CONST_RETURN const
#endif
#include <gdk/gdkx.h>
#endif
#endif