1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
34 #include <X11/Xresource.h>
39 XIM
XvaOpenIM( Display
*, XrmDatabase
, char*, char*, ... );
41 extern Status
XCloseIM(XIM
);
44 typedef int (*XIMProc1
)(XIC
, XPointer
, XPointer
);
51 typedef struct _XIMAnnotation
{
58 XIMUText: XIMText extention for UTF16
60 typedef struct _XIMUnicodeText
{
61 unsigned short length
;
62 XIMFeedback
*feedback
;
63 Bool encoding_is_wchar
;
67 unsigned short *utf16_char
;
69 unsigned int count_annotations
;
70 XIMAnnotation
*annotations
;
75 XIMDrawUpHorizontally
= 0 ,
76 XIMDrawUpVertically
= 1
77 } XIMDrawUpDirection
;
79 typedef struct _XIMLookupStartCallbackStruct
{
80 int choice_per_window
; /* Number of choices can be display
85 XIMDrawUpDirection draw_up_direction
;
86 } XIMLookupStartCallbackStruct
;
88 typedef struct _XIMUnicodeChoiceObject
{
89 XIMUnicodeText
*label
;
90 XIMUnicodeText
*value
;
91 } XIMUnicodeChoiceObject
;
93 typedef struct _XIMLookupDrawCallbackStruct
{
94 XIMUnicodeChoiceObject
*choices
; /* the lookup choices */
95 int n_choices
; /* Total number of lookup choices */
99 XIMUnicodeText
*title
;
100 } XIMLookupDrawCallbackStruct
;
104 XIMKatakana
, XIMHanzi
105 } XIMUnicodeCharacterSubsetID
;
107 typedef struct _XIMUncodeSubset
{
108 XIMUnicodeCharacterSubsetID index
;
109 XIMUnicodeCharacterSubsetID subset_id
;
112 } XIMUnicodeCharacterSubset
;
114 typedef struct _XIMUncodeSubsets
{
115 unsigned short count_subsets
;
116 XIMUnicodeCharacterSubset
*supported_subsets
;
117 } XIMUnicodeCharacterSubsets
;
119 typedef struct _XIMSwitchIMNotifyCallbackStruct
{
120 XIMUnicodeCharacterSubset
*from
;
121 XIMUnicodeCharacterSubset
*to
;
122 } XIMSwitchIMNotifyCallbackStruct
;
124 /* XIM attributes for multilingual IM extension */
125 #define XNMultiLingualInput "multiLingualInput"
126 #define XNQueryUnicodeCharacterSubset "unicodeCharacterSubset"
128 /* XIC attributes for multilingual IM extension */
130 #define XNUnicodeCharacterSubset "UnicodeChararcterSubset"
132 #define XNSwitchIMNotifyCallback "switchIMNotifyCallback"
133 #define XNCommitStringCallback "commitStringCallback"
134 #define XNForwardEventCallback "forwardEventCallback"
136 #define XNLookupStartCallback "lookupStartCallback"
137 #define XNLookupDrawCallback "lookupDrawCallback"
138 #define XNLookupDoneCallback "lookupDoneCallback"