comparison include/ConvDispP.h @ 0:92745d501b9a

initial import from kinput2-v3.1
author Yoshiki Yazawa <yaz@honeyplanet.jp>
date Mon, 08 Mar 2010 04:44:30 +0900
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:92745d501b9a
1 /* $Id: ConvDispP.h,v 1.7 1991/09/17 10:04:46 ishisone Rel $ */
2 /*
3 * Copyright (c) 1990 Software Research Associates, Inc.
4 *
5 * Permission to use, copy, modify, and distribute this software and its
6 * documentation for any purpose and without fee is hereby granted, provided
7 * that the above copyright notice appear in all copies and that both that
8 * copyright notice and this permission notice appear in supporting
9 * documentation, and that the name of Software Research Associates not be
10 * used in advertising or publicity pertaining to distribution of the
11 * software without specific, written prior permission. Software Research
12 * Associates makes no representations about the suitability of this software
13 * for any purpose. It is provided "as is" without express or implied
14 * warranty.
15 *
16 * Author: Makoto Ishisone, Software Research Associates, Inc., Japan
17 */
18
19 #ifndef _ConvDisplayP_h
20 #define _ConvDisplayP_h
21
22 #include <X11/ObjectP.h>
23 #include "ConvDisp.h"
24
25 typedef struct {
26 int (*StringWidth)();
27 int (*LineHeight)();
28 void (*DrawString)();
29 int (*MaxChar)();
30 void (*DrawCursor)();
31 void (*GetCursorBounds)();
32 void (*SetFonts)();
33 } ConvDisplayClassPart;
34
35 typedef struct _ConvDisplayClassRec {
36 ObjectClassPart object_class;
37 ConvDisplayClassPart convDisplay_class;
38 } ConvDisplayClassRec;
39
40 typedef struct {
41 /* resources */
42 Pixel foreground;
43 Pixel background;
44 Pixmap cursor; /* really a bitmap */
45 Position hotx;
46 Position hoty;
47 /* private */
48 Boolean cursorcreated;
49 XRectangle cursorbounds;
50 GC cursorgc;
51 Boolean cursorvisible;
52 } ConvDisplayPart;
53
54 typedef struct _ConvDisplayRec {
55 ObjectPart object;
56 ConvDisplayPart convDisplay;
57 } ConvDisplayRec;
58
59 extern ConvDisplayClassRec convDisplayClassRec;
60
61 #define XtInheritStringWidth (int(*)())_XtInherit
62 #define XtInheritLineHeight (int(*)())_XtInherit
63 #define XtInheritDrawString (void(*)())_XtInherit
64 #define XtInheritMaxChar (int(*)())_XtInherit
65 #define XtInheritDrawCursor (void(*)())_XtInherit
66 #define XtInheritGetCursorBounds (void(*)())_XtInherit
67 #define XtInheritSetFonts (void(*)())_XtInherit
68
69
70 /* semi-public function */
71
72 typedef struct {
73 Atom registry; /* ex) "ISO8859", "JISX0208.1983" */
74 Atom encoding; /* ex) "0", "1" */
75 XFontStruct *font; /* return value */
76 } FontSpec;
77
78 extern int _CDPickupFonts(
79 #if NeedFunctionPrototypes
80 Widget /* widget */,
81 FontSpec * /* spec */,
82 Cardinal /* num_specs */,
83 XFontStruct ** /* fonts */,
84 Cardinal /* num_fonts */
85 #endif
86 );
87
88 #endif