From 83a4fe0dc71aafbef11477b284abe530d3877556 Mon Sep 17 00:00:00 2001 From: marha Date: Thu, 3 Feb 2011 09:44:39 +0000 Subject: libXext xserver libXau libX11 pixman mesa git update 3 Feb 2011 --- libX11/modules/im/ximcp/imLcLkup.c | 4 + libX11/modules/im/ximcp/imRm.c | 6414 ++++----- libX11/modules/im/ximcp/imRmAttr.c | 7 +- libX11/modules/im/ximcp/imTrX.c | 1029 +- libX11/modules/lc/def/lcDefConv.c | 2 +- libX11/modules/lc/gen/lcGenConv.c | 2 +- libX11/src/GetProp.c | 266 +- libX11/src/ImUtil.c | 1 + libX11/src/XlibInt.c | 8 +- libX11/src/Xrm.c | 10 +- libX11/src/xcms/LRGB.c | 3692 +++-- libX11/src/xcms/cmsColNm.c | 4 +- libX11/src/xlibi18n/XDefaultOMIF.c | 2558 ++-- libX11/src/xlibi18n/lcFile.c | 6 +- libX11/src/xlibi18n/lcGeneric.c | 2 +- libXau/configure.ac | 157 +- libXdmcp/configure.ac | 144 +- libXext/configure.ac | 106 +- mesalib/scons/crossmingw.py | 399 +- mesalib/src/glsl/ast_function.cpp | 2 +- mesalib/src/glsl/glcpp/glcpp-parse.y | 7 +- mesalib/src/glsl/ir_constant_expression.cpp | 36 +- pixman/pixman/pixman-private.h | 18 +- pixman/pixman/pixman-sse2.c | 352 +- pixman/test/lowlevel-blt-bench.c | 1425 +- xorg-server/Xext/xf86bigfont.c | 89 +- xorg-server/Xext/xselinux_ext.c | 1466 +- xorg-server/configure.ac | 11 +- xorg-server/exa/exa.c | 2315 ++-- xorg-server/exa/exa_driver.c | 450 +- xorg-server/exa/exa_migration_mixed.c | 17 +- xorg-server/hw/xfree86/common/xf86DGA.c | 2449 ++-- xorg-server/hw/xfree86/common/xf86Module.h | 424 +- xorg-server/hw/xfree86/common/xf86Xinput.c | 29 +- xorg-server/hw/xfree86/dixmods/extmod/dgaproc.h | 1 - xorg-server/hw/xfree86/modes/xf86Crtc.c | 6562 ++++----- xorg-server/hw/xfree86/parser/Makefile.am | 7 +- xorg-server/hw/xquartz/bundle/Info.plist.cpp | 94 +- .../bundle/Resources/Dutch.lproj/locversion.plist | 28 +- .../Resources/Dutch.lproj/main.nib/designable.nib | 7362 +++++----- .../Dutch.lproj/main.nib/keyedobjects.nib | Bin 47472 -> 33492 bytes .../bundle/Resources/German.lproj/locversion.plist | 28 +- .../Resources/German.lproj/main.nib/designable.nib | 7102 +++++----- .../German.lproj/main.nib/keyedobjects.nib | Bin 54286 -> 52574 bytes .../Resources/Italian.lproj/locversion.plist | 28 +- .../Italian.lproj/main.nib/designable.nib | 7352 +++++----- .../Italian.lproj/main.nib/keyedobjects.nib | Bin 51319 -> 34798 bytes .../Resources/Japanese.lproj/locversion.plist | 28 +- .../Japanese.lproj/main.nib/designable.nib | 7145 +++++----- .../Japanese.lproj/main.nib/keyedobjects.nib | Bin 49135 -> 46474 bytes .../Resources/Spanish.lproj/locversion.plist | 28 +- .../Spanish.lproj/main.nib/designable.nib | 7363 +++++----- .../Spanish.lproj/main.nib/keyedobjects.nib | Bin 55363 -> 35797 bytes .../bundle/Resources/ar.lproj/locversion.plist | 28 +- .../Resources/ar.lproj/main.nib/designable.nib | 7331 +++++----- .../Resources/ar.lproj/main.nib/keyedobjects.nib | Bin 52500 -> 35150 bytes .../bundle/Resources/da.lproj/locversion.plist | 28 +- .../Resources/da.lproj/main.nib/designable.nib | 7348 +++++----- .../Resources/da.lproj/main.nib/keyedobjects.nib | Bin 51733 -> 35240 bytes .../bundle/Resources/fi.lproj/locversion.plist | 28 +- .../Resources/fi.lproj/main.nib/designable.nib | 7121 +++++----- .../Resources/fi.lproj/main.nib/keyedobjects.nib | Bin 54750 -> 51669 bytes .../bundle/Resources/ko.lproj/locversion.plist | 28 +- .../Resources/ko.lproj/main.nib/designable.nib | 7341 +++++----- .../Resources/ko.lproj/main.nib/keyedobjects.nib | Bin 47943 -> 33266 bytes .../bundle/Resources/no.lproj/locversion.plist | 28 +- .../Resources/no.lproj/main.nib/designable.nib | 7362 +++++----- .../Resources/no.lproj/main.nib/keyedobjects.nib | Bin 51758 -> 34852 bytes .../bundle/Resources/pl.lproj/locversion.plist | 28 +- .../Resources/pl.lproj/main.nib/designable.nib | 7364 +++++----- .../Resources/pl.lproj/main.nib/keyedobjects.nib | Bin 52636 -> 35340 bytes .../bundle/Resources/pt.lproj/locversion.plist | 28 +- .../Resources/pt.lproj/main.nib/designable.nib | 7377 +++++----- .../Resources/pt.lproj/main.nib/keyedobjects.nib | Bin 54868 -> 35673 bytes .../bundle/Resources/pt_PT.lproj/locversion.plist | 28 +- .../Resources/pt_PT.lproj/main.nib/designable.nib | 7096 +++++----- .../pt_PT.lproj/main.nib/keyedobjects.nib | Bin 55486 -> 53755 bytes .../bundle/Resources/ru.lproj/locversion.plist | 28 +- .../Resources/ru.lproj/main.nib/designable.nib | 7342 +++++----- .../Resources/ru.lproj/main.nib/keyedobjects.nib | Bin 56631 -> 36037 bytes .../bundle/Resources/sv.lproj/locversion.plist | 28 +- .../Resources/sv.lproj/main.nib/designable.nib | 7361 +++++----- .../Resources/sv.lproj/main.nib/keyedobjects.nib | Bin 52740 -> 35414 bytes .../Resources/zh_CN.lproj/Localizable.strings | Bin 2140 -> 2140 bytes .../bundle/Resources/zh_CN.lproj/locversion.plist | 28 +- .../Resources/zh_CN.lproj/main.nib/designable.nib | 7114 +++++----- .../zh_CN.lproj/main.nib/keyedobjects.nib | Bin 43969 -> 32549 bytes .../bundle/Resources/zh_TW.lproj/locversion.plist | 28 +- .../Resources/zh_TW.lproj/main.nib/designable.nib | 7365 +++++----- .../zh_TW.lproj/main.nib/keyedobjects.nib | Bin 45835 -> 32488 bytes xorg-server/hw/xquartz/darwinEvents.c | 1171 +- xorg-server/hw/xquartz/quartz.c | 24 + xorg-server/include/eventstr.h | 492 +- xorg-server/m4/ax_tls.m4 | 74 + xorg-server/xkb/xkb.c | 13475 ++++++++++--------- 95 files changed, 86044 insertions(+), 84079 deletions(-) create mode 100644 xorg-server/m4/ax_tls.m4 diff --git a/libX11/modules/im/ximcp/imLcLkup.c b/libX11/modules/im/ximcp/imLcLkup.c index 80e4cfef1..4891176cc 100644 --- a/libX11/modules/im/ximcp/imLcLkup.c +++ b/libX11/modules/im/ximcp/imLcLkup.c @@ -63,6 +63,10 @@ _XimLocalMbLookupString(XIC xic, XKeyEvent *ev, char *buffer, int bytes, unsigned char pattern = ic->private.local.brl_committed; char mb[XLC_PUBLIC(ic->core.im->core.lcd, mb_cur_max)]; ret = _Xlcwctomb(ic->core.im->core.lcd, mb, BRL_UC_ROW | pattern); + if(ret < 0) { + if(status) *status = XLookupNone; + return(0); + } if(ret > bytes) { if(status) *status = XBufferOverflow; return(ret); diff --git a/libX11/modules/im/ximcp/imRm.c b/libX11/modules/im/ximcp/imRm.c index 249c42d3d..3d09b8136 100644 --- a/libX11/modules/im/ximcp/imRm.c +++ b/libX11/modules/im/ximcp/imRm.c @@ -1,3205 +1,3209 @@ -/****************************************************************** - - Copyright 1990, 1991, 1992,1993, 1994 by FUJITSU LIMITED - Copyright 1994 by Sony Corporation - -Permission to use, copy, modify, distribute, and sell this software -and its documentation for any purpose is hereby granted without fee, -provided that the above copyright notice appear in all copies and -that both that copyright notice and this permission notice appear -in supporting documentation, and that the name of FUJITSU LIMITED -and Sony Corporation not be used in advertising or publicity -pertaining to distribution of the software without specific, -written prior permission. FUJITSU LIMITED and Sony Corporation make -no representations about the suitability of this software for any -purpose. It is provided "as is" without express or implied warranty. - -FUJITSU LIMITED AND SONY CORPORATION DISCLAIM ALL WARRANTIES WITH -REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL FUJITSU LIMITED AND -SONY CORPORATION BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL -DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR -PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER -TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR -PERFORMANCE OF THIS SOFTWARE. - - Author: Takashi Fujiwara FUJITSU LIMITED - fujiwara@a80.tech.yk.fujitsu.co.jp - Modifier: Makoto Wakamatsu Sony Corporation - makoto@sm.sony.co.jp - -******************************************************************/ - -#ifdef HAVE_CONFIG_H -#include -#endif -#include -#include -#include "Xlibint.h" -#include "Xlcint.h" -#include "Ximint.h" -#include "Xresource.h" - -#define GET_NAME(x) name_table + x.name_offset - -typedef struct _XimValueOffsetInfo { - unsigned short name_offset; - XrmQuark quark; - unsigned int offset; - Bool (*defaults)( - struct _XimValueOffsetInfo *, XPointer, XPointer, unsigned long - ); - Bool (*encode)( - struct _XimValueOffsetInfo *, XPointer, XPointer - ); - Bool (*decode)( - struct _XimValueOffsetInfo *, XPointer, XPointer - ); -} XimValueOffsetInfoRec, *XimValueOffsetInfo; - -#ifdef XIM_CONNECTABLE -Private Bool -_XimCheckBool(str) - char *str; -{ - if(!strcmp(str, "True") || !strcmp(str, "true") || - !strcmp(str, "Yes") || !strcmp(str, "yes") || - !strcmp(str, "ON") || !strcmp(str, "on")) - return True; - return False; -} - -Public void -_XimSetProtoResource(im) - Xim im; -{ - char res_name_buf[256]; - char* res_name; - char res_class_buf[256]; - char* res_class; - char* str_type; - XrmValue value; - XIMStyle preedit_style = 0; - XIMStyle status_style = 0; - XIMStyles* imstyles; - char* dotximdot = ".xim."; - char* ximdot = "xim."; - char* dotXimdot = ".Xim."; - char* Ximdot = "Xim."; - - if (!im->core.rdb) - return; - - if (strlen (im->core.res_name) < 200) res_name = res_name_buf; - else res_name = Xmalloc (strlen (im->core.res_name) + 50); - if (strlen (im->core.res_class) < 200) res_class = res_class_buf; - else res_class = Xmalloc (strlen (im->core.res_class) + 50); - /* pretend malloc always works */ - - (void) sprintf (res_name, "%s%s%s", - im->core.res_name != NULL ? im->core.res_name : "*", - im->core.res_name != NULL ? dotximdot : ximdot, - "useAuth"); - (void) sprintf (res_class, "%s%s%s", - im->core.res_class != NULL ? im->core.res_class : "*", - im->core.res_class != NULL ? dotXimdot : Ximdot, - "UseAuth"); - bzero(&value, sizeof(XrmValue)); - if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { - if(_XimCheckBool(value.addr)) { - MARK_USE_AUTHORIZATION_FUNC(im); - } - } - - (void) sprintf (res_name, "%s%s%s", - im->core.res_name != NULL ? im->core.res_name : "*", - im->core.res_name != NULL ? dotximdot : ximdot, - "delaybinding"); - (void) sprintf (res_class, "%s%s%s", - im->core.res_class != NULL ? im->core.res_class : "*", - im->core.res_class != NULL ? dotXimdot : Ximdot, - "Delaybinding"); - bzero(&value, sizeof(XrmValue)); - if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { - if(_XimCheckBool(value.addr)) { - MARK_DELAYBINDABLE(im); - } - } - - (void) sprintf (res_name, "%s%s%s", - im->core.res_name != NULL ? im->core.res_name : "*", - im->core.res_name != NULL ? dotximdot : ximdot, - "reconnect"); - (void) sprintf (res_class, "%s%s%s", - im->core.res_class != NULL ? im->core.res_class : "*", - im->core.res_class != NULL ? dotXimdot : Ximdot, - "Reconnect"); - bzero(&value, sizeof(XrmValue)); - if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { - if(_XimCheckBool(value.addr)) { - MARK_RECONNECTABLE(im); - } - } - - if(!IS_CONNECTABLE(im)) { - if (res_name != res_name_buf) Xfree (res_name); - if (res_class != res_class_buf) Xfree (res_class); - return; - } - - (void) sprintf (res_name, "%s%s%s", - im->core.res_name != NULL ? im->core.res_name : "*", - im->core.res_name != NULL ? dotximdot : ximdot, - "preeditDefaultStyle"); - (void) sprintf (res_class, "%s%s%s", - im->core.res_class != NULL ? im->core.res_class : "*", - im->core.res_class != NULL ? dotXimdot : Ximdot, - "PreeditDefaultStyle"); - if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { - if(!strcmp(value.addr, "XIMPreeditArea")) - preedit_style = XIMPreeditArea; - else if(!strcmp(value.addr, "XIMPreeditCallbacks")) - preedit_style = XIMPreeditCallbacks; - else if(!strcmp(value.addr, "XIMPreeditPosition")) - preedit_style = XIMPreeditPosition; - else if(!strcmp(value.addr, "XIMPreeditNothing")) - preedit_style = XIMPreeditNothing; - else if(!strcmp(value.addr, "XIMPreeditNone")) - preedit_style = XIMPreeditNone; - } - if(!preedit_style) - preedit_style = XIMPreeditNothing; - - (void) sprintf (res_name, "%s%s%s", - im->core.res_name != NULL ? im->core.res_name : "*", - im->core.res_name != NULL ? dotximdot : ximdot, - "statusDefaultStyle"); - (void) sprintf (res_class, "%s%s%s", - im->core.res_class != NULL ? im->core.res_class : "*", - im->core.res_class != NULL ? dotXimdot : Ximdot, - "StatusDefaultStyle"); - if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { - if(!strcmp(value.addr, "XIMStatusArea")) - status_style = XIMStatusArea; - else if(!strcmp(value.addr, "XIMStatusCallbacks")) - status_style = XIMStatusCallbacks; - else if(!strcmp(value.addr, "XIMStatusNothing")) - status_style = XIMStatusNothing; - else if(!strcmp(value.addr, "XIMStatusNone")) - status_style = XIMStatusNone; - } - if(!status_style) - status_style = XIMStatusNothing; - - if(!(imstyles = (XIMStyles *)Xmalloc(sizeof(XIMStyles) + sizeof(XIMStyle)))){ - if (res_name != res_name_buf) Xfree (res_name); - if (res_class != res_class_buf) Xfree (res_class); - return; - } - imstyles->count_styles = 1; - imstyles->supported_styles = - (XIMStyle *)((char *)imstyles + sizeof(XIMStyles)); - imstyles->supported_styles[0] = preedit_style | status_style; - im->private.proto.default_styles = imstyles; - if (res_name != res_name_buf) Xfree (res_name); - if (res_class != res_class_buf) Xfree (res_class); -} -#endif /* XIM_CONNECTABLE */ - -static const char name_table[] = - /* 0 */ XNQueryInputStyle"\0" - /* 16 */ XNClientWindow"\0" - /* 29 */ XNInputStyle"\0" - /* 40 */ XNFocusWindow"\0" - /* 52 */ XNResourceName"\0" - /* 65 */ XNResourceClass"\0" - /* 79 */ XNGeometryCallback"\0" - /* 96 */ XNDestroyCallback"\0" - /* 112 */ XNFilterEvents"\0" - /* 125 */ XNPreeditStartCallback"\0" - /* 146 */ XNPreeditDoneCallback"\0" - /* 166 */ XNPreeditDrawCallback"\0" - /* 186 */ XNPreeditCaretCallback"\0" - /* 207 */ XNPreeditStateNotifyCallback"\0" - /* 234 */ XNPreeditAttributes"\0" - /* 252 */ XNStatusStartCallback"\0" - /* 272 */ XNStatusDoneCallback"\0" - /* 291 */ XNStatusDrawCallback"\0" - /* 310 */ XNStatusAttributes"\0" - /* 327 */ XNArea"\0" - /* 332 */ XNAreaNeeded"\0" - /* 343 */ XNSpotLocation"\0" - /* 356 */ XNColormap"\0" - /* 365 */ XNStdColormap"\0" - /* 377 */ XNForeground"\0" - /* 388 */ XNBackground"\0" - /* 399 */ XNBackgroundPixmap"\0" - /* 416 */ XNFontSet"\0" - /* 424 */ XNLineSpace"\0" - /* 434 */ XNCursor"\0" - /* 441 */ XNQueryIMValuesList"\0" - /* 459 */ XNQueryICValuesList"\0" - /* 477 */ XNVisiblePosition"\0" - /* 493 */ XNStringConversionCallback"\0" - /* 518 */ XNStringConversion"\0" - /* 535 */ XNResetState"\0" - /* 546 */ XNHotKey"\0" - /* 553 */ XNHotKeyState"\0" - /* 565 */ XNPreeditState -; - -#define OFFSET_XNQUERYINPUTSTYLE 0 -#define OFFSET_XNCLIENTWINDOW 16 -#define OFFSET_XNINPUTSTYLE 29 -#define OFFSET_XNFOCUSWINDOW 40 -#define OFFSET_XNRESOURCENAME 52 -#define OFFSET_XNRESOURCECLASS 65 -#define OFFSET_XNGEOMETRYCALLBACK 79 -#define OFFSET_XNDESTROYCALLBACK 96 -#define OFFSET_XNFILTEREVENTS 112 -#define OFFSET_XNPREEDITSTARTCALLBACK 125 -#define OFFSET_XNPREEDITDONECALLBACK 146 -#define OFFSET_XNPREEDITDRAWCALLBACK 166 -#define OFFSET_XNPREEDITCARETCALLBACK 186 -#define OFFSET_XNPREEDITSTATENOTIFYCALLBACK 207 -#define OFFSET_XNPREEDITATTRIBUTES 234 -#define OFFSET_XNSTATUSSTARTCALLBACK 252 -#define OFFSET_XNSTATUSDONECALLBACK 272 -#define OFFSET_XNSTATUSDRAWCALLBACK 291 -#define OFFSET_XNSTATUSATTRIBUTES 310 -#define OFFSET_XNAREA 327 -#define OFFSET_XNAREANEEDED 332 -#define OFFSET_XNSPOTLOCATION 343 -#define OFFSET_XNCOLORMAP 356 -#define OFFSET_XNSTDCOLORMAP 365 -#define OFFSET_XNFOREGROUND 377 -#define OFFSET_XNBACKGROUND 388 -#define OFFSET_XNBACKGROUNDPIXMAP 399 -#define OFFSET_XNFONTSET 416 -#define OFFSET_XNLINESPACE 424 -#define OFFSET_XNCURSOR 434 -#define OFFSET_XNQUERYIMVALUESLIST 441 -#define OFFSET_XNQUERYICVALUESLIST 459 -#define OFFSET_XNVISIBLEPOSITION 477 -#define OFFSET_XNSTRINGCONVERSIONCALLBACK 493 -#define OFFSET_XNSTRINGCONVERSION 518 -#define OFFSET_XNRESETSTATE 535 -#define OFFSET_XNHOTKEY 546 -#define OFFSET_XNHOTKEYSTATE 553 -#define OFFSET_XNPREEDITSTATE 565 - -/* offsets into name_table */ -static const unsigned short supported_local_im_values_list[] = { - OFFSET_XNQUERYINPUTSTYLE, - OFFSET_XNRESOURCENAME, - OFFSET_XNRESOURCECLASS, - OFFSET_XNDESTROYCALLBACK, - OFFSET_XNQUERYIMVALUESLIST, - OFFSET_XNQUERYICVALUESLIST, - OFFSET_XNVISIBLEPOSITION -}; - -/* offsets into name_table */ -static const unsigned short supported_local_ic_values_list[] = { - OFFSET_XNINPUTSTYLE, - OFFSET_XNCLIENTWINDOW, - OFFSET_XNFOCUSWINDOW, - OFFSET_XNRESOURCENAME, - OFFSET_XNRESOURCECLASS, - OFFSET_XNGEOMETRYCALLBACK, - OFFSET_XNFILTEREVENTS, - OFFSET_XNDESTROYCALLBACK, - OFFSET_XNSTRINGCONVERSIONCALLBACK, - OFFSET_XNSTRINGCONVERSIONCALLBACK, - OFFSET_XNRESETSTATE, - OFFSET_XNHOTKEY, - OFFSET_XNHOTKEYSTATE, - OFFSET_XNPREEDITATTRIBUTES, - OFFSET_XNSTATUSATTRIBUTES, - OFFSET_XNAREA, - OFFSET_XNAREANEEDED, - OFFSET_XNSPOTLOCATION, - OFFSET_XNCOLORMAP, - OFFSET_XNSTDCOLORMAP, - OFFSET_XNFOREGROUND, - OFFSET_XNBACKGROUND, - OFFSET_XNBACKGROUNDPIXMAP, - OFFSET_XNFONTSET, - OFFSET_XNLINESPACE, - OFFSET_XNCURSOR, - OFFSET_XNPREEDITSTARTCALLBACK, - OFFSET_XNPREEDITDONECALLBACK, - OFFSET_XNPREEDITDRAWCALLBACK, - OFFSET_XNPREEDITCARETCALLBACK, - OFFSET_XNSTATUSSTARTCALLBACK, - OFFSET_XNSTATUSDONECALLBACK, - OFFSET_XNSTATUSDRAWCALLBACK, - OFFSET_XNPREEDITSTATE, - OFFSET_XNPREEDITSTATENOTIFYCALLBACK -}; - -static XIMStyle const supported_local_styles[] = { - XIMPreeditNone | XIMStatusNone, - XIMPreeditNothing | XIMStatusNothing, - 0 /* dummy */ -}; - -Private Bool -_XimDefaultStyles( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, /* unused */ - unsigned long mode) /* unused */ -{ - XIMStyles *styles; - XIMStyles **out; - register int i; - unsigned int n; - int len; - XPointer tmp; - - n = XIMNumber(supported_local_styles) - 1; - len = sizeof(XIMStyles) + sizeof(XIMStyle) * n; - if(!(tmp = (XPointer)Xmalloc(len))) { - return False; - } - bzero(tmp, len); - - styles = (XIMStyles *)tmp; - if (n > 0) { - styles->count_styles = (unsigned short)n; - styles->supported_styles = - (XIMStyle *)((char *)tmp + sizeof(XIMStyles)); - for(i = 0; i < n; i++) { - styles->supported_styles[i] = supported_local_styles[i]; - } - } - - out = (XIMStyles **)((char *)top + info->offset); - *out = styles; - return True; -} - -Private Bool -_XimDefaultIMValues( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, /* unused */ - unsigned long mode) /* unused */ -{ - XIMValuesList *values_list; - XIMValuesList **out; - register int i; - unsigned int n; - int len; - XPointer tmp; - - n = XIMNumber(supported_local_im_values_list); - len = sizeof(XIMValuesList) + sizeof(char **) * n; - if(!(tmp = (XPointer)Xmalloc(len))) { - return False; - } - bzero(tmp, len); - - values_list = (XIMValuesList *)tmp; - if (n > 0) { - values_list->count_values = (unsigned short)n; - values_list->supported_values - = (char **)((char *)tmp + sizeof(XIMValuesList)); - for(i = 0; i < n; i++) { - values_list->supported_values[i] = - (char *)name_table + supported_local_im_values_list[i]; - } - } - - out = (XIMValuesList **)((char *)top + info->offset); - *out = values_list; - return True; -} - -Private Bool -_XimDefaultICValues( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, /* unused */ - unsigned long mode) /* unused */ -{ - XIMValuesList *values_list; - XIMValuesList **out; - register int i; - unsigned int n; - int len; - XPointer tmp; - - n = XIMNumber(supported_local_ic_values_list); - len = sizeof(XIMValuesList) + sizeof(char **) * n; - if(!(tmp = (XPointer)Xmalloc(len))) { - return False; - } - bzero(tmp, len); - - values_list = (XIMValuesList *)tmp; - if (n > 0) { - values_list->count_values = (unsigned short)n; - values_list->supported_values - = (char **)((char *)tmp + sizeof(XIMValuesList)); - for(i = 0; i < n; i++) { - values_list->supported_values[i] = - (char *)name_table + supported_local_ic_values_list[i]; - } - } - - out = (XIMValuesList **)((char *)top + info->offset); - *out = values_list; - return True; -} - -Private Bool -_XimDefaultVisiblePos( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, /* unused */ - unsigned long mode) /* unused */ -{ - Bool *out; - - out = (Bool *)((char *)top + info->offset); - *out = False; - return True; -} - -Private Bool -_XimDefaultFocusWindow( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Window *out; - - if(ic->core.client_window == (Window)NULL) { - return True; - } - - out = (Window *)((char *)top + info->offset); - *out = ic->core.client_window; - return True; -} - -Private Bool -_XimDefaultResName( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - char **out; - - if(im->core.res_name == (char *)NULL) { - return True; - } - - out = (char **)((char *)top + info->offset); - *out = im->core.res_name; - return True; -} - -Private Bool -_XimDefaultResClass( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - char **out; - - if(im->core.res_class == (char *)NULL) { - return True; - } - - out = (char **)((char *)top + info->offset); - *out = im->core.res_class; - return True; -} - -Private Bool -_XimDefaultDestroyCB( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - XIMCallback *out; - - out = (XIMCallback *)((char *)top + info->offset); - *out = im->core.destroy_callback; - return True; -} - -Private Bool -_XimDefaultResetState( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - XIMResetState *out; - - out = (XIMResetState *)((char *)top + info->offset); - *out = XIMInitialState; - return True; -} - -Private Bool -_XimDefaultHotKeyState( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - XIMHotKeyState *out; - - out = (XIMHotKeyState *)((char *)top + info->offset); - *out = XIMHotKeyStateOFF; - return True; -} - -Private Bool -_XimDefaultArea( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - Window root_return; - int x_return, y_return; - unsigned int width_return, height_return; - unsigned int border_width_return; - unsigned int depth_return; - XRectangle area; - XRectangle *out; - - if(ic->core.focus_window == (Window)NULL) { - return True; - } - if(XGetGeometry(im->core.display, (Drawable)ic->core.focus_window, - &root_return, &x_return, &y_return, &width_return, - &height_return, &border_width_return, &depth_return) - == (Status)Success) { - return True; - } - area.x = 0; - area.y = 0; - area.width = width_return; - area.height = height_return; - - out = (XRectangle *)((char *)top + info->offset); - *out = area; - return True; -} - -Private Bool -_XimDefaultColormap( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - XWindowAttributes win_attr; - Colormap *out; - - if(ic->core.client_window == (Window)NULL) { - return True; - } - if(XGetWindowAttributes(im->core.display, ic->core.client_window, - &win_attr) == (Status)Success) { - return True; - } - - out = (Colormap *)((char *)top + info->offset); - *out = win_attr.colormap; - return True; -} - -Private Bool -_XimDefaultStdColormap( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Atom *out; - - out = (Atom *)((char *)top + info->offset); - *out = (Atom)0; - return True; -} - -Private Bool -_XimDefaultFg( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - unsigned long fg; - unsigned long *out; - - fg = WhitePixel(im->core.display, DefaultScreen(im->core.display)); - out = (unsigned long *)((char *)top + info->offset); - *out = fg; - return True; -} - -Private Bool -_XimDefaultBg( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - Xim im = (Xim)ic->core.im; - unsigned long bg; - unsigned long *out; - - bg = BlackPixel(im->core.display, DefaultScreen(im->core.display)); - out = (unsigned long *)((char *)top + info->offset); - *out = bg; - return True; -} - -Private Bool -_XimDefaultBgPixmap( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Pixmap *out; - - out = (Pixmap *)((char *)top + info->offset); - *out = (Pixmap)0; - return True; -} - -Private Bool -_XimDefaultFontSet( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - XFontSet *out; - - out = (XFontSet *)((char *)top + info->offset); - *out = 0; - return True; -} - -Private Bool -_XimDefaultLineSpace( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Xic ic = (Xic)parm; - XFontSet fontset; - XFontSetExtents *fset_extents; - int line_space = 0; - int *out; - - if(mode & XIM_PREEDIT_ATTR) { - fontset = ic->core.preedit_attr.fontset; - } else if(mode & XIM_STATUS_ATTR) { - fontset = ic->core.status_attr.fontset; - } else { - return True; - } - if (fontset) { - fset_extents = XExtentsOfFontSet(fontset); - line_space = fset_extents->max_logical_extent.height; - } - out = (int *)((char *)top + info->offset); - *out = line_space; - return True; -} - -Private Bool -_XimDefaultCursor( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - Cursor *out; - - out = (Cursor *)((char *)top + info->offset); - *out = (Cursor)0; - return True; -} - -Private Bool -_XimDefaultPreeditState( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - XIMPreeditState *out; - - out = (XIMPreeditState *)((char *)top + info->offset); - *out = XIMPreeditDisable; - return True; -} - -Private Bool -_XimDefaultNest( - XimValueOffsetInfo info, - XPointer top, - XPointer parm, - unsigned long mode) -{ - return True; -} - -Private Bool -_XimEncodeCallback( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMCallback *out; - - out = (XIMCallback *)((char *)top + info->offset); - *out = *((XIMCallback *)val); - return True; -} - -Private Bool -_XimEncodeString( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - int len; - char *string; - char **out; - - if(val == (XPointer)NULL) { - return False; - } - len = strlen((char *)val); - if(!(string = (char *)Xmalloc(len + 1))) { - return False; - } - (void)strcpy(string, (char *)val); - string[len] = '\0'; - - out = (char **)((char *)top + info->offset); - if(*out) { - Xfree(*out); - } - *out = string; - return True; -} - -Private Bool -_XimEncodeStyle( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMStyle *out; - - out = (XIMStyle *)((char *)top + info->offset); - *out = (XIMStyle)val; - return True; -} - -Private Bool -_XimEncodeWindow( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Window *out; - - out = (Window *)((char *)top + info->offset); - *out = (Window)val; - return True; -} - -Private Bool -_XimEncodeStringConv( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - /* - * Not yet - */ - return True; -} - -Private Bool -_XimEncodeResetState( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMResetState *out; - - out = (XIMResetState *)((char *)top + info->offset); - *out = (XIMResetState)val; - return True; -} - -Private Bool -_XimEncodeHotKey( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMHotKeyTriggers *hotkey = (XIMHotKeyTriggers *)val; - XIMHotKeyTriggers **out; - XIMHotKeyTriggers *key_list; - XIMHotKeyTrigger *key; - XPointer tmp; - int num; - int len; - register int i; - - if(hotkey == (XIMHotKeyTriggers *)NULL) { - return True; - } - - if((num = hotkey->num_hot_key) == 0) { - return True; - } - - len = sizeof(XIMHotKeyTriggers) + sizeof(XIMHotKeyTrigger) * num; - if(!(tmp = (XPointer)Xmalloc(len))) { - return False; - } - - key_list = (XIMHotKeyTriggers *)tmp; - key = (XIMHotKeyTrigger *)((char *)tmp + sizeof(XIMHotKeyTriggers)); - - for(i = 0; i < num; i++) { - key[i] = hotkey->key[i]; - } - - key_list->num_hot_key = num; - key_list->key = key; - - out = (XIMHotKeyTriggers **)((char *)top + info->offset); - *out = key_list; - return True; -} - -Private Bool -_XimEncodeHotKetState( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMHotKeyState *out; - - out = (XIMHotKeyState *)((char *)top + info->offset); - *out = (XIMHotKeyState)val; - return True; -} - -Private Bool -_XimEncodeRectangle( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XRectangle *out; - - out = (XRectangle *)((char *)top + info->offset); - *out = *((XRectangle *)val); - return True; -} - -Private Bool -_XimEncodeSpot( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XPoint *out; - - out = (XPoint *)((char *)top + info->offset); - *out = *((XPoint *)val); - return True; -} - -Private Bool -_XimEncodeColormap( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Colormap *out; - - out = (Colormap *)((char *)top + info->offset); - *out = (Colormap)val; - return True; -} - -Private Bool -_XimEncodeStdColormap( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Atom *out; - - out = (Atom *)((char *)top + info->offset); - *out = (Atom)val; - return True; -} - -Private Bool -_XimEncodeLong( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - unsigned long *out; - - out = (unsigned long *)((char *)top + info->offset); - *out = (unsigned long)val; - return True; -} - -Private Bool -_XimEncodeBgPixmap( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Pixmap *out; - - out = (Pixmap *)((char *)top + info->offset); - *out = (Pixmap)val; - return True; -} - -Private Bool -_XimEncodeFontSet( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XFontSet *out; - - out = (XFontSet *)((char *)top + info->offset); - *out = (XFontSet)val; - return True; -} - -Private Bool -_XimEncodeLineSpace( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - int *out; - - out = (int *)((char *)top + info->offset); - *out = (long)val; - return True; -} - -Private Bool -_XimEncodeCursor( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Cursor *out; - - out = (Cursor *)((char *)top + info->offset); - *out = (Cursor)val; - return True; -} - -Private Bool -_XimEncodePreeditState( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMPreeditState *out; - - out = (XIMPreeditState *)((char *)top + info->offset); - *out = (XIMPreeditState)val; - return True; -} - -Private Bool -_XimEncodeNest( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - return True; -} - -Private Bool -_XimDecodeStyles( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMStyles *styles; - XIMStyles *out; - register int i; - unsigned int num; - int len; - XPointer tmp; - - if(val == (XPointer)NULL) { - return False; - } - - styles = *((XIMStyles **)((char *)top + info->offset)); - num = styles->count_styles; - - len = sizeof(XIMStyles) + sizeof(XIMStyle) * num; - if(!(tmp = (XPointer)Xmalloc(len))) { - return False; - } - bzero(tmp, len); - - out = (XIMStyles *)tmp; - if(num >0) { - out->count_styles = (unsigned short)num; - out->supported_styles = (XIMStyle *)((char *)tmp + sizeof(XIMStyles)); - - for(i = 0; i < num; i++) { - out->supported_styles[i] = styles->supported_styles[i]; - } - } - *((XIMStyles **)val) = out; - return True; -} - -Private Bool -_XimDecodeValues( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMValuesList *values_list; - XIMValuesList *out; - register int i; - unsigned int num; - int len; - XPointer tmp; - - if(val == (XPointer)NULL) { - return False; - } - - values_list = *((XIMValuesList **)((char *)top + info->offset)); - num = values_list->count_values; - - len = sizeof(XIMValuesList) + sizeof(char **) * num; - if(!(tmp = (char *)Xmalloc(len))) { - return False; - } - bzero(tmp, len); - - out = (XIMValuesList *)tmp; - if(num) { - out->count_values = (unsigned short)num; - out->supported_values = (char **)((char *)tmp + sizeof(XIMValuesList)); - - for(i = 0; i < num; i++) { - out->supported_values[i] = values_list->supported_values[i]; - } - } - *((XIMValuesList **)val) = out; - return True; -} - -Private Bool -_XimDecodeCallback( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMCallback *in; - XIMCallback *callback; - - in = (XIMCallback *)((char *)top + info->offset); - if(!(callback = (XIMCallback *)Xmalloc(sizeof(XIMCallback)))) { - return False; - } - callback->client_data = in->client_data; - callback->callback = in->callback; - - *((XIMCallback **)val) = callback; - return True; -} - -Private Bool -_XimDecodeString( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - int len = 0; - char *in; - char *string; - - in = *((char **)((char *)top + info->offset)); - if(in != (char *)NULL) { - len = strlen(in); - } - if(!(string = (char *)Xmalloc(len + 1))) { - return False; - } - if(in != (char *)NULL) { - (void)strcpy(string, in); - } - string[len] = '\0'; - *((char **)val) = string; - return True; -} - -Private Bool -_XimDecodeBool( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Bool *in; - - in = (Bool *)((char *)top + info->offset); - *((Bool *)val) = *in; - return True; -} - -Private Bool -_XimDecodeStyle( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMStyle *in; - - in = (XIMStyle *)((char *)top + info->offset); - *((XIMStyle *)val) = *in; - return True; -} - -Private Bool -_XimDecodeWindow( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Window *in; - - in = (Window *)((char *)top + info->offset); - *((Window *)val) = *in; - return True; -} - -Private Bool -_XimDecodeStringConv( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - /* - * Not yet - */ - return True; -} - -Private Bool -_XimDecodeResetState( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMResetState *in; - - in = (XIMResetState *)((char *)top + info->offset); - *((XIMResetState *)val) = *in; - return True; -} - -Private Bool -_XimDecodeHotKey( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMHotKeyTriggers *in; - XIMHotKeyTriggers *hotkey; - XIMHotKeyTrigger *key; - XPointer tmp; - int num; - int len; - register int i; - - in = *((XIMHotKeyTriggers **)((char *)top + info->offset)); - num = in->num_hot_key; - len = sizeof(XIMHotKeyTriggers) + sizeof(XIMHotKeyTrigger) * num; - if(!(tmp = (XPointer)Xmalloc(len))) { - return False; - } - - hotkey = (XIMHotKeyTriggers *)tmp; - key = (XIMHotKeyTrigger *)((char *)tmp + sizeof(XIMHotKeyTriggers)); - - for(i = 0; i < num; i++) { - key[i] = in->key[i]; - } - hotkey->num_hot_key = num; - hotkey->key = key; - - *((XIMHotKeyTriggers **)val) = hotkey; - return True; -} - -Private Bool -_XimDecodeHotKetState( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMHotKeyState *in; - - in = (XIMHotKeyState *)((char *)top + info->offset); - *((XIMHotKeyState *)val) = *in; - return True; -} - -Private Bool -_XimDecodeRectangle( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XRectangle *in; - XRectangle *rect; - - in = (XRectangle *)((char *)top + info->offset); - if(!(rect = (XRectangle *)Xmalloc(sizeof(XRectangle)))) { - return False; - } - *rect = *in; - *((XRectangle **)val) = rect; - return True; -} - -Private Bool -_XimDecodeSpot( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XPoint *in; - XPoint *spot; - - in = (XPoint *)((char *)top + info->offset); - if(!(spot = (XPoint *)Xmalloc(sizeof(XPoint)))) { - return False; - } - *spot = *in; - *((XPoint **)val) = spot; - return True; -} - -Private Bool -_XimDecodeColormap( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Colormap *in; - - in = (Colormap *)((char *)top + info->offset); - *((Colormap *)val) = *in; - return True; -} - -Private Bool -_XimDecodeStdColormap( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Atom *in; - - in = (Atom *)((char *)top + info->offset); - *((Atom *)val) = *in; - return True; -} - -Private Bool -_XimDecodeLong( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - unsigned long *in; - - in = (unsigned long *)((char *)top + info->offset); - *((unsigned long *)val) = *in; - return True; -} - -Private Bool -_XimDecodeBgPixmap( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Pixmap *in; - - in = (Pixmap *)((char *)top + info->offset); - *((Pixmap *)val) = *in; - return True; -} - -Private Bool -_XimDecodeFontSet( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XFontSet *in; - - in = (XFontSet *)((char *)top + info->offset); - *((XFontSet *)val) = *in; - return True; -} - -Private Bool -_XimDecodeLineSpace( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - int *in; - - in = (int *)((char *)top + info->offset); - *((int *)val) = *in; - return True; -} - -Private Bool -_XimDecodeCursor( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - Cursor *in; - - in = (Cursor *)((char *)top + info->offset); - *((Cursor *)val) = *in; - return True; -} - -Private Bool -_XimDecodePreeditState( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - XIMPreeditState *in; - - in = (XIMPreeditState *)((char *)top + info->offset); - *((XIMPreeditState *)val) = *in; - return True; -} - -Private Bool -_XimDecodeNest( - XimValueOffsetInfo info, - XPointer top, - XPointer val) -{ - return True; -} - -static XIMResource im_resources[] = { - {XNQueryInputStyle, 0, XimType_XIMStyles, 0, 0, 0}, - {XNDestroyCallback, 0, 0, 0, 0, 0}, - {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, - {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, - {XNQueryIMValuesList, 0, 0, 0, 0, 0}, - {XNQueryICValuesList, 0, 0, 0, 0, 0}, - {XNVisiblePosition, 0, 0, 0, 0, 0} -}; - -static XIMResource im_inner_resources[] = { - {XNDestroyCallback, 0, 0, 0, 0, 0}, - {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, - {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, - {XNQueryIMValuesList, 0, 0, 0, 0, 0}, - {XNQueryICValuesList, 0, 0, 0, 0, 0}, - {XNVisiblePosition, 0, 0, 0, 0, 0} -}; - -static XIMResource ic_resources[] = { - {XNInputStyle, 0, XimType_CARD32, 0, 0, 0}, - {XNClientWindow, 0, XimType_Window, 0, 0, 0}, - {XNFocusWindow, 0, XimType_Window, 0, 0, 0}, - {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, - {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, - {XNGeometryCallback, 0, 0, 0, 0, 0}, - {XNFilterEvents, 0, XimType_CARD32, 0, 0, 0}, - {XNDestroyCallback, 0, 0, 0, 0, 0}, - {XNStringConversionCallback, 0, 0, 0, 0, 0}, - {XNStringConversion, 0, XimType_XIMStringConversion,0, 0, 0}, - {XNResetState, 0, 0, 0, 0, 0}, - {XNHotKey, 0, XimType_XIMHotKeyTriggers,0, 0, 0}, - {XNHotKeyState, 0, XimType_XIMHotKeyState, 0, 0, 0}, - {XNPreeditAttributes, 0, XimType_NEST, 0, 0, 0}, - {XNStatusAttributes, 0, XimType_NEST, 0, 0, 0}, - {XNArea, 0, XimType_XRectangle, 0, 0, 0}, - {XNAreaNeeded, 0, XimType_XRectangle, 0, 0, 0}, - {XNSpotLocation, 0, XimType_XPoint, 0, 0, 0}, - {XNColormap, 0, XimType_CARD32, 0, 0, 0}, - {XNStdColormap, 0, XimType_CARD32, 0, 0, 0}, - {XNForeground, 0, XimType_CARD32, 0, 0, 0}, - {XNBackground, 0, XimType_CARD32, 0, 0, 0}, - {XNBackgroundPixmap, 0, XimType_CARD32, 0, 0, 0}, - {XNFontSet, 0, XimType_XFontSet, 0, 0, 0}, - {XNLineSpace, 0, XimType_CARD32, 0, 0, 0}, - {XNCursor, 0, XimType_CARD32, 0, 0, 0}, - {XNPreeditStartCallback, 0, 0, 0, 0, 0}, - {XNPreeditDoneCallback, 0, 0, 0, 0, 0}, - {XNPreeditDrawCallback, 0, 0, 0, 0, 0}, - {XNPreeditCaretCallback, 0, 0, 0, 0, 0}, - {XNStatusStartCallback, 0, 0, 0, 0, 0}, - {XNStatusDoneCallback, 0, 0, 0, 0, 0}, - {XNStatusDrawCallback, 0, 0, 0, 0, 0}, - {XNPreeditState, 0, 0, 0, 0, 0}, - {XNPreeditStateNotifyCallback, 0, 0, 0, 0, 0}, -}; - -static XIMResource ic_inner_resources[] = { - {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, - {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, - {XNGeometryCallback, 0, 0, 0, 0, 0}, - {XNDestroyCallback, 0, 0, 0, 0, 0}, - {XNStringConversionCallback, 0, 0, 0, 0, 0}, - {XNPreeditStartCallback, 0, 0, 0, 0, 0}, - {XNPreeditDoneCallback, 0, 0, 0, 0, 0}, - {XNPreeditDrawCallback, 0, 0, 0, 0, 0}, - {XNPreeditCaretCallback, 0, 0, 0, 0, 0}, - {XNStatusStartCallback, 0, 0, 0, 0, 0}, - {XNStatusDoneCallback, 0, 0, 0, 0, 0}, - {XNStatusDrawCallback, 0, 0, 0, 0, 0}, - {XNPreeditStateNotifyCallback, 0, 0, 0, 0, 0}, -}; - -static XimValueOffsetInfoRec im_attr_info[] = { - {OFFSET_XNQUERYINPUTSTYLE, 0, - XOffsetOf(XimDefIMValues, styles), - _XimDefaultStyles, NULL, _XimDecodeStyles}, - - {OFFSET_XNDESTROYCALLBACK, 0, - XOffsetOf(XimDefIMValues, destroy_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNRESOURCENAME, 0, - XOffsetOf(XimDefIMValues, res_name), - NULL, _XimEncodeString, _XimDecodeString}, - - {OFFSET_XNRESOURCECLASS, 0, - XOffsetOf(XimDefIMValues, res_class), - NULL, _XimEncodeString, _XimDecodeString}, - - {OFFSET_XNQUERYIMVALUESLIST, 0, - XOffsetOf(XimDefIMValues, im_values_list), - _XimDefaultIMValues, NULL, _XimDecodeValues}, - - {OFFSET_XNQUERYICVALUESLIST, 0, - XOffsetOf(XimDefIMValues, ic_values_list), - _XimDefaultICValues, NULL, _XimDecodeValues}, - - {OFFSET_XNVISIBLEPOSITION, 0, - XOffsetOf(XimDefIMValues, visible_position), - _XimDefaultVisiblePos, NULL, _XimDecodeBool} -}; - -static XimValueOffsetInfoRec ic_attr_info[] = { - {OFFSET_XNINPUTSTYLE, 0, - XOffsetOf(XimDefICValues, input_style), - NULL, _XimEncodeStyle, _XimDecodeStyle}, - - {OFFSET_XNCLIENTWINDOW, 0, - XOffsetOf(XimDefICValues, client_window), - NULL, _XimEncodeWindow, _XimDecodeWindow}, - - {OFFSET_XNFOCUSWINDOW, 0, - XOffsetOf(XimDefICValues, focus_window), - _XimDefaultFocusWindow, _XimEncodeWindow, _XimDecodeWindow}, - - {OFFSET_XNRESOURCENAME, 0, - XOffsetOf(XimDefICValues, res_name), - _XimDefaultResName, _XimEncodeString, _XimDecodeString}, - - {OFFSET_XNRESOURCECLASS, 0, - XOffsetOf(XimDefICValues, res_class), - _XimDefaultResClass, _XimEncodeString, _XimDecodeString}, - - {OFFSET_XNGEOMETRYCALLBACK, 0, - XOffsetOf(XimDefICValues, geometry_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNFILTEREVENTS, 0, - XOffsetOf(XimDefICValues, filter_events), - NULL, NULL, _XimDecodeLong}, - - {OFFSET_XNDESTROYCALLBACK, 0, - XOffsetOf(XimDefICValues, destroy_callback), - _XimDefaultDestroyCB, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNSTRINGCONVERSIONCALLBACK, 0, - XOffsetOf(XimDefICValues, string_conversion_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNSTRINGCONVERSION, 0, - XOffsetOf(XimDefICValues, string_conversion), - NULL, _XimEncodeStringConv, _XimDecodeStringConv}, - - {OFFSET_XNRESETSTATE, 0, - XOffsetOf(XimDefICValues, reset_state), - _XimDefaultResetState, _XimEncodeResetState, _XimDecodeResetState}, - - {OFFSET_XNHOTKEY, 0, - XOffsetOf(XimDefICValues, hotkey), - NULL, _XimEncodeHotKey, _XimDecodeHotKey}, - - {OFFSET_XNHOTKEYSTATE, 0, - XOffsetOf(XimDefICValues, hotkey_state), - _XimDefaultHotKeyState, _XimEncodeHotKetState, _XimDecodeHotKetState}, - - {OFFSET_XNPREEDITATTRIBUTES, 0, - XOffsetOf(XimDefICValues, preedit_attr), - _XimDefaultNest, _XimEncodeNest, _XimDecodeNest}, - - {OFFSET_XNSTATUSATTRIBUTES, 0, - XOffsetOf(XimDefICValues, status_attr), - _XimDefaultNest, _XimEncodeNest, _XimDecodeNest}, -}; - -static XimValueOffsetInfoRec ic_pre_attr_info[] = { - {OFFSET_XNAREA, 0, - XOffsetOf(ICPreeditAttributes, area), - _XimDefaultArea, _XimEncodeRectangle, _XimDecodeRectangle}, - - {OFFSET_XNAREANEEDED, 0, - XOffsetOf(ICPreeditAttributes, area_needed), - NULL, _XimEncodeRectangle, _XimDecodeRectangle}, - - {OFFSET_XNSPOTLOCATION, 0, - XOffsetOf(ICPreeditAttributes, spot_location), - NULL, _XimEncodeSpot, _XimDecodeSpot}, - - {OFFSET_XNCOLORMAP, 0, - XOffsetOf(ICPreeditAttributes, colormap), - _XimDefaultColormap, _XimEncodeColormap, _XimDecodeColormap}, - - {OFFSET_XNSTDCOLORMAP, 0, - XOffsetOf(ICPreeditAttributes, std_colormap), - _XimDefaultStdColormap, _XimEncodeStdColormap, _XimDecodeStdColormap}, - - {OFFSET_XNFOREGROUND, 0, - XOffsetOf(ICPreeditAttributes, foreground), - _XimDefaultFg, _XimEncodeLong, _XimDecodeLong}, - - {OFFSET_XNBACKGROUND, 0, - XOffsetOf(ICPreeditAttributes, background), - _XimDefaultBg, _XimEncodeLong, _XimDecodeLong}, - - {OFFSET_XNBACKGROUNDPIXMAP, 0, - XOffsetOf(ICPreeditAttributes, background_pixmap), - _XimDefaultBgPixmap, _XimEncodeBgPixmap, _XimDecodeBgPixmap}, - - {OFFSET_XNFONTSET, 0, - XOffsetOf(ICPreeditAttributes, fontset), - _XimDefaultFontSet, _XimEncodeFontSet, _XimDecodeFontSet}, - - {OFFSET_XNLINESPACE, 0, - XOffsetOf(ICPreeditAttributes, line_spacing), - _XimDefaultLineSpace, _XimEncodeLineSpace, _XimDecodeLineSpace}, - - {OFFSET_XNCURSOR, 0, - XOffsetOf(ICPreeditAttributes, cursor), - _XimDefaultCursor, _XimEncodeCursor, _XimDecodeCursor}, - - {OFFSET_XNPREEDITSTARTCALLBACK, 0, - XOffsetOf(ICPreeditAttributes, start_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNPREEDITDONECALLBACK, 0, - XOffsetOf(ICPreeditAttributes, done_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNPREEDITDRAWCALLBACK, 0, - XOffsetOf(ICPreeditAttributes, draw_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNPREEDITCARETCALLBACK, 0, - XOffsetOf(ICPreeditAttributes, caret_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNPREEDITSTATE, 0, - XOffsetOf(ICPreeditAttributes, preedit_state), - _XimDefaultPreeditState, _XimEncodePreeditState,_XimDecodePreeditState}, - - {OFFSET_XNPREEDITSTATENOTIFYCALLBACK, 0, - XOffsetOf(ICPreeditAttributes, state_notify_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, -}; - -static XimValueOffsetInfoRec ic_sts_attr_info[] = { - {OFFSET_XNAREA, 0, - XOffsetOf(ICStatusAttributes, area), - _XimDefaultArea, _XimEncodeRectangle, _XimDecodeRectangle}, - - {OFFSET_XNAREANEEDED, 0, - XOffsetOf(ICStatusAttributes, area_needed), - NULL, _XimEncodeRectangle, _XimDecodeRectangle}, - - {OFFSET_XNCOLORMAP, 0, - XOffsetOf(ICStatusAttributes, colormap), - _XimDefaultColormap, _XimEncodeColormap, _XimDecodeColormap}, - - {OFFSET_XNSTDCOLORMAP, 0, - XOffsetOf(ICStatusAttributes, std_colormap), - _XimDefaultStdColormap, _XimEncodeStdColormap, _XimDecodeStdColormap}, - - {OFFSET_XNFOREGROUND, 0, - XOffsetOf(ICStatusAttributes, foreground), - _XimDefaultFg, _XimEncodeLong, _XimDecodeLong}, - - {OFFSET_XNBACKGROUND, 0, - XOffsetOf(ICStatusAttributes, background), - _XimDefaultBg, _XimEncodeLong, _XimDecodeLong}, - - {OFFSET_XNBACKGROUNDPIXMAP, 0, - XOffsetOf(ICStatusAttributes, background_pixmap), - _XimDefaultBgPixmap, _XimEncodeBgPixmap, _XimDecodeBgPixmap}, - - {OFFSET_XNFONTSET, 0, - XOffsetOf(ICStatusAttributes, fontset), - _XimDefaultFontSet, _XimEncodeFontSet, _XimDecodeFontSet}, - - {OFFSET_XNLINESPACE, 0, - XOffsetOf(ICStatusAttributes, line_spacing), - _XimDefaultLineSpace, _XimEncodeLineSpace, _XimDecodeLineSpace}, - - {OFFSET_XNCURSOR, 0, - XOffsetOf(ICStatusAttributes, cursor), - _XimDefaultCursor, _XimEncodeCursor, _XimDecodeCursor}, - - {OFFSET_XNSTATUSSTARTCALLBACK, 0, - XOffsetOf(ICStatusAttributes, start_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNSTATUSDONECALLBACK, 0, - XOffsetOf(ICStatusAttributes, done_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback}, - - {OFFSET_XNSTATUSDRAWCALLBACK, 0, - XOffsetOf(ICStatusAttributes, draw_callback), - NULL, _XimEncodeCallback, _XimDecodeCallback} -}; - -typedef struct _XimIMMode { - unsigned short name_offset; - unsigned short mode; -} XimIMMode; - -static const XimIMMode im_mode[] = { - {OFFSET_XNQUERYINPUTSTYLE, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)}, - {OFFSET_XNDESTROYCALLBACK, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_SET | XIM_MODE_IM_GET)}, - {OFFSET_XNRESOURCENAME, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_SET | XIM_MODE_IM_GET)}, - {OFFSET_XNRESOURCECLASS, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_SET | XIM_MODE_IM_GET)}, - {OFFSET_XNQUERYIMVALUESLIST, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)}, - {OFFSET_XNQUERYICVALUESLIST, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)}, - {OFFSET_XNVISIBLEPOSITION, - (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)} -}; - -typedef struct _XimICMode { - unsigned short name_offset; - unsigned short preedit_callback_mode; - unsigned short preedit_position_mode; - unsigned short preedit_area_mode; - unsigned short preedit_nothing_mode; - unsigned short preedit_none_mode; - unsigned short status_callback_mode; - unsigned short status_area_mode; - unsigned short status_nothing_mode; - unsigned short status_none_mode; -} XimICMode; - -static const XimICMode ic_mode[] = { - {OFFSET_XNINPUTSTYLE, - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), - (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET), - (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET), - (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET), - (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET)}, - {OFFSET_XNCLIENTWINDOW, - (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), - 0, - (XIM_MODE_STS_ONCE | XIM_MODE_STS_GET), - (XIM_MODE_STS_ONCE | XIM_MODE_STS_GET), - (XIM_MODE_STS_ONCE | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNFOCUSWINDOW, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNRESOURCENAME, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNRESOURCECLASS, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNGEOMETRYCALLBACK, - 0, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0, - 0}, - {OFFSET_XNFILTEREVENTS, - XIM_MODE_PRE_GET, - XIM_MODE_PRE_GET, - XIM_MODE_PRE_GET, - XIM_MODE_PRE_GET, - 0, - XIM_MODE_STS_GET, - XIM_MODE_STS_GET, - XIM_MODE_STS_GET, - XIM_MODE_STS_GET}, - {OFFSET_XNDESTROYCALLBACK, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0}, - {OFFSET_XNSTRINGCONVERSIONCALLBACK, - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0}, - {OFFSET_XNSTRINGCONVERSION, - XIM_MODE_PRE_SET, - XIM_MODE_PRE_SET, - XIM_MODE_PRE_SET, - XIM_MODE_PRE_SET, - XIM_MODE_PRE_SET, - 0, - 0, - 0, - 0}, - {OFFSET_XNRESETSTATE, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNHOTKEY, - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNHOTKEYSTATE, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNPREEDITATTRIBUTES, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNSTATUSATTRIBUTES, - 0, - 0, - 0, - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNAREA, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0, - 0}, - {OFFSET_XNAREANEEDED, - 0, - 0, - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - (XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0, - 0}, - {OFFSET_XNSPOTLOCATION, - 0, /*(XIM_MODE_PRE_SET | XIM_MODE_PRE_GET),*/ - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0}, - {OFFSET_XNCOLORMAP, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNSTDCOLORMAP, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNFOREGROUND, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNBACKGROUND, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNBACKGROUNDPIXMAP, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNFONTSET, - 0, - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNLINESPACE, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNCURSOR, - 0, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0}, - {OFFSET_XNPREEDITSTARTCALLBACK, - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNPREEDITDONECALLBACK, - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNPREEDITDRAWCALLBACK, - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNPREEDITCARETCALLBACK, - (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNPREEDITSTATE, - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNPREEDITSTATENOTIFYCALLBACK, - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), - 0, - 0, - 0, - 0, - 0}, - {OFFSET_XNSTATUSSTARTCALLBACK, - 0, - 0, - 0, - 0, - 0, - (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0, - 0, - 0}, - {OFFSET_XNSTATUSDONECALLBACK, - 0, - 0, - 0, - 0, - 0, - (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0, - 0, - 0}, - {OFFSET_XNSTATUSDRAWCALLBACK, - 0, - 0, - 0, - 0, - 0, - (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), - 0, - 0, - 0} -}; - -/* the quarks are separated from im_mode/ic_mode so those arrays - * can be const. - */ -static XrmQuark im_mode_quark[sizeof(im_mode) / sizeof(im_mode[0])]; -static XrmQuark ic_mode_quark[sizeof(ic_mode) / sizeof(ic_mode[0])]; - -Private Bool -_XimSetResourceList( - XIMResourceList *res_list, - unsigned int *list_num, - XIMResourceList resource, - unsigned int num_resource, - unsigned short id) -{ - register int i; - int len; - XIMResourceList res; - - len = sizeof(XIMResource) * num_resource; - if(!(res = (XIMResourceList)Xmalloc(len))) { - return False; - } - bzero((char *)res, len); - - for(i = 0; i < num_resource; i++, id++) { - res[i] = resource[i]; - res[i].id = id; - } - - _XIMCompileResourceList(res, num_resource); - *res_list = res; - *list_num = num_resource; - return True; -} - -Public Bool -_XimSetIMResourceList( - XIMResourceList *res_list, - unsigned int *list_num) -{ - return _XimSetResourceList(res_list, list_num, - im_resources, XIMNumber(im_resources), 100); -} - -Public Bool -_XimSetICResourceList( - XIMResourceList *res_list, - unsigned int *list_num) -{ - return _XimSetResourceList(res_list, list_num, - ic_resources, XIMNumber(ic_resources), 200); -} - -Public Bool -_XimSetInnerIMResourceList( - XIMResourceList *res_list, - unsigned int *list_num) -{ - return _XimSetResourceList(res_list, list_num, - im_inner_resources, XIMNumber(im_inner_resources), 100); -} - -Public Bool -_XimSetInnerICResourceList( - XIMResourceList *res_list, - unsigned int *list_num) -{ - return _XimSetResourceList(res_list, list_num, - ic_inner_resources, XIMNumber(ic_inner_resources), 200); -} - -Private XIMResourceList -_XimGetResourceListRecByMode( - XIMResourceList res_list, - unsigned int list_num, - unsigned short mode) -{ - register int i; - - for(i = 0; i < list_num; i++) { - if (res_list[i].mode & mode) { - return (XIMResourceList)&res_list[i]; - } - } - return (XIMResourceList)NULL; -} - -Public Bool -_XimCheckCreateICValues( - XIMResourceList res_list, - unsigned int list_num) -{ - if (!_XimGetResourceListRecByMode(res_list, list_num, XIM_MODE_IC_CREATE)) { - return True; - } - return False; -} - -Public XIMResourceList -_XimGetResourceListRecByQuark( - XIMResourceList res_list, - unsigned int list_num, - XrmQuark quark) -{ - register int i; - - for(i = 0; i < list_num; i++) { - if (res_list[i].xrm_name == quark) { - return (XIMResourceList)&res_list[i]; - } - } - return (XIMResourceList)NULL; -} - -Public XIMResourceList -_XimGetResourceListRec( - XIMResourceList res_list, - unsigned int list_num, - const char *name) -{ - XrmQuark quark = XrmStringToQuark(name); - - return _XimGetResourceListRecByQuark(res_list, list_num, quark); -} - -Public char * -_XimSetIMValueData( - Xim im, - XPointer top, - XIMArg *values, - XIMResourceList res_list, - unsigned int list_num) -{ - register XIMArg *p; - XIMResourceList res; - int check; - - for(p = values; p->name != NULL; p++) { - if(!(res = _XimGetResourceListRec(res_list, list_num, p->name))) { - return p->value; - } - check = _XimCheckIMMode(res, XIM_SETIMVALUES); - if(check == XIM_CHECK_INVALID) { - continue; - } else if (check == XIM_CHECK_ERROR) { - return p->value; - } - - if(!_XimEncodeLocalIMAttr(res, top, p->value)) { - return p->value; - } - } - return NULL; -} - -Public char * -_XimGetIMValueData( - Xim im, - XPointer top, - XIMArg *values, - XIMResourceList res_list, - unsigned int list_num) -{ - register XIMArg *p; - XIMResourceList res; - int check; - - for(p = values; p->name != NULL; p++) { - if(!(res = _XimGetResourceListRec(res_list, list_num, p->name))) { - return p->value; - } - check = _XimCheckIMMode(res, XIM_GETIMVALUES); - if(check == XIM_CHECK_INVALID) { - continue; - } else if (check == XIM_CHECK_ERROR) { - return p->value; - } - - if(!_XimDecodeLocalIMAttr(res, top, p->value)) { - return p->value; - } - } - return NULL; -} - -Public void -_XimSetIMMode( - XIMResourceList res_list, - unsigned int list_num) -{ - XIMResourceList res; - unsigned int n = XIMNumber(im_mode); - register int i; - - for(i = 0; i < n; i++) { - if(!(res = _XimGetResourceListRecByQuark(res_list, - list_num, im_mode_quark[i]))) { - continue; - } - res->mode = im_mode[i].mode; - } - return; -} - -Private int -_XimCheckSetIMDefaultsMode( - XIMResourceList res) -{ - if(res->mode & XIM_MODE_IM_DEFAULT) { - return XIM_CHECK_VALID; - } - return XIM_CHECK_INVALID; -} - -Private int -_XimCheckSetIMValuesMode( - XIMResourceList res) -{ - if(res->mode & XIM_MODE_IM_SET) { - return XIM_CHECK_VALID; - } - return XIM_CHECK_INVALID; -} - -Private int - _XimCheckGetIMValuesMode( - XIMResourceList res) -{ - if(res->mode & XIM_MODE_IM_GET) { - return XIM_CHECK_VALID; - } - return XIM_CHECK_INVALID; -} - -Public int - _XimCheckIMMode( - XIMResourceList res, - unsigned long mode) -{ - if(res->mode == 0) { - return XIM_CHECK_INVALID; - } - if(mode & XIM_SETIMDEFAULTS) { - return _XimCheckSetIMDefaultsMode(res); - } else if (mode & XIM_SETIMVALUES) { - return _XimCheckSetIMValuesMode(res); - } else if (mode & XIM_GETIMVALUES) { - return _XimCheckGetIMValuesMode(res); - } else { - return XIM_CHECK_ERROR; - } -} - -Public void -_XimSetICMode(XIMResourceList res_list, unsigned int list_num, XIMStyle style) -{ - XIMResourceList res; - unsigned int n = XIMNumber(ic_mode); - register int i; - unsigned int pre_offset; - unsigned int sts_offset; - - if(style & XIMPreeditArea) { - pre_offset = XOffsetOf(XimICMode, preedit_area_mode); - } else if(style & XIMPreeditCallbacks) { - pre_offset = XOffsetOf(XimICMode, preedit_callback_mode); - } else if(style & XIMPreeditPosition) { - pre_offset = XOffsetOf(XimICMode, preedit_position_mode); - } else if(style & XIMPreeditNothing) { - pre_offset = XOffsetOf(XimICMode, preedit_nothing_mode); - } else { - pre_offset = XOffsetOf(XimICMode, preedit_none_mode); - } - - if(style & XIMStatusArea) { - sts_offset = XOffsetOf(XimICMode, status_area_mode); - } else if(style & XIMStatusCallbacks) { - sts_offset = XOffsetOf(XimICMode, status_callback_mode); - } else if(style & XIMStatusNothing) { - sts_offset = XOffsetOf(XimICMode, status_nothing_mode); - } else { - sts_offset = XOffsetOf(XimICMode, status_none_mode); - } - - for(i = 0; i < n; i++) { - if(!(res = _XimGetResourceListRecByQuark(res_list, - list_num, ic_mode_quark[i]))) { - continue; - } - res->mode = ( (*(unsigned short *)((char *)&ic_mode[i] + pre_offset)) - | (*(unsigned short *)((char *)&ic_mode[i] + sts_offset))); - } - return; -} - -Private int -_XimCheckSetICDefaultsMode( - XIMResourceList res, - unsigned long mode) -{ - if(mode & XIM_PREEDIT_ATTR) { - if(!(res->mode & XIM_MODE_PRE_MASK)) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_PRE_CREATE) { - return XIM_CHECK_ERROR; - } else if (!(res->mode & XIM_MODE_PRE_DEFAULT)) { - return XIM_CHECK_INVALID; - } - - } else if(mode & XIM_STATUS_ATTR) { - if(!(res->mode & XIM_MODE_STS_MASK)) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_STS_CREATE) { - return XIM_CHECK_ERROR; - } - if(!(res->mode & XIM_MODE_STS_DEFAULT)) { - return XIM_CHECK_INVALID; - } - - } else { - if(!res->mode) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_IC_CREATE) { - return XIM_CHECK_ERROR; - } - if(!(res->mode & XIM_MODE_IC_DEFAULT)) { - return XIM_CHECK_INVALID; - } - } - return XIM_CHECK_VALID; -} - -Private int -_XimCheckCreateICMode( - XIMResourceList res, - unsigned long mode) -{ - if(mode & XIM_PREEDIT_ATTR) { - if(!(res->mode & XIM_MODE_PRE_MASK)) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_PRE_CREATE) { - res->mode &= ~XIM_MODE_PRE_CREATE; - } else if(res->mode & XIM_MODE_PRE_ONCE) { - res->mode &= ~XIM_MODE_PRE_ONCE; - } else if(res->mode & XIM_MODE_PRE_DEFAULT) { - res->mode &= ~XIM_MODE_PRE_DEFAULT; - } else if (!(res->mode & XIM_MODE_PRE_SET)) { - return XIM_CHECK_ERROR; - } - - } else if(mode & XIM_STATUS_ATTR) { - if(!(res->mode & XIM_MODE_STS_MASK)) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_STS_CREATE) { - res->mode &= ~XIM_MODE_STS_CREATE; - } else if(res->mode & XIM_MODE_STS_ONCE) { - res->mode &= ~XIM_MODE_STS_ONCE; - } else if(res->mode & XIM_MODE_STS_DEFAULT) { - res->mode &= ~XIM_MODE_STS_DEFAULT; - } else if (!(res->mode & XIM_MODE_STS_SET)) { - return XIM_CHECK_ERROR; - } - - } else { - if(!res->mode) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_IC_CREATE) { - res->mode &= ~XIM_MODE_IC_CREATE; - } else if(res->mode & XIM_MODE_IC_ONCE) { - res->mode &= ~XIM_MODE_IC_ONCE; - } else if(res->mode & XIM_MODE_IC_DEFAULT) { - res->mode &= ~XIM_MODE_IC_DEFAULT; - } else if (!(res->mode & XIM_MODE_IC_SET)) { - return XIM_CHECK_ERROR; - } - } - return XIM_CHECK_VALID; -} - -Private int -_XimCheckSetICValuesMode( - XIMResourceList res, - unsigned long mode) -{ - if(mode & XIM_PREEDIT_ATTR) { - if(!(res->mode & XIM_MODE_PRE_MASK)) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_PRE_ONCE) { - res->mode &= ~XIM_MODE_PRE_ONCE; - } else if(!(res->mode & XIM_MODE_PRE_SET)) { - return XIM_CHECK_ERROR; - } - - } else if(mode & XIM_STATUS_ATTR) { - if(!(res->mode & XIM_MODE_STS_MASK)) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_STS_ONCE) { - res->mode &= ~XIM_MODE_STS_ONCE; - } else if(!(res->mode & XIM_MODE_STS_SET)) { - return XIM_CHECK_ERROR; - } - - } else { - if(!res->mode) { - return XIM_CHECK_INVALID; - } - - if(res->mode & XIM_MODE_IC_ONCE) { - res->mode &= ~XIM_MODE_IC_ONCE; - } else if(!(res->mode & XIM_MODE_IC_SET)) { - return XIM_CHECK_ERROR; - } - } - return XIM_CHECK_VALID; -} - -Private int -_XimCheckGetICValuesMode( - XIMResourceList res, - unsigned long mode) -{ - if(mode & XIM_PREEDIT_ATTR) { - if(!(res->mode & XIM_MODE_PRE_MASK)) { - return XIM_CHECK_INVALID; - } - - if(!(res->mode & XIM_MODE_PRE_GET)) { - return XIM_CHECK_ERROR; - } - - } else if(mode & XIM_STATUS_ATTR) { - if(!(res->mode & XIM_MODE_STS_MASK)) { - return XIM_CHECK_INVALID; - } - - if(!(res->mode & XIM_MODE_STS_GET)) { - return XIM_CHECK_ERROR; - } - - } else { - if(!res->mode) { - return XIM_CHECK_INVALID; - } - - if(!(res->mode & XIM_MODE_IC_GET)) { - return XIM_CHECK_ERROR; - } - } - return XIM_CHECK_VALID; -} - -Public int - _XimCheckICMode( - XIMResourceList res, - unsigned long mode) -{ - if(mode &XIM_SETICDEFAULTS) { - return _XimCheckSetICDefaultsMode(res, mode); - } else if (mode & XIM_CREATEIC) { - return _XimCheckCreateICMode(res, mode); - } else if (mode & XIM_SETICVALUES) { - return _XimCheckSetICValuesMode(res, mode); - } else if (mode & XIM_GETICVALUES) { - return _XimCheckGetICValuesMode(res, mode); - } else { - return XIM_CHECK_ERROR; - } -} - -Public Bool -_XimSetLocalIMDefaults( - Xim im, - XPointer top, - XIMResourceList res_list, - unsigned int list_num) -{ - XimValueOffsetInfo info; - unsigned int num; - register int i; - XIMResourceList res; - int check; - - info = im_attr_info; - num = XIMNumber(im_attr_info); - - for(i = 0; i < num; i++) { - if((res = _XimGetResourceListRecByQuark( res_list, list_num, - info[i].quark)) == (XIMResourceList)NULL) { - return False; - } - - check = _XimCheckIMMode(res, XIM_SETIMDEFAULTS); - if(check == XIM_CHECK_INVALID) { - continue; - } else if (check == XIM_CHECK_ERROR) { - return False; - } - - if(!info[i].defaults) { - continue; - } - if(!(info[i].defaults(&info[i], top, (XPointer)NULL, 0))) { - return False; - } - } - return True; -} - -Public Bool -_XimSetICDefaults( - Xic ic, - XPointer top, - unsigned long mode, - XIMResourceList res_list, - unsigned int list_num) -{ - unsigned int num; - XimValueOffsetInfo info; - register int i; - XIMResourceList res; - int check; - XrmQuark pre_quark; - XrmQuark sts_quark; - - pre_quark = XrmStringToQuark(XNPreeditAttributes); - sts_quark = XrmStringToQuark(XNStatusAttributes); - - if(mode & XIM_PREEDIT_ATTR) { - info = ic_pre_attr_info; - num = XIMNumber(ic_pre_attr_info); - } else if(mode & XIM_STATUS_ATTR) { - info = ic_sts_attr_info; - num = XIMNumber(ic_sts_attr_info); - } else { - info = ic_attr_info; - num = XIMNumber(ic_attr_info); - } - - for(i = 0; i < num; i++) { - if(info[i].quark == pre_quark) { - if(!_XimSetICDefaults(ic, (XPointer)((char *)top + info[i].offset), - (mode | XIM_PREEDIT_ATTR), res_list, list_num)) { - return False; - } - } else if (info[i].quark == sts_quark) { - if(!_XimSetICDefaults(ic, (XPointer)((char *)top + info[i].offset), - (mode | XIM_STATUS_ATTR), res_list, list_num)) { - return False; - } - } else { - if(!(res = _XimGetResourceListRecByQuark(res_list, list_num, - info[i].quark))) { - return False; - } - - check = _XimCheckICMode(res, mode); - if (check == XIM_CHECK_INVALID) { - continue; - } else if (check == XIM_CHECK_ERROR) { - return False; - } - - if (!info[i].defaults) { - continue; - } - if (!(info[i].defaults(&info[i], top, (XPointer)ic, mode))) { - return False; - } - } - } - return True; -} - -Private Bool -_XimEncodeAttr( - XimValueOffsetInfo info, - unsigned int num, - XIMResourceList res, - XPointer top, - XPointer val) -{ - register int i; - - for(i = 0; i < num; i++ ) { - if(info[i].quark == res->xrm_name) { - if(!info[i].encode) { - return False; - } - return (*info[i].encode)(&info[i], top, val); - } - } - return False; -} - -Public Bool -_XimEncodeLocalIMAttr( - XIMResourceList res, - XPointer top, - XPointer val) -{ - return _XimEncodeAttr(im_attr_info, XIMNumber(im_attr_info), - res, top, val); -} - -Public Bool -_XimEncodeLocalICAttr( - Xic ic, - XIMResourceList res, - XPointer top, - XIMArg *arg, - unsigned long mode) -{ - unsigned int num; - XimValueOffsetInfo info; - - if(mode & XIM_PREEDIT_ATTR) { - info = ic_pre_attr_info; - num = XIMNumber(ic_pre_attr_info); - } else if(mode & XIM_STATUS_ATTR) { - info = ic_sts_attr_info; - num = XIMNumber(ic_sts_attr_info); - } else { - info = ic_attr_info; - num = XIMNumber(ic_attr_info); - } - - return _XimEncodeAttr(info, num, res, top, arg->value); -} - -Private Bool -_XimEncodeLocalTopValue( - Xic ic, - XIMResourceList res, - XPointer val, - Bool flag) -{ - XIMArg *p = (XIMArg *)val; - - if (res->xrm_name == XrmStringToQuark(XNClientWindow)) { - ic->core.client_window = (Window)p->value; - if (ic->core.focus_window == (Window)0) - ic->core.focus_window = ic->core.client_window; - if (flag) { - _XRegisterFilterByType(ic->core.im->core.display, - ic->core.focus_window, - KeyPress, KeyRelease, _XimLocalFilter, (XPointer)ic); - } - } else if (res->xrm_name == XrmStringToQuark(XNFocusWindow)) { - if (ic->core.client_window) { - if (flag) { - _XUnregisterFilter(ic->core.im->core.display, - ic->core.focus_window, _XimLocalFilter, (XPointer)ic); - } - ic->core.focus_window = (Window)p->value; - if (flag) { - _XRegisterFilterByType(ic->core.im->core.display, - ic->core.focus_window, KeyPress, KeyRelease, - _XimLocalFilter, (XPointer)ic); - } - } else - ic->core.focus_window = (Window)p->value; - } - return True; -} - -Private Bool -_XimEncodeLocalPreeditValue( - Xic ic, - XIMResourceList res, - XPointer val) -{ - XIMArg *p = (XIMArg *)val; - - if (res->xrm_name == XrmStringToQuark(XNStdColormap)) { - XStandardColormap *colormap_ret; - int count; - - if (!(XGetRGBColormaps(ic->core.im->core.display, - ic->core.focus_window, &colormap_ret, - &count, (Atom)p->value))) - return False; - } - return True; -} - -Private Bool -_XimEncodeLocalStatusValue( - Xic ic, - XIMResourceList res, - XPointer val) -{ - XIMArg *p = (XIMArg *)val; - - if (res->xrm_name == XrmStringToQuark(XNStdColormap)) { - XStandardColormap *colormap_ret; - int count; - - if (!(XGetRGBColormaps(ic->core.im->core.display, - ic->core.focus_window, &colormap_ret, - &count, (Atom)p->value))) - return False; - } - return True; -} - -Public char * -_XimSetICValueData( - Xic ic, - XPointer top, - XIMResourceList res_list, - unsigned int list_num, - XIMArg *values, - unsigned long mode, - Bool flag) -{ - register XIMArg *p; - XIMResourceList res; - char *name; - int check; - XrmQuark pre_quark; - XrmQuark sts_quark; - - pre_quark = XrmStringToQuark(XNPreeditAttributes); - sts_quark = XrmStringToQuark(XNStatusAttributes); - - for(p = values; p->name != NULL; p++) { - if((res = _XimGetResourceListRec(res_list, list_num, - p->name)) == (XIMResourceList)NULL) { - return p->name; - } - if(res->xrm_name == pre_quark) { - if(((name = _XimSetICValueData(ic, - (XPointer)(&((XimDefICValues *)top)->preedit_attr), - res_list, list_num, (XIMArg *)p->value, - (mode | XIM_PREEDIT_ATTR), flag)))) { - return name; - } - } else if(res->xrm_name == sts_quark) { - if(((name = _XimSetICValueData(ic, - (XPointer)(&((XimDefICValues *)top)->status_attr), - res_list, list_num, (XIMArg *)p->value, - (mode | XIM_STATUS_ATTR), flag)))) { - return name; - } - } else { - check = _XimCheckICMode(res, mode); - if(check == XIM_CHECK_INVALID) { - continue; - } else if(check == XIM_CHECK_ERROR) { - return p->name; - } - - if(mode & XIM_PREEDIT_ATTR) { - if (!_XimEncodeLocalPreeditValue(ic, res, (XPointer)p)) - return False; - } else if(mode & XIM_STATUS_ATTR) { - if (!_XimEncodeLocalStatusValue(ic, res, (XPointer)p)) - return False; - } else { - if (!_XimEncodeLocalTopValue(ic, res, (XPointer)p, flag)) - return False; - } - if(_XimEncodeLocalICAttr(ic, res, top, p, mode) == False) { - return p->name; - } - } - } - return NULL; -} - -Private Bool -_XimCheckInputStyle( - XIMStyles *styles, - XIMStyle style) -{ - int num = styles->count_styles; - register int i; - - for(i = 0; i < num; i++) { - if(styles->supported_styles[i] == style) { - return True; - } - } - return False; -} - -Public Bool -_XimCheckLocalInputStyle( - Xic ic, - XPointer top, - XIMArg *values, - XIMStyles *styles, - XIMResourceList res_list, - unsigned int list_num) -{ - XrmQuark quark = XrmStringToQuark(XNInputStyle); - register XIMArg *p; - XIMResourceList res; - - for(p = values; p && p->name != NULL; p++) { - if(quark == XrmStringToQuark(p->name)) { - if(!(res = _XimGetResourceListRec(res_list, list_num, p->name))) { - return False; - } - if(!_XimEncodeLocalICAttr(ic, res, top, p, 0)) { - return False; - } - if (_XimCheckInputStyle(styles, - ((XimDefICValues *)top)->input_style)) { - return True; - } - return False; - } - } - return False; -} - -Private Bool -_XimDecodeAttr( - XimValueOffsetInfo info, - unsigned int num, - XIMResourceList res, - XPointer top, - XPointer val) -{ - register int i; - - for(i = 0; i < num; i++ ) { - if(info[i].quark == res->xrm_name) { - if(!info[i].decode) { - return False; - } - return (*info[i].decode)(&info[i], top, val); - } - } - return False; -} - -Public Bool -_XimDecodeLocalIMAttr( - XIMResourceList res, - XPointer top, - XPointer val) -{ - return _XimDecodeAttr(im_attr_info, XIMNumber(im_attr_info), - res, top, val); -} - -Public Bool -_XimDecodeLocalICAttr( - XIMResourceList res, - XPointer top, - XPointer val, - unsigned long mode) -{ - unsigned int num; - XimValueOffsetInfo info; - - if(mode & XIM_PREEDIT_ATTR) { - info = ic_pre_attr_info; - num = XIMNumber(ic_pre_attr_info); - } else if(mode & XIM_STATUS_ATTR) { - info = ic_sts_attr_info; - num = XIMNumber(ic_sts_attr_info); - } else { - info = ic_attr_info; - num = XIMNumber(ic_attr_info); - } - - return _XimDecodeAttr(info, num, res, top, val); -} - -Public char * -_XimGetICValueData(Xic ic, XPointer top, XIMResourceList res_list, - unsigned int list_num, XIMArg *values, unsigned long mode) -{ - register XIMArg *p; - XIMResourceList res; - char *name; - int check; - XrmQuark pre_quark; - XrmQuark sts_quark; - - pre_quark = XrmStringToQuark(XNPreeditAttributes); - sts_quark = XrmStringToQuark(XNStatusAttributes); - - for(p = values; p->name != NULL; p++) { - if((res = _XimGetResourceListRec(res_list, list_num, - p->name)) == (XIMResourceList)NULL) { - return p->name; - } - if(res->xrm_name == pre_quark) { - if((name = _XimGetICValueData(ic, - (XPointer)(&((XimDefICValues *)top)->preedit_attr), - res_list, list_num, (XIMArg *)p->value, - (mode | XIM_PREEDIT_ATTR)))) { - return name; - } - } else if(res->xrm_name == sts_quark) { - if((name = _XimGetICValueData(ic, - (XPointer)(&((XimDefICValues *)top)->status_attr), - res_list, list_num, (XIMArg *)p->value, - (mode | XIM_STATUS_ATTR)))) { - return name; - } - } else { - check = _XimCheckICMode(res, mode); - if(check == XIM_CHECK_INVALID) { - continue; - } else if(check == XIM_CHECK_ERROR) { - return p->name; - } - - if(_XimDecodeLocalICAttr(res, top, p->value, mode) == False) { - return p->name; - } - } - } - return NULL; -} - -Public void -_XimGetCurrentIMValues(Xim im, XimDefIMValues *im_values) -{ - bzero((char *)im_values, sizeof(XimDefIMValues)); - - im_values->styles = im->core.styles; - im_values->im_values_list = im->core.im_values_list; - im_values->ic_values_list = im->core.ic_values_list; - im_values->destroy_callback = im->core.destroy_callback; - im_values->res_name = im->core.res_name; - im_values->res_class = im->core.res_class; - im_values->visible_position = im->core.visible_position; -} - -Public void -_XimSetCurrentIMValues(Xim im, XimDefIMValues *im_values) -{ - im->core.styles = im_values->styles; - im->core.im_values_list = im_values->im_values_list; - im->core.ic_values_list = im_values->ic_values_list; - im->core.destroy_callback = im_values->destroy_callback; - im->core.res_name = im_values->res_name; - im->core.res_class = im_values->res_class; - im->core.visible_position = im_values->visible_position; -} - -Public void -_XimGetCurrentICValues(Xic ic, XimDefICValues *ic_values) -{ - bzero((char *)ic_values, sizeof(XimDefICValues)); - - ic_values->input_style = ic->core.input_style; - ic_values->client_window = ic->core.client_window; - ic_values->focus_window = ic->core.focus_window; - ic_values->filter_events = ic->core.filter_events; - ic_values->geometry_callback = ic->core.geometry_callback; - ic_values->res_name = ic->core.res_name; - ic_values->res_class = ic->core.res_class; - ic_values->destroy_callback = ic->core.destroy_callback; - ic_values->string_conversion_callback - = ic->core.string_conversion_callback; - ic_values->string_conversion = ic->core.string_conversion; - ic_values->reset_state = ic->core.reset_state; - ic_values->hotkey = ic->core.hotkey; - ic_values->hotkey_state = ic->core.hotkey_state; - ic_values->preedit_attr = ic->core.preedit_attr; - ic_values->status_attr = ic->core.status_attr; -} - -Public void -_XimSetCurrentICValues( - Xic ic, - XimDefICValues *ic_values) -{ - ic->core.input_style = ic_values->input_style; - ic->core.client_window = ic_values->client_window; - if (ic_values->focus_window) - ic->core.focus_window = ic_values->focus_window; - ic->core.filter_events = ic_values->filter_events; - ic->core.geometry_callback = ic_values->geometry_callback; - ic->core.res_name = ic_values->res_name; - ic->core.res_class = ic_values->res_class; - ic->core.destroy_callback = ic_values->destroy_callback; - ic->core.string_conversion_callback - = ic_values->string_conversion_callback; - ic->core.string_conversion = ic_values->string_conversion; - ic->core.reset_state = ic_values->reset_state; - ic->core.hotkey = ic_values->hotkey; - ic->core.hotkey_state = ic_values->hotkey_state; - ic->core.preedit_attr = ic_values->preedit_attr; - ic->core.status_attr = ic_values->status_attr; -} - -Private void -_XimInitialIMOffsetInfo(void) -{ - unsigned int n = XIMNumber(im_attr_info); - register int i; - - for(i = 0; i < n; i++) { - im_attr_info[i].quark = XrmStringToQuark(GET_NAME(im_attr_info[i])); - } -} - -Private void -_XimInitialICOffsetInfo(void) -{ - unsigned int n; - register int i; - - n = XIMNumber(ic_attr_info); - for(i = 0; i < n; i++) { - ic_attr_info[i].quark = XrmStringToQuark(GET_NAME(ic_attr_info[i])); - } - - n = XIMNumber(ic_pre_attr_info); - for(i = 0; i < n; i++) { - ic_pre_attr_info[i].quark = XrmStringToQuark(GET_NAME(ic_pre_attr_info[i])); - } - - n = XIMNumber(ic_sts_attr_info); - for(i = 0; i < n; i++) { - ic_sts_attr_info[i].quark = XrmStringToQuark(GET_NAME(ic_sts_attr_info[i])); - } -} - -Private void -_XimInitialIMMode(void) -{ - unsigned int n = XIMNumber(im_mode); - register int i; - - for(i = 0; i < n; i++) { - im_mode_quark[i] = XrmStringToQuark(GET_NAME(im_mode[i])); - } -} - -Private void -_XimInitialICMode(void) -{ - unsigned int n = XIMNumber(ic_mode); - register int i; - - for(i = 0; i < n; i++) { - ic_mode_quark[i] = XrmStringToQuark(GET_NAME(ic_mode[i])); - } -} - -Public void -_XimInitialResourceInfo(void) -{ - static Bool init_flag = False; - - if(init_flag == True) { - return; - } - _XimInitialIMOffsetInfo(); - _XimInitialICOffsetInfo(); - _XimInitialIMMode(); - _XimInitialICMode(); - init_flag = True; -} +/****************************************************************** + + Copyright 1990, 1991, 1992,1993, 1994 by FUJITSU LIMITED + Copyright 1994 by Sony Corporation + +Permission to use, copy, modify, distribute, and sell this software +and its documentation for any purpose is hereby granted without fee, +provided that the above copyright notice appear in all copies and +that both that copyright notice and this permission notice appear +in supporting documentation, and that the name of FUJITSU LIMITED +and Sony Corporation not be used in advertising or publicity +pertaining to distribution of the software without specific, +written prior permission. FUJITSU LIMITED and Sony Corporation make +no representations about the suitability of this software for any +purpose. It is provided "as is" without express or implied warranty. + +FUJITSU LIMITED AND SONY CORPORATION DISCLAIM ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL FUJITSU LIMITED AND +SONY CORPORATION BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL +DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + + Author: Takashi Fujiwara FUJITSU LIMITED + fujiwara@a80.tech.yk.fujitsu.co.jp + Modifier: Makoto Wakamatsu Sony Corporation + makoto@sm.sony.co.jp + +******************************************************************/ + +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include +#include "Xlibint.h" +#include "Xlcint.h" +#include "Ximint.h" +#include "Xresource.h" + +#define GET_NAME(x) name_table + x.name_offset + +typedef struct _XimValueOffsetInfo { + unsigned short name_offset; + XrmQuark quark; + unsigned int offset; + Bool (*defaults)( + struct _XimValueOffsetInfo *, XPointer, XPointer, unsigned long + ); + Bool (*encode)( + struct _XimValueOffsetInfo *, XPointer, XPointer + ); + Bool (*decode)( + struct _XimValueOffsetInfo *, XPointer, XPointer + ); +} XimValueOffsetInfoRec, *XimValueOffsetInfo; + +#ifdef XIM_CONNECTABLE +Private Bool +_XimCheckBool(str) + char *str; +{ + if(!strcmp(str, "True") || !strcmp(str, "true") || + !strcmp(str, "Yes") || !strcmp(str, "yes") || + !strcmp(str, "ON") || !strcmp(str, "on")) + return True; + return False; +} + +Public void +_XimSetProtoResource(im) + Xim im; +{ + char res_name_buf[256]; + char* res_name; + char res_class_buf[256]; + char* res_class; + char* str_type; + XrmValue value; + XIMStyle preedit_style = 0; + XIMStyle status_style = 0; + XIMStyles* imstyles; + char* dotximdot = ".xim."; + char* ximdot = "xim."; + char* dotXimdot = ".Xim."; + char* Ximdot = "Xim."; + + if (!im->core.rdb) + return; + + if (strlen (im->core.res_name) < 200) res_name = res_name_buf; + else res_name = Xmalloc (strlen (im->core.res_name) + 50); + if (strlen (im->core.res_class) < 200) res_class = res_class_buf; + else res_class = Xmalloc (strlen (im->core.res_class) + 50); + /* pretend malloc always works */ + + (void) sprintf (res_name, "%s%s%s", + im->core.res_name != NULL ? im->core.res_name : "*", + im->core.res_name != NULL ? dotximdot : ximdot, + "useAuth"); + (void) sprintf (res_class, "%s%s%s", + im->core.res_class != NULL ? im->core.res_class : "*", + im->core.res_class != NULL ? dotXimdot : Ximdot, + "UseAuth"); + bzero(&value, sizeof(XrmValue)); + if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { + if(_XimCheckBool(value.addr)) { + MARK_USE_AUTHORIZATION_FUNC(im); + } + } + + (void) sprintf (res_name, "%s%s%s", + im->core.res_name != NULL ? im->core.res_name : "*", + im->core.res_name != NULL ? dotximdot : ximdot, + "delaybinding"); + (void) sprintf (res_class, "%s%s%s", + im->core.res_class != NULL ? im->core.res_class : "*", + im->core.res_class != NULL ? dotXimdot : Ximdot, + "Delaybinding"); + bzero(&value, sizeof(XrmValue)); + if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { + if(_XimCheckBool(value.addr)) { + MARK_DELAYBINDABLE(im); + } + } + + (void) sprintf (res_name, "%s%s%s", + im->core.res_name != NULL ? im->core.res_name : "*", + im->core.res_name != NULL ? dotximdot : ximdot, + "reconnect"); + (void) sprintf (res_class, "%s%s%s", + im->core.res_class != NULL ? im->core.res_class : "*", + im->core.res_class != NULL ? dotXimdot : Ximdot, + "Reconnect"); + bzero(&value, sizeof(XrmValue)); + if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { + if(_XimCheckBool(value.addr)) { + MARK_RECONNECTABLE(im); + } + } + + if(!IS_CONNECTABLE(im)) { + if (res_name != res_name_buf) Xfree (res_name); + if (res_class != res_class_buf) Xfree (res_class); + return; + } + + (void) sprintf (res_name, "%s%s%s", + im->core.res_name != NULL ? im->core.res_name : "*", + im->core.res_name != NULL ? dotximdot : ximdot, + "preeditDefaultStyle"); + (void) sprintf (res_class, "%s%s%s", + im->core.res_class != NULL ? im->core.res_class : "*", + im->core.res_class != NULL ? dotXimdot : Ximdot, + "PreeditDefaultStyle"); + if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { + if(!strcmp(value.addr, "XIMPreeditArea")) + preedit_style = XIMPreeditArea; + else if(!strcmp(value.addr, "XIMPreeditCallbacks")) + preedit_style = XIMPreeditCallbacks; + else if(!strcmp(value.addr, "XIMPreeditPosition")) + preedit_style = XIMPreeditPosition; + else if(!strcmp(value.addr, "XIMPreeditNothing")) + preedit_style = XIMPreeditNothing; + else if(!strcmp(value.addr, "XIMPreeditNone")) + preedit_style = XIMPreeditNone; + } + if(!preedit_style) + preedit_style = XIMPreeditNothing; + + (void) sprintf (res_name, "%s%s%s", + im->core.res_name != NULL ? im->core.res_name : "*", + im->core.res_name != NULL ? dotximdot : ximdot, + "statusDefaultStyle"); + (void) sprintf (res_class, "%s%s%s", + im->core.res_class != NULL ? im->core.res_class : "*", + im->core.res_class != NULL ? dotXimdot : Ximdot, + "StatusDefaultStyle"); + if(XrmGetResource(im->core.rdb, res_name, res_class, &str_type, &value)) { + if(!strcmp(value.addr, "XIMStatusArea")) + status_style = XIMStatusArea; + else if(!strcmp(value.addr, "XIMStatusCallbacks")) + status_style = XIMStatusCallbacks; + else if(!strcmp(value.addr, "XIMStatusNothing")) + status_style = XIMStatusNothing; + else if(!strcmp(value.addr, "XIMStatusNone")) + status_style = XIMStatusNone; + } + if(!status_style) + status_style = XIMStatusNothing; + + if(!(imstyles = (XIMStyles *)Xmalloc(sizeof(XIMStyles) + sizeof(XIMStyle)))){ + if (res_name != res_name_buf) Xfree (res_name); + if (res_class != res_class_buf) Xfree (res_class); + return; + } + imstyles->count_styles = 1; + imstyles->supported_styles = + (XIMStyle *)((char *)imstyles + sizeof(XIMStyles)); + imstyles->supported_styles[0] = preedit_style | status_style; + im->private.proto.default_styles = imstyles; + if (res_name != res_name_buf) Xfree (res_name); + if (res_class != res_class_buf) Xfree (res_class); +} +#endif /* XIM_CONNECTABLE */ + +static const char name_table[] = + /* 0 */ XNQueryInputStyle"\0" + /* 16 */ XNClientWindow"\0" + /* 29 */ XNInputStyle"\0" + /* 40 */ XNFocusWindow"\0" + /* 52 */ XNResourceName"\0" + /* 65 */ XNResourceClass"\0" + /* 79 */ XNGeometryCallback"\0" + /* 96 */ XNDestroyCallback"\0" + /* 112 */ XNFilterEvents"\0" + /* 125 */ XNPreeditStartCallback"\0" + /* 146 */ XNPreeditDoneCallback"\0" + /* 166 */ XNPreeditDrawCallback"\0" + /* 186 */ XNPreeditCaretCallback"\0" + /* 207 */ XNPreeditStateNotifyCallback"\0" + /* 234 */ XNPreeditAttributes"\0" + /* 252 */ XNStatusStartCallback"\0" + /* 272 */ XNStatusDoneCallback"\0" + /* 291 */ XNStatusDrawCallback"\0" + /* 310 */ XNStatusAttributes"\0" + /* 327 */ XNArea"\0" + /* 332 */ XNAreaNeeded"\0" + /* 343 */ XNSpotLocation"\0" + /* 356 */ XNColormap"\0" + /* 365 */ XNStdColormap"\0" + /* 377 */ XNForeground"\0" + /* 388 */ XNBackground"\0" + /* 399 */ XNBackgroundPixmap"\0" + /* 416 */ XNFontSet"\0" + /* 424 */ XNLineSpace"\0" + /* 434 */ XNCursor"\0" + /* 441 */ XNQueryIMValuesList"\0" + /* 459 */ XNQueryICValuesList"\0" + /* 477 */ XNVisiblePosition"\0" + /* 493 */ XNStringConversionCallback"\0" + /* 518 */ XNStringConversion"\0" + /* 535 */ XNResetState"\0" + /* 546 */ XNHotKey"\0" + /* 553 */ XNHotKeyState"\0" + /* 565 */ XNPreeditState +; + +#define OFFSET_XNQUERYINPUTSTYLE 0 +#define OFFSET_XNCLIENTWINDOW 16 +#define OFFSET_XNINPUTSTYLE 29 +#define OFFSET_XNFOCUSWINDOW 40 +#define OFFSET_XNRESOURCENAME 52 +#define OFFSET_XNRESOURCECLASS 65 +#define OFFSET_XNGEOMETRYCALLBACK 79 +#define OFFSET_XNDESTROYCALLBACK 96 +#define OFFSET_XNFILTEREVENTS 112 +#define OFFSET_XNPREEDITSTARTCALLBACK 125 +#define OFFSET_XNPREEDITDONECALLBACK 146 +#define OFFSET_XNPREEDITDRAWCALLBACK 166 +#define OFFSET_XNPREEDITCARETCALLBACK 186 +#define OFFSET_XNPREEDITSTATENOTIFYCALLBACK 207 +#define OFFSET_XNPREEDITATTRIBUTES 234 +#define OFFSET_XNSTATUSSTARTCALLBACK 252 +#define OFFSET_XNSTATUSDONECALLBACK 272 +#define OFFSET_XNSTATUSDRAWCALLBACK 291 +#define OFFSET_XNSTATUSATTRIBUTES 310 +#define OFFSET_XNAREA 327 +#define OFFSET_XNAREANEEDED 332 +#define OFFSET_XNSPOTLOCATION 343 +#define OFFSET_XNCOLORMAP 356 +#define OFFSET_XNSTDCOLORMAP 365 +#define OFFSET_XNFOREGROUND 377 +#define OFFSET_XNBACKGROUND 388 +#define OFFSET_XNBACKGROUNDPIXMAP 399 +#define OFFSET_XNFONTSET 416 +#define OFFSET_XNLINESPACE 424 +#define OFFSET_XNCURSOR 434 +#define OFFSET_XNQUERYIMVALUESLIST 441 +#define OFFSET_XNQUERYICVALUESLIST 459 +#define OFFSET_XNVISIBLEPOSITION 477 +#define OFFSET_XNSTRINGCONVERSIONCALLBACK 493 +#define OFFSET_XNSTRINGCONVERSION 518 +#define OFFSET_XNRESETSTATE 535 +#define OFFSET_XNHOTKEY 546 +#define OFFSET_XNHOTKEYSTATE 553 +#define OFFSET_XNPREEDITSTATE 565 + +/* offsets into name_table */ +static const unsigned short supported_local_im_values_list[] = { + OFFSET_XNQUERYINPUTSTYLE, + OFFSET_XNRESOURCENAME, + OFFSET_XNRESOURCECLASS, + OFFSET_XNDESTROYCALLBACK, + OFFSET_XNQUERYIMVALUESLIST, + OFFSET_XNQUERYICVALUESLIST, + OFFSET_XNVISIBLEPOSITION +}; + +/* offsets into name_table */ +static const unsigned short supported_local_ic_values_list[] = { + OFFSET_XNINPUTSTYLE, + OFFSET_XNCLIENTWINDOW, + OFFSET_XNFOCUSWINDOW, + OFFSET_XNRESOURCENAME, + OFFSET_XNRESOURCECLASS, + OFFSET_XNGEOMETRYCALLBACK, + OFFSET_XNFILTEREVENTS, + OFFSET_XNDESTROYCALLBACK, + OFFSET_XNSTRINGCONVERSIONCALLBACK, + OFFSET_XNSTRINGCONVERSIONCALLBACK, + OFFSET_XNRESETSTATE, + OFFSET_XNHOTKEY, + OFFSET_XNHOTKEYSTATE, + OFFSET_XNPREEDITATTRIBUTES, + OFFSET_XNSTATUSATTRIBUTES, + OFFSET_XNAREA, + OFFSET_XNAREANEEDED, + OFFSET_XNSPOTLOCATION, + OFFSET_XNCOLORMAP, + OFFSET_XNSTDCOLORMAP, + OFFSET_XNFOREGROUND, + OFFSET_XNBACKGROUND, + OFFSET_XNBACKGROUNDPIXMAP, + OFFSET_XNFONTSET, + OFFSET_XNLINESPACE, + OFFSET_XNCURSOR, + OFFSET_XNPREEDITSTARTCALLBACK, + OFFSET_XNPREEDITDONECALLBACK, + OFFSET_XNPREEDITDRAWCALLBACK, + OFFSET_XNPREEDITCARETCALLBACK, + OFFSET_XNSTATUSSTARTCALLBACK, + OFFSET_XNSTATUSDONECALLBACK, + OFFSET_XNSTATUSDRAWCALLBACK, + OFFSET_XNPREEDITSTATE, + OFFSET_XNPREEDITSTATENOTIFYCALLBACK +}; + +static XIMStyle const supported_local_styles[] = { + XIMPreeditNone | XIMStatusNone, + XIMPreeditNothing | XIMStatusNothing, + 0 /* dummy */ +}; + +Private Bool +_XimDefaultStyles( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, /* unused */ + unsigned long mode) /* unused */ +{ + XIMStyles *styles; + XIMStyles **out; + register int i; + unsigned int n; + int len; + XPointer tmp; + + n = XIMNumber(supported_local_styles) - 1; + len = sizeof(XIMStyles) + sizeof(XIMStyle) * n; + if(!(tmp = (XPointer)Xmalloc(len))) { + return False; + } + bzero(tmp, len); + + styles = (XIMStyles *)tmp; + if (n > 0) { + styles->count_styles = (unsigned short)n; + styles->supported_styles = + (XIMStyle *)((char *)tmp + sizeof(XIMStyles)); + for(i = 0; i < n; i++) { + styles->supported_styles[i] = supported_local_styles[i]; + } + } + + out = (XIMStyles **)((char *)top + info->offset); + *out = styles; + return True; +} + +Private Bool +_XimDefaultIMValues( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, /* unused */ + unsigned long mode) /* unused */ +{ + XIMValuesList *values_list; + XIMValuesList **out; + register int i; + unsigned int n; + int len; + XPointer tmp; + + n = XIMNumber(supported_local_im_values_list); + len = sizeof(XIMValuesList) + sizeof(char **) * n; + if(!(tmp = (XPointer)Xmalloc(len))) { + return False; + } + bzero(tmp, len); + + values_list = (XIMValuesList *)tmp; + if (n > 0) { + values_list->count_values = (unsigned short)n; + values_list->supported_values + = (char **)((char *)tmp + sizeof(XIMValuesList)); + for(i = 0; i < n; i++) { + values_list->supported_values[i] = + (char *)name_table + supported_local_im_values_list[i]; + } + } + + out = (XIMValuesList **)((char *)top + info->offset); + *out = values_list; + return True; +} + +Private Bool +_XimDefaultICValues( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, /* unused */ + unsigned long mode) /* unused */ +{ + XIMValuesList *values_list; + XIMValuesList **out; + register int i; + unsigned int n; + int len; + XPointer tmp; + + n = XIMNumber(supported_local_ic_values_list); + len = sizeof(XIMValuesList) + sizeof(char **) * n; + if(!(tmp = (XPointer)Xmalloc(len))) { + return False; + } + bzero(tmp, len); + + values_list = (XIMValuesList *)tmp; + if (n > 0) { + values_list->count_values = (unsigned short)n; + values_list->supported_values + = (char **)((char *)tmp + sizeof(XIMValuesList)); + for(i = 0; i < n; i++) { + values_list->supported_values[i] = + (char *)name_table + supported_local_ic_values_list[i]; + } + } + + out = (XIMValuesList **)((char *)top + info->offset); + *out = values_list; + return True; +} + +Private Bool +_XimDefaultVisiblePos( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, /* unused */ + unsigned long mode) /* unused */ +{ + Bool *out; + + out = (Bool *)((char *)top + info->offset); + *out = False; + return True; +} + +Private Bool +_XimDefaultFocusWindow( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Window *out; + + if(ic->core.client_window == (Window)NULL) { + return True; + } + + out = (Window *)((char *)top + info->offset); + *out = ic->core.client_window; + return True; +} + +Private Bool +_XimDefaultResName( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + char **out; + + if(im->core.res_name == (char *)NULL) { + return True; + } + + out = (char **)((char *)top + info->offset); + *out = im->core.res_name; + return True; +} + +Private Bool +_XimDefaultResClass( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + char **out; + + if(im->core.res_class == (char *)NULL) { + return True; + } + + out = (char **)((char *)top + info->offset); + *out = im->core.res_class; + return True; +} + +Private Bool +_XimDefaultDestroyCB( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + XIMCallback *out; + + out = (XIMCallback *)((char *)top + info->offset); + *out = im->core.destroy_callback; + return True; +} + +Private Bool +_XimDefaultResetState( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + XIMResetState *out; + + out = (XIMResetState *)((char *)top + info->offset); + *out = XIMInitialState; + return True; +} + +Private Bool +_XimDefaultHotKeyState( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + XIMHotKeyState *out; + + out = (XIMHotKeyState *)((char *)top + info->offset); + *out = XIMHotKeyStateOFF; + return True; +} + +Private Bool +_XimDefaultArea( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + Window root_return; + int x_return, y_return; + unsigned int width_return, height_return; + unsigned int border_width_return; + unsigned int depth_return; + XRectangle area; + XRectangle *out; + + if(ic->core.focus_window == (Window)NULL) { + return True; + } + if(XGetGeometry(im->core.display, (Drawable)ic->core.focus_window, + &root_return, &x_return, &y_return, &width_return, + &height_return, &border_width_return, &depth_return) + == (Status)Success) { + return True; + } + area.x = 0; + area.y = 0; + area.width = width_return; + area.height = height_return; + + out = (XRectangle *)((char *)top + info->offset); + *out = area; + return True; +} + +Private Bool +_XimDefaultColormap( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + XWindowAttributes win_attr; + Colormap *out; + + if(ic->core.client_window == (Window)NULL) { + return True; + } + if(XGetWindowAttributes(im->core.display, ic->core.client_window, + &win_attr) == (Status)Success) { + return True; + } + + out = (Colormap *)((char *)top + info->offset); + *out = win_attr.colormap; + return True; +} + +Private Bool +_XimDefaultStdColormap( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Atom *out; + + out = (Atom *)((char *)top + info->offset); + *out = (Atom)0; + return True; +} + +Private Bool +_XimDefaultFg( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + unsigned long fg; + unsigned long *out; + + fg = WhitePixel(im->core.display, DefaultScreen(im->core.display)); + out = (unsigned long *)((char *)top + info->offset); + *out = fg; + return True; +} + +Private Bool +_XimDefaultBg( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + Xim im = (Xim)ic->core.im; + unsigned long bg; + unsigned long *out; + + bg = BlackPixel(im->core.display, DefaultScreen(im->core.display)); + out = (unsigned long *)((char *)top + info->offset); + *out = bg; + return True; +} + +Private Bool +_XimDefaultBgPixmap( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Pixmap *out; + + out = (Pixmap *)((char *)top + info->offset); + *out = (Pixmap)0; + return True; +} + +Private Bool +_XimDefaultFontSet( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + XFontSet *out; + + out = (XFontSet *)((char *)top + info->offset); + *out = 0; + return True; +} + +Private Bool +_XimDefaultLineSpace( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Xic ic = (Xic)parm; + XFontSet fontset; + XFontSetExtents *fset_extents; + int line_space = 0; + int *out; + + if(mode & XIM_PREEDIT_ATTR) { + fontset = ic->core.preedit_attr.fontset; + } else if(mode & XIM_STATUS_ATTR) { + fontset = ic->core.status_attr.fontset; + } else { + return True; + } + if (fontset) { + fset_extents = XExtentsOfFontSet(fontset); + line_space = fset_extents->max_logical_extent.height; + } + out = (int *)((char *)top + info->offset); + *out = line_space; + return True; +} + +Private Bool +_XimDefaultCursor( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + Cursor *out; + + out = (Cursor *)((char *)top + info->offset); + *out = (Cursor)0; + return True; +} + +Private Bool +_XimDefaultPreeditState( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + XIMPreeditState *out; + + out = (XIMPreeditState *)((char *)top + info->offset); + *out = XIMPreeditDisable; + return True; +} + +Private Bool +_XimDefaultNest( + XimValueOffsetInfo info, + XPointer top, + XPointer parm, + unsigned long mode) +{ + return True; +} + +Private Bool +_XimEncodeCallback( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMCallback *out; + + out = (XIMCallback *)((char *)top + info->offset); + *out = *((XIMCallback *)val); + return True; +} + +Private Bool +_XimEncodeString( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + int len; + char *string; + char **out; + + if(val == (XPointer)NULL) { + return False; + } + len = strlen((char *)val); + if(!(string = (char *)Xmalloc(len + 1))) { + return False; + } + (void)strcpy(string, (char *)val); + string[len] = '\0'; + + out = (char **)((char *)top + info->offset); + if(*out) { + Xfree(*out); + } + *out = string; + return True; +} + +Private Bool +_XimEncodeStyle( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMStyle *out; + + out = (XIMStyle *)((char *)top + info->offset); + *out = (XIMStyle)val; + return True; +} + +Private Bool +_XimEncodeWindow( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Window *out; + + out = (Window *)((char *)top + info->offset); + *out = (Window)val; + return True; +} + +Private Bool +_XimEncodeStringConv( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + /* + * Not yet + */ + return True; +} + +Private Bool +_XimEncodeResetState( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMResetState *out; + + out = (XIMResetState *)((char *)top + info->offset); + *out = (XIMResetState)val; + return True; +} + +Private Bool +_XimEncodeHotKey( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMHotKeyTriggers *hotkey = (XIMHotKeyTriggers *)val; + XIMHotKeyTriggers **out; + XIMHotKeyTriggers *key_list; + XIMHotKeyTrigger *key; + XPointer tmp; + int num; + int len; + register int i; + + if(hotkey == (XIMHotKeyTriggers *)NULL) { + return True; + } + + if((num = hotkey->num_hot_key) == 0) { + return True; + } + + len = sizeof(XIMHotKeyTriggers) + sizeof(XIMHotKeyTrigger) * num; + if(!(tmp = (XPointer)Xmalloc(len))) { + return False; + } + + key_list = (XIMHotKeyTriggers *)tmp; + key = (XIMHotKeyTrigger *)((char *)tmp + sizeof(XIMHotKeyTriggers)); + + for(i = 0; i < num; i++) { + key[i] = hotkey->key[i]; + } + + key_list->num_hot_key = num; + key_list->key = key; + + out = (XIMHotKeyTriggers **)((char *)top + info->offset); + *out = key_list; + return True; +} + +Private Bool +_XimEncodeHotKetState( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMHotKeyState *out; + + out = (XIMHotKeyState *)((char *)top + info->offset); + *out = (XIMHotKeyState)val; + return True; +} + +Private Bool +_XimEncodeRectangle( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XRectangle *out; + + out = (XRectangle *)((char *)top + info->offset); + *out = *((XRectangle *)val); + return True; +} + +Private Bool +_XimEncodeSpot( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XPoint *out; + + out = (XPoint *)((char *)top + info->offset); + *out = *((XPoint *)val); + return True; +} + +Private Bool +_XimEncodeColormap( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Colormap *out; + + out = (Colormap *)((char *)top + info->offset); + *out = (Colormap)val; + return True; +} + +Private Bool +_XimEncodeStdColormap( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Atom *out; + + out = (Atom *)((char *)top + info->offset); + *out = (Atom)val; + return True; +} + +Private Bool +_XimEncodeLong( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + unsigned long *out; + + out = (unsigned long *)((char *)top + info->offset); + *out = (unsigned long)val; + return True; +} + +Private Bool +_XimEncodeBgPixmap( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Pixmap *out; + + out = (Pixmap *)((char *)top + info->offset); + *out = (Pixmap)val; + return True; +} + +Private Bool +_XimEncodeFontSet( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XFontSet *out; + + out = (XFontSet *)((char *)top + info->offset); + *out = (XFontSet)val; + return True; +} + +Private Bool +_XimEncodeLineSpace( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + int *out; + + out = (int *)((char *)top + info->offset); + *out = (long)val; + return True; +} + +Private Bool +_XimEncodeCursor( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Cursor *out; + + out = (Cursor *)((char *)top + info->offset); + *out = (Cursor)val; + return True; +} + +Private Bool +_XimEncodePreeditState( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMPreeditState *out; + + out = (XIMPreeditState *)((char *)top + info->offset); + *out = (XIMPreeditState)val; + return True; +} + +Private Bool +_XimEncodeNest( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + return True; +} + +Private Bool +_XimDecodeStyles( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMStyles *styles; + XIMStyles *out; + register int i; + unsigned int num; + int len; + XPointer tmp; + + if(val == (XPointer)NULL) { + return False; + } + + styles = *((XIMStyles **)((char *)top + info->offset)); + num = styles->count_styles; + + len = sizeof(XIMStyles) + sizeof(XIMStyle) * num; + if(!(tmp = (XPointer)Xmalloc(len))) { + return False; + } + bzero(tmp, len); + + out = (XIMStyles *)tmp; + if(num >0) { + out->count_styles = (unsigned short)num; + out->supported_styles = (XIMStyle *)((char *)tmp + sizeof(XIMStyles)); + + for(i = 0; i < num; i++) { + out->supported_styles[i] = styles->supported_styles[i]; + } + } + *((XIMStyles **)val) = out; + return True; +} + +Private Bool +_XimDecodeValues( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMValuesList *values_list; + XIMValuesList *out; + register int i; + unsigned int num; + int len; + XPointer tmp; + + if(val == (XPointer)NULL) { + return False; + } + + values_list = *((XIMValuesList **)((char *)top + info->offset)); + num = values_list->count_values; + + len = sizeof(XIMValuesList) + sizeof(char **) * num; + if(!(tmp = (char *)Xmalloc(len))) { + return False; + } + bzero(tmp, len); + + out = (XIMValuesList *)tmp; + if(num) { + out->count_values = (unsigned short)num; + out->supported_values = (char **)((char *)tmp + sizeof(XIMValuesList)); + + for(i = 0; i < num; i++) { + out->supported_values[i] = values_list->supported_values[i]; + } + } + *((XIMValuesList **)val) = out; + return True; +} + +Private Bool +_XimDecodeCallback( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMCallback *in; + XIMCallback *callback; + + in = (XIMCallback *)((char *)top + info->offset); + if(!(callback = (XIMCallback *)Xmalloc(sizeof(XIMCallback)))) { + return False; + } + callback->client_data = in->client_data; + callback->callback = in->callback; + + *((XIMCallback **)val) = callback; + return True; +} + +Private Bool +_XimDecodeString( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + int len = 0; + char *in; + char *string; + + in = *((char **)((char *)top + info->offset)); + if(in != (char *)NULL) { + len = strlen(in); + } + if(!(string = (char *)Xmalloc(len + 1))) { + return False; + } + if(in != (char *)NULL) { + (void)strcpy(string, in); + } + string[len] = '\0'; + *((char **)val) = string; + return True; +} + +Private Bool +_XimDecodeBool( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Bool *in; + + in = (Bool *)((char *)top + info->offset); + *((Bool *)val) = *in; + return True; +} + +Private Bool +_XimDecodeStyle( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMStyle *in; + + in = (XIMStyle *)((char *)top + info->offset); + *((XIMStyle *)val) = *in; + return True; +} + +Private Bool +_XimDecodeWindow( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Window *in; + + in = (Window *)((char *)top + info->offset); + *((Window *)val) = *in; + return True; +} + +Private Bool +_XimDecodeStringConv( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + /* + * Not yet + */ + return True; +} + +Private Bool +_XimDecodeResetState( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMResetState *in; + + in = (XIMResetState *)((char *)top + info->offset); + *((XIMResetState *)val) = *in; + return True; +} + +Private Bool +_XimDecodeHotKey( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMHotKeyTriggers *in; + XIMHotKeyTriggers *hotkey; + XIMHotKeyTrigger *key; + XPointer tmp; + int num; + int len; + register int i; + + in = *((XIMHotKeyTriggers **)((char *)top + info->offset)); + num = in->num_hot_key; + len = sizeof(XIMHotKeyTriggers) + sizeof(XIMHotKeyTrigger) * num; + if(!(tmp = (XPointer)Xmalloc(len))) { + return False; + } + + hotkey = (XIMHotKeyTriggers *)tmp; + key = (XIMHotKeyTrigger *)((char *)tmp + sizeof(XIMHotKeyTriggers)); + + for(i = 0; i < num; i++) { + key[i] = in->key[i]; + } + hotkey->num_hot_key = num; + hotkey->key = key; + + *((XIMHotKeyTriggers **)val) = hotkey; + return True; +} + +Private Bool +_XimDecodeHotKetState( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMHotKeyState *in; + + in = (XIMHotKeyState *)((char *)top + info->offset); + *((XIMHotKeyState *)val) = *in; + return True; +} + +Private Bool +_XimDecodeRectangle( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XRectangle *in; + XRectangle *rect; + + in = (XRectangle *)((char *)top + info->offset); + if(!(rect = (XRectangle *)Xmalloc(sizeof(XRectangle)))) { + return False; + } + *rect = *in; + *((XRectangle **)val) = rect; + return True; +} + +Private Bool +_XimDecodeSpot( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XPoint *in; + XPoint *spot; + + in = (XPoint *)((char *)top + info->offset); + if(!(spot = (XPoint *)Xmalloc(sizeof(XPoint)))) { + return False; + } + *spot = *in; + *((XPoint **)val) = spot; + return True; +} + +Private Bool +_XimDecodeColormap( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Colormap *in; + + in = (Colormap *)((char *)top + info->offset); + *((Colormap *)val) = *in; + return True; +} + +Private Bool +_XimDecodeStdColormap( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Atom *in; + + in = (Atom *)((char *)top + info->offset); + *((Atom *)val) = *in; + return True; +} + +Private Bool +_XimDecodeLong( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + unsigned long *in; + + in = (unsigned long *)((char *)top + info->offset); + *((unsigned long *)val) = *in; + return True; +} + +Private Bool +_XimDecodeBgPixmap( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Pixmap *in; + + in = (Pixmap *)((char *)top + info->offset); + *((Pixmap *)val) = *in; + return True; +} + +Private Bool +_XimDecodeFontSet( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XFontSet *in; + + in = (XFontSet *)((char *)top + info->offset); + *((XFontSet *)val) = *in; + return True; +} + +Private Bool +_XimDecodeLineSpace( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + int *in; + + in = (int *)((char *)top + info->offset); + *((int *)val) = *in; + return True; +} + +Private Bool +_XimDecodeCursor( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + Cursor *in; + + in = (Cursor *)((char *)top + info->offset); + *((Cursor *)val) = *in; + return True; +} + +Private Bool +_XimDecodePreeditState( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + XIMPreeditState *in; + + in = (XIMPreeditState *)((char *)top + info->offset); + *((XIMPreeditState *)val) = *in; + return True; +} + +Private Bool +_XimDecodeNest( + XimValueOffsetInfo info, + XPointer top, + XPointer val) +{ + return True; +} + +static XIMResource im_resources[] = { + {XNQueryInputStyle, 0, XimType_XIMStyles, 0, 0, 0}, + {XNDestroyCallback, 0, 0, 0, 0, 0}, + {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, + {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, + {XNQueryIMValuesList, 0, 0, 0, 0, 0}, + {XNQueryICValuesList, 0, 0, 0, 0, 0}, + {XNVisiblePosition, 0, 0, 0, 0, 0} +}; + +static XIMResource im_inner_resources[] = { + {XNDestroyCallback, 0, 0, 0, 0, 0}, + {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, + {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, + {XNQueryIMValuesList, 0, 0, 0, 0, 0}, + {XNQueryICValuesList, 0, 0, 0, 0, 0}, + {XNVisiblePosition, 0, 0, 0, 0, 0} +}; + +static XIMResource ic_resources[] = { + {XNInputStyle, 0, XimType_CARD32, 0, 0, 0}, + {XNClientWindow, 0, XimType_Window, 0, 0, 0}, + {XNFocusWindow, 0, XimType_Window, 0, 0, 0}, + {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, + {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, + {XNGeometryCallback, 0, 0, 0, 0, 0}, + {XNFilterEvents, 0, XimType_CARD32, 0, 0, 0}, + {XNDestroyCallback, 0, 0, 0, 0, 0}, + {XNStringConversionCallback, 0, 0, 0, 0, 0}, + {XNStringConversion, 0, XimType_XIMStringConversion,0, 0, 0}, + {XNResetState, 0, 0, 0, 0, 0}, + {XNHotKey, 0, XimType_XIMHotKeyTriggers,0, 0, 0}, + {XNHotKeyState, 0, XimType_XIMHotKeyState, 0, 0, 0}, + {XNPreeditAttributes, 0, XimType_NEST, 0, 0, 0}, + {XNStatusAttributes, 0, XimType_NEST, 0, 0, 0}, + {XNArea, 0, XimType_XRectangle, 0, 0, 0}, + {XNAreaNeeded, 0, XimType_XRectangle, 0, 0, 0}, + {XNSpotLocation, 0, XimType_XPoint, 0, 0, 0}, + {XNColormap, 0, XimType_CARD32, 0, 0, 0}, + {XNStdColormap, 0, XimType_CARD32, 0, 0, 0}, + {XNForeground, 0, XimType_CARD32, 0, 0, 0}, + {XNBackground, 0, XimType_CARD32, 0, 0, 0}, + {XNBackgroundPixmap, 0, XimType_CARD32, 0, 0, 0}, + {XNFontSet, 0, XimType_XFontSet, 0, 0, 0}, + {XNLineSpace, 0, XimType_CARD32, 0, 0, 0}, + {XNCursor, 0, XimType_CARD32, 0, 0, 0}, + {XNPreeditStartCallback, 0, 0, 0, 0, 0}, + {XNPreeditDoneCallback, 0, 0, 0, 0, 0}, + {XNPreeditDrawCallback, 0, 0, 0, 0, 0}, + {XNPreeditCaretCallback, 0, 0, 0, 0, 0}, + {XNStatusStartCallback, 0, 0, 0, 0, 0}, + {XNStatusDoneCallback, 0, 0, 0, 0, 0}, + {XNStatusDrawCallback, 0, 0, 0, 0, 0}, + {XNPreeditState, 0, 0, 0, 0, 0}, + {XNPreeditStateNotifyCallback, 0, 0, 0, 0, 0}, +}; + +static XIMResource ic_inner_resources[] = { + {XNResourceName, 0, XimType_STRING8, 0, 0, 0}, + {XNResourceClass, 0, XimType_STRING8, 0, 0, 0}, + {XNGeometryCallback, 0, 0, 0, 0, 0}, + {XNDestroyCallback, 0, 0, 0, 0, 0}, + {XNStringConversionCallback, 0, 0, 0, 0, 0}, + {XNPreeditStartCallback, 0, 0, 0, 0, 0}, + {XNPreeditDoneCallback, 0, 0, 0, 0, 0}, + {XNPreeditDrawCallback, 0, 0, 0, 0, 0}, + {XNPreeditCaretCallback, 0, 0, 0, 0, 0}, + {XNStatusStartCallback, 0, 0, 0, 0, 0}, + {XNStatusDoneCallback, 0, 0, 0, 0, 0}, + {XNStatusDrawCallback, 0, 0, 0, 0, 0}, + {XNPreeditStateNotifyCallback, 0, 0, 0, 0, 0}, +}; + +static XimValueOffsetInfoRec im_attr_info[] = { + {OFFSET_XNQUERYINPUTSTYLE, 0, + XOffsetOf(XimDefIMValues, styles), + _XimDefaultStyles, NULL, _XimDecodeStyles}, + + {OFFSET_XNDESTROYCALLBACK, 0, + XOffsetOf(XimDefIMValues, destroy_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNRESOURCENAME, 0, + XOffsetOf(XimDefIMValues, res_name), + NULL, _XimEncodeString, _XimDecodeString}, + + {OFFSET_XNRESOURCECLASS, 0, + XOffsetOf(XimDefIMValues, res_class), + NULL, _XimEncodeString, _XimDecodeString}, + + {OFFSET_XNQUERYIMVALUESLIST, 0, + XOffsetOf(XimDefIMValues, im_values_list), + _XimDefaultIMValues, NULL, _XimDecodeValues}, + + {OFFSET_XNQUERYICVALUESLIST, 0, + XOffsetOf(XimDefIMValues, ic_values_list), + _XimDefaultICValues, NULL, _XimDecodeValues}, + + {OFFSET_XNVISIBLEPOSITION, 0, + XOffsetOf(XimDefIMValues, visible_position), + _XimDefaultVisiblePos, NULL, _XimDecodeBool} +}; + +static XimValueOffsetInfoRec ic_attr_info[] = { + {OFFSET_XNINPUTSTYLE, 0, + XOffsetOf(XimDefICValues, input_style), + NULL, _XimEncodeStyle, _XimDecodeStyle}, + + {OFFSET_XNCLIENTWINDOW, 0, + XOffsetOf(XimDefICValues, client_window), + NULL, _XimEncodeWindow, _XimDecodeWindow}, + + {OFFSET_XNFOCUSWINDOW, 0, + XOffsetOf(XimDefICValues, focus_window), + _XimDefaultFocusWindow, _XimEncodeWindow, _XimDecodeWindow}, + + {OFFSET_XNRESOURCENAME, 0, + XOffsetOf(XimDefICValues, res_name), + _XimDefaultResName, _XimEncodeString, _XimDecodeString}, + + {OFFSET_XNRESOURCECLASS, 0, + XOffsetOf(XimDefICValues, res_class), + _XimDefaultResClass, _XimEncodeString, _XimDecodeString}, + + {OFFSET_XNGEOMETRYCALLBACK, 0, + XOffsetOf(XimDefICValues, geometry_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNFILTEREVENTS, 0, + XOffsetOf(XimDefICValues, filter_events), + NULL, NULL, _XimDecodeLong}, + + {OFFSET_XNDESTROYCALLBACK, 0, + XOffsetOf(XimDefICValues, destroy_callback), + _XimDefaultDestroyCB, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNSTRINGCONVERSIONCALLBACK, 0, + XOffsetOf(XimDefICValues, string_conversion_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNSTRINGCONVERSION, 0, + XOffsetOf(XimDefICValues, string_conversion), + NULL, _XimEncodeStringConv, _XimDecodeStringConv}, + + {OFFSET_XNRESETSTATE, 0, + XOffsetOf(XimDefICValues, reset_state), + _XimDefaultResetState, _XimEncodeResetState, _XimDecodeResetState}, + + {OFFSET_XNHOTKEY, 0, + XOffsetOf(XimDefICValues, hotkey), + NULL, _XimEncodeHotKey, _XimDecodeHotKey}, + + {OFFSET_XNHOTKEYSTATE, 0, + XOffsetOf(XimDefICValues, hotkey_state), + _XimDefaultHotKeyState, _XimEncodeHotKetState, _XimDecodeHotKetState}, + + {OFFSET_XNPREEDITATTRIBUTES, 0, + XOffsetOf(XimDefICValues, preedit_attr), + _XimDefaultNest, _XimEncodeNest, _XimDecodeNest}, + + {OFFSET_XNSTATUSATTRIBUTES, 0, + XOffsetOf(XimDefICValues, status_attr), + _XimDefaultNest, _XimEncodeNest, _XimDecodeNest}, +}; + +static XimValueOffsetInfoRec ic_pre_attr_info[] = { + {OFFSET_XNAREA, 0, + XOffsetOf(ICPreeditAttributes, area), + _XimDefaultArea, _XimEncodeRectangle, _XimDecodeRectangle}, + + {OFFSET_XNAREANEEDED, 0, + XOffsetOf(ICPreeditAttributes, area_needed), + NULL, _XimEncodeRectangle, _XimDecodeRectangle}, + + {OFFSET_XNSPOTLOCATION, 0, + XOffsetOf(ICPreeditAttributes, spot_location), + NULL, _XimEncodeSpot, _XimDecodeSpot}, + + {OFFSET_XNCOLORMAP, 0, + XOffsetOf(ICPreeditAttributes, colormap), + _XimDefaultColormap, _XimEncodeColormap, _XimDecodeColormap}, + + {OFFSET_XNSTDCOLORMAP, 0, + XOffsetOf(ICPreeditAttributes, std_colormap), + _XimDefaultStdColormap, _XimEncodeStdColormap, _XimDecodeStdColormap}, + + {OFFSET_XNFOREGROUND, 0, + XOffsetOf(ICPreeditAttributes, foreground), + _XimDefaultFg, _XimEncodeLong, _XimDecodeLong}, + + {OFFSET_XNBACKGROUND, 0, + XOffsetOf(ICPreeditAttributes, background), + _XimDefaultBg, _XimEncodeLong, _XimDecodeLong}, + + {OFFSET_XNBACKGROUNDPIXMAP, 0, + XOffsetOf(ICPreeditAttributes, background_pixmap), + _XimDefaultBgPixmap, _XimEncodeBgPixmap, _XimDecodeBgPixmap}, + + {OFFSET_XNFONTSET, 0, + XOffsetOf(ICPreeditAttributes, fontset), + _XimDefaultFontSet, _XimEncodeFontSet, _XimDecodeFontSet}, + + {OFFSET_XNLINESPACE, 0, + XOffsetOf(ICPreeditAttributes, line_spacing), + _XimDefaultLineSpace, _XimEncodeLineSpace, _XimDecodeLineSpace}, + + {OFFSET_XNCURSOR, 0, + XOffsetOf(ICPreeditAttributes, cursor), + _XimDefaultCursor, _XimEncodeCursor, _XimDecodeCursor}, + + {OFFSET_XNPREEDITSTARTCALLBACK, 0, + XOffsetOf(ICPreeditAttributes, start_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNPREEDITDONECALLBACK, 0, + XOffsetOf(ICPreeditAttributes, done_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNPREEDITDRAWCALLBACK, 0, + XOffsetOf(ICPreeditAttributes, draw_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNPREEDITCARETCALLBACK, 0, + XOffsetOf(ICPreeditAttributes, caret_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNPREEDITSTATE, 0, + XOffsetOf(ICPreeditAttributes, preedit_state), + _XimDefaultPreeditState, _XimEncodePreeditState,_XimDecodePreeditState}, + + {OFFSET_XNPREEDITSTATENOTIFYCALLBACK, 0, + XOffsetOf(ICPreeditAttributes, state_notify_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, +}; + +static XimValueOffsetInfoRec ic_sts_attr_info[] = { + {OFFSET_XNAREA, 0, + XOffsetOf(ICStatusAttributes, area), + _XimDefaultArea, _XimEncodeRectangle, _XimDecodeRectangle}, + + {OFFSET_XNAREANEEDED, 0, + XOffsetOf(ICStatusAttributes, area_needed), + NULL, _XimEncodeRectangle, _XimDecodeRectangle}, + + {OFFSET_XNCOLORMAP, 0, + XOffsetOf(ICStatusAttributes, colormap), + _XimDefaultColormap, _XimEncodeColormap, _XimDecodeColormap}, + + {OFFSET_XNSTDCOLORMAP, 0, + XOffsetOf(ICStatusAttributes, std_colormap), + _XimDefaultStdColormap, _XimEncodeStdColormap, _XimDecodeStdColormap}, + + {OFFSET_XNFOREGROUND, 0, + XOffsetOf(ICStatusAttributes, foreground), + _XimDefaultFg, _XimEncodeLong, _XimDecodeLong}, + + {OFFSET_XNBACKGROUND, 0, + XOffsetOf(ICStatusAttributes, background), + _XimDefaultBg, _XimEncodeLong, _XimDecodeLong}, + + {OFFSET_XNBACKGROUNDPIXMAP, 0, + XOffsetOf(ICStatusAttributes, background_pixmap), + _XimDefaultBgPixmap, _XimEncodeBgPixmap, _XimDecodeBgPixmap}, + + {OFFSET_XNFONTSET, 0, + XOffsetOf(ICStatusAttributes, fontset), + _XimDefaultFontSet, _XimEncodeFontSet, _XimDecodeFontSet}, + + {OFFSET_XNLINESPACE, 0, + XOffsetOf(ICStatusAttributes, line_spacing), + _XimDefaultLineSpace, _XimEncodeLineSpace, _XimDecodeLineSpace}, + + {OFFSET_XNCURSOR, 0, + XOffsetOf(ICStatusAttributes, cursor), + _XimDefaultCursor, _XimEncodeCursor, _XimDecodeCursor}, + + {OFFSET_XNSTATUSSTARTCALLBACK, 0, + XOffsetOf(ICStatusAttributes, start_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNSTATUSDONECALLBACK, 0, + XOffsetOf(ICStatusAttributes, done_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback}, + + {OFFSET_XNSTATUSDRAWCALLBACK, 0, + XOffsetOf(ICStatusAttributes, draw_callback), + NULL, _XimEncodeCallback, _XimDecodeCallback} +}; + +typedef struct _XimIMMode { + unsigned short name_offset; + unsigned short mode; +} XimIMMode; + +static const XimIMMode im_mode[] = { + {OFFSET_XNQUERYINPUTSTYLE, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)}, + {OFFSET_XNDESTROYCALLBACK, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_SET | XIM_MODE_IM_GET)}, + {OFFSET_XNRESOURCENAME, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_SET | XIM_MODE_IM_GET)}, + {OFFSET_XNRESOURCECLASS, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_SET | XIM_MODE_IM_GET)}, + {OFFSET_XNQUERYIMVALUESLIST, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)}, + {OFFSET_XNQUERYICVALUESLIST, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)}, + {OFFSET_XNVISIBLEPOSITION, + (XIM_MODE_IM_DEFAULT | XIM_MODE_IM_GET)} +}; + +typedef struct _XimICMode { + unsigned short name_offset; + unsigned short preedit_callback_mode; + unsigned short preedit_position_mode; + unsigned short preedit_area_mode; + unsigned short preedit_nothing_mode; + unsigned short preedit_none_mode; + unsigned short status_callback_mode; + unsigned short status_area_mode; + unsigned short status_nothing_mode; + unsigned short status_none_mode; +} XimICMode; + +static const XimICMode ic_mode[] = { + {OFFSET_XNINPUTSTYLE, + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_GET), + (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET), + (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET), + (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET), + (XIM_MODE_STS_CREATE | XIM_MODE_STS_GET)}, + {OFFSET_XNCLIENTWINDOW, + (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_ONCE | XIM_MODE_PRE_GET), + 0, + (XIM_MODE_STS_ONCE | XIM_MODE_STS_GET), + (XIM_MODE_STS_ONCE | XIM_MODE_STS_GET), + (XIM_MODE_STS_ONCE | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNFOCUSWINDOW, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNRESOURCENAME, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNRESOURCECLASS, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNGEOMETRYCALLBACK, + 0, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0, + 0}, + {OFFSET_XNFILTEREVENTS, + XIM_MODE_PRE_GET, + XIM_MODE_PRE_GET, + XIM_MODE_PRE_GET, + XIM_MODE_PRE_GET, + 0, + XIM_MODE_STS_GET, + XIM_MODE_STS_GET, + XIM_MODE_STS_GET, + XIM_MODE_STS_GET}, + {OFFSET_XNDESTROYCALLBACK, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0}, + {OFFSET_XNSTRINGCONVERSIONCALLBACK, + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0}, + {OFFSET_XNSTRINGCONVERSION, + XIM_MODE_PRE_SET, + XIM_MODE_PRE_SET, + XIM_MODE_PRE_SET, + XIM_MODE_PRE_SET, + XIM_MODE_PRE_SET, + 0, + 0, + 0, + 0}, + {OFFSET_XNRESETSTATE, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNHOTKEY, + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNHOTKEYSTATE, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNPREEDITATTRIBUTES, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNSTATUSATTRIBUTES, + 0, + 0, + 0, + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNAREA, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0, + 0}, + {OFFSET_XNAREANEEDED, + 0, + 0, + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + (XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0, + 0}, + {OFFSET_XNSPOTLOCATION, + 0, /*(XIM_MODE_PRE_SET | XIM_MODE_PRE_GET),*/ + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0}, + {OFFSET_XNCOLORMAP, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNSTDCOLORMAP, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNFOREGROUND, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNBACKGROUND, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNBACKGROUNDPIXMAP, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNFONTSET, + 0, + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNLINESPACE, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNCURSOR, + 0, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + (XIM_MODE_STS_DEFAULT | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0}, + {OFFSET_XNPREEDITSTARTCALLBACK, + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNPREEDITDONECALLBACK, + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNPREEDITDRAWCALLBACK, + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNPREEDITCARETCALLBACK, + (XIM_MODE_PRE_CREATE | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNPREEDITSTATE, + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_DEFAULT | XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNPREEDITSTATENOTIFYCALLBACK, + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + (XIM_MODE_PRE_SET | XIM_MODE_PRE_GET), + 0, + 0, + 0, + 0, + 0}, + {OFFSET_XNSTATUSSTARTCALLBACK, + 0, + 0, + 0, + 0, + 0, + (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0, + 0, + 0}, + {OFFSET_XNSTATUSDONECALLBACK, + 0, + 0, + 0, + 0, + 0, + (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0, + 0, + 0}, + {OFFSET_XNSTATUSDRAWCALLBACK, + 0, + 0, + 0, + 0, + 0, + (XIM_MODE_STS_CREATE | XIM_MODE_STS_SET | XIM_MODE_STS_GET), + 0, + 0, + 0} +}; + +/* the quarks are separated from im_mode/ic_mode so those arrays + * can be const. + */ +static XrmQuark im_mode_quark[sizeof(im_mode) / sizeof(im_mode[0])]; +static XrmQuark ic_mode_quark[sizeof(ic_mode) / sizeof(ic_mode[0])]; + +Private Bool +_XimSetResourceList( + XIMResourceList *res_list, + unsigned int *list_num, + XIMResourceList resource, + unsigned int num_resource, + unsigned short id) +{ + register int i; + int len; + XIMResourceList res; + + len = sizeof(XIMResource) * num_resource; + if(!(res = (XIMResourceList)Xmalloc(len))) { + return False; + } + bzero((char *)res, len); + + for(i = 0; i < num_resource; i++, id++) { + res[i] = resource[i]; + res[i].id = id; + } + + _XIMCompileResourceList(res, num_resource); + *res_list = res; + *list_num = num_resource; + return True; +} + +Public Bool +_XimSetIMResourceList( + XIMResourceList *res_list, + unsigned int *list_num) +{ + return _XimSetResourceList(res_list, list_num, + im_resources, XIMNumber(im_resources), 100); +} + +Public Bool +_XimSetICResourceList( + XIMResourceList *res_list, + unsigned int *list_num) +{ + return _XimSetResourceList(res_list, list_num, + ic_resources, XIMNumber(ic_resources), 200); +} + +Public Bool +_XimSetInnerIMResourceList( + XIMResourceList *res_list, + unsigned int *list_num) +{ + return _XimSetResourceList(res_list, list_num, + im_inner_resources, XIMNumber(im_inner_resources), 100); +} + +Public Bool +_XimSetInnerICResourceList( + XIMResourceList *res_list, + unsigned int *list_num) +{ + return _XimSetResourceList(res_list, list_num, + ic_inner_resources, XIMNumber(ic_inner_resources), 200); +} + +Private XIMResourceList +_XimGetResourceListRecByMode( + XIMResourceList res_list, + unsigned int list_num, + unsigned short mode) +{ + register int i; + + for(i = 0; i < list_num; i++) { + if (res_list[i].mode & mode) { + return (XIMResourceList)&res_list[i]; + } + } + return (XIMResourceList)NULL; +} + +Public Bool +_XimCheckCreateICValues( + XIMResourceList res_list, + unsigned int list_num) +{ + if (!_XimGetResourceListRecByMode(res_list, list_num, XIM_MODE_IC_CREATE)) { + return True; + } + return False; +} + +Public XIMResourceList +_XimGetResourceListRecByQuark( + XIMResourceList res_list, + unsigned int list_num, + XrmQuark quark) +{ + register int i; + + for(i = 0; i < list_num; i++) { + if (res_list[i].xrm_name == quark) { + return (XIMResourceList)&res_list[i]; + } + } + return (XIMResourceList)NULL; +} + +Public XIMResourceList +_XimGetResourceListRec( + XIMResourceList res_list, + unsigned int list_num, + const char *name) +{ + XrmQuark quark = XrmStringToQuark(name); + + return _XimGetResourceListRecByQuark(res_list, list_num, quark); +} + +Public char * +_XimSetIMValueData( + Xim im, + XPointer top, + XIMArg *values, + XIMResourceList res_list, + unsigned int list_num) +{ + register XIMArg *p; + XIMResourceList res; + int check; + + for(p = values; p->name != NULL; p++) { + if(!(res = _XimGetResourceListRec(res_list, list_num, p->name))) { + return p->value; + } + check = _XimCheckIMMode(res, XIM_SETIMVALUES); + if(check == XIM_CHECK_INVALID) { + continue; + } else if (check == XIM_CHECK_ERROR) { + return p->value; + } + + if(!_XimEncodeLocalIMAttr(res, top, p->value)) { + return p->value; + } + } + return NULL; +} + +Public char * +_XimGetIMValueData( + Xim im, + XPointer top, + XIMArg *values, + XIMResourceList res_list, + unsigned int list_num) +{ + register XIMArg *p; + XIMResourceList res; + int check; + + for(p = values; p->name != NULL; p++) { + if(!(res = _XimGetResourceListRec(res_list, list_num, p->name))) { + return p->value; + } + check = _XimCheckIMMode(res, XIM_GETIMVALUES); + if(check == XIM_CHECK_INVALID) { + continue; + } else if (check == XIM_CHECK_ERROR) { + return p->value; + } + + if(!_XimDecodeLocalIMAttr(res, top, p->value)) { + return p->value; + } + } + return NULL; +} + +Public void +_XimSetIMMode( + XIMResourceList res_list, + unsigned int list_num) +{ + XIMResourceList res; + unsigned int n = XIMNumber(im_mode); + register int i; + + for(i = 0; i < n; i++) { + if(!(res = _XimGetResourceListRecByQuark(res_list, + list_num, im_mode_quark[i]))) { + continue; + } + res->mode = im_mode[i].mode; + } + return; +} + +Private int +_XimCheckSetIMDefaultsMode( + XIMResourceList res) +{ + if(res->mode & XIM_MODE_IM_DEFAULT) { + return XIM_CHECK_VALID; + } + return XIM_CHECK_INVALID; +} + +Private int +_XimCheckSetIMValuesMode( + XIMResourceList res) +{ + if(res->mode & XIM_MODE_IM_SET) { + return XIM_CHECK_VALID; + } + return XIM_CHECK_INVALID; +} + +Private int + _XimCheckGetIMValuesMode( + XIMResourceList res) +{ + if(res->mode & XIM_MODE_IM_GET) { + return XIM_CHECK_VALID; + } + return XIM_CHECK_INVALID; +} + +Public int + _XimCheckIMMode( + XIMResourceList res, + unsigned long mode) +{ + if(res->mode == 0) { + return XIM_CHECK_INVALID; + } + if(mode & XIM_SETIMDEFAULTS) { + return _XimCheckSetIMDefaultsMode(res); + } else if (mode & XIM_SETIMVALUES) { + return _XimCheckSetIMValuesMode(res); + } else if (mode & XIM_GETIMVALUES) { + return _XimCheckGetIMValuesMode(res); + } else { + return XIM_CHECK_ERROR; + } +} + +Public void +_XimSetICMode(XIMResourceList res_list, unsigned int list_num, XIMStyle style) +{ + XIMResourceList res; + unsigned int n = XIMNumber(ic_mode); + register int i; + unsigned int pre_offset; + unsigned int sts_offset; + + if(style & XIMPreeditArea) { + pre_offset = XOffsetOf(XimICMode, preedit_area_mode); + } else if(style & XIMPreeditCallbacks) { + pre_offset = XOffsetOf(XimICMode, preedit_callback_mode); + } else if(style & XIMPreeditPosition) { + pre_offset = XOffsetOf(XimICMode, preedit_position_mode); + } else if(style & XIMPreeditNothing) { + pre_offset = XOffsetOf(XimICMode, preedit_nothing_mode); + } else { + pre_offset = XOffsetOf(XimICMode, preedit_none_mode); + } + + if(style & XIMStatusArea) { + sts_offset = XOffsetOf(XimICMode, status_area_mode); + } else if(style & XIMStatusCallbacks) { + sts_offset = XOffsetOf(XimICMode, status_callback_mode); + } else if(style & XIMStatusNothing) { + sts_offset = XOffsetOf(XimICMode, status_nothing_mode); + } else { + sts_offset = XOffsetOf(XimICMode, status_none_mode); + } + + for(i = 0; i < n; i++) { + if(!(res = _XimGetResourceListRecByQuark(res_list, + list_num, ic_mode_quark[i]))) { + continue; + } + res->mode = ( (*(unsigned short *)((char *)&ic_mode[i] + pre_offset)) + | (*(unsigned short *)((char *)&ic_mode[i] + sts_offset))); + } + return; +} + +Private int +_XimCheckSetICDefaultsMode( + XIMResourceList res, + unsigned long mode) +{ + if(mode & XIM_PREEDIT_ATTR) { + if(!(res->mode & XIM_MODE_PRE_MASK)) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_PRE_CREATE) { + return XIM_CHECK_ERROR; + } else if (!(res->mode & XIM_MODE_PRE_DEFAULT)) { + return XIM_CHECK_INVALID; + } + + } else if(mode & XIM_STATUS_ATTR) { + if(!(res->mode & XIM_MODE_STS_MASK)) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_STS_CREATE) { + return XIM_CHECK_ERROR; + } + if(!(res->mode & XIM_MODE_STS_DEFAULT)) { + return XIM_CHECK_INVALID; + } + + } else { + if(!res->mode) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_IC_CREATE) { + return XIM_CHECK_ERROR; + } + if(!(res->mode & XIM_MODE_IC_DEFAULT)) { + return XIM_CHECK_INVALID; + } + } + return XIM_CHECK_VALID; +} + +Private int +_XimCheckCreateICMode( + XIMResourceList res, + unsigned long mode) +{ + if(mode & XIM_PREEDIT_ATTR) { + if(!(res->mode & XIM_MODE_PRE_MASK)) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_PRE_CREATE) { + res->mode &= ~XIM_MODE_PRE_CREATE; + } else if(res->mode & XIM_MODE_PRE_ONCE) { + res->mode &= ~XIM_MODE_PRE_ONCE; + } else if(res->mode & XIM_MODE_PRE_DEFAULT) { + res->mode &= ~XIM_MODE_PRE_DEFAULT; + } else if (!(res->mode & XIM_MODE_PRE_SET)) { + return XIM_CHECK_ERROR; + } + + } else if(mode & XIM_STATUS_ATTR) { + if(!(res->mode & XIM_MODE_STS_MASK)) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_STS_CREATE) { + res->mode &= ~XIM_MODE_STS_CREATE; + } else if(res->mode & XIM_MODE_STS_ONCE) { + res->mode &= ~XIM_MODE_STS_ONCE; + } else if(res->mode & XIM_MODE_STS_DEFAULT) { + res->mode &= ~XIM_MODE_STS_DEFAULT; + } else if (!(res->mode & XIM_MODE_STS_SET)) { + return XIM_CHECK_ERROR; + } + + } else { + if(!res->mode) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_IC_CREATE) { + res->mode &= ~XIM_MODE_IC_CREATE; + } else if(res->mode & XIM_MODE_IC_ONCE) { + res->mode &= ~XIM_MODE_IC_ONCE; + } else if(res->mode & XIM_MODE_IC_DEFAULT) { + res->mode &= ~XIM_MODE_IC_DEFAULT; + } else if (!(res->mode & XIM_MODE_IC_SET)) { + return XIM_CHECK_ERROR; + } + } + return XIM_CHECK_VALID; +} + +Private int +_XimCheckSetICValuesMode( + XIMResourceList res, + unsigned long mode) +{ + if(mode & XIM_PREEDIT_ATTR) { + if(!(res->mode & XIM_MODE_PRE_MASK)) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_PRE_ONCE) { + res->mode &= ~XIM_MODE_PRE_ONCE; + } else if(!(res->mode & XIM_MODE_PRE_SET)) { + return XIM_CHECK_ERROR; + } + + } else if(mode & XIM_STATUS_ATTR) { + if(!(res->mode & XIM_MODE_STS_MASK)) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_STS_ONCE) { + res->mode &= ~XIM_MODE_STS_ONCE; + } else if(!(res->mode & XIM_MODE_STS_SET)) { + return XIM_CHECK_ERROR; + } + + } else { + if(!res->mode) { + return XIM_CHECK_INVALID; + } + + if(res->mode & XIM_MODE_IC_ONCE) { + res->mode &= ~XIM_MODE_IC_ONCE; + } else if(!(res->mode & XIM_MODE_IC_SET)) { + return XIM_CHECK_ERROR; + } + } + return XIM_CHECK_VALID; +} + +Private int +_XimCheckGetICValuesMode( + XIMResourceList res, + unsigned long mode) +{ + if(mode & XIM_PREEDIT_ATTR) { + if(!(res->mode & XIM_MODE_PRE_MASK)) { + return XIM_CHECK_INVALID; + } + + if(!(res->mode & XIM_MODE_PRE_GET)) { + return XIM_CHECK_ERROR; + } + + } else if(mode & XIM_STATUS_ATTR) { + if(!(res->mode & XIM_MODE_STS_MASK)) { + return XIM_CHECK_INVALID; + } + + if(!(res->mode & XIM_MODE_STS_GET)) { + return XIM_CHECK_ERROR; + } + + } else { + if(!res->mode) { + return XIM_CHECK_INVALID; + } + + if(!(res->mode & XIM_MODE_IC_GET)) { + return XIM_CHECK_ERROR; + } + } + return XIM_CHECK_VALID; +} + +Public int + _XimCheckICMode( + XIMResourceList res, + unsigned long mode) +{ + if(mode &XIM_SETICDEFAULTS) { + return _XimCheckSetICDefaultsMode(res, mode); + } else if (mode & XIM_CREATEIC) { + return _XimCheckCreateICMode(res, mode); + } else if (mode & XIM_SETICVALUES) { + return _XimCheckSetICValuesMode(res, mode); + } else if (mode & XIM_GETICVALUES) { + return _XimCheckGetICValuesMode(res, mode); + } else { + return XIM_CHECK_ERROR; + } +} + +Public Bool +_XimSetLocalIMDefaults( + Xim im, + XPointer top, + XIMResourceList res_list, + unsigned int list_num) +{ + XimValueOffsetInfo info; + unsigned int num; + register int i; + XIMResourceList res; + int check; + + info = im_attr_info; + num = XIMNumber(im_attr_info); + + for(i = 0; i < num; i++) { + if((res = _XimGetResourceListRecByQuark( res_list, list_num, + info[i].quark)) == (XIMResourceList)NULL) { + return False; + } + + check = _XimCheckIMMode(res, XIM_SETIMDEFAULTS); + if(check == XIM_CHECK_INVALID) { + continue; + } else if (check == XIM_CHECK_ERROR) { + return False; + } + + if(!info[i].defaults) { + continue; + } + if(!(info[i].defaults(&info[i], top, (XPointer)NULL, 0))) { + return False; + } + } + return True; +} + +Public Bool +_XimSetICDefaults( + Xic ic, + XPointer top, + unsigned long mode, + XIMResourceList res_list, + unsigned int list_num) +{ + unsigned int num; + XimValueOffsetInfo info; + register int i; + XIMResourceList res; + int check; + XrmQuark pre_quark; + XrmQuark sts_quark; + + pre_quark = XrmStringToQuark(XNPreeditAttributes); + sts_quark = XrmStringToQuark(XNStatusAttributes); + + if(mode & XIM_PREEDIT_ATTR) { + info = ic_pre_attr_info; + num = XIMNumber(ic_pre_attr_info); + } else if(mode & XIM_STATUS_ATTR) { + info = ic_sts_attr_info; + num = XIMNumber(ic_sts_attr_info); + } else { + info = ic_attr_info; + num = XIMNumber(ic_attr_info); + } + + for(i = 0; i < num; i++) { + if(info[i].quark == pre_quark) { + if(!_XimSetICDefaults(ic, (XPointer)((char *)top + info[i].offset), + (mode | XIM_PREEDIT_ATTR), res_list, list_num)) { + return False; + } + } else if (info[i].quark == sts_quark) { + if(!_XimSetICDefaults(ic, (XPointer)((char *)top + info[i].offset), + (mode | XIM_STATUS_ATTR), res_list, list_num)) { + return False; + } + } else { + if(!(res = _XimGetResourceListRecByQuark(res_list, list_num, + info[i].quark))) { + return False; + } + + check = _XimCheckICMode(res, mode); + if (check == XIM_CHECK_INVALID) { + continue; + } else if (check == XIM_CHECK_ERROR) { + return False; + } + + if (!info[i].defaults) { + continue; + } + if (!(info[i].defaults(&info[i], top, (XPointer)ic, mode))) { + return False; + } + } + } + return True; +} + +Private Bool +_XimEncodeAttr( + XimValueOffsetInfo info, + unsigned int num, + XIMResourceList res, + XPointer top, + XPointer val) +{ + register int i; + + for(i = 0; i < num; i++ ) { + if(info[i].quark == res->xrm_name) { + if(!info[i].encode) { + return False; + } + return (*info[i].encode)(&info[i], top, val); + } + } + return False; +} + +Public Bool +_XimEncodeLocalIMAttr( + XIMResourceList res, + XPointer top, + XPointer val) +{ + return _XimEncodeAttr(im_attr_info, XIMNumber(im_attr_info), + res, top, val); +} + +Public Bool +_XimEncodeLocalICAttr( + Xic ic, + XIMResourceList res, + XPointer top, + XIMArg *arg, + unsigned long mode) +{ + unsigned int num; + XimValueOffsetInfo info; + + if(mode & XIM_PREEDIT_ATTR) { + info = ic_pre_attr_info; + num = XIMNumber(ic_pre_attr_info); + } else if(mode & XIM_STATUS_ATTR) { + info = ic_sts_attr_info; + num = XIMNumber(ic_sts_attr_info); + } else { + info = ic_attr_info; + num = XIMNumber(ic_attr_info); + } + + return _XimEncodeAttr(info, num, res, top, arg->value); +} + +Private Bool +_XimEncodeLocalTopValue( + Xic ic, + XIMResourceList res, + XPointer val, + Bool flag) +{ + XIMArg *p = (XIMArg *)val; + + if (res->xrm_name == XrmStringToQuark(XNClientWindow)) { + ic->core.client_window = (Window)p->value; + if (ic->core.focus_window == (Window)0) + ic->core.focus_window = ic->core.client_window; + if (flag) { + _XRegisterFilterByType(ic->core.im->core.display, + ic->core.focus_window, + KeyPress, KeyRelease, _XimLocalFilter, (XPointer)ic); + } + } else if (res->xrm_name == XrmStringToQuark(XNFocusWindow)) { + if (ic->core.client_window) { + if (flag) { + _XUnregisterFilter(ic->core.im->core.display, + ic->core.focus_window, _XimLocalFilter, (XPointer)ic); + } + ic->core.focus_window = (Window)p->value; + if (flag) { + _XRegisterFilterByType(ic->core.im->core.display, + ic->core.focus_window, KeyPress, KeyRelease, + _XimLocalFilter, (XPointer)ic); + } + } else + ic->core.focus_window = (Window)p->value; + } + return True; +} + +Private Bool +_XimEncodeLocalPreeditValue( + Xic ic, + XIMResourceList res, + XPointer val) +{ + XIMArg *p = (XIMArg *)val; + + if (res->xrm_name == XrmStringToQuark(XNStdColormap)) { + XStandardColormap *colormap_ret; + int count; + + if (!(XGetRGBColormaps(ic->core.im->core.display, + ic->core.focus_window, &colormap_ret, + &count, (Atom)p->value))) + return False; + + Xfree(colormap_ret); + } + return True; +} + +Private Bool +_XimEncodeLocalStatusValue( + Xic ic, + XIMResourceList res, + XPointer val) +{ + XIMArg *p = (XIMArg *)val; + + if (res->xrm_name == XrmStringToQuark(XNStdColormap)) { + XStandardColormap *colormap_ret; + int count; + + if (!(XGetRGBColormaps(ic->core.im->core.display, + ic->core.focus_window, &colormap_ret, + &count, (Atom)p->value))) + return False; + + Xfree(colormap_ret); + } + return True; +} + +Public char * +_XimSetICValueData( + Xic ic, + XPointer top, + XIMResourceList res_list, + unsigned int list_num, + XIMArg *values, + unsigned long mode, + Bool flag) +{ + register XIMArg *p; + XIMResourceList res; + char *name; + int check; + XrmQuark pre_quark; + XrmQuark sts_quark; + + pre_quark = XrmStringToQuark(XNPreeditAttributes); + sts_quark = XrmStringToQuark(XNStatusAttributes); + + for(p = values; p->name != NULL; p++) { + if((res = _XimGetResourceListRec(res_list, list_num, + p->name)) == (XIMResourceList)NULL) { + return p->name; + } + if(res->xrm_name == pre_quark) { + if(((name = _XimSetICValueData(ic, + (XPointer)(&((XimDefICValues *)top)->preedit_attr), + res_list, list_num, (XIMArg *)p->value, + (mode | XIM_PREEDIT_ATTR), flag)))) { + return name; + } + } else if(res->xrm_name == sts_quark) { + if(((name = _XimSetICValueData(ic, + (XPointer)(&((XimDefICValues *)top)->status_attr), + res_list, list_num, (XIMArg *)p->value, + (mode | XIM_STATUS_ATTR), flag)))) { + return name; + } + } else { + check = _XimCheckICMode(res, mode); + if(check == XIM_CHECK_INVALID) { + continue; + } else if(check == XIM_CHECK_ERROR) { + return p->name; + } + + if(mode & XIM_PREEDIT_ATTR) { + if (!_XimEncodeLocalPreeditValue(ic, res, (XPointer)p)) + return False; + } else if(mode & XIM_STATUS_ATTR) { + if (!_XimEncodeLocalStatusValue(ic, res, (XPointer)p)) + return False; + } else { + if (!_XimEncodeLocalTopValue(ic, res, (XPointer)p, flag)) + return False; + } + if(_XimEncodeLocalICAttr(ic, res, top, p, mode) == False) { + return p->name; + } + } + } + return NULL; +} + +Private Bool +_XimCheckInputStyle( + XIMStyles *styles, + XIMStyle style) +{ + int num = styles->count_styles; + register int i; + + for(i = 0; i < num; i++) { + if(styles->supported_styles[i] == style) { + return True; + } + } + return False; +} + +Public Bool +_XimCheckLocalInputStyle( + Xic ic, + XPointer top, + XIMArg *values, + XIMStyles *styles, + XIMResourceList res_list, + unsigned int list_num) +{ + XrmQuark quark = XrmStringToQuark(XNInputStyle); + register XIMArg *p; + XIMResourceList res; + + for(p = values; p && p->name != NULL; p++) { + if(quark == XrmStringToQuark(p->name)) { + if(!(res = _XimGetResourceListRec(res_list, list_num, p->name))) { + return False; + } + if(!_XimEncodeLocalICAttr(ic, res, top, p, 0)) { + return False; + } + if (_XimCheckInputStyle(styles, + ((XimDefICValues *)top)->input_style)) { + return True; + } + return False; + } + } + return False; +} + +Private Bool +_XimDecodeAttr( + XimValueOffsetInfo info, + unsigned int num, + XIMResourceList res, + XPointer top, + XPointer val) +{ + register int i; + + for(i = 0; i < num; i++ ) { + if(info[i].quark == res->xrm_name) { + if(!info[i].decode) { + return False; + } + return (*info[i].decode)(&info[i], top, val); + } + } + return False; +} + +Public Bool +_XimDecodeLocalIMAttr( + XIMResourceList res, + XPointer top, + XPointer val) +{ + return _XimDecodeAttr(im_attr_info, XIMNumber(im_attr_info), + res, top, val); +} + +Public Bool +_XimDecodeLocalICAttr( + XIMResourceList res, + XPointer top, + XPointer val, + unsigned long mode) +{ + unsigned int num; + XimValueOffsetInfo info; + + if(mode & XIM_PREEDIT_ATTR) { + info = ic_pre_attr_info; + num = XIMNumber(ic_pre_attr_info); + } else if(mode & XIM_STATUS_ATTR) { + info = ic_sts_attr_info; + num = XIMNumber(ic_sts_attr_info); + } else { + info = ic_attr_info; + num = XIMNumber(ic_attr_info); + } + + return _XimDecodeAttr(info, num, res, top, val); +} + +Public char * +_XimGetICValueData(Xic ic, XPointer top, XIMResourceList res_list, + unsigned int list_num, XIMArg *values, unsigned long mode) +{ + register XIMArg *p; + XIMResourceList res; + char *name; + int check; + XrmQuark pre_quark; + XrmQuark sts_quark; + + pre_quark = XrmStringToQuark(XNPreeditAttributes); + sts_quark = XrmStringToQuark(XNStatusAttributes); + + for(p = values; p->name != NULL; p++) { + if((res = _XimGetResourceListRec(res_list, list_num, + p->name)) == (XIMResourceList)NULL) { + return p->name; + } + if(res->xrm_name == pre_quark) { + if((name = _XimGetICValueData(ic, + (XPointer)(&((XimDefICValues *)top)->preedit_attr), + res_list, list_num, (XIMArg *)p->value, + (mode | XIM_PREEDIT_ATTR)))) { + return name; + } + } else if(res->xrm_name == sts_quark) { + if((name = _XimGetICValueData(ic, + (XPointer)(&((XimDefICValues *)top)->status_attr), + res_list, list_num, (XIMArg *)p->value, + (mode | XIM_STATUS_ATTR)))) { + return name; + } + } else { + check = _XimCheckICMode(res, mode); + if(check == XIM_CHECK_INVALID) { + continue; + } else if(check == XIM_CHECK_ERROR) { + return p->name; + } + + if(_XimDecodeLocalICAttr(res, top, p->value, mode) == False) { + return p->name; + } + } + } + return NULL; +} + +Public void +_XimGetCurrentIMValues(Xim im, XimDefIMValues *im_values) +{ + bzero((char *)im_values, sizeof(XimDefIMValues)); + + im_values->styles = im->core.styles; + im_values->im_values_list = im->core.im_values_list; + im_values->ic_values_list = im->core.ic_values_list; + im_values->destroy_callback = im->core.destroy_callback; + im_values->res_name = im->core.res_name; + im_values->res_class = im->core.res_class; + im_values->visible_position = im->core.visible_position; +} + +Public void +_XimSetCurrentIMValues(Xim im, XimDefIMValues *im_values) +{ + im->core.styles = im_values->styles; + im->core.im_values_list = im_values->im_values_list; + im->core.ic_values_list = im_values->ic_values_list; + im->core.destroy_callback = im_values->destroy_callback; + im->core.res_name = im_values->res_name; + im->core.res_class = im_values->res_class; + im->core.visible_position = im_values->visible_position; +} + +Public void +_XimGetCurrentICValues(Xic ic, XimDefICValues *ic_values) +{ + bzero((char *)ic_values, sizeof(XimDefICValues)); + + ic_values->input_style = ic->core.input_style; + ic_values->client_window = ic->core.client_window; + ic_values->focus_window = ic->core.focus_window; + ic_values->filter_events = ic->core.filter_events; + ic_values->geometry_callback = ic->core.geometry_callback; + ic_values->res_name = ic->core.res_name; + ic_values->res_class = ic->core.res_class; + ic_values->destroy_callback = ic->core.destroy_callback; + ic_values->string_conversion_callback + = ic->core.string_conversion_callback; + ic_values->string_conversion = ic->core.string_conversion; + ic_values->reset_state = ic->core.reset_state; + ic_values->hotkey = ic->core.hotkey; + ic_values->hotkey_state = ic->core.hotkey_state; + ic_values->preedit_attr = ic->core.preedit_attr; + ic_values->status_attr = ic->core.status_attr; +} + +Public void +_XimSetCurrentICValues( + Xic ic, + XimDefICValues *ic_values) +{ + ic->core.input_style = ic_values->input_style; + ic->core.client_window = ic_values->client_window; + if (ic_values->focus_window) + ic->core.focus_window = ic_values->focus_window; + ic->core.filter_events = ic_values->filter_events; + ic->core.geometry_callback = ic_values->geometry_callback; + ic->core.res_name = ic_values->res_name; + ic->core.res_class = ic_values->res_class; + ic->core.destroy_callback = ic_values->destroy_callback; + ic->core.string_conversion_callback + = ic_values->string_conversion_callback; + ic->core.string_conversion = ic_values->string_conversion; + ic->core.reset_state = ic_values->reset_state; + ic->core.hotkey = ic_values->hotkey; + ic->core.hotkey_state = ic_values->hotkey_state; + ic->core.preedit_attr = ic_values->preedit_attr; + ic->core.status_attr = ic_values->status_attr; +} + +Private void +_XimInitialIMOffsetInfo(void) +{ + unsigned int n = XIMNumber(im_attr_info); + register int i; + + for(i = 0; i < n; i++) { + im_attr_info[i].quark = XrmStringToQuark(GET_NAME(im_attr_info[i])); + } +} + +Private void +_XimInitialICOffsetInfo(void) +{ + unsigned int n; + register int i; + + n = XIMNumber(ic_attr_info); + for(i = 0; i < n; i++) { + ic_attr_info[i].quark = XrmStringToQuark(GET_NAME(ic_attr_info[i])); + } + + n = XIMNumber(ic_pre_attr_info); + for(i = 0; i < n; i++) { + ic_pre_attr_info[i].quark = XrmStringToQuark(GET_NAME(ic_pre_attr_info[i])); + } + + n = XIMNumber(ic_sts_attr_info); + for(i = 0; i < n; i++) { + ic_sts_attr_info[i].quark = XrmStringToQuark(GET_NAME(ic_sts_attr_info[i])); + } +} + +Private void +_XimInitialIMMode(void) +{ + unsigned int n = XIMNumber(im_mode); + register int i; + + for(i = 0; i < n; i++) { + im_mode_quark[i] = XrmStringToQuark(GET_NAME(im_mode[i])); + } +} + +Private void +_XimInitialICMode(void) +{ + unsigned int n = XIMNumber(ic_mode); + register int i; + + for(i = 0; i < n; i++) { + ic_mode_quark[i] = XrmStringToQuark(GET_NAME(ic_mode[i])); + } +} + +Public void +_XimInitialResourceInfo(void) +{ + static Bool init_flag = False; + + if(init_flag == True) { + return; + } + _XimInitialIMOffsetInfo(); + _XimInitialICOffsetInfo(); + _XimInitialIMMode(); + _XimInitialICMode(); + init_flag = True; +} diff --git a/libX11/modules/im/ximcp/imRmAttr.c b/libX11/modules/im/ximcp/imRmAttr.c index b6d1e1293..5035df514 100644 --- a/libX11/modules/im/ximcp/imRmAttr.c +++ b/libX11/modules/im/ximcp/imRmAttr.c @@ -313,7 +313,7 @@ _XimAttributeToValue( INT16 len = data[0]; char *base_name; XFontSet rep = (XFontSet)NULL; - char **missing_list; + char **missing_list = NULL; int missing_count; char *def_string; @@ -347,6 +347,7 @@ _XimAttributeToValue( } Xfree(base_name); + Xfree(missing_list); *((XFontSet *)value) = rep; break; } @@ -956,6 +957,7 @@ _XimEncodePreeditValue( &count, (Atom)p->value))) return False; + XFree(colormap_ret); } else if (res->xrm_name == XrmStringToQuark(XNFontSet)) { int list_ret; XFontStruct **struct_list; @@ -999,7 +1001,7 @@ _XimEncodeStatusValue( XIMArg *p) { if (res->xrm_name == XrmStringToQuark(XNStdColormap)) { - XStandardColormap *colormap_ret; + XStandardColormap *colormap_ret = NULL; int count; if (!(XGetRGBColormaps(ic->core.im->core.display, @@ -1007,6 +1009,7 @@ _XimEncodeStatusValue( &count, (Atom)p->value))) return False; + XFree(colormap_ret); } else if (res->xrm_name == XrmStringToQuark(XNFontSet)) { int list_ret; XFontStruct **struct_list; diff --git a/libX11/modules/im/ximcp/imTrX.c b/libX11/modules/im/ximcp/imTrX.c index 01c438eed..edcaf0852 100644 --- a/libX11/modules/im/ximcp/imTrX.c +++ b/libX11/modules/im/ximcp/imTrX.c @@ -1,510 +1,519 @@ -/* - * Copyright 1992 Oracle and/or its affiliates. All rights reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - */ -/****************************************************************** - - Copyright 1992, 1993, 1994 by FUJITSU LIMITED - -Permission to use, copy, modify, distribute, and sell this software -and its documentation for any purpose is hereby granted without fee, -provided that the above copyright notice appear in all copies and -that both that copyright notice and this permission notice appear -in supporting documentation, and that the name of FUJITSU LIMITED -not be used in advertising or publicity pertaining to distribution -of the software without specific, written prior permission. -FUJITSU LIMITED makes no representations about the suitability of -this software for any purpose. -It is provided "as is" without express or implied warranty. - -FUJITSU LIMITED DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, -INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO -EVENT SHALL FUJITSU LIMITED BE LIABLE FOR ANY SPECIAL, INDIRECT OR -CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF -USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR -OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR -PERFORMANCE OF THIS SOFTWARE. - - Author: Hideki Hiura (hhiura@Sun.COM) Sun Microsystems, Inc. - Takashi Fujiwara FUJITSU LIMITED - fujiwara@a80.tech.yk.fujitsu.co.jp - -******************************************************************/ - -#ifdef HAVE_CONFIG_H -#include -#endif -#include -#include -#include "Xlibint.h" -#include "Xlcint.h" -#include "Ximint.h" -#include "XimTrInt.h" -#include "XimTrX.h" - -Private Bool -_XimXRegisterDispatcher( - Xim im, - Bool (*callback)( - Xim, INT16, XPointer, XPointer - ), - XPointer call_data) -{ - XIntrCallbackPtr rec; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - - if (!(rec = (XIntrCallbackPtr)Xmalloc(sizeof(XIntrCallbackRec)))) - return False; - - rec->func = callback; - rec->call_data = call_data; - rec->next = spec->intr_cb; - spec->intr_cb = rec; - return True; -} - -Private void -_XimXFreeIntrCallback( - Xim im) -{ - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - register XIntrCallbackPtr rec, next; - - for (rec = spec->intr_cb; rec;) { - next = rec->next; - Xfree(rec); - rec = next; - } - return; -} - -Private Bool -_XimXCallDispatcher(Xim im, INT16 len, XPointer data) -{ - register XIntrCallbackRec *rec; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - - for (rec = spec->intr_cb; rec; rec = rec->next) { - if ((*rec->func)(im, len, data, rec->call_data)) - return True; - } - return False; -} - -Private Bool -_XimXFilterWaitEvent( - Display *d, - Window w, - XEvent *ev, - XPointer arg) -{ - Xim im = (Xim)arg; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - Bool ret; - - spec->ev = (XPointer)ev; - ret = _XimFilterWaitEvent(im); - - /* - * If ev is a pointer to a stack variable, there could be - * a coredump later on if the pointer is dereferenced. - * Therefore, reset to NULL to force reinitialization in - * _XimXRead(). - * - * Keep in mind _XimXRead may be called again when the stack - * is very different. - */ - spec->ev = (XPointer)NULL; - - return ret; -} - -Private Bool -_CheckConnect( - Display *display, - XEvent *event, - XPointer xim) -{ - Xim im = (Xim)xim; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - - if ((event->type == ClientMessage) - && (event->xclient.message_type == spec->imconnectid)) { - return True; - } - return False; -} - -Private Bool -_XimXConnect(Xim im) -{ - XEvent event; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - CARD32 major_code; - CARD32 minor_code; - - if (!(spec->lib_connect_wid = XCreateSimpleWindow(im->core.display, - DefaultRootWindow(im->core.display), 0, 0, 1, 1, 1, 0, 0))) { - return False; - } - - event.xclient.type = ClientMessage; - event.xclient.display = im->core.display; - event.xclient.window = im->private.proto.im_window; - event.xclient.message_type = spec->imconnectid; - event.xclient.format = 32; - event.xclient.data.l[0] = (CARD32)spec->lib_connect_wid; - event.xclient.data.l[1] = spec->major_code; - event.xclient.data.l[2] = spec->minor_code; - event.xclient.data.l[3] = 0; - event.xclient.data.l[4] = 0; - - if(event.xclient.data.l[1] == 1 || event.xclient.data.l[1] == 2) { - XWindowAttributes atr; - long event_mask; - - XGetWindowAttributes(im->core.display, spec->lib_connect_wid, &atr); - event_mask = atr.your_event_mask | PropertyChangeMask; - XSelectInput(im->core.display, spec->lib_connect_wid, event_mask); - _XRegisterFilterByType(im->core.display, spec->lib_connect_wid, - PropertyNotify, PropertyNotify, - _XimXFilterWaitEvent, (XPointer)im); - } - - XSendEvent(im->core.display, im->private.proto.im_window, - False, NoEventMask, &event); - XFlush(im->core.display); - - for (;;) { - XIfEvent(im->core.display, &event, _CheckConnect, (XPointer)im); - if (event.xclient.type != ClientMessage) { - return False; - } - if (event.xclient.message_type == spec->imconnectid) - break; - } - - spec->ims_connect_wid = (Window)event.xclient.data.l[0]; - major_code = (CARD32)event.xclient.data.l[1]; - minor_code = (CARD32)event.xclient.data.l[2]; - - if (((major_code == 0) && (minor_code <= 2)) || - ((major_code == 1) && (minor_code == 0)) || - ((major_code == 2) && (minor_code <= 1))) { - spec->major_code = major_code; - spec->minor_code = minor_code; - } - if (((major_code == 0) && (minor_code == 2)) || - ((major_code == 2) && (minor_code == 1))) { - spec->BoundarySize = (CARD32)event.xclient.data.l[3]; - } - - /* ClientMessage Event Filter */ - _XRegisterFilterByType(im->core.display, spec->lib_connect_wid, - ClientMessage, ClientMessage, - _XimXFilterWaitEvent, (XPointer)im); - return True; -} - -Private Bool -_XimXShutdown(Xim im) -{ - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - - if (!spec) - return True; - - /* ClientMessage Event Filter */ - _XUnregisterFilter(im->core.display, - ((XSpecRec *)im->private.proto.spec)->lib_connect_wid, - _XimXFilterWaitEvent, (XPointer)im); - XDestroyWindow(im->core.display, - ((XSpecRec *)im->private.proto.spec)->lib_connect_wid); - _XimXFreeIntrCallback(im); - Xfree(spec); - im->private.proto.spec = 0; - return True; -} - -Private char * -_NewAtom( - char *atomName) -{ - static int sequence = 0; - - (void)sprintf(atomName, "_client%d", sequence); - sequence = ((sequence < 20) ? sequence + 1 : 0); - return atomName; -} - -Private Bool -_XimXWrite(Xim im, INT16 len, XPointer data) -{ - Atom atom; - char atomName[16]; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - XEvent event; - CARD8 *p; - CARD32 major_code = spec->major_code; - CARD32 minor_code = spec->minor_code; - int BoundSize; - - bzero(&event,sizeof(XEvent)); - event.xclient.type = ClientMessage; - event.xclient.display = im->core.display; - event.xclient.window = spec->ims_connect_wid; - if(major_code == 1 && minor_code == 0) { - BoundSize = 0; - } else if((major_code == 0 && minor_code == 2) || - (major_code == 2 && minor_code == 1)) { - BoundSize = spec->BoundarySize; - } else if(major_code == 0 && minor_code == 1) { - BoundSize = len; - } else { - BoundSize = XIM_CM_DATA_SIZE; - } - if (len > BoundSize) { - event.xclient.message_type = spec->improtocolid; - atom = XInternAtom(im->core.display, _NewAtom(atomName), False); - XChangeProperty(im->core.display, spec->ims_connect_wid, - atom, XA_STRING, 8, PropModeAppend, - (unsigned char *)data, len); - if(major_code == 0) { - event.xclient.format = 32; - event.xclient.data.l[0] = (long)len; - event.xclient.data.l[1] = (long)atom; - XSendEvent(im->core.display, spec->ims_connect_wid, - False, NoEventMask, &event); - } - } else { - int length; - - event.xclient.format = 8; - for(length = 0 ; length < len ; length += XIM_CM_DATA_SIZE) { - p = (CARD8 *)&event.xclient.data.b[0]; - if((length + XIM_CM_DATA_SIZE) >= len) { - event.xclient.message_type = spec->improtocolid; - bzero(p, XIM_CM_DATA_SIZE); - memcpy((char *)p, (data + length), (len - length)); - } else { - event.xclient.message_type = spec->immoredataid; - memcpy((char *)p, (data + length), XIM_CM_DATA_SIZE); - } - XSendEvent(im->core.display, spec->ims_connect_wid, - False, NoEventMask, &event); - } - } - - return True; -} - -Private Bool -_XimXGetReadData( - Xim im, - char *buf, - int buf_len, - int *ret_len, - XEvent *event) -{ - char *data; - int len; - - char tmp_buf[XIM_CM_DATA_SIZE]; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - unsigned long length; - Atom prop; - int return_code; - Atom type_ret; - int format_ret; - unsigned long nitems; - unsigned long bytes_after_ret; - unsigned char *prop_ret; - - if ((event->type == ClientMessage) && - !((event->xclient.message_type == spec->improtocolid) || - (event->xclient.message_type == spec->immoredataid))) { - /* This event has nothing to do with us, - * FIXME should not have gotten here then... - */ - return False; - } else if ((event->type == ClientMessage) && (event->xclient.format == 8)) { - data = event->xclient.data.b; - if (buf_len >= XIM_CM_DATA_SIZE) { - (void)memcpy(buf, data, XIM_CM_DATA_SIZE); - *ret_len = XIM_CM_DATA_SIZE; - } else { - (void)memcpy(buf, data, buf_len); - len = XIM_CM_DATA_SIZE - buf_len; - (void)memcpy(tmp_buf, &data[buf_len], len); - bzero(data, XIM_CM_DATA_SIZE); - (void)memcpy(data, tmp_buf, len); - XPutBackEvent(im->core.display, event); - *ret_len = buf_len; - } - } else if ((event->type == ClientMessage) - && (event->xclient.format == 32)) { - length = (unsigned long)event->xclient.data.l[0]; - prop = (Atom)event->xclient.data.l[1]; - return_code = XGetWindowProperty(im->core.display, - spec->lib_connect_wid, prop, 0L, - (long)((length + 3)/ 4), True, AnyPropertyType, - &type_ret, &format_ret, &nitems, &bytes_after_ret, &prop_ret); - if (return_code != Success || format_ret == 0 || nitems == 0) { - if (return_code == Success) - XFree(prop_ret); - return False; - } - if (buf_len >= length) { - (void)memcpy(buf, prop_ret, (int)nitems); - *ret_len = (int)nitems; - if (bytes_after_ret > 0) { - XFree(prop_ret); - XGetWindowProperty(im->core.display, - spec->lib_connect_wid, prop, 0L, - ((length + bytes_after_ret + 3)/ 4), True, AnyPropertyType, - &type_ret, &format_ret, &nitems, &bytes_after_ret, - &prop_ret); - XChangeProperty(im->core.display, spec->lib_connect_wid, prop, - XA_STRING, 8, PropModePrepend, &prop_ret[length], - (nitems - length)); - } - } else { - (void)memcpy(buf, prop_ret, buf_len); - *ret_len = buf_len; - len = nitems - buf_len; - - if (bytes_after_ret > 0) { - XFree(prop_ret); - XGetWindowProperty(im->core.display, - spec->lib_connect_wid, prop, 0L, - ((length + bytes_after_ret + 3)/ 4), True, AnyPropertyType, - &type_ret, &format_ret, &nitems, &bytes_after_ret, &prop_ret); - } - XChangeProperty(im->core.display, spec->lib_connect_wid, prop, - XA_STRING, 8, PropModePrepend, &prop_ret[buf_len], len); - event->xclient.data.l[0] = (long)len; - event->xclient.data.l[1] = (long)prop; - XPutBackEvent(im->core.display, event); - } - XFree(prop_ret); - } else if (event->type == PropertyNotify) { - prop = event->xproperty.atom; - return_code = XGetWindowProperty(im->core.display, - spec->lib_connect_wid, prop, 0L, - 1000000L, True, AnyPropertyType, - &type_ret, &format_ret, &nitems, &bytes_after_ret, &prop_ret); - if (return_code != Success || format_ret == 0 || nitems == 0) { - if (return_code == Success) - XFree(prop_ret); - return False; - } - if (buf_len >= nitems) { - (void)memcpy(buf, prop_ret, (int)nitems); - *ret_len = (int)nitems; - } else { - (void)memcpy(buf, prop_ret, buf_len); - *ret_len = buf_len; - len = nitems - buf_len; - XChangeProperty(im->core.display, spec->lib_connect_wid, prop, - XA_STRING, 8, PropModePrepend, &prop_ret[buf_len], len); - } - XFree(prop_ret); - } - return True; -} - -Private Bool -_CheckCMEvent( - Display *display, - XEvent *event, - XPointer xim) -{ - Xim im = (Xim)xim; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - CARD32 major_code = spec->major_code; - - if ((event->type == ClientMessage) - &&((event->xclient.message_type == spec->improtocolid) || - (event->xclient.message_type == spec->immoredataid))) - return True; - if((major_code == 1 || major_code == 2) && - (event->type == PropertyNotify) && - (event->xproperty.state == PropertyNewValue)) - return True; - return False; -} - -Private Bool -_XimXRead(Xim im, XPointer recv_buf, int buf_len, int *ret_len) -{ - XEvent *ev; - XEvent event; - int len = 0; - XSpecRec *spec = (XSpecRec *)im->private.proto.spec; - XPointer arg = spec->ev; - - if (!arg) { - bzero(&event, sizeof(XEvent)); - ev = &event; - XIfEvent(im->core.display, ev, _CheckCMEvent, (XPointer)im); - } else { - ev = (XEvent *)arg; - spec->ev = (XPointer)NULL; - } - if (!(_XimXGetReadData(im, recv_buf, buf_len, &len, ev))) - return False; - *ret_len = len; - return True; -} - -Private void -_XimXFlush(Xim im) -{ - XFlush(im->core.display); - return; -} - -Public Bool -_XimXConf(Xim im, char *address) -{ - XSpecRec *spec; - - if (!(spec = (XSpecRec *)Xmalloc(sizeof(XSpecRec)))) - return False; - bzero(spec, sizeof(XSpecRec)); - - spec->improtocolid = XInternAtom(im->core.display, _XIM_PROTOCOL, False); - spec->imconnectid = XInternAtom(im->core.display, _XIM_XCONNECT, False); - spec->immoredataid = XInternAtom(im->core.display, _XIM_MOREDATA, False); - spec->major_code = MAJOR_TRANSPORT_VERSION; - spec->minor_code = MINOR_TRANSPORT_VERSION; - - im->private.proto.spec = (XPointer)spec; - im->private.proto.connect = _XimXConnect; - im->private.proto.shutdown = _XimXShutdown; - im->private.proto.write = _XimXWrite; - im->private.proto.read = _XimXRead; - im->private.proto.flush = _XimXFlush; - im->private.proto.register_dispatcher = _XimXRegisterDispatcher; - im->private.proto.call_dispatcher = _XimXCallDispatcher; - - return True; -} +/* + * Copyright 1992 Oracle and/or its affiliates. All rights reserved. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ +/****************************************************************** + + Copyright 1992, 1993, 1994 by FUJITSU LIMITED + +Permission to use, copy, modify, distribute, and sell this software +and its documentation for any purpose is hereby granted without fee, +provided that the above copyright notice appear in all copies and +that both that copyright notice and this permission notice appear +in supporting documentation, and that the name of FUJITSU LIMITED +not be used in advertising or publicity pertaining to distribution +of the software without specific, written prior permission. +FUJITSU LIMITED makes no representations about the suitability of +this software for any purpose. +It is provided "as is" without express or implied warranty. + +FUJITSU LIMITED DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, +INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO +EVENT SHALL FUJITSU LIMITED BE LIABLE FOR ANY SPECIAL, INDIRECT OR +CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF +USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + + Author: Hideki Hiura (hhiura@Sun.COM) Sun Microsystems, Inc. + Takashi Fujiwara FUJITSU LIMITED + fujiwara@a80.tech.yk.fujitsu.co.jp + +******************************************************************/ + +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include +#include "Xlibint.h" +#include "Xlcint.h" +#include "Ximint.h" +#include "XimTrInt.h" +#include "XimTrX.h" + +Private Bool +_XimXRegisterDispatcher( + Xim im, + Bool (*callback)( + Xim, INT16, XPointer, XPointer + ), + XPointer call_data) +{ + XIntrCallbackPtr rec; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + + if (!(rec = (XIntrCallbackPtr)Xmalloc(sizeof(XIntrCallbackRec)))) + return False; + + rec->func = callback; + rec->call_data = call_data; + rec->next = spec->intr_cb; + spec->intr_cb = rec; + return True; +} + +Private void +_XimXFreeIntrCallback( + Xim im) +{ + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + register XIntrCallbackPtr rec, next; + + for (rec = spec->intr_cb; rec;) { + next = rec->next; + Xfree(rec); + rec = next; + } + return; +} + +Private Bool +_XimXCallDispatcher(Xim im, INT16 len, XPointer data) +{ + register XIntrCallbackRec *rec; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + + for (rec = spec->intr_cb; rec; rec = rec->next) { + if ((*rec->func)(im, len, data, rec->call_data)) + return True; + } + return False; +} + +Private Bool +_XimXFilterWaitEvent( + Display *d, + Window w, + XEvent *ev, + XPointer arg) +{ + Xim im = (Xim)arg; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + Bool ret; + + spec->ev = (XPointer)ev; + ret = _XimFilterWaitEvent(im); + + /* + * If ev is a pointer to a stack variable, there could be + * a coredump later on if the pointer is dereferenced. + * Therefore, reset to NULL to force reinitialization in + * _XimXRead(). + * + * Keep in mind _XimXRead may be called again when the stack + * is very different. + */ + spec->ev = (XPointer)NULL; + + return ret; +} + +Private Bool +_CheckConnect( + Display *display, + XEvent *event, + XPointer xim) +{ + Xim im = (Xim)xim; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + + if ((event->type == ClientMessage) + && (event->xclient.message_type == spec->imconnectid)) { + return True; + } + return False; +} + +Private Bool +_XimXConnect(Xim im) +{ + XEvent event; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + CARD32 major_code; + CARD32 minor_code; + + if (!(spec->lib_connect_wid = XCreateSimpleWindow(im->core.display, + DefaultRootWindow(im->core.display), 0, 0, 1, 1, 1, 0, 0))) { + return False; + } + + event.xclient.type = ClientMessage; + event.xclient.display = im->core.display; + event.xclient.window = im->private.proto.im_window; + event.xclient.message_type = spec->imconnectid; + event.xclient.format = 32; + event.xclient.data.l[0] = (CARD32)spec->lib_connect_wid; + event.xclient.data.l[1] = spec->major_code; + event.xclient.data.l[2] = spec->minor_code; + event.xclient.data.l[3] = 0; + event.xclient.data.l[4] = 0; + + if(event.xclient.data.l[1] == 1 || event.xclient.data.l[1] == 2) { + XWindowAttributes atr; + long event_mask; + + XGetWindowAttributes(im->core.display, spec->lib_connect_wid, &atr); + event_mask = atr.your_event_mask | PropertyChangeMask; + XSelectInput(im->core.display, spec->lib_connect_wid, event_mask); + _XRegisterFilterByType(im->core.display, spec->lib_connect_wid, + PropertyNotify, PropertyNotify, + _XimXFilterWaitEvent, (XPointer)im); + } + + XSendEvent(im->core.display, im->private.proto.im_window, + False, NoEventMask, &event); + XFlush(im->core.display); + + for (;;) { + XIfEvent(im->core.display, &event, _CheckConnect, (XPointer)im); + if (event.xclient.type != ClientMessage) { + return False; + } + if (event.xclient.message_type == spec->imconnectid) + break; + } + + spec->ims_connect_wid = (Window)event.xclient.data.l[0]; + major_code = (CARD32)event.xclient.data.l[1]; + minor_code = (CARD32)event.xclient.data.l[2]; + + if (((major_code == 0) && (minor_code <= 2)) || + ((major_code == 1) && (minor_code == 0)) || + ((major_code == 2) && (minor_code <= 1))) { + spec->major_code = major_code; + spec->minor_code = minor_code; + } + if (((major_code == 0) && (minor_code == 2)) || + ((major_code == 2) && (minor_code == 1))) { + spec->BoundarySize = (CARD32)event.xclient.data.l[3]; + } + + /* ClientMessage Event Filter */ + _XRegisterFilterByType(im->core.display, spec->lib_connect_wid, + ClientMessage, ClientMessage, + _XimXFilterWaitEvent, (XPointer)im); + return True; +} + +Private Bool +_XimXShutdown(Xim im) +{ + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + + if (!spec) + return True; + + /* ClientMessage Event Filter */ + _XUnregisterFilter(im->core.display, + ((XSpecRec *)im->private.proto.spec)->lib_connect_wid, + _XimXFilterWaitEvent, (XPointer)im); + XDestroyWindow(im->core.display, + ((XSpecRec *)im->private.proto.spec)->lib_connect_wid); + _XimXFreeIntrCallback(im); + Xfree(spec); + im->private.proto.spec = 0; + return True; +} + +Private char * +_NewAtom( + char *atomName) +{ + static int sequence = 0; + + (void)sprintf(atomName, "_client%d", sequence); + sequence = ((sequence < 20) ? sequence + 1 : 0); + return atomName; +} + +Private Bool +_XimXWrite(Xim im, INT16 len, XPointer data) +{ + Atom atom; + char atomName[16]; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + XEvent event; + CARD8 *p; + CARD32 major_code = spec->major_code; + CARD32 minor_code = spec->minor_code; + int BoundSize; + + bzero(&event,sizeof(XEvent)); + event.xclient.type = ClientMessage; + event.xclient.display = im->core.display; + event.xclient.window = spec->ims_connect_wid; + if(major_code == 1 && minor_code == 0) { + BoundSize = 0; + } else if((major_code == 0 && minor_code == 2) || + (major_code == 2 && minor_code == 1)) { + BoundSize = spec->BoundarySize; + } else if(major_code == 0 && minor_code == 1) { + BoundSize = len; + } else { + BoundSize = XIM_CM_DATA_SIZE; + } + if (len > BoundSize) { + event.xclient.message_type = spec->improtocolid; + atom = XInternAtom(im->core.display, _NewAtom(atomName), False); + XChangeProperty(im->core.display, spec->ims_connect_wid, + atom, XA_STRING, 8, PropModeAppend, + (unsigned char *)data, len); + if(major_code == 0) { + event.xclient.format = 32; + event.xclient.data.l[0] = (long)len; + event.xclient.data.l[1] = (long)atom; + XSendEvent(im->core.display, spec->ims_connect_wid, + False, NoEventMask, &event); + } + } else { + int length; + + event.xclient.format = 8; + for(length = 0 ; length < len ; length += XIM_CM_DATA_SIZE) { + p = (CARD8 *)&event.xclient.data.b[0]; + if((length + XIM_CM_DATA_SIZE) >= len) { + event.xclient.message_type = spec->improtocolid; + bzero(p, XIM_CM_DATA_SIZE); + memcpy((char *)p, (data + length), (len - length)); + } else { + event.xclient.message_type = spec->immoredataid; + memcpy((char *)p, (data + length), XIM_CM_DATA_SIZE); + } + XSendEvent(im->core.display, spec->ims_connect_wid, + False, NoEventMask, &event); + } + } + + return True; +} + +Private Bool +_XimXGetReadData( + Xim im, + char *buf, + int buf_len, + int *ret_len, + XEvent *event) +{ + char *data; + int len; + + char tmp_buf[XIM_CM_DATA_SIZE]; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + unsigned long length; + Atom prop; + int return_code; + Atom type_ret; + int format_ret; + unsigned long nitems; + unsigned long bytes_after_ret; + unsigned char *prop_ret; + + if ((event->type == ClientMessage) && + !((event->xclient.message_type == spec->improtocolid) || + (event->xclient.message_type == spec->immoredataid))) { + /* This event has nothing to do with us, + * FIXME should not have gotten here then... + */ + return False; + } else if ((event->type == ClientMessage) && (event->xclient.format == 8)) { + data = event->xclient.data.b; + if (buf_len >= XIM_CM_DATA_SIZE) { + (void)memcpy(buf, data, XIM_CM_DATA_SIZE); + *ret_len = XIM_CM_DATA_SIZE; + } else { + (void)memcpy(buf, data, buf_len); + len = XIM_CM_DATA_SIZE - buf_len; + (void)memcpy(tmp_buf, &data[buf_len], len); + bzero(data, XIM_CM_DATA_SIZE); + (void)memcpy(data, tmp_buf, len); + XPutBackEvent(im->core.display, event); + *ret_len = buf_len; + } + } else if ((event->type == ClientMessage) + && (event->xclient.format == 32)) { + length = (unsigned long)event->xclient.data.l[0]; + prop = (Atom)event->xclient.data.l[1]; + return_code = XGetWindowProperty(im->core.display, + spec->lib_connect_wid, prop, 0L, + (long)((length + 3)/ 4), True, AnyPropertyType, + &type_ret, &format_ret, &nitems, &bytes_after_ret, &prop_ret); + if (return_code != Success || format_ret == 0 || nitems == 0) { + if (return_code == Success) + XFree(prop_ret); + return False; + } + if (buf_len >= length) { + (void)memcpy(buf, prop_ret, (int)nitems); + *ret_len = (int)nitems; + if (bytes_after_ret > 0) { + XFree(prop_ret); + if (XGetWindowProperty(im->core.display, + spec->lib_connect_wid, prop, 0L, + ((length + bytes_after_ret + 3)/ 4), + True, AnyPropertyType, + &type_ret, &format_ret, &nitems, + &bytes_after_ret, + &prop_ret) == Success) { + XChangeProperty(im->core.display, spec->lib_connect_wid, prop, + XA_STRING, 8, PropModePrepend, &prop_ret[length], + (nitems - length)); + } else { + return False; + } + } + } else { + (void)memcpy(buf, prop_ret, buf_len); + *ret_len = buf_len; + len = nitems - buf_len; + + if (bytes_after_ret > 0) { + XFree(prop_ret); + if (XGetWindowProperty(im->core.display, + spec->lib_connect_wid, prop, 0L, + ((length + bytes_after_ret + 3)/ 4), + True, AnyPropertyType, + &type_ret, &format_ret, &nitems, + &bytes_after_ret, &prop_ret) != Success) { + return False; + } + } + XChangeProperty(im->core.display, spec->lib_connect_wid, prop, + XA_STRING, 8, PropModePrepend, &prop_ret[buf_len], len); + event->xclient.data.l[0] = (long)len; + event->xclient.data.l[1] = (long)prop; + XPutBackEvent(im->core.display, event); + } + XFree(prop_ret); + } else if (event->type == PropertyNotify) { + prop = event->xproperty.atom; + return_code = XGetWindowProperty(im->core.display, + spec->lib_connect_wid, prop, 0L, + 1000000L, True, AnyPropertyType, + &type_ret, &format_ret, &nitems, &bytes_after_ret, &prop_ret); + if (return_code != Success || format_ret == 0 || nitems == 0) { + if (return_code == Success) + XFree(prop_ret); + return False; + } + if (buf_len >= nitems) { + (void)memcpy(buf, prop_ret, (int)nitems); + *ret_len = (int)nitems; + } else { + (void)memcpy(buf, prop_ret, buf_len); + *ret_len = buf_len; + len = nitems - buf_len; + XChangeProperty(im->core.display, spec->lib_connect_wid, prop, + XA_STRING, 8, PropModePrepend, &prop_ret[buf_len], len); + } + XFree(prop_ret); + } + return True; +} + +Private Bool +_CheckCMEvent( + Display *display, + XEvent *event, + XPointer xim) +{ + Xim im = (Xim)xim; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + CARD32 major_code = spec->major_code; + + if ((event->type == ClientMessage) + &&((event->xclient.message_type == spec->improtocolid) || + (event->xclient.message_type == spec->immoredataid))) + return True; + if((major_code == 1 || major_code == 2) && + (event->type == PropertyNotify) && + (event->xproperty.state == PropertyNewValue)) + return True; + return False; +} + +Private Bool +_XimXRead(Xim im, XPointer recv_buf, int buf_len, int *ret_len) +{ + XEvent *ev; + XEvent event; + int len = 0; + XSpecRec *spec = (XSpecRec *)im->private.proto.spec; + XPointer arg = spec->ev; + + if (!arg) { + bzero(&event, sizeof(XEvent)); + ev = &event; + XIfEvent(im->core.display, ev, _CheckCMEvent, (XPointer)im); + } else { + ev = (XEvent *)arg; + spec->ev = (XPointer)NULL; + } + if (!(_XimXGetReadData(im, recv_buf, buf_len, &len, ev))) + return False; + *ret_len = len; + return True; +} + +Private void +_XimXFlush(Xim im) +{ + XFlush(im->core.display); + return; +} + +Public Bool +_XimXConf(Xim im, char *address) +{ + XSpecRec *spec; + + if (!(spec = (XSpecRec *)Xmalloc(sizeof(XSpecRec)))) + return False; + bzero(spec, sizeof(XSpecRec)); + + spec->improtocolid = XInternAtom(im->core.display, _XIM_PROTOCOL, False); + spec->imconnectid = XInternAtom(im->core.display, _XIM_XCONNECT, False); + spec->immoredataid = XInternAtom(im->core.display, _XIM_MOREDATA, False); + spec->major_code = MAJOR_TRANSPORT_VERSION; + spec->minor_code = MINOR_TRANSPORT_VERSION; + + im->private.proto.spec = (XPointer)spec; + im->private.proto.connect = _XimXConnect; + im->private.proto.shutdown = _XimXShutdown; + im->private.proto.write = _XimXWrite; + im->private.proto.read = _XimXRead; + im->private.proto.flush = _XimXFlush; + im->private.proto.register_dispatcher = _XimXRegisterDispatcher; + im->private.proto.call_dispatcher = _XimXCallDispatcher; + + return True; +} diff --git a/libX11/modules/lc/def/lcDefConv.c b/libX11/modules/lc/def/lcDefConv.c index 5860a79a5..12a48615e 100644 --- a/libX11/modules/lc/def/lcDefConv.c +++ b/libX11/modules/lc/def/lcDefConv.c @@ -577,7 +577,7 @@ create_conv( XlcConv conv; State state; - conv = (XlcConv) Xmalloc(sizeof(XlcConvRec)); + conv = (XlcConv) Xcalloc(1, sizeof(XlcConvRec)); if (conv == NULL) return (XlcConv) NULL; diff --git a/libX11/modules/lc/gen/lcGenConv.c b/libX11/modules/lc/gen/lcGenConv.c index 074a8d726..baac73a39 100644 --- a/libX11/modules/lc/gen/lcGenConv.c +++ b/libX11/modules/lc/gen/lcGenConv.c @@ -2650,7 +2650,7 @@ create_conv( XlcConv conv; State state; - conv = (XlcConv) Xmalloc(sizeof(XlcConvRec)); + conv = (XlcConv) Xcalloc(1, sizeof(XlcConvRec)); if (conv == NULL) return (XlcConv) NULL; diff --git a/libX11/src/GetProp.c b/libX11/src/GetProp.c index fc4643b95..5d6e0b8c4 100644 --- a/libX11/src/GetProp.c +++ b/libX11/src/GetProp.c @@ -1,133 +1,133 @@ -/* - -Copyright 1986, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - -*/ - -#ifdef HAVE_CONFIG_H -#include -#endif -#include "Xlibint.h" - -int -XGetWindowProperty( - register Display *dpy, - Window w, - Atom property, - long offset, - long length, - Bool delete, - Atom req_type, - Atom *actual_type, /* RETURN */ - int *actual_format, /* RETURN 8, 16, or 32 */ - unsigned long *nitems, /* RETURN # of 8-, 16-, or 32-bit entities */ - unsigned long *bytesafter, /* RETURN */ - unsigned char **prop) /* RETURN */ -{ - xGetPropertyReply reply; - register xGetPropertyReq *req; - xError error; - - LockDisplay(dpy); - GetReq (GetProperty, req); - req->window = w; - req->property = property; - req->type = req_type; - req->delete = delete; - req->longOffset = offset; - req->longLength = length; - error.sequenceNumber = dpy->request; - - if (!_XReply (dpy, (xReply *) &reply, 0, xFalse)) { - UnlockDisplay(dpy); - SyncHandle(); - return (1); /* not Success */ - } - - *prop = (unsigned char *) NULL; - if (reply.propertyType != None) { - long nbytes, netbytes; - switch (reply.format) { - /* - * One extra byte is malloced than is needed to contain the property - * data, but this last byte is null terminated and convenient for - * returning string properties, so the client doesn't then have to - * recopy the string to make it null terminated. - */ - case 8: - nbytes = netbytes = reply.nItems; - if (nbytes + 1 > 0 && - (*prop = (unsigned char *) Xmalloc ((unsigned)nbytes + 1))) - _XReadPad (dpy, (char *) *prop, netbytes); - break; - - case 16: - nbytes = reply.nItems * sizeof (short); - netbytes = reply.nItems << 1; - if (nbytes + 1 > 0 && - (*prop = (unsigned char *) Xmalloc ((unsigned)nbytes + 1))) - _XRead16Pad (dpy, (short *) *prop, netbytes); - break; - - case 32: - nbytes = reply.nItems * sizeof (long); - netbytes = reply.nItems << 2; - if (nbytes + 1 > 0 && - (*prop = (unsigned char *) Xmalloc ((unsigned)nbytes + 1))) - _XRead32 (dpy, (long *) *prop, netbytes); - break; - - default: - /* - * This part of the code should never be reached. If it is, - * the server sent back a property with an invalid format. - * This is a BadImplementation error. - */ - { - /* sequence number stored above */ - error.type = X_Error; - error.majorCode = X_GetProperty; - error.minorCode = 0; - error.errorCode = BadImplementation; - _XError(dpy, &error); - } - nbytes = netbytes = 0L; - break; - } - if (! *prop) { - _XEatData(dpy, (unsigned long) netbytes); - UnlockDisplay(dpy); - SyncHandle(); - return(BadAlloc); /* not Success */ - } - (*prop)[nbytes] = '\0'; - } - *actual_type = reply.propertyType; - *actual_format = reply.format; - *nitems = reply.nItems; - *bytesafter = reply.bytesAfter; - UnlockDisplay(dpy); - SyncHandle(); - return(Success); -} - +/* + +Copyright 1986, 1998 The Open Group + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation. + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + +*/ + +#ifdef HAVE_CONFIG_H +#include +#endif +#include "Xlibint.h" + +int +XGetWindowProperty( + register Display *dpy, + Window w, + Atom property, + long offset, + long length, + Bool delete, + Atom req_type, + Atom *actual_type, /* RETURN */ + int *actual_format, /* RETURN 8, 16, or 32 */ + unsigned long *nitems, /* RETURN # of 8-, 16-, or 32-bit entities */ + unsigned long *bytesafter, /* RETURN */ + unsigned char **prop) /* RETURN */ +{ + xGetPropertyReply reply; + register xGetPropertyReq *req; + xError error = {0}; + + LockDisplay(dpy); + GetReq (GetProperty, req); + req->window = w; + req->property = property; + req->type = req_type; + req->delete = delete; + req->longOffset = offset; + req->longLength = length; + error.sequenceNumber = dpy->request; + + if (!_XReply (dpy, (xReply *) &reply, 0, xFalse)) { + UnlockDisplay(dpy); + SyncHandle(); + return (1); /* not Success */ + } + + *prop = (unsigned char *) NULL; + if (reply.propertyType != None) { + long nbytes, netbytes; + switch (reply.format) { + /* + * One extra byte is malloced than is needed to contain the property + * data, but this last byte is null terminated and convenient for + * returning string properties, so the client doesn't then have to + * recopy the string to make it null terminated. + */ + case 8: + nbytes = netbytes = reply.nItems; + if (nbytes + 1 > 0 && + (*prop = (unsigned char *) Xmalloc ((unsigned)nbytes + 1))) + _XReadPad (dpy, (char *) *prop, netbytes); + break; + + case 16: + nbytes = reply.nItems * sizeof (short); + netbytes = reply.nItems << 1; + if (nbytes + 1 > 0 && + (*prop = (unsigned char *) Xmalloc ((unsigned)nbytes + 1))) + _XRead16Pad (dpy, (short *) *prop, netbytes); + break; + + case 32: + nbytes = reply.nItems * sizeof (long); + netbytes = reply.nItems << 2; + if (nbytes + 1 > 0 && + (*prop = (unsigned char *) Xmalloc ((unsigned)nbytes + 1))) + _XRead32 (dpy, (long *) *prop, netbytes); + break; + + default: + /* + * This part of the code should never be reached. If it is, + * the server sent back a property with an invalid format. + * This is a BadImplementation error. + */ + { + /* sequence number stored above */ + error.type = X_Error; + error.majorCode = X_GetProperty; + error.minorCode = 0; + error.errorCode = BadImplementation; + _XError(dpy, &error); + } + nbytes = netbytes = 0L; + break; + } + if (! *prop) { + _XEatData(dpy, (unsigned long) netbytes); + UnlockDisplay(dpy); + SyncHandle(); + return(BadAlloc); /* not Success */ + } + (*prop)[nbytes] = '\0'; + } + *actual_type = reply.propertyType; + *actual_format = reply.format; + *nitems = reply.nItems; + *bytesafter = reply.bytesAfter; + UnlockDisplay(dpy); + SyncHandle(); + return(Success); +} + diff --git a/libX11/src/ImUtil.c b/libX11/src/ImUtil.c index cd418d885..3164d43b7 100644 --- a/libX11/src/ImUtil.c +++ b/libX11/src/ImUtil.c @@ -372,6 +372,7 @@ XImage *XCreateImage ( if (image_bytes_per_line == 0) { image->bytes_per_line = min_bytes_per_line; } else if (image_bytes_per_line < min_bytes_per_line) { + Xfree(image); return NULL; } else { image->bytes_per_line = image_bytes_per_line; diff --git a/libX11/src/XlibInt.c b/libX11/src/XlibInt.c index c385f4cbf..a78da9bf1 100644 --- a/libX11/src/XlibInt.c +++ b/libX11/src/XlibInt.c @@ -662,6 +662,7 @@ XAddConnectionWatch( UnlockDisplay(dpy); return 0; } + info_list->watch_data = wd_array; wd_array[dpy->watcher_count] = NULL; /* for cleanliness */ } @@ -1438,9 +1439,10 @@ static int _XPrintDefaultError( ext && (ext->codes.major_opcode != event->request_code); ext = ext->next) ; - if (ext) - strcpy(buffer, ext->name); - else + if (ext) { + strncpy(buffer, ext->name, BUFSIZ); + buffer[BUFSIZ - 1] = '\0'; + } else buffer[0] = '\0'; } (void) fprintf(fp, " (%s)\n", buffer); diff --git a/libX11/src/Xrm.c b/libX11/src/Xrm.c index 21f0af3c0..fbc8ad293 100644 --- a/libX11/src/Xrm.c +++ b/libX11/src/Xrm.c @@ -842,8 +842,10 @@ static void PutEntry( nprev = NodeBuckets(table); \ } else { \ table->leaf = 1; \ - if (!(nprev = (NTable *)Xmalloc(sizeof(VEntry *)))) \ + if (!(nprev = (NTable *)Xmalloc(sizeof(VEntry *)))) {\ + Xfree(table); \ return; \ + } \ ((LTable)table)->buckets = (VEntry *)nprev; \ } \ *nprev = (NTable)NULL; \ @@ -1594,6 +1596,12 @@ ReadInFile(_Xconst char *filename) */ GetSizeOfFile(fd, size); + /* There might have been a problem trying to stat a file */ + if (size == -1) { + close (fd); + return (char *)NULL; + } + if (!(filebuf = Xmalloc(size + 1))) { /* leave room for '\0' */ close(fd); return (char *)NULL; diff --git a/libX11/src/xcms/LRGB.c b/libX11/src/xcms/LRGB.c index 7e09db00a..750c4924e 100644 --- a/libX11/src/xcms/LRGB.c +++ b/libX11/src/xcms/LRGB.c @@ -1,1847 +1,1845 @@ - -/* - * Code and supporting documentation (c) Copyright 1990 1991 Tektronix, Inc. - * All Rights Reserved - * - * This file is a component of an X Window System-specific implementation - * of Xcms based on the TekColor Color Management System. Permission is - * hereby granted to use, copy, modify, sell, and otherwise distribute this - * software and its documentation for any purpose and without fee, provided - * that this copyright, permission, and disclaimer notice is reproduced in - * all copies of this software and in supporting documentation. TekColor - * is a trademark of Tektronix, Inc. - * - * Tektronix makes no representation about the suitability of this software - * for any purpose. It is provided "as is" and with all faults. - * - * TEKTRONIX DISCLAIMS ALL WARRANTIES APPLICABLE TO THIS SOFTWARE, - * INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A - * PARTICULAR PURPOSE. IN NO EVENT SHALL TEKTRONIX BE LIABLE FOR ANY - * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER - * RESULTING FROM LOSS OF USE, DATA, OR PROFITS, WHETHER IN AN ACTION OF - * CONTRACT, NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN - * CONNECTION WITH THE USE OR THE PERFORMANCE OF THIS SOFTWARE. - * - * - * NAME - * XcmsLRGB.c - * - * DESCRIPTION - * This file contains the conversion routines: - * 1. CIE XYZ to RGB intensity - * 2. RGB intensity to device RGB - * 3. device RGB to RGB intensity - * 4. RGB intensity to CIE XYZ - * - */ - -#ifdef HAVE_CONFIG_H -#include -#endif -#include -#include -#include -#include "Xlibint.h" -#include "Xcmsint.h" -#include "Cv.h" - -/* - * LOCAL DEFINES - * #define declarations local to this package. - */ -#define EPS 0.001 -#ifndef MIN -#define MIN(x,y) ((x) > (y) ? (y) : (x)) -#endif /* MIN */ -#ifndef MAX -#define MAX(x,y) ((x) > (y) ? (x) : (y)) -#endif /* MAX */ -#ifndef MIN3 -#define MIN3(x,y,z) ((x) > (MIN((y), (z))) ? (MIN((y), (z))) : (x)) -#endif /* MIN3 */ -#ifndef MAX3 -#define MAX3(x,y,z) ((x) > (MAX((y), (z))) ? (x) : (MAX((y), (z)))) -#endif /* MAX3 */ - -/* - * LOCAL TYPEDEFS - * typedefs local to this package (for use with local vars). - * - */ - -/* - * FORWARD DECLARATIONS - */ -static void LINEAR_RGB_FreeSCCData(XPointer pScreenDataTemp); -static int LINEAR_RGB_InitSCCData(Display *dpy, - int screenNumber, XcmsPerScrnInfo *pPerScrnInfo); -static int XcmsLRGB_RGB_ParseString(register char *spec, XcmsColor *pColor); -static int XcmsLRGB_RGBi_ParseString(register char *spec, XcmsColor *pColor); -static Status -_XcmsGetTableType0( - IntensityTbl *pTbl, - int format, - char **pChar, - unsigned long *pCount); -static Status -_XcmsGetTableType1( - IntensityTbl *pTbl, - int format, - char **pChar, - unsigned long *pCount); - -/* - * LOCALS VARIABLES - * Variables local to this package. - * Usage example: - * static int ExampleLocalVar; - */ - -static unsigned short const MASK[17] = { - 0x0000, /* 0 bitsPerRGB */ - 0x8000, /* 1 bitsPerRGB */ - 0xc000, /* 2 bitsPerRGB */ - 0xe000, /* 3 bitsPerRGB */ - 0xf000, /* 4 bitsPerRGB */ - 0xf800, /* 5 bitsPerRGB */ - 0xfc00, /* 6 bitsPerRGB */ - 0xfe00, /* 7 bitsPerRGB */ - 0xff00, /* 8 bitsPerRGB */ - 0xff80, /* 9 bitsPerRGB */ - 0xffc0, /* 10 bitsPerRGB */ - 0xffe0, /* 11 bitsPerRGB */ - 0xfff0, /* 12 bitsPerRGB */ - 0xfff8, /* 13 bitsPerRGB */ - 0xfffc, /* 14 bitsPerRGB */ - 0xfffe, /* 15 bitsPerRGB */ - 0xffff /* 16 bitsPerRGB */ -}; - - - /* - * A NULL terminated array of function pointers that when applied - * in series will convert an XcmsColor structure from XcmsRGBFormat - * to XcmsCIEXYZFormat. - */ -static XcmsConversionProc Fl_RGB_to_CIEXYZ[] = { - (XcmsConversionProc)XcmsRGBToRGBi, - (XcmsConversionProc)XcmsRGBiToCIEXYZ, - NULL -}; - - /* - * A NULL terminated array of function pointers that when applied - * in series will convert an XcmsColor structure from XcmsCIEXYZFormat - * to XcmsRGBFormat. - */ -static XcmsConversionProc Fl_CIEXYZ_to_RGB[] = { - (XcmsConversionProc)XcmsCIEXYZToRGBi, - (XcmsConversionProc)XcmsRGBiToRGB, - NULL -}; - - /* - * A NULL terminated array of function pointers that when applied - * in series will convert an XcmsColor structure from XcmsRGBiFormat - * to XcmsCIEXYZFormat. - */ -static XcmsConversionProc Fl_RGBi_to_CIEXYZ[] = { - (XcmsConversionProc)XcmsRGBiToCIEXYZ, - NULL -}; - - /* - * A NULL terminated array of function pointers that when applied - * in series will convert an XcmsColor structure from XcmsCIEXYZFormat - * to XcmsRGBiFormat. - */ -static XcmsConversionProc Fl_CIEXYZ_to_RGBi[] = { - (XcmsConversionProc)XcmsCIEXYZToRGBi, - NULL -}; - - /* - * RGBi Color Spaces - */ -XcmsColorSpace XcmsRGBiColorSpace = - { - _XcmsRGBi_prefix, /* prefix */ - XcmsRGBiFormat, /* id */ - XcmsLRGB_RGBi_ParseString, /* parseString */ - Fl_RGBi_to_CIEXYZ, /* to_CIEXYZ */ - Fl_CIEXYZ_to_RGBi, /* from_CIEXYZ */ - 1 - }; - - /* - * RGB Color Spaces - */ -XcmsColorSpace XcmsRGBColorSpace = - { - _XcmsRGB_prefix, /* prefix */ - XcmsRGBFormat, /* id */ - XcmsLRGB_RGB_ParseString, /* parseString */ - Fl_RGB_to_CIEXYZ, /* to_CIEXYZ */ - Fl_CIEXYZ_to_RGB, /* from_CIEXYZ */ - 1 - }; - - /* - * Device-Independent Color Spaces known to the - * LINEAR_RGB Screen Color Characteristics Function Set. - */ -static XcmsColorSpace *DDColorSpaces[] = { - &XcmsRGBColorSpace, - &XcmsRGBiColorSpace, - NULL -}; - - -/* - * GLOBALS - * Variables declared in this package that are allowed - * to be used globally. - */ - - /* - * LINEAR_RGB Screen Color Characteristics Function Set. - */ -XcmsFunctionSet XcmsLinearRGBFunctionSet = - { - &DDColorSpaces[0], /* pDDColorSpaces */ - LINEAR_RGB_InitSCCData, /* pInitScrnFunc */ - LINEAR_RGB_FreeSCCData /* pFreeSCCData */ - }; - -/* - * DESCRIPTION - * Contents of Default SCCData should be replaced if other - * data should be used as default. - * - * - */ - -/* - * NAME Tektronix 19" (Sony) CRT - * PART_NUMBER 119-2451-00 - * MODEL Tek4300, Tek4800 - */ - -static IntensityRec const Default_RGB_RedTuples[] = { - /* {unsigned short value, XcmsFloat intensity} */ - { 0x0000, 0.000000 }, - { 0x0909, 0.000000 }, - { 0x0a0a, 0.000936 }, - { 0x0f0f, 0.001481 }, - { 0x1414, 0.002329 }, - { 0x1919, 0.003529 }, - { 0x1e1e, 0.005127 }, - { 0x2323, 0.007169 }, - { 0x2828, 0.009699 }, - { 0x2d2d, 0.012759 }, - { 0x3232, 0.016392 }, - { 0x3737, 0.020637 }, - { 0x3c3c, 0.025533 }, - { 0x4141, 0.031119 }, - { 0x4646, 0.037431 }, - { 0x4b4b, 0.044504 }, - { 0x5050, 0.052373 }, - { 0x5555, 0.061069 }, - { 0x5a5a, 0.070624 }, - { 0x5f5f, 0.081070 }, - { 0x6464, 0.092433 }, - { 0x6969, 0.104744 }, - { 0x6e6e, 0.118026 }, - { 0x7373, 0.132307 }, - { 0x7878, 0.147610 }, - { 0x7d7d, 0.163958 }, - { 0x8282, 0.181371 }, - { 0x8787, 0.199871 }, - { 0x8c8c, 0.219475 }, - { 0x9191, 0.240202 }, - { 0x9696, 0.262069 }, - { 0x9b9b, 0.285089 }, - { 0xa0a0, 0.309278 }, - { 0xa5a5, 0.334647 }, - { 0xaaaa, 0.361208 }, - { 0xafaf, 0.388971 }, - { 0xb4b4, 0.417945 }, - { 0xb9b9, 0.448138 }, - { 0xbebe, 0.479555 }, - { 0xc3c3, 0.512202 }, - { 0xc8c8, 0.546082 }, - { 0xcdcd, 0.581199 }, - { 0xd2d2, 0.617552 }, - { 0xd7d7, 0.655144 }, - { 0xdcdc, 0.693971 }, - { 0xe1e1, 0.734031 }, - { 0xe6e6, 0.775322 }, - { 0xebeb, 0.817837 }, - { 0xf0f0, 0.861571 }, - { 0xf5f5, 0.906515 }, - { 0xfafa, 0.952662 }, - { 0xffff, 1.000000 } -}; - -static IntensityRec const Default_RGB_GreenTuples[] = { - /* {unsigned short value, XcmsFloat intensity} */ - { 0x0000, 0.000000 }, - { 0x1313, 0.000000 }, - { 0x1414, 0.000832 }, - { 0x1919, 0.001998 }, - { 0x1e1e, 0.003612 }, - { 0x2323, 0.005736 }, - { 0x2828, 0.008428 }, - { 0x2d2d, 0.011745 }, - { 0x3232, 0.015740 }, - { 0x3737, 0.020463 }, - { 0x3c3c, 0.025960 }, - { 0x4141, 0.032275 }, - { 0x4646, 0.039449 }, - { 0x4b4b, 0.047519 }, - { 0x5050, 0.056520 }, - { 0x5555, 0.066484 }, - { 0x5a5a, 0.077439 }, - { 0x5f5f, 0.089409 }, - { 0x6464, 0.102418 }, - { 0x6969, 0.116485 }, - { 0x6e6e, 0.131625 }, - { 0x7373, 0.147853 }, - { 0x7878, 0.165176 }, - { 0x7d7d, 0.183604 }, - { 0x8282, 0.203140 }, - { 0x8787, 0.223783 }, - { 0x8c8c, 0.245533 }, - { 0x9191, 0.268384 }, - { 0x9696, 0.292327 }, - { 0x9b9b, 0.317351 }, - { 0xa0a0, 0.343441 }, - { 0xa5a5, 0.370580 }, - { 0xaaaa, 0.398747 }, - { 0xafaf, 0.427919 }, - { 0xb4b4, 0.458068 }, - { 0xb9b9, 0.489165 }, - { 0xbebe, 0.521176 }, - { 0xc3c3, 0.554067 }, - { 0xc8c8, 0.587797 }, - { 0xcdcd, 0.622324 }, - { 0xd2d2, 0.657604 }, - { 0xd7d7, 0.693588 }, - { 0xdcdc, 0.730225 }, - { 0xe1e1, 0.767459 }, - { 0xe6e6, 0.805235 }, - { 0xebeb, 0.843491 }, - { 0xf0f0, 0.882164 }, - { 0xf5f5, 0.921187 }, - { 0xfafa, 0.960490 }, - { 0xffff, 1.000000 } -}; - -static IntensityRec const Default_RGB_BlueTuples[] = { - /* {unsigned short value, XcmsFloat intensity} */ - { 0x0000, 0.000000 }, - { 0x0e0e, 0.000000 }, - { 0x0f0f, 0.001341 }, - { 0x1414, 0.002080 }, - { 0x1919, 0.003188 }, - { 0x1e1e, 0.004729 }, - { 0x2323, 0.006766 }, - { 0x2828, 0.009357 }, - { 0x2d2d, 0.012559 }, - { 0x3232, 0.016424 }, - { 0x3737, 0.021004 }, - { 0x3c3c, 0.026344 }, - { 0x4141, 0.032489 }, - { 0x4646, 0.039481 }, - { 0x4b4b, 0.047357 }, - { 0x5050, 0.056154 }, - { 0x5555, 0.065903 }, - { 0x5a5a, 0.076634 }, - { 0x5f5f, 0.088373 }, - { 0x6464, 0.101145 }, - { 0x6969, 0.114968 }, - { 0x6e6e, 0.129862 }, - { 0x7373, 0.145841 }, - { 0x7878, 0.162915 }, - { 0x7d7d, 0.181095 }, - { 0x8282, 0.200386 }, - { 0x8787, 0.220791 }, - { 0x8c8c, 0.242309 }, - { 0x9191, 0.264937 }, - { 0x9696, 0.288670 }, - { 0x9b9b, 0.313499 }, - { 0xa0a0, 0.339410 }, - { 0xa5a5, 0.366390 }, - { 0xaaaa, 0.394421 }, - { 0xafaf, 0.423481 }, - { 0xb4b4, 0.453547 }, - { 0xb9b9, 0.484592 }, - { 0xbebe, 0.516587 }, - { 0xc3c3, 0.549498 }, - { 0xc8c8, 0.583291 }, - { 0xcdcd, 0.617925 }, - { 0xd2d2, 0.653361 }, - { 0xd7d7, 0.689553 }, - { 0xdcdc, 0.726454 }, - { 0xe1e1, 0.764013 }, - { 0xe6e6, 0.802178 }, - { 0xebeb, 0.840891 }, - { 0xf0f0, 0.880093 }, - { 0xf5f5, 0.919723 }, - { 0xfafa, 0.959715 }, - { 0xffff, 1.00000 } -}; - -static IntensityTbl Default_RGB_RedTbl = { - /* IntensityRec *pBase */ - (IntensityRec *) Default_RGB_RedTuples, - /* unsigned int nEntries */ - 52 -}; - -static IntensityTbl Default_RGB_GreenTbl = { - /* IntensityRec *pBase */ - (IntensityRec *)Default_RGB_GreenTuples, - /* unsigned int nEntries */ - 50 -}; - -static IntensityTbl Default_RGB_BlueTbl = { - /* IntensityRec *pBase */ - (IntensityRec *)Default_RGB_BlueTuples, - /* unsigned int nEntries */ - 51 -}; - -static LINEAR_RGB_SCCData Default_RGB_SCCData = { - /* XcmsFloat XYZtoRGBmatrix[3][3] */ - { - { 3.48340481253539000, -1.52176374927285200, -0.55923133354049780 }, - {-1.07152751306193600, 1.96593795204372400, 0.03673691339553462 }, - { 0.06351179790497788, -0.20020501000496480, 0.81070942031648220 } - }, - - /* XcmsFloat RGBtoXYZmatrix[3][3] */ - { - { 0.38106149108714790, 0.32025712365352110, 0.24834578525933100 }, - { 0.20729745115140850, 0.68054638776373240, 0.11215616108485920 }, - { 0.02133944350088028, 0.14297193020246480, 1.24172892629665500 } - }, - - /* IntensityTbl *pRedTbl */ - &Default_RGB_RedTbl, - - /* IntensityTbl *pGreenTbl */ - &Default_RGB_GreenTbl, - - /* IntensityTbl *pBlueTbl */ - &Default_RGB_BlueTbl -}; - -/************************************************************************ - * * - * PRIVATE ROUTINES * - * * - ************************************************************************/ - -/* - * NAME - * LINEAR_RGB_InitSCCData() - * - * SYNOPSIS - */ -static Status -LINEAR_RGB_InitSCCData( - Display *dpy, - int screenNumber, - XcmsPerScrnInfo *pPerScrnInfo) -/* - * DESCRIPTION - * - * RETURNS - * XcmsFailure if failed. - * XcmsSuccess if succeeded. - * - */ -{ - Atom CorrectAtom = XInternAtom (dpy, XDCCC_CORRECT_ATOM_NAME, True); - Atom MatrixAtom = XInternAtom (dpy, XDCCC_MATRIX_ATOM_NAME, True); - int format_return, count, cType, nTables; - unsigned long nitems, nbytes_return; - char *property_return, *pChar; - XcmsFloat *pValue; -#ifdef ALLDEBUG - IntensityRec *pIRec; -#endif /* ALLDEBUG */ - VisualID visualID; - - LINEAR_RGB_SCCData *pScreenData, *pScreenDefaultData; - XcmsIntensityMap *pNewMap; - - /* - * Allocate memory for pScreenData - */ - if (!(pScreenData = pScreenDefaultData = (LINEAR_RGB_SCCData *) - Xcalloc (1, sizeof(LINEAR_RGB_SCCData)))) { - return(XcmsFailure); - } - - /* - * 1. Get the XYZ->RGB and RGB->XYZ matrices - */ - - if (MatrixAtom == None || - !_XcmsGetProperty (dpy, RootWindow(dpy, screenNumber), MatrixAtom, - &format_return, &nitems, &nbytes_return, &property_return) || - nitems != 18 || format_return != 32) { - /* - * As per the XDCCC, there must be 18 data items and each must be - * in 32 bits ! - */ - goto FreeSCCData; - - } else { - - /* - * RGBtoXYZ and XYZtoRGB matrices - */ - pValue = (XcmsFloat *) pScreenData; - pChar = property_return; - for (count = 0; count < 18; count++) { - *pValue++ = (long)_XcmsGetElement(format_return, &pChar, - &nitems) / (XcmsFloat)XDCCC_NUMBER; - } - Xfree ((char *)property_return); - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.X = - pScreenData->RGBtoXYZmatrix[0][0] + - pScreenData->RGBtoXYZmatrix[0][1] + - pScreenData->RGBtoXYZmatrix[0][2]; - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = - pScreenData->RGBtoXYZmatrix[1][0] + - pScreenData->RGBtoXYZmatrix[1][1] + - pScreenData->RGBtoXYZmatrix[1][2]; - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Z = - pScreenData->RGBtoXYZmatrix[2][0] + - pScreenData->RGBtoXYZmatrix[2][1] + - pScreenData->RGBtoXYZmatrix[2][2]; - - /* - * Compute the Screen White Point - */ - if ((pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y < (1.0 - EPS) ) - || (pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y > (1.0 + EPS))) { - goto FreeSCCData; - } else { - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = 1.0; - } - pPerScrnInfo->screenWhitePt.format = XcmsCIEXYZFormat; - pPerScrnInfo->screenWhitePt.pixel = 0; - -#ifdef PDEBUG - printf ("RGB to XYZ Matrix values:\n"); - printf (" %f %f %f\n %f %f %f\n %f %f %f\n", - pScreenData->RGBtoXYZmatrix[0][0], - pScreenData->RGBtoXYZmatrix[0][1], - pScreenData->RGBtoXYZmatrix[0][2], - pScreenData->RGBtoXYZmatrix[1][0], - pScreenData->RGBtoXYZmatrix[1][1], - pScreenData->RGBtoXYZmatrix[1][2], - pScreenData->RGBtoXYZmatrix[2][0], - pScreenData->RGBtoXYZmatrix[2][1], - pScreenData->RGBtoXYZmatrix[2][2]); - printf ("XYZ to RGB Matrix values:\n"); - printf (" %f %f %f\n %f %f %f\n %f %f %f\n", - pScreenData->XYZtoRGBmatrix[0][0], - pScreenData->XYZtoRGBmatrix[0][1], - pScreenData->XYZtoRGBmatrix[0][2], - pScreenData->XYZtoRGBmatrix[1][0], - pScreenData->XYZtoRGBmatrix[1][1], - pScreenData->XYZtoRGBmatrix[1][2], - pScreenData->XYZtoRGBmatrix[2][0], - pScreenData->XYZtoRGBmatrix[2][1], - pScreenData->XYZtoRGBmatrix[2][2]); - printf ("Screen White Pt value: %f %f %f\n", - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.X, - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y, - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Z); -#endif /* PDEBUG */ - } - - /* - * 2. Get the Intensity Profile - */ - if (CorrectAtom == None || - !_XcmsGetProperty (dpy, RootWindow(dpy, screenNumber), CorrectAtom, - &format_return, &nitems, &nbytes_return, &property_return)) { - Xfree ((char *)property_return); - goto FreeSCCData; - } - - pChar = property_return; - - while (nitems) { - switch (format_return) { - case 8: - /* - * Must have at least: - * VisualID0 - * VisualID1 - * VisualID2 - * VisualID3 - * type - * count - * length - * intensity1 - * intensity2 - */ - if (nitems < 9) { - Xfree ((char *)property_return); - goto FreeSCCData; - } - count = 3; - break; - case 16: - /* - * Must have at least: - * VisualID0 - * VisualID3 - * type - * count - * length - * intensity1 - * intensity2 - */ - if (nitems < 7) { - Xfree ((char *)property_return); - goto FreeSCCData; - } - count = 1; - break; - case 32: - /* - * Must have at least: - * VisualID0 - * type - * count - * length - * intensity1 - * intensity2 - */ - if (nitems < 6) { - Xfree ((char *)property_return); - goto FreeSCCData; - } - count = 0; - break; - default: - Xfree ((char *)property_return); - goto FreeSCCData; - } - - /* - * Get VisualID - */ - visualID = _XcmsGetElement(format_return, &pChar, &nitems); - while (count--) { - visualID = visualID << format_return; - visualID |= _XcmsGetElement(format_return, &pChar, &nitems); - } - - if (visualID == 0) { - /* - * This is a shared intensity table - */ - pScreenData = pScreenDefaultData; - } else { - /* - * This is a per-Visual intensity table - */ - if (!(pScreenData = (LINEAR_RGB_SCCData *) - Xcalloc (1, sizeof(LINEAR_RGB_SCCData)))) { - return(XcmsFailure); - } - /* copy matrices */ - memcpy((char *)pScreenData, (char *)pScreenDefaultData, - 18 * sizeof(XcmsFloat)); - - /* Create, initialize, and add map */ - if (!(pNewMap = (XcmsIntensityMap *) - Xcalloc (1, sizeof(XcmsIntensityMap)))) { - Xfree((char *)pScreenData); - return(XcmsFailure); - } - pNewMap->visualID = visualID; - pNewMap->screenData = (XPointer)pScreenData; - pNewMap->pFreeScreenData = LINEAR_RGB_FreeSCCData; - pNewMap->pNext = - (XcmsIntensityMap *)dpy->cms.perVisualIntensityMaps; - dpy->cms.perVisualIntensityMaps = (XPointer)pNewMap; - dpy->free_funcs->intensityMaps = _XcmsFreeIntensityMaps; - } - - cType = _XcmsGetElement(format_return, &pChar, &nitems); - nTables = _XcmsGetElement(format_return, &pChar, &nitems); - - if (cType == 0) { - - /* Red Intensity Table */ - if (!(pScreenData->pRedTbl = (IntensityTbl *) - Xcalloc (1, sizeof(IntensityTbl)))) { - goto FreeSCCData; - } - if (_XcmsGetTableType0(pScreenData->pRedTbl, format_return, &pChar, - &nitems) == XcmsFailure) { - goto FreeRedTbl; - } - - if (nTables == 1) { - /* Green Intensity Table */ - pScreenData->pGreenTbl = pScreenData->pRedTbl; - /* Blue Intensity Table */ - pScreenData->pBlueTbl = pScreenData->pRedTbl; - } else { - /* Green Intensity Table */ - if (!(pScreenData->pGreenTbl = (IntensityTbl *) - Xcalloc (1, sizeof(IntensityTbl)))) { - goto FreeRedTblElements; - } - if (_XcmsGetTableType0(pScreenData->pGreenTbl, format_return, &pChar, - &nitems) == XcmsFailure) { - goto FreeGreenTbl; - } - - /* Blue Intensity Table */ - if (!(pScreenData->pBlueTbl = (IntensityTbl *) - Xcalloc (1, sizeof(IntensityTbl)))) { - goto FreeGreenTblElements; - } - if (_XcmsGetTableType0(pScreenData->pBlueTbl, format_return, &pChar, - &nitems) == XcmsFailure) { - goto FreeBlueTbl; - } - } - } else if (cType == 1) { - /* Red Intensity Table */ - if (!(pScreenData->pRedTbl = (IntensityTbl *) - Xcalloc (1, sizeof(IntensityTbl)))) { - goto FreeSCCData; - } - if (_XcmsGetTableType1(pScreenData->pRedTbl, format_return, &pChar, - &nitems) == XcmsFailure) { - goto FreeRedTbl; - } - - if (nTables == 1) { - - /* Green Intensity Table */ - pScreenData->pGreenTbl = pScreenData->pRedTbl; - /* Blue Intensity Table */ - pScreenData->pBlueTbl = pScreenData->pRedTbl; - - } else { - - /* Green Intensity Table */ - if (!(pScreenData->pGreenTbl = (IntensityTbl *) - Xcalloc (1, sizeof(IntensityTbl)))) { - goto FreeRedTblElements; - } - if (_XcmsGetTableType1(pScreenData->pGreenTbl, format_return, &pChar, - &nitems) == XcmsFailure) { - goto FreeGreenTbl; - } - - /* Blue Intensity Table */ - if (!(pScreenData->pBlueTbl = (IntensityTbl *) - Xcalloc (1, sizeof(IntensityTbl)))) { - goto FreeGreenTblElements; - } - if (_XcmsGetTableType1(pScreenData->pBlueTbl, format_return, &pChar, - &nitems) == XcmsFailure) { - goto FreeBlueTbl; - } - } - } else { - Xfree ((char *)property_return); - goto FreeSCCData; - } - -#ifdef ALLDEBUG - printf ("Intensity Table RED %d\n", pScreenData->pRedTbl->nEntries); - pIRec = (IntensityRec *) pScreenData->pRedTbl->pBase; - for (count = 0; count < pScreenData->pRedTbl->nEntries; count++, pIRec++) { - printf ("\t0x%4x\t%f\n", pIRec->value, pIRec->intensity); - } - if (pScreenData->pGreenTbl->pBase != pScreenData->pRedTbl->pBase) { - printf ("Intensity Table GREEN %d\n", pScreenData->pGreenTbl->nEntries); - pIRec = (IntensityRec *)pScreenData->pGreenTbl->pBase; - for (count = 0; count < pScreenData->pGreenTbl->nEntries; count++, pIRec++) { - printf ("\t0x%4x\t%f\n", pIRec->value, pIRec->intensity); - } - } - if (pScreenData->pBlueTbl->pBase != pScreenData->pRedTbl->pBase) { - printf ("Intensity Table BLUE %d\n", pScreenData->pBlueTbl->nEntries); - pIRec = (IntensityRec *) pScreenData->pBlueTbl->pBase; - for (count = 0; count < pScreenData->pBlueTbl->nEntries; count++, pIRec++) { - printf ("\t0x%4x\t%f\n", pIRec->value, pIRec->intensity); - } - } -#endif /* ALLDEBUG */ - } - - Xfree ((char *)property_return); - - /* Free the old memory and use the new structure created. */ - LINEAR_RGB_FreeSCCData(pPerScrnInfo->screenData); - - pPerScrnInfo->functionSet = (XPointer) &XcmsLinearRGBFunctionSet; - - pPerScrnInfo->screenData = (XPointer) pScreenData; - - pPerScrnInfo->state = XcmsInitSuccess; - - return(XcmsSuccess); - -FreeBlueTblElements: - Xfree((char *)pScreenData->pBlueTbl->pBase); - -FreeBlueTbl: - Xfree((char *)pScreenData->pBlueTbl); - -FreeGreenTblElements: - Xfree((char *)pScreenData->pBlueTbl->pBase); - -FreeGreenTbl: - Xfree((char *)pScreenData->pGreenTbl); - -FreeRedTblElements: - Xfree((char *)pScreenData->pRedTbl->pBase); - -FreeRedTbl: - Xfree((char *)pScreenData->pRedTbl); - -FreeSCCData: - Xfree((char *)pScreenData); - pPerScrnInfo->state = XcmsInitNone; - return(XcmsFailure); -} - - -/* - * NAME - * LINEAR_RGB_FreeSCCData() - * - * SYNOPSIS - */ -static void -LINEAR_RGB_FreeSCCData( - XPointer pScreenDataTemp) -/* - * DESCRIPTION - * - * RETURNS - * 0 if failed. - * 1 if succeeded with no modifications. - * - */ -{ - LINEAR_RGB_SCCData *pScreenData = (LINEAR_RGB_SCCData *) pScreenDataTemp; - - if (pScreenData && pScreenData != &Default_RGB_SCCData) { - if (pScreenData->pRedTbl) { - if (pScreenData->pGreenTbl) { - if (pScreenData->pRedTbl->pBase != - pScreenData->pGreenTbl->pBase) { - if (pScreenData->pGreenTbl->pBase) { - Xfree ((char *)pScreenData->pGreenTbl->pBase); - } - } - if (pScreenData->pGreenTbl != pScreenData->pRedTbl) { - Xfree ((char *)pScreenData->pGreenTbl); - } - } - if (pScreenData->pBlueTbl) { - if (pScreenData->pRedTbl->pBase != - pScreenData->pBlueTbl->pBase) { - if (pScreenData->pBlueTbl->pBase) { - Xfree ((char *)pScreenData->pBlueTbl->pBase); - } - } - if (pScreenData->pBlueTbl != pScreenData->pRedTbl) { - Xfree ((char *)pScreenData->pBlueTbl); - } - } - if (pScreenData->pRedTbl->pBase) { - Xfree ((char *)pScreenData->pRedTbl->pBase); - } - Xfree ((char *)pScreenData->pRedTbl); - } - Xfree ((char *)pScreenData); - } -} - - - -/************************************************************************ - * * - * API PRIVATE ROUTINES * - * * - ************************************************************************/ - -/* - * NAME - * _XcmsGetTableType0 - * - * SYNOPSIS - */ -static Status -_XcmsGetTableType0( - IntensityTbl *pTbl, - int format, - char **pChar, - unsigned long *pCount) -/* - * DESCRIPTION - * - * RETURNS - * XcmsFailure if failed. - * XcmsSuccess if succeeded. - * - */ -{ - unsigned int nElements; - IntensityRec *pIRec; - - nElements = pTbl->nEntries = - _XcmsGetElement(format, pChar, pCount) + 1; - if (!(pIRec = pTbl->pBase = (IntensityRec *) - Xcalloc (nElements, sizeof(IntensityRec)))) { - return(XcmsFailure); - } - - switch (format) { - case 8: - for (; nElements--; pIRec++) { - /* 0xFFFF/0xFF = 0x101 */ - pIRec->value = _XcmsGetElement (format, pChar, pCount) * 0x101; - pIRec->intensity = - _XcmsGetElement (format, pChar, pCount) / (XcmsFloat)255.0; - } - break; - case 16: - for (; nElements--; pIRec++) { - pIRec->value = _XcmsGetElement (format, pChar, pCount); - pIRec->intensity = _XcmsGetElement (format, pChar, pCount) - / (XcmsFloat)65535.0; - } - break; - case 32: - for (; nElements--; pIRec++) { - pIRec->value = _XcmsGetElement (format, pChar, pCount); - pIRec->intensity = _XcmsGetElement (format, pChar, pCount) - / (XcmsFloat)4294967295.0; - } - break; - default: - return(XcmsFailure); - } - return(XcmsSuccess); -} - - -/* - * NAME - * _XcmsGetTableType1 - * - * SYNOPSIS - */ -static Status -_XcmsGetTableType1( - IntensityTbl *pTbl, - int format, - char **pChar, - unsigned long *pCount) -/* - * DESCRIPTION - * - * RETURNS - * XcmsFailure if failed. - * XcmsSuccess if succeeded. - * - */ -{ - int count; - unsigned int max_index; - IntensityRec *pIRec; - - max_index = _XcmsGetElement(format, pChar, pCount); - pTbl->nEntries = max_index + 1; - if (!(pIRec = pTbl->pBase = (IntensityRec *) - Xcalloc (max_index+1, sizeof(IntensityRec)))) { - return(XcmsFailure); - } - - switch (format) { - case 8: - for (count = 0; count < max_index+1; count++, pIRec++) { - pIRec->value = (count * 65535) / max_index; - pIRec->intensity = _XcmsGetElement (format, pChar, pCount) - / (XcmsFloat)255.0; - } - break; - case 16: - for (count = 0; count < max_index+1; count++, pIRec++) { - pIRec->value = (count * 65535) / max_index; - pIRec->intensity = _XcmsGetElement (format, pChar, pCount) - / (XcmsFloat)65535.0; - } - break; - case 32: - for (count = 0; count < max_index+1; count++, pIRec++) { - pIRec->value = (count * 65535) / max_index; - pIRec->intensity = _XcmsGetElement (format, pChar, pCount) - / (XcmsFloat)4294967295.0; - } - break; - default: - return(XcmsFailure); - } - - return(XcmsSuccess); -} - - -/* - * NAME - * ValueCmp - * - * SYNOPSIS - */ -static int -_XcmsValueCmp( - IntensityRec *p1, IntensityRec *p2) -/* - * DESCRIPTION - * Compares the value component of two IntensityRec - * structures. - * - * RETURNS - * 0 if p1->value is equal to p2->value - * < 0 if p1->value is less than p2->value - * > 0 if p1->value is greater than p2->value - * - */ -{ - return (p1->value - p2->value); -} - - -/* - * NAME - * IntensityCmp - * - * SYNOPSIS - */ -static int -_XcmsIntensityCmp( - IntensityRec *p1, IntensityRec *p2) -/* - * DESCRIPTION - * Compares the intensity component of two IntensityRec - * structures. - * - * RETURNS - * 0 if equal; - * < 0 if first precedes second - * > 0 if first succeeds second - * - */ -{ - if (p1->intensity < p2->intensity) { - return (-1); - } - if (p1->intensity > p2->intensity) { - return (XcmsSuccess); - } - return (XcmsFailure); -} - -/* - * NAME - * ValueInterpolation - * - * SYNOPSIS - */ -/* ARGSUSED */ -static int -_XcmsValueInterpolation( - IntensityRec *key, IntensityRec *lo, IntensityRec *hi, IntensityRec *answer, - int bitsPerRGB) -/* - * DESCRIPTION - * Based on a given value, performs a linear interpolation - * on the intensities between two IntensityRec structures. - * Note that the bitsPerRGB parameter is ignored. - * - * RETURNS - * Returns 0 if failed; otherwise non-zero. - */ -{ - XcmsFloat ratio; - - ratio = ((XcmsFloat)key->value - (XcmsFloat)lo->value) / - ((XcmsFloat)hi->value - (XcmsFloat)lo->value); - answer->value = key->value; - answer->intensity = (hi->intensity - lo->intensity) * ratio; - answer->intensity += lo->intensity; - return (XcmsSuccess); -} - -/* - * NAME - * IntensityInterpolation - * - * SYNOPSIS - */ -static int -_XcmsIntensityInterpolation( - IntensityRec *key, IntensityRec *lo, IntensityRec *hi, IntensityRec *answer, - int bitsPerRGB) -/* - * DESCRIPTION - * Based on a given intensity, performs a linear interpolation - * on the values between two IntensityRec structures. - * The bitsPerRGB parameter is necessary to perform rounding - * to the correct number of significant bits. - * - * RETURNS - * Returns 0 if failed; otherwise non-zero. - */ -{ - XcmsFloat ratio; - long target, up, down; - int shift = 16 - bitsPerRGB; - int max_color = (1 << bitsPerRGB) - 1; - - ratio = (key->intensity - lo->intensity) / (hi->intensity - lo->intensity); - answer->intensity = key->intensity; - target = hi->value - lo->value; - target *= ratio; - target += lo->value; - - /* - * Ok now, lets find the closest in respects to bits per RGB - */ - up = ((target >> shift) * 0xFFFF) / max_color; - if (up < target) { - down = up; - up = (MIN((down >> shift) + 1, max_color) * 0xFFFF) / max_color; - } else { - down = (MAX((up >> shift) - 1, 0) * 0xFFFF) / max_color; - } - answer->value = ((up - target) < (target - down) ? up : down); - answer->value &= MASK[bitsPerRGB]; - return (XcmsSuccess); -} - - - -typedef int (*comparProcp)( - char *p1, - char *p2); -typedef int (*interpolProcp)( - char *key, - char *lo, - char *hi, - char *answer, - int bitsPerRGB); - -/* - * NAME - * _XcmsTableSearch - * - * SYNOPSIS - */ -static int -_XcmsTableSearch( - char *key, - int bitsPerRGB, - char *base, - unsigned nel, - unsigned nKeyPtrSize, - int (*compar)( - char *p1, - char *p2), - int (*interpol)( - char *key, - char *lo, - char *hi, - char *answer, - int bitsPerRGB), - char *answer) - -/* - * DESCRIPTION - * A binary search through the specificied table. - * - * RETURNS - * Returns 0 if failed; otherwise non-zero. - * - */ -{ - char *hi, *lo, *mid, *last; - int result; - - last = hi = base + ((nel - 1) * nKeyPtrSize); - mid = lo = base; - - /* use only the significants bits, then scale into 16 bits */ - ((IntensityRec *)key)->value = ((unsigned long) - (((IntensityRec *)key)->value >> (16 - bitsPerRGB)) * 0xFFFF) - / ((1 << bitsPerRGB) - 1); - - /* Special case so that zero intensity always maps to zero value */ - if ((*compar) (key,lo) <= 0) { - memcpy (answer, lo, nKeyPtrSize); - ((IntensityRec *)answer)->value &= MASK[bitsPerRGB]; - return XcmsSuccess; - } - while (mid != last) { - last = mid; - mid = lo + (((unsigned)(hi - lo) / nKeyPtrSize) / 2) * nKeyPtrSize; - result = (*compar) (key, mid); - if (result == 0) { - - memcpy(answer, mid, nKeyPtrSize); - ((IntensityRec *)answer)->value &= MASK[bitsPerRGB]; - return (XcmsSuccess); - } else if (result < 0) { - hi = mid; - } else { - lo = mid; - } - } - - /* - * If we got to here, we didn't find a solution, so we - * need to apply interpolation. - */ - return ((*interpol)(key, lo, hi, answer, bitsPerRGB)); -} - - -/* - * NAME - * _XcmsMatVec - multiply a 3 x 3 by a 3 x 1 vector - * - * SYNOPSIS - */ -static void _XcmsMatVec( - XcmsFloat *pMat, XcmsFloat *pIn, XcmsFloat *pOut) -/* - * DESCRIPTION - * Multiply the passed vector by the passed matrix to return a - * vector. Matrix is 3x3, vectors are of length 3. - * - * RETURNS - * void - */ -{ - int i, j; - - for (i = 0; i < 3; i++) { - pOut[i] = 0.0; - for (j = 0; j < 3; j++) - pOut[i] += *(pMat+(i*3)+j) * pIn[j]; - } -} - - -/************************************************************************ - * * - * PUBLIC ROUTINES * - * * - ************************************************************************/ - - -/* - * NAME - * XcmsLRGB_RGB_ParseString - * - * SYNOPSIS - */ -static int -XcmsLRGB_RGB_ParseString( - register char *spec, - XcmsColor *pColor) -/* - * DESCRIPTION - * This routines takes a string and attempts to convert - * it into a XcmsColor structure with XcmsRGBFormat. - * - * RETURNS - * 0 if failed, non-zero otherwise. - */ -{ - register int n, i; - unsigned short r, g, b; - char c; - char *pchar; - unsigned short *pShort; - - /* - * Check for old # format - */ - if (*spec == '#') { - /* - * Attempt to parse the value portion. - */ - spec++; - n = strlen(spec); - if (n != 3 && n != 6 && n != 9 && n != 12) { - return(XcmsFailure); - } - - n /= 3; - g = b = 0; - do { - r = g; - g = b; - b = 0; - for (i = n; --i >= 0; ) { - c = *spec++; - b <<= 4; - if (c >= '0' && c <= '9') - b |= c - '0'; - /* assume string in lowercase - else if (c >= 'A' && c <= 'F') - b |= c - ('A' - 10); - */ - else if (c >= 'a' && c <= 'f') - b |= c - ('a' - 10); - else return (XcmsFailure); - } - } while (*spec != '\0'); - - /* - * Succeeded ! - */ - n <<= 2; - n = 16 - n; - /* shift instead of scale, to match old broken semantics */ - pColor->spec.RGB.red = r << n; - pColor->spec.RGB.green = g << n; - pColor->spec.RGB.blue = b << n; - } else { - if ((pchar = strchr(spec, ':')) == NULL) { - return(XcmsFailure); - } - n = (int)(pchar - spec); - - /* - * Check for proper prefix. - */ - if (strncmp(spec, _XcmsRGB_prefix, n) != 0) { - return(XcmsFailure); - } - - /* - * Attempt to parse the value portion. - */ - spec += (n + 1); - pShort = &pColor->spec.RGB.red; - for (i = 0; i < 3; i++, pShort++, spec++) { - n = 0; - *pShort = 0; - while (*spec != '/' && *spec != '\0') { - if (++n > 4) { - return(XcmsFailure); - } - c = *spec++; - *pShort <<= 4; - if (c >= '0' && c <= '9') - *pShort |= c - '0'; - /* assume string in lowercase - else if (c >= 'A' && c <= 'F') - *pShort |= c - ('A' - 10); - */ - else if (c >= 'a' && c <= 'f') - *pShort |= c - ('a' - 10); - else return (XcmsFailure); - } - if (n == 0) - return (XcmsFailure); - if (n < 4) { - *pShort = ((unsigned long)*pShort * 0xFFFF) / ((1 << n*4) - 1); - } - } - } - pColor->format = XcmsRGBFormat; - pColor->pixel = 0; - return (XcmsSuccess); -} - - -/* - * NAME - * XcmsLRGB_RGBi_ParseString - * - * SYNOPSIS - */ -static int -XcmsLRGB_RGBi_ParseString( - register char *spec, - XcmsColor *pColor) -/* - * DESCRIPTION - * This routines takes a string and attempts to convert - * it into a XcmsColor structure with XcmsRGBiFormat. - * The assumed RGBi string syntax is: - * RGBi:// - * Where r, g, and b are in string input format for floats - * consisting of: - * a. an optional sign - * b. a string of numbers possibly containing a decimal point, - * c. an optional exponent field containing an 'E' or 'e' - * followed by a possibly signed integer string. - * - * RETURNS - * 0 if failed, non-zero otherwise. - */ -{ - int n; - char *pchar; - - if ((pchar = strchr(spec, ':')) == NULL) { - return(XcmsFailure); - } - n = (int)(pchar - spec); - - /* - * Check for proper prefix. - */ - if (strncmp(spec, _XcmsRGBi_prefix, n) != 0) { - return(XcmsFailure); - } - - /* - * Attempt to parse the value portion. - */ - if (sscanf(spec + n + 1, "%lf/%lf/%lf", - &pColor->spec.RGBi.red, - &pColor->spec.RGBi.green, - &pColor->spec.RGBi.blue) != 3) { - char *s; /* Maybe failed due to locale */ - int f; - if ((s = strdup(spec))) { - for (f = 0; s[f]; ++f) - if (s[f] == '.') - s[f] = ','; - else if (s[f] == ',') - s[f] = '.'; - if (sscanf(s + n + 1, "%lf/%lf/%lf", - &pColor->spec.RGBi.red, - &pColor->spec.RGBi.green, - &pColor->spec.RGBi.blue) != 3) { - free(s); - return(XcmsFailure); - } - free(s); - } else - return(XcmsFailure); - } - - /* - * Succeeded ! - */ - pColor->format = XcmsRGBiFormat; - pColor->pixel = 0; - return (XcmsSuccess); -} - - -/* - * NAME - * XcmsCIEXYZToRGBi - convert CIE XYZ to RGB - * - * SYNOPSIS - */ -/* ARGSUSED */ -Status -XcmsCIEXYZToRGBi( - XcmsCCC ccc, - XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ - unsigned int nColors, /* Number of colors */ - Bool *pCompressed) /* pointer to an array of Bool */ -/* - * DESCRIPTION - * Converts color specifications in an array of XcmsColor - * structures from RGB format to RGBi format. - * - * RETURNS - * XcmsFailure if failed, - * XcmsSuccess if succeeded without gamut compression. - * XcmsSuccessWithCompression if succeeded with gamut - * compression. - */ -{ - LINEAR_RGB_SCCData *pScreenData; - XcmsFloat tmp[3]; - int hasCompressed = 0; - unsigned int i; - XcmsColor *pColor = pXcmsColors_in_out; - - if (ccc == NULL) { - return(XcmsFailure); - } - - pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; - - /* - * XcmsColors should be White Point Adjusted, if necessary, by now! - */ - - /* - * NEW!!! for extended gamut compression - * - * 1. Need to zero out pCompressed - * - * 2. Need to save initial address of pColor - * - * 3. Need to save initial address of pCompressed - */ - - for (i = 0; i < nColors; i++) { - - /* Make sure format is XcmsCIEXYZFormat */ - if (pColor->format != XcmsCIEXYZFormat) { - return(XcmsFailure); - } - - /* Multiply [A]-1 * [XYZ] to get RGB intensity */ - _XcmsMatVec((XcmsFloat *) pScreenData->XYZtoRGBmatrix, - (XcmsFloat *) &pColor->spec, tmp); - - if ((MIN3 (tmp[0], tmp[1], tmp[2]) < -EPS) || - (MAX3 (tmp[0], tmp[1], tmp[2]) > (1.0 + EPS))) { - - /* - * RGBi out of screen's gamut - */ - - if (ccc->gamutCompProc == NULL) { - /* - * Aha!! Here's that little trick that will allow - * gamut compression routines to get the out of bound - * RGBi. - */ - memcpy((char *)&pColor->spec, (char *)tmp, sizeof(tmp)); - pColor->format = XcmsRGBiFormat; - return(XcmsFailure); - } else if ((*ccc->gamutCompProc)(ccc, pXcmsColors_in_out, nColors, - i, pCompressed) == 0) { - return(XcmsFailure); - } - - /* - * The gamut compression function should return colors in CIEXYZ - * Also check again to if the new color is within gamut. - */ - if (pColor->format != XcmsCIEXYZFormat) { - return(XcmsFailure); - } - _XcmsMatVec((XcmsFloat *) pScreenData->XYZtoRGBmatrix, - (XcmsFloat *) &pColor->spec, tmp); - if ((MIN3 (tmp[0], tmp[1], tmp[2]) < -EPS) || - (MAX3 (tmp[0], tmp[1], tmp[2]) > (1.0 + EPS))) { - return(XcmsFailure); - } - hasCompressed++; - } - memcpy((char *)&pColor->spec, (char *)tmp, sizeof(tmp)); - /* These if statements are done to ensure the fudge factor is */ - /* is taken into account. */ - if (pColor->spec.RGBi.red < 0.0) { - pColor->spec.RGBi.red = 0.0; - } else if (pColor->spec.RGBi.red > 1.0) { - pColor->spec.RGBi.red = 1.0; - } - if (pColor->spec.RGBi.green < 0.0) { - pColor->spec.RGBi.green = 0.0; - } else if (pColor->spec.RGBi.green > 1.0) { - pColor->spec.RGBi.green = 1.0; - } - if (pColor->spec.RGBi.blue < 0.0) { - pColor->spec.RGBi.blue = 0.0; - } else if (pColor->spec.RGBi.blue > 1.0) { - pColor->spec.RGBi.blue = 1.0; - } - (pColor++)->format = XcmsRGBiFormat; - } - return (hasCompressed ? XcmsSuccessWithCompression : XcmsSuccess); -} - - -/* - * NAME - * LINEAR_RGBi_to_CIEXYZ - convert RGBi to CIEXYZ - * - * SYNOPSIS - */ -/* ARGSUSED */ -Status -XcmsRGBiToCIEXYZ( - XcmsCCC ccc, - XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ - unsigned int nColors, /* Number of colors */ - Bool *pCompressed) /* pointer to a bit array */ -/* - * DESCRIPTION - * Converts color specifications in an array of XcmsColor - * structures from RGBi format to CIEXYZ format. - * - * RETURNS - * XcmsFailure if failed, - * XcmsSuccess if succeeded. - */ -{ - LINEAR_RGB_SCCData *pScreenData; - XcmsFloat tmp[3]; - - /* - * pCompressed ignored in this function. - */ - - if (ccc == NULL) { - return(XcmsFailure); - } - - pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; - - /* - * XcmsColors should be White Point Adjusted, if necessary, by now! - */ - - while (nColors--) { - - /* Multiply [A]-1 * [XYZ] to get RGB intensity */ - _XcmsMatVec((XcmsFloat *) pScreenData->RGBtoXYZmatrix, - (XcmsFloat *) &pXcmsColors_in_out->spec, tmp); - - memcpy((char *)&pXcmsColors_in_out->spec, (char *)tmp, sizeof(tmp)); - (pXcmsColors_in_out++)->format = XcmsCIEXYZFormat; - } - return(XcmsSuccess); -} - - -/* - * NAME - * XcmsRGBiToRGB - * - * SYNOPSIS - */ -/* ARGSUSED */ -Status -XcmsRGBiToRGB( - XcmsCCC ccc, - XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ - unsigned int nColors, /* Number of colors */ - Bool *pCompressed) /* pointer to a bit array */ -/* - * DESCRIPTION - * Converts color specifications in an array of XcmsColor - * structures from RGBi format to RGB format. - * - * RETURNS - * XcmsFailure if failed, - * XcmsSuccess if succeeded without gamut compression. - * XcmsSuccessWithCompression if succeeded with gamut - * compression. - */ -{ - LINEAR_RGB_SCCData *pScreenData; - XcmsRGB tmpRGB; - IntensityRec keyIRec, answerIRec; - - /* - * pCompressed ignored in this function. - */ - - if (ccc == NULL) { - return(XcmsFailure); - } - - pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; - - while (nColors--) { - - /* Make sure format is XcmsRGBiFormat */ - if (pXcmsColors_in_out->format != XcmsRGBiFormat) { - return(XcmsFailure); - } - - keyIRec.intensity = pXcmsColors_in_out->spec.RGBi.red; - if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, - (char *)pScreenData->pRedTbl->pBase, - (unsigned)pScreenData->pRedTbl->nEntries, - (unsigned)sizeof(IntensityRec), - (comparProcp)_XcmsIntensityCmp, (interpolProcp)_XcmsIntensityInterpolation, (char *)&answerIRec)) { - return(XcmsFailure); - } - tmpRGB.red = answerIRec.value; - - keyIRec.intensity = pXcmsColors_in_out->spec.RGBi.green; - if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, - (char *)pScreenData->pGreenTbl->pBase, - (unsigned)pScreenData->pGreenTbl->nEntries, - (unsigned)sizeof(IntensityRec), - (comparProcp)_XcmsIntensityCmp, (interpolProcp)_XcmsIntensityInterpolation, (char *)&answerIRec)) { - return(XcmsFailure); - } - tmpRGB.green = answerIRec.value; - - keyIRec.intensity = pXcmsColors_in_out->spec.RGBi.blue; - if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, - (char *)pScreenData->pBlueTbl->pBase, - (unsigned)pScreenData->pBlueTbl->nEntries, - (unsigned)sizeof(IntensityRec), - (comparProcp)_XcmsIntensityCmp, (interpolProcp)_XcmsIntensityInterpolation, (char *)&answerIRec)) { - return(XcmsFailure); - } - tmpRGB.blue = answerIRec.value; - - memcpy((char *)&pXcmsColors_in_out->spec, (char *)&tmpRGB, sizeof(XcmsRGB)); - (pXcmsColors_in_out++)->format = XcmsRGBFormat; - } - return(XcmsSuccess); -} - - -/* - * NAME - * XcmsRGBToRGBi - * - * SYNOPSIS - */ -/* ARGSUSED */ -Status -XcmsRGBToRGBi( - XcmsCCC ccc, - XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ - unsigned int nColors, /* Number of colors */ - Bool *pCompressed) /* pointer to a bit array */ -/* - * DESCRIPTION - * Converts color specifications in an array of XcmsColor - * structures from RGB format to RGBi format. - * - * RETURNS - * XcmsFailure if failed, - * XcmsSuccess if succeeded. - */ -{ - LINEAR_RGB_SCCData *pScreenData; - XcmsRGBi tmpRGBi; - IntensityRec keyIRec, answerIRec; - - /* - * pCompressed ignored in this function. - */ - - if (ccc == NULL) { - return(XcmsFailure); - } - - pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; - - while (nColors--) { - - /* Make sure format is XcmsRGBFormat */ - if (pXcmsColors_in_out->format != XcmsRGBFormat) { - return(XcmsFailure); - } - - keyIRec.value = pXcmsColors_in_out->spec.RGB.red; - if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, - (char *)pScreenData->pRedTbl->pBase, - (unsigned)pScreenData->pRedTbl->nEntries, - (unsigned)sizeof(IntensityRec), - (comparProcp)_XcmsValueCmp, (interpolProcp)_XcmsValueInterpolation, (char *)&answerIRec)) { - return(XcmsFailure); - } - tmpRGBi.red = answerIRec.intensity; - - keyIRec.value = pXcmsColors_in_out->spec.RGB.green; - if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, - (char *)pScreenData->pGreenTbl->pBase, - (unsigned)pScreenData->pGreenTbl->nEntries, - (unsigned)sizeof(IntensityRec), - (comparProcp)_XcmsValueCmp, (interpolProcp)_XcmsValueInterpolation, (char *)&answerIRec)) { - return(XcmsFailure); - } - tmpRGBi.green = answerIRec.intensity; - - keyIRec.value = pXcmsColors_in_out->spec.RGB.blue; - if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, - (char *)pScreenData->pBlueTbl->pBase, - (unsigned)pScreenData->pBlueTbl->nEntries, - (unsigned)sizeof(IntensityRec), - (comparProcp)_XcmsValueCmp, (interpolProcp)_XcmsValueInterpolation, (char *)&answerIRec)) { - return(XcmsFailure); - } - tmpRGBi.blue = answerIRec.intensity; - - memcpy((char *)&pXcmsColors_in_out->spec, (char *)&tmpRGBi, sizeof(XcmsRGBi)); - (pXcmsColors_in_out++)->format = XcmsRGBiFormat; - } - return(XcmsSuccess); -} - -/* - * NAME - * _XcmsInitScrnDefaultInfo - * - * SYNOPSIS - */ -/* ARGSUSED */ -int -_XcmsLRGB_InitScrnDefault( - Display *dpy, - int screenNumber, - XcmsPerScrnInfo *pPerScrnInfo) -/* - * DESCRIPTION - * Given a display and screen number, this routine attempts - * to initialize the Xcms per Screen Info structure - * (XcmsPerScrnInfo) with defaults. - * - * RETURNS - * Returns zero if initialization failed; non-zero otherwise. - */ -{ - pPerScrnInfo->screenData = (XPointer)&Default_RGB_SCCData; - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.X = - Default_RGB_SCCData.RGBtoXYZmatrix[0][0] + - Default_RGB_SCCData.RGBtoXYZmatrix[0][1] + - Default_RGB_SCCData.RGBtoXYZmatrix[0][2]; - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = - Default_RGB_SCCData.RGBtoXYZmatrix[1][0] + - Default_RGB_SCCData.RGBtoXYZmatrix[1][1] + - Default_RGB_SCCData.RGBtoXYZmatrix[1][2]; - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Z = - Default_RGB_SCCData.RGBtoXYZmatrix[2][0] + - Default_RGB_SCCData.RGBtoXYZmatrix[2][1] + - Default_RGB_SCCData.RGBtoXYZmatrix[2][2]; - if ((pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y < (1.0 - EPS) ) - || (pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y > (1.0 + EPS))) { - pPerScrnInfo->screenData = (XPointer)NULL; - pPerScrnInfo->state = XcmsInitNone; - return(0); - } - pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = 1.0; - pPerScrnInfo->screenWhitePt.format = XcmsCIEXYZFormat; - pPerScrnInfo->screenWhitePt.pixel = 0; - pPerScrnInfo->functionSet = (XPointer)&XcmsLinearRGBFunctionSet; - pPerScrnInfo->state = XcmsInitFailure; /* default initialization */ - return(1); -} + +/* + * Code and supporting documentation (c) Copyright 1990 1991 Tektronix, Inc. + * All Rights Reserved + * + * This file is a component of an X Window System-specific implementation + * of Xcms based on the TekColor Color Management System. Permission is + * hereby granted to use, copy, modify, sell, and otherwise distribute this + * software and its documentation for any purpose and without fee, provided + * that this copyright, permission, and disclaimer notice is reproduced in + * all copies of this software and in supporting documentation. TekColor + * is a trademark of Tektronix, Inc. + * + * Tektronix makes no representation about the suitability of this software + * for any purpose. It is provided "as is" and with all faults. + * + * TEKTRONIX DISCLAIMS ALL WARRANTIES APPLICABLE TO THIS SOFTWARE, + * INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A + * PARTICULAR PURPOSE. IN NO EVENT SHALL TEKTRONIX BE LIABLE FOR ANY + * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER + * RESULTING FROM LOSS OF USE, DATA, OR PROFITS, WHETHER IN AN ACTION OF + * CONTRACT, NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN + * CONNECTION WITH THE USE OR THE PERFORMANCE OF THIS SOFTWARE. + * + * + * NAME + * XcmsLRGB.c + * + * DESCRIPTION + * This file contains the conversion routines: + * 1. CIE XYZ to RGB intensity + * 2. RGB intensity to device RGB + * 3. device RGB to RGB intensity + * 4. RGB intensity to CIE XYZ + * + */ + +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include +#include +#include "Xlibint.h" +#include "Xcmsint.h" +#include "Cv.h" + +/* + * LOCAL DEFINES + * #define declarations local to this package. + */ +#define EPS 0.001 +#ifndef MIN +#define MIN(x,y) ((x) > (y) ? (y) : (x)) +#endif /* MIN */ +#ifndef MAX +#define MAX(x,y) ((x) > (y) ? (x) : (y)) +#endif /* MAX */ +#ifndef MIN3 +#define MIN3(x,y,z) ((x) > (MIN((y), (z))) ? (MIN((y), (z))) : (x)) +#endif /* MIN3 */ +#ifndef MAX3 +#define MAX3(x,y,z) ((x) > (MAX((y), (z))) ? (x) : (MAX((y), (z)))) +#endif /* MAX3 */ + +/* + * LOCAL TYPEDEFS + * typedefs local to this package (for use with local vars). + * + */ + +/* + * FORWARD DECLARATIONS + */ +static void LINEAR_RGB_FreeSCCData(XPointer pScreenDataTemp); +static int LINEAR_RGB_InitSCCData(Display *dpy, + int screenNumber, XcmsPerScrnInfo *pPerScrnInfo); +static int XcmsLRGB_RGB_ParseString(register char *spec, XcmsColor *pColor); +static int XcmsLRGB_RGBi_ParseString(register char *spec, XcmsColor *pColor); +static Status +_XcmsGetTableType0( + IntensityTbl *pTbl, + int format, + char **pChar, + unsigned long *pCount); +static Status +_XcmsGetTableType1( + IntensityTbl *pTbl, + int format, + char **pChar, + unsigned long *pCount); + +/* + * LOCALS VARIABLES + * Variables local to this package. + * Usage example: + * static int ExampleLocalVar; + */ + +static unsigned short const MASK[17] = { + 0x0000, /* 0 bitsPerRGB */ + 0x8000, /* 1 bitsPerRGB */ + 0xc000, /* 2 bitsPerRGB */ + 0xe000, /* 3 bitsPerRGB */ + 0xf000, /* 4 bitsPerRGB */ + 0xf800, /* 5 bitsPerRGB */ + 0xfc00, /* 6 bitsPerRGB */ + 0xfe00, /* 7 bitsPerRGB */ + 0xff00, /* 8 bitsPerRGB */ + 0xff80, /* 9 bitsPerRGB */ + 0xffc0, /* 10 bitsPerRGB */ + 0xffe0, /* 11 bitsPerRGB */ + 0xfff0, /* 12 bitsPerRGB */ + 0xfff8, /* 13 bitsPerRGB */ + 0xfffc, /* 14 bitsPerRGB */ + 0xfffe, /* 15 bitsPerRGB */ + 0xffff /* 16 bitsPerRGB */ +}; + + + /* + * A NULL terminated array of function pointers that when applied + * in series will convert an XcmsColor structure from XcmsRGBFormat + * to XcmsCIEXYZFormat. + */ +static XcmsConversionProc Fl_RGB_to_CIEXYZ[] = { + (XcmsConversionProc)XcmsRGBToRGBi, + (XcmsConversionProc)XcmsRGBiToCIEXYZ, + NULL +}; + + /* + * A NULL terminated array of function pointers that when applied + * in series will convert an XcmsColor structure from XcmsCIEXYZFormat + * to XcmsRGBFormat. + */ +static XcmsConversionProc Fl_CIEXYZ_to_RGB[] = { + (XcmsConversionProc)XcmsCIEXYZToRGBi, + (XcmsConversionProc)XcmsRGBiToRGB, + NULL +}; + + /* + * A NULL terminated array of function pointers that when applied + * in series will convert an XcmsColor structure from XcmsRGBiFormat + * to XcmsCIEXYZFormat. + */ +static XcmsConversionProc Fl_RGBi_to_CIEXYZ[] = { + (XcmsConversionProc)XcmsRGBiToCIEXYZ, + NULL +}; + + /* + * A NULL terminated array of function pointers that when applied + * in series will convert an XcmsColor structure from XcmsCIEXYZFormat + * to XcmsRGBiFormat. + */ +static XcmsConversionProc Fl_CIEXYZ_to_RGBi[] = { + (XcmsConversionProc)XcmsCIEXYZToRGBi, + NULL +}; + + /* + * RGBi Color Spaces + */ +XcmsColorSpace XcmsRGBiColorSpace = + { + _XcmsRGBi_prefix, /* prefix */ + XcmsRGBiFormat, /* id */ + XcmsLRGB_RGBi_ParseString, /* parseString */ + Fl_RGBi_to_CIEXYZ, /* to_CIEXYZ */ + Fl_CIEXYZ_to_RGBi, /* from_CIEXYZ */ + 1 + }; + + /* + * RGB Color Spaces + */ +XcmsColorSpace XcmsRGBColorSpace = + { + _XcmsRGB_prefix, /* prefix */ + XcmsRGBFormat, /* id */ + XcmsLRGB_RGB_ParseString, /* parseString */ + Fl_RGB_to_CIEXYZ, /* to_CIEXYZ */ + Fl_CIEXYZ_to_RGB, /* from_CIEXYZ */ + 1 + }; + + /* + * Device-Independent Color Spaces known to the + * LINEAR_RGB Screen Color Characteristics Function Set. + */ +static XcmsColorSpace *DDColorSpaces[] = { + &XcmsRGBColorSpace, + &XcmsRGBiColorSpace, + NULL +}; + + +/* + * GLOBALS + * Variables declared in this package that are allowed + * to be used globally. + */ + + /* + * LINEAR_RGB Screen Color Characteristics Function Set. + */ +XcmsFunctionSet XcmsLinearRGBFunctionSet = + { + &DDColorSpaces[0], /* pDDColorSpaces */ + LINEAR_RGB_InitSCCData, /* pInitScrnFunc */ + LINEAR_RGB_FreeSCCData /* pFreeSCCData */ + }; + +/* + * DESCRIPTION + * Contents of Default SCCData should be replaced if other + * data should be used as default. + * + * + */ + +/* + * NAME Tektronix 19" (Sony) CRT + * PART_NUMBER 119-2451-00 + * MODEL Tek4300, Tek4800 + */ + +static IntensityRec const Default_RGB_RedTuples[] = { + /* {unsigned short value, XcmsFloat intensity} */ + { 0x0000, 0.000000 }, + { 0x0909, 0.000000 }, + { 0x0a0a, 0.000936 }, + { 0x0f0f, 0.001481 }, + { 0x1414, 0.002329 }, + { 0x1919, 0.003529 }, + { 0x1e1e, 0.005127 }, + { 0x2323, 0.007169 }, + { 0x2828, 0.009699 }, + { 0x2d2d, 0.012759 }, + { 0x3232, 0.016392 }, + { 0x3737, 0.020637 }, + { 0x3c3c, 0.025533 }, + { 0x4141, 0.031119 }, + { 0x4646, 0.037431 }, + { 0x4b4b, 0.044504 }, + { 0x5050, 0.052373 }, + { 0x5555, 0.061069 }, + { 0x5a5a, 0.070624 }, + { 0x5f5f, 0.081070 }, + { 0x6464, 0.092433 }, + { 0x6969, 0.104744 }, + { 0x6e6e, 0.118026 }, + { 0x7373, 0.132307 }, + { 0x7878, 0.147610 }, + { 0x7d7d, 0.163958 }, + { 0x8282, 0.181371 }, + { 0x8787, 0.199871 }, + { 0x8c8c, 0.219475 }, + { 0x9191, 0.240202 }, + { 0x9696, 0.262069 }, + { 0x9b9b, 0.285089 }, + { 0xa0a0, 0.309278 }, + { 0xa5a5, 0.334647 }, + { 0xaaaa, 0.361208 }, + { 0xafaf, 0.388971 }, + { 0xb4b4, 0.417945 }, + { 0xb9b9, 0.448138 }, + { 0xbebe, 0.479555 }, + { 0xc3c3, 0.512202 }, + { 0xc8c8, 0.546082 }, + { 0xcdcd, 0.581199 }, + { 0xd2d2, 0.617552 }, + { 0xd7d7, 0.655144 }, + { 0xdcdc, 0.693971 }, + { 0xe1e1, 0.734031 }, + { 0xe6e6, 0.775322 }, + { 0xebeb, 0.817837 }, + { 0xf0f0, 0.861571 }, + { 0xf5f5, 0.906515 }, + { 0xfafa, 0.952662 }, + { 0xffff, 1.000000 } +}; + +static IntensityRec const Default_RGB_GreenTuples[] = { + /* {unsigned short value, XcmsFloat intensity} */ + { 0x0000, 0.000000 }, + { 0x1313, 0.000000 }, + { 0x1414, 0.000832 }, + { 0x1919, 0.001998 }, + { 0x1e1e, 0.003612 }, + { 0x2323, 0.005736 }, + { 0x2828, 0.008428 }, + { 0x2d2d, 0.011745 }, + { 0x3232, 0.015740 }, + { 0x3737, 0.020463 }, + { 0x3c3c, 0.025960 }, + { 0x4141, 0.032275 }, + { 0x4646, 0.039449 }, + { 0x4b4b, 0.047519 }, + { 0x5050, 0.056520 }, + { 0x5555, 0.066484 }, + { 0x5a5a, 0.077439 }, + { 0x5f5f, 0.089409 }, + { 0x6464, 0.102418 }, + { 0x6969, 0.116485 }, + { 0x6e6e, 0.131625 }, + { 0x7373, 0.147853 }, + { 0x7878, 0.165176 }, + { 0x7d7d, 0.183604 }, + { 0x8282, 0.203140 }, + { 0x8787, 0.223783 }, + { 0x8c8c, 0.245533 }, + { 0x9191, 0.268384 }, + { 0x9696, 0.292327 }, + { 0x9b9b, 0.317351 }, + { 0xa0a0, 0.343441 }, + { 0xa5a5, 0.370580 }, + { 0xaaaa, 0.398747 }, + { 0xafaf, 0.427919 }, + { 0xb4b4, 0.458068 }, + { 0xb9b9, 0.489165 }, + { 0xbebe, 0.521176 }, + { 0xc3c3, 0.554067 }, + { 0xc8c8, 0.587797 }, + { 0xcdcd, 0.622324 }, + { 0xd2d2, 0.657604 }, + { 0xd7d7, 0.693588 }, + { 0xdcdc, 0.730225 }, + { 0xe1e1, 0.767459 }, + { 0xe6e6, 0.805235 }, + { 0xebeb, 0.843491 }, + { 0xf0f0, 0.882164 }, + { 0xf5f5, 0.921187 }, + { 0xfafa, 0.960490 }, + { 0xffff, 1.000000 } +}; + +static IntensityRec const Default_RGB_BlueTuples[] = { + /* {unsigned short value, XcmsFloat intensity} */ + { 0x0000, 0.000000 }, + { 0x0e0e, 0.000000 }, + { 0x0f0f, 0.001341 }, + { 0x1414, 0.002080 }, + { 0x1919, 0.003188 }, + { 0x1e1e, 0.004729 }, + { 0x2323, 0.006766 }, + { 0x2828, 0.009357 }, + { 0x2d2d, 0.012559 }, + { 0x3232, 0.016424 }, + { 0x3737, 0.021004 }, + { 0x3c3c, 0.026344 }, + { 0x4141, 0.032489 }, + { 0x4646, 0.039481 }, + { 0x4b4b, 0.047357 }, + { 0x5050, 0.056154 }, + { 0x5555, 0.065903 }, + { 0x5a5a, 0.076634 }, + { 0x5f5f, 0.088373 }, + { 0x6464, 0.101145 }, + { 0x6969, 0.114968 }, + { 0x6e6e, 0.129862 }, + { 0x7373, 0.145841 }, + { 0x7878, 0.162915 }, + { 0x7d7d, 0.181095 }, + { 0x8282, 0.200386 }, + { 0x8787, 0.220791 }, + { 0x8c8c, 0.242309 }, + { 0x9191, 0.264937 }, + { 0x9696, 0.288670 }, + { 0x9b9b, 0.313499 }, + { 0xa0a0, 0.339410 }, + { 0xa5a5, 0.366390 }, + { 0xaaaa, 0.394421 }, + { 0xafaf, 0.423481 }, + { 0xb4b4, 0.453547 }, + { 0xb9b9, 0.484592 }, + { 0xbebe, 0.516587 }, + { 0xc3c3, 0.549498 }, + { 0xc8c8, 0.583291 }, + { 0xcdcd, 0.617925 }, + { 0xd2d2, 0.653361 }, + { 0xd7d7, 0.689553 }, + { 0xdcdc, 0.726454 }, + { 0xe1e1, 0.764013 }, + { 0xe6e6, 0.802178 }, + { 0xebeb, 0.840891 }, + { 0xf0f0, 0.880093 }, + { 0xf5f5, 0.919723 }, + { 0xfafa, 0.959715 }, + { 0xffff, 1.00000 } +}; + +static IntensityTbl Default_RGB_RedTbl = { + /* IntensityRec *pBase */ + (IntensityRec *) Default_RGB_RedTuples, + /* unsigned int nEntries */ + 52 +}; + +static IntensityTbl Default_RGB_GreenTbl = { + /* IntensityRec *pBase */ + (IntensityRec *)Default_RGB_GreenTuples, + /* unsigned int nEntries */ + 50 +}; + +static IntensityTbl Default_RGB_BlueTbl = { + /* IntensityRec *pBase */ + (IntensityRec *)Default_RGB_BlueTuples, + /* unsigned int nEntries */ + 51 +}; + +static LINEAR_RGB_SCCData Default_RGB_SCCData = { + /* XcmsFloat XYZtoRGBmatrix[3][3] */ + { + { 3.48340481253539000, -1.52176374927285200, -0.55923133354049780 }, + {-1.07152751306193600, 1.96593795204372400, 0.03673691339553462 }, + { 0.06351179790497788, -0.20020501000496480, 0.81070942031648220 } + }, + + /* XcmsFloat RGBtoXYZmatrix[3][3] */ + { + { 0.38106149108714790, 0.32025712365352110, 0.24834578525933100 }, + { 0.20729745115140850, 0.68054638776373240, 0.11215616108485920 }, + { 0.02133944350088028, 0.14297193020246480, 1.24172892629665500 } + }, + + /* IntensityTbl *pRedTbl */ + &Default_RGB_RedTbl, + + /* IntensityTbl *pGreenTbl */ + &Default_RGB_GreenTbl, + + /* IntensityTbl *pBlueTbl */ + &Default_RGB_BlueTbl +}; + +/************************************************************************ + * * + * PRIVATE ROUTINES * + * * + ************************************************************************/ + +/* + * NAME + * LINEAR_RGB_InitSCCData() + * + * SYNOPSIS + */ +static Status +LINEAR_RGB_InitSCCData( + Display *dpy, + int screenNumber, + XcmsPerScrnInfo *pPerScrnInfo) +/* + * DESCRIPTION + * + * RETURNS + * XcmsFailure if failed. + * XcmsSuccess if succeeded. + * + */ +{ + Atom CorrectAtom = XInternAtom (dpy, XDCCC_CORRECT_ATOM_NAME, True); + Atom MatrixAtom = XInternAtom (dpy, XDCCC_MATRIX_ATOM_NAME, True); + int format_return, count, cType, nTables; + unsigned long nitems, nbytes_return; + char *property_return, *pChar; + XcmsFloat *pValue; +#ifdef ALLDEBUG + IntensityRec *pIRec; +#endif /* ALLDEBUG */ + VisualID visualID; + + LINEAR_RGB_SCCData *pScreenData, *pScreenDefaultData; + XcmsIntensityMap *pNewMap; + + /* + * Allocate memory for pScreenData + */ + if (!(pScreenData = pScreenDefaultData = (LINEAR_RGB_SCCData *) + Xcalloc (1, sizeof(LINEAR_RGB_SCCData)))) { + return(XcmsFailure); + } + + /* + * 1. Get the XYZ->RGB and RGB->XYZ matrices + */ + + if (MatrixAtom == None || + !_XcmsGetProperty (dpy, RootWindow(dpy, screenNumber), MatrixAtom, + &format_return, &nitems, &nbytes_return, &property_return) || + nitems != 18 || format_return != 32) { + /* + * As per the XDCCC, there must be 18 data items and each must be + * in 32 bits ! + */ + goto FreeSCCData; + + } else { + + /* + * RGBtoXYZ and XYZtoRGB matrices + */ + pValue = (XcmsFloat *) pScreenData; + pChar = property_return; + for (count = 0; count < 18; count++) { + *pValue++ = (long)_XcmsGetElement(format_return, &pChar, + &nitems) / (XcmsFloat)XDCCC_NUMBER; + } + Xfree ((char *)property_return); + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.X = + pScreenData->RGBtoXYZmatrix[0][0] + + pScreenData->RGBtoXYZmatrix[0][1] + + pScreenData->RGBtoXYZmatrix[0][2]; + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = + pScreenData->RGBtoXYZmatrix[1][0] + + pScreenData->RGBtoXYZmatrix[1][1] + + pScreenData->RGBtoXYZmatrix[1][2]; + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Z = + pScreenData->RGBtoXYZmatrix[2][0] + + pScreenData->RGBtoXYZmatrix[2][1] + + pScreenData->RGBtoXYZmatrix[2][2]; + + /* + * Compute the Screen White Point + */ + if ((pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y < (1.0 - EPS) ) + || (pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y > (1.0 + EPS))) { + goto FreeSCCData; + } else { + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = 1.0; + } + pPerScrnInfo->screenWhitePt.format = XcmsCIEXYZFormat; + pPerScrnInfo->screenWhitePt.pixel = 0; + +#ifdef PDEBUG + printf ("RGB to XYZ Matrix values:\n"); + printf (" %f %f %f\n %f %f %f\n %f %f %f\n", + pScreenData->RGBtoXYZmatrix[0][0], + pScreenData->RGBtoXYZmatrix[0][1], + pScreenData->RGBtoXYZmatrix[0][2], + pScreenData->RGBtoXYZmatrix[1][0], + pScreenData->RGBtoXYZmatrix[1][1], + pScreenData->RGBtoXYZmatrix[1][2], + pScreenData->RGBtoXYZmatrix[2][0], + pScreenData->RGBtoXYZmatrix[2][1], + pScreenData->RGBtoXYZmatrix[2][2]); + printf ("XYZ to RGB Matrix values:\n"); + printf (" %f %f %f\n %f %f %f\n %f %f %f\n", + pScreenData->XYZtoRGBmatrix[0][0], + pScreenData->XYZtoRGBmatrix[0][1], + pScreenData->XYZtoRGBmatrix[0][2], + pScreenData->XYZtoRGBmatrix[1][0], + pScreenData->XYZtoRGBmatrix[1][1], + pScreenData->XYZtoRGBmatrix[1][2], + pScreenData->XYZtoRGBmatrix[2][0], + pScreenData->XYZtoRGBmatrix[2][1], + pScreenData->XYZtoRGBmatrix[2][2]); + printf ("Screen White Pt value: %f %f %f\n", + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.X, + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y, + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Z); +#endif /* PDEBUG */ + } + + /* + * 2. Get the Intensity Profile + */ + if (CorrectAtom == None || + !_XcmsGetProperty (dpy, RootWindow(dpy, screenNumber), CorrectAtom, + &format_return, &nitems, &nbytes_return, &property_return)) { + Xfree ((char *)property_return); + goto FreeSCCData; + } + + pChar = property_return; + + while (nitems) { + switch (format_return) { + case 8: + /* + * Must have at least: + * VisualID0 + * VisualID1 + * VisualID2 + * VisualID3 + * type + * count + * length + * intensity1 + * intensity2 + */ + if (nitems < 9) { + goto Free_property_return; + } + count = 3; + break; + case 16: + /* + * Must have at least: + * VisualID0 + * VisualID3 + * type + * count + * length + * intensity1 + * intensity2 + */ + if (nitems < 7) { + goto Free_property_return; + } + count = 1; + break; + case 32: + /* + * Must have at least: + * VisualID0 + * type + * count + * length + * intensity1 + * intensity2 + */ + if (nitems < 6) { + goto Free_property_return; + } + count = 0; + break; + default: + goto Free_property_return; + } + + /* + * Get VisualID + */ + visualID = _XcmsGetElement(format_return, &pChar, &nitems); + while (count--) { + visualID = visualID << format_return; + visualID |= _XcmsGetElement(format_return, &pChar, &nitems); + } + + if (visualID == 0) { + /* + * This is a shared intensity table + */ + pScreenData = pScreenDefaultData; + } else { + /* + * This is a per-Visual intensity table + */ + if (!(pScreenData = (LINEAR_RGB_SCCData *) + Xcalloc (1, sizeof(LINEAR_RGB_SCCData)))) { + return(XcmsFailure); + } + /* copy matrices */ + memcpy((char *)pScreenData, (char *)pScreenDefaultData, + 18 * sizeof(XcmsFloat)); + + /* Create, initialize, and add map */ + if (!(pNewMap = (XcmsIntensityMap *) + Xcalloc (1, sizeof(XcmsIntensityMap)))) { + Xfree((char *)pScreenData); + return(XcmsFailure); + } + pNewMap->visualID = visualID; + pNewMap->screenData = (XPointer)pScreenData; + pNewMap->pFreeScreenData = LINEAR_RGB_FreeSCCData; + pNewMap->pNext = + (XcmsIntensityMap *)dpy->cms.perVisualIntensityMaps; + dpy->cms.perVisualIntensityMaps = (XPointer)pNewMap; + dpy->free_funcs->intensityMaps = _XcmsFreeIntensityMaps; + } + + cType = _XcmsGetElement(format_return, &pChar, &nitems); + nTables = _XcmsGetElement(format_return, &pChar, &nitems); + + if (cType == 0) { + + /* Red Intensity Table */ + if (!(pScreenData->pRedTbl = (IntensityTbl *) + Xcalloc (1, sizeof(IntensityTbl)))) { + goto Free_property_return; + } + if (_XcmsGetTableType0(pScreenData->pRedTbl, format_return, &pChar, + &nitems) == XcmsFailure) { + goto FreeRedTbl; + } + + if (nTables == 1) { + /* Green Intensity Table */ + pScreenData->pGreenTbl = pScreenData->pRedTbl; + /* Blue Intensity Table */ + pScreenData->pBlueTbl = pScreenData->pRedTbl; + } else { + /* Green Intensity Table */ + if (!(pScreenData->pGreenTbl = (IntensityTbl *) + Xcalloc (1, sizeof(IntensityTbl)))) { + goto FreeRedTblElements; + } + if (_XcmsGetTableType0(pScreenData->pGreenTbl, format_return, &pChar, + &nitems) == XcmsFailure) { + goto FreeGreenTbl; + } + + /* Blue Intensity Table */ + if (!(pScreenData->pBlueTbl = (IntensityTbl *) + Xcalloc (1, sizeof(IntensityTbl)))) { + goto FreeGreenTblElements; + } + if (_XcmsGetTableType0(pScreenData->pBlueTbl, format_return, &pChar, + &nitems) == XcmsFailure) { + goto FreeBlueTbl; + } + } + } else if (cType == 1) { + /* Red Intensity Table */ + if (!(pScreenData->pRedTbl = (IntensityTbl *) + Xcalloc (1, sizeof(IntensityTbl)))) { + goto Free_property_return; + } + if (_XcmsGetTableType1(pScreenData->pRedTbl, format_return, &pChar, + &nitems) == XcmsFailure) { + goto FreeRedTbl; + } + + if (nTables == 1) { + + /* Green Intensity Table */ + pScreenData->pGreenTbl = pScreenData->pRedTbl; + /* Blue Intensity Table */ + pScreenData->pBlueTbl = pScreenData->pRedTbl; + + } else { + + /* Green Intensity Table */ + if (!(pScreenData->pGreenTbl = (IntensityTbl *) + Xcalloc (1, sizeof(IntensityTbl)))) { + goto FreeRedTblElements; + } + if (_XcmsGetTableType1(pScreenData->pGreenTbl, format_return, &pChar, + &nitems) == XcmsFailure) { + goto FreeGreenTbl; + } + + /* Blue Intensity Table */ + if (!(pScreenData->pBlueTbl = (IntensityTbl *) + Xcalloc (1, sizeof(IntensityTbl)))) { + goto FreeGreenTblElements; + } + if (_XcmsGetTableType1(pScreenData->pBlueTbl, format_return, &pChar, + &nitems) == XcmsFailure) { + goto FreeBlueTbl; + } + } + } else { + goto Free_property_return; + } + +#ifdef ALLDEBUG + printf ("Intensity Table RED %d\n", pScreenData->pRedTbl->nEntries); + pIRec = (IntensityRec *) pScreenData->pRedTbl->pBase; + for (count = 0; count < pScreenData->pRedTbl->nEntries; count++, pIRec++) { + printf ("\t0x%4x\t%f\n", pIRec->value, pIRec->intensity); + } + if (pScreenData->pGreenTbl->pBase != pScreenData->pRedTbl->pBase) { + printf ("Intensity Table GREEN %d\n", pScreenData->pGreenTbl->nEntries); + pIRec = (IntensityRec *)pScreenData->pGreenTbl->pBase; + for (count = 0; count < pScreenData->pGreenTbl->nEntries; count++, pIRec++) { + printf ("\t0x%4x\t%f\n", pIRec->value, pIRec->intensity); + } + } + if (pScreenData->pBlueTbl->pBase != pScreenData->pRedTbl->pBase) { + printf ("Intensity Table BLUE %d\n", pScreenData->pBlueTbl->nEntries); + pIRec = (IntensityRec *) pScreenData->pBlueTbl->pBase; + for (count = 0; count < pScreenData->pBlueTbl->nEntries; count++, pIRec++) { + printf ("\t0x%4x\t%f\n", pIRec->value, pIRec->intensity); + } + } +#endif /* ALLDEBUG */ + } + + Xfree ((char *)property_return); + + /* Free the old memory and use the new structure created. */ + LINEAR_RGB_FreeSCCData(pPerScrnInfo->screenData); + + pPerScrnInfo->functionSet = (XPointer) &XcmsLinearRGBFunctionSet; + + pPerScrnInfo->screenData = (XPointer) pScreenData; + + pPerScrnInfo->state = XcmsInitSuccess; + + return(XcmsSuccess); + +FreeBlueTblElements: + Xfree((char *)pScreenData->pBlueTbl->pBase); + +FreeBlueTbl: + Xfree((char *)pScreenData->pBlueTbl); + +FreeGreenTblElements: + Xfree((char *)pScreenData->pBlueTbl->pBase); + +FreeGreenTbl: + Xfree((char *)pScreenData->pGreenTbl); + +FreeRedTblElements: + Xfree((char *)pScreenData->pRedTbl->pBase); + +FreeRedTbl: + Xfree((char *)pScreenData->pRedTbl); + +Free_property_return: + Xfree ((char *)property_return); + +FreeSCCData: + Xfree((char *)pScreenData); + pPerScrnInfo->state = XcmsInitNone; + return(XcmsFailure); +} + + +/* + * NAME + * LINEAR_RGB_FreeSCCData() + * + * SYNOPSIS + */ +static void +LINEAR_RGB_FreeSCCData( + XPointer pScreenDataTemp) +/* + * DESCRIPTION + * + * RETURNS + * 0 if failed. + * 1 if succeeded with no modifications. + * + */ +{ + LINEAR_RGB_SCCData *pScreenData = (LINEAR_RGB_SCCData *) pScreenDataTemp; + + if (pScreenData && pScreenData != &Default_RGB_SCCData) { + if (pScreenData->pRedTbl) { + if (pScreenData->pGreenTbl) { + if (pScreenData->pRedTbl->pBase != + pScreenData->pGreenTbl->pBase) { + if (pScreenData->pGreenTbl->pBase) { + Xfree ((char *)pScreenData->pGreenTbl->pBase); + } + } + if (pScreenData->pGreenTbl != pScreenData->pRedTbl) { + Xfree ((char *)pScreenData->pGreenTbl); + } + } + if (pScreenData->pBlueTbl) { + if (pScreenData->pRedTbl->pBase != + pScreenData->pBlueTbl->pBase) { + if (pScreenData->pBlueTbl->pBase) { + Xfree ((char *)pScreenData->pBlueTbl->pBase); + } + } + if (pScreenData->pBlueTbl != pScreenData->pRedTbl) { + Xfree ((char *)pScreenData->pBlueTbl); + } + } + if (pScreenData->pRedTbl->pBase) { + Xfree ((char *)pScreenData->pRedTbl->pBase); + } + Xfree ((char *)pScreenData->pRedTbl); + } + Xfree ((char *)pScreenData); + } +} + + + +/************************************************************************ + * * + * API PRIVATE ROUTINES * + * * + ************************************************************************/ + +/* + * NAME + * _XcmsGetTableType0 + * + * SYNOPSIS + */ +static Status +_XcmsGetTableType0( + IntensityTbl *pTbl, + int format, + char **pChar, + unsigned long *pCount) +/* + * DESCRIPTION + * + * RETURNS + * XcmsFailure if failed. + * XcmsSuccess if succeeded. + * + */ +{ + unsigned int nElements; + IntensityRec *pIRec; + + nElements = pTbl->nEntries = + _XcmsGetElement(format, pChar, pCount) + 1; + if (!(pIRec = pTbl->pBase = (IntensityRec *) + Xcalloc (nElements, sizeof(IntensityRec)))) { + return(XcmsFailure); + } + + switch (format) { + case 8: + for (; nElements--; pIRec++) { + /* 0xFFFF/0xFF = 0x101 */ + pIRec->value = _XcmsGetElement (format, pChar, pCount) * 0x101; + pIRec->intensity = + _XcmsGetElement (format, pChar, pCount) / (XcmsFloat)255.0; + } + break; + case 16: + for (; nElements--; pIRec++) { + pIRec->value = _XcmsGetElement (format, pChar, pCount); + pIRec->intensity = _XcmsGetElement (format, pChar, pCount) + / (XcmsFloat)65535.0; + } + break; + case 32: + for (; nElements--; pIRec++) { + pIRec->value = _XcmsGetElement (format, pChar, pCount); + pIRec->intensity = _XcmsGetElement (format, pChar, pCount) + / (XcmsFloat)4294967295.0; + } + break; + default: + return(XcmsFailure); + } + return(XcmsSuccess); +} + + +/* + * NAME + * _XcmsGetTableType1 + * + * SYNOPSIS + */ +static Status +_XcmsGetTableType1( + IntensityTbl *pTbl, + int format, + char **pChar, + unsigned long *pCount) +/* + * DESCRIPTION + * + * RETURNS + * XcmsFailure if failed. + * XcmsSuccess if succeeded. + * + */ +{ + int count; + unsigned int max_index; + IntensityRec *pIRec; + + max_index = _XcmsGetElement(format, pChar, pCount); + pTbl->nEntries = max_index + 1; + if (!(pIRec = pTbl->pBase = (IntensityRec *) + Xcalloc (max_index+1, sizeof(IntensityRec)))) { + return(XcmsFailure); + } + + switch (format) { + case 8: + for (count = 0; count < max_index+1; count++, pIRec++) { + pIRec->value = (count * 65535) / max_index; + pIRec->intensity = _XcmsGetElement (format, pChar, pCount) + / (XcmsFloat)255.0; + } + break; + case 16: + for (count = 0; count < max_index+1; count++, pIRec++) { + pIRec->value = (count * 65535) / max_index; + pIRec->intensity = _XcmsGetElement (format, pChar, pCount) + / (XcmsFloat)65535.0; + } + break; + case 32: + for (count = 0; count < max_index+1; count++, pIRec++) { + pIRec->value = (count * 65535) / max_index; + pIRec->intensity = _XcmsGetElement (format, pChar, pCount) + / (XcmsFloat)4294967295.0; + } + break; + default: + return(XcmsFailure); + } + + return(XcmsSuccess); +} + + +/* + * NAME + * ValueCmp + * + * SYNOPSIS + */ +static int +_XcmsValueCmp( + IntensityRec *p1, IntensityRec *p2) +/* + * DESCRIPTION + * Compares the value component of two IntensityRec + * structures. + * + * RETURNS + * 0 if p1->value is equal to p2->value + * < 0 if p1->value is less than p2->value + * > 0 if p1->value is greater than p2->value + * + */ +{ + return (p1->value - p2->value); +} + + +/* + * NAME + * IntensityCmp + * + * SYNOPSIS + */ +static int +_XcmsIntensityCmp( + IntensityRec *p1, IntensityRec *p2) +/* + * DESCRIPTION + * Compares the intensity component of two IntensityRec + * structures. + * + * RETURNS + * 0 if equal; + * < 0 if first precedes second + * > 0 if first succeeds second + * + */ +{ + if (p1->intensity < p2->intensity) { + return (-1); + } + if (p1->intensity > p2->intensity) { + return (XcmsSuccess); + } + return (XcmsFailure); +} + +/* + * NAME + * ValueInterpolation + * + * SYNOPSIS + */ +/* ARGSUSED */ +static int +_XcmsValueInterpolation( + IntensityRec *key, IntensityRec *lo, IntensityRec *hi, IntensityRec *answer, + int bitsPerRGB) +/* + * DESCRIPTION + * Based on a given value, performs a linear interpolation + * on the intensities between two IntensityRec structures. + * Note that the bitsPerRGB parameter is ignored. + * + * RETURNS + * Returns 0 if failed; otherwise non-zero. + */ +{ + XcmsFloat ratio; + + ratio = ((XcmsFloat)key->value - (XcmsFloat)lo->value) / + ((XcmsFloat)hi->value - (XcmsFloat)lo->value); + answer->value = key->value; + answer->intensity = (hi->intensity - lo->intensity) * ratio; + answer->intensity += lo->intensity; + return (XcmsSuccess); +} + +/* + * NAME + * IntensityInterpolation + * + * SYNOPSIS + */ +static int +_XcmsIntensityInterpolation( + IntensityRec *key, IntensityRec *lo, IntensityRec *hi, IntensityRec *answer, + int bitsPerRGB) +/* + * DESCRIPTION + * Based on a given intensity, performs a linear interpolation + * on the values between two IntensityRec structures. + * The bitsPerRGB parameter is necessary to perform rounding + * to the correct number of significant bits. + * + * RETURNS + * Returns 0 if failed; otherwise non-zero. + */ +{ + XcmsFloat ratio; + long target, up, down; + int shift = 16 - bitsPerRGB; + int max_color = (1 << bitsPerRGB) - 1; + + ratio = (key->intensity - lo->intensity) / (hi->intensity - lo->intensity); + answer->intensity = key->intensity; + target = hi->value - lo->value; + target *= ratio; + target += lo->value; + + /* + * Ok now, lets find the closest in respects to bits per RGB + */ + up = ((target >> shift) * 0xFFFF) / max_color; + if (up < target) { + down = up; + up = (MIN((down >> shift) + 1, max_color) * 0xFFFF) / max_color; + } else { + down = (MAX((up >> shift) - 1, 0) * 0xFFFF) / max_color; + } + answer->value = ((up - target) < (target - down) ? up : down); + answer->value &= MASK[bitsPerRGB]; + return (XcmsSuccess); +} + + + +typedef int (*comparProcp)( + char *p1, + char *p2); +typedef int (*interpolProcp)( + char *key, + char *lo, + char *hi, + char *answer, + int bitsPerRGB); + +/* + * NAME + * _XcmsTableSearch + * + * SYNOPSIS + */ +static int +_XcmsTableSearch( + char *key, + int bitsPerRGB, + char *base, + unsigned nel, + unsigned nKeyPtrSize, + int (*compar)( + char *p1, + char *p2), + int (*interpol)( + char *key, + char *lo, + char *hi, + char *answer, + int bitsPerRGB), + char *answer) + +/* + * DESCRIPTION + * A binary search through the specificied table. + * + * RETURNS + * Returns 0 if failed; otherwise non-zero. + * + */ +{ + char *hi, *lo, *mid, *last; + int result; + + last = hi = base + ((nel - 1) * nKeyPtrSize); + mid = lo = base; + + /* use only the significants bits, then scale into 16 bits */ + ((IntensityRec *)key)->value = ((unsigned long) + (((IntensityRec *)key)->value >> (16 - bitsPerRGB)) * 0xFFFF) + / ((1 << bitsPerRGB) - 1); + + /* Special case so that zero intensity always maps to zero value */ + if ((*compar) (key,lo) <= 0) { + memcpy (answer, lo, nKeyPtrSize); + ((IntensityRec *)answer)->value &= MASK[bitsPerRGB]; + return XcmsSuccess; + } + while (mid != last) { + last = mid; + mid = lo + (((unsigned)(hi - lo) / nKeyPtrSize) / 2) * nKeyPtrSize; + result = (*compar) (key, mid); + if (result == 0) { + + memcpy(answer, mid, nKeyPtrSize); + ((IntensityRec *)answer)->value &= MASK[bitsPerRGB]; + return (XcmsSuccess); + } else if (result < 0) { + hi = mid; + } else { + lo = mid; + } + } + + /* + * If we got to here, we didn't find a solution, so we + * need to apply interpolation. + */ + return ((*interpol)(key, lo, hi, answer, bitsPerRGB)); +} + + +/* + * NAME + * _XcmsMatVec - multiply a 3 x 3 by a 3 x 1 vector + * + * SYNOPSIS + */ +static void _XcmsMatVec( + XcmsFloat *pMat, XcmsFloat *pIn, XcmsFloat *pOut) +/* + * DESCRIPTION + * Multiply the passed vector by the passed matrix to return a + * vector. Matrix is 3x3, vectors are of length 3. + * + * RETURNS + * void + */ +{ + int i, j; + + for (i = 0; i < 3; i++) { + pOut[i] = 0.0; + for (j = 0; j < 3; j++) + pOut[i] += *(pMat+(i*3)+j) * pIn[j]; + } +} + + +/************************************************************************ + * * + * PUBLIC ROUTINES * + * * + ************************************************************************/ + + +/* + * NAME + * XcmsLRGB_RGB_ParseString + * + * SYNOPSIS + */ +static int +XcmsLRGB_RGB_ParseString( + register char *spec, + XcmsColor *pColor) +/* + * DESCRIPTION + * This routines takes a string and attempts to convert + * it into a XcmsColor structure with XcmsRGBFormat. + * + * RETURNS + * 0 if failed, non-zero otherwise. + */ +{ + register int n, i; + unsigned short r, g, b; + char c; + char *pchar; + unsigned short *pShort; + + /* + * Check for old # format + */ + if (*spec == '#') { + /* + * Attempt to parse the value portion. + */ + spec++; + n = strlen(spec); + if (n != 3 && n != 6 && n != 9 && n != 12) { + return(XcmsFailure); + } + + n /= 3; + g = b = 0; + do { + r = g; + g = b; + b = 0; + for (i = n; --i >= 0; ) { + c = *spec++; + b <<= 4; + if (c >= '0' && c <= '9') + b |= c - '0'; + /* assume string in lowercase + else if (c >= 'A' && c <= 'F') + b |= c - ('A' - 10); + */ + else if (c >= 'a' && c <= 'f') + b |= c - ('a' - 10); + else return (XcmsFailure); + } + } while (*spec != '\0'); + + /* + * Succeeded ! + */ + n <<= 2; + n = 16 - n; + /* shift instead of scale, to match old broken semantics */ + pColor->spec.RGB.red = r << n; + pColor->spec.RGB.green = g << n; + pColor->spec.RGB.blue = b << n; + } else { + if ((pchar = strchr(spec, ':')) == NULL) { + return(XcmsFailure); + } + n = (int)(pchar - spec); + + /* + * Check for proper prefix. + */ + if (strncmp(spec, _XcmsRGB_prefix, n) != 0) { + return(XcmsFailure); + } + + /* + * Attempt to parse the value portion. + */ + spec += (n + 1); + pShort = &pColor->spec.RGB.red; + for (i = 0; i < 3; i++, pShort++, spec++) { + n = 0; + *pShort = 0; + while (*spec != '/' && *spec != '\0') { + if (++n > 4) { + return(XcmsFailure); + } + c = *spec++; + *pShort <<= 4; + if (c >= '0' && c <= '9') + *pShort |= c - '0'; + /* assume string in lowercase + else if (c >= 'A' && c <= 'F') + *pShort |= c - ('A' - 10); + */ + else if (c >= 'a' && c <= 'f') + *pShort |= c - ('a' - 10); + else return (XcmsFailure); + } + if (n == 0) + return (XcmsFailure); + if (n < 4) { + *pShort = ((unsigned long)*pShort * 0xFFFF) / ((1 << n*4) - 1); + } + } + } + pColor->format = XcmsRGBFormat; + pColor->pixel = 0; + return (XcmsSuccess); +} + + +/* + * NAME + * XcmsLRGB_RGBi_ParseString + * + * SYNOPSIS + */ +static int +XcmsLRGB_RGBi_ParseString( + register char *spec, + XcmsColor *pColor) +/* + * DESCRIPTION + * This routines takes a string and attempts to convert + * it into a XcmsColor structure with XcmsRGBiFormat. + * The assumed RGBi string syntax is: + * RGBi:// + * Where r, g, and b are in string input format for floats + * consisting of: + * a. an optional sign + * b. a string of numbers possibly containing a decimal point, + * c. an optional exponent field containing an 'E' or 'e' + * followed by a possibly signed integer string. + * + * RETURNS + * 0 if failed, non-zero otherwise. + */ +{ + int n; + char *pchar; + + if ((pchar = strchr(spec, ':')) == NULL) { + return(XcmsFailure); + } + n = (int)(pchar - spec); + + /* + * Check for proper prefix. + */ + if (strncmp(spec, _XcmsRGBi_prefix, n) != 0) { + return(XcmsFailure); + } + + /* + * Attempt to parse the value portion. + */ + if (sscanf(spec + n + 1, "%lf/%lf/%lf", + &pColor->spec.RGBi.red, + &pColor->spec.RGBi.green, + &pColor->spec.RGBi.blue) != 3) { + char *s; /* Maybe failed due to locale */ + int f; + if ((s = strdup(spec))) { + for (f = 0; s[f]; ++f) + if (s[f] == '.') + s[f] = ','; + else if (s[f] == ',') + s[f] = '.'; + if (sscanf(s + n + 1, "%lf/%lf/%lf", + &pColor->spec.RGBi.red, + &pColor->spec.RGBi.green, + &pColor->spec.RGBi.blue) != 3) { + free(s); + return(XcmsFailure); + } + free(s); + } else + return(XcmsFailure); + } + + /* + * Succeeded ! + */ + pColor->format = XcmsRGBiFormat; + pColor->pixel = 0; + return (XcmsSuccess); +} + + +/* + * NAME + * XcmsCIEXYZToRGBi - convert CIE XYZ to RGB + * + * SYNOPSIS + */ +/* ARGSUSED */ +Status +XcmsCIEXYZToRGBi( + XcmsCCC ccc, + XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ + unsigned int nColors, /* Number of colors */ + Bool *pCompressed) /* pointer to an array of Bool */ +/* + * DESCRIPTION + * Converts color specifications in an array of XcmsColor + * structures from RGB format to RGBi format. + * + * RETURNS + * XcmsFailure if failed, + * XcmsSuccess if succeeded without gamut compression. + * XcmsSuccessWithCompression if succeeded with gamut + * compression. + */ +{ + LINEAR_RGB_SCCData *pScreenData; + XcmsFloat tmp[3]; + int hasCompressed = 0; + unsigned int i; + XcmsColor *pColor = pXcmsColors_in_out; + + if (ccc == NULL) { + return(XcmsFailure); + } + + pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; + + /* + * XcmsColors should be White Point Adjusted, if necessary, by now! + */ + + /* + * NEW!!! for extended gamut compression + * + * 1. Need to zero out pCompressed + * + * 2. Need to save initial address of pColor + * + * 3. Need to save initial address of pCompressed + */ + + for (i = 0; i < nColors; i++) { + + /* Make sure format is XcmsCIEXYZFormat */ + if (pColor->format != XcmsCIEXYZFormat) { + return(XcmsFailure); + } + + /* Multiply [A]-1 * [XYZ] to get RGB intensity */ + _XcmsMatVec((XcmsFloat *) pScreenData->XYZtoRGBmatrix, + (XcmsFloat *) &pColor->spec, tmp); + + if ((MIN3 (tmp[0], tmp[1], tmp[2]) < -EPS) || + (MAX3 (tmp[0], tmp[1], tmp[2]) > (1.0 + EPS))) { + + /* + * RGBi out of screen's gamut + */ + + if (ccc->gamutCompProc == NULL) { + /* + * Aha!! Here's that little trick that will allow + * gamut compression routines to get the out of bound + * RGBi. + */ + memcpy((char *)&pColor->spec, (char *)tmp, sizeof(tmp)); + pColor->format = XcmsRGBiFormat; + return(XcmsFailure); + } else if ((*ccc->gamutCompProc)(ccc, pXcmsColors_in_out, nColors, + i, pCompressed) == 0) { + return(XcmsFailure); + } + + /* + * The gamut compression function should return colors in CIEXYZ + * Also check again to if the new color is within gamut. + */ + if (pColor->format != XcmsCIEXYZFormat) { + return(XcmsFailure); + } + _XcmsMatVec((XcmsFloat *) pScreenData->XYZtoRGBmatrix, + (XcmsFloat *) &pColor->spec, tmp); + if ((MIN3 (tmp[0], tmp[1], tmp[2]) < -EPS) || + (MAX3 (tmp[0], tmp[1], tmp[2]) > (1.0 + EPS))) { + return(XcmsFailure); + } + hasCompressed++; + } + memcpy((char *)&pColor->spec, (char *)tmp, sizeof(tmp)); + /* These if statements are done to ensure the fudge factor is */ + /* is taken into account. */ + if (pColor->spec.RGBi.red < 0.0) { + pColor->spec.RGBi.red = 0.0; + } else if (pColor->spec.RGBi.red > 1.0) { + pColor->spec.RGBi.red = 1.0; + } + if (pColor->spec.RGBi.green < 0.0) { + pColor->spec.RGBi.green = 0.0; + } else if (pColor->spec.RGBi.green > 1.0) { + pColor->spec.RGBi.green = 1.0; + } + if (pColor->spec.RGBi.blue < 0.0) { + pColor->spec.RGBi.blue = 0.0; + } else if (pColor->spec.RGBi.blue > 1.0) { + pColor->spec.RGBi.blue = 1.0; + } + (pColor++)->format = XcmsRGBiFormat; + } + return (hasCompressed ? XcmsSuccessWithCompression : XcmsSuccess); +} + + +/* + * NAME + * LINEAR_RGBi_to_CIEXYZ - convert RGBi to CIEXYZ + * + * SYNOPSIS + */ +/* ARGSUSED */ +Status +XcmsRGBiToCIEXYZ( + XcmsCCC ccc, + XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ + unsigned int nColors, /* Number of colors */ + Bool *pCompressed) /* pointer to a bit array */ +/* + * DESCRIPTION + * Converts color specifications in an array of XcmsColor + * structures from RGBi format to CIEXYZ format. + * + * RETURNS + * XcmsFailure if failed, + * XcmsSuccess if succeeded. + */ +{ + LINEAR_RGB_SCCData *pScreenData; + XcmsFloat tmp[3]; + + /* + * pCompressed ignored in this function. + */ + + if (ccc == NULL) { + return(XcmsFailure); + } + + pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; + + /* + * XcmsColors should be White Point Adjusted, if necessary, by now! + */ + + while (nColors--) { + + /* Multiply [A]-1 * [XYZ] to get RGB intensity */ + _XcmsMatVec((XcmsFloat *) pScreenData->RGBtoXYZmatrix, + (XcmsFloat *) &pXcmsColors_in_out->spec, tmp); + + memcpy((char *)&pXcmsColors_in_out->spec, (char *)tmp, sizeof(tmp)); + (pXcmsColors_in_out++)->format = XcmsCIEXYZFormat; + } + return(XcmsSuccess); +} + + +/* + * NAME + * XcmsRGBiToRGB + * + * SYNOPSIS + */ +/* ARGSUSED */ +Status +XcmsRGBiToRGB( + XcmsCCC ccc, + XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ + unsigned int nColors, /* Number of colors */ + Bool *pCompressed) /* pointer to a bit array */ +/* + * DESCRIPTION + * Converts color specifications in an array of XcmsColor + * structures from RGBi format to RGB format. + * + * RETURNS + * XcmsFailure if failed, + * XcmsSuccess if succeeded without gamut compression. + * XcmsSuccessWithCompression if succeeded with gamut + * compression. + */ +{ + LINEAR_RGB_SCCData *pScreenData; + XcmsRGB tmpRGB; + IntensityRec keyIRec, answerIRec; + + /* + * pCompressed ignored in this function. + */ + + if (ccc == NULL) { + return(XcmsFailure); + } + + pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; + + while (nColors--) { + + /* Make sure format is XcmsRGBiFormat */ + if (pXcmsColors_in_out->format != XcmsRGBiFormat) { + return(XcmsFailure); + } + + keyIRec.intensity = pXcmsColors_in_out->spec.RGBi.red; + if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, + (char *)pScreenData->pRedTbl->pBase, + (unsigned)pScreenData->pRedTbl->nEntries, + (unsigned)sizeof(IntensityRec), + (comparProcp)_XcmsIntensityCmp, (interpolProcp)_XcmsIntensityInterpolation, (char *)&answerIRec)) { + return(XcmsFailure); + } + tmpRGB.red = answerIRec.value; + + keyIRec.intensity = pXcmsColors_in_out->spec.RGBi.green; + if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, + (char *)pScreenData->pGreenTbl->pBase, + (unsigned)pScreenData->pGreenTbl->nEntries, + (unsigned)sizeof(IntensityRec), + (comparProcp)_XcmsIntensityCmp, (interpolProcp)_XcmsIntensityInterpolation, (char *)&answerIRec)) { + return(XcmsFailure); + } + tmpRGB.green = answerIRec.value; + + keyIRec.intensity = pXcmsColors_in_out->spec.RGBi.blue; + if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, + (char *)pScreenData->pBlueTbl->pBase, + (unsigned)pScreenData->pBlueTbl->nEntries, + (unsigned)sizeof(IntensityRec), + (comparProcp)_XcmsIntensityCmp, (interpolProcp)_XcmsIntensityInterpolation, (char *)&answerIRec)) { + return(XcmsFailure); + } + tmpRGB.blue = answerIRec.value; + + memcpy((char *)&pXcmsColors_in_out->spec, (char *)&tmpRGB, sizeof(XcmsRGB)); + (pXcmsColors_in_out++)->format = XcmsRGBFormat; + } + return(XcmsSuccess); +} + + +/* + * NAME + * XcmsRGBToRGBi + * + * SYNOPSIS + */ +/* ARGSUSED */ +Status +XcmsRGBToRGBi( + XcmsCCC ccc, + XcmsColor *pXcmsColors_in_out,/* pointer to XcmsColors to convert */ + unsigned int nColors, /* Number of colors */ + Bool *pCompressed) /* pointer to a bit array */ +/* + * DESCRIPTION + * Converts color specifications in an array of XcmsColor + * structures from RGB format to RGBi format. + * + * RETURNS + * XcmsFailure if failed, + * XcmsSuccess if succeeded. + */ +{ + LINEAR_RGB_SCCData *pScreenData; + XcmsRGBi tmpRGBi; + IntensityRec keyIRec, answerIRec; + + /* + * pCompressed ignored in this function. + */ + + if (ccc == NULL) { + return(XcmsFailure); + } + + pScreenData = (LINEAR_RGB_SCCData *)ccc->pPerScrnInfo->screenData; + + while (nColors--) { + + /* Make sure format is XcmsRGBFormat */ + if (pXcmsColors_in_out->format != XcmsRGBFormat) { + return(XcmsFailure); + } + + keyIRec.value = pXcmsColors_in_out->spec.RGB.red; + if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, + (char *)pScreenData->pRedTbl->pBase, + (unsigned)pScreenData->pRedTbl->nEntries, + (unsigned)sizeof(IntensityRec), + (comparProcp)_XcmsValueCmp, (interpolProcp)_XcmsValueInterpolation, (char *)&answerIRec)) { + return(XcmsFailure); + } + tmpRGBi.red = answerIRec.intensity; + + keyIRec.value = pXcmsColors_in_out->spec.RGB.green; + if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, + (char *)pScreenData->pGreenTbl->pBase, + (unsigned)pScreenData->pGreenTbl->nEntries, + (unsigned)sizeof(IntensityRec), + (comparProcp)_XcmsValueCmp, (interpolProcp)_XcmsValueInterpolation, (char *)&answerIRec)) { + return(XcmsFailure); + } + tmpRGBi.green = answerIRec.intensity; + + keyIRec.value = pXcmsColors_in_out->spec.RGB.blue; + if (!_XcmsTableSearch((char *)&keyIRec, ccc->visual->bits_per_rgb, + (char *)pScreenData->pBlueTbl->pBase, + (unsigned)pScreenData->pBlueTbl->nEntries, + (unsigned)sizeof(IntensityRec), + (comparProcp)_XcmsValueCmp, (interpolProcp)_XcmsValueInterpolation, (char *)&answerIRec)) { + return(XcmsFailure); + } + tmpRGBi.blue = answerIRec.intensity; + + memcpy((char *)&pXcmsColors_in_out->spec, (char *)&tmpRGBi, sizeof(XcmsRGBi)); + (pXcmsColors_in_out++)->format = XcmsRGBiFormat; + } + return(XcmsSuccess); +} + +/* + * NAME + * _XcmsInitScrnDefaultInfo + * + * SYNOPSIS + */ +/* ARGSUSED */ +int +_XcmsLRGB_InitScrnDefault( + Display *dpy, + int screenNumber, + XcmsPerScrnInfo *pPerScrnInfo) +/* + * DESCRIPTION + * Given a display and screen number, this routine attempts + * to initialize the Xcms per Screen Info structure + * (XcmsPerScrnInfo) with defaults. + * + * RETURNS + * Returns zero if initialization failed; non-zero otherwise. + */ +{ + pPerScrnInfo->screenData = (XPointer)&Default_RGB_SCCData; + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.X = + Default_RGB_SCCData.RGBtoXYZmatrix[0][0] + + Default_RGB_SCCData.RGBtoXYZmatrix[0][1] + + Default_RGB_SCCData.RGBtoXYZmatrix[0][2]; + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = + Default_RGB_SCCData.RGBtoXYZmatrix[1][0] + + Default_RGB_SCCData.RGBtoXYZmatrix[1][1] + + Default_RGB_SCCData.RGBtoXYZmatrix[1][2]; + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Z = + Default_RGB_SCCData.RGBtoXYZmatrix[2][0] + + Default_RGB_SCCData.RGBtoXYZmatrix[2][1] + + Default_RGB_SCCData.RGBtoXYZmatrix[2][2]; + if ((pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y < (1.0 - EPS) ) + || (pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y > (1.0 + EPS))) { + pPerScrnInfo->screenData = (XPointer)NULL; + pPerScrnInfo->state = XcmsInitNone; + return(0); + } + pPerScrnInfo->screenWhitePt.spec.CIEXYZ.Y = 1.0; + pPerScrnInfo->screenWhitePt.format = XcmsCIEXYZFormat; + pPerScrnInfo->screenWhitePt.pixel = 0; + pPerScrnInfo->functionSet = (XPointer)&XcmsLinearRGBFunctionSet; + pPerScrnInfo->state = XcmsInitFailure; /* default initialization */ + return(1); +} diff --git a/libX11/src/xcms/cmsColNm.c b/libX11/src/xcms/cmsColNm.c index 41643703e..8518adfd1 100644 --- a/libX11/src/xcms/cmsColNm.c +++ b/libX11/src/xcms/cmsColNm.c @@ -567,7 +567,7 @@ stringSectionSize( return(XcmsFailure); } - while((pBuf = fgets(buf, XCMSDB_MAXLINELEN, stream)) != NULL) { + while((fgets(buf, XCMSDB_MAXLINELEN, stream)) != NULL) { if ((sscanf(buf, "%s", token)) && (strcmp(token, END_TOKEN) == 0)) { break; } @@ -651,7 +651,7 @@ ReadColornameDB( * Process lines between START_TOKEN to END_TOKEN */ - while ((pBuf = fgets(buf, XCMSDB_MAXLINELEN, stream)) != NULL) { + while ((fgets(buf, XCMSDB_MAXLINELEN, stream)) != NULL) { if ((sscanf(buf, "%s", token)) && (strcmp(token, END_TOKEN) == 0)) { /* * Found END_TOKEN so break out of for loop diff --git a/libX11/src/xlibi18n/XDefaultOMIF.c b/libX11/src/xlibi18n/XDefaultOMIF.c index c7511e608..ae8ac79e4 100644 --- a/libX11/src/xlibi18n/XDefaultOMIF.c +++ b/libX11/src/xlibi18n/XDefaultOMIF.c @@ -1,1282 +1,1276 @@ -/* -Copyright 1985, 1986, 1987, 1991, 1998 The Open Group - -Permission is hereby granted, free of charge, to any person obtaining a -copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: The above copyright notice and this -permission notice shall be included in all copies or substantial -portions of the Software. - - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE -EVEN IF ADVISED IN ADVANCE OF THE POSSIBILITY OF SUCH DAMAGES. - - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - - -X Window System is a trademark of The Open Group - -OSF/1, OSF/Motif and Motif are registered trademarks, and OSF, the OSF -logo, LBX, X Window System, and Xinerama are trademarks of the Open -Group. All other trademarks and registered trademarks mentioned herein -are the property of their respective owners. No right, title or -interest in or to any trademark, service mark, logo or trade name of -Sun Microsystems, Inc. or its licensors is granted. - -*/ -/* - * Copyright 2000 Oracle and/or its affiliates. All rights reserved. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - */ - - -#ifdef HAVE_CONFIG_H -#include -#endif -#include "Xlibint.h" -#include "Xlcint.h" -#include "XlcPublic.h" -#include -#include -#include - -#define MAXFONTS 100 - -#define XOM_GENERIC(om) (&((XOMGeneric) om)->gen) -#define XOC_GENERIC(font_set) (&((XOCGeneric) font_set)->gen) - -#define DefineLocalBuf char local_buf[BUFSIZ] -#define AllocLocalBuf(length) (length > BUFSIZ ? (char *)Xmalloc(length) : local_buf) -#define FreeLocalBuf(ptr) if (ptr != local_buf) Xfree(ptr) - -typedef struct _FontDataRec { - char *name; -} FontDataRec, *FontData; - -typedef struct _OMDataRec { - int font_data_count; - FontData font_data; -} OMDataRec, *OMData; - -typedef struct _XOMGenericPart { - OMData data; -} XOMGenericPart; - -typedef struct _XOMGenericRec { - XOMMethods methods; - XOMCoreRec core; - XOMGenericPart gen; -} XOMGenericRec, *XOMGeneric; - -typedef struct _FontSetRec { - int id; - int font_data_count; - FontData font_data; - char *font_name; - XFontStruct *info; - XFontStruct *font; -} FontSetRec, *FontSet; - -typedef struct _XOCGenericPart { - XlcConv wcs_to_cs; - FontSet font_set; -} XOCGenericPart; - -typedef struct _XOCGenericRec { - XOCMethods methods; - XOCCoreRec core; - XOCGenericPart gen; -} XOCGenericRec, *XOCGeneric; - -static Bool -init_fontset( - XOC oc) -{ - XOCGenericPart *gen; - FontSet font_set; - OMData data; - - data = XOM_GENERIC(oc->core.om)->data; - - font_set = (FontSet) Xmalloc(sizeof(FontSetRec)); - if (font_set == NULL) - return False; - bzero((char *) font_set, sizeof(FontSetRec)); - - gen = XOC_GENERIC(oc); - gen->font_set = font_set; - - font_set->font_data_count = data->font_data_count; - font_set->font_data = data->font_data; - - return True; -} - -static char * -get_prop_name( - Display *dpy, - XFontStruct *fs) -{ - unsigned long fp; - - if (XGetFontProperty(fs, XA_FONT, &fp)) - return XGetAtomName(dpy, fp); - - return (char *) NULL; -} - -static FontData -check_charset( - FontSet font_set, - char *font_name) -{ - FontData font_data; - char *last; - int count; - ssize_t length, name_len; - - name_len = strlen(font_name); - last = font_name + name_len; - - count = font_set->font_data_count; - font_data = font_set->font_data; - - for ( ; count-- > 0; font_data++) { - length = strlen(font_data->name); - - if (length > name_len) - return(NULL); - - if (_XlcCompareISOLatin1(last - length, font_data->name) == 0) - return font_data; - } - return (FontData) NULL; -} - -#if 0 /* Unused */ -static int -check_fontname( - XOC oc, - char *name) -{ - Display *dpy = oc->core.om->core.display; - XOCGenericPart *gen = XOC_GENERIC(oc); - FontData data; - FontSet font_set; - XFontStruct *fs_list; - char **fn_list, *fname, *prop_fname = NULL; - int list_num, i; - int list2_num; - char **fn2_list = NULL; - int found_num = 0; - - fn_list = XListFonts(dpy, name, MAXFONTS, &list_num); - if (fn_list == NULL) - return found_num; - - for (i = 0; i < list_num; i++) { - fname = fn_list[i]; - - font_set = gen->font_set; - - if ((data = check_charset(font_set, fname)) == NULL) { - if ((fn2_list = XListFontsWithInfo(dpy, name, MAXFONTS, - &list2_num, &fs_list)) - && (prop_fname = get_prop_name(dpy, fs_list)) - && (data = check_charset(font_set, prop_fname))) - fname = prop_fname; - } - if (data) { - font_set->font_name = (char *) Xmalloc(strlen(fname) + 1); - if (font_set->font_name) { - strcpy(font_set->font_name, fname); - found_num++; - } - } - if (fn2_list) { - XFreeFontInfo(fn2_list, fs_list, list2_num); - fn2_list = NULL; - if (prop_fname) { - Xfree(prop_fname); - prop_fname = NULL; - } - } - if (found_num == 1) - break; - } - XFreeFontNames(fn_list); - return found_num; -} -#endif - -static Bool -load_font( - XOC oc) -{ - Display *dpy = oc->core.om->core.display; - XOCGenericPart *gen = XOC_GENERIC(oc); - FontSet font_set = gen->font_set; - - if (font_set->font_name == NULL) - return False; - - if (font_set->font == NULL) { - font_set->font = XLoadQueryFont(dpy, font_set->font_name); - if (font_set->font == NULL) - return False; - } - return True; -} - -#if 0 -static Bool -load_font_info( - XOC oc) -{ - Display *dpy = oc->core.om->core.display; - XOCGenericPart *gen = XOC_GENERIC(oc); - FontSet font_set = gen->font_set; - char **fn_list; - int fn_num; - - if (font_set->font_name == NULL) - return False; - - if (font_set->info == NULL) { - fn_list = XListFontsWithInfo(dpy, font_set->font_name, 1, &fn_num, - &font_set->info); - if (font_set->info == NULL) - return False; - if (fn_num > 0) - font_set->info->fid = XLoadFont(dpy, font_set->font_name); - - if (fn_list) XFreeFontNames(fn_list); - } - return True; -} -#endif - -static void -set_fontset_extents( - XOC oc) -{ - XRectangle *ink = &oc->core.font_set_extents.max_ink_extent; - XRectangle *logical = &oc->core.font_set_extents.max_logical_extent; - XFontStruct **font_list, *font; - XCharStruct overall; - int logical_ascent, logical_descent; - - font_list = oc->core.font_info.font_struct_list; - font = *font_list++; - overall = font->max_bounds; - overall.lbearing = font->min_bounds.lbearing; - logical_ascent = font->ascent; - logical_descent = font->descent; - - ink->x = overall.lbearing; - ink->y = -(overall.ascent); - ink->width = overall.rbearing - overall.lbearing; - ink->height = overall.ascent + overall.descent; - - logical->x = 0; - logical->y = -(logical_ascent); - logical->width = overall.width; - logical->height = logical_ascent + logical_descent; -} - -static Bool -init_core_part( - XOC oc) -{ - XOCGenericPart *gen = XOC_GENERIC(oc); - FontSet font_set; - XFontStruct **font_struct_list; - char **font_name_list, *font_name_buf; - int count, length; - - font_set = gen->font_set; - count = length = 0; - - if (font_set->font_name != NULL) { - length += strlen(font_set->font_name) + 1; - count++; - } - if (count == 0) - return False; - - font_struct_list = (XFontStruct **) Xmalloc(sizeof(XFontStruct *)); - if (font_struct_list == NULL) - return False; - - font_name_list = (char **) Xmalloc(sizeof(char *)); - if (font_name_list == NULL) - goto err; - - font_name_buf = (char *) Xmalloc(length); - if (font_name_buf == NULL) - goto err; - - oc->core.font_info.num_font = 1; - oc->core.font_info.font_name_list = font_name_list; - oc->core.font_info.font_struct_list = font_struct_list; - - font_set = gen->font_set; - - if (font_set->font_name != NULL) { - font_set->id = 1; - if (font_set->font) - *font_struct_list++ = font_set->font; - else - *font_struct_list++ = font_set->info; - strcpy(font_name_buf, font_set->font_name); - Xfree(font_set->font_name); - *font_name_list++ = font_set->font_name = font_name_buf; - font_name_buf += strlen(font_name_buf) + 1; - } - - set_fontset_extents(oc); - - return True; - -err: - if (font_name_list) - Xfree(font_name_list); - Xfree(font_struct_list); - - return False; -} - -static char * -get_font_name( - XOC oc, - char *pattern) -{ - char **list, *name, *prop_name; - int count; - XFontStruct *fs; - Display *dpy = oc->core.om->core.display; - - list = XListFonts(dpy, pattern, 1, &count); - if (list != NULL) { - name = (char *) Xmalloc(strlen(*list) + 1); - if (name) - strcpy(name, *list); - - XFreeFontNames(list); - } else { - fs = XLoadQueryFont(dpy, pattern); - if (fs == NULL) return NULL; - - prop_name = get_prop_name(dpy, fs); - if (prop_name == NULL) return NULL; - - name = (char*) Xmalloc(strlen(prop_name) + 1); - if (name) - strcpy(name, prop_name); - - XFreeFont(dpy, fs); - } - return name; -} - -static int -parse_fontname( - XOC oc) -{ - XOCGenericPart *gen = XOC_GENERIC(oc); - FontSet font_set; - FontData font_data; - char *pattern, *last, buf[BUFSIZ]; - int font_data_count, found_num = 0; - ssize_t length; - int count, num_fields; - char *base_name, *font_name, **name_list, **cur_name_list; - char *charset_p = NULL; - Bool append_charset; - /* - append_charset flag should be set to True when the XLFD fontname - doesn't contain a chaset part. - */ - - name_list = _XParseBaseFontNameList(oc->core.base_name_list, &count); - if (name_list == NULL) - return -1; - cur_name_list = name_list; - - while (count-- > 0) { - pattern = *cur_name_list++; - if (pattern == NULL || *pattern == '\0') - continue; - - append_charset = False; - - if (strchr(pattern, '*') == NULL && - (font_name = get_font_name(oc, pattern))) { - - font_set = gen->font_set; - - font_data = check_charset(font_set, font_name); - if (font_data == NULL) { - Display *dpy = oc->core.om->core.display; - char **fn_list = NULL, *prop_fname = NULL; - int list_num; - XFontStruct *fs_list; - if ((fn_list = XListFontsWithInfo(dpy, font_name, - MAXFONTS, - &list_num, &fs_list)) - && (prop_fname = get_prop_name(dpy, fs_list)) - && (font_data = check_charset(font_set, prop_fname))) { - if (fn_list) { - XFreeFontInfo(fn_list, fs_list, list_num); - fn_list = NULL; - } - font_name = prop_fname; - } - } - if (font_data == NULL) - continue; - - font_set->font_name = (char *) Xmalloc(strlen(font_name) + 1); - if (font_set->font_name == NULL) { - Xfree(font_name); - goto err; - } - strcpy(font_set->font_name, font_name); - Xfree(font_name); - found_num++; - goto found; - } -/* -1266793 -Limit the length of the string copy to prevent stack corruption. - strcpy(buf, pattern); -*/ - strncpy(buf, pattern, BUFSIZ); - buf[BUFSIZ-1] = '\0'; - length = strlen(buf); - last = buf + length - 1; - - for (num_fields = 0, base_name = buf; *base_name != '\0'; base_name++) - if (*base_name == '-') num_fields++; - if (strchr(pattern, '*') == NULL) { - if (num_fields == 12) { - append_charset = True; - *++last = '-'; - last++; - } else - continue; - } else { - if (num_fields == 13 || num_fields == 14) { - /* - * There are 14 fields in an XLFD name -- make certain the - * charset (& encoding) is placed in the correct field. - */ - append_charset = True; - last = strrchr (buf, '-'); - if (num_fields == 14) { - *last = '\0'; - last = strrchr (buf, '-'); - } - last++; - } else if (*last == '*') { - append_charset = True; - if (length > 3 && *(last-3) == '-' && *(last-2) == '*' - && *(last-1) == '-') { - last -= 2; - } - *++last = '-'; - last++; - } else { - last = strrchr (buf, '-'); - charset_p = last; - charset_p = strrchr (buf, '-'); - while (*(--charset_p) != '-'); - charset_p++; - } - } - - font_set = gen->font_set; - - font_data = font_set->font_data; - font_data_count = font_set->font_data_count; - for ( ; font_data_count-- > 0; font_data++) { - if (append_charset) - { -/* -1266793 -Limit the length of the string copy to prevent stack corruption. - strcpy(last, font_data->name); -*/ - strncpy(last, font_data->name, BUFSIZ - length); - buf[BUFSIZ-1] = '\0'; - } - else { - if (_XlcCompareISOLatin1(charset_p, - font_data->name)) { - continue; - } - } - if ((font_set->font_name = get_font_name(oc, buf))) - break; - } - if (font_set->font_name != NULL) { - found_num++; - goto found; - } - } - found: - base_name = (char *) Xmalloc(strlen(oc->core.base_name_list) + 1); - if (base_name == NULL) - goto err; - - strcpy(base_name, oc->core.base_name_list); - oc->core.base_name_list = base_name; - - XFreeStringList(name_list); - - return found_num; -err: - XFreeStringList(name_list); - - return -1; -} - -static Bool -set_missing_list( - XOC oc) -{ - XOCGenericPart *gen = XOC_GENERIC(oc); - FontSet font_set; - char **charset_list, *charset_buf; - int count, length; - - font_set = gen->font_set; - count = length = 0; - - if (!font_set->info && !font_set->font) { - length += strlen(font_set->font_data->name) + 1; - count++; - } - - if (count == 0) - return True; - - charset_list = (char **) Xmalloc(sizeof(char *)); - if (charset_list == NULL) - return False; - - charset_buf = (char *) Xmalloc(length); - if (charset_buf == NULL) { - Xfree(charset_list); - return False; - } - - oc->core.missing_list.charset_list = charset_list; - - font_set = gen->font_set; - - if (!font_set->info && !font_set->font) { - strcpy(charset_buf, font_set->font_data->name); - *charset_list++ = charset_buf; - charset_buf += strlen(charset_buf) + 1; - } - return True; -} - -static Bool -create_fontset( - XOC oc) -{ - int found_num; - - if (init_fontset(oc) == False) - return False; - - found_num = parse_fontname(oc); - if (found_num <= 0) { - if (found_num == 0) - set_missing_list(oc); - return False; - } - - if (load_font(oc) == False) - return False; - - if (init_core_part(oc) == False) - return False; - - if (set_missing_list(oc) == False) - return False; - - return True; -} - -static void -destroy_oc( - XOC oc) -{ - Display *dpy = oc->core.om->core.display; - XOCGenericPart *gen = XOC_GENERIC(oc); - XFontStruct **font_list, *font; - - if (gen->font_set) - Xfree(gen->font_set); - - if (oc->core.base_name_list) - Xfree(oc->core.base_name_list); - - if (oc->core.font_info.font_name_list) - XFreeStringList(oc->core.font_info.font_name_list); - - if ((font_list = oc->core.font_info.font_struct_list)) { - if ((font = *font_list)) { - if (font->fid) - XFreeFont(dpy, font); - else - XFreeFontInfo(NULL, font, 1); - } - Xfree(oc->core.font_info.font_struct_list); - } - - if (oc->core.missing_list.charset_list) - XFreeStringList(oc->core.missing_list.charset_list); - -#ifdef notdef - if (oc->core.res_name) - Xfree(oc->core.res_name); - if (oc->core.res_class) - Xfree(oc->core.res_class); -#endif - - Xfree(oc); -} - -static char * -set_oc_values( - XOC oc, - XlcArgList args, - int num_args) -{ - if (oc->core.resources == NULL) - return NULL; - - return _XlcSetValues((XPointer) oc, oc->core.resources, - oc->core.num_resources, args, num_args, XlcSetMask); -} - -static char * -get_oc_values( - XOC oc, - XlcArgList args, - int num_args) -{ - if (oc->core.resources == NULL) - return NULL; - - return _XlcGetValues((XPointer) oc, oc->core.resources, - oc->core.num_resources, args, num_args, XlcGetMask); -} - -static Bool -wcs_to_mbs( - XOC oc, - char *to, - _Xconst wchar_t *from, - int length) -{ - XlcConv conv = XOC_GENERIC(oc)->wcs_to_cs; - XLCd lcd; - int ret, to_left = length; - - if (conv == NULL) { - lcd = oc->core.om->core.lcd; - conv = _XlcOpenConverter(lcd, XlcNWideChar, lcd, XlcNMultiByte); - if (conv == NULL) - return False; - XOC_GENERIC(oc)->wcs_to_cs = conv; - } else - _XlcResetConverter(conv); - - ret = _XlcConvert(conv, (XPointer *) &from, &length, (XPointer *) &to, - &to_left, NULL, 0); - if (ret != 0 || length > 0) - return False; - - return True; -} - -static int -_XmbDefaultTextEscapement(XOC oc, _Xconst char *text, int length) -{ - return XTextWidth(*oc->core.font_info.font_struct_list, text, length); -} - -static int -_XwcDefaultTextEscapement(XOC oc, _Xconst wchar_t *text, int length) -{ - DefineLocalBuf; - char *buf = AllocLocalBuf(length); - int ret = 0; - - if (buf == NULL) - return 0; - - if (wcs_to_mbs(oc, buf, text, length) == False) - goto err; - - ret = _XmbDefaultTextEscapement(oc, buf, length); - -err: - FreeLocalBuf(buf); - - return ret; -} - -static int -_XmbDefaultTextExtents(XOC oc, _Xconst char *text, int length, - XRectangle *overall_ink, XRectangle *overall_logical) -{ - int direction, logical_ascent, logical_descent; - XCharStruct overall; - - XTextExtents(*oc->core.font_info.font_struct_list, text, length, &direction, - &logical_ascent, &logical_descent, &overall); - - if (overall_ink) { - overall_ink->x = overall.lbearing; - overall_ink->y = -(overall.ascent); - overall_ink->width = overall.rbearing - overall.lbearing; - overall_ink->height = overall.ascent + overall.descent; - } - - if (overall_logical) { - overall_logical->x = 0; - overall_logical->y = -(logical_ascent); - overall_logical->width = overall.width; - overall_logical->height = logical_ascent + logical_descent; - } - - return overall.width; -} - -static int -_XwcDefaultTextExtents(XOC oc, _Xconst wchar_t *text, int length, - XRectangle *overall_ink, XRectangle *overall_logical) -{ - DefineLocalBuf; - char *buf = AllocLocalBuf(length); - int ret = 0; - - if (buf == NULL) - return 0; - - if (wcs_to_mbs(oc, buf, text, length) == False) - goto err; - - ret = _XmbDefaultTextExtents(oc, buf, length, overall_ink, overall_logical); - -err: - FreeLocalBuf(buf); - - return ret; -} - -static Status -_XmbDefaultTextPerCharExtents(XOC oc, _Xconst char *text, int length, - XRectangle *ink_buf, XRectangle *logical_buf, - int buf_size, int *num_chars, - XRectangle *overall_ink, - XRectangle *overall_logical) -{ - XFontStruct *font = *oc->core.font_info.font_struct_list; - XCharStruct *def, *cs, overall; - Bool first = True; - - if (buf_size < length) - return 0; - - bzero((char *) &overall, sizeof(XCharStruct)); - *num_chars = 0; - - CI_GET_DEFAULT_INFO_1D(font, def) - - while (length-- > 0) { - CI_GET_CHAR_INFO_1D(font, *text, def, cs) - text++; - if (cs == NULL) - continue; - - ink_buf->x = overall.width + cs->lbearing; - ink_buf->y = -(cs->ascent); - ink_buf->width = cs->rbearing - cs->lbearing; - ink_buf->height = cs->ascent + cs->descent; - ink_buf++; - - logical_buf->x = overall.width; - logical_buf->y = -(font->ascent); - logical_buf->width = cs->width; - logical_buf->height = font->ascent + font->descent; - logical_buf++; - - if (first) { - overall = *cs; - first = False; - } else { - overall.ascent = max(overall.ascent, cs->ascent); - overall.descent = max(overall.descent, cs->descent); - overall.lbearing = min(overall.lbearing, overall.width + - cs->lbearing); - overall.rbearing = max(overall.rbearing, overall.width + - cs->rbearing); - overall.width += cs->width; - } - (*num_chars)++; - } - - if (overall_ink) { - overall_ink->x = overall.lbearing; - overall_ink->y = -(overall.ascent); - overall_ink->width = overall.rbearing - overall.lbearing; - overall_ink->height = overall.ascent + overall.descent; - } - - if (overall_logical) { - overall_logical->x = 0; - overall_logical->y = -(font->ascent); - overall_logical->width = overall.width; - overall_logical->height = font->ascent + font->descent; - } - - return 1; -} - -static Status -_XwcDefaultTextPerCharExtents(XOC oc, _Xconst wchar_t *text, int length, - XRectangle *ink_buf, XRectangle *logical_buf, - int buf_size, int *num_chars, - XRectangle *overall_ink, - XRectangle *overall_logical) -{ - DefineLocalBuf; - char *buf = AllocLocalBuf(length); - Status ret = 0; - - if (buf == NULL) - return 0; - - if (wcs_to_mbs(oc, buf, text, length) == False) - goto err; - - ret = _XmbDefaultTextPerCharExtents(oc, buf, length, ink_buf, logical_buf, - buf_size, num_chars, overall_ink, - overall_logical); - -err: - FreeLocalBuf(buf); - - return ret; -} - -static int -_XmbDefaultDrawString(Display *dpy, Drawable d, XOC oc, GC gc, int x, int y, - _Xconst char *text, int length) -{ - XFontStruct *font = *oc->core.font_info.font_struct_list; - - XSetFont(dpy, gc, font->fid); - XDrawString(dpy, d, gc, x, y, text, length); - - return XTextWidth(font, text, length); -} - -static int -_XwcDefaultDrawString(Display *dpy, Drawable d, XOC oc, GC gc, int x, int y, - _Xconst wchar_t *text, int length) -{ - DefineLocalBuf; - char *buf = AllocLocalBuf(length); - int ret = 0; - - if (buf == NULL) - return 0; - - if (wcs_to_mbs(oc, buf, text, length) == False) - goto err; - - ret = _XmbDefaultDrawString(dpy, d, oc, gc, x, y, buf, length); - -err: - FreeLocalBuf(buf); - - return ret; -} - -static void -_XmbDefaultDrawImageString(Display *dpy, Drawable d, XOC oc, GC gc, int x, - int y, _Xconst char *text, int length) -{ - XSetFont(dpy, gc, (*oc->core.font_info.font_struct_list)->fid); - XDrawImageString(dpy, d, gc, x, y, text, length); -} - -static void -_XwcDefaultDrawImageString(Display *dpy, Drawable d, XOC oc, GC gc, int x, - int y, _Xconst wchar_t *text, int length) -{ - DefineLocalBuf; - char *buf = AllocLocalBuf(length); - - if (buf == NULL) - return; - - if (wcs_to_mbs(oc, buf, text, length) == False) - goto err; - - _XmbDefaultDrawImageString(dpy, d, oc, gc, x, y, buf, length); - -err: - FreeLocalBuf(buf); -} - -static _Xconst XOCMethodsRec oc_default_methods = { - destroy_oc, - set_oc_values, - get_oc_values, - _XmbDefaultTextEscapement, - _XmbDefaultTextExtents, - _XmbDefaultTextPerCharExtents, - _XmbDefaultDrawString, - _XmbDefaultDrawImageString, - _XwcDefaultTextEscapement, - _XwcDefaultTextExtents, - _XwcDefaultTextPerCharExtents, - _XwcDefaultDrawString, - _XwcDefaultDrawImageString -}; - -static XlcResource oc_resources[] = { - { XNBaseFontName, NULLQUARK, sizeof(char *), - XOffsetOf(XOCRec, core.base_name_list), XlcCreateMask | XlcGetMask }, - { XNOMAutomatic, NULLQUARK, sizeof(Bool), - XOffsetOf(XOCRec, core.om_automatic), XlcGetMask }, - { XNMissingCharSet, NULLQUARK, sizeof(XOMCharSetList), - XOffsetOf(XOCRec, core.missing_list), XlcGetMask }, - { XNDefaultString, NULLQUARK, sizeof(char *), - XOffsetOf(XOCRec, core.default_string), XlcGetMask }, - { XNOrientation, NULLQUARK, sizeof(XOrientation), - XOffsetOf(XOCRec, core.orientation), XlcSetMask | XlcGetMask }, - { XNResourceName, NULLQUARK, sizeof(char *), - XOffsetOf(XOCRec, core.res_name), XlcSetMask | XlcGetMask }, - { XNResourceClass, NULLQUARK, sizeof(char *), - XOffsetOf(XOCRec, core.res_class), XlcSetMask | XlcGetMask }, - { XNFontInfo, NULLQUARK, sizeof(XOMFontInfo), - XOffsetOf(XOCRec, core.font_info), XlcGetMask } -}; - -static XOC -create_oc( - XOM om, - XlcArgList args, - int num_args) -{ - XOC oc; - - oc = (XOC) Xmalloc(sizeof(XOCGenericRec)); - if (oc == NULL) - return (XOC) NULL; - bzero((char *) oc, sizeof(XOCGenericRec)); - - oc->core.om = om; - - if (oc_resources[0].xrm_name == NULLQUARK) - _XlcCompileResourceList(oc_resources, XlcNumber(oc_resources)); - - if (_XlcSetValues((XPointer) oc, oc_resources, XlcNumber(oc_resources), - args, num_args, XlcCreateMask | XlcDefaultMask)) - goto err; - - if (oc->core.base_name_list == NULL) - goto err; - - oc->core.resources = oc_resources; - oc->core.num_resources = XlcNumber(oc_resources); - - if (create_fontset(oc) == False) - goto err; - - oc->methods = (XOCMethods)&oc_default_methods; - - return oc; - -err: - destroy_oc(oc); - - return (XOC) NULL; -} - -static Status -close_om( - XOM om) -{ - XOMGenericPart *gen = XOM_GENERIC(om); - OMData data; - FontData font_data; - int count; - - if ((data = gen->data)) { - if (data->font_data) { - for (font_data = data->font_data, count = data->font_data_count; - count-- > 0 ; font_data++) { - if (font_data->name) - Xfree(font_data->name); - } - Xfree(data->font_data); - } - Xfree(gen->data); - } - - if (om->core.res_name) - Xfree(om->core.res_name); - if (om->core.res_class) - Xfree(om->core.res_class); - if (om->core.required_charset.charset_list) - XFreeStringList(om->core.required_charset.charset_list); - else - Xfree((char*)om->core.required_charset.charset_list); - if (om->core.orientation_list.orientation) - Xfree(om->core.orientation_list.orientation); - - Xfree(om); - - return 1; -} - -static char * -set_om_values( - XOM om, - XlcArgList args, - int num_args) -{ - if (om->core.resources == NULL) - return NULL; - - return _XlcSetValues((XPointer) om, om->core.resources, - om->core.num_resources, args, num_args, XlcSetMask); -} - -static char * -get_om_values( - XOM om, - XlcArgList args, - int num_args) -{ - if (om->core.resources == NULL) - return NULL; - - return _XlcGetValues((XPointer) om, om->core.resources, - om->core.num_resources, args, num_args, XlcGetMask); -} - -static _Xconst XOMMethodsRec methods = { - close_om, - set_om_values, - get_om_values, - create_oc -}; - -static XlcResource om_resources[] = { - { XNRequiredCharSet, NULLQUARK, sizeof(XOMCharSetList), - XOffsetOf(XOMRec, core.required_charset), XlcGetMask }, - { XNQueryOrientation, NULLQUARK, sizeof(XOMOrientation), - XOffsetOf(XOMRec, core.orientation_list), XlcGetMask }, - { XNDirectionalDependentDrawing, NULLQUARK, sizeof(Bool), - XOffsetOf(XOMRec, core.directional_dependent), XlcGetMask }, - { XNContextualDrawing, NULLQUARK, sizeof(Bool), - XOffsetOf(XOMRec, core.contextual_drawing), XlcGetMask } -}; - -static OMData -add_data( - XOM om) -{ - XOMGenericPart *gen = XOM_GENERIC(om); - OMData new; - - new = (OMData) Xmalloc(sizeof(OMDataRec)); - - if (new == NULL) - return NULL; - - gen->data = new; - - bzero((char *) new, sizeof(OMDataRec)); - - return new; -} - -static _Xconst char *supported_charset_list[] = { - "ISO8859-1", -/* fix for bug4332979 */ - "adobe-fontspecific", -/* fix for bug4237353: "JISX0201.1976-0" entry should be removed from - supported_charset_list because it is not a supported_charset for C locale - "JISX0201.1976-0", */ - "SUNOLCURSOR-1", - "SUNOLGLYPH-1" -}; - -static Bool -init_om( - XOM om) -{ - XOMGenericPart *gen = XOM_GENERIC(om); - OMData data; - FontData font_data; - char **required_list; - XOrientation *orientation; - char **value, buf[BUFSIZ], *bufptr; - int count, length = 0; - - value = (char**)supported_charset_list; - count = XlcNumber(supported_charset_list); - - data = add_data(om); - if (data == NULL) - return False; - - font_data = (FontData) Xmalloc(sizeof(FontDataRec) * count); - if (font_data == NULL) - return False; - bzero((char *) font_data, sizeof(FontDataRec) * count); - data->font_data = font_data; - data->font_data_count = count; - - for ( ; count-- > 0; font_data++) { -/* -1266793 -This one is fine. *value points to one of the local strings in -supported_charset_list[]. -*/ - strcpy(buf, *value++); - font_data->name = (char *) Xmalloc(strlen(buf) + 1); - if (font_data->name == NULL) - return False; - strcpy(font_data->name, buf); - } - - length += strlen(data->font_data->name) + 1; - - /* required charset list */ - required_list = (char **) Xmalloc(sizeof(char *)); - if (required_list == NULL) - return False; - - bufptr = (char *) Xmalloc(length); - if (bufptr == NULL) { - Xfree(required_list); - return False; - } - - om->core.required_charset.charset_list = required_list; - om->core.required_charset.charset_count = 1; /* always 1 */ - - data = gen->data; - - strcpy(bufptr, data->font_data->name); - *required_list++ = bufptr; - bufptr += strlen(bufptr) + 1; - - /* orientation list */ - orientation = (XOrientation *) Xmalloc(sizeof(XOrientation)); - if (orientation == NULL) - return False; - - *orientation = XOMOrientation_LTR_TTB; - om->core.orientation_list.orientation = orientation; - om->core.orientation_list.num_orientation = 1; - - /* directional dependent drawing */ - om->core.directional_dependent = False; - - /* contexual drawing */ - om->core.contextual_drawing = False; - - /* context dependent */ - om->core.context_dependent = False; - - return True; -} - -XOM -_XDefaultOpenOM(XLCd lcd, Display *dpy, XrmDatabase rdb, - _Xconst char *res_name, _Xconst char *res_class) -{ - XOM om; - - om = (XOM) Xmalloc(sizeof(XOMGenericRec)); - if (om == NULL) - return (XOM) NULL; - bzero((char *) om, sizeof(XOMGenericRec)); - - om->methods = (XOMMethods)&methods; - om->core.lcd = lcd; - om->core.display = dpy; - om->core.rdb = rdb; - if (res_name) { - om->core.res_name = (char *)Xmalloc(strlen(res_name) + 1); - if (om->core.res_name == NULL) - goto err; - strcpy(om->core.res_name, res_name); - } - if (res_class) { - om->core.res_class = (char *)Xmalloc(strlen(res_class) + 1); - if (om->core.res_class == NULL) - goto err; - strcpy(om->core.res_class, res_class); - } - - if (om_resources[0].xrm_name == NULLQUARK) - _XlcCompileResourceList(om_resources, XlcNumber(om_resources)); - - om->core.resources = om_resources; - om->core.num_resources = XlcNumber(om_resources); - - if (init_om(om) == False) - goto err; - - return om; -err: - close_om(om); - - return (XOM) NULL; -} +/* +Copyright 1985, 1986, 1987, 1991, 1998 The Open Group + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: The above copyright notice and this +permission notice shall be included in all copies or substantial +portions of the Software. + + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE +EVEN IF ADVISED IN ADVANCE OF THE POSSIBILITY OF SUCH DAMAGES. + + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + + +X Window System is a trademark of The Open Group + +OSF/1, OSF/Motif and Motif are registered trademarks, and OSF, the OSF +logo, LBX, X Window System, and Xinerama are trademarks of the Open +Group. All other trademarks and registered trademarks mentioned herein +are the property of their respective owners. No right, title or +interest in or to any trademark, service mark, logo or trade name of +Sun Microsystems, Inc. or its licensors is granted. + +*/ +/* + * Copyright 2000 Oracle and/or its affiliates. All rights reserved. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + + +#ifdef HAVE_CONFIG_H +#include +#endif +#include "Xlibint.h" +#include "Xlcint.h" +#include "XlcPublic.h" +#include +#include +#include + +#define MAXFONTS 100 + +#define XOM_GENERIC(om) (&((XOMGeneric) om)->gen) +#define XOC_GENERIC(font_set) (&((XOCGeneric) font_set)->gen) + +#define DefineLocalBuf char local_buf[BUFSIZ] +#define AllocLocalBuf(length) (length > BUFSIZ ? (char *)Xmalloc(length) : local_buf) +#define FreeLocalBuf(ptr) if (ptr != local_buf) Xfree(ptr) + +typedef struct _FontDataRec { + char *name; +} FontDataRec, *FontData; + +typedef struct _OMDataRec { + int font_data_count; + FontData font_data; +} OMDataRec, *OMData; + +typedef struct _XOMGenericPart { + OMData data; +} XOMGenericPart; + +typedef struct _XOMGenericRec { + XOMMethods methods; + XOMCoreRec core; + XOMGenericPart gen; +} XOMGenericRec, *XOMGeneric; + +typedef struct _FontSetRec { + int id; + int font_data_count; + FontData font_data; + char *font_name; + XFontStruct *info; + XFontStruct *font; +} FontSetRec, *FontSet; + +typedef struct _XOCGenericPart { + XlcConv wcs_to_cs; + FontSet font_set; +} XOCGenericPart; + +typedef struct _XOCGenericRec { + XOCMethods methods; + XOCCoreRec core; + XOCGenericPart gen; +} XOCGenericRec, *XOCGeneric; + +static Bool +init_fontset( + XOC oc) +{ + XOCGenericPart *gen; + FontSet font_set; + OMData data; + + data = XOM_GENERIC(oc->core.om)->data; + + font_set = (FontSet) Xmalloc(sizeof(FontSetRec)); + if (font_set == NULL) + return False; + bzero((char *) font_set, sizeof(FontSetRec)); + + gen = XOC_GENERIC(oc); + gen->font_set = font_set; + + font_set->font_data_count = data->font_data_count; + font_set->font_data = data->font_data; + + return True; +} + +static char * +get_prop_name( + Display *dpy, + XFontStruct *fs) +{ + unsigned long fp; + + if (XGetFontProperty(fs, XA_FONT, &fp)) + return XGetAtomName(dpy, fp); + + return (char *) NULL; +} + +static FontData +check_charset( + FontSet font_set, + char *font_name) +{ + FontData font_data; + char *last; + int count; + ssize_t length, name_len; + + name_len = strlen(font_name); + last = font_name + name_len; + + count = font_set->font_data_count; + font_data = font_set->font_data; + + for ( ; count-- > 0; font_data++) { + length = strlen(font_data->name); + + if (length > name_len) + return(NULL); + + if (_XlcCompareISOLatin1(last - length, font_data->name) == 0) + return font_data; + } + return (FontData) NULL; +} + +#if 0 /* Unused */ +static int +check_fontname( + XOC oc, + char *name) +{ + Display *dpy = oc->core.om->core.display; + XOCGenericPart *gen = XOC_GENERIC(oc); + FontData data; + FontSet font_set; + XFontStruct *fs_list; + char **fn_list, *fname, *prop_fname = NULL; + int list_num, i; + int list2_num; + char **fn2_list = NULL; + int found_num = 0; + + fn_list = XListFonts(dpy, name, MAXFONTS, &list_num); + if (fn_list == NULL) + return found_num; + + for (i = 0; i < list_num; i++) { + fname = fn_list[i]; + + font_set = gen->font_set; + + if ((data = check_charset(font_set, fname)) == NULL) { + if ((fn2_list = XListFontsWithInfo(dpy, name, MAXFONTS, + &list2_num, &fs_list)) + && (prop_fname = get_prop_name(dpy, fs_list)) + && (data = check_charset(font_set, prop_fname))) + fname = prop_fname; + } + if (data) { + font_set->font_name = (char *) Xmalloc(strlen(fname) + 1); + if (font_set->font_name) { + strcpy(font_set->font_name, fname); + found_num++; + } + } + if (fn2_list) { + XFreeFontInfo(fn2_list, fs_list, list2_num); + fn2_list = NULL; + if (prop_fname) { + Xfree(prop_fname); + prop_fname = NULL; + } + } + if (found_num == 1) + break; + } + XFreeFontNames(fn_list); + return found_num; +} +#endif + +static Bool +load_font( + XOC oc) +{ + Display *dpy = oc->core.om->core.display; + XOCGenericPart *gen = XOC_GENERIC(oc); + FontSet font_set = gen->font_set; + + if (font_set->font_name == NULL) + return False; + + if (font_set->font == NULL) { + font_set->font = XLoadQueryFont(dpy, font_set->font_name); + if (font_set->font == NULL) + return False; + } + return True; +} + +#if 0 +static Bool +load_font_info( + XOC oc) +{ + Display *dpy = oc->core.om->core.display; + XOCGenericPart *gen = XOC_GENERIC(oc); + FontSet font_set = gen->font_set; + char **fn_list; + int fn_num; + + if (font_set->font_name == NULL) + return False; + + if (font_set->info == NULL) { + fn_list = XListFontsWithInfo(dpy, font_set->font_name, 1, &fn_num, + &font_set->info); + if (font_set->info == NULL) + return False; + if (fn_num > 0) + font_set->info->fid = XLoadFont(dpy, font_set->font_name); + + if (fn_list) XFreeFontNames(fn_list); + } + return True; +} +#endif + +static void +set_fontset_extents( + XOC oc) +{ + XRectangle *ink = &oc->core.font_set_extents.max_ink_extent; + XRectangle *logical = &oc->core.font_set_extents.max_logical_extent; + XFontStruct **font_list, *font; + XCharStruct overall; + int logical_ascent, logical_descent; + + font_list = oc->core.font_info.font_struct_list; + font = *font_list++; + overall = font->max_bounds; + overall.lbearing = font->min_bounds.lbearing; + logical_ascent = font->ascent; + logical_descent = font->descent; + + ink->x = overall.lbearing; + ink->y = -(overall.ascent); + ink->width = overall.rbearing - overall.lbearing; + ink->height = overall.ascent + overall.descent; + + logical->x = 0; + logical->y = -(logical_ascent); + logical->width = overall.width; + logical->height = logical_ascent + logical_descent; +} + +static Bool +init_core_part( + XOC oc) +{ + XOCGenericPart *gen = XOC_GENERIC(oc); + FontSet font_set; + XFontStruct **font_struct_list; + char **font_name_list, *font_name_buf; + int count, length; + + font_set = gen->font_set; + count = length = 0; + + if (font_set->font_name != NULL) { + length += strlen(font_set->font_name) + 1; + count++; + } + if (count == 0) + return False; + + font_struct_list = (XFontStruct **) Xmalloc(sizeof(XFontStruct *)); + if (font_struct_list == NULL) + return False; + + font_name_list = (char **) Xmalloc(sizeof(char *)); + if (font_name_list == NULL) + goto err; + + font_name_buf = (char *) Xmalloc(length); + if (font_name_buf == NULL) + goto err; + + oc->core.font_info.num_font = 1; + oc->core.font_info.font_name_list = font_name_list; + oc->core.font_info.font_struct_list = font_struct_list; + + font_set = gen->font_set; + + if (font_set->font_name != NULL) { + font_set->id = 1; + if (font_set->font) + *font_struct_list++ = font_set->font; + else + *font_struct_list++ = font_set->info; + strcpy(font_name_buf, font_set->font_name); + Xfree(font_set->font_name); + *font_name_list++ = font_set->font_name = font_name_buf; + font_name_buf += strlen(font_name_buf) + 1; + } + + set_fontset_extents(oc); + + return True; + +err: + if (font_name_list) + Xfree(font_name_list); + Xfree(font_struct_list); + + return False; +} + +static char * +get_font_name( + XOC oc, + char *pattern) +{ + char **list, *name; + int count; + XFontStruct *fs; + Display *dpy = oc->core.om->core.display; + + list = XListFonts(dpy, pattern, 1, &count); + if (list != NULL) { + name = (char *) Xmalloc(strlen(*list) + 1); + if (name) + strcpy(name, *list); + + XFreeFontNames(list); + } else { + fs = XLoadQueryFont(dpy, pattern); + if (fs == NULL) return NULL; + + name = get_prop_name(dpy, fs); + XFreeFont(dpy, fs); + } + return name; +} + +static int +parse_fontname( + XOC oc) +{ + XOCGenericPart *gen = XOC_GENERIC(oc); + FontSet font_set; + FontData font_data; + char *pattern, *last, buf[BUFSIZ]; + int font_data_count, found_num = 0; + ssize_t length; + int count, num_fields; + char *base_name, *font_name, **name_list, **cur_name_list; + char *charset_p = NULL; + Bool append_charset; + /* + append_charset flag should be set to True when the XLFD fontname + doesn't contain a chaset part. + */ + + name_list = _XParseBaseFontNameList(oc->core.base_name_list, &count); + if (name_list == NULL) + return -1; + cur_name_list = name_list; + + while (count-- > 0) { + pattern = *cur_name_list++; + if (pattern == NULL || *pattern == '\0') + continue; + + append_charset = False; + + if (strchr(pattern, '*') == NULL && + (font_name = get_font_name(oc, pattern))) { + + font_set = gen->font_set; + + font_data = check_charset(font_set, font_name); + if (font_data == NULL) { + Display *dpy = oc->core.om->core.display; + char **fn_list = NULL, *prop_fname = NULL; + int list_num; + XFontStruct *fs_list; + if ((fn_list = XListFontsWithInfo(dpy, font_name, + MAXFONTS, + &list_num, &fs_list)) + && (prop_fname = get_prop_name(dpy, fs_list)) + && (font_data = check_charset(font_set, prop_fname))) { + if (fn_list) { + XFreeFontInfo(fn_list, fs_list, list_num); + fn_list = NULL; + } + font_name = prop_fname; + } + } + if (font_data == NULL) + continue; + + font_set->font_name = (char *) Xmalloc(strlen(font_name) + 1); + if (font_set->font_name == NULL) { + Xfree(font_name); + goto err; + } + strcpy(font_set->font_name, font_name); + Xfree(font_name); + found_num++; + goto found; + } +/* +1266793 +Limit the length of the string copy to prevent stack corruption. + strcpy(buf, pattern); +*/ + strncpy(buf, pattern, BUFSIZ); + buf[BUFSIZ-1] = '\0'; + length = strlen(buf); + last = buf + length - 1; + + for (num_fields = 0, base_name = buf; *base_name != '\0'; base_name++) + if (*base_name == '-') num_fields++; + if (strchr(pattern, '*') == NULL) { + if (num_fields == 12) { + append_charset = True; + *++last = '-'; + last++; + } else + continue; + } else { + if (num_fields == 13 || num_fields == 14) { + /* + * There are 14 fields in an XLFD name -- make certain the + * charset (& encoding) is placed in the correct field. + */ + append_charset = True; + last = strrchr (buf, '-'); + if (num_fields == 14) { + *last = '\0'; + last = strrchr (buf, '-'); + } + last++; + } else if (*last == '*') { + append_charset = True; + if (length > 3 && *(last-3) == '-' && *(last-2) == '*' + && *(last-1) == '-') { + last -= 2; + } + *++last = '-'; + last++; + } else { + last = strrchr (buf, '-'); + charset_p = last; + charset_p = strrchr (buf, '-'); + while (*(--charset_p) != '-'); + charset_p++; + } + } + + font_set = gen->font_set; + + font_data = font_set->font_data; + font_data_count = font_set->font_data_count; + for ( ; font_data_count-- > 0; font_data++) { + if (append_charset) + { +/* +1266793 +Limit the length of the string copy to prevent stack corruption. + strcpy(last, font_data->name); +*/ + strncpy(last, font_data->name, BUFSIZ - length); + buf[BUFSIZ-1] = '\0'; + } + else { + if (_XlcCompareISOLatin1(charset_p, + font_data->name)) { + continue; + } + } + if ((font_set->font_name = get_font_name(oc, buf))) + break; + } + if (font_set->font_name != NULL) { + found_num++; + goto found; + } + } + found: + base_name = (char *) Xmalloc(strlen(oc->core.base_name_list) + 1); + if (base_name == NULL) + goto err; + + strcpy(base_name, oc->core.base_name_list); + oc->core.base_name_list = base_name; + + XFreeStringList(name_list); + + return found_num; +err: + XFreeStringList(name_list); + + return -1; +} + +static Bool +set_missing_list( + XOC oc) +{ + XOCGenericPart *gen = XOC_GENERIC(oc); + FontSet font_set; + char **charset_list, *charset_buf; + int count, length; + + font_set = gen->font_set; + count = length = 0; + + if (!font_set->info && !font_set->font) { + length += strlen(font_set->font_data->name) + 1; + count++; + } + + if (count == 0) + return True; + + charset_list = (char **) Xmalloc(sizeof(char *)); + if (charset_list == NULL) + return False; + + charset_buf = (char *) Xmalloc(length); + if (charset_buf == NULL) { + Xfree(charset_list); + return False; + } + + oc->core.missing_list.charset_list = charset_list; + + font_set = gen->font_set; + + if (!font_set->info && !font_set->font) { + strcpy(charset_buf, font_set->font_data->name); + *charset_list++ = charset_buf; + charset_buf += strlen(charset_buf) + 1; + } + return True; +} + +static Bool +create_fontset( + XOC oc) +{ + int found_num; + + if (init_fontset(oc) == False) + return False; + + found_num = parse_fontname(oc); + if (found_num <= 0) { + if (found_num == 0) + set_missing_list(oc); + return False; + } + + if (load_font(oc) == False) + return False; + + if (init_core_part(oc) == False) + return False; + + if (set_missing_list(oc) == False) + return False; + + return True; +} + +static void +destroy_oc( + XOC oc) +{ + Display *dpy = oc->core.om->core.display; + XOCGenericPart *gen = XOC_GENERIC(oc); + XFontStruct **font_list, *font; + + if (gen->font_set) + Xfree(gen->font_set); + + if (oc->core.base_name_list) + Xfree(oc->core.base_name_list); + + if (oc->core.font_info.font_name_list) + XFreeStringList(oc->core.font_info.font_name_list); + + if ((font_list = oc->core.font_info.font_struct_list)) { + if ((font = *font_list)) { + if (font->fid) + XFreeFont(dpy, font); + else + XFreeFontInfo(NULL, font, 1); + } + Xfree(oc->core.font_info.font_struct_list); + } + + if (oc->core.missing_list.charset_list) + XFreeStringList(oc->core.missing_list.charset_list); + +#ifdef notdef + if (oc->core.res_name) + Xfree(oc->core.res_name); + if (oc->core.res_class) + Xfree(oc->core.res_class); +#endif + + Xfree(oc); +} + +static char * +set_oc_values( + XOC oc, + XlcArgList args, + int num_args) +{ + if (oc->core.resources == NULL) + return NULL; + + return _XlcSetValues((XPointer) oc, oc->core.resources, + oc->core.num_resources, args, num_args, XlcSetMask); +} + +static char * +get_oc_values( + XOC oc, + XlcArgList args, + int num_args) +{ + if (oc->core.resources == NULL) + return NULL; + + return _XlcGetValues((XPointer) oc, oc->core.resources, + oc->core.num_resources, args, num_args, XlcGetMask); +} + +static Bool +wcs_to_mbs( + XOC oc, + char *to, + _Xconst wchar_t *from, + int length) +{ + XlcConv conv = XOC_GENERIC(oc)->wcs_to_cs; + XLCd lcd; + int ret, to_left = length; + + if (conv == NULL) { + lcd = oc->core.om->core.lcd; + conv = _XlcOpenConverter(lcd, XlcNWideChar, lcd, XlcNMultiByte); + if (conv == NULL) + return False; + XOC_GENERIC(oc)->wcs_to_cs = conv; + } else + _XlcResetConverter(conv); + + ret = _XlcConvert(conv, (XPointer *) &from, &length, (XPointer *) &to, + &to_left, NULL, 0); + if (ret != 0 || length > 0) + return False; + + return True; +} + +static int +_XmbDefaultTextEscapement(XOC oc, _Xconst char *text, int length) +{ + return XTextWidth(*oc->core.font_info.font_struct_list, text, length); +} + +static int +_XwcDefaultTextEscapement(XOC oc, _Xconst wchar_t *text, int length) +{ + DefineLocalBuf; + char *buf = AllocLocalBuf(length); + int ret = 0; + + if (buf == NULL) + return 0; + + if (wcs_to_mbs(oc, buf, text, length) == False) + goto err; + + ret = _XmbDefaultTextEscapement(oc, buf, length); + +err: + FreeLocalBuf(buf); + + return ret; +} + +static int +_XmbDefaultTextExtents(XOC oc, _Xconst char *text, int length, + XRectangle *overall_ink, XRectangle *overall_logical) +{ + int direction, logical_ascent, logical_descent; + XCharStruct overall; + + XTextExtents(*oc->core.font_info.font_struct_list, text, length, &direction, + &logical_ascent, &logical_descent, &overall); + + if (overall_ink) { + overall_ink->x = overall.lbearing; + overall_ink->y = -(overall.ascent); + overall_ink->width = overall.rbearing - overall.lbearing; + overall_ink->height = overall.ascent + overall.descent; + } + + if (overall_logical) { + overall_logical->x = 0; + overall_logical->y = -(logical_ascent); + overall_logical->width = overall.width; + overall_logical->height = logical_ascent + logical_descent; + } + + return overall.width; +} + +static int +_XwcDefaultTextExtents(XOC oc, _Xconst wchar_t *text, int length, + XRectangle *overall_ink, XRectangle *overall_logical) +{ + DefineLocalBuf; + char *buf = AllocLocalBuf(length); + int ret = 0; + + if (buf == NULL) + return 0; + + if (wcs_to_mbs(oc, buf, text, length) == False) + goto err; + + ret = _XmbDefaultTextExtents(oc, buf, length, overall_ink, overall_logical); + +err: + FreeLocalBuf(buf); + + return ret; +} + +static Status +_XmbDefaultTextPerCharExtents(XOC oc, _Xconst char *text, int length, + XRectangle *ink_buf, XRectangle *logical_buf, + int buf_size, int *num_chars, + XRectangle *overall_ink, + XRectangle *overall_logical) +{ + XFontStruct *font = *oc->core.font_info.font_struct_list; + XCharStruct *def, *cs, overall; + Bool first = True; + + if (buf_size < length) + return 0; + + bzero((char *) &overall, sizeof(XCharStruct)); + *num_chars = 0; + + CI_GET_DEFAULT_INFO_1D(font, def) + + while (length-- > 0) { + CI_GET_CHAR_INFO_1D(font, *text, def, cs) + text++; + if (cs == NULL) + continue; + + ink_buf->x = overall.width + cs->lbearing; + ink_buf->y = -(cs->ascent); + ink_buf->width = cs->rbearing - cs->lbearing; + ink_buf->height = cs->ascent + cs->descent; + ink_buf++; + + logical_buf->x = overall.width; + logical_buf->y = -(font->ascent); + logical_buf->width = cs->width; + logical_buf->height = font->ascent + font->descent; + logical_buf++; + + if (first) { + overall = *cs; + first = False; + } else { + overall.ascent = max(overall.ascent, cs->ascent); + overall.descent = max(overall.descent, cs->descent); + overall.lbearing = min(overall.lbearing, overall.width + + cs->lbearing); + overall.rbearing = max(overall.rbearing, overall.width + + cs->rbearing); + overall.width += cs->width; + } + (*num_chars)++; + } + + if (overall_ink) { + overall_ink->x = overall.lbearing; + overall_ink->y = -(overall.ascent); + overall_ink->width = overall.rbearing - overall.lbearing; + overall_ink->height = overall.ascent + overall.descent; + } + + if (overall_logical) { + overall_logical->x = 0; + overall_logical->y = -(font->ascent); + overall_logical->width = overall.width; + overall_logical->height = font->ascent + font->descent; + } + + return 1; +} + +static Status +_XwcDefaultTextPerCharExtents(XOC oc, _Xconst wchar_t *text, int length, + XRectangle *ink_buf, XRectangle *logical_buf, + int buf_size, int *num_chars, + XRectangle *overall_ink, + XRectangle *overall_logical) +{ + DefineLocalBuf; + char *buf = AllocLocalBuf(length); + Status ret = 0; + + if (buf == NULL) + return 0; + + if (wcs_to_mbs(oc, buf, text, length) == False) + goto err; + + ret = _XmbDefaultTextPerCharExtents(oc, buf, length, ink_buf, logical_buf, + buf_size, num_chars, overall_ink, + overall_logical); + +err: + FreeLocalBuf(buf); + + return ret; +} + +static int +_XmbDefaultDrawString(Display *dpy, Drawable d, XOC oc, GC gc, int x, int y, + _Xconst char *text, int length) +{ + XFontStruct *font = *oc->core.font_info.font_struct_list; + + XSetFont(dpy, gc, font->fid); + XDrawString(dpy, d, gc, x, y, text, length); + + return XTextWidth(font, text, length); +} + +static int +_XwcDefaultDrawString(Display *dpy, Drawable d, XOC oc, GC gc, int x, int y, + _Xconst wchar_t *text, int length) +{ + DefineLocalBuf; + char *buf = AllocLocalBuf(length); + int ret = 0; + + if (buf == NULL) + return 0; + + if (wcs_to_mbs(oc, buf, text, length) == False) + goto err; + + ret = _XmbDefaultDrawString(dpy, d, oc, gc, x, y, buf, length); + +err: + FreeLocalBuf(buf); + + return ret; +} + +static void +_XmbDefaultDrawImageString(Display *dpy, Drawable d, XOC oc, GC gc, int x, + int y, _Xconst char *text, int length) +{ + XSetFont(dpy, gc, (*oc->core.font_info.font_struct_list)->fid); + XDrawImageString(dpy, d, gc, x, y, text, length); +} + +static void +_XwcDefaultDrawImageString(Display *dpy, Drawable d, XOC oc, GC gc, int x, + int y, _Xconst wchar_t *text, int length) +{ + DefineLocalBuf; + char *buf = AllocLocalBuf(length); + + if (buf == NULL) + return; + + if (wcs_to_mbs(oc, buf, text, length) == False) + goto err; + + _XmbDefaultDrawImageString(dpy, d, oc, gc, x, y, buf, length); + +err: + FreeLocalBuf(buf); +} + +static _Xconst XOCMethodsRec oc_default_methods = { + destroy_oc, + set_oc_values, + get_oc_values, + _XmbDefaultTextEscapement, + _XmbDefaultTextExtents, + _XmbDefaultTextPerCharExtents, + _XmbDefaultDrawString, + _XmbDefaultDrawImageString, + _XwcDefaultTextEscapement, + _XwcDefaultTextExtents, + _XwcDefaultTextPerCharExtents, + _XwcDefaultDrawString, + _XwcDefaultDrawImageString +}; + +static XlcResource oc_resources[] = { + { XNBaseFontName, NULLQUARK, sizeof(char *), + XOffsetOf(XOCRec, core.base_name_list), XlcCreateMask | XlcGetMask }, + { XNOMAutomatic, NULLQUARK, sizeof(Bool), + XOffsetOf(XOCRec, core.om_automatic), XlcGetMask }, + { XNMissingCharSet, NULLQUARK, sizeof(XOMCharSetList), + XOffsetOf(XOCRec, core.missing_list), XlcGetMask }, + { XNDefaultString, NULLQUARK, sizeof(char *), + XOffsetOf(XOCRec, core.default_string), XlcGetMask }, + { XNOrientation, NULLQUARK, sizeof(XOrientation), + XOffsetOf(XOCRec, core.orientation), XlcSetMask | XlcGetMask }, + { XNResourceName, NULLQUARK, sizeof(char *), + XOffsetOf(XOCRec, core.res_name), XlcSetMask | XlcGetMask }, + { XNResourceClass, NULLQUARK, sizeof(char *), + XOffsetOf(XOCRec, core.res_class), XlcSetMask | XlcGetMask }, + { XNFontInfo, NULLQUARK, sizeof(XOMFontInfo), + XOffsetOf(XOCRec, core.font_info), XlcGetMask } +}; + +static XOC +create_oc( + XOM om, + XlcArgList args, + int num_args) +{ + XOC oc; + + oc = (XOC) Xmalloc(sizeof(XOCGenericRec)); + if (oc == NULL) + return (XOC) NULL; + bzero((char *) oc, sizeof(XOCGenericRec)); + + oc->core.om = om; + + if (oc_resources[0].xrm_name == NULLQUARK) + _XlcCompileResourceList(oc_resources, XlcNumber(oc_resources)); + + if (_XlcSetValues((XPointer) oc, oc_resources, XlcNumber(oc_resources), + args, num_args, XlcCreateMask | XlcDefaultMask)) + goto err; + + if (oc->core.base_name_list == NULL) + goto err; + + oc->core.resources = oc_resources; + oc->core.num_resources = XlcNumber(oc_resources); + + if (create_fontset(oc) == False) + goto err; + + oc->methods = (XOCMethods)&oc_default_methods; + + return oc; + +err: + destroy_oc(oc); + + return (XOC) NULL; +} + +static Status +close_om( + XOM om) +{ + XOMGenericPart *gen = XOM_GENERIC(om); + OMData data; + FontData font_data; + int count; + + if ((data = gen->data)) { + if (data->font_data) { + for (font_data = data->font_data, count = data->font_data_count; + count-- > 0 ; font_data++) { + if (font_data->name) + Xfree(font_data->name); + } + Xfree(data->font_data); + } + Xfree(gen->data); + } + + if (om->core.res_name) + Xfree(om->core.res_name); + if (om->core.res_class) + Xfree(om->core.res_class); + if (om->core.required_charset.charset_list) + XFreeStringList(om->core.required_charset.charset_list); + else + Xfree((char*)om->core.required_charset.charset_list); + if (om->core.orientation_list.orientation) + Xfree(om->core.orientation_list.orientation); + + Xfree(om); + + return 1; +} + +static char * +set_om_values( + XOM om, + XlcArgList args, + int num_args) +{ + if (om->core.resources == NULL) + return NULL; + + return _XlcSetValues((XPointer) om, om->core.resources, + om->core.num_resources, args, num_args, XlcSetMask); +} + +static char * +get_om_values( + XOM om, + XlcArgList args, + int num_args) +{ + if (om->core.resources == NULL) + return NULL; + + return _XlcGetValues((XPointer) om, om->core.resources, + om->core.num_resources, args, num_args, XlcGetMask); +} + +static _Xconst XOMMethodsRec methods = { + close_om, + set_om_values, + get_om_values, + create_oc +}; + +static XlcResource om_resources[] = { + { XNRequiredCharSet, NULLQUARK, sizeof(XOMCharSetList), + XOffsetOf(XOMRec, core.required_charset), XlcGetMask }, + { XNQueryOrientation, NULLQUARK, sizeof(XOMOrientation), + XOffsetOf(XOMRec, core.orientation_list), XlcGetMask }, + { XNDirectionalDependentDrawing, NULLQUARK, sizeof(Bool), + XOffsetOf(XOMRec, core.directional_dependent), XlcGetMask }, + { XNContextualDrawing, NULLQUARK, sizeof(Bool), + XOffsetOf(XOMRec, core.contextual_drawing), XlcGetMask } +}; + +static OMData +add_data( + XOM om) +{ + XOMGenericPart *gen = XOM_GENERIC(om); + OMData new; + + new = (OMData) Xmalloc(sizeof(OMDataRec)); + + if (new == NULL) + return NULL; + + gen->data = new; + + bzero((char *) new, sizeof(OMDataRec)); + + return new; +} + +static _Xconst char *supported_charset_list[] = { + "ISO8859-1", +/* fix for bug4332979 */ + "adobe-fontspecific", +/* fix for bug4237353: "JISX0201.1976-0" entry should be removed from + supported_charset_list because it is not a supported_charset for C locale + "JISX0201.1976-0", */ + "SUNOLCURSOR-1", + "SUNOLGLYPH-1" +}; + +static Bool +init_om( + XOM om) +{ + XOMGenericPart *gen = XOM_GENERIC(om); + OMData data; + FontData font_data; + char **required_list; + XOrientation *orientation; + char **value, buf[BUFSIZ], *bufptr; + int count, length = 0; + + value = (char**)supported_charset_list; + count = XlcNumber(supported_charset_list); + + data = add_data(om); + if (data == NULL) + return False; + + font_data = (FontData) Xmalloc(sizeof(FontDataRec) * count); + if (font_data == NULL) + return False; + bzero((char *) font_data, sizeof(FontDataRec) * count); + data->font_data = font_data; + data->font_data_count = count; + + for ( ; count-- > 0; font_data++) { +/* +1266793 +This one is fine. *value points to one of the local strings in +supported_charset_list[]. +*/ + strcpy(buf, *value++); + font_data->name = (char *) Xmalloc(strlen(buf) + 1); + if (font_data->name == NULL) + return False; + strcpy(font_data->name, buf); + } + + length += strlen(data->font_data->name) + 1; + + /* required charset list */ + required_list = (char **) Xmalloc(sizeof(char *)); + if (required_list == NULL) + return False; + + bufptr = (char *) Xmalloc(length); + if (bufptr == NULL) { + Xfree(required_list); + return False; + } + + om->core.required_charset.charset_list = required_list; + om->core.required_charset.charset_count = 1; /* always 1 */ + + data = gen->data; + + strcpy(bufptr, data->font_data->name); + *required_list++ = bufptr; + bufptr += strlen(bufptr) + 1; + + /* orientation list */ + orientation = (XOrientation *) Xmalloc(sizeof(XOrientation)); + if (orientation == NULL) + return False; + + *orientation = XOMOrientation_LTR_TTB; + om->core.orientation_list.orientation = orientation; + om->core.orientation_list.num_orientation = 1; + + /* directional dependent drawing */ + om->core.directional_dependent = False; + + /* contexual drawing */ + om->core.contextual_drawing = False; + + /* context dependent */ + om->core.context_dependent = False; + + return True; +} + +XOM +_XDefaultOpenOM(XLCd lcd, Display *dpy, XrmDatabase rdb, + _Xconst char *res_name, _Xconst char *res_class) +{ + XOM om; + + om = (XOM) Xmalloc(sizeof(XOMGenericRec)); + if (om == NULL) + return (XOM) NULL; + bzero((char *) om, sizeof(XOMGenericRec)); + + om->methods = (XOMMethods)&methods; + om->core.lcd = lcd; + om->core.display = dpy; + om->core.rdb = rdb; + if (res_name) { + om->core.res_name = (char *)Xmalloc(strlen(res_name) + 1); + if (om->core.res_name == NULL) + goto err; + strcpy(om->core.res_name, res_name); + } + if (res_class) { + om->core.res_class = (char *)Xmalloc(strlen(res_class) + 1); + if (om->core.res_class == NULL) + goto err; + strcpy(om->core.res_class, res_class); + } + + if (om_resources[0].xrm_name == NULLQUARK) + _XlcCompileResourceList(om_resources, XlcNumber(om_resources)); + + om->core.resources = om_resources; + om->core.num_resources = XlcNumber(om_resources); + + if (init_om(om) == False) + goto err; + + return om; +err: + close_om(om); + + return (XOM) NULL; +} diff --git a/libX11/src/xlibi18n/lcFile.c b/libX11/src/xlibi18n/lcFile.c index 21a546d8f..18756c1ca 100644 --- a/libX11/src/xlibi18n/lcFile.c +++ b/libX11/src/xlibi18n/lcFile.c @@ -685,8 +685,7 @@ _XlcLocaleDirName(char *dir_name, size_t dir_len, char *lc_name) Xfree(name); continue; } - if ((1 + (target_dir ? strlen (target_dir) : 0) + - strlen("locale.dir")) < PATH_MAX) { + if ((1 + strlen (target_dir) + strlen("locale.dir")) < PATH_MAX) { sprintf(buf, "%s/locale.dir", target_dir); target_name = resolve_name(name, buf, RtoL); } @@ -785,8 +784,7 @@ _XlcLocaleLibDirName(char *dir_name, size_t dir_len, char *lc_name) Xfree(name); continue; } - if ((1 + (target_dir ? strlen (target_dir) : 0) + - strlen("locale.dir")) < PATH_MAX) { + if ((1 + strlen (target_dir) + strlen("locale.dir")) < PATH_MAX) { sprintf(buf, "%s/locale.dir", target_dir); target_name = resolve_name(name, buf, RtoL); } diff --git a/libX11/src/xlibi18n/lcGeneric.c b/libX11/src/xlibi18n/lcGeneric.c index 69ea97db8..688a4cfc4 100644 --- a/libX11/src/xlibi18n/lcGeneric.c +++ b/libX11/src/xlibi18n/lcGeneric.c @@ -428,7 +428,7 @@ read_charset_define( char name[BUFSIZ]; XlcCharSet charsetd; char **value; - int num, new; + int num, new = 0; XlcSide side = XlcUnknown; char *tmp; diff --git a/libXau/configure.ac b/libXau/configure.ac index db51f0c3a..09a872e05 100644 --- a/libXau/configure.ac +++ b/libXau/configure.ac @@ -1,75 +1,82 @@ -dnl -dnl Copyright © 2003 Keith Packard, Noah Levitt -dnl -dnl Permission to use, copy, modify, distribute, and sell this software and its -dnl documentation for any purpose is hereby granted without fee, provided that -dnl the above copyright notice appear in all copies and that both that -dnl copyright notice and this permission notice appear in supporting -dnl documentation, and that the name of Keith Packard not be used in -dnl advertising or publicity pertaining to distribution of the software without -dnl specific, written prior permission. Keith Packard makes no -dnl representations about the suitability of this software for any purpose. It -dnl is provided "as is" without express or implied warranty. -dnl -dnl KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, -dnl INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO -dnl EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR -dnl CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, -dnl DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER -dnl TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR -dnl PERFORMANCE OF THIS SOFTWARE. -dnl -dnl Process this file with autoconf to create configure. - -AC_PREREQ([2.60]) -AC_INIT(libXau, 1.0.6, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],libXau) -AM_INIT_AUTOMAKE([foreign dist-bzip2]) -AM_MAINTAINER_MODE - -AC_CONFIG_HEADERS(config.h) - -# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS -m4_ifndef([XORG_MACROS_VERSION], - [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])]) -XORG_MACROS_VERSION(1.8) -XORG_DEFAULT_OPTIONS - -AC_PROG_LN_S -AC_LIBTOOL_WIN32_DLL -AM_PROG_LIBTOOL - -PKG_CHECK_MODULES(XAU, xproto) - -AC_ARG_ENABLE(xthreads, - AS_HELP_STRING([--disable-xthreads], - [Disable libXau support for Multithreading]), - [xthreads=$enableval],[xthreads=yes]) - -if test "x$xthreads" = "xyes" ; then - AC_DEFINE(XTHREADS,1,[Whether libXau is compiled with thread support]) - AC_CHECK_LIB(c, gethostbyname_r, [mtsafe=yes]) - if test "x$mtsafe" = "x" ; then - AC_CHECK_LIB(nsl, gethostbyname_r, [mtsafe=yes]) - fi - if test "x$mtsafe" = "xyes" ; then - AC_DEFINE(XUSE_MTSAFE_API, 1, - [Whether libXau needs to use MT safe API's]) - fi - -dnl XXX incomplete, please fill this in - case $host_os in - solaris*) - XTHREAD_CFLAGS="-D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS" ;; - esac - XAU_CFLAGS="$XAU_CFLAGS $XTHREAD_CFLAGS" -fi - -dnl Allow checking code with lint, sparse, etc. -XORG_WITH_LINT -XORG_LINT_LIBRARY([Xau]) -LINT_FLAGS="${LINT_FLAGS} ${XAU_CFLAGS}" - - -AC_OUTPUT([Makefile - man/Makefile - xau.pc]) +# +# Copyright © 2003 Keith Packard, Noah Levitt +# +# Permission to use, copy, modify, distribute, and sell this software and its +# documentation for any purpose is hereby granted without fee, provided that +# the above copyright notice appear in all copies and that both that +# copyright notice and this permission notice appear in supporting +# documentation, and that the name of Keith Packard not be used in +# advertising or publicity pertaining to distribution of the software without +# specific, written prior permission. Keith Packard makes no +# representations about the suitability of this software for any purpose. It +# is provided "as is" without express or implied warranty. +# +# KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, +# INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO +# EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR +# CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +# DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +# PERFORMANCE OF THIS SOFTWARE. +# + +# Initialize Autoconf +AC_PREREQ([2.60]) +AC_INIT([libXau], [1.0.6], + [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXau]) +AC_CONFIG_SRCDIR([Makefile.am]) +AC_CONFIG_HEADERS([config.h]) + +# Initialize Automake +AM_INIT_AUTOMAKE([foreign dist-bzip2]) +AM_MAINTAINER_MODE + +# Initialize libtool +AC_LIBTOOL_WIN32_DLL +AC_PROG_LIBTOOL + +# Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS +m4_ifndef([XORG_MACROS_VERSION], + [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])]) +XORG_MACROS_VERSION(1.8) +XORG_DEFAULT_OPTIONS + +# Checks for programs. +AC_PROG_LN_S + +# Obtain compiler/linker options for depedencies +PKG_CHECK_MODULES(XAU, xproto) + +AC_ARG_ENABLE(xthreads, + AS_HELP_STRING([--disable-xthreads], + [Disable libXau support for Multithreading]), + [xthreads=$enableval],[xthreads=yes]) + +if test "x$xthreads" = "xyes" ; then + AC_DEFINE(XTHREADS,1,[Whether libXau is compiled with thread support]) + AC_CHECK_LIB(c, gethostbyname_r, [mtsafe=yes]) + if test "x$mtsafe" = "x" ; then + AC_CHECK_LIB(nsl, gethostbyname_r, [mtsafe=yes]) + fi + if test "x$mtsafe" = "xyes" ; then + AC_DEFINE(XUSE_MTSAFE_API, 1, + [Whether libXau needs to use MT safe API's]) + fi + +# XXX incomplete, please fill this in + case $host_os in + solaris*) + XTHREAD_CFLAGS="-D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS" ;; + esac + XAU_CFLAGS="$XAU_CFLAGS $XTHREAD_CFLAGS" +fi + +# Allow checking code with lint, sparse, etc. +XORG_WITH_LINT +XORG_LINT_LIBRARY([Xau]) +LINT_FLAGS="${LINT_FLAGS} ${XAU_CFLAGS}" + +AC_CONFIG_FILES([Makefile + man/Makefile + xau.pc]) +AC_OUTPUT diff --git a/libXdmcp/configure.ac b/libXdmcp/configure.ac index b9ed587b8..97d31a1cd 100644 --- a/libXdmcp/configure.ac +++ b/libXdmcp/configure.ac @@ -1,68 +1,76 @@ -dnl -dnl Copyright © 2003 Keith Packard, Noah Levitt -dnl -dnl Permission to use, copy, modify, distribute, and sell this software and its -dnl documentation for any purpose is hereby granted without fee, provided that -dnl the above copyright notice appear in all copies and that both that -dnl copyright notice and this permission notice appear in supporting -dnl documentation, and that the name of Keith Packard not be used in -dnl advertising or publicity pertaining to distribution of the software without -dnl specific, written prior permission. Keith Packard makes no -dnl representations about the suitability of this software for any purpose. It -dnl is provided "as is" without express or implied warranty. -dnl -dnl KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, -dnl INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO -dnl EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR -dnl CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, -dnl DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER -dnl TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR -dnl PERFORMANCE OF THIS SOFTWARE. -dnl -dnl Process this file with autoconf to create configure. - -AC_PREREQ([2.60]) -AC_INIT([libXdmcp], [1.1.0], - [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXdmcp]) -AM_INIT_AUTOMAKE([foreign dist-bzip2]) -AM_MAINTAINER_MODE - -AC_CONFIG_HEADERS(config.h) - -# Require xorg-macros minimum of 1.10 for HAVE_STYLESHEETS in XORG_CHECK_SGML_DOCTOOLS -m4_ifndef([XORG_MACROS_VERSION], - [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])]) -XORG_MACROS_VERSION(1.10) -XORG_DEFAULT_OPTIONS -XORG_ENABLE_DOCS -XORG_WITH_XMLTO(0.0.20) -XORG_WITH_FOP -XORG_CHECK_SGML_DOCTOOLS(1.5) - -AC_PROG_LN_S -AC_LIBTOOL_WIN32_DLL -AM_PROG_LIBTOOL -AC_PROG_MAKE_SET - -AC_CHECK_FUNCS([srand48 lrand48]) - -AC_SEARCH_LIBS([recvfrom],[socket]) - -PKG_CHECK_MODULES(XDMCP, xproto) - -if test -f ${srcdir}/Wraphelp.c; then - AC_DEFINE(HASXDMAUTH,1,[Has Wraphelp.c needed for XDM AUTH protocols]) - HASXDMAUTH=yes -else - HASXDMAUTH=no -fi - -AM_CONDITIONAL(HASXDMAUTH,test x$HASXDMAUTH = xyes) - -dnl Allow checking code with lint, sparse, etc. -XORG_WITH_LINT -XORG_LINT_LIBRARY([Xdmcp]) - -AC_OUTPUT([Makefile - doc/Makefile - xdmcp.pc]) +# +# Copyright © 2003 Keith Packard, Noah Levitt +# +# Permission to use, copy, modify, distribute, and sell this software and its +# documentation for any purpose is hereby granted without fee, provided that +# the above copyright notice appear in all copies and that both that +# copyright notice and this permission notice appear in supporting +# documentation, and that the name of Keith Packard not be used in +# advertising or publicity pertaining to distribution of the software without +# specific, written prior permission. Keith Packard makes no +# representations about the suitability of this software for any purpose. It +# is provided "as is" without express or implied warranty. +# +# KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, +# INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO +# EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR +# CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +# DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +# PERFORMANCE OF THIS SOFTWARE. +# + +# Initialize Autoconf +AC_PREREQ([2.60]) +AC_INIT([libXdmcp], [1.1.0], + [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXdmcp]) +AC_CONFIG_SRCDIR([Makefile.am]) +AC_CONFIG_HEADERS([config.h]) + +# Initialize Automake +AM_INIT_AUTOMAKE([foreign dist-bzip2]) +AM_MAINTAINER_MODE + +# Initialize libtool +AC_LIBTOOL_WIN32_DLL +AC_PROG_LIBTOOL + +# Require xorg-macros minimum of 1.10 for HAVE_STYLESHEETS in XORG_CHECK_SGML_DOCTOOLS +m4_ifndef([XORG_MACROS_VERSION], + [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])]) +XORG_MACROS_VERSION(1.10) +XORG_DEFAULT_OPTIONS +XORG_ENABLE_DOCS +XORG_WITH_XMLTO(0.0.20) +XORG_WITH_FOP +XORG_CHECK_SGML_DOCTOOLS(1.5) + +# Checks for programs. +AC_PROG_LN_S + +# Checks for libraries. +AC_SEARCH_LIBS([recvfrom],[socket]) + +# Checks for library functions. +AC_CHECK_FUNCS([srand48 lrand48]) + +# Obtain compiler/linker options for depedencies +PKG_CHECK_MODULES(XDMCP, xproto) + +if test -f ${srcdir}/Wraphelp.c; then + AC_DEFINE(HASXDMAUTH,1,[Has Wraphelp.c needed for XDM AUTH protocols]) + HASXDMAUTH=yes +else + HASXDMAUTH=no +fi + +AM_CONDITIONAL(HASXDMAUTH,test x$HASXDMAUTH = xyes) + +# Allow checking code with lint, sparse, etc. +XORG_WITH_LINT +XORG_LINT_LIBRARY([Xdmcp]) + +AC_CONFIG_FILES([Makefile + doc/Makefile + xdmcp.pc]) +AC_OUTPUT diff --git a/libXext/configure.ac b/libXext/configure.ac index 6e28bb663..5dae4f695 100644 --- a/libXext/configure.ac +++ b/libXext/configure.ac @@ -1,56 +1,50 @@ -# -*- Autoconf -*- -# Process this file with autoconf to produce a configure script. - -AC_PREREQ([2.60]) -AC_INIT([libXext], - [1.2.99.0], - [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], - [libXext]) - -AC_CONFIG_SRCDIR([Makefile.am]) -AM_INIT_AUTOMAKE([foreign dist-bzip2]) - -AM_MAINTAINER_MODE - -# Require xorg-macros minimum of 1.10 for DocBook XML documentation -m4_ifndef([XORG_MACROS_VERSION], - [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])]) -XORG_MACROS_VERSION(1.10) -XORG_DEFAULT_OPTIONS -XORG_ENABLE_SPECS -XORG_WITH_XMLTO(0.0.20) -XORG_WITH_FOP -XORG_CHECK_SGML_DOCTOOLS(1.5) -AC_CONFIG_HEADERS([config.h]) - -# Determine .so library version per platform -# based on SharedXextRev in monolith xc/config/cf/*Lib.tmpl -AC_CANONICAL_HOST -if test "x$XEXT_SOREV" = "x" ; then - case $host_os in - openbsd*) XEXT_SOREV=8:0 ;; - solaris*) XEXT_SOREV=0 ;; - *) XEXT_SOREV=6:4:0 ;; - esac -fi -AC_SUBST(XEXT_SOREV) - -# Checks for programs. -AC_PROG_LIBTOOL - -# Checks for pkg-config packages -PKG_CHECK_MODULES(XEXT, [xproto >= 7.0.13] [x11 >= 1.1.99.1] [xextproto >= 7.1.99]) -AC_SUBST(XEXT_CFLAGS) -AC_SUBST(XEXT_LIBS) - -XORG_CHECK_MALLOC_ZERO - -dnl Allow checking code with lint, sparse, etc. -XORG_WITH_LINT -XORG_LINT_LIBRARY([Xext]) - -AC_OUTPUT([Makefile - man/Makefile - src/Makefile - specs/Makefile - xext.pc]) + +# Initialize Autoconf +AC_PREREQ([2.60]) +AC_INIT([libXext], [1.2.99.0], + [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXext]) +AC_CONFIG_SRCDIR([Makefile.am]) +AC_CONFIG_HEADERS([config.h]) + +# Initialize Automake +AM_INIT_AUTOMAKE([foreign dist-bzip2]) +AM_MAINTAINER_MODE + +# Initialize libtool +AC_PROG_LIBTOOL + +# Require xorg-macros minimum of 1.10 for DocBook XML documentation +m4_ifndef([XORG_MACROS_VERSION], + [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])]) +XORG_MACROS_VERSION(1.10) +XORG_DEFAULT_OPTIONS +XORG_ENABLE_SPECS +XORG_WITH_XMLTO(0.0.20) +XORG_WITH_FOP +XORG_CHECK_SGML_DOCTOOLS(1.5) +XORG_CHECK_MALLOC_ZERO + +# Determine .so library version per platform +# based on SharedXextRev in monolith xc/config/cf/*Lib.tmpl +if test "x$XEXT_SOREV" = "x" ; then + case $host_os in + openbsd*) XEXT_SOREV=8:0 ;; + solaris*) XEXT_SOREV=0 ;; + *) XEXT_SOREV=6:4:0 ;; + esac +fi +AC_SUBST(XEXT_SOREV) + +# Obtain compiler/linker options for depedencies +PKG_CHECK_MODULES(XEXT, [xproto >= 7.0.13] [x11 >= 1.1.99.1] [xextproto >= 7.1.99]) + +# Allow checking code with lint, sparse, etc. +XORG_WITH_LINT +XORG_LINT_LIBRARY([Xext]) + +AC_CONFIG_FILES([Makefile + man/Makefile + src/Makefile + specs/Makefile + xext.pc]) +AC_OUTPUT diff --git a/mesalib/scons/crossmingw.py b/mesalib/scons/crossmingw.py index bac51de07..cc046229e 100644 --- a/mesalib/scons/crossmingw.py +++ b/mesalib/scons/crossmingw.py @@ -1,198 +1,201 @@ -"""SCons.Tool.gcc - -Tool-specific initialization for MinGW (http://www.mingw.org/) - -There normally shouldn't be any need to import this module directly. -It will usually be imported through the generic SCons.Tool.Tool() -selection method. - -See also http://www.scons.org/wiki/CrossCompilingMingw -""" - -# -# Copyright (c) 2001, 2002, 2003, 2004 The SCons Foundation -# -# Permission is hereby granted, free of charge, to any person obtaining -# a copy of this software and associated documentation files (the -# "Software"), to deal in the Software without restriction, including -# without limitation the rights to use, copy, modify, merge, publish, -# distribute, sublicense, and/or sell copies of the Software, and to -# permit persons to whom the Software is furnished to do so, subject to -# the following conditions: -# -# The above copyright notice and this permission notice shall be included -# in all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY -# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE -# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# - -import os -import os.path -import string - -import SCons.Action -import SCons.Builder -import SCons.Tool -import SCons.Util - -# This is what we search for to find mingw: -prefixes32 = SCons.Util.Split(""" - mingw32- - mingw32msvc- - i386-mingw32- - i486-mingw32- - i586-mingw32- - i686-mingw32- - i386-mingw32msvc- - i486-mingw32msvc- - i586-mingw32msvc- - i686-mingw32msvc- - i686-pc-mingw32- - i686-w64-mingw32- -""") -prefixes64 = SCons.Util.Split(""" - amd64-mingw32- - amd64-mingw32msvc- - amd64-pc-mingw32- - x86_64-w64-mingw32- -""") - -def find(env): - if env['machine'] == 'x86_64': - prefixes = prefixes64 - else: - prefixes = prefixes32 - for prefix in prefixes: - # First search in the SCons path and then the OS path: - if env.WhereIs(prefix + 'gcc') or SCons.Util.WhereIs(prefix + 'gcc'): - return prefix - - return '' - -def shlib_generator(target, source, env, for_signature): - cmd = SCons.Util.CLVar(['$SHLINK', '$SHLINKFLAGS']) - - dll = env.FindIxes(target, 'SHLIBPREFIX', 'SHLIBSUFFIX') - if dll: cmd.extend(['-o', dll]) - - cmd.extend(['$SOURCES', '$_LIBDIRFLAGS', '$_LIBFLAGS']) - - implib = env.FindIxes(target, 'LIBPREFIX', 'LIBSUFFIX') - if implib: cmd.append('-Wl,--out-implib,'+implib.get_string(for_signature)) - - def_target = env.FindIxes(target, 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX') - if def_target: cmd.append('-Wl,--output-def,'+def_target.get_string(for_signature)) - - return [cmd] - -def shlib_emitter(target, source, env): - dll = env.FindIxes(target, 'SHLIBPREFIX', 'SHLIBSUFFIX') - no_import_lib = env.get('no_import_lib', 0) - - if not dll: - raise SCons.Errors.UserError, "A shared library should have exactly one target with the suffix: %s" % env.subst("$SHLIBSUFFIX") - - if not no_import_lib and \ - not env.FindIxes(target, 'LIBPREFIX', 'LIBSUFFIX'): - - # Append an import library to the list of targets. - target.append(env.ReplaceIxes(dll, - 'SHLIBPREFIX', 'SHLIBSUFFIX', - 'LIBPREFIX', 'LIBSUFFIX')) - - # Append a def file target if there isn't already a def file target - # or a def file source. There is no option to disable def file - # target emitting, because I can't figure out why someone would ever - # want to turn it off. - def_source = env.FindIxes(source, 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX') - def_target = env.FindIxes(target, 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX') - if not def_source and not def_target: - target.append(env.ReplaceIxes(dll, - 'SHLIBPREFIX', 'SHLIBSUFFIX', - 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX')) - - return (target, source) - - -shlib_action = SCons.Action.Action(shlib_generator, '$SHLINKCOMSTR', generator=1) - -res_action = SCons.Action.Action('$RCCOM', '$RCCOMSTR') - -res_builder = SCons.Builder.Builder(action=res_action, suffix='.o', - source_scanner=SCons.Tool.SourceFileScanner) -SCons.Tool.SourceFileScanner.add_scanner('.rc', SCons.Defaults.CScan) - -def generate(env): - mingw_prefix = find(env) - - if mingw_prefix: - dir = os.path.dirname(env.WhereIs(mingw_prefix + 'gcc') or SCons.Util.WhereIs(mingw_prefix + 'gcc')) - - # The mingw bin directory must be added to the path: - path = env['ENV'].get('PATH', []) - if not path: - path = [] - if SCons.Util.is_String(path): - path = string.split(path, os.pathsep) - - env['ENV']['PATH'] = string.join([dir] + path, os.pathsep) - - # Most of mingw is the same as gcc and friends... - gnu_tools = ['gcc', 'g++', 'gnulink', 'ar', 'gas'] - for tool in gnu_tools: - SCons.Tool.Tool(tool)(env) - - #... but a few things differ: - env['CC'] = mingw_prefix + 'gcc' - env['SHCCFLAGS'] = SCons.Util.CLVar('$CCFLAGS') - env['CXX'] = mingw_prefix + 'g++' - env['SHCXXFLAGS'] = SCons.Util.CLVar('$CXXFLAGS') - env['SHLINKFLAGS'] = SCons.Util.CLVar('$LINKFLAGS -shared') - env['SHLINKCOM'] = shlib_action - env.Append(SHLIBEMITTER = [shlib_emitter]) - env['LINK'] = mingw_prefix + 'g++' - env['AR'] = mingw_prefix + 'ar' - env['RANLIB'] = mingw_prefix + 'ranlib' - env['LINK'] = mingw_prefix + 'g++' - env['AS'] = mingw_prefix + 'as' - env['WIN32DEFPREFIX'] = '' - env['WIN32DEFSUFFIX'] = '.def' - env['SHOBJSUFFIX'] = '.o' - env['STATIC_AND_SHARED_OBJECTS_ARE_THE_SAME'] = 1 - - env['RC'] = mingw_prefix + 'windres' - env['RCFLAGS'] = SCons.Util.CLVar('') - env['RCCOM'] = '$RC $_CPPDEFFLAGS $_CPPINCFLAGS ${INCPREFIX}${SOURCE.dir} $RCFLAGS -i $SOURCE -o $TARGET' - env['BUILDERS']['RES'] = res_builder - - # Some setting from the platform also have to be overridden: - env['OBJPREFIX'] = '' - env['OBJSUFFIX'] = '.o' - env['SHOBJPREFIX'] = '$OBJPREFIX' - env['SHOBJSUFFIX'] = '$OBJSUFFIX' - env['PROGPREFIX'] = '' - env['PROGSUFFIX'] = '.exe' - env['LIBPREFIX'] = 'lib' - env['LIBSUFFIX'] = '.a' - env['SHLIBPREFIX'] = '' - env['SHLIBSUFFIX'] = '.dll' - env['LIBPREFIXES'] = [ 'lib', '' ] - env['LIBSUFFIXES'] = [ '.a', '.lib' ] - - # MinGW port of gdb does not handle well dwarf debug info which is the - # default in recent gcc versions - env.AppendUnique(CCFLAGS = ['-gstabs']) - - env.AppendUnique(CPPDEFINES = [('__MSVCRT_VERSION__', '0x0700')]) - #env.AppendUnique(LIBS = ['iberty']) - env.AppendUnique(SHLINKFLAGS = ['-Wl,--enable-stdcall-fixup']) - #env.AppendUnique(SHLINKFLAGS = ['-Wl,--kill-at']) - -def exists(env): - return find(env) +"""SCons.Tool.gcc + +Tool-specific initialization for MinGW (http://www.mingw.org/) + +There normally shouldn't be any need to import this module directly. +It will usually be imported through the generic SCons.Tool.Tool() +selection method. + +See also http://www.scons.org/wiki/CrossCompilingMingw +""" + +# +# Copyright (c) 2001, 2002, 2003, 2004 The SCons Foundation +# +# Permission is hereby granted, free of charge, to any person obtaining +# a copy of this software and associated documentation files (the +# "Software"), to deal in the Software without restriction, including +# without limitation the rights to use, copy, modify, merge, publish, +# distribute, sublicense, and/or sell copies of the Software, and to +# permit persons to whom the Software is furnished to do so, subject to +# the following conditions: +# +# The above copyright notice and this permission notice shall be included +# in all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY +# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE +# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# + +import os +import os.path +import string + +import SCons.Action +import SCons.Builder +import SCons.Tool +import SCons.Util + +# This is what we search for to find mingw: +prefixes32 = SCons.Util.Split(""" + mingw32- + mingw32msvc- + i386-mingw32- + i486-mingw32- + i586-mingw32- + i686-mingw32- + i386-mingw32msvc- + i486-mingw32msvc- + i586-mingw32msvc- + i686-mingw32msvc- + i686-pc-mingw32- + i686-w64-mingw32- +""") +prefixes64 = SCons.Util.Split(""" + amd64-mingw32- + amd64-mingw32msvc- + amd64-pc-mingw32- + x86_64-w64-mingw32- +""") + +def find(env): + if env['machine'] == 'x86_64': + prefixes = prefixes64 + else: + prefixes = prefixes32 + for prefix in prefixes: + # First search in the SCons path and then the OS path: + if env.WhereIs(prefix + 'gcc') or SCons.Util.WhereIs(prefix + 'gcc'): + return prefix + + return '' + +def shlib_generator(target, source, env, for_signature): + cmd = SCons.Util.CLVar(['$SHLINK', '$SHLINKFLAGS']) + + dll = env.FindIxes(target, 'SHLIBPREFIX', 'SHLIBSUFFIX') + if dll: cmd.extend(['-o', dll]) + + cmd.extend(['$SOURCES', '$_LIBDIRFLAGS', '$_LIBFLAGS']) + + implib = env.FindIxes(target, 'LIBPREFIX', 'LIBSUFFIX') + if implib: cmd.append('-Wl,--out-implib,'+implib.get_string(for_signature)) + + def_target = env.FindIxes(target, 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX') + if def_target: cmd.append('-Wl,--output-def,'+def_target.get_string(for_signature)) + + return [cmd] + +def shlib_emitter(target, source, env): + dll = env.FindIxes(target, 'SHLIBPREFIX', 'SHLIBSUFFIX') + no_import_lib = env.get('no_import_lib', 0) + + if not dll: + raise SCons.Errors.UserError, "A shared library should have exactly one target with the suffix: %s" % env.subst("$SHLIBSUFFIX") + + if not no_import_lib and \ + not env.FindIxes(target, 'LIBPREFIX', 'LIBSUFFIX'): + + # Append an import library to the list of targets. + target.append(env.ReplaceIxes(dll, + 'SHLIBPREFIX', 'SHLIBSUFFIX', + 'LIBPREFIX', 'LIBSUFFIX')) + + # Append a def file target if there isn't already a def file target + # or a def file source. There is no option to disable def file + # target emitting, because I can't figure out why someone would ever + # want to turn it off. + def_source = env.FindIxes(source, 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX') + def_target = env.FindIxes(target, 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX') + if not def_source and not def_target: + target.append(env.ReplaceIxes(dll, + 'SHLIBPREFIX', 'SHLIBSUFFIX', + 'WIN32DEFPREFIX', 'WIN32DEFSUFFIX')) + + return (target, source) + + +shlib_action = SCons.Action.Action(shlib_generator, '$SHLINKCOMSTR', generator=1) + +res_action = SCons.Action.Action('$RCCOM', '$RCCOMSTR') + +res_builder = SCons.Builder.Builder(action=res_action, suffix='.o', + source_scanner=SCons.Tool.SourceFileScanner) +SCons.Tool.SourceFileScanner.add_scanner('.rc', SCons.Defaults.CScan) + +def generate(env): + mingw_prefix = find(env) + + if mingw_prefix: + dir = os.path.dirname(env.WhereIs(mingw_prefix + 'gcc') or SCons.Util.WhereIs(mingw_prefix + 'gcc')) + + # The mingw bin directory must be added to the path: + path = env['ENV'].get('PATH', []) + if not path: + path = [] + if SCons.Util.is_String(path): + path = string.split(path, os.pathsep) + + env['ENV']['PATH'] = string.join([dir] + path, os.pathsep) + + # Most of mingw is the same as gcc and friends... + gnu_tools = ['gcc', 'g++', 'gnulink', 'ar', 'gas'] + for tool in gnu_tools: + SCons.Tool.Tool(tool)(env) + + #... but a few things differ: + env['CC'] = mingw_prefix + 'gcc' + env['SHCCFLAGS'] = SCons.Util.CLVar('$CCFLAGS') + env['CXX'] = mingw_prefix + 'g++' + env['SHCXXFLAGS'] = SCons.Util.CLVar('$CXXFLAGS') + env['SHLINKFLAGS'] = SCons.Util.CLVar('$LINKFLAGS -shared') + env['SHLINKCOM'] = shlib_action + env.Append(SHLIBEMITTER = [shlib_emitter]) + env['LINK'] = mingw_prefix + 'g++' + env['AR'] = mingw_prefix + 'ar' + env['RANLIB'] = mingw_prefix + 'ranlib' + env['LINK'] = mingw_prefix + 'g++' + env['AS'] = mingw_prefix + 'as' + env['WIN32DEFPREFIX'] = '' + env['WIN32DEFSUFFIX'] = '.def' + env['SHOBJSUFFIX'] = '.o' + env['STATIC_AND_SHARED_OBJECTS_ARE_THE_SAME'] = 1 + + env['RC'] = mingw_prefix + 'windres' + env['RCFLAGS'] = SCons.Util.CLVar('') + env['RCCOM'] = '$RC $_CPPDEFFLAGS $_CPPINCFLAGS ${INCPREFIX}${SOURCE.dir} $RCFLAGS -i $SOURCE -o $TARGET' + env['BUILDERS']['RES'] = res_builder + + # Some setting from the platform also have to be overridden: + env['OBJPREFIX'] = '' + env['OBJSUFFIX'] = '.o' + env['SHOBJPREFIX'] = '$OBJPREFIX' + env['SHOBJSUFFIX'] = '$OBJSUFFIX' + env['PROGPREFIX'] = '' + env['PROGSUFFIX'] = '.exe' + env['LIBPREFIX'] = 'lib' + env['LIBSUFFIX'] = '.a' + env['SHLIBPREFIX'] = '' + env['SHLIBSUFFIX'] = '.dll' + env['LIBPREFIXES'] = [ 'lib', '' ] + env['LIBSUFFIXES'] = [ '.a', '.lib' ] + + # MinGW port of gdb does not handle well dwarf debug info which is the + # default in recent gcc versions + env.AppendUnique(CCFLAGS = ['-gstabs']) + + env.AppendUnique(CPPDEFINES = [('__MSVCRT_VERSION__', '0x0700')]) + #env.AppendUnique(LIBS = ['iberty']) + env.AppendUnique(SHLINKFLAGS = ['-Wl,--enable-stdcall-fixup']) + #env.AppendUnique(SHLINKFLAGS = ['-Wl,--kill-at']) + + # Avoid depending on gcc runtime DLLs + env.AppendUnique(LINKFLAGS = ['-static-libgcc']) + +def exists(env): + return find(env) diff --git a/mesalib/src/glsl/ast_function.cpp b/mesalib/src/glsl/ast_function.cpp index 28d49ee0d..7611617df 100644 --- a/mesalib/src/glsl/ast_function.cpp +++ b/mesalib/src/glsl/ast_function.cpp @@ -75,7 +75,7 @@ prototype_string(const glsl_type *return_type, const char *name, char *str = NULL; if (return_type != NULL) - ralloc_asprintf(&str, "%s ", return_type->name); + str = ralloc_asprintf(NULL, "%s ", return_type->name); ralloc_asprintf_append(&str, "%s(", name); diff --git a/mesalib/src/glsl/glcpp/glcpp-parse.y b/mesalib/src/glsl/glcpp/glcpp-parse.y index aa5a0c4f2..1f6e67fa0 100644 --- a/mesalib/src/glsl/glcpp/glcpp-parse.y +++ b/mesalib/src/glsl/glcpp/glcpp-parse.y @@ -388,7 +388,12 @@ expression: $$ = $1 + $3; } | expression '%' expression { - $$ = $1 % $3; + if ($3 == 0) { + yyerror (& @1, parser, + "zero modulus in preprocessor directive"); + } else { + $$ = $1 % $3; + } } | expression '/' expression { if ($3 == 0) { diff --git a/mesalib/src/glsl/ir_constant_expression.cpp b/mesalib/src/glsl/ir_constant_expression.cpp index cf958aa7a..2841fb350 100644 --- a/mesalib/src/glsl/ir_constant_expression.cpp +++ b/mesalib/src/glsl/ir_constant_expression.cpp @@ -288,20 +288,24 @@ ir_expression::constant_expression_value() break; case ir_unop_rcp: + /* FINISHME: Emit warning when division-by-zero is detected. */ assert(op[0]->type->base_type == GLSL_TYPE_FLOAT); for (unsigned c = 0; c < op[0]->type->components(); c++) { switch (this->type->base_type) { case GLSL_TYPE_UINT: - if (op[0]->value.u[c] != 0.0) - data.u[c] = 1 / op[0]->value.u[c]; + if (op[0]->value.u[c] == 0.0) + return NULL; + data.u[c] = 1 / op[0]->value.u[c]; break; case GLSL_TYPE_INT: - if (op[0]->value.i[c] != 0.0) - data.i[c] = 1 / op[0]->value.i[c]; + if (op[0]->value.i[c] == 0.0) + return NULL; + data.i[c] = 1 / op[0]->value.i[c]; break; case GLSL_TYPE_FLOAT: - if (op[0]->value.f[c] != 0.0) - data.f[c] = 1.0F / op[0]->value.f[c]; + if (op[0]->value.f[c] == 0.0) + return NULL; + data.f[c] = 1.0F / op[0]->value.f[c]; break; default: assert(0); @@ -310,9 +314,13 @@ ir_expression::constant_expression_value() break; case ir_unop_rsq: + /* FINISHME: Emit warning when division-by-zero is detected. */ assert(op[0]->type->base_type == GLSL_TYPE_FLOAT); for (unsigned c = 0; c < op[0]->type->components(); c++) { - data.f[c] = 1.0F / sqrtf(op[0]->value.f[c]); + float s = sqrtf(op[0]->value.f[c]); + if (s == 0) + return NULL; + data.f[c] = 1.0F / s; } break; @@ -507,6 +515,7 @@ ir_expression::constant_expression_value() break; case ir_binop_div: + /* FINISHME: Emit warning when division-by-zero is detected. */ assert(op[0]->type == op[1]->type || op0_scalar || op1_scalar); for (unsigned c = 0, c0 = 0, c1 = 0; c < components; @@ -514,12 +523,18 @@ ir_expression::constant_expression_value() switch (op[0]->type->base_type) { case GLSL_TYPE_UINT: + if (op[1]->value.u[c1] == 0) + return NULL; data.u[c] = op[0]->value.u[c0] / op[1]->value.u[c1]; break; case GLSL_TYPE_INT: + if (op[1]->value.i[c1] == 0) + return NULL; data.i[c] = op[0]->value.i[c0] / op[1]->value.i[c1]; break; case GLSL_TYPE_FLOAT: + if (op[1]->value.f[c1] == 0) + return NULL; data.f[c] = op[0]->value.f[c0] / op[1]->value.f[c1]; break; default: @@ -529,6 +544,7 @@ ir_expression::constant_expression_value() break; case ir_binop_mod: + /* FINISHME: Emit warning when division-by-zero is detected. */ assert(op[0]->type == op[1]->type || op0_scalar || op1_scalar); for (unsigned c = 0, c0 = 0, c1 = 0; c < components; @@ -536,12 +552,18 @@ ir_expression::constant_expression_value() switch (op[0]->type->base_type) { case GLSL_TYPE_UINT: + if (op[1]->value.u[c1] == 0) + return NULL; data.u[c] = op[0]->value.u[c0] % op[1]->value.u[c1]; break; case GLSL_TYPE_INT: + if (op[1]->value.i[c1] == 0) + return NULL; data.i[c] = op[0]->value.i[c0] % op[1]->value.i[c1]; break; case GLSL_TYPE_FLOAT: + if (op[1]->value.f[c1] == 0) + return NULL; /* We don't use fmod because it rounds toward zero; GLSL specifies * the use of floor. */ diff --git a/pixman/pixman/pixman-private.h b/pixman/pixman/pixman-private.h index 664260b9f..f5d0ba165 100644 --- a/pixman/pixman/pixman-private.h +++ b/pixman/pixman/pixman-private.h @@ -183,6 +183,9 @@ union pixman_image }; typedef struct pixman_iter_t pixman_iter_t; +typedef uint32_t *(* pixman_iter_get_scanline_t) (pixman_iter_t *iter, const uint32_t *mask); +typedef void (* pixman_iter_write_back_t) (pixman_iter_t *iter); + typedef enum { ITER_NARROW = (1 << 0), @@ -209,13 +212,16 @@ typedef enum struct pixman_iter_t { - uint32_t *(* get_scanline) (pixman_iter_t *iter, const uint32_t *mask); - void (* write_back) (pixman_iter_t *iter); + pixman_iter_get_scanline_t get_scanline; + pixman_iter_write_back_t write_back; + + pixman_image_t * image; + uint32_t * buffer; + int x, y; + int width; - pixman_image_t * image; - uint32_t * buffer; - int x, y; - int width; + uint8_t * bits; + int stride; }; void diff --git a/pixman/pixman/pixman-sse2.c b/pixman/pixman/pixman-sse2.c index ae5545604..91adc0560 100644 --- a/pixman/pixman/pixman-sse2.c +++ b/pixman/pixman/pixman-sse2.c @@ -610,81 +610,173 @@ combine4 (const __m128i *ps, const __m128i *pm) } static force_inline void -core_combine_over_u_sse2 (uint32_t* pd, - const uint32_t* ps, - const uint32_t* pm, - int w) +core_combine_over_u_sse2_mask (uint32_t * pd, + const uint32_t* ps, + const uint32_t* pm, + int w) { uint32_t s, d; - __m128i xmm_dst_lo, xmm_dst_hi; - __m128i xmm_src_lo, xmm_src_hi; - __m128i xmm_alpha_lo, xmm_alpha_hi; - /* Align dst on a 16-byte boundary */ while (w && ((unsigned long)pd & 15)) { d = *pd; s = combine1 (ps, pm); - *pd++ = core_combine_over_u_pixel_sse2 (s, d); + if (s) + *pd = core_combine_over_u_pixel_sse2 (s, d); + pd++; ps++; - if (pm) - pm++; + pm++; w--; } while (w >= 4) { - /* I'm loading unaligned because I'm not sure about - * the address alignment. - */ - xmm_src_hi = combine4 ((__m128i*)ps, (__m128i*)pm); + __m128i mask = load_128_unaligned ((__m128i *)pm); - if (is_opaque (xmm_src_hi)) - { - save_128_aligned ((__m128i*)pd, xmm_src_hi); - } - else if (!is_zero (xmm_src_hi)) + if (!is_zero (mask)) { - xmm_dst_hi = load_128_aligned ((__m128i*) pd); + __m128i src; + __m128i src_hi, src_lo; + __m128i mask_hi, mask_lo; + __m128i alpha_hi, alpha_lo; - unpack_128_2x128 (xmm_src_hi, &xmm_src_lo, &xmm_src_hi); - unpack_128_2x128 (xmm_dst_hi, &xmm_dst_lo, &xmm_dst_hi); + src = load_128_unaligned ((__m128i *)ps); - expand_alpha_2x128 ( - xmm_src_lo, xmm_src_hi, &xmm_alpha_lo, &xmm_alpha_hi); + if (is_opaque (_mm_and_si128 (src, mask))) + { + save_128_aligned ((__m128i *)pd, src); + } + else + { + __m128i dst = load_128_aligned ((__m128i *)pd); + __m128i dst_hi, dst_lo; - over_2x128 (&xmm_src_lo, &xmm_src_hi, - &xmm_alpha_lo, &xmm_alpha_hi, - &xmm_dst_lo, &xmm_dst_hi); + unpack_128_2x128 (mask, &mask_lo, &mask_hi); + unpack_128_2x128 (src, &src_lo, &src_hi); - /* rebuid the 4 pixel data and save*/ - save_128_aligned ((__m128i*)pd, - pack_2x128_128 (xmm_dst_lo, xmm_dst_hi)); + expand_alpha_2x128 (mask_lo, mask_hi, &mask_lo, &mask_hi); + pix_multiply_2x128 (&src_lo, &src_hi, + &mask_lo, &mask_hi, + &src_lo, &src_hi); + + unpack_128_2x128 (dst, &dst_lo, &dst_hi); + + expand_alpha_2x128 (src_lo, src_hi, + &alpha_lo, &alpha_hi); + + over_2x128 (&src_lo, &src_hi, &alpha_lo, &alpha_hi, + &dst_lo, &dst_hi); + + save_128_aligned ( + (__m128i *)pd, + pack_2x128_128 (dst_lo, dst_hi)); + } } - w -= 4; + pm += 4; ps += 4; pd += 4; - if (pm) - pm += 4; + w -= 4; } - while (w) { d = *pd; s = combine1 (ps, pm); - *pd++ = core_combine_over_u_pixel_sse2 (s, d); + if (s) + *pd = core_combine_over_u_pixel_sse2 (s, d); + pd++; + ps++; + pm++; + + w--; + } +} + +static force_inline void +core_combine_over_u_sse2_no_mask (uint32_t * pd, + const uint32_t* ps, + int w) +{ + uint32_t s, d; + + /* Align dst on a 16-byte boundary */ + while (w && ((unsigned long)pd & 15)) + { + d = *pd; + s = *ps; + + if (s) + *pd = core_combine_over_u_pixel_sse2 (s, d); + pd++; + ps++; + w--; + } + + while (w >= 4) + { + __m128i src; + __m128i src_hi, src_lo, dst_hi, dst_lo; + __m128i alpha_hi, alpha_lo; + + src = load_128_unaligned ((__m128i *)ps); + + if (!is_zero (src)) + { + if (is_opaque (src)) + { + save_128_aligned ((__m128i *)pd, src); + } + else + { + __m128i dst = load_128_aligned ((__m128i *)pd); + + unpack_128_2x128 (src, &src_lo, &src_hi); + unpack_128_2x128 (dst, &dst_lo, &dst_hi); + + expand_alpha_2x128 (src_lo, src_hi, + &alpha_lo, &alpha_hi); + over_2x128 (&src_lo, &src_hi, &alpha_lo, &alpha_hi, + &dst_lo, &dst_hi); + + save_128_aligned ( + (__m128i *)pd, + pack_2x128_128 (dst_lo, dst_hi)); + } + } + + ps += 4; + pd += 4; + w -= 4; + } + while (w) + { + d = *pd; + s = *ps; + + if (s) + *pd = core_combine_over_u_pixel_sse2 (s, d); + pd++; ps++; - if (pm) - pm++; w--; } } +static force_inline void +core_combine_over_u_sse2 (uint32_t* pd, + const uint32_t* ps, + const uint32_t* pm, + int w) +{ + if (pm) + core_combine_over_u_sse2_mask (pd, ps, pm, w); + else + core_combine_over_u_sse2_no_mask (pd, ps, w); +} + static force_inline void core_combine_over_reverse_u_sse2 (uint32_t* pd, const uint32_t* ps, @@ -5953,6 +6045,188 @@ sse2_fill (pixman_implementation_t *imp, return TRUE; } +static uint32_t * +sse2_fetch_x8r8g8b8 (pixman_iter_t *iter, const uint32_t *mask) +{ + int w = iter->width; + __m128i ff000000 = mask_ff000000; + uint32_t *dst = iter->buffer; + uint32_t *src = (uint32_t *)iter->bits; + + iter->bits += iter->stride; + + while (w && ((unsigned long)dst) & 0x0f) + { + *dst++ = (*src++) | 0xff000000; + w--; + } + + while (w >= 4) + { + save_128_aligned ( + (__m128i *)dst, _mm_or_si128 ( + load_128_unaligned ((__m128i *)src), ff000000)); + + dst += 4; + src += 4; + w -= 4; + } + + while (w) + { + *dst++ = (*src++) | 0xff000000; + w--; + } + + return iter->buffer; +} + +static uint32_t * +sse2_fetch_r5g6b5 (pixman_iter_t *iter, const uint32_t *mask) +{ + int w = iter->width; + uint32_t *dst = iter->buffer; + uint16_t *src = (uint16_t *)iter->bits; + __m128i ff000000 = mask_ff000000; + + iter->bits += iter->stride; + + while (w && ((unsigned long)dst) & 0x0f) + { + uint16_t s = *src++; + + *dst++ = CONVERT_0565_TO_8888 (s); + w--; + } + + while (w >= 8) + { + __m128i lo, hi, s; + + s = _mm_loadu_si128 ((__m128i *)src); + + lo = unpack_565_to_8888 (_mm_unpacklo_epi16 (s, _mm_setzero_si128 ())); + hi = unpack_565_to_8888 (_mm_unpackhi_epi16 (s, _mm_setzero_si128 ())); + + save_128_aligned ((__m128i *)(dst + 0), _mm_or_si128 (lo, ff000000)); + save_128_aligned ((__m128i *)(dst + 4), _mm_or_si128 (hi, ff000000)); + + dst += 8; + src += 8; + w -= 8; + } + + while (w) + { + uint16_t s = *src++; + + *dst++ = CONVERT_0565_TO_8888 (s); + w--; + } + + return iter->buffer; +} + +static uint32_t * +sse2_fetch_a8 (pixman_iter_t *iter, const uint32_t *mask) +{ + int w = iter->width; + uint32_t *dst = iter->buffer; + uint8_t *src = iter->bits; + __m128i xmm0, xmm1, xmm2, xmm3, xmm4, xmm5, xmm6; + + iter->bits += iter->stride; + + while (w && (((unsigned long)dst) & 15)) + { + *dst++ = *(src++) << 24; + w--; + } + + while (w >= 16) + { + xmm0 = _mm_loadu_si128((__m128i *)src); + + xmm1 = _mm_unpacklo_epi8 (_mm_setzero_si128(), xmm0); + xmm2 = _mm_unpackhi_epi8 (_mm_setzero_si128(), xmm0); + xmm3 = _mm_unpacklo_epi16 (_mm_setzero_si128(), xmm1); + xmm4 = _mm_unpackhi_epi16 (_mm_setzero_si128(), xmm1); + xmm5 = _mm_unpacklo_epi16 (_mm_setzero_si128(), xmm2); + xmm6 = _mm_unpackhi_epi16 (_mm_setzero_si128(), xmm2); + + _mm_store_si128(((__m128i *)(dst + 0)), xmm3); + _mm_store_si128(((__m128i *)(dst + 4)), xmm4); + _mm_store_si128(((__m128i *)(dst + 8)), xmm5); + _mm_store_si128(((__m128i *)(dst + 12)), xmm6); + + dst += 16; + src += 16; + w -= 16; + } + + while (w) + { + *dst++ = *(src++) << 24; + w--; + } + + return iter->buffer; +} + +typedef struct +{ + pixman_format_code_t format; + pixman_iter_get_scanline_t get_scanline; +} fetcher_info_t; + +static const fetcher_info_t fetchers[] = +{ + { PIXMAN_x8r8g8b8, sse2_fetch_x8r8g8b8 }, + { PIXMAN_r5g6b5, sse2_fetch_r5g6b5 }, + { PIXMAN_a8, sse2_fetch_a8 }, + { PIXMAN_null } +}; + +static void +sse2_src_iter_init (pixman_implementation_t *imp, + pixman_iter_t *iter, + pixman_image_t *image, + int x, int y, int width, int height, + uint8_t *buffer, iter_flags_t flags) +{ +#define FLAGS \ + (FAST_PATH_STANDARD_FLAGS | FAST_PATH_ID_TRANSFORM) + + if ((flags & ITER_NARROW) && + (image->common.flags & FLAGS) == FLAGS && + x >= 0 && y >= 0 && + x + width <= image->bits.width && + y + height <= image->bits.height) + { + const fetcher_info_t *f; + + for (f = &fetchers[0]; f->format != PIXMAN_null; f++) + { + if (image->common.extended_format_code == f->format) + { + uint8_t *b = (uint8_t *)image->bits.bits; + int s = image->bits.rowstride * 4; + + iter->bits = b + s * y + x * PIXMAN_FORMAT_BPP (f->format) / 8; + iter->stride = s; + iter->width = width; + iter->buffer = (uint32_t *)buffer; + + iter->get_scanline = f->get_scanline; + return; + } + } + } + + _pixman_implementation_src_iter_init ( + imp->delegate, iter, image, x, y, width, height, buffer, flags); +} + #if defined(__GNUC__) && !defined(__x86_64__) && !defined(__amd64__) __attribute__((__force_align_arg_pointer__)) #endif @@ -6020,6 +6294,8 @@ _pixman_implementation_create_sse2 (pixman_implementation_t *fallback) imp->blt = sse2_blt; imp->fill = sse2_fill; + imp->src_iter_init = sse2_src_iter_init; + return imp; } diff --git a/pixman/test/lowlevel-blt-bench.c b/pixman/test/lowlevel-blt-bench.c index 343aafee9..67c845f8f 100644 --- a/pixman/test/lowlevel-blt-bench.c +++ b/pixman/test/lowlevel-blt-bench.c @@ -1,712 +1,713 @@ -/* - * Copyright © 2009 Nokia Corporation - * Copyright © 2010 Movial Creative Technologies Oy - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - */ - -#include -#include -#include -#include - -#ifdef HAVE_CONFIG_H -#include -#endif - -#include "pixman-private.h" -#include "utils.h" - -#define SOLID_FLAG 1 -#define CA_FLAG 2 - -#define L1CACHE_SIZE (8 * 1024) -#define L2CACHE_SIZE (128 * 1024) - -#define WIDTH 1920 -#define HEIGHT 1080 -#define BUFSIZE (WIDTH * HEIGHT * 4) -#define XWIDTH 256 -#define XHEIGHT 256 -#define TILEWIDTH 32 -#define TINYWIDTH 8 - -#define EXCLUDE_OVERHEAD 1 - -uint32_t *dst; -uint32_t *src; -uint32_t *mask; - -double bandwidth = 0; - -double -bench_memcpy () -{ - int64_t n = 0, total; - double t1, t2; - int x = 0; - - t1 = gettime (); - while (1) - { - memcpy (dst, src, BUFSIZE - 64); - memcpy (src, dst, BUFSIZE - 64); - n += 4 * (BUFSIZE - 64); - t2 = gettime (); - if (t2 - t1 > 0.5) - break; - } - n = total = n * 5; - t1 = gettime (); - while (n > 0) - { - if (++x >= 64) - x = 0; - memcpy ((char *)dst + 1, (char *)src + x, BUFSIZE - 64); - memcpy ((char *)src + 1, (char *)dst + x, BUFSIZE - 64); - n -= 4 * (BUFSIZE - 64); - } - t2 = gettime (); - return (double)total / (t2 - t1); -} - -static void -pixman_image_composite_wrapper (pixman_implementation_t *impl, - pixman_op_t op, - pixman_image_t * src_image, - pixman_image_t * mask_image, - pixman_image_t * dst_image, - int32_t src_x, - int32_t src_y, - int32_t mask_x, - int32_t mask_y, - int32_t dest_x, - int32_t dest_y, - int32_t width, - int32_t height) -{ - pixman_image_composite (op, src_image, mask_image, dst_image, src_x, - src_y, mask_x, mask_y, dest_x, dest_y, width, height); -} - -static void -pixman_image_composite_empty (pixman_implementation_t *impl, - pixman_op_t op, - pixman_image_t * src_image, - pixman_image_t * mask_image, - pixman_image_t * dst_image, - int32_t src_x, - int32_t src_y, - int32_t mask_x, - int32_t mask_y, - int32_t dest_x, - int32_t dest_y, - int32_t width, - int32_t height) -{ - pixman_image_composite (op, src_image, mask_image, dst_image, 0, - 0, 0, 0, 0, 0, 1, 1); -} - -void -noinline -bench_L (pixman_op_t op, - pixman_image_t * src_img, - pixman_image_t * mask_img, - pixman_image_t * dst_img, - int64_t n, - pixman_composite_func_t func, - int width, - int lines_count) -{ - int64_t i, j; - int x = 0; - int q = 0; - volatile int qx; - - for (i = 0; i < n; i++) - { - /* touch destination buffer to fetch it into L1 cache */ - for (j = 0; j < width + 64; j += 16) { - q += dst[j]; - q += src[j]; - } - if (++x >= 64) - x = 0; - func (0, op, src_img, mask_img, dst_img, x, 0, x, 0, 63 - x, 0, width, lines_count); - } - qx = q; -} - -void -noinline -bench_M (pixman_op_t op, - pixman_image_t * src_img, - pixman_image_t * mask_img, - pixman_image_t * dst_img, - int64_t n, - pixman_composite_func_t func) -{ - int64_t i; - int x = 0; - - for (i = 0; i < n; i++) - { - if (++x >= 64) - x = 0; - func (0, op, src_img, mask_img, dst_img, x, 0, x, 0, 1, 0, WIDTH - 64, HEIGHT); - } -} - -double -noinline -bench_HT (pixman_op_t op, - pixman_image_t * src_img, - pixman_image_t * mask_img, - pixman_image_t * dst_img, - int64_t n, - pixman_composite_func_t func) -{ - double pix_cnt = 0; - int x = 0; - int y = 0; - int64_t i; - - srand (0); - for (i = 0; i < n; i++) - { - int w = (rand () % (TILEWIDTH * 2)) + 1; - int h = (rand () % (TILEWIDTH * 2)) + 1; - if (x + w > WIDTH) - { - x = 0; - y += TILEWIDTH * 2; - } - if (y + h > HEIGHT) - { - y = 0; - } - func (0, op, src_img, mask_img, dst_img, x, y, x, y, x, y, w, h); - x += w; - pix_cnt += w * h; - } - return pix_cnt; -} - -double -noinline -bench_VT (pixman_op_t op, - pixman_image_t * src_img, - pixman_image_t * mask_img, - pixman_image_t * dst_img, - int64_t n, - pixman_composite_func_t func) -{ - double pix_cnt = 0; - int x = 0; - int y = 0; - int64_t i; - - srand (0); - for (i = 0; i < n; i++) - { - int w = (rand () % (TILEWIDTH * 2)) + 1; - int h = (rand () % (TILEWIDTH * 2)) + 1; - if (y + h > HEIGHT) - { - y = 0; - x += TILEWIDTH * 2; - } - if (x + w > WIDTH) - { - x = 0; - } - func (0, op, src_img, mask_img, dst_img, x, y, x, y, x, y, w, h); - y += h; - pix_cnt += w * h; - } - return pix_cnt; -} - -double -noinline -bench_R (pixman_op_t op, - pixman_image_t * src_img, - pixman_image_t * mask_img, - pixman_image_t * dst_img, - int64_t n, - pixman_composite_func_t func, - int maxw, - int maxh) -{ - double pix_cnt = 0; - int64_t i; - - if (maxw <= TILEWIDTH * 2 || maxh <= TILEWIDTH * 2) - { - printf("error: maxw <= TILEWIDTH * 2 || maxh <= TILEWIDTH * 2\n"); - return 0; - } - - srand (0); - for (i = 0; i < n; i++) - { - int w = (rand () % (TILEWIDTH * 2)) + 1; - int h = (rand () % (TILEWIDTH * 2)) + 1; - int sx = rand () % (maxw - TILEWIDTH * 2); - int sy = rand () % (maxh - TILEWIDTH * 2); - int dx = rand () % (maxw - TILEWIDTH * 2); - int dy = rand () % (maxh - TILEWIDTH * 2); - func (0, op, src_img, mask_img, dst_img, sx, sy, sx, sy, dx, dy, w, h); - pix_cnt += w * h; - } - return pix_cnt; -} - -double -noinline -bench_RT (pixman_op_t op, - pixman_image_t * src_img, - pixman_image_t * mask_img, - pixman_image_t * dst_img, - int64_t n, - pixman_composite_func_t func, - int maxw, - int maxh) -{ - double pix_cnt = 0; - int64_t i; - - if (maxw <= TINYWIDTH * 2 || maxh <= TINYWIDTH * 2) - { - printf("error: maxw <= TINYWIDTH * 2 || maxh <= TINYWIDTH * 2\n"); - return 0; - } - - srand (0); - for (i = 0; i < n; i++) - { - int w = (rand () % (TINYWIDTH * 2)) + 1; - int h = (rand () % (TINYWIDTH * 2)) + 1; - int sx = rand () % (maxw - TINYWIDTH * 2); - int sy = rand () % (maxh - TINYWIDTH * 2); - int dx = rand () % (maxw - TINYWIDTH * 2); - int dy = rand () % (maxh - TINYWIDTH * 2); - func (0, op, src_img, mask_img, dst_img, sx, sy, sx, sy, dx, dy, w, h); - pix_cnt += w * h; - } - return pix_cnt; -} - -void -bench_composite (char * testname, - int src_fmt, - int src_flags, - int op, - int mask_fmt, - int mask_flags, - int dst_fmt, - double npix) -{ - pixman_image_t * src_img; - pixman_image_t * dst_img; - pixman_image_t * mask_img; - pixman_image_t * xsrc_img; - pixman_image_t * xdst_img; - pixman_image_t * xmask_img; - double t1, t2, t3, pix_cnt; - int64_t n, l1test_width, nlines; - double bytes_per_pix = 0; - - pixman_composite_func_t func = pixman_image_composite_wrapper; - - if (!(src_flags & SOLID_FLAG)) - { - bytes_per_pix += (src_fmt >> 24) / 8.0; - src_img = pixman_image_create_bits (src_fmt, - WIDTH, HEIGHT, - src, - WIDTH * 4); - xsrc_img = pixman_image_create_bits (src_fmt, - XWIDTH, XHEIGHT, - src, - XWIDTH * 4); - } - else - { - src_img = pixman_image_create_bits (src_fmt, - 1, 1, - src, - 4); - xsrc_img = pixman_image_create_bits (src_fmt, - 1, 1, - src, - 4); - pixman_image_set_repeat (src_img, PIXMAN_REPEAT_NORMAL); - pixman_image_set_repeat (xsrc_img, PIXMAN_REPEAT_NORMAL); - } - - bytes_per_pix += (dst_fmt >> 24) / 8.0; - dst_img = pixman_image_create_bits (dst_fmt, - WIDTH, HEIGHT, - dst, - WIDTH * 4); - - mask_img = NULL; - xmask_img = NULL; - if (!(mask_flags & SOLID_FLAG) && mask_fmt != PIXMAN_null) - { - bytes_per_pix += (mask_fmt >> 24) / ((op == PIXMAN_OP_SRC) ? 8.0 : 4.0); - mask_img = pixman_image_create_bits (mask_fmt, - WIDTH, HEIGHT, - mask, - WIDTH * 4); - xmask_img = pixman_image_create_bits (mask_fmt, - XWIDTH, XHEIGHT, - mask, - XWIDTH * 4); - } - else if (mask_fmt != PIXMAN_null) - { - mask_img = pixman_image_create_bits (mask_fmt, - 1, 1, - mask, - 4); - xmask_img = pixman_image_create_bits (mask_fmt, - 1, 1, - mask, - 4 * 4); - pixman_image_set_repeat (mask_img, PIXMAN_REPEAT_NORMAL); - pixman_image_set_repeat (xmask_img, PIXMAN_REPEAT_NORMAL); - } - if ((mask_flags & CA_FLAG) && mask_fmt != PIXMAN_null) - { - pixman_image_set_component_alpha (mask_img, 1); - } - xdst_img = pixman_image_create_bits (dst_fmt, - XWIDTH, XHEIGHT, - dst, - XWIDTH * 4); - - - printf ("%24s %c", testname, func != pixman_image_composite_wrapper ? - '-' : '='); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - l1test_width = L1CACHE_SIZE / 8 - 64; - if (l1test_width < 1) - l1test_width = 1; - if (l1test_width > WIDTH - 64) - l1test_width = WIDTH - 64; - n = 1 + npix / (l1test_width * 8); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - bench_L (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, l1test_width, 1); -#endif - t2 = gettime (); - bench_L (op, src_img, mask_img, dst_img, n, func, l1test_width, 1); - t3 = gettime (); - printf (" L1:%7.2f", (double)n * l1test_width * 1 / - ((t3 - t2) - (t2 - t1)) / 1000000.); - fflush (stdout); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - nlines = (L2CACHE_SIZE / l1test_width) / - ((PIXMAN_FORMAT_BPP(src_fmt) + PIXMAN_FORMAT_BPP(dst_fmt)) / 8); - if (nlines < 1) - nlines = 1; - n = 1 + npix / (l1test_width * nlines); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - bench_L (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, l1test_width, nlines); -#endif - t2 = gettime (); - bench_L (op, src_img, mask_img, dst_img, n, func, l1test_width, nlines); - t3 = gettime (); - printf (" L2:%7.2f", (double)n * l1test_width * nlines / - ((t3 - t2) - (t2 - t1)) / 1000000.); - fflush (stdout); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - n = 1 + npix / (WIDTH * HEIGHT); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - bench_M (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty); -#endif - t2 = gettime (); - bench_M (op, src_img, mask_img, dst_img, n, func); - t3 = gettime (); - printf (" M:%6.2f (%6.2f%%)", - ((double)n * (WIDTH - 64) * HEIGHT / ((t3 - t2) - (t2 - t1))) / 1000000., - ((double)n * (WIDTH - 64) * HEIGHT / ((t3 - t2) - (t2 - t1)) * bytes_per_pix) * (100.0 / bandwidth) ); - fflush (stdout); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - n = 1 + npix / (8 * TILEWIDTH * TILEWIDTH); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - pix_cnt = bench_HT (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty); -#endif - t2 = gettime (); - pix_cnt = bench_HT (op, src_img, mask_img, dst_img, n, func); - t3 = gettime (); - printf (" HT:%6.2f", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000.); - fflush (stdout); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - n = 1 + npix / (8 * TILEWIDTH * TILEWIDTH); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - pix_cnt = bench_VT (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty); -#endif - t2 = gettime (); - pix_cnt = bench_VT (op, src_img, mask_img, dst_img, n, func); - t3 = gettime (); - printf (" VT:%6.2f", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000.); - fflush (stdout); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - n = 1 + npix / (8 * TILEWIDTH * TILEWIDTH); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - pix_cnt = bench_R (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, WIDTH, HEIGHT); -#endif - t2 = gettime (); - pix_cnt = bench_R (op, src_img, mask_img, dst_img, n, func, WIDTH, HEIGHT); - t3 = gettime (); - printf (" R:%6.2f", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000.); - fflush (stdout); - - memcpy (src, dst, BUFSIZE); - memcpy (dst, src, BUFSIZE); - - n = 1 + npix / (16 * TINYWIDTH * TINYWIDTH); - t1 = gettime (); -#if EXCLUDE_OVERHEAD - pix_cnt = bench_RT (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, WIDTH, HEIGHT); -#endif - t2 = gettime (); - pix_cnt = bench_RT (op, src_img, mask_img, dst_img, n, func, WIDTH, HEIGHT); - t3 = gettime (); - printf (" RT:%6.2f (%4.0fKops/s)\n", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000., (double) n / ((t3 - t2) * 1000)); - - if (mask_img) { - pixman_image_unref (mask_img); - pixman_image_unref (xmask_img); - } - pixman_image_unref (src_img); - pixman_image_unref (dst_img); - pixman_image_unref (xsrc_img); - pixman_image_unref (xdst_img); -} - -#define PIXMAN_OP_OUT_REV (PIXMAN_OP_OUT_REVERSE) - -struct -{ - char *testname; - int src_fmt; - int src_flags; - int op; - int mask_fmt; - int mask_flags; - int dst_fmt; -} -tests_tbl[] = -{ - { "add_8_8_8", PIXMAN_a8, 0, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a8 }, - { "add_n_8_8", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a8 }, - { "add_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, - { "add_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, - { "add_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "add_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, - { "add_n_8_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a4r4g4b4 }, - { "add_n_8_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a2r2g2b2 }, - { "add_n_8_2x10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_x2r10g10b10 }, - { "add_n_8_2a10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a2r10g10b10 }, - { "add_n_8", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8 }, - { "add_n_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "add_n_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "add_n_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "add_n_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, - { "add_n_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, - { "add_n_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, - { "add_n_2x10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, - { "add_n_2a10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, - { "add_8_8", PIXMAN_a8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8 }, - { "add_x888_x888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "add_8888_8888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "add_8888_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "add_8888_1555", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, - { "add_8888_4444", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, - { "add_8888_2222", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, - { "add_0565_0565", PIXMAN_r5g6b5, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "add_1555_1555", PIXMAN_a1r5g5b5, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, - { "add_0565_2x10", PIXMAN_r5g6b5, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, - { "add_2a10_2a10", PIXMAN_a2r10g10b10, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, - { "src_n_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, - { "src_n_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "src_n_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, - { "src_n_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, - { "src_n_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "src_n_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "src_n_2x10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, - { "src_n_2a10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, - { "src_8888_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "src_8888_4444", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, - { "src_8888_2222", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, - { "src_8888_2x10", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, - { "src_8888_2a10", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, - { "src_0888_0565", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "src_0888_8888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "src_0888_x888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "src_x888_x888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "src_x888_8888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "src_8888_8888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "src_0565_0565", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "src_1555_0565", PIXMAN_a1r5g5b5, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "src_0565_1555", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, - { "src_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "src_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, - { "src_n_8_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a4r4g4b4 }, - { "src_n_8_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a2r2g2b2 }, - { "src_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, - { "src_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, - { "src_n_8_2x10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x2r10g10b10 }, - { "src_n_8_2a10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a2r10g10b10 }, - { "src_8888_8_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "src_0888_8_0565", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "src_0888_8_8888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, - { "src_0888_8_x888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, - { "src_x888_8_x888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, - { "src_x888_8_8888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, - { "src_0565_8_0565", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "src_1555_8_0565", PIXMAN_a1r5g5b5, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "src_0565_8_1555", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, - { "over_n_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "over_n_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, - { "over_n_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "over_n_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, - { "over_8888_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_r5g6b5 }, - { "over_8888_x888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, - { "over_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "over_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, - { "over_n_8_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a4r4g4b4 }, - { "over_n_8_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a2r2g2b2 }, - { "over_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, - { "over_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, - { "over_n_8_2x10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_x2r10g10b10 }, - { "over_n_8_2a10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a2r10g10b10 }, - { "over_n_8888_8888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a8r8g8b8 }, - { "over_n_8888_x888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_x8r8g8b8 }, - { "over_n_8888_0565_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_r5g6b5 }, - { "over_n_8888_1555_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a1r5g5b5 }, - { "over_n_8888_4444_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a4r4g4b4 }, - { "over_n_8888_2222_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a2r2g2b2 }, - { "over_n_8888_2x10_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_x2r10g10b10 }, - { "over_n_8888_2a10_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a2r10g10b10 }, - { "over_8888_n_8888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_a8r8g8b8 }, - { "over_8888_n_x888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_x8r8g8b8 }, - { "over_8888_n_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_r5g6b5 }, - { "over_8888_n_1555", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_a1r5g5b5 }, - { "outrev_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, - { "outrev_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, - { "outrev_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, - { "outrev_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, - { "outrev_n_8888_0565_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_r5g6b5 }, - { "outrev_n_8888_1555_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_a1r5g5b5 }, - { "outrev_n_8888_x888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_x8r8g8b8 }, - { "outrev_n_8888_8888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_a8r8g8b8 }, -}; - -int -main (int argc, char *argv[]) -{ - double x; - int i; - char *pattern = argc > 1 ? argv[1] : "all"; - - src = aligned_malloc (4096, BUFSIZE * 3); - memset (src, 0xCC, BUFSIZE * 3); - dst = src + (BUFSIZE / 4); - mask = dst + (BUFSIZE / 4); - - printf ("Benchmark for a set of most commonly used functions\n"); - printf ("---\n"); - printf ("All results are presented in millions of pixels per second\n"); - printf ("L1 - small Xx1 rectangle (fitting L1 cache), always blitted at the same\n"); - printf (" memory location with small drift in horizontal direction\n"); - printf ("L2 - small XxY rectangle (fitting L2 cache), always blitted at the same\n"); - printf (" memory location with small drift in horizontal direction\n"); - printf ("M - large %dx%d rectangle, always blitted at the same\n", - WIDTH - 64, HEIGHT); - printf (" memory location with small drift in horizontal direction\n"); - printf ("HT - random rectangles with %dx%d average size are copied from\n", - TILEWIDTH, TILEWIDTH); - printf (" one %dx%d buffer to another, traversing from left to right\n", - WIDTH, HEIGHT); - printf (" and from top to bottom\n"); - printf ("VT - random rectangles with %dx%d average size are copied from\n", - TILEWIDTH, TILEWIDTH); - printf (" one %dx%d buffer to another, traversing from top to bottom\n", - WIDTH, HEIGHT); - printf (" and from left to right\n"); - printf ("R - random rectangles with %dx%d average size are copied from\n", - TILEWIDTH, TILEWIDTH); - printf (" random locations of one %dx%d buffer to another\n", - WIDTH, HEIGHT); - printf ("RT - as R, but %dx%d average sized rectangles are copied\n", - TINYWIDTH, TINYWIDTH); - printf ("---\n"); - bandwidth = x = bench_memcpy (); - printf ("reference memcpy speed = %.1fMB/s (%.1fMP/s for 32bpp fills)\n", - x / 1000000., x / 4000000); - printf ("---\n"); - - for (i = 0; i < sizeof(tests_tbl) / sizeof(tests_tbl[0]); i++) - { - if (strcmp (pattern, "all") == 0 || strstr (tests_tbl[i].testname, pattern)) - { - bench_composite (tests_tbl[i].testname, - tests_tbl[i].src_fmt, - tests_tbl[i].src_flags, - tests_tbl[i].op, - tests_tbl[i].mask_fmt, - tests_tbl[i].mask_flags, - tests_tbl[i].dst_fmt, - bandwidth/8); - } - } - - free (src); - return 0; -} +/* + * Copyright © 2009 Nokia Corporation + * Copyright © 2010 Movial Creative Technologies Oy + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + +#include +#include +#include +#include + +#ifdef HAVE_CONFIG_H +#include +#endif + +#include "pixman-private.h" +#include "utils.h" + +#define SOLID_FLAG 1 +#define CA_FLAG 2 + +#define L1CACHE_SIZE (8 * 1024) +#define L2CACHE_SIZE (128 * 1024) + +#define WIDTH 1920 +#define HEIGHT 1080 +#define BUFSIZE (WIDTH * HEIGHT * 4) +#define XWIDTH 256 +#define XHEIGHT 256 +#define TILEWIDTH 32 +#define TINYWIDTH 8 + +#define EXCLUDE_OVERHEAD 1 + +uint32_t *dst; +uint32_t *src; +uint32_t *mask; + +double bandwidth = 0; + +double +bench_memcpy () +{ + int64_t n = 0, total; + double t1, t2; + int x = 0; + + t1 = gettime (); + while (1) + { + memcpy (dst, src, BUFSIZE - 64); + memcpy (src, dst, BUFSIZE - 64); + n += 4 * (BUFSIZE - 64); + t2 = gettime (); + if (t2 - t1 > 0.5) + break; + } + n = total = n * 5; + t1 = gettime (); + while (n > 0) + { + if (++x >= 64) + x = 0; + memcpy ((char *)dst + 1, (char *)src + x, BUFSIZE - 64); + memcpy ((char *)src + 1, (char *)dst + x, BUFSIZE - 64); + n -= 4 * (BUFSIZE - 64); + } + t2 = gettime (); + return (double)total / (t2 - t1); +} + +static void +pixman_image_composite_wrapper (pixman_implementation_t *impl, + pixman_op_t op, + pixman_image_t * src_image, + pixman_image_t * mask_image, + pixman_image_t * dst_image, + int32_t src_x, + int32_t src_y, + int32_t mask_x, + int32_t mask_y, + int32_t dest_x, + int32_t dest_y, + int32_t width, + int32_t height) +{ + pixman_image_composite (op, src_image, mask_image, dst_image, src_x, + src_y, mask_x, mask_y, dest_x, dest_y, width, height); +} + +static void +pixman_image_composite_empty (pixman_implementation_t *impl, + pixman_op_t op, + pixman_image_t * src_image, + pixman_image_t * mask_image, + pixman_image_t * dst_image, + int32_t src_x, + int32_t src_y, + int32_t mask_x, + int32_t mask_y, + int32_t dest_x, + int32_t dest_y, + int32_t width, + int32_t height) +{ + pixman_image_composite (op, src_image, mask_image, dst_image, 0, + 0, 0, 0, 0, 0, 1, 1); +} + +void +noinline +bench_L (pixman_op_t op, + pixman_image_t * src_img, + pixman_image_t * mask_img, + pixman_image_t * dst_img, + int64_t n, + pixman_composite_func_t func, + int width, + int lines_count) +{ + int64_t i, j; + int x = 0; + int q = 0; + volatile int qx; + + for (i = 0; i < n; i++) + { + /* touch destination buffer to fetch it into L1 cache */ + for (j = 0; j < width + 64; j += 16) { + q += dst[j]; + q += src[j]; + } + if (++x >= 64) + x = 0; + func (0, op, src_img, mask_img, dst_img, x, 0, x, 0, 63 - x, 0, width, lines_count); + } + qx = q; +} + +void +noinline +bench_M (pixman_op_t op, + pixman_image_t * src_img, + pixman_image_t * mask_img, + pixman_image_t * dst_img, + int64_t n, + pixman_composite_func_t func) +{ + int64_t i; + int x = 0; + + for (i = 0; i < n; i++) + { + if (++x >= 64) + x = 0; + func (0, op, src_img, mask_img, dst_img, x, 0, x, 0, 1, 0, WIDTH - 64, HEIGHT); + } +} + +double +noinline +bench_HT (pixman_op_t op, + pixman_image_t * src_img, + pixman_image_t * mask_img, + pixman_image_t * dst_img, + int64_t n, + pixman_composite_func_t func) +{ + double pix_cnt = 0; + int x = 0; + int y = 0; + int64_t i; + + srand (0); + for (i = 0; i < n; i++) + { + int w = (rand () % (TILEWIDTH * 2)) + 1; + int h = (rand () % (TILEWIDTH * 2)) + 1; + if (x + w > WIDTH) + { + x = 0; + y += TILEWIDTH * 2; + } + if (y + h > HEIGHT) + { + y = 0; + } + func (0, op, src_img, mask_img, dst_img, x, y, x, y, x, y, w, h); + x += w; + pix_cnt += w * h; + } + return pix_cnt; +} + +double +noinline +bench_VT (pixman_op_t op, + pixman_image_t * src_img, + pixman_image_t * mask_img, + pixman_image_t * dst_img, + int64_t n, + pixman_composite_func_t func) +{ + double pix_cnt = 0; + int x = 0; + int y = 0; + int64_t i; + + srand (0); + for (i = 0; i < n; i++) + { + int w = (rand () % (TILEWIDTH * 2)) + 1; + int h = (rand () % (TILEWIDTH * 2)) + 1; + if (y + h > HEIGHT) + { + y = 0; + x += TILEWIDTH * 2; + } + if (x + w > WIDTH) + { + x = 0; + } + func (0, op, src_img, mask_img, dst_img, x, y, x, y, x, y, w, h); + y += h; + pix_cnt += w * h; + } + return pix_cnt; +} + +double +noinline +bench_R (pixman_op_t op, + pixman_image_t * src_img, + pixman_image_t * mask_img, + pixman_image_t * dst_img, + int64_t n, + pixman_composite_func_t func, + int maxw, + int maxh) +{ + double pix_cnt = 0; + int64_t i; + + if (maxw <= TILEWIDTH * 2 || maxh <= TILEWIDTH * 2) + { + printf("error: maxw <= TILEWIDTH * 2 || maxh <= TILEWIDTH * 2\n"); + return 0; + } + + srand (0); + for (i = 0; i < n; i++) + { + int w = (rand () % (TILEWIDTH * 2)) + 1; + int h = (rand () % (TILEWIDTH * 2)) + 1; + int sx = rand () % (maxw - TILEWIDTH * 2); + int sy = rand () % (maxh - TILEWIDTH * 2); + int dx = rand () % (maxw - TILEWIDTH * 2); + int dy = rand () % (maxh - TILEWIDTH * 2); + func (0, op, src_img, mask_img, dst_img, sx, sy, sx, sy, dx, dy, w, h); + pix_cnt += w * h; + } + return pix_cnt; +} + +double +noinline +bench_RT (pixman_op_t op, + pixman_image_t * src_img, + pixman_image_t * mask_img, + pixman_image_t * dst_img, + int64_t n, + pixman_composite_func_t func, + int maxw, + int maxh) +{ + double pix_cnt = 0; + int64_t i; + + if (maxw <= TINYWIDTH * 2 || maxh <= TINYWIDTH * 2) + { + printf("error: maxw <= TINYWIDTH * 2 || maxh <= TINYWIDTH * 2\n"); + return 0; + } + + srand (0); + for (i = 0; i < n; i++) + { + int w = (rand () % (TINYWIDTH * 2)) + 1; + int h = (rand () % (TINYWIDTH * 2)) + 1; + int sx = rand () % (maxw - TINYWIDTH * 2); + int sy = rand () % (maxh - TINYWIDTH * 2); + int dx = rand () % (maxw - TINYWIDTH * 2); + int dy = rand () % (maxh - TINYWIDTH * 2); + func (0, op, src_img, mask_img, dst_img, sx, sy, sx, sy, dx, dy, w, h); + pix_cnt += w * h; + } + return pix_cnt; +} + +void +bench_composite (char * testname, + int src_fmt, + int src_flags, + int op, + int mask_fmt, + int mask_flags, + int dst_fmt, + double npix) +{ + pixman_image_t * src_img; + pixman_image_t * dst_img; + pixman_image_t * mask_img; + pixman_image_t * xsrc_img; + pixman_image_t * xdst_img; + pixman_image_t * xmask_img; + double t1, t2, t3, pix_cnt; + int64_t n, l1test_width, nlines; + double bytes_per_pix = 0; + + pixman_composite_func_t func = pixman_image_composite_wrapper; + + if (!(src_flags & SOLID_FLAG)) + { + bytes_per_pix += (src_fmt >> 24) / 8.0; + src_img = pixman_image_create_bits (src_fmt, + WIDTH, HEIGHT, + src, + WIDTH * 4); + xsrc_img = pixman_image_create_bits (src_fmt, + XWIDTH, XHEIGHT, + src, + XWIDTH * 4); + } + else + { + src_img = pixman_image_create_bits (src_fmt, + 1, 1, + src, + 4); + xsrc_img = pixman_image_create_bits (src_fmt, + 1, 1, + src, + 4); + pixman_image_set_repeat (src_img, PIXMAN_REPEAT_NORMAL); + pixman_image_set_repeat (xsrc_img, PIXMAN_REPEAT_NORMAL); + } + + bytes_per_pix += (dst_fmt >> 24) / 8.0; + dst_img = pixman_image_create_bits (dst_fmt, + WIDTH, HEIGHT, + dst, + WIDTH * 4); + + mask_img = NULL; + xmask_img = NULL; + if (!(mask_flags & SOLID_FLAG) && mask_fmt != PIXMAN_null) + { + bytes_per_pix += (mask_fmt >> 24) / ((op == PIXMAN_OP_SRC) ? 8.0 : 4.0); + mask_img = pixman_image_create_bits (mask_fmt, + WIDTH, HEIGHT, + mask, + WIDTH * 4); + xmask_img = pixman_image_create_bits (mask_fmt, + XWIDTH, XHEIGHT, + mask, + XWIDTH * 4); + } + else if (mask_fmt != PIXMAN_null) + { + mask_img = pixman_image_create_bits (mask_fmt, + 1, 1, + mask, + 4); + xmask_img = pixman_image_create_bits (mask_fmt, + 1, 1, + mask, + 4 * 4); + pixman_image_set_repeat (mask_img, PIXMAN_REPEAT_NORMAL); + pixman_image_set_repeat (xmask_img, PIXMAN_REPEAT_NORMAL); + } + if ((mask_flags & CA_FLAG) && mask_fmt != PIXMAN_null) + { + pixman_image_set_component_alpha (mask_img, 1); + } + xdst_img = pixman_image_create_bits (dst_fmt, + XWIDTH, XHEIGHT, + dst, + XWIDTH * 4); + + + printf ("%24s %c", testname, func != pixman_image_composite_wrapper ? + '-' : '='); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + l1test_width = L1CACHE_SIZE / 8 - 64; + if (l1test_width < 1) + l1test_width = 1; + if (l1test_width > WIDTH - 64) + l1test_width = WIDTH - 64; + n = 1 + npix / (l1test_width * 8); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + bench_L (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, l1test_width, 1); +#endif + t2 = gettime (); + bench_L (op, src_img, mask_img, dst_img, n, func, l1test_width, 1); + t3 = gettime (); + printf (" L1:%7.2f", (double)n * l1test_width * 1 / + ((t3 - t2) - (t2 - t1)) / 1000000.); + fflush (stdout); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + nlines = (L2CACHE_SIZE / l1test_width) / + ((PIXMAN_FORMAT_BPP(src_fmt) + PIXMAN_FORMAT_BPP(dst_fmt)) / 8); + if (nlines < 1) + nlines = 1; + n = 1 + npix / (l1test_width * nlines); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + bench_L (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, l1test_width, nlines); +#endif + t2 = gettime (); + bench_L (op, src_img, mask_img, dst_img, n, func, l1test_width, nlines); + t3 = gettime (); + printf (" L2:%7.2f", (double)n * l1test_width * nlines / + ((t3 - t2) - (t2 - t1)) / 1000000.); + fflush (stdout); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + n = 1 + npix / (WIDTH * HEIGHT); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + bench_M (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty); +#endif + t2 = gettime (); + bench_M (op, src_img, mask_img, dst_img, n, func); + t3 = gettime (); + printf (" M:%6.2f (%6.2f%%)", + ((double)n * (WIDTH - 64) * HEIGHT / ((t3 - t2) - (t2 - t1))) / 1000000., + ((double)n * (WIDTH - 64) * HEIGHT / ((t3 - t2) - (t2 - t1)) * bytes_per_pix) * (100.0 / bandwidth) ); + fflush (stdout); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + n = 1 + npix / (8 * TILEWIDTH * TILEWIDTH); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + pix_cnt = bench_HT (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty); +#endif + t2 = gettime (); + pix_cnt = bench_HT (op, src_img, mask_img, dst_img, n, func); + t3 = gettime (); + printf (" HT:%6.2f", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000.); + fflush (stdout); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + n = 1 + npix / (8 * TILEWIDTH * TILEWIDTH); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + pix_cnt = bench_VT (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty); +#endif + t2 = gettime (); + pix_cnt = bench_VT (op, src_img, mask_img, dst_img, n, func); + t3 = gettime (); + printf (" VT:%6.2f", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000.); + fflush (stdout); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + n = 1 + npix / (8 * TILEWIDTH * TILEWIDTH); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + pix_cnt = bench_R (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, WIDTH, HEIGHT); +#endif + t2 = gettime (); + pix_cnt = bench_R (op, src_img, mask_img, dst_img, n, func, WIDTH, HEIGHT); + t3 = gettime (); + printf (" R:%6.2f", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000.); + fflush (stdout); + + memcpy (src, dst, BUFSIZE); + memcpy (dst, src, BUFSIZE); + + n = 1 + npix / (16 * TINYWIDTH * TINYWIDTH); + t1 = gettime (); +#if EXCLUDE_OVERHEAD + pix_cnt = bench_RT (op, src_img, mask_img, dst_img, n, pixman_image_composite_empty, WIDTH, HEIGHT); +#endif + t2 = gettime (); + pix_cnt = bench_RT (op, src_img, mask_img, dst_img, n, func, WIDTH, HEIGHT); + t3 = gettime (); + printf (" RT:%6.2f (%4.0fKops/s)\n", (double)pix_cnt / ((t3 - t2) - (t2 - t1)) / 1000000., (double) n / ((t3 - t2) * 1000)); + + if (mask_img) { + pixman_image_unref (mask_img); + pixman_image_unref (xmask_img); + } + pixman_image_unref (src_img); + pixman_image_unref (dst_img); + pixman_image_unref (xsrc_img); + pixman_image_unref (xdst_img); +} + +#define PIXMAN_OP_OUT_REV (PIXMAN_OP_OUT_REVERSE) + +struct +{ + char *testname; + int src_fmt; + int src_flags; + int op; + int mask_fmt; + int mask_flags; + int dst_fmt; +} +tests_tbl[] = +{ + { "add_8_8_8", PIXMAN_a8, 0, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a8 }, + { "add_n_8_8", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a8 }, + { "add_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, + { "add_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, + { "add_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "add_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, + { "add_n_8_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a4r4g4b4 }, + { "add_n_8_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a2r2g2b2 }, + { "add_n_8_2x10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_x2r10g10b10 }, + { "add_n_8_2a10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_a8, 0, PIXMAN_a2r10g10b10 }, + { "add_n_8", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8 }, + { "add_n_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "add_n_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "add_n_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "add_n_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, + { "add_n_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, + { "add_n_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, + { "add_n_2x10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, + { "add_n_2a10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, + { "add_8_8", PIXMAN_a8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8 }, + { "add_x888_x888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "add_8888_8888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "add_8888_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "add_8888_1555", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, + { "add_8888_4444", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, + { "add_8888_2222", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, + { "add_0565_0565", PIXMAN_r5g6b5, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "add_1555_1555", PIXMAN_a1r5g5b5, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, + { "add_0565_2x10", PIXMAN_r5g6b5, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, + { "add_2a10_2a10", PIXMAN_a2r10g10b10, 0, PIXMAN_OP_ADD, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, + { "src_n_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, + { "src_n_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "src_n_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, + { "src_n_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, + { "src_n_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "src_n_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "src_n_2x10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, + { "src_n_2a10", PIXMAN_a2r10g10b10, 1, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, + { "src_8888_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "src_8888_4444", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a4r4g4b4 }, + { "src_8888_2222", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r2g2b2 }, + { "src_8888_2x10", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x2r10g10b10 }, + { "src_8888_2a10", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a2r10g10b10 }, + { "src_0888_0565", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "src_0888_8888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "src_0888_x888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "src_x888_x888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "src_x888_8888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "src_8888_8888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "src_0565_0565", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "src_1555_0565", PIXMAN_a1r5g5b5, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "src_0565_1555", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, + { "src_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "src_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, + { "src_n_8_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a4r4g4b4 }, + { "src_n_8_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a2r2g2b2 }, + { "src_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, + { "src_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, + { "src_n_8_2x10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x2r10g10b10 }, + { "src_n_8_2a10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a2r10g10b10 }, + { "src_8888_8_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "src_0888_8_0565", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "src_0888_8_8888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, + { "src_0888_8_x888", PIXMAN_r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, + { "src_x888_8_x888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, + { "src_x888_8_8888", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, + { "src_0565_8_0565", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "src_1555_8_0565", PIXMAN_a1r5g5b5, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "src_0565_8_1555", PIXMAN_r5g6b5, 0, PIXMAN_OP_SRC, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, + { "over_n_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "over_n_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_a8r8g8b8 }, + { "over_n_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "over_n_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_a1r5g5b5 }, + { "over_8888_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_r5g6b5 }, + { "over_8888_x888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_null, 0, PIXMAN_x8r8g8b8 }, + { "over_x888_8_0565", PIXMAN_x8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "over_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "over_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, + { "over_n_8_4444", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a4r4g4b4 }, + { "over_n_8_2222", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a2r2g2b2 }, + { "over_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, + { "over_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, + { "over_n_8_2x10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_x2r10g10b10 }, + { "over_n_8_2a10", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8, 0, PIXMAN_a2r10g10b10 }, + { "over_n_8888_8888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a8r8g8b8 }, + { "over_n_8888_x888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_x8r8g8b8 }, + { "over_n_8888_0565_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_r5g6b5 }, + { "over_n_8888_1555_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a1r5g5b5 }, + { "over_n_8888_4444_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a4r4g4b4 }, + { "over_n_8888_2222_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a2r2g2b2 }, + { "over_n_8888_2x10_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_x2r10g10b10 }, + { "over_n_8888_2a10_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OVER, PIXMAN_a8r8g8b8, 2, PIXMAN_a2r10g10b10 }, + { "over_8888_n_8888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_a8r8g8b8 }, + { "over_8888_n_x888", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_x8r8g8b8 }, + { "over_8888_n_0565", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_r5g6b5 }, + { "over_8888_n_1555", PIXMAN_a8r8g8b8, 0, PIXMAN_OP_OVER, PIXMAN_a8, 1, PIXMAN_a1r5g5b5 }, + { "outrev_n_8_0565", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_r5g6b5 }, + { "outrev_n_8_1555", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_a1r5g5b5 }, + { "outrev_n_8_x888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_x8r8g8b8 }, + { "outrev_n_8_8888", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8, 0, PIXMAN_a8r8g8b8 }, + { "outrev_n_8888_0565_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_r5g6b5 }, + { "outrev_n_8888_1555_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_a1r5g5b5 }, + { "outrev_n_8888_x888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_x8r8g8b8 }, + { "outrev_n_8888_8888_ca", PIXMAN_a8r8g8b8, 1, PIXMAN_OP_OUT_REV, PIXMAN_a8r8g8b8, 2, PIXMAN_a8r8g8b8 }, +}; + +int +main (int argc, char *argv[]) +{ + double x; + int i; + char *pattern = argc > 1 ? argv[1] : "all"; + + src = aligned_malloc (4096, BUFSIZE * 3); + memset (src, 0xCC, BUFSIZE * 3); + dst = src + (BUFSIZE / 4); + mask = dst + (BUFSIZE / 4); + + printf ("Benchmark for a set of most commonly used functions\n"); + printf ("---\n"); + printf ("All results are presented in millions of pixels per second\n"); + printf ("L1 - small Xx1 rectangle (fitting L1 cache), always blitted at the same\n"); + printf (" memory location with small drift in horizontal direction\n"); + printf ("L2 - small XxY rectangle (fitting L2 cache), always blitted at the same\n"); + printf (" memory location with small drift in horizontal direction\n"); + printf ("M - large %dx%d rectangle, always blitted at the same\n", + WIDTH - 64, HEIGHT); + printf (" memory location with small drift in horizontal direction\n"); + printf ("HT - random rectangles with %dx%d average size are copied from\n", + TILEWIDTH, TILEWIDTH); + printf (" one %dx%d buffer to another, traversing from left to right\n", + WIDTH, HEIGHT); + printf (" and from top to bottom\n"); + printf ("VT - random rectangles with %dx%d average size are copied from\n", + TILEWIDTH, TILEWIDTH); + printf (" one %dx%d buffer to another, traversing from top to bottom\n", + WIDTH, HEIGHT); + printf (" and from left to right\n"); + printf ("R - random rectangles with %dx%d average size are copied from\n", + TILEWIDTH, TILEWIDTH); + printf (" random locations of one %dx%d buffer to another\n", + WIDTH, HEIGHT); + printf ("RT - as R, but %dx%d average sized rectangles are copied\n", + TINYWIDTH, TINYWIDTH); + printf ("---\n"); + bandwidth = x = bench_memcpy (); + printf ("reference memcpy speed = %.1fMB/s (%.1fMP/s for 32bpp fills)\n", + x / 1000000., x / 4000000); + printf ("---\n"); + + for (i = 0; i < sizeof(tests_tbl) / sizeof(tests_tbl[0]); i++) + { + if (strcmp (pattern, "all") == 0 || strstr (tests_tbl[i].testname, pattern)) + { + bench_composite (tests_tbl[i].testname, + tests_tbl[i].src_fmt, + tests_tbl[i].src_flags, + tests_tbl[i].op, + tests_tbl[i].mask_fmt, + tests_tbl[i].mask_flags, + tests_tbl[i].dst_fmt, + bandwidth/8); + } + } + + free (src); + return 0; +} diff --git a/xorg-server/Xext/xf86bigfont.c b/xorg-server/Xext/xf86bigfont.c index da3528783..de8274469 100644 --- a/xorg-server/Xext/xf86bigfont.c +++ b/xorg-server/Xext/xf86bigfont.c @@ -137,51 +137,6 @@ CheckForShmSyscall(void) #endif -void -XFree86BigfontExtensionInit(void) -{ - if (AddExtension(XF86BIGFONTNAME, - XF86BigfontNumberEvents, - XF86BigfontNumberErrors, - ProcXF86BigfontDispatch, - SProcXF86BigfontDispatch, - XF86BigfontResetProc, - StandardMinorOpcode)) { -#ifdef HAS_SHM -#ifdef MUST_CHECK_FOR_SHM_SYSCALL - /* - * Note: Local-clients will not be optimized without shared memory - * support. Remote-client optimization does not depend on shared - * memory support. Thus, the extension is still registered even - * when shared memory support is not functional. - */ - if (!CheckForShmSyscall()) { - ErrorF(XF86BIGFONTNAME " extension local-client optimization disabled due to lack of shared memory support in the kernel\n"); - return; - } -#endif - - srand((unsigned int) time(NULL)); - signature = ((unsigned int) (65536.0/(RAND_MAX+1.0) * rand()) << 16) - + (unsigned int) (65536.0/(RAND_MAX+1.0) * rand()); - /* fprintf(stderr, "signature = 0x%08X\n", signature); */ - - FontShmdescIndex = AllocateFontPrivateIndex(); - -#if !defined(CSRG_BASED) && !defined(__CYGWIN__) - pagesize = SHMLBA; -#else -# ifdef _SC_PAGESIZE - pagesize = sysconf(_SC_PAGESIZE); -# else - pagesize = getpagesize(); -# endif -#endif -#endif - } -} - - /* ========== Management of shared memory segments ========== */ #ifdef HAS_SHM @@ -749,3 +704,47 @@ SProcXF86BigfontDispatch( return BadRequest; } } + +void +XFree86BigfontExtensionInit(void) +{ + if (AddExtension(XF86BIGFONTNAME, + XF86BigfontNumberEvents, + XF86BigfontNumberErrors, + ProcXF86BigfontDispatch, + SProcXF86BigfontDispatch, + XF86BigfontResetProc, + StandardMinorOpcode)) { +#ifdef HAS_SHM +#ifdef MUST_CHECK_FOR_SHM_SYSCALL + /* + * Note: Local-clients will not be optimized without shared memory + * support. Remote-client optimization does not depend on shared + * memory support. Thus, the extension is still registered even + * when shared memory support is not functional. + */ + if (!CheckForShmSyscall()) { + ErrorF(XF86BIGFONTNAME " extension local-client optimization disabled due to lack of shared memory support in the kernel\n"); + return; + } +#endif + + srand((unsigned int) time(NULL)); + signature = ((unsigned int) (65536.0/(RAND_MAX+1.0) * rand()) << 16) + + (unsigned int) (65536.0/(RAND_MAX+1.0) * rand()); + /* fprintf(stderr, "signature = 0x%08X\n", signature); */ + + FontShmdescIndex = AllocateFontPrivateIndex(); + +#if !defined(CSRG_BASED) && !defined(__CYGWIN__) + pagesize = SHMLBA; +#else +# ifdef _SC_PAGESIZE + pagesize = sysconf(_SC_PAGESIZE); +# else + pagesize = getpagesize(); +# endif +#endif +#endif + } +} diff --git a/xorg-server/Xext/xselinux_ext.c b/xorg-server/Xext/xselinux_ext.c index 0076cedb4..374571c4b 100644 --- a/xorg-server/Xext/xselinux_ext.c +++ b/xorg-server/Xext/xselinux_ext.c @@ -1,734 +1,732 @@ -/************************************************************ - -Author: Eamon Walsh - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -this permission notice appear in supporting documentation. This permission -notice shall be included in all copies or substantial portions of the -Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -********************************************************/ - -#ifdef HAVE_DIX_CONFIG_H -#include -#endif - -#include "selection.h" -#include "inputstr.h" -#include "windowstr.h" -#include "propertyst.h" -#include "extnsionst.h" -#include "modinit.h" -#include "xselinuxint.h" - -#define CTX_DEV offsetof(SELinuxSubjectRec, dev_create_sid) -#define CTX_WIN offsetof(SELinuxSubjectRec, win_create_sid) -#define CTX_PRP offsetof(SELinuxSubjectRec, prp_create_sid) -#define CTX_SEL offsetof(SELinuxSubjectRec, sel_create_sid) -#define USE_PRP offsetof(SELinuxSubjectRec, prp_use_sid) -#define USE_SEL offsetof(SELinuxSubjectRec, sel_use_sid) - -typedef struct { - security_context_t octx; - security_context_t dctx; - CARD32 octx_len; - CARD32 dctx_len; - CARD32 id; -} SELinuxListItemRec; - - -/* - * Extension Dispatch - */ - -static security_context_t -SELinuxCopyContext(char *ptr, unsigned len) -{ - security_context_t copy = malloc(len + 1); - if (!copy) - return NULL; - strncpy(copy, ptr, len); - copy[len] = '\0'; - return copy; -} - -static int -ProcSELinuxQueryVersion(ClientPtr client) -{ - SELinuxQueryVersionReply rep; - - rep.type = X_Reply; - rep.length = 0; - rep.sequenceNumber = client->sequence; - rep.server_major = SELINUX_MAJOR_VERSION; - rep.server_minor = SELINUX_MINOR_VERSION; - if (client->swapped) { - int n; - swaps(&rep.sequenceNumber, n); - swapl(&rep.length, n); - swaps(&rep.server_major, n); - swaps(&rep.server_minor, n); - } - WriteToClient(client, sizeof(rep), (char *)&rep); - return Success; -} - -static int -SELinuxSendContextReply(ClientPtr client, security_id_t sid) -{ - SELinuxGetContextReply rep; - security_context_t ctx = NULL; - int len = 0; - - if (sid) { - if (avc_sid_to_context_raw(sid, &ctx) < 0) - return BadValue; - len = strlen(ctx) + 1; - } - - rep.type = X_Reply; - rep.length = bytes_to_int32(len); - rep.sequenceNumber = client->sequence; - rep.context_len = len; - - if (client->swapped) { - int n; - swapl(&rep.length, n); - swaps(&rep.sequenceNumber, n); - swapl(&rep.context_len, n); - } - - WriteToClient(client, sizeof(SELinuxGetContextReply), (char *)&rep); - WriteToClient(client, len, ctx); - freecon(ctx); - return Success; -} - -static int -ProcSELinuxSetCreateContext(ClientPtr client, unsigned offset) -{ - PrivateRec **privPtr = &client->devPrivates; - security_id_t *pSid; - security_context_t ctx = NULL; - char *ptr; - int rc; - - REQUEST(SELinuxSetCreateContextReq); - REQUEST_FIXED_SIZE(SELinuxSetCreateContextReq, stuff->context_len); - - if (stuff->context_len > 0) { - ctx = SELinuxCopyContext((char *)(stuff + 1), stuff->context_len); - if (!ctx) - return BadAlloc; - } - - ptr = dixLookupPrivate(privPtr, subjectKey); - pSid = (security_id_t *)(ptr + offset); - *pSid = NULL; - - rc = Success; - if (stuff->context_len > 0) { - if (security_check_context_raw(ctx) < 0 || - avc_context_to_sid_raw(ctx, pSid) < 0) - rc = BadValue; - } - - free(ctx); - return rc; -} - -static int -ProcSELinuxGetCreateContext(ClientPtr client, unsigned offset) -{ - security_id_t *pSid; - char *ptr; - - REQUEST_SIZE_MATCH(SELinuxGetCreateContextReq); - - if (offset == CTX_DEV) - ptr = dixLookupPrivate(&serverClient->devPrivates, subjectKey); - else - ptr = dixLookupPrivate(&client->devPrivates, subjectKey); - - pSid = (security_id_t *)(ptr + offset); - return SELinuxSendContextReply(client, *pSid); -} - -static int -ProcSELinuxSetDeviceContext(ClientPtr client) -{ - security_context_t ctx; - security_id_t sid; - DeviceIntPtr dev; - SELinuxSubjectRec *subj; - SELinuxObjectRec *obj; - int rc; - - REQUEST(SELinuxSetContextReq); - REQUEST_FIXED_SIZE(SELinuxSetContextReq, stuff->context_len); - - if (stuff->context_len < 1) - return BadLength; - ctx = SELinuxCopyContext((char *)(stuff + 1), stuff->context_len); - if (!ctx) - return BadAlloc; - - rc = dixLookupDevice(&dev, stuff->id, client, DixManageAccess); - if (rc != Success) - goto out; - - if (security_check_context_raw(ctx) < 0 || - avc_context_to_sid_raw(ctx, &sid) < 0) { - rc = BadValue; - goto out; - } - - subj = dixLookupPrivate(&dev->devPrivates, subjectKey); - subj->sid = sid; - obj = dixLookupPrivate(&dev->devPrivates, objectKey); - obj->sid = sid; - - rc = Success; -out: - free(ctx); - return rc; -} - -static int -ProcSELinuxGetDeviceContext(ClientPtr client) -{ - DeviceIntPtr dev; - SELinuxSubjectRec *subj; - int rc; - - REQUEST(SELinuxGetContextReq); - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - - rc = dixLookupDevice(&dev, stuff->id, client, DixGetAttrAccess); - if (rc != Success) - return rc; - - subj = dixLookupPrivate(&dev->devPrivates, subjectKey); - return SELinuxSendContextReply(client, subj->sid); -} - -static int -ProcSELinuxGetDrawableContext(ClientPtr client) -{ - DrawablePtr pDraw; - PrivateRec **privatePtr; - SELinuxObjectRec *obj; - int rc; - - REQUEST(SELinuxGetContextReq); - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - - rc = dixLookupDrawable(&pDraw, stuff->id, client, - M_WINDOW | M_DRAWABLE_PIXMAP, - DixGetAttrAccess); - if (rc != Success) - return rc; - - if (pDraw->type == M_DRAWABLE_PIXMAP) - privatePtr = &((PixmapPtr)pDraw)->devPrivates; - else - privatePtr = &((WindowPtr)pDraw)->devPrivates; - - obj = dixLookupPrivate(privatePtr, objectKey); - return SELinuxSendContextReply(client, obj->sid); -} - -static int -ProcSELinuxGetPropertyContext(ClientPtr client, pointer privKey) -{ - WindowPtr pWin; - PropertyPtr pProp; - SELinuxObjectRec *obj; - int rc; - - REQUEST(SELinuxGetPropertyContextReq); - REQUEST_SIZE_MATCH(SELinuxGetPropertyContextReq); - - rc = dixLookupWindow(&pWin, stuff->window, client, DixGetPropAccess); - if (rc != Success) - return rc; - - rc = dixLookupProperty(&pProp, pWin, stuff->property, client, - DixGetAttrAccess); - if (rc != Success) - return rc; - - obj = dixLookupPrivate(&pProp->devPrivates, privKey); - return SELinuxSendContextReply(client, obj->sid); -} - -static int -ProcSELinuxGetSelectionContext(ClientPtr client, pointer privKey) -{ - Selection *pSel; - SELinuxObjectRec *obj; - int rc; - - REQUEST(SELinuxGetContextReq); - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - - rc = dixLookupSelection(&pSel, stuff->id, client, DixGetAttrAccess); - if (rc != Success) - return rc; - - obj = dixLookupPrivate(&pSel->devPrivates, privKey); - return SELinuxSendContextReply(client, obj->sid); -} - -static int -ProcSELinuxGetClientContext(ClientPtr client) -{ - ClientPtr target; - SELinuxSubjectRec *subj; - int rc; - - REQUEST(SELinuxGetContextReq); - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - - rc = dixLookupClient(&target, stuff->id, client, DixGetAttrAccess); - if (rc != Success) - return rc; - - subj = dixLookupPrivate(&target->devPrivates, subjectKey); - return SELinuxSendContextReply(client, subj->sid); -} - -static int -SELinuxPopulateItem(SELinuxListItemRec *i, PrivateRec **privPtr, CARD32 id, - int *size) -{ - SELinuxObjectRec *obj = dixLookupPrivate(privPtr, objectKey); - SELinuxObjectRec *data = dixLookupPrivate(privPtr, dataKey); - - if (avc_sid_to_context_raw(obj->sid, &i->octx) < 0) - return BadValue; - if (avc_sid_to_context_raw(data->sid, &i->dctx) < 0) - return BadValue; - - i->id = id; - i->octx_len = bytes_to_int32(strlen(i->octx) + 1); - i->dctx_len = bytes_to_int32(strlen(i->dctx) + 1); - - *size += i->octx_len + i->dctx_len + 3; - return Success; -} - -static void -SELinuxFreeItems(SELinuxListItemRec *items, int count) -{ - int k; - for (k = 0; k < count; k++) { - freecon(items[k].octx); - freecon(items[k].dctx); - } - free(items); -} - -static int -SELinuxSendItemsToClient(ClientPtr client, SELinuxListItemRec *items, - int size, int count) -{ - int rc, k, n, pos = 0; - SELinuxListItemsReply rep; - CARD32 *buf; - - buf = calloc(size, sizeof(CARD32)); - if (size && !buf) { - rc = BadAlloc; - goto out; - } - - /* Fill in the buffer */ - for (k = 0; k < count; k++) { - buf[pos] = items[k].id; - if (client->swapped) - swapl(buf + pos, n); - pos++; - - buf[pos] = items[k].octx_len * 4; - if (client->swapped) - swapl(buf + pos, n); - pos++; - - buf[pos] = items[k].dctx_len * 4; - if (client->swapped) - swapl(buf + pos, n); - pos++; - - memcpy((char *)(buf + pos), items[k].octx, strlen(items[k].octx) + 1); - pos += items[k].octx_len; - memcpy((char *)(buf + pos), items[k].dctx, strlen(items[k].dctx) + 1); - pos += items[k].dctx_len; - } - - /* Send reply to client */ - rep.type = X_Reply; - rep.length = size; - rep.sequenceNumber = client->sequence; - rep.count = count; - - if (client->swapped) { - swapl(&rep.length, n); - swaps(&rep.sequenceNumber, n); - swapl(&rep.count, n); - } - - WriteToClient(client, sizeof(SELinuxListItemsReply), (char *)&rep); - WriteToClient(client, size * 4, (char *)buf); - - /* Free stuff and return */ - rc = Success; - free(buf); -out: - SELinuxFreeItems(items, count); - return rc; -} - -static int -ProcSELinuxListProperties(ClientPtr client) -{ - WindowPtr pWin; - PropertyPtr pProp; - SELinuxListItemRec *items; - int rc, count, size, i; - CARD32 id; - - REQUEST(SELinuxGetContextReq); - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - - rc = dixLookupWindow(&pWin, stuff->id, client, DixListPropAccess); - if (rc != Success) - return rc; - - /* Count the number of properties and allocate items */ - count = 0; - for (pProp = wUserProps(pWin); pProp; pProp = pProp->next) - count++; - items = calloc(count, sizeof(SELinuxListItemRec)); - if (count && !items) - return BadAlloc; - - /* Fill in the items and calculate size */ - i = 0; - size = 0; - for (pProp = wUserProps(pWin); pProp; pProp = pProp->next) { - id = pProp->propertyName; - rc = SELinuxPopulateItem(items + i, &pProp->devPrivates, id, &size); - if (rc != Success) { - SELinuxFreeItems(items, count); - return rc; - } - i++; - } - - return SELinuxSendItemsToClient(client, items, size, count); -} - -static int -ProcSELinuxListSelections(ClientPtr client) -{ - Selection *pSel; - SELinuxListItemRec *items; - int rc, count, size, i; - CARD32 id; - - REQUEST_SIZE_MATCH(SELinuxGetCreateContextReq); - - /* Count the number of selections and allocate items */ - count = 0; - for (pSel = CurrentSelections; pSel; pSel = pSel->next) - count++; - items = calloc(count, sizeof(SELinuxListItemRec)); - if (count && !items) - return BadAlloc; - - /* Fill in the items and calculate size */ - i = 0; - size = 0; - for (pSel = CurrentSelections; pSel; pSel = pSel->next) { - id = pSel->selection; - rc = SELinuxPopulateItem(items + i, &pSel->devPrivates, id, &size); - if (rc != Success) { - SELinuxFreeItems(items, count); - return rc; - } - i++; - } - - return SELinuxSendItemsToClient(client, items, size, count); -} - -static int -ProcSELinuxDispatch(ClientPtr client) -{ - REQUEST(xReq); - switch (stuff->data) { - case X_SELinuxQueryVersion: - return ProcSELinuxQueryVersion(client); - case X_SELinuxSetDeviceCreateContext: - return ProcSELinuxSetCreateContext(client, CTX_DEV); - case X_SELinuxGetDeviceCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_DEV); - case X_SELinuxSetDeviceContext: - return ProcSELinuxSetDeviceContext(client); - case X_SELinuxGetDeviceContext: - return ProcSELinuxGetDeviceContext(client); - case X_SELinuxSetDrawableCreateContext: - return ProcSELinuxSetCreateContext(client, CTX_WIN); - case X_SELinuxGetDrawableCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_WIN); - case X_SELinuxGetDrawableContext: - return ProcSELinuxGetDrawableContext(client); - case X_SELinuxSetPropertyCreateContext: - return ProcSELinuxSetCreateContext(client, CTX_PRP); - case X_SELinuxGetPropertyCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_PRP); - case X_SELinuxSetPropertyUseContext: - return ProcSELinuxSetCreateContext(client, USE_PRP); - case X_SELinuxGetPropertyUseContext: - return ProcSELinuxGetCreateContext(client, USE_PRP); - case X_SELinuxGetPropertyContext: - return ProcSELinuxGetPropertyContext(client, objectKey); - case X_SELinuxGetPropertyDataContext: - return ProcSELinuxGetPropertyContext(client, dataKey); - case X_SELinuxListProperties: - return ProcSELinuxListProperties(client); - case X_SELinuxSetSelectionCreateContext: - return ProcSELinuxSetCreateContext(client, CTX_SEL); - case X_SELinuxGetSelectionCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_SEL); - case X_SELinuxSetSelectionUseContext: - return ProcSELinuxSetCreateContext(client, USE_SEL); - case X_SELinuxGetSelectionUseContext: - return ProcSELinuxGetCreateContext(client, USE_SEL); - case X_SELinuxGetSelectionContext: - return ProcSELinuxGetSelectionContext(client, objectKey); - case X_SELinuxGetSelectionDataContext: - return ProcSELinuxGetSelectionContext(client, dataKey); - case X_SELinuxListSelections: - return ProcSELinuxListSelections(client); - case X_SELinuxGetClientContext: - return ProcSELinuxGetClientContext(client); - default: - return BadRequest; - } -} - -static int -SProcSELinuxQueryVersion(ClientPtr client) -{ - REQUEST(SELinuxQueryVersionReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxQueryVersionReq); - swaps(&stuff->client_major, n); - swaps(&stuff->client_minor, n); - return ProcSELinuxQueryVersion(client); -} - -static int -SProcSELinuxSetCreateContext(ClientPtr client, unsigned offset) -{ - REQUEST(SELinuxSetCreateContextReq); - int n; - - REQUEST_AT_LEAST_SIZE(SELinuxSetCreateContextReq); - swapl(&stuff->context_len, n); - return ProcSELinuxSetCreateContext(client, offset); -} - -static int -SProcSELinuxSetDeviceContext(ClientPtr client) -{ - REQUEST(SELinuxSetContextReq); - int n; - - REQUEST_AT_LEAST_SIZE(SELinuxSetContextReq); - swapl(&stuff->id, n); - swapl(&stuff->context_len, n); - return ProcSELinuxSetDeviceContext(client); -} - -static int -SProcSELinuxGetDeviceContext(ClientPtr client) -{ - REQUEST(SELinuxGetContextReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - swapl(&stuff->id, n); - return ProcSELinuxGetDeviceContext(client); -} - -static int -SProcSELinuxGetDrawableContext(ClientPtr client) -{ - REQUEST(SELinuxGetContextReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - swapl(&stuff->id, n); - return ProcSELinuxGetDrawableContext(client); -} - -static int -SProcSELinuxGetPropertyContext(ClientPtr client, pointer privKey) -{ - REQUEST(SELinuxGetPropertyContextReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxGetPropertyContextReq); - swapl(&stuff->window, n); - swapl(&stuff->property, n); - return ProcSELinuxGetPropertyContext(client, privKey); -} - -static int -SProcSELinuxGetSelectionContext(ClientPtr client, pointer privKey) -{ - REQUEST(SELinuxGetContextReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - swapl(&stuff->id, n); - return ProcSELinuxGetSelectionContext(client, privKey); -} - -static int -SProcSELinuxListProperties(ClientPtr client) -{ - REQUEST(SELinuxGetContextReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - swapl(&stuff->id, n); - return ProcSELinuxListProperties(client); -} - -static int -SProcSELinuxGetClientContext(ClientPtr client) -{ - REQUEST(SELinuxGetContextReq); - int n; - - REQUEST_SIZE_MATCH(SELinuxGetContextReq); - swapl(&stuff->id, n); - return ProcSELinuxGetClientContext(client); -} - -static int -SProcSELinuxDispatch(ClientPtr client) -{ - REQUEST(xReq); - int n; - - swaps(&stuff->length, n); - - switch (stuff->data) { - case X_SELinuxQueryVersion: - return SProcSELinuxQueryVersion(client); - case X_SELinuxSetDeviceCreateContext: - return SProcSELinuxSetCreateContext(client, CTX_DEV); - case X_SELinuxGetDeviceCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_DEV); - case X_SELinuxSetDeviceContext: - return SProcSELinuxSetDeviceContext(client); - case X_SELinuxGetDeviceContext: - return SProcSELinuxGetDeviceContext(client); - case X_SELinuxSetDrawableCreateContext: - return SProcSELinuxSetCreateContext(client, CTX_WIN); - case X_SELinuxGetDrawableCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_WIN); - case X_SELinuxGetDrawableContext: - return SProcSELinuxGetDrawableContext(client); - case X_SELinuxSetPropertyCreateContext: - return SProcSELinuxSetCreateContext(client, CTX_PRP); - case X_SELinuxGetPropertyCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_PRP); - case X_SELinuxSetPropertyUseContext: - return SProcSELinuxSetCreateContext(client, USE_PRP); - case X_SELinuxGetPropertyUseContext: - return ProcSELinuxGetCreateContext(client, USE_PRP); - case X_SELinuxGetPropertyContext: - return SProcSELinuxGetPropertyContext(client, objectKey); - case X_SELinuxGetPropertyDataContext: - return SProcSELinuxGetPropertyContext(client, dataKey); - case X_SELinuxListProperties: - return SProcSELinuxListProperties(client); - case X_SELinuxSetSelectionCreateContext: - return SProcSELinuxSetCreateContext(client, CTX_SEL); - case X_SELinuxGetSelectionCreateContext: - return ProcSELinuxGetCreateContext(client, CTX_SEL); - case X_SELinuxSetSelectionUseContext: - return SProcSELinuxSetCreateContext(client, USE_SEL); - case X_SELinuxGetSelectionUseContext: - return ProcSELinuxGetCreateContext(client, USE_SEL); - case X_SELinuxGetSelectionContext: - return SProcSELinuxGetSelectionContext(client, objectKey); - case X_SELinuxGetSelectionDataContext: - return SProcSELinuxGetSelectionContext(client, dataKey); - case X_SELinuxListSelections: - return ProcSELinuxListSelections(client); - case X_SELinuxGetClientContext: - return SProcSELinuxGetClientContext(client); - default: - return BadRequest; - } -} - - -/* - * Extension Setup / Teardown - */ - -static void -SELinuxResetProc(ExtensionEntry *extEntry) -{ - SELinuxFlaskReset(); - SELinuxLabelReset(); -} - -void -SELinuxExtensionInit(INITARGS) -{ - ExtensionEntry *extEntry; - - /* Check SELinux mode on system, configuration file, and boolean */ - if (!is_selinux_enabled()) { - LogMessage(X_INFO, "SELinux: Disabled on system\n"); - return; - } - if (selinuxEnforcingState == SELINUX_MODE_DISABLED) { - LogMessage(X_INFO, "SELinux: Disabled in configuration file\n"); - return; - } - if (!security_get_boolean_active("xserver_object_manager")) { - LogMessage(X_INFO, "SELinux: Disabled by boolean\n"); - return; - } - - /* Set up XACE hooks */ - SELinuxLabelInit(); - SELinuxFlaskInit(); - - /* Add extension to server */ - extEntry = AddExtension(SELINUX_EXTENSION_NAME, - SELinuxNumberEvents, SELinuxNumberErrors, - ProcSELinuxDispatch, SProcSELinuxDispatch, - SELinuxResetProc, StandardMinorOpcode); - - AddExtensionAlias("Flask", extEntry); -} +/************************************************************ + +Author: Eamon Walsh + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +this permission notice appear in supporting documentation. This permission +notice shall be included in all copies or substantial portions of the +Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +********************************************************/ + +#ifdef HAVE_DIX_CONFIG_H +#include +#endif + +#include "selection.h" +#include "inputstr.h" +#include "windowstr.h" +#include "propertyst.h" +#include "extnsionst.h" +#include "modinit.h" +#include "xselinuxint.h" + +#define CTX_DEV offsetof(SELinuxSubjectRec, dev_create_sid) +#define CTX_WIN offsetof(SELinuxSubjectRec, win_create_sid) +#define CTX_PRP offsetof(SELinuxSubjectRec, prp_create_sid) +#define CTX_SEL offsetof(SELinuxSubjectRec, sel_create_sid) +#define USE_PRP offsetof(SELinuxSubjectRec, prp_use_sid) +#define USE_SEL offsetof(SELinuxSubjectRec, sel_use_sid) + +typedef struct { + security_context_t octx; + security_context_t dctx; + CARD32 octx_len; + CARD32 dctx_len; + CARD32 id; +} SELinuxListItemRec; + + +/* + * Extension Dispatch + */ + +static security_context_t +SELinuxCopyContext(char *ptr, unsigned len) +{ + security_context_t copy = malloc(len + 1); + if (!copy) + return NULL; + strncpy(copy, ptr, len); + copy[len] = '\0'; + return copy; +} + +static int +ProcSELinuxQueryVersion(ClientPtr client) +{ + SELinuxQueryVersionReply rep; + + rep.type = X_Reply; + rep.length = 0; + rep.sequenceNumber = client->sequence; + rep.server_major = SELINUX_MAJOR_VERSION; + rep.server_minor = SELINUX_MINOR_VERSION; + if (client->swapped) { + int n; + swaps(&rep.sequenceNumber, n); + swapl(&rep.length, n); + swaps(&rep.server_major, n); + swaps(&rep.server_minor, n); + } + WriteToClient(client, sizeof(rep), (char *)&rep); + return Success; +} + +static int +SELinuxSendContextReply(ClientPtr client, security_id_t sid) +{ + SELinuxGetContextReply rep; + security_context_t ctx = NULL; + int len = 0; + + if (sid) { + if (avc_sid_to_context_raw(sid, &ctx) < 0) + return BadValue; + len = strlen(ctx) + 1; + } + + rep.type = X_Reply; + rep.length = bytes_to_int32(len); + rep.sequenceNumber = client->sequence; + rep.context_len = len; + + if (client->swapped) { + int n; + swapl(&rep.length, n); + swaps(&rep.sequenceNumber, n); + swapl(&rep.context_len, n); + } + + WriteToClient(client, sizeof(SELinuxGetContextReply), (char *)&rep); + WriteToClient(client, len, ctx); + freecon(ctx); + return Success; +} + +static int +ProcSELinuxSetCreateContext(ClientPtr client, unsigned offset) +{ + PrivateRec **privPtr = &client->devPrivates; + security_id_t *pSid; + security_context_t ctx = NULL; + char *ptr; + int rc; + + REQUEST(SELinuxSetCreateContextReq); + REQUEST_FIXED_SIZE(SELinuxSetCreateContextReq, stuff->context_len); + + if (stuff->context_len > 0) { + ctx = SELinuxCopyContext((char *)(stuff + 1), stuff->context_len); + if (!ctx) + return BadAlloc; + } + + ptr = dixLookupPrivate(privPtr, subjectKey); + pSid = (security_id_t *)(ptr + offset); + *pSid = NULL; + + rc = Success; + if (stuff->context_len > 0) { + if (security_check_context_raw(ctx) < 0 || + avc_context_to_sid_raw(ctx, pSid) < 0) + rc = BadValue; + } + + free(ctx); + return rc; +} + +static int +ProcSELinuxGetCreateContext(ClientPtr client, unsigned offset) +{ + security_id_t *pSid; + char *ptr; + + REQUEST_SIZE_MATCH(SELinuxGetCreateContextReq); + + if (offset == CTX_DEV) + ptr = dixLookupPrivate(&serverClient->devPrivates, subjectKey); + else + ptr = dixLookupPrivate(&client->devPrivates, subjectKey); + + pSid = (security_id_t *)(ptr + offset); + return SELinuxSendContextReply(client, *pSid); +} + +static int +ProcSELinuxSetDeviceContext(ClientPtr client) +{ + security_context_t ctx; + security_id_t sid; + DeviceIntPtr dev; + SELinuxSubjectRec *subj; + SELinuxObjectRec *obj; + int rc; + + REQUEST(SELinuxSetContextReq); + REQUEST_FIXED_SIZE(SELinuxSetContextReq, stuff->context_len); + + if (stuff->context_len < 1) + return BadLength; + ctx = SELinuxCopyContext((char *)(stuff + 1), stuff->context_len); + if (!ctx) + return BadAlloc; + + rc = dixLookupDevice(&dev, stuff->id, client, DixManageAccess); + if (rc != Success) + goto out; + + if (security_check_context_raw(ctx) < 0 || + avc_context_to_sid_raw(ctx, &sid) < 0) { + rc = BadValue; + goto out; + } + + subj = dixLookupPrivate(&dev->devPrivates, subjectKey); + subj->sid = sid; + obj = dixLookupPrivate(&dev->devPrivates, objectKey); + obj->sid = sid; + + rc = Success; +out: + free(ctx); + return rc; +} + +static int +ProcSELinuxGetDeviceContext(ClientPtr client) +{ + DeviceIntPtr dev; + SELinuxSubjectRec *subj; + int rc; + + REQUEST(SELinuxGetContextReq); + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + + rc = dixLookupDevice(&dev, stuff->id, client, DixGetAttrAccess); + if (rc != Success) + return rc; + + subj = dixLookupPrivate(&dev->devPrivates, subjectKey); + return SELinuxSendContextReply(client, subj->sid); +} + +static int +ProcSELinuxGetDrawableContext(ClientPtr client) +{ + DrawablePtr pDraw; + PrivateRec **privatePtr; + SELinuxObjectRec *obj; + int rc; + + REQUEST(SELinuxGetContextReq); + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + + rc = dixLookupDrawable(&pDraw, stuff->id, client, 0, DixGetAttrAccess); + if (rc != Success) + return rc; + + if (pDraw->type == DRAWABLE_PIXMAP) + privatePtr = &((PixmapPtr)pDraw)->devPrivates; + else + privatePtr = &((WindowPtr)pDraw)->devPrivates; + + obj = dixLookupPrivate(privatePtr, objectKey); + return SELinuxSendContextReply(client, obj->sid); +} + +static int +ProcSELinuxGetPropertyContext(ClientPtr client, pointer privKey) +{ + WindowPtr pWin; + PropertyPtr pProp; + SELinuxObjectRec *obj; + int rc; + + REQUEST(SELinuxGetPropertyContextReq); + REQUEST_SIZE_MATCH(SELinuxGetPropertyContextReq); + + rc = dixLookupWindow(&pWin, stuff->window, client, DixGetPropAccess); + if (rc != Success) + return rc; + + rc = dixLookupProperty(&pProp, pWin, stuff->property, client, + DixGetAttrAccess); + if (rc != Success) + return rc; + + obj = dixLookupPrivate(&pProp->devPrivates, privKey); + return SELinuxSendContextReply(client, obj->sid); +} + +static int +ProcSELinuxGetSelectionContext(ClientPtr client, pointer privKey) +{ + Selection *pSel; + SELinuxObjectRec *obj; + int rc; + + REQUEST(SELinuxGetContextReq); + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + + rc = dixLookupSelection(&pSel, stuff->id, client, DixGetAttrAccess); + if (rc != Success) + return rc; + + obj = dixLookupPrivate(&pSel->devPrivates, privKey); + return SELinuxSendContextReply(client, obj->sid); +} + +static int +ProcSELinuxGetClientContext(ClientPtr client) +{ + ClientPtr target; + SELinuxSubjectRec *subj; + int rc; + + REQUEST(SELinuxGetContextReq); + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + + rc = dixLookupClient(&target, stuff->id, client, DixGetAttrAccess); + if (rc != Success) + return rc; + + subj = dixLookupPrivate(&target->devPrivates, subjectKey); + return SELinuxSendContextReply(client, subj->sid); +} + +static int +SELinuxPopulateItem(SELinuxListItemRec *i, PrivateRec **privPtr, CARD32 id, + int *size) +{ + SELinuxObjectRec *obj = dixLookupPrivate(privPtr, objectKey); + SELinuxObjectRec *data = dixLookupPrivate(privPtr, dataKey); + + if (avc_sid_to_context_raw(obj->sid, &i->octx) < 0) + return BadValue; + if (avc_sid_to_context_raw(data->sid, &i->dctx) < 0) + return BadValue; + + i->id = id; + i->octx_len = bytes_to_int32(strlen(i->octx) + 1); + i->dctx_len = bytes_to_int32(strlen(i->dctx) + 1); + + *size += i->octx_len + i->dctx_len + 3; + return Success; +} + +static void +SELinuxFreeItems(SELinuxListItemRec *items, int count) +{ + int k; + for (k = 0; k < count; k++) { + freecon(items[k].octx); + freecon(items[k].dctx); + } + free(items); +} + +static int +SELinuxSendItemsToClient(ClientPtr client, SELinuxListItemRec *items, + int size, int count) +{ + int rc, k, n, pos = 0; + SELinuxListItemsReply rep; + CARD32 *buf; + + buf = calloc(size, sizeof(CARD32)); + if (size && !buf) { + rc = BadAlloc; + goto out; + } + + /* Fill in the buffer */ + for (k = 0; k < count; k++) { + buf[pos] = items[k].id; + if (client->swapped) + swapl(buf + pos, n); + pos++; + + buf[pos] = items[k].octx_len * 4; + if (client->swapped) + swapl(buf + pos, n); + pos++; + + buf[pos] = items[k].dctx_len * 4; + if (client->swapped) + swapl(buf + pos, n); + pos++; + + memcpy((char *)(buf + pos), items[k].octx, strlen(items[k].octx) + 1); + pos += items[k].octx_len; + memcpy((char *)(buf + pos), items[k].dctx, strlen(items[k].dctx) + 1); + pos += items[k].dctx_len; + } + + /* Send reply to client */ + rep.type = X_Reply; + rep.length = size; + rep.sequenceNumber = client->sequence; + rep.count = count; + + if (client->swapped) { + swapl(&rep.length, n); + swaps(&rep.sequenceNumber, n); + swapl(&rep.count, n); + } + + WriteToClient(client, sizeof(SELinuxListItemsReply), (char *)&rep); + WriteToClient(client, size * 4, (char *)buf); + + /* Free stuff and return */ + rc = Success; + free(buf); +out: + SELinuxFreeItems(items, count); + return rc; +} + +static int +ProcSELinuxListProperties(ClientPtr client) +{ + WindowPtr pWin; + PropertyPtr pProp; + SELinuxListItemRec *items; + int rc, count, size, i; + CARD32 id; + + REQUEST(SELinuxGetContextReq); + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + + rc = dixLookupWindow(&pWin, stuff->id, client, DixListPropAccess); + if (rc != Success) + return rc; + + /* Count the number of properties and allocate items */ + count = 0; + for (pProp = wUserProps(pWin); pProp; pProp = pProp->next) + count++; + items = calloc(count, sizeof(SELinuxListItemRec)); + if (count && !items) + return BadAlloc; + + /* Fill in the items and calculate size */ + i = 0; + size = 0; + for (pProp = wUserProps(pWin); pProp; pProp = pProp->next) { + id = pProp->propertyName; + rc = SELinuxPopulateItem(items + i, &pProp->devPrivates, id, &size); + if (rc != Success) { + SELinuxFreeItems(items, count); + return rc; + } + i++; + } + + return SELinuxSendItemsToClient(client, items, size, count); +} + +static int +ProcSELinuxListSelections(ClientPtr client) +{ + Selection *pSel; + SELinuxListItemRec *items; + int rc, count, size, i; + CARD32 id; + + REQUEST_SIZE_MATCH(SELinuxGetCreateContextReq); + + /* Count the number of selections and allocate items */ + count = 0; + for (pSel = CurrentSelections; pSel; pSel = pSel->next) + count++; + items = calloc(count, sizeof(SELinuxListItemRec)); + if (count && !items) + return BadAlloc; + + /* Fill in the items and calculate size */ + i = 0; + size = 0; + for (pSel = CurrentSelections; pSel; pSel = pSel->next) { + id = pSel->selection; + rc = SELinuxPopulateItem(items + i, &pSel->devPrivates, id, &size); + if (rc != Success) { + SELinuxFreeItems(items, count); + return rc; + } + i++; + } + + return SELinuxSendItemsToClient(client, items, size, count); +} + +static int +ProcSELinuxDispatch(ClientPtr client) +{ + REQUEST(xReq); + switch (stuff->data) { + case X_SELinuxQueryVersion: + return ProcSELinuxQueryVersion(client); + case X_SELinuxSetDeviceCreateContext: + return ProcSELinuxSetCreateContext(client, CTX_DEV); + case X_SELinuxGetDeviceCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_DEV); + case X_SELinuxSetDeviceContext: + return ProcSELinuxSetDeviceContext(client); + case X_SELinuxGetDeviceContext: + return ProcSELinuxGetDeviceContext(client); + case X_SELinuxSetDrawableCreateContext: + return ProcSELinuxSetCreateContext(client, CTX_WIN); + case X_SELinuxGetDrawableCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_WIN); + case X_SELinuxGetDrawableContext: + return ProcSELinuxGetDrawableContext(client); + case X_SELinuxSetPropertyCreateContext: + return ProcSELinuxSetCreateContext(client, CTX_PRP); + case X_SELinuxGetPropertyCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_PRP); + case X_SELinuxSetPropertyUseContext: + return ProcSELinuxSetCreateContext(client, USE_PRP); + case X_SELinuxGetPropertyUseContext: + return ProcSELinuxGetCreateContext(client, USE_PRP); + case X_SELinuxGetPropertyContext: + return ProcSELinuxGetPropertyContext(client, objectKey); + case X_SELinuxGetPropertyDataContext: + return ProcSELinuxGetPropertyContext(client, dataKey); + case X_SELinuxListProperties: + return ProcSELinuxListProperties(client); + case X_SELinuxSetSelectionCreateContext: + return ProcSELinuxSetCreateContext(client, CTX_SEL); + case X_SELinuxGetSelectionCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_SEL); + case X_SELinuxSetSelectionUseContext: + return ProcSELinuxSetCreateContext(client, USE_SEL); + case X_SELinuxGetSelectionUseContext: + return ProcSELinuxGetCreateContext(client, USE_SEL); + case X_SELinuxGetSelectionContext: + return ProcSELinuxGetSelectionContext(client, objectKey); + case X_SELinuxGetSelectionDataContext: + return ProcSELinuxGetSelectionContext(client, dataKey); + case X_SELinuxListSelections: + return ProcSELinuxListSelections(client); + case X_SELinuxGetClientContext: + return ProcSELinuxGetClientContext(client); + default: + return BadRequest; + } +} + +static int +SProcSELinuxQueryVersion(ClientPtr client) +{ + REQUEST(SELinuxQueryVersionReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxQueryVersionReq); + swaps(&stuff->client_major, n); + swaps(&stuff->client_minor, n); + return ProcSELinuxQueryVersion(client); +} + +static int +SProcSELinuxSetCreateContext(ClientPtr client, unsigned offset) +{ + REQUEST(SELinuxSetCreateContextReq); + int n; + + REQUEST_AT_LEAST_SIZE(SELinuxSetCreateContextReq); + swapl(&stuff->context_len, n); + return ProcSELinuxSetCreateContext(client, offset); +} + +static int +SProcSELinuxSetDeviceContext(ClientPtr client) +{ + REQUEST(SELinuxSetContextReq); + int n; + + REQUEST_AT_LEAST_SIZE(SELinuxSetContextReq); + swapl(&stuff->id, n); + swapl(&stuff->context_len, n); + return ProcSELinuxSetDeviceContext(client); +} + +static int +SProcSELinuxGetDeviceContext(ClientPtr client) +{ + REQUEST(SELinuxGetContextReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + swapl(&stuff->id, n); + return ProcSELinuxGetDeviceContext(client); +} + +static int +SProcSELinuxGetDrawableContext(ClientPtr client) +{ + REQUEST(SELinuxGetContextReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + swapl(&stuff->id, n); + return ProcSELinuxGetDrawableContext(client); +} + +static int +SProcSELinuxGetPropertyContext(ClientPtr client, pointer privKey) +{ + REQUEST(SELinuxGetPropertyContextReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxGetPropertyContextReq); + swapl(&stuff->window, n); + swapl(&stuff->property, n); + return ProcSELinuxGetPropertyContext(client, privKey); +} + +static int +SProcSELinuxGetSelectionContext(ClientPtr client, pointer privKey) +{ + REQUEST(SELinuxGetContextReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + swapl(&stuff->id, n); + return ProcSELinuxGetSelectionContext(client, privKey); +} + +static int +SProcSELinuxListProperties(ClientPtr client) +{ + REQUEST(SELinuxGetContextReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + swapl(&stuff->id, n); + return ProcSELinuxListProperties(client); +} + +static int +SProcSELinuxGetClientContext(ClientPtr client) +{ + REQUEST(SELinuxGetContextReq); + int n; + + REQUEST_SIZE_MATCH(SELinuxGetContextReq); + swapl(&stuff->id, n); + return ProcSELinuxGetClientContext(client); +} + +static int +SProcSELinuxDispatch(ClientPtr client) +{ + REQUEST(xReq); + int n; + + swaps(&stuff->length, n); + + switch (stuff->data) { + case X_SELinuxQueryVersion: + return SProcSELinuxQueryVersion(client); + case X_SELinuxSetDeviceCreateContext: + return SProcSELinuxSetCreateContext(client, CTX_DEV); + case X_SELinuxGetDeviceCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_DEV); + case X_SELinuxSetDeviceContext: + return SProcSELinuxSetDeviceContext(client); + case X_SELinuxGetDeviceContext: + return SProcSELinuxGetDeviceContext(client); + case X_SELinuxSetDrawableCreateContext: + return SProcSELinuxSetCreateContext(client, CTX_WIN); + case X_SELinuxGetDrawableCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_WIN); + case X_SELinuxGetDrawableContext: + return SProcSELinuxGetDrawableContext(client); + case X_SELinuxSetPropertyCreateContext: + return SProcSELinuxSetCreateContext(client, CTX_PRP); + case X_SELinuxGetPropertyCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_PRP); + case X_SELinuxSetPropertyUseContext: + return SProcSELinuxSetCreateContext(client, USE_PRP); + case X_SELinuxGetPropertyUseContext: + return ProcSELinuxGetCreateContext(client, USE_PRP); + case X_SELinuxGetPropertyContext: + return SProcSELinuxGetPropertyContext(client, objectKey); + case X_SELinuxGetPropertyDataContext: + return SProcSELinuxGetPropertyContext(client, dataKey); + case X_SELinuxListProperties: + return SProcSELinuxListProperties(client); + case X_SELinuxSetSelectionCreateContext: + return SProcSELinuxSetCreateContext(client, CTX_SEL); + case X_SELinuxGetSelectionCreateContext: + return ProcSELinuxGetCreateContext(client, CTX_SEL); + case X_SELinuxSetSelectionUseContext: + return SProcSELinuxSetCreateContext(client, USE_SEL); + case X_SELinuxGetSelectionUseContext: + return ProcSELinuxGetCreateContext(client, USE_SEL); + case X_SELinuxGetSelectionContext: + return SProcSELinuxGetSelectionContext(client, objectKey); + case X_SELinuxGetSelectionDataContext: + return SProcSELinuxGetSelectionContext(client, dataKey); + case X_SELinuxListSelections: + return ProcSELinuxListSelections(client); + case X_SELinuxGetClientContext: + return SProcSELinuxGetClientContext(client); + default: + return BadRequest; + } +} + + +/* + * Extension Setup / Teardown + */ + +static void +SELinuxResetProc(ExtensionEntry *extEntry) +{ + SELinuxFlaskReset(); + SELinuxLabelReset(); +} + +void +SELinuxExtensionInit(INITARGS) +{ + ExtensionEntry *extEntry; + + /* Check SELinux mode on system, configuration file, and boolean */ + if (!is_selinux_enabled()) { + LogMessage(X_INFO, "SELinux: Disabled on system\n"); + return; + } + if (selinuxEnforcingState == SELINUX_MODE_DISABLED) { + LogMessage(X_INFO, "SELinux: Disabled in configuration file\n"); + return; + } + if (!security_get_boolean_active("xserver_object_manager")) { + LogMessage(X_INFO, "SELinux: Disabled by boolean\n"); + return; + } + + /* Set up XACE hooks */ + SELinuxLabelInit(); + SELinuxFlaskInit(); + + /* Add extension to server */ + extEntry = AddExtension(SELINUX_EXTENSION_NAME, + SELinuxNumberEvents, SELinuxNumberErrors, + ProcSELinuxDispatch, SProcSELinuxDispatch, + SELinuxResetProc, StandardMinorOpcode); + + AddExtensionAlias("Flask", extEntry); +} diff --git a/xorg-server/configure.ac b/xorg-server/configure.ac index 120321e7c..9b3e2be2b 100644 --- a/xorg-server/configure.ac +++ b/xorg-server/configure.ac @@ -597,9 +597,14 @@ dnl GLX build options AC_ARG_ENABLE(aiglx, AS_HELP_STRING([--enable-aiglx], [Build accelerated indirect GLX (default: enabled)]), [AIGLX=$enableval], [AIGLX=yes]) -AC_ARG_ENABLE(glx-tls, AS_HELP_STRING([--enable-glx-tls], [Build GLX with TLS support (default: disabled)]), +AX_TLS +AC_ARG_ENABLE(glx-tls, AS_HELP_STRING([--enable-glx-tls], [Build GLX with TLS support (default: auto)]), [GLX_USE_TLS=$enableval], - [GLX_USE_TLS=no]) + [GLX_USE_TLS=no + if test "${ac_cv_tls}" != "none" ; then + GLX_USE_TLS=yes + fi]) +AC_SUBST(GLX_TLS, ${GLX_USE_TLS}) dnl Extensions. AC_ARG_ENABLE(registry, AS_HELP_STRING([--disable-registry], [Build string registry module (default: enabled)]), [XREGISTRY=$enableval], [XREGISTRY=yes]) @@ -1008,7 +1013,7 @@ else fi AM_CONDITIONAL(AIGLX, test "x$AIGLX" = xyes) -if test "x$GLX_USE_TLS" = xyes -a "x$AIGLX" = xyes; then +if test "x$GLX_USE_TLS" = xyes ; then GLX_DEFINES="-DGLX_USE_TLS -DPTHREADS" GLX_SYS_LIBS="$GLX_SYS_LIBS -lpthread" fi diff --git a/xorg-server/exa/exa.c b/xorg-server/exa/exa.c index 9dbcf4d10..a4e294a71 100644 --- a/xorg-server/exa/exa.c +++ b/xorg-server/exa/exa.c @@ -1,1157 +1,1158 @@ -/* - * Copyright © 2001 Keith Packard - * - * Partly based on code that is Copyright © The XFree86 Project Inc. - * - * Permission to use, copy, modify, distribute, and sell this software and its - * documentation for any purpose is hereby granted without fee, provided that - * the above copyright notice appear in all copies and that both that - * copyright notice and this permission notice appear in supporting - * documentation, and that the name of Keith Packard not be used in - * advertising or publicity pertaining to distribution of the software without - * specific, written prior permission. Keith Packard makes no - * representations about the suitability of this software for any purpose. It - * is provided "as is" without express or implied warranty. - * - * KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, - * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO - * EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR - * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, - * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER - * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/** @file - * This file covers the initialization and teardown of EXA, and has various - * functions not responsible for performing rendering, pixmap migration, or - * memory management. - */ - -#ifdef HAVE_DIX_CONFIG_H -#include -#endif - -#include - -#include "exa_priv.h" -#include "exa.h" - -DevPrivateKeyRec exaScreenPrivateKeyRec; -DevPrivateKeyRec exaPixmapPrivateKeyRec; -DevPrivateKeyRec exaGCPrivateKeyRec; - -#ifdef MITSHM -static ShmFuncs exaShmFuncs = { NULL, NULL }; -#endif - -/** - * exaGetPixmapOffset() returns the offset (in bytes) within the framebuffer of - * the beginning of the given pixmap. - * - * Note that drivers are free to, and often do, munge this offset as necessary - * for handing to the hardware -- for example, translating it into a different - * aperture. This function may need to be extended in the future if we grow - * support for having multiple card-accessible offscreen, such as an AGP memory - * pool alongside the framebuffer pool. - */ -unsigned long -exaGetPixmapOffset(PixmapPtr pPix) -{ - ExaScreenPriv (pPix->drawable.pScreen); - ExaPixmapPriv (pPix); - - return (CARD8 *)pExaPixmap->fb_ptr - pExaScr->info->memoryBase; -} - -void * -exaGetPixmapDriverPrivate(PixmapPtr pPix) -{ - ExaPixmapPriv(pPix); - - return pExaPixmap->driverPriv; -} - -/** - * exaGetPixmapPitch() returns the pitch (in bytes) of the given pixmap. - * - * This is a helper to make driver code more obvious, due to the rather obscure - * naming of the pitch field in the pixmap. - */ -unsigned long -exaGetPixmapPitch(PixmapPtr pPix) -{ - return pPix->devKind; -} - -/** - * exaGetPixmapSize() returns the size in bytes of the given pixmap in video - * memory. Only valid when the pixmap is currently in framebuffer. - */ -unsigned long -exaGetPixmapSize(PixmapPtr pPix) -{ - ExaPixmapPrivPtr pExaPixmap; - - pExaPixmap = ExaGetPixmapPriv(pPix); - if (pExaPixmap != NULL) - return pExaPixmap->fb_size; - return 0; -} - -/** - * exaGetDrawablePixmap() returns a backing pixmap for a given drawable. - * - * @param pDrawable the drawable being requested. - * - * This function returns the backing pixmap for a drawable, whether it is a - * redirected window, unredirected window, or already a pixmap. Note that - * coordinate translation is needed when drawing to the backing pixmap of a - * redirected window, and the translation coordinates are provided by calling - * exaGetOffscreenPixmap() on the drawable. - */ -PixmapPtr -exaGetDrawablePixmap(DrawablePtr pDrawable) -{ - if (pDrawable->type == DRAWABLE_WINDOW) - return pDrawable->pScreen->GetWindowPixmap ((WindowPtr) pDrawable); - else - return (PixmapPtr) pDrawable; -} - -/** - * Sets the offsets to add to coordinates to make them address the same bits in - * the backing drawable. These coordinates are nonzero only for redirected - * windows. - */ -void -exaGetDrawableDeltas (DrawablePtr pDrawable, PixmapPtr pPixmap, - int *xp, int *yp) -{ -#ifdef COMPOSITE - if (pDrawable->type == DRAWABLE_WINDOW) { - *xp = -pPixmap->screen_x; - *yp = -pPixmap->screen_y; - return; - } -#endif - - *xp = 0; - *yp = 0; -} - -/** - * exaPixmapDirty() marks a pixmap as dirty, allowing for - * optimizations in pixmap migration when no changes have occurred. - */ -void -exaPixmapDirty (PixmapPtr pPix, int x1, int y1, int x2, int y2) -{ - BoxRec box; - RegionRec region; - - box.x1 = max(x1, 0); - box.y1 = max(y1, 0); - box.x2 = min(x2, pPix->drawable.width); - box.y2 = min(y2, pPix->drawable.height); - - if (box.x1 >= box.x2 || box.y1 >= box.y2) - return; - - RegionInit(®ion, &box, 1); - DamageDamageRegion(&pPix->drawable, ®ion); - RegionUninit(®ion); -} - -static int -exaLog2(int val) -{ - int bits; - - if (val <= 0) - return 0; - for (bits = 0; val != 0; bits++) - val >>= 1; - return bits - 1; -} - -void -exaSetAccelBlock(ExaScreenPrivPtr pExaScr, ExaPixmapPrivPtr pExaPixmap, - int w, int h, int bpp) -{ - pExaPixmap->accel_blocked = 0; - - if (pExaScr->info->maxPitchPixels) { - int max_pitch = pExaScr->info->maxPitchPixels * bits_to_bytes(bpp); - - if (pExaPixmap->fb_pitch > max_pitch) - pExaPixmap->accel_blocked |= EXA_RANGE_PITCH; - } - - if (pExaScr->info->maxPitchBytes && - pExaPixmap->fb_pitch > pExaScr->info->maxPitchBytes) - pExaPixmap->accel_blocked |= EXA_RANGE_PITCH; - - if (w > pExaScr->info->maxX) - pExaPixmap->accel_blocked |= EXA_RANGE_WIDTH; - - if (h > pExaScr->info->maxY) - pExaPixmap->accel_blocked |= EXA_RANGE_HEIGHT; -} - -void -exaSetFbPitch(ExaScreenPrivPtr pExaScr, ExaPixmapPrivPtr pExaPixmap, - int w, int h, int bpp) -{ - if (pExaScr->info->flags & EXA_OFFSCREEN_ALIGN_POT && w != 1) - pExaPixmap->fb_pitch = bits_to_bytes((1 << (exaLog2(w - 1) + 1)) * bpp); - else - pExaPixmap->fb_pitch = bits_to_bytes(w * bpp); - - pExaPixmap->fb_pitch = EXA_ALIGN(pExaPixmap->fb_pitch, - pExaScr->info->pixmapPitchAlign); -} - -/** - * Returns TRUE if the pixmap is not movable. This is the case where it's a - * pixmap which has no private (almost always bad) or it's a scratch pixmap created by - * some X Server internal component (the score says it's pinned). - */ -Bool -exaPixmapIsPinned (PixmapPtr pPix) -{ - ExaPixmapPriv (pPix); - - if (pExaPixmap == NULL) - EXA_FatalErrorDebugWithRet(("EXA bug: exaPixmapIsPinned was called on a non-exa pixmap.\n"), TRUE); - - return pExaPixmap->score == EXA_PIXMAP_SCORE_PINNED; -} - -/** - * exaPixmapHasGpuCopy() is used to determine if a pixmap is in offscreen - * memory, meaning that acceleration could probably be done to it, and that it - * will need to be wrapped by PrepareAccess()/FinishAccess() when accessing it - * with the CPU. - * - * Note that except for UploadToScreen()/DownloadFromScreen() (which explicitly - * deal with moving pixmaps in and out of system memory), EXA will give drivers - * pixmaps as arguments for which exaPixmapHasGpuCopy() is TRUE. - * - * @return TRUE if the given drawable is in framebuffer memory. - */ -Bool -exaPixmapHasGpuCopy(PixmapPtr pPixmap) -{ - ScreenPtr pScreen = pPixmap->drawable.pScreen; - ExaScreenPriv(pScreen); - - if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) - return FALSE; - - return (*pExaScr->pixmap_has_gpu_copy)(pPixmap); -} - -/** - * exaDrawableIsOffscreen() is a convenience wrapper for exaPixmapHasGpuCopy(). - */ -Bool -exaDrawableIsOffscreen (DrawablePtr pDrawable) -{ - return exaPixmapHasGpuCopy (exaGetDrawablePixmap (pDrawable)); -} - -/** - * Returns the pixmap which backs a drawable, and the offsets to add to - * coordinates to make them address the same bits in the backing drawable. - */ -PixmapPtr -exaGetOffscreenPixmap (DrawablePtr pDrawable, int *xp, int *yp) -{ - PixmapPtr pPixmap = exaGetDrawablePixmap (pDrawable); - - exaGetDrawableDeltas (pDrawable, pPixmap, xp, yp); - - if (exaPixmapHasGpuCopy (pPixmap)) - return pPixmap; - else - return NULL; -} - -/** - * Returns TRUE if the pixmap GPU copy is being accessed. - */ -Bool -ExaDoPrepareAccess(PixmapPtr pPixmap, int index) -{ - ScreenPtr pScreen = pPixmap->drawable.pScreen; - ExaScreenPriv (pScreen); - ExaPixmapPriv(pPixmap); - Bool has_gpu_copy, ret; - int i; - - if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) - return FALSE; - - if (pExaPixmap == NULL) - EXA_FatalErrorDebugWithRet(("EXA bug: ExaDoPrepareAccess was called on a non-exa pixmap.\n"), FALSE); - - /* Handle repeated / nested calls. */ - for (i = 0; i < EXA_NUM_PREPARE_INDICES; i++) { - if (pExaScr->access[i].pixmap == pPixmap) { - pExaScr->access[i].count++; - return pExaScr->access[i].retval; - } - } - - /* If slot for this index is taken, find an empty slot */ - if (pExaScr->access[index].pixmap) { - for (index = EXA_NUM_PREPARE_INDICES - 1; index >= 0; index--) - if (!pExaScr->access[index].pixmap) - break; - } - - /* Access to this pixmap hasn't been prepared yet, so data pointer should be NULL. */ - if (pPixmap->devPrivate.ptr != NULL) { - EXA_FatalErrorDebug(("EXA bug: pPixmap->devPrivate.ptr was %p, but should have been NULL.\n", - pPixmap->devPrivate.ptr)); - } - - has_gpu_copy = exaPixmapHasGpuCopy(pPixmap); - - if (has_gpu_copy && pExaPixmap->fb_ptr) { - pPixmap->devPrivate.ptr = pExaPixmap->fb_ptr; - ret = TRUE; - } else { - pPixmap->devPrivate.ptr = pExaPixmap->sys_ptr; - ret = FALSE; - } - - /* Store so we can handle repeated / nested calls. */ - pExaScr->access[index].pixmap = pPixmap; - pExaScr->access[index].count = 1; - - if (!has_gpu_copy) - goto out; - - exaWaitSync (pScreen); - - if (pExaScr->info->PrepareAccess == NULL) - goto out; - - if (index >= EXA_PREPARE_AUX_DEST && - !(pExaScr->info->flags & EXA_SUPPORTS_PREPARE_AUX)) { - if (pExaPixmap->score == EXA_PIXMAP_SCORE_PINNED) - FatalError("Unsupported AUX indices used on a pinned pixmap.\n"); - exaMoveOutPixmap (pPixmap); - ret = FALSE; - goto out; - } - - if (!(*pExaScr->info->PrepareAccess) (pPixmap, index)) { - if (pExaPixmap->score == EXA_PIXMAP_SCORE_PINNED && - !(pExaScr->info->flags & EXA_MIXED_PIXMAPS)) - FatalError("Driver failed PrepareAccess on a pinned pixmap.\n"); - exaMoveOutPixmap (pPixmap); - ret = FALSE; - goto out; - } - - ret = TRUE; - -out: - pExaScr->access[index].retval = ret; - return ret; -} - -/** - * exaPrepareAccess() is EXA's wrapper for the driver's PrepareAccess() handler. - * - * It deals with waiting for synchronization with the card, determining if - * PrepareAccess() is necessary, and working around PrepareAccess() failure. - */ -void -exaPrepareAccess(DrawablePtr pDrawable, int index) -{ - PixmapPtr pPixmap = exaGetDrawablePixmap(pDrawable); - ExaScreenPriv(pDrawable->pScreen); - - if (pExaScr->prepare_access_reg) - pExaScr->prepare_access_reg(pPixmap, index, NULL); - else - (void)ExaDoPrepareAccess(pPixmap, index); -} - -/** - * exaFinishAccess() is EXA's wrapper for the driver's FinishAccess() handler. - * - * It deals with calling the driver's FinishAccess() only if necessary. - */ -void -exaFinishAccess(DrawablePtr pDrawable, int index) -{ - ScreenPtr pScreen = pDrawable->pScreen; - ExaScreenPriv (pScreen); - PixmapPtr pPixmap = exaGetDrawablePixmap (pDrawable); - ExaPixmapPriv (pPixmap); - int i; - - if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) - return; - - if (pExaPixmap == NULL) - EXA_FatalErrorDebugWithRet(("EXA bug: exaFinishAccesss was called on a non-exa pixmap.\n"),); - - /* Handle repeated / nested calls. */ - for (i = 0; i < EXA_NUM_PREPARE_INDICES; i++) { - if (pExaScr->access[i].pixmap == pPixmap) { - if (--pExaScr->access[i].count > 0) - return; - break; - } - } - - /* Catch unbalanced Prepare/FinishAccess calls. */ - if (i == EXA_NUM_PREPARE_INDICES) - EXA_FatalErrorDebugWithRet(("EXA bug: FinishAccess called without PrepareAccess for pixmap 0x%p.\n", - pPixmap),); - - pExaScr->access[i].pixmap = NULL; - - /* We always hide the devPrivate.ptr. */ - pPixmap->devPrivate.ptr = NULL; - - if (!pExaScr->info->FinishAccess || !exaPixmapHasGpuCopy(pPixmap)) - return; - - if (i >= EXA_PREPARE_AUX_DEST && - !(pExaScr->info->flags & EXA_SUPPORTS_PREPARE_AUX)) { - ErrorF("EXA bug: Trying to call driver FinishAccess hook with " - "unsupported index EXA_PREPARE_AUX*\n"); - return; - } - - (*pExaScr->info->FinishAccess) (pPixmap, i); -} - - -/** - * Helper for things common to all schemes when a pixmap is destroyed - */ -void -exaDestroyPixmap(PixmapPtr pPixmap) -{ - ExaScreenPriv(pPixmap->drawable.pScreen); - int i; - - /* Finish access if it was prepared (e.g. pixmap created during - * software fallback) - */ - for (i = 0; i < EXA_NUM_PREPARE_INDICES; i++) { - if (pExaScr->access[i].pixmap == pPixmap) { - exaFinishAccess(&pPixmap->drawable, i); - pExaScr->access[i].pixmap = NULL; - break; - } - } -} - - -/** - * Here begins EXA's GC code. - * Do not ever access the fb/mi layer directly. - */ - -static void -exaValidateGC(GCPtr pGC, - unsigned long changes, - DrawablePtr pDrawable); - -static void -exaDestroyGC(GCPtr pGC); - -static void -exaChangeGC (GCPtr pGC, - unsigned long mask); - -static void -exaCopyGC (GCPtr pGCSrc, - unsigned long mask, - GCPtr pGCDst); - -static void -exaChangeClip (GCPtr pGC, - int type, - pointer pvalue, - int nrects); - -static void -exaCopyClip(GCPtr pGCDst, GCPtr pGCSrc); - -static void -exaCopyClip(GCPtr pGCDst, GCPtr pGCSrc); - -static void -exaDestroyClip(GCPtr pGC); - -const GCFuncs exaGCFuncs = { - exaValidateGC, - exaChangeGC, - exaCopyGC, - exaDestroyGC, - exaChangeClip, - exaDestroyClip, - exaCopyClip -}; - -static void -exaValidateGC(GCPtr pGC, - unsigned long changes, - DrawablePtr pDrawable) -{ - /* fbValidateGC will do direct access to pixmaps if the tiling has changed. - * Do a few smart things so fbValidateGC can do it's work. - */ - - ScreenPtr pScreen = pDrawable->pScreen; - ExaScreenPriv(pScreen); - ExaGCPriv(pGC); - PixmapPtr pTile = NULL; - Bool finish_current_tile = FALSE; - - /* Either of these conditions is enough to trigger access to a tile pixmap. */ - /* With pGC->tileIsPixel == 1, you run the risk of dereferencing an invalid tile pixmap pointer. */ - if (pGC->fillStyle == FillTiled || ((changes & GCTile) && !pGC->tileIsPixel)) { - pTile = pGC->tile.pixmap; - - /* Sometimes tile pixmaps are swapped, you need access to: - * - The current tile if it depth matches. - * - Or the rotated tile if that one matches depth and !(changes & GCTile). - * - Or the current tile pixmap and a newly created one. - */ - if (pTile && pTile->drawable.depth != pDrawable->depth && !(changes & GCTile)) { - PixmapPtr pRotatedTile = fbGetRotatedPixmap(pGC); - if (pRotatedTile && pRotatedTile->drawable.depth == pDrawable->depth) - pTile = pRotatedTile; - else - finish_current_tile = TRUE; /* CreatePixmap will be called. */ - } - } - - if (pGC->stipple) - exaPrepareAccess(&pGC->stipple->drawable, EXA_PREPARE_MASK); - if (pTile) - exaPrepareAccess(&pTile->drawable, EXA_PREPARE_SRC); - - /* Calls to Create/DestroyPixmap have to be identified as special. */ - pExaScr->fallback_counter++; - swap(pExaGC, pGC, funcs); - (*pGC->funcs->ValidateGC)(pGC, changes, pDrawable); - swap(pExaGC, pGC, funcs); - pExaScr->fallback_counter--; - - if (pTile) - exaFinishAccess(&pTile->drawable, EXA_PREPARE_SRC); - if (finish_current_tile && pGC->tile.pixmap) - exaFinishAccess(&pGC->tile.pixmap->drawable, EXA_PREPARE_AUX_DEST); - if (pGC->stipple) - exaFinishAccess(&pGC->stipple->drawable, EXA_PREPARE_MASK); -} - -/* Is exaPrepareAccessGC() needed? */ -static void -exaDestroyGC(GCPtr pGC) -{ - ExaGCPriv(pGC); - swap(pExaGC, pGC, funcs); - (*pGC->funcs->DestroyGC)(pGC); - swap(pExaGC, pGC, funcs); -} - -static void -exaChangeGC (GCPtr pGC, - unsigned long mask) -{ - ExaGCPriv(pGC); - swap(pExaGC, pGC, funcs); - (*pGC->funcs->ChangeGC) (pGC, mask); - swap(pExaGC, pGC, funcs); -} - -static void -exaCopyGC (GCPtr pGCSrc, - unsigned long mask, - GCPtr pGCDst) -{ - ExaGCPriv(pGCDst); - swap(pExaGC, pGCDst, funcs); - (*pGCDst->funcs->CopyGC) (pGCSrc, mask, pGCDst); - swap(pExaGC, pGCDst, funcs); -} - -static void -exaChangeClip (GCPtr pGC, - int type, - pointer pvalue, - int nrects) -{ - ExaGCPriv(pGC); - swap(pExaGC, pGC, funcs); - (*pGC->funcs->ChangeClip) (pGC, type, pvalue, nrects); - swap(pExaGC, pGC, funcs); -} - -static void -exaCopyClip(GCPtr pGCDst, GCPtr pGCSrc) -{ - ExaGCPriv(pGCDst); - swap(pExaGC, pGCDst, funcs); - (*pGCDst->funcs->CopyClip)(pGCDst, pGCSrc); - swap(pExaGC, pGCDst, funcs); -} - -static void -exaDestroyClip(GCPtr pGC) -{ - ExaGCPriv(pGC); - swap(pExaGC, pGC, funcs); - (*pGC->funcs->DestroyClip)(pGC); - swap(pExaGC, pGC, funcs); -} - -/** - * exaCreateGC makes a new GC and hooks up its funcs handler, so that - * exaValidateGC() will get called. - */ -static int -exaCreateGC (GCPtr pGC) -{ - ScreenPtr pScreen = pGC->pScreen; - ExaScreenPriv(pScreen); - ExaGCPriv(pGC); - Bool ret; - - swap(pExaScr, pScreen, CreateGC); - if ((ret = (*pScreen->CreateGC) (pGC))) { - wrap(pExaGC, pGC, funcs, (GCFuncs *) &exaGCFuncs); - wrap(pExaGC, pGC, ops, (GCOps *) &exaOps); - } - swap(pExaScr, pScreen, CreateGC); - - return ret; -} - -static Bool -exaChangeWindowAttributes(WindowPtr pWin, unsigned long mask) -{ - Bool ret; - ScreenPtr pScreen = pWin->drawable.pScreen; - ExaScreenPriv(pScreen); - - if ((mask & CWBackPixmap) && pWin->backgroundState == BackgroundPixmap) - exaPrepareAccess(&pWin->background.pixmap->drawable, EXA_PREPARE_SRC); - - if ((mask & CWBorderPixmap) && pWin->borderIsPixel == FALSE) - exaPrepareAccess(&pWin->border.pixmap->drawable, EXA_PREPARE_MASK); - - pExaScr->fallback_counter++; - swap(pExaScr, pScreen, ChangeWindowAttributes); - ret = pScreen->ChangeWindowAttributes(pWin, mask); - swap(pExaScr, pScreen, ChangeWindowAttributes); - pExaScr->fallback_counter--; - - if ((mask & CWBackPixmap) && pWin->backgroundState == BackgroundPixmap) - exaFinishAccess(&pWin->background.pixmap->drawable, EXA_PREPARE_SRC); - if ((mask & CWBorderPixmap) && pWin->borderIsPixel == FALSE) - exaFinishAccess(&pWin->border.pixmap->drawable, EXA_PREPARE_MASK); - - return ret; -} - -static RegionPtr -exaBitmapToRegion(PixmapPtr pPix) -{ - RegionPtr ret; - ScreenPtr pScreen = pPix->drawable.pScreen; - ExaScreenPriv(pScreen); - - exaPrepareAccess(&pPix->drawable, EXA_PREPARE_SRC); - swap(pExaScr, pScreen, BitmapToRegion); - ret = (*pScreen->BitmapToRegion)(pPix); - swap(pExaScr, pScreen, BitmapToRegion); - exaFinishAccess(&pPix->drawable, EXA_PREPARE_SRC); - - return ret; -} - -static Bool -exaCreateScreenResources(ScreenPtr pScreen) -{ - ExaScreenPriv(pScreen); - PixmapPtr pScreenPixmap; - Bool b; - - swap(pExaScr, pScreen, CreateScreenResources); - b = pScreen->CreateScreenResources(pScreen); - swap(pExaScr, pScreen, CreateScreenResources); - - if (!b) - return FALSE; - - pScreenPixmap = pScreen->GetScreenPixmap(pScreen); - - if (pScreenPixmap) { - ExaPixmapPriv(pScreenPixmap); - - exaSetAccelBlock(pExaScr, pExaPixmap, - pScreenPixmap->drawable.width, - pScreenPixmap->drawable.height, - pScreenPixmap->drawable.bitsPerPixel); - } - - return TRUE; -} - -static void -ExaBlockHandler(int screenNum, pointer blockData, pointer pTimeout, - pointer pReadmask) -{ - ScreenPtr pScreen = screenInfo.screens[screenNum]; - ExaScreenPriv(pScreen); - - /* Move any deferred results from a software fallback to the driver pixmap */ - if (pExaScr->deferred_mixed_pixmap) - exaMoveInPixmap_mixed(pExaScr->deferred_mixed_pixmap); - - unwrap(pExaScr, pScreen, BlockHandler); - (*pScreen->BlockHandler) (screenNum, blockData, pTimeout, pReadmask); - wrap(pExaScr, pScreen, BlockHandler, ExaBlockHandler); - - /* The rest only applies to classic EXA */ - if (pExaScr->info->flags & EXA_HANDLES_PIXMAPS) - return; - - /* Try and keep the offscreen memory area tidy every now and then (at most - * once per second) when the server has been idle for at least 100ms. - */ - if (pExaScr->numOffscreenAvailable > 1) { - CARD32 now = GetTimeInMillis(); - - pExaScr->nextDefragment = now + - max(100, (INT32)(pExaScr->lastDefragment + 1000 - now)); - AdjustWaitForDelay(pTimeout, pExaScr->nextDefragment - now); - } -} - -static void -ExaWakeupHandler(int screenNum, pointer wakeupData, unsigned long result, - pointer pReadmask) -{ - ScreenPtr pScreen = screenInfo.screens[screenNum]; - ExaScreenPriv(pScreen); - - unwrap(pExaScr, pScreen, WakeupHandler); - (*pScreen->WakeupHandler) (screenNum, wakeupData, result, pReadmask); - wrap(pExaScr, pScreen, WakeupHandler, ExaWakeupHandler); - - if (result == 0 && pExaScr->numOffscreenAvailable > 1) { - CARD32 now = GetTimeInMillis(); - - if ((int)(now - pExaScr->nextDefragment) > 0) { - ExaOffscreenDefragment(pScreen); - pExaScr->lastDefragment = now; - } - } -} - -/** - * exaCloseScreen() unwraps its wrapped screen functions and tears down EXA's - * screen private, before calling down to the next CloseSccreen. - */ -static Bool -exaCloseScreen(int i, ScreenPtr pScreen) -{ - ExaScreenPriv(pScreen); - PictureScreenPtr ps = GetPictureScreenIfSet(pScreen); - - if (ps->Glyphs == exaGlyphs) - exaGlyphsFini(pScreen); - - if (pScreen->BlockHandler == ExaBlockHandler) - unwrap(pExaScr, pScreen, BlockHandler); - if (pScreen->WakeupHandler == ExaWakeupHandler) - unwrap(pExaScr, pScreen, WakeupHandler); - unwrap(pExaScr, pScreen, CreateGC); - unwrap(pExaScr, pScreen, CloseScreen); - unwrap(pExaScr, pScreen, GetImage); - unwrap(pExaScr, pScreen, GetSpans); - if (pExaScr->SavedCreatePixmap) - unwrap(pExaScr, pScreen, CreatePixmap); - if (pExaScr->SavedDestroyPixmap) - unwrap(pExaScr, pScreen, DestroyPixmap); - if (pExaScr->SavedModifyPixmapHeader) - unwrap(pExaScr, pScreen, ModifyPixmapHeader); - unwrap(pExaScr, pScreen, CopyWindow); - unwrap(pExaScr, pScreen, ChangeWindowAttributes); - unwrap(pExaScr, pScreen, BitmapToRegion); - unwrap(pExaScr, pScreen, CreateScreenResources); - unwrap(pExaScr, ps, Composite); - if (pExaScr->SavedGlyphs) - unwrap(pExaScr, ps, Glyphs); - unwrap(pExaScr, ps, Trapezoids); - unwrap(pExaScr, ps, Triangles); - unwrap(pExaScr, ps, AddTraps); - - free(pExaScr); - - return (*pScreen->CloseScreen) (i, pScreen); -} - -/** - * This function allocates a driver structure for EXA drivers to fill in. By - * having EXA allocate the structure, the driver structure can be extended - * without breaking ABI between EXA and the drivers. The driver's - * responsibility is to check beforehand that the EXA module has a matching - * major number and sufficient minor. Drivers are responsible for freeing the - * driver structure using free(). - * - * @return a newly allocated, zero-filled driver structure - */ -ExaDriverPtr -exaDriverAlloc(void) -{ - return calloc(1, sizeof(ExaDriverRec)); -} - -/** - * @param pScreen screen being initialized - * @param pScreenInfo EXA driver record - * - * exaDriverInit sets up EXA given a driver record filled in by the driver. - * pScreenInfo should have been allocated by exaDriverAlloc(). See the - * comments in _ExaDriver for what must be filled in and what is optional. - * - * @return TRUE if EXA was successfully initialized. - */ -Bool -exaDriverInit (ScreenPtr pScreen, - ExaDriverPtr pScreenInfo) -{ - ExaScreenPrivPtr pExaScr; - PictureScreenPtr ps; - - if (!pScreenInfo) - return FALSE; - - if (pScreenInfo->exa_major != EXA_VERSION_MAJOR || - pScreenInfo->exa_minor > EXA_VERSION_MINOR) - { - LogMessage(X_ERROR, "EXA(%d): driver's EXA version requirements " - "(%d.%d) are incompatible with EXA version (%d.%d)\n", - pScreen->myNum, - pScreenInfo->exa_major, pScreenInfo->exa_minor, - EXA_VERSION_MAJOR, EXA_VERSION_MINOR); - return FALSE; - } - - if (!pScreenInfo->CreatePixmap && !pScreenInfo->CreatePixmap2) { - if (!pScreenInfo->memoryBase) { - LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::memoryBase " - "must be non-zero\n", pScreen->myNum); - return FALSE; - } - - if (!pScreenInfo->memorySize) { - LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::memorySize must be " - "non-zero\n", pScreen->myNum); - return FALSE; - } - - if (pScreenInfo->offScreenBase > pScreenInfo->memorySize) { - LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::offScreenBase must " - "be <= ExaDriverRec::memorySize\n", pScreen->myNum); - return FALSE; - } - } - - if (!pScreenInfo->PrepareSolid) { - LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::PrepareSolid must be " - "non-NULL\n", pScreen->myNum); - return FALSE; - } - - if (!pScreenInfo->PrepareCopy) { - LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::PrepareCopy must be " - "non-NULL\n", pScreen->myNum); - return FALSE; - } - - if (!pScreenInfo->WaitMarker) { - LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::WaitMarker must be " - "non-NULL\n", pScreen->myNum); - return FALSE; - } - - /* If the driver doesn't set any max pitch values, we'll just assume - * that there's a limitation by pixels, and that it's the same as - * maxX. - * - * We want maxPitchPixels or maxPitchBytes to be set so we can check - * pixmaps against the max pitch in exaCreatePixmap() -- it matters - * whether a pixmap is rejected because of its pitch or - * because of its width. - */ - if (!pScreenInfo->maxPitchPixels && !pScreenInfo->maxPitchBytes) - { - pScreenInfo->maxPitchPixels = pScreenInfo->maxX; - } - - ps = GetPictureScreenIfSet(pScreen); - - if (!dixRegisterPrivateKey(&exaScreenPrivateKeyRec, PRIVATE_SCREEN, 0)) { - LogMessage(X_WARNING, "EXA(%d): Failed to register screen private\n", - pScreen->myNum); - return FALSE; - } - - pExaScr = calloc (sizeof (ExaScreenPrivRec), 1); - if (!pExaScr) { - LogMessage(X_WARNING, "EXA(%d): Failed to allocate screen private\n", - pScreen->myNum); - return FALSE; - } - - pExaScr->info = pScreenInfo; - - dixSetPrivate(&pScreen->devPrivates, exaScreenPrivateKey, pExaScr); - - pExaScr->migration = ExaMigrationAlways; - - exaDDXDriverInit(pScreen); - - if (!dixRegisterPrivateKey(&exaGCPrivateKeyRec, PRIVATE_GC, sizeof(ExaGCPrivRec))) { - LogMessage(X_WARNING, - "EXA(%d): Failed to allocate GC private\n", - pScreen->myNum); - return FALSE; - } - - /* - * Replace various fb screen functions - */ - if ((pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) && - (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS) || - (pExaScr->info->flags & EXA_MIXED_PIXMAPS))) - wrap(pExaScr, pScreen, BlockHandler, ExaBlockHandler); - if ((pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) && - !(pExaScr->info->flags & EXA_HANDLES_PIXMAPS)) - wrap(pExaScr, pScreen, WakeupHandler, ExaWakeupHandler); - wrap(pExaScr, pScreen, CreateGC, exaCreateGC); - wrap(pExaScr, pScreen, CloseScreen, exaCloseScreen); - wrap(pExaScr, pScreen, GetImage, exaGetImage); - wrap(pExaScr, pScreen, GetSpans, ExaCheckGetSpans); - wrap(pExaScr, pScreen, CopyWindow, exaCopyWindow); - wrap(pExaScr, pScreen, ChangeWindowAttributes, exaChangeWindowAttributes); - wrap(pExaScr, pScreen, BitmapToRegion, exaBitmapToRegion); - wrap(pExaScr, pScreen, CreateScreenResources, exaCreateScreenResources); - - if (ps) { - wrap(pExaScr, ps, Composite, exaComposite); - if (pScreenInfo->PrepareComposite) { - wrap(pExaScr, ps, Glyphs, exaGlyphs); - } else { - wrap(pExaScr, ps, Glyphs, ExaCheckGlyphs); - } - wrap(pExaScr, ps, Trapezoids, exaTrapezoids); - wrap(pExaScr, ps, Triangles, exaTriangles); - wrap(pExaScr, ps, AddTraps, ExaCheckAddTraps); - } - -#ifdef MITSHM - /* - * Don't allow shared pixmaps. - */ - ShmRegisterFuncs(pScreen, &exaShmFuncs); -#endif - /* - * Hookup offscreen pixmaps - */ - if (pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) - { - if (!dixRegisterPrivateKey(&exaPixmapPrivateKeyRec, PRIVATE_PIXMAP, sizeof(ExaPixmapPrivRec))) { - LogMessage(X_WARNING, - "EXA(%d): Failed to allocate pixmap private\n", - pScreen->myNum); - return FALSE; - } - if (pExaScr->info->flags & EXA_HANDLES_PIXMAPS) { - if (pExaScr->info->flags & EXA_MIXED_PIXMAPS) { - wrap(pExaScr, pScreen, CreatePixmap, exaCreatePixmap_mixed); - wrap(pExaScr, pScreen, DestroyPixmap, exaDestroyPixmap_mixed); - wrap(pExaScr, pScreen, ModifyPixmapHeader, exaModifyPixmapHeader_mixed); - pExaScr->do_migration = exaDoMigration_mixed; - pExaScr->pixmap_has_gpu_copy = exaPixmapHasGpuCopy_mixed; - pExaScr->do_move_in_pixmap = exaMoveInPixmap_mixed; - pExaScr->do_move_out_pixmap = NULL; - pExaScr->prepare_access_reg = exaPrepareAccessReg_mixed; - } else { - wrap(pExaScr, pScreen, CreatePixmap, exaCreatePixmap_driver); - wrap(pExaScr, pScreen, DestroyPixmap, exaDestroyPixmap_driver); - wrap(pExaScr, pScreen, ModifyPixmapHeader, exaModifyPixmapHeader_driver); - pExaScr->do_migration = NULL; - pExaScr->pixmap_has_gpu_copy = exaPixmapHasGpuCopy_driver; - pExaScr->do_move_in_pixmap = NULL; - pExaScr->do_move_out_pixmap = NULL; - pExaScr->prepare_access_reg = NULL; - } - } else { - wrap(pExaScr, pScreen, CreatePixmap, exaCreatePixmap_classic); - wrap(pExaScr, pScreen, DestroyPixmap, exaDestroyPixmap_classic); - wrap(pExaScr, pScreen, ModifyPixmapHeader, exaModifyPixmapHeader_classic); - pExaScr->do_migration = exaDoMigration_classic; - pExaScr->pixmap_has_gpu_copy = exaPixmapHasGpuCopy_classic; - pExaScr->do_move_in_pixmap = exaMoveInPixmap_classic; - pExaScr->do_move_out_pixmap = exaMoveOutPixmap_classic; - pExaScr->prepare_access_reg = exaPrepareAccessReg_classic; - } - if (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS)) { - LogMessage(X_INFO, "EXA(%d): Offscreen pixmap area of %lu bytes\n", - pScreen->myNum, - pExaScr->info->memorySize - pExaScr->info->offScreenBase); - } else { - LogMessage(X_INFO, "EXA(%d): Driver allocated offscreen pixmaps\n", - pScreen->myNum); - - } - } - else - LogMessage(X_INFO, "EXA(%d): No offscreen pixmaps\n", pScreen->myNum); - - if (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS)) { - DBG_PIXMAP(("============== %ld < %ld\n", pExaScr->info->offScreenBase, - pExaScr->info->memorySize)); - if (pExaScr->info->offScreenBase < pExaScr->info->memorySize) { - if (!exaOffscreenInit (pScreen)) { - LogMessage(X_WARNING, "EXA(%d): Offscreen pixmap setup failed\n", - pScreen->myNum); - return FALSE; - } - } - } - - if (ps->Glyphs == exaGlyphs) - exaGlyphsInit(pScreen); - - LogMessage(X_INFO, "EXA(%d): Driver registered support for the following" - " operations:\n", pScreen->myNum); - assert(pScreenInfo->PrepareSolid != NULL); - LogMessage(X_INFO, " Solid\n"); - assert(pScreenInfo->PrepareCopy != NULL); - LogMessage(X_INFO, " Copy\n"); - if (pScreenInfo->PrepareComposite != NULL) { - LogMessage(X_INFO, " Composite (RENDER acceleration)\n"); - } - if (pScreenInfo->UploadToScreen != NULL) { - LogMessage(X_INFO, " UploadToScreen\n"); - } - if (pScreenInfo->DownloadFromScreen != NULL) { - LogMessage(X_INFO, " DownloadFromScreen\n"); - } - - return TRUE; -} - -/** - * exaDriverFini tears down EXA on a given screen. - * - * @param pScreen screen being torn down. - */ -void -exaDriverFini (ScreenPtr pScreen) -{ - /*right now does nothing*/ -} - -/** - * exaMarkSync() should be called after any asynchronous drawing by the hardware. - * - * @param pScreen screen which drawing occurred on - * - * exaMarkSync() sets a flag to indicate that some asynchronous drawing has - * happened and a WaitSync() will be necessary before relying on the contents of - * offscreen memory from the CPU's perspective. It also calls an optional - * driver MarkSync() callback, the return value of which may be used to do partial - * synchronization with the hardware in the future. - */ -void exaMarkSync(ScreenPtr pScreen) -{ - ExaScreenPriv(pScreen); - - pExaScr->info->needsSync = TRUE; - if (pExaScr->info->MarkSync != NULL) { - pExaScr->info->lastMarker = (*pExaScr->info->MarkSync)(pScreen); - } -} - -/** - * exaWaitSync() ensures that all drawing has been completed. - * - * @param pScreen screen being synchronized. - * - * Calls down into the driver to ensure that all previous drawing has completed. - * It should always be called before relying on the framebuffer contents - * reflecting previous drawing, from a CPU perspective. - */ -void exaWaitSync(ScreenPtr pScreen) -{ - ExaScreenPriv(pScreen); - - if (pExaScr->info->needsSync && !pExaScr->swappedOut) { - (*pExaScr->info->WaitMarker)(pScreen, pExaScr->info->lastMarker); - pExaScr->info->needsSync = FALSE; - } -} - -/** - * Performs migration of the pixmaps according to the operation information - * provided in pixmaps and can_accel and the migration scheme chosen in the - * config file. - */ -void -exaDoMigration (ExaMigrationPtr pixmaps, int npixmaps, Bool can_accel) -{ - ScreenPtr pScreen = pixmaps[0].pPix->drawable.pScreen; - ExaScreenPriv(pScreen); - - if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) - return; - - if (pExaScr->do_migration) - (*pExaScr->do_migration)(pixmaps, npixmaps, can_accel); -} - -void -exaMoveInPixmap (PixmapPtr pPixmap) -{ - ScreenPtr pScreen = pPixmap->drawable.pScreen; - ExaScreenPriv(pScreen); - - if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) - return; - - if (pExaScr->do_move_in_pixmap) - (*pExaScr->do_move_in_pixmap)(pPixmap); -} - -void -exaMoveOutPixmap (PixmapPtr pPixmap) -{ - ScreenPtr pScreen = pPixmap->drawable.pScreen; - ExaScreenPriv(pScreen); - - if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) - return; - - if (pExaScr->do_move_out_pixmap) - (*pExaScr->do_move_out_pixmap)(pPixmap); -} +/* + * Copyright © 2001 Keith Packard + * + * Partly based on code that is Copyright © The XFree86 Project Inc. + * + * Permission to use, copy, modify, distribute, and sell this software and its + * documentation for any purpose is hereby granted without fee, provided that + * the above copyright notice appear in all copies and that both that + * copyright notice and this permission notice appear in supporting + * documentation, and that the name of Keith Packard not be used in + * advertising or publicity pertaining to distribution of the software without + * specific, written prior permission. Keith Packard makes no + * representations about the suitability of this software for any purpose. It + * is provided "as is" without express or implied warranty. + * + * KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, + * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO + * EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR + * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, + * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER + * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/** @file + * This file covers the initialization and teardown of EXA, and has various + * functions not responsible for performing rendering, pixmap migration, or + * memory management. + */ + +#ifdef HAVE_DIX_CONFIG_H +#include +#endif + +#include + +#include "exa_priv.h" +#include "exa.h" + +DevPrivateKeyRec exaScreenPrivateKeyRec; +DevPrivateKeyRec exaPixmapPrivateKeyRec; +DevPrivateKeyRec exaGCPrivateKeyRec; + +#ifdef MITSHM +static ShmFuncs exaShmFuncs = { NULL, NULL }; +#endif + +/** + * exaGetPixmapOffset() returns the offset (in bytes) within the framebuffer of + * the beginning of the given pixmap. + * + * Note that drivers are free to, and often do, munge this offset as necessary + * for handing to the hardware -- for example, translating it into a different + * aperture. This function may need to be extended in the future if we grow + * support for having multiple card-accessible offscreen, such as an AGP memory + * pool alongside the framebuffer pool. + */ +unsigned long +exaGetPixmapOffset(PixmapPtr pPix) +{ + ExaScreenPriv (pPix->drawable.pScreen); + ExaPixmapPriv (pPix); + + return (CARD8 *)pExaPixmap->fb_ptr - pExaScr->info->memoryBase; +} + +void * +exaGetPixmapDriverPrivate(PixmapPtr pPix) +{ + ExaPixmapPriv(pPix); + + return pExaPixmap->driverPriv; +} + +/** + * exaGetPixmapPitch() returns the pitch (in bytes) of the given pixmap. + * + * This is a helper to make driver code more obvious, due to the rather obscure + * naming of the pitch field in the pixmap. + */ +unsigned long +exaGetPixmapPitch(PixmapPtr pPix) +{ + return pPix->devKind; +} + +/** + * exaGetPixmapSize() returns the size in bytes of the given pixmap in video + * memory. Only valid when the pixmap is currently in framebuffer. + */ +unsigned long +exaGetPixmapSize(PixmapPtr pPix) +{ + ExaPixmapPrivPtr pExaPixmap; + + pExaPixmap = ExaGetPixmapPriv(pPix); + if (pExaPixmap != NULL) + return pExaPixmap->fb_size; + return 0; +} + +/** + * exaGetDrawablePixmap() returns a backing pixmap for a given drawable. + * + * @param pDrawable the drawable being requested. + * + * This function returns the backing pixmap for a drawable, whether it is a + * redirected window, unredirected window, or already a pixmap. Note that + * coordinate translation is needed when drawing to the backing pixmap of a + * redirected window, and the translation coordinates are provided by calling + * exaGetOffscreenPixmap() on the drawable. + */ +PixmapPtr +exaGetDrawablePixmap(DrawablePtr pDrawable) +{ + if (pDrawable->type == DRAWABLE_WINDOW) + return pDrawable->pScreen->GetWindowPixmap ((WindowPtr) pDrawable); + else + return (PixmapPtr) pDrawable; +} + +/** + * Sets the offsets to add to coordinates to make them address the same bits in + * the backing drawable. These coordinates are nonzero only for redirected + * windows. + */ +void +exaGetDrawableDeltas (DrawablePtr pDrawable, PixmapPtr pPixmap, + int *xp, int *yp) +{ +#ifdef COMPOSITE + if (pDrawable->type == DRAWABLE_WINDOW) { + *xp = -pPixmap->screen_x; + *yp = -pPixmap->screen_y; + return; + } +#endif + + *xp = 0; + *yp = 0; +} + +/** + * exaPixmapDirty() marks a pixmap as dirty, allowing for + * optimizations in pixmap migration when no changes have occurred. + */ +void +exaPixmapDirty (PixmapPtr pPix, int x1, int y1, int x2, int y2) +{ + BoxRec box; + RegionRec region; + + box.x1 = max(x1, 0); + box.y1 = max(y1, 0); + box.x2 = min(x2, pPix->drawable.width); + box.y2 = min(y2, pPix->drawable.height); + + if (box.x1 >= box.x2 || box.y1 >= box.y2) + return; + + RegionInit(®ion, &box, 1); + DamageDamageRegion(&pPix->drawable, ®ion); + RegionUninit(®ion); +} + +static int +exaLog2(int val) +{ + int bits; + + if (val <= 0) + return 0; + for (bits = 0; val != 0; bits++) + val >>= 1; + return bits - 1; +} + +void +exaSetAccelBlock(ExaScreenPrivPtr pExaScr, ExaPixmapPrivPtr pExaPixmap, + int w, int h, int bpp) +{ + pExaPixmap->accel_blocked = 0; + + if (pExaScr->info->maxPitchPixels) { + int max_pitch = pExaScr->info->maxPitchPixels * bits_to_bytes(bpp); + + if (pExaPixmap->fb_pitch > max_pitch) + pExaPixmap->accel_blocked |= EXA_RANGE_PITCH; + } + + if (pExaScr->info->maxPitchBytes && + pExaPixmap->fb_pitch > pExaScr->info->maxPitchBytes) + pExaPixmap->accel_blocked |= EXA_RANGE_PITCH; + + if (w > pExaScr->info->maxX) + pExaPixmap->accel_blocked |= EXA_RANGE_WIDTH; + + if (h > pExaScr->info->maxY) + pExaPixmap->accel_blocked |= EXA_RANGE_HEIGHT; +} + +void +exaSetFbPitch(ExaScreenPrivPtr pExaScr, ExaPixmapPrivPtr pExaPixmap, + int w, int h, int bpp) +{ + if (pExaScr->info->flags & EXA_OFFSCREEN_ALIGN_POT && w != 1) + pExaPixmap->fb_pitch = bits_to_bytes((1 << (exaLog2(w - 1) + 1)) * bpp); + else + pExaPixmap->fb_pitch = bits_to_bytes(w * bpp); + + pExaPixmap->fb_pitch = EXA_ALIGN(pExaPixmap->fb_pitch, + pExaScr->info->pixmapPitchAlign); +} + +/** + * Returns TRUE if the pixmap is not movable. This is the case where it's a + * pixmap which has no private (almost always bad) or it's a scratch pixmap created by + * some X Server internal component (the score says it's pinned). + */ +Bool +exaPixmapIsPinned (PixmapPtr pPix) +{ + ExaPixmapPriv (pPix); + + if (pExaPixmap == NULL) + EXA_FatalErrorDebugWithRet(("EXA bug: exaPixmapIsPinned was called on a non-exa pixmap.\n"), TRUE); + + return pExaPixmap->score == EXA_PIXMAP_SCORE_PINNED; +} + +/** + * exaPixmapHasGpuCopy() is used to determine if a pixmap is in offscreen + * memory, meaning that acceleration could probably be done to it, and that it + * will need to be wrapped by PrepareAccess()/FinishAccess() when accessing it + * with the CPU. + * + * Note that except for UploadToScreen()/DownloadFromScreen() (which explicitly + * deal with moving pixmaps in and out of system memory), EXA will give drivers + * pixmaps as arguments for which exaPixmapHasGpuCopy() is TRUE. + * + * @return TRUE if the given drawable is in framebuffer memory. + */ +Bool +exaPixmapHasGpuCopy(PixmapPtr pPixmap) +{ + ScreenPtr pScreen = pPixmap->drawable.pScreen; + ExaScreenPriv(pScreen); + + if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) + return FALSE; + + return (*pExaScr->pixmap_has_gpu_copy)(pPixmap); +} + +/** + * exaDrawableIsOffscreen() is a convenience wrapper for exaPixmapHasGpuCopy(). + */ +Bool +exaDrawableIsOffscreen (DrawablePtr pDrawable) +{ + return exaPixmapHasGpuCopy (exaGetDrawablePixmap (pDrawable)); +} + +/** + * Returns the pixmap which backs a drawable, and the offsets to add to + * coordinates to make them address the same bits in the backing drawable. + */ +PixmapPtr +exaGetOffscreenPixmap (DrawablePtr pDrawable, int *xp, int *yp) +{ + PixmapPtr pPixmap = exaGetDrawablePixmap (pDrawable); + + exaGetDrawableDeltas (pDrawable, pPixmap, xp, yp); + + if (exaPixmapHasGpuCopy (pPixmap)) + return pPixmap; + else + return NULL; +} + +/** + * Returns TRUE if the pixmap GPU copy is being accessed. + */ +Bool +ExaDoPrepareAccess(PixmapPtr pPixmap, int index) +{ + ScreenPtr pScreen = pPixmap->drawable.pScreen; + ExaScreenPriv (pScreen); + ExaPixmapPriv(pPixmap); + Bool has_gpu_copy, ret; + int i; + + if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) + return FALSE; + + if (pExaPixmap == NULL) + EXA_FatalErrorDebugWithRet(("EXA bug: ExaDoPrepareAccess was called on a non-exa pixmap.\n"), FALSE); + + /* Handle repeated / nested calls. */ + for (i = 0; i < EXA_NUM_PREPARE_INDICES; i++) { + if (pExaScr->access[i].pixmap == pPixmap) { + pExaScr->access[i].count++; + return pExaScr->access[i].retval; + } + } + + /* If slot for this index is taken, find an empty slot */ + if (pExaScr->access[index].pixmap) { + for (index = EXA_NUM_PREPARE_INDICES - 1; index >= 0; index--) + if (!pExaScr->access[index].pixmap) + break; + } + + /* Access to this pixmap hasn't been prepared yet, so data pointer should be NULL. */ + if (pPixmap->devPrivate.ptr != NULL) { + EXA_FatalErrorDebug(("EXA bug: pPixmap->devPrivate.ptr was %p, but should have been NULL.\n", + pPixmap->devPrivate.ptr)); + } + + has_gpu_copy = exaPixmapHasGpuCopy(pPixmap); + + if (has_gpu_copy && pExaPixmap->fb_ptr) { + pPixmap->devPrivate.ptr = pExaPixmap->fb_ptr; + ret = TRUE; + } else { + pPixmap->devPrivate.ptr = pExaPixmap->sys_ptr; + ret = FALSE; + } + + /* Store so we can handle repeated / nested calls. */ + pExaScr->access[index].pixmap = pPixmap; + pExaScr->access[index].count = 1; + + if (!has_gpu_copy) + goto out; + + exaWaitSync (pScreen); + + if (pExaScr->info->PrepareAccess == NULL) + goto out; + + if (index >= EXA_PREPARE_AUX_DEST && + !(pExaScr->info->flags & EXA_SUPPORTS_PREPARE_AUX)) { + if (pExaPixmap->score == EXA_PIXMAP_SCORE_PINNED) + FatalError("Unsupported AUX indices used on a pinned pixmap.\n"); + exaMoveOutPixmap (pPixmap); + ret = FALSE; + goto out; + } + + if (!(*pExaScr->info->PrepareAccess) (pPixmap, index)) { + if (pExaPixmap->score == EXA_PIXMAP_SCORE_PINNED && + !(pExaScr->info->flags & EXA_MIXED_PIXMAPS)) + FatalError("Driver failed PrepareAccess on a pinned pixmap.\n"); + exaMoveOutPixmap (pPixmap); + ret = FALSE; + goto out; + } + + ret = TRUE; + +out: + pExaScr->access[index].retval = ret; + return ret; +} + +/** + * exaPrepareAccess() is EXA's wrapper for the driver's PrepareAccess() handler. + * + * It deals with waiting for synchronization with the card, determining if + * PrepareAccess() is necessary, and working around PrepareAccess() failure. + */ +void +exaPrepareAccess(DrawablePtr pDrawable, int index) +{ + PixmapPtr pPixmap = exaGetDrawablePixmap(pDrawable); + ExaScreenPriv(pDrawable->pScreen); + + if (pExaScr->prepare_access_reg) + pExaScr->prepare_access_reg(pPixmap, index, NULL); + else + (void)ExaDoPrepareAccess(pPixmap, index); +} + +/** + * exaFinishAccess() is EXA's wrapper for the driver's FinishAccess() handler. + * + * It deals with calling the driver's FinishAccess() only if necessary. + */ +void +exaFinishAccess(DrawablePtr pDrawable, int index) +{ + ScreenPtr pScreen = pDrawable->pScreen; + ExaScreenPriv (pScreen); + PixmapPtr pPixmap = exaGetDrawablePixmap (pDrawable); + ExaPixmapPriv (pPixmap); + int i; + + if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) + return; + + if (pExaPixmap == NULL) + EXA_FatalErrorDebugWithRet(("EXA bug: exaFinishAccesss was called on a non-exa pixmap.\n"),); + + /* Handle repeated / nested calls. */ + for (i = 0; i < EXA_NUM_PREPARE_INDICES; i++) { + if (pExaScr->access[i].pixmap == pPixmap) { + if (--pExaScr->access[i].count > 0) + return; + break; + } + } + + /* Catch unbalanced Prepare/FinishAccess calls. */ + if (i == EXA_NUM_PREPARE_INDICES) + EXA_FatalErrorDebugWithRet(("EXA bug: FinishAccess called without PrepareAccess for pixmap 0x%p.\n", + pPixmap),); + + pExaScr->access[i].pixmap = NULL; + + /* We always hide the devPrivate.ptr. */ + pPixmap->devPrivate.ptr = NULL; + + /* Only call FinishAccess if PrepareAccess was called and succeeded. */ + if (!pExaScr->info->FinishAccess || !pExaScr->access[i].retval) + return; + + if (i >= EXA_PREPARE_AUX_DEST && + !(pExaScr->info->flags & EXA_SUPPORTS_PREPARE_AUX)) { + ErrorF("EXA bug: Trying to call driver FinishAccess hook with " + "unsupported index EXA_PREPARE_AUX*\n"); + return; + } + + (*pExaScr->info->FinishAccess) (pPixmap, i); +} + + +/** + * Helper for things common to all schemes when a pixmap is destroyed + */ +void +exaDestroyPixmap(PixmapPtr pPixmap) +{ + ExaScreenPriv(pPixmap->drawable.pScreen); + int i; + + /* Finish access if it was prepared (e.g. pixmap created during + * software fallback) + */ + for (i = 0; i < EXA_NUM_PREPARE_INDICES; i++) { + if (pExaScr->access[i].pixmap == pPixmap) { + exaFinishAccess(&pPixmap->drawable, i); + pExaScr->access[i].pixmap = NULL; + break; + } + } +} + + +/** + * Here begins EXA's GC code. + * Do not ever access the fb/mi layer directly. + */ + +static void +exaValidateGC(GCPtr pGC, + unsigned long changes, + DrawablePtr pDrawable); + +static void +exaDestroyGC(GCPtr pGC); + +static void +exaChangeGC (GCPtr pGC, + unsigned long mask); + +static void +exaCopyGC (GCPtr pGCSrc, + unsigned long mask, + GCPtr pGCDst); + +static void +exaChangeClip (GCPtr pGC, + int type, + pointer pvalue, + int nrects); + +static void +exaCopyClip(GCPtr pGCDst, GCPtr pGCSrc); + +static void +exaCopyClip(GCPtr pGCDst, GCPtr pGCSrc); + +static void +exaDestroyClip(GCPtr pGC); + +const GCFuncs exaGCFuncs = { + exaValidateGC, + exaChangeGC, + exaCopyGC, + exaDestroyGC, + exaChangeClip, + exaDestroyClip, + exaCopyClip +}; + +static void +exaValidateGC(GCPtr pGC, + unsigned long changes, + DrawablePtr pDrawable) +{ + /* fbValidateGC will do direct access to pixmaps if the tiling has changed. + * Do a few smart things so fbValidateGC can do it's work. + */ + + ScreenPtr pScreen = pDrawable->pScreen; + ExaScreenPriv(pScreen); + ExaGCPriv(pGC); + PixmapPtr pTile = NULL; + Bool finish_current_tile = FALSE; + + /* Either of these conditions is enough to trigger access to a tile pixmap. */ + /* With pGC->tileIsPixel == 1, you run the risk of dereferencing an invalid tile pixmap pointer. */ + if (pGC->fillStyle == FillTiled || ((changes & GCTile) && !pGC->tileIsPixel)) { + pTile = pGC->tile.pixmap; + + /* Sometimes tile pixmaps are swapped, you need access to: + * - The current tile if it depth matches. + * - Or the rotated tile if that one matches depth and !(changes & GCTile). + * - Or the current tile pixmap and a newly created one. + */ + if (pTile && pTile->drawable.depth != pDrawable->depth && !(changes & GCTile)) { + PixmapPtr pRotatedTile = fbGetRotatedPixmap(pGC); + if (pRotatedTile && pRotatedTile->drawable.depth == pDrawable->depth) + pTile = pRotatedTile; + else + finish_current_tile = TRUE; /* CreatePixmap will be called. */ + } + } + + if (pGC->stipple) + exaPrepareAccess(&pGC->stipple->drawable, EXA_PREPARE_MASK); + if (pTile) + exaPrepareAccess(&pTile->drawable, EXA_PREPARE_SRC); + + /* Calls to Create/DestroyPixmap have to be identified as special. */ + pExaScr->fallback_counter++; + swap(pExaGC, pGC, funcs); + (*pGC->funcs->ValidateGC)(pGC, changes, pDrawable); + swap(pExaGC, pGC, funcs); + pExaScr->fallback_counter--; + + if (pTile) + exaFinishAccess(&pTile->drawable, EXA_PREPARE_SRC); + if (finish_current_tile && pGC->tile.pixmap) + exaFinishAccess(&pGC->tile.pixmap->drawable, EXA_PREPARE_AUX_DEST); + if (pGC->stipple) + exaFinishAccess(&pGC->stipple->drawable, EXA_PREPARE_MASK); +} + +/* Is exaPrepareAccessGC() needed? */ +static void +exaDestroyGC(GCPtr pGC) +{ + ExaGCPriv(pGC); + swap(pExaGC, pGC, funcs); + (*pGC->funcs->DestroyGC)(pGC); + swap(pExaGC, pGC, funcs); +} + +static void +exaChangeGC (GCPtr pGC, + unsigned long mask) +{ + ExaGCPriv(pGC); + swap(pExaGC, pGC, funcs); + (*pGC->funcs->ChangeGC) (pGC, mask); + swap(pExaGC, pGC, funcs); +} + +static void +exaCopyGC (GCPtr pGCSrc, + unsigned long mask, + GCPtr pGCDst) +{ + ExaGCPriv(pGCDst); + swap(pExaGC, pGCDst, funcs); + (*pGCDst->funcs->CopyGC) (pGCSrc, mask, pGCDst); + swap(pExaGC, pGCDst, funcs); +} + +static void +exaChangeClip (GCPtr pGC, + int type, + pointer pvalue, + int nrects) +{ + ExaGCPriv(pGC); + swap(pExaGC, pGC, funcs); + (*pGC->funcs->ChangeClip) (pGC, type, pvalue, nrects); + swap(pExaGC, pGC, funcs); +} + +static void +exaCopyClip(GCPtr pGCDst, GCPtr pGCSrc) +{ + ExaGCPriv(pGCDst); + swap(pExaGC, pGCDst, funcs); + (*pGCDst->funcs->CopyClip)(pGCDst, pGCSrc); + swap(pExaGC, pGCDst, funcs); +} + +static void +exaDestroyClip(GCPtr pGC) +{ + ExaGCPriv(pGC); + swap(pExaGC, pGC, funcs); + (*pGC->funcs->DestroyClip)(pGC); + swap(pExaGC, pGC, funcs); +} + +/** + * exaCreateGC makes a new GC and hooks up its funcs handler, so that + * exaValidateGC() will get called. + */ +static int +exaCreateGC (GCPtr pGC) +{ + ScreenPtr pScreen = pGC->pScreen; + ExaScreenPriv(pScreen); + ExaGCPriv(pGC); + Bool ret; + + swap(pExaScr, pScreen, CreateGC); + if ((ret = (*pScreen->CreateGC) (pGC))) { + wrap(pExaGC, pGC, funcs, (GCFuncs *) &exaGCFuncs); + wrap(pExaGC, pGC, ops, (GCOps *) &exaOps); + } + swap(pExaScr, pScreen, CreateGC); + + return ret; +} + +static Bool +exaChangeWindowAttributes(WindowPtr pWin, unsigned long mask) +{ + Bool ret; + ScreenPtr pScreen = pWin->drawable.pScreen; + ExaScreenPriv(pScreen); + + if ((mask & CWBackPixmap) && pWin->backgroundState == BackgroundPixmap) + exaPrepareAccess(&pWin->background.pixmap->drawable, EXA_PREPARE_SRC); + + if ((mask & CWBorderPixmap) && pWin->borderIsPixel == FALSE) + exaPrepareAccess(&pWin->border.pixmap->drawable, EXA_PREPARE_MASK); + + pExaScr->fallback_counter++; + swap(pExaScr, pScreen, ChangeWindowAttributes); + ret = pScreen->ChangeWindowAttributes(pWin, mask); + swap(pExaScr, pScreen, ChangeWindowAttributes); + pExaScr->fallback_counter--; + + if ((mask & CWBackPixmap) && pWin->backgroundState == BackgroundPixmap) + exaFinishAccess(&pWin->background.pixmap->drawable, EXA_PREPARE_SRC); + if ((mask & CWBorderPixmap) && pWin->borderIsPixel == FALSE) + exaFinishAccess(&pWin->border.pixmap->drawable, EXA_PREPARE_MASK); + + return ret; +} + +static RegionPtr +exaBitmapToRegion(PixmapPtr pPix) +{ + RegionPtr ret; + ScreenPtr pScreen = pPix->drawable.pScreen; + ExaScreenPriv(pScreen); + + exaPrepareAccess(&pPix->drawable, EXA_PREPARE_SRC); + swap(pExaScr, pScreen, BitmapToRegion); + ret = (*pScreen->BitmapToRegion)(pPix); + swap(pExaScr, pScreen, BitmapToRegion); + exaFinishAccess(&pPix->drawable, EXA_PREPARE_SRC); + + return ret; +} + +static Bool +exaCreateScreenResources(ScreenPtr pScreen) +{ + ExaScreenPriv(pScreen); + PixmapPtr pScreenPixmap; + Bool b; + + swap(pExaScr, pScreen, CreateScreenResources); + b = pScreen->CreateScreenResources(pScreen); + swap(pExaScr, pScreen, CreateScreenResources); + + if (!b) + return FALSE; + + pScreenPixmap = pScreen->GetScreenPixmap(pScreen); + + if (pScreenPixmap) { + ExaPixmapPriv(pScreenPixmap); + + exaSetAccelBlock(pExaScr, pExaPixmap, + pScreenPixmap->drawable.width, + pScreenPixmap->drawable.height, + pScreenPixmap->drawable.bitsPerPixel); + } + + return TRUE; +} + +static void +ExaBlockHandler(int screenNum, pointer blockData, pointer pTimeout, + pointer pReadmask) +{ + ScreenPtr pScreen = screenInfo.screens[screenNum]; + ExaScreenPriv(pScreen); + + /* Move any deferred results from a software fallback to the driver pixmap */ + if (pExaScr->deferred_mixed_pixmap) + exaMoveInPixmap_mixed(pExaScr->deferred_mixed_pixmap); + + unwrap(pExaScr, pScreen, BlockHandler); + (*pScreen->BlockHandler) (screenNum, blockData, pTimeout, pReadmask); + wrap(pExaScr, pScreen, BlockHandler, ExaBlockHandler); + + /* The rest only applies to classic EXA */ + if (pExaScr->info->flags & EXA_HANDLES_PIXMAPS) + return; + + /* Try and keep the offscreen memory area tidy every now and then (at most + * once per second) when the server has been idle for at least 100ms. + */ + if (pExaScr->numOffscreenAvailable > 1) { + CARD32 now = GetTimeInMillis(); + + pExaScr->nextDefragment = now + + max(100, (INT32)(pExaScr->lastDefragment + 1000 - now)); + AdjustWaitForDelay(pTimeout, pExaScr->nextDefragment - now); + } +} + +static void +ExaWakeupHandler(int screenNum, pointer wakeupData, unsigned long result, + pointer pReadmask) +{ + ScreenPtr pScreen = screenInfo.screens[screenNum]; + ExaScreenPriv(pScreen); + + unwrap(pExaScr, pScreen, WakeupHandler); + (*pScreen->WakeupHandler) (screenNum, wakeupData, result, pReadmask); + wrap(pExaScr, pScreen, WakeupHandler, ExaWakeupHandler); + + if (result == 0 && pExaScr->numOffscreenAvailable > 1) { + CARD32 now = GetTimeInMillis(); + + if ((int)(now - pExaScr->nextDefragment) > 0) { + ExaOffscreenDefragment(pScreen); + pExaScr->lastDefragment = now; + } + } +} + +/** + * exaCloseScreen() unwraps its wrapped screen functions and tears down EXA's + * screen private, before calling down to the next CloseSccreen. + */ +static Bool +exaCloseScreen(int i, ScreenPtr pScreen) +{ + ExaScreenPriv(pScreen); + PictureScreenPtr ps = GetPictureScreenIfSet(pScreen); + + if (ps->Glyphs == exaGlyphs) + exaGlyphsFini(pScreen); + + if (pScreen->BlockHandler == ExaBlockHandler) + unwrap(pExaScr, pScreen, BlockHandler); + if (pScreen->WakeupHandler == ExaWakeupHandler) + unwrap(pExaScr, pScreen, WakeupHandler); + unwrap(pExaScr, pScreen, CreateGC); + unwrap(pExaScr, pScreen, CloseScreen); + unwrap(pExaScr, pScreen, GetImage); + unwrap(pExaScr, pScreen, GetSpans); + if (pExaScr->SavedCreatePixmap) + unwrap(pExaScr, pScreen, CreatePixmap); + if (pExaScr->SavedDestroyPixmap) + unwrap(pExaScr, pScreen, DestroyPixmap); + if (pExaScr->SavedModifyPixmapHeader) + unwrap(pExaScr, pScreen, ModifyPixmapHeader); + unwrap(pExaScr, pScreen, CopyWindow); + unwrap(pExaScr, pScreen, ChangeWindowAttributes); + unwrap(pExaScr, pScreen, BitmapToRegion); + unwrap(pExaScr, pScreen, CreateScreenResources); + unwrap(pExaScr, ps, Composite); + if (pExaScr->SavedGlyphs) + unwrap(pExaScr, ps, Glyphs); + unwrap(pExaScr, ps, Trapezoids); + unwrap(pExaScr, ps, Triangles); + unwrap(pExaScr, ps, AddTraps); + + free(pExaScr); + + return (*pScreen->CloseScreen) (i, pScreen); +} + +/** + * This function allocates a driver structure for EXA drivers to fill in. By + * having EXA allocate the structure, the driver structure can be extended + * without breaking ABI between EXA and the drivers. The driver's + * responsibility is to check beforehand that the EXA module has a matching + * major number and sufficient minor. Drivers are responsible for freeing the + * driver structure using free(). + * + * @return a newly allocated, zero-filled driver structure + */ +ExaDriverPtr +exaDriverAlloc(void) +{ + return calloc(1, sizeof(ExaDriverRec)); +} + +/** + * @param pScreen screen being initialized + * @param pScreenInfo EXA driver record + * + * exaDriverInit sets up EXA given a driver record filled in by the driver. + * pScreenInfo should have been allocated by exaDriverAlloc(). See the + * comments in _ExaDriver for what must be filled in and what is optional. + * + * @return TRUE if EXA was successfully initialized. + */ +Bool +exaDriverInit (ScreenPtr pScreen, + ExaDriverPtr pScreenInfo) +{ + ExaScreenPrivPtr pExaScr; + PictureScreenPtr ps; + + if (!pScreenInfo) + return FALSE; + + if (pScreenInfo->exa_major != EXA_VERSION_MAJOR || + pScreenInfo->exa_minor > EXA_VERSION_MINOR) + { + LogMessage(X_ERROR, "EXA(%d): driver's EXA version requirements " + "(%d.%d) are incompatible with EXA version (%d.%d)\n", + pScreen->myNum, + pScreenInfo->exa_major, pScreenInfo->exa_minor, + EXA_VERSION_MAJOR, EXA_VERSION_MINOR); + return FALSE; + } + + if (!pScreenInfo->CreatePixmap && !pScreenInfo->CreatePixmap2) { + if (!pScreenInfo->memoryBase) { + LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::memoryBase " + "must be non-zero\n", pScreen->myNum); + return FALSE; + } + + if (!pScreenInfo->memorySize) { + LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::memorySize must be " + "non-zero\n", pScreen->myNum); + return FALSE; + } + + if (pScreenInfo->offScreenBase > pScreenInfo->memorySize) { + LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::offScreenBase must " + "be <= ExaDriverRec::memorySize\n", pScreen->myNum); + return FALSE; + } + } + + if (!pScreenInfo->PrepareSolid) { + LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::PrepareSolid must be " + "non-NULL\n", pScreen->myNum); + return FALSE; + } + + if (!pScreenInfo->PrepareCopy) { + LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::PrepareCopy must be " + "non-NULL\n", pScreen->myNum); + return FALSE; + } + + if (!pScreenInfo->WaitMarker) { + LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::WaitMarker must be " + "non-NULL\n", pScreen->myNum); + return FALSE; + } + + /* If the driver doesn't set any max pitch values, we'll just assume + * that there's a limitation by pixels, and that it's the same as + * maxX. + * + * We want maxPitchPixels or maxPitchBytes to be set so we can check + * pixmaps against the max pitch in exaCreatePixmap() -- it matters + * whether a pixmap is rejected because of its pitch or + * because of its width. + */ + if (!pScreenInfo->maxPitchPixels && !pScreenInfo->maxPitchBytes) + { + pScreenInfo->maxPitchPixels = pScreenInfo->maxX; + } + + ps = GetPictureScreenIfSet(pScreen); + + if (!dixRegisterPrivateKey(&exaScreenPrivateKeyRec, PRIVATE_SCREEN, 0)) { + LogMessage(X_WARNING, "EXA(%d): Failed to register screen private\n", + pScreen->myNum); + return FALSE; + } + + pExaScr = calloc (sizeof (ExaScreenPrivRec), 1); + if (!pExaScr) { + LogMessage(X_WARNING, "EXA(%d): Failed to allocate screen private\n", + pScreen->myNum); + return FALSE; + } + + pExaScr->info = pScreenInfo; + + dixSetPrivate(&pScreen->devPrivates, exaScreenPrivateKey, pExaScr); + + pExaScr->migration = ExaMigrationAlways; + + exaDDXDriverInit(pScreen); + + if (!dixRegisterPrivateKey(&exaGCPrivateKeyRec, PRIVATE_GC, sizeof(ExaGCPrivRec))) { + LogMessage(X_WARNING, + "EXA(%d): Failed to allocate GC private\n", + pScreen->myNum); + return FALSE; + } + + /* + * Replace various fb screen functions + */ + if ((pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) && + (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS) || + (pExaScr->info->flags & EXA_MIXED_PIXMAPS))) + wrap(pExaScr, pScreen, BlockHandler, ExaBlockHandler); + if ((pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) && + !(pExaScr->info->flags & EXA_HANDLES_PIXMAPS)) + wrap(pExaScr, pScreen, WakeupHandler, ExaWakeupHandler); + wrap(pExaScr, pScreen, CreateGC, exaCreateGC); + wrap(pExaScr, pScreen, CloseScreen, exaCloseScreen); + wrap(pExaScr, pScreen, GetImage, exaGetImage); + wrap(pExaScr, pScreen, GetSpans, ExaCheckGetSpans); + wrap(pExaScr, pScreen, CopyWindow, exaCopyWindow); + wrap(pExaScr, pScreen, ChangeWindowAttributes, exaChangeWindowAttributes); + wrap(pExaScr, pScreen, BitmapToRegion, exaBitmapToRegion); + wrap(pExaScr, pScreen, CreateScreenResources, exaCreateScreenResources); + + if (ps) { + wrap(pExaScr, ps, Composite, exaComposite); + if (pScreenInfo->PrepareComposite) { + wrap(pExaScr, ps, Glyphs, exaGlyphs); + } else { + wrap(pExaScr, ps, Glyphs, ExaCheckGlyphs); + } + wrap(pExaScr, ps, Trapezoids, exaTrapezoids); + wrap(pExaScr, ps, Triangles, exaTriangles); + wrap(pExaScr, ps, AddTraps, ExaCheckAddTraps); + } + +#ifdef MITSHM + /* + * Don't allow shared pixmaps. + */ + ShmRegisterFuncs(pScreen, &exaShmFuncs); +#endif + /* + * Hookup offscreen pixmaps + */ + if (pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) + { + if (!dixRegisterPrivateKey(&exaPixmapPrivateKeyRec, PRIVATE_PIXMAP, sizeof(ExaPixmapPrivRec))) { + LogMessage(X_WARNING, + "EXA(%d): Failed to allocate pixmap private\n", + pScreen->myNum); + return FALSE; + } + if (pExaScr->info->flags & EXA_HANDLES_PIXMAPS) { + if (pExaScr->info->flags & EXA_MIXED_PIXMAPS) { + wrap(pExaScr, pScreen, CreatePixmap, exaCreatePixmap_mixed); + wrap(pExaScr, pScreen, DestroyPixmap, exaDestroyPixmap_mixed); + wrap(pExaScr, pScreen, ModifyPixmapHeader, exaModifyPixmapHeader_mixed); + pExaScr->do_migration = exaDoMigration_mixed; + pExaScr->pixmap_has_gpu_copy = exaPixmapHasGpuCopy_mixed; + pExaScr->do_move_in_pixmap = exaMoveInPixmap_mixed; + pExaScr->do_move_out_pixmap = NULL; + pExaScr->prepare_access_reg = exaPrepareAccessReg_mixed; + } else { + wrap(pExaScr, pScreen, CreatePixmap, exaCreatePixmap_driver); + wrap(pExaScr, pScreen, DestroyPixmap, exaDestroyPixmap_driver); + wrap(pExaScr, pScreen, ModifyPixmapHeader, exaModifyPixmapHeader_driver); + pExaScr->do_migration = NULL; + pExaScr->pixmap_has_gpu_copy = exaPixmapHasGpuCopy_driver; + pExaScr->do_move_in_pixmap = NULL; + pExaScr->do_move_out_pixmap = NULL; + pExaScr->prepare_access_reg = NULL; + } + } else { + wrap(pExaScr, pScreen, CreatePixmap, exaCreatePixmap_classic); + wrap(pExaScr, pScreen, DestroyPixmap, exaDestroyPixmap_classic); + wrap(pExaScr, pScreen, ModifyPixmapHeader, exaModifyPixmapHeader_classic); + pExaScr->do_migration = exaDoMigration_classic; + pExaScr->pixmap_has_gpu_copy = exaPixmapHasGpuCopy_classic; + pExaScr->do_move_in_pixmap = exaMoveInPixmap_classic; + pExaScr->do_move_out_pixmap = exaMoveOutPixmap_classic; + pExaScr->prepare_access_reg = exaPrepareAccessReg_classic; + } + if (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS)) { + LogMessage(X_INFO, "EXA(%d): Offscreen pixmap area of %lu bytes\n", + pScreen->myNum, + pExaScr->info->memorySize - pExaScr->info->offScreenBase); + } else { + LogMessage(X_INFO, "EXA(%d): Driver allocated offscreen pixmaps\n", + pScreen->myNum); + + } + } + else + LogMessage(X_INFO, "EXA(%d): No offscreen pixmaps\n", pScreen->myNum); + + if (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS)) { + DBG_PIXMAP(("============== %ld < %ld\n", pExaScr->info->offScreenBase, + pExaScr->info->memorySize)); + if (pExaScr->info->offScreenBase < pExaScr->info->memorySize) { + if (!exaOffscreenInit (pScreen)) { + LogMessage(X_WARNING, "EXA(%d): Offscreen pixmap setup failed\n", + pScreen->myNum); + return FALSE; + } + } + } + + if (ps->Glyphs == exaGlyphs) + exaGlyphsInit(pScreen); + + LogMessage(X_INFO, "EXA(%d): Driver registered support for the following" + " operations:\n", pScreen->myNum); + assert(pScreenInfo->PrepareSolid != NULL); + LogMessage(X_INFO, " Solid\n"); + assert(pScreenInfo->PrepareCopy != NULL); + LogMessage(X_INFO, " Copy\n"); + if (pScreenInfo->PrepareComposite != NULL) { + LogMessage(X_INFO, " Composite (RENDER acceleration)\n"); + } + if (pScreenInfo->UploadToScreen != NULL) { + LogMessage(X_INFO, " UploadToScreen\n"); + } + if (pScreenInfo->DownloadFromScreen != NULL) { + LogMessage(X_INFO, " DownloadFromScreen\n"); + } + + return TRUE; +} + +/** + * exaDriverFini tears down EXA on a given screen. + * + * @param pScreen screen being torn down. + */ +void +exaDriverFini (ScreenPtr pScreen) +{ + /*right now does nothing*/ +} + +/** + * exaMarkSync() should be called after any asynchronous drawing by the hardware. + * + * @param pScreen screen which drawing occurred on + * + * exaMarkSync() sets a flag to indicate that some asynchronous drawing has + * happened and a WaitSync() will be necessary before relying on the contents of + * offscreen memory from the CPU's perspective. It also calls an optional + * driver MarkSync() callback, the return value of which may be used to do partial + * synchronization with the hardware in the future. + */ +void exaMarkSync(ScreenPtr pScreen) +{ + ExaScreenPriv(pScreen); + + pExaScr->info->needsSync = TRUE; + if (pExaScr->info->MarkSync != NULL) { + pExaScr->info->lastMarker = (*pExaScr->info->MarkSync)(pScreen); + } +} + +/** + * exaWaitSync() ensures that all drawing has been completed. + * + * @param pScreen screen being synchronized. + * + * Calls down into the driver to ensure that all previous drawing has completed. + * It should always be called before relying on the framebuffer contents + * reflecting previous drawing, from a CPU perspective. + */ +void exaWaitSync(ScreenPtr pScreen) +{ + ExaScreenPriv(pScreen); + + if (pExaScr->info->needsSync && !pExaScr->swappedOut) { + (*pExaScr->info->WaitMarker)(pScreen, pExaScr->info->lastMarker); + pExaScr->info->needsSync = FALSE; + } +} + +/** + * Performs migration of the pixmaps according to the operation information + * provided in pixmaps and can_accel and the migration scheme chosen in the + * config file. + */ +void +exaDoMigration (ExaMigrationPtr pixmaps, int npixmaps, Bool can_accel) +{ + ScreenPtr pScreen = pixmaps[0].pPix->drawable.pScreen; + ExaScreenPriv(pScreen); + + if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) + return; + + if (pExaScr->do_migration) + (*pExaScr->do_migration)(pixmaps, npixmaps, can_accel); +} + +void +exaMoveInPixmap (PixmapPtr pPixmap) +{ + ScreenPtr pScreen = pPixmap->drawable.pScreen; + ExaScreenPriv(pScreen); + + if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) + return; + + if (pExaScr->do_move_in_pixmap) + (*pExaScr->do_move_in_pixmap)(pPixmap); +} + +void +exaMoveOutPixmap (PixmapPtr pPixmap) +{ + ScreenPtr pScreen = pPixmap->drawable.pScreen; + ExaScreenPriv(pScreen); + + if (!(pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS)) + return; + + if (pExaScr->do_move_out_pixmap) + (*pExaScr->do_move_out_pixmap)(pPixmap); +} diff --git a/xorg-server/exa/exa_driver.c b/xorg-server/exa/exa_driver.c index 3849a7c01..b9903d1bc 100644 --- a/xorg-server/exa/exa_driver.c +++ b/xorg-server/exa/exa_driver.c @@ -1,224 +1,226 @@ -/* - * Copyright © 2009 Maarten Maathuis - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - * - */ - -#ifdef HAVE_DIX_CONFIG_H -#include -#endif - -#include - -#include "exa_priv.h" -#include "exa.h" - -/* This file holds the driver allocated pixmaps specific implementation. */ - -static _X_INLINE void* -ExaGetPixmapAddress(PixmapPtr p) -{ - ExaPixmapPriv(p); - - return pExaPixmap->sys_ptr; -} - -/** - * exaCreatePixmap() creates a new pixmap. - * - * Pixmaps are always marked as pinned, because exa has no control over them. - */ -PixmapPtr -exaCreatePixmap_driver(ScreenPtr pScreen, int w, int h, int depth, - unsigned usage_hint) -{ - PixmapPtr pPixmap; - ExaPixmapPrivPtr pExaPixmap; - int bpp; - size_t paddedWidth, datasize; - ExaScreenPriv(pScreen); - - if (w > 32767 || h > 32767) - return NullPixmap; - - swap(pExaScr, pScreen, CreatePixmap); - pPixmap = pScreen->CreatePixmap(pScreen, 0, 0, depth, usage_hint); - swap(pExaScr, pScreen, CreatePixmap); - - if (!pPixmap) - return NULL; - - pExaPixmap = ExaGetPixmapPriv(pPixmap); - pExaPixmap->driverPriv = NULL; - - bpp = pPixmap->drawable.bitsPerPixel; - - /* Set this before driver hooks, to allow for driver pixmaps without gpu - * memory to back it. These pixmaps have a valid pointer at all times. - */ - pPixmap->devPrivate.ptr = NULL; - - if (pExaScr->info->CreatePixmap2) { - int new_pitch = 0; - pExaPixmap->driverPriv = pExaScr->info->CreatePixmap2(pScreen, w, h, depth, usage_hint, bpp, &new_pitch); - paddedWidth = pExaPixmap->fb_pitch = new_pitch; - } - else { - paddedWidth = ((w * bpp + FB_MASK) >> FB_SHIFT) * sizeof(FbBits); - if (paddedWidth / 4 > 32767 || h > 32767) - return NullPixmap; - - exaSetFbPitch(pExaScr, pExaPixmap, w, h, bpp); - - if (paddedWidth < pExaPixmap->fb_pitch) - paddedWidth = pExaPixmap->fb_pitch; - datasize = h * paddedWidth; - pExaPixmap->driverPriv = pExaScr->info->CreatePixmap(pScreen, datasize, 0); - } - - if (!pExaPixmap->driverPriv) { - swap(pExaScr, pScreen, DestroyPixmap); - pScreen->DestroyPixmap (pPixmap); - swap(pExaScr, pScreen, DestroyPixmap); - return NULL; - } - - /* Allow ModifyPixmapHeader to set sys_ptr appropriately. */ - pExaPixmap->score = EXA_PIXMAP_SCORE_PINNED; - pExaPixmap->fb_ptr = NULL; - pExaPixmap->pDamage = NULL; - pExaPixmap->sys_ptr = NULL; - - (*pScreen->ModifyPixmapHeader)(pPixmap, w, h, 0, 0, - paddedWidth, NULL); - - pExaPixmap->area = NULL; - - exaSetAccelBlock(pExaScr, pExaPixmap, - w, h, bpp); - - /* During a fallback we must prepare access. */ - if (pExaScr->fallback_counter) - exaPrepareAccess(&pPixmap->drawable, EXA_PREPARE_AUX_DEST); - - return pPixmap; -} - -Bool -exaModifyPixmapHeader_driver(PixmapPtr pPixmap, int width, int height, int depth, - int bitsPerPixel, int devKind, pointer pPixData) -{ - ScreenPtr pScreen; - ExaScreenPrivPtr pExaScr; - ExaPixmapPrivPtr pExaPixmap; - Bool ret; - - if (!pPixmap) - return FALSE; - - pScreen = pPixmap->drawable.pScreen; - pExaScr = ExaGetScreenPriv(pScreen); - pExaPixmap = ExaGetPixmapPriv(pPixmap); - - if (pExaPixmap) { - if (pPixData) - pExaPixmap->sys_ptr = pPixData; - - if (devKind > 0) - pExaPixmap->sys_pitch = devKind; - - if (width > 0 && height > 0 && bitsPerPixel > 0) { - exaSetFbPitch(pExaScr, pExaPixmap, - width, height, bitsPerPixel); - - exaSetAccelBlock(pExaScr, pExaPixmap, - width, height, bitsPerPixel); - } - } - - if (pExaScr->info->ModifyPixmapHeader) { - ret = pExaScr->info->ModifyPixmapHeader(pPixmap, width, height, depth, - bitsPerPixel, devKind, pPixData); - /* For EXA_HANDLES_PIXMAPS, we set pPixData to NULL. - * If pPixmap->devPrivate.ptr is non-NULL, then we've got a - * !has_gpu_copy pixmap. We need to store the pointer, - * because PrepareAccess won't be called. - */ - if (!pPixData && pPixmap->devPrivate.ptr && pPixmap->devKind) { - pExaPixmap->sys_ptr = pPixmap->devPrivate.ptr; - pExaPixmap->sys_pitch = pPixmap->devKind; - } - if (ret == TRUE) - goto out; - } - - swap(pExaScr, pScreen, ModifyPixmapHeader); - ret = pScreen->ModifyPixmapHeader(pPixmap, width, height, depth, - bitsPerPixel, devKind, pPixData); - swap(pExaScr, pScreen, ModifyPixmapHeader); - -out: - /* Always NULL this, we don't want lingering pointers. */ - pPixmap->devPrivate.ptr = NULL; - - return ret; -} - -Bool -exaDestroyPixmap_driver (PixmapPtr pPixmap) -{ - ScreenPtr pScreen = pPixmap->drawable.pScreen; - ExaScreenPriv(pScreen); - Bool ret; - - if (pPixmap->refcnt == 1) - { - ExaPixmapPriv (pPixmap); - - exaDestroyPixmap(pPixmap); - - if (pExaPixmap->driverPriv) - pExaScr->info->DestroyPixmap(pScreen, pExaPixmap->driverPriv); - pExaPixmap->driverPriv = NULL; - } - - swap(pExaScr, pScreen, DestroyPixmap); - ret = pScreen->DestroyPixmap (pPixmap); - swap(pExaScr, pScreen, DestroyPixmap); - - return ret; -} - -Bool -exaPixmapHasGpuCopy_driver(PixmapPtr pPixmap) -{ - ScreenPtr pScreen = pPixmap->drawable.pScreen; - ExaScreenPriv(pScreen); - pointer saved_ptr; - Bool ret; - - saved_ptr = pPixmap->devPrivate.ptr; - pPixmap->devPrivate.ptr = ExaGetPixmapAddress(pPixmap); - ret = pExaScr->info->PixmapIsOffscreen(pPixmap); - pPixmap->devPrivate.ptr = saved_ptr; - - return ret; -} +/* + * Copyright © 2009 Maarten Maathuis + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + */ + +#ifdef HAVE_DIX_CONFIG_H +#include +#endif + +#include + +#include "exa_priv.h" +#include "exa.h" + +/* This file holds the driver allocated pixmaps specific implementation. */ + +static _X_INLINE void* +ExaGetPixmapAddress(PixmapPtr p) +{ + ExaPixmapPriv(p); + + return pExaPixmap->sys_ptr; +} + +/** + * exaCreatePixmap() creates a new pixmap. + * + * Pixmaps are always marked as pinned, because exa has no control over them. + */ +PixmapPtr +exaCreatePixmap_driver(ScreenPtr pScreen, int w, int h, int depth, + unsigned usage_hint) +{ + PixmapPtr pPixmap; + ExaPixmapPrivPtr pExaPixmap; + int bpp; + size_t paddedWidth, datasize; + ExaScreenPriv(pScreen); + + if (w > 32767 || h > 32767) + return NullPixmap; + + swap(pExaScr, pScreen, CreatePixmap); + pPixmap = pScreen->CreatePixmap(pScreen, 0, 0, depth, usage_hint); + swap(pExaScr, pScreen, CreatePixmap); + + if (!pPixmap) + return NULL; + + pExaPixmap = ExaGetPixmapPriv(pPixmap); + pExaPixmap->driverPriv = NULL; + + bpp = pPixmap->drawable.bitsPerPixel; + + /* Set this before driver hooks, to allow for driver pixmaps without gpu + * memory to back it. These pixmaps have a valid pointer at all times. + */ + pPixmap->devPrivate.ptr = NULL; + + if (pExaScr->info->CreatePixmap2) { + int new_pitch = 0; + pExaPixmap->driverPriv = pExaScr->info->CreatePixmap2(pScreen, w, h, depth, usage_hint, bpp, &new_pitch); + paddedWidth = pExaPixmap->fb_pitch = new_pitch; + } + else { + paddedWidth = ((w * bpp + FB_MASK) >> FB_SHIFT) * sizeof(FbBits); + if (paddedWidth / 4 > 32767 || h > 32767) + return NullPixmap; + + exaSetFbPitch(pExaScr, pExaPixmap, w, h, bpp); + + if (paddedWidth < pExaPixmap->fb_pitch) + paddedWidth = pExaPixmap->fb_pitch; + datasize = h * paddedWidth; + pExaPixmap->driverPriv = pExaScr->info->CreatePixmap(pScreen, datasize, 0); + } + + if (!pExaPixmap->driverPriv) { + swap(pExaScr, pScreen, DestroyPixmap); + pScreen->DestroyPixmap (pPixmap); + swap(pExaScr, pScreen, DestroyPixmap); + return NULL; + } + + /* Allow ModifyPixmapHeader to set sys_ptr appropriately. */ + pExaPixmap->score = EXA_PIXMAP_SCORE_PINNED; + pExaPixmap->fb_ptr = NULL; + pExaPixmap->pDamage = NULL; + pExaPixmap->sys_ptr = NULL; + + (*pScreen->ModifyPixmapHeader)(pPixmap, w, h, 0, 0, + paddedWidth, NULL); + + pExaPixmap->area = NULL; + + exaSetAccelBlock(pExaScr, pExaPixmap, + w, h, bpp); + + pExaPixmap->use_gpu_copy = exaPixmapHasGpuCopy(pPixmap); + + /* During a fallback we must prepare access. */ + if (pExaScr->fallback_counter) + exaPrepareAccess(&pPixmap->drawable, EXA_PREPARE_AUX_DEST); + + return pPixmap; +} + +Bool +exaModifyPixmapHeader_driver(PixmapPtr pPixmap, int width, int height, int depth, + int bitsPerPixel, int devKind, pointer pPixData) +{ + ScreenPtr pScreen; + ExaScreenPrivPtr pExaScr; + ExaPixmapPrivPtr pExaPixmap; + Bool ret; + + if (!pPixmap) + return FALSE; + + pScreen = pPixmap->drawable.pScreen; + pExaScr = ExaGetScreenPriv(pScreen); + pExaPixmap = ExaGetPixmapPriv(pPixmap); + + if (pExaPixmap) { + if (pPixData) + pExaPixmap->sys_ptr = pPixData; + + if (devKind > 0) + pExaPixmap->sys_pitch = devKind; + + if (width > 0 && height > 0 && bitsPerPixel > 0) { + exaSetFbPitch(pExaScr, pExaPixmap, + width, height, bitsPerPixel); + + exaSetAccelBlock(pExaScr, pExaPixmap, + width, height, bitsPerPixel); + } + } + + if (pExaScr->info->ModifyPixmapHeader) { + ret = pExaScr->info->ModifyPixmapHeader(pPixmap, width, height, depth, + bitsPerPixel, devKind, pPixData); + /* For EXA_HANDLES_PIXMAPS, we set pPixData to NULL. + * If pPixmap->devPrivate.ptr is non-NULL, then we've got a + * !has_gpu_copy pixmap. We need to store the pointer, + * because PrepareAccess won't be called. + */ + if (!pPixData && pPixmap->devPrivate.ptr && pPixmap->devKind) { + pExaPixmap->sys_ptr = pPixmap->devPrivate.ptr; + pExaPixmap->sys_pitch = pPixmap->devKind; + } + if (ret == TRUE) + goto out; + } + + swap(pExaScr, pScreen, ModifyPixmapHeader); + ret = pScreen->ModifyPixmapHeader(pPixmap, width, height, depth, + bitsPerPixel, devKind, pPixData); + swap(pExaScr, pScreen, ModifyPixmapHeader); + +out: + /* Always NULL this, we don't want lingering pointers. */ + pPixmap->devPrivate.ptr = NULL; + + return ret; +} + +Bool +exaDestroyPixmap_driver (PixmapPtr pPixmap) +{ + ScreenPtr pScreen = pPixmap->drawable.pScreen; + ExaScreenPriv(pScreen); + Bool ret; + + if (pPixmap->refcnt == 1) + { + ExaPixmapPriv (pPixmap); + + exaDestroyPixmap(pPixmap); + + if (pExaPixmap->driverPriv) + pExaScr->info->DestroyPixmap(pScreen, pExaPixmap->driverPriv); + pExaPixmap->driverPriv = NULL; + } + + swap(pExaScr, pScreen, DestroyPixmap); + ret = pScreen->DestroyPixmap (pPixmap); + swap(pExaScr, pScreen, DestroyPixmap); + + return ret; +} + +Bool +exaPixmapHasGpuCopy_driver(PixmapPtr pPixmap) +{ + ScreenPtr pScreen = pPixmap->drawable.pScreen; + ExaScreenPriv(pScreen); + pointer saved_ptr; + Bool ret; + + saved_ptr = pPixmap->devPrivate.ptr; + pPixmap->devPrivate.ptr = ExaGetPixmapAddress(pPixmap); + ret = pExaScr->info->PixmapIsOffscreen(pPixmap); + pPixmap->devPrivate.ptr = saved_ptr; + + return ret; +} diff --git a/xorg-server/exa/exa_migration_mixed.c b/xorg-server/exa/exa_migration_mixed.c index fb4715135..4f49905d3 100644 --- a/xorg-server/exa/exa_migration_mixed.c +++ b/xorg-server/exa/exa_migration_mixed.c @@ -138,6 +138,7 @@ void exaDamageReport_mixed(DamagePtr pDamage, RegionPtr pRegion, void *closure) { PixmapPtr pPixmap = closure; + ScreenPtr pScreen = pPixmap->drawable.pScreen; ExaPixmapPriv(pPixmap); /* Move back results of software rendering on system memory copy of mixed driver @@ -149,10 +150,18 @@ exaDamageReport_mixed(DamagePtr pDamage, RegionPtr pRegion, void *closure) if (!pExaPixmap->use_gpu_copy && exaPixmapHasGpuCopy(pPixmap)) { ExaScreenPriv(pPixmap->drawable.pScreen); - if (pExaScr->deferred_mixed_pixmap && - pExaScr->deferred_mixed_pixmap != pPixmap) - exaMoveInPixmap_mixed(pExaScr->deferred_mixed_pixmap); - pExaScr->deferred_mixed_pixmap = pPixmap; + /* Front buffer: Don't wait for the block handler to copy back the data. + * This avoids annoying latency if you encounter a lot of software rendering. + */ + if (pPixmap == pScreen->GetScreenPixmap(pScreen)) + exaMoveInPixmap_mixed(pPixmap); + else { + if (pExaScr->deferred_mixed_pixmap && + pExaScr->deferred_mixed_pixmap != pPixmap) + exaMoveInPixmap_mixed(pExaScr->deferred_mixed_pixmap); + + pExaScr->deferred_mixed_pixmap = pPixmap; + } } } diff --git a/xorg-server/hw/xfree86/common/xf86DGA.c b/xorg-server/hw/xfree86/common/xf86DGA.c index 9a99a339b..74eb739e4 100644 --- a/xorg-server/hw/xfree86/common/xf86DGA.c +++ b/xorg-server/hw/xfree86/common/xf86DGA.c @@ -1,1232 +1,1217 @@ -/* - * Copyright (c) 1998-2002 by The XFree86 Project, Inc. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR - * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, - * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR - * OTHER DEALINGS IN THE SOFTWARE. - * - * Except as contained in this notice, the name of the copyright holder(s) - * and author(s) shall not be used in advertising or otherwise to promote - * the sale, use or other dealings in this Software without prior written - * authorization from the copyright holder(s) and author(s). - * - * Written by Mark Vojkovich - */ - -#ifdef HAVE_XORG_CONFIG_H -#include -#endif - -#include "xf86.h" -#include "xf86str.h" -#include "xf86Priv.h" -#include "dgaproc.h" -#include -#include "colormapst.h" -#include "pixmapstr.h" -#include "inputstr.h" -#include "globals.h" -#include "servermd.h" -#include "micmap.h" -#include "xkbsrv.h" -#include "xf86Xinput.h" -#include "exglobals.h" -#include "exevents.h" -#include "eventstr.h" -#include "eventconvert.h" - -#include "mi.h" - -static DevPrivateKeyRec DGAScreenKeyRec; -#define DGAScreenKeyRegistered dixPrivateKeyRegistered(&DGAScreenKeyRec) -static int mieq_installed = 0; - -static Bool DGACloseScreen(int i, ScreenPtr pScreen); -static void DGADestroyColormap(ColormapPtr pmap); -static void DGAInstallColormap(ColormapPtr pmap); -static void DGAUninstallColormap(ColormapPtr pmap); -static void DGAHandleEvent(int screen_num, InternalEvent *event, - DeviceIntPtr device); - -static void -DGACopyModeInfo( - DGAModePtr mode, - XDGAModePtr xmode -); - -int *XDGAEventBase = NULL; - -#define DGA_GET_SCREEN_PRIV(pScreen) ((DGAScreenPtr) \ - dixLookupPrivate(&(pScreen)->devPrivates, &DGAScreenKeyRec)) - - -typedef struct _FakedVisualList{ - Bool free; - VisualPtr pVisual; - struct _FakedVisualList *next; -} FakedVisualList; - - -typedef struct { - ScrnInfoPtr pScrn; - int numModes; - DGAModePtr modes; - CloseScreenProcPtr CloseScreen; - DestroyColormapProcPtr DestroyColormap; - InstallColormapProcPtr InstallColormap; - UninstallColormapProcPtr UninstallColormap; - DGADevicePtr current; - DGAFunctionPtr funcs; - int input; - ClientPtr client; - int pixmapMode; - FakedVisualList *fakedVisuals; - ColormapPtr dgaColormap; - ColormapPtr savedColormap; - Bool grabMouse; - Bool grabKeyboard; -} DGAScreenRec, *DGAScreenPtr; - -Bool -DGAInit( - ScreenPtr pScreen, - DGAFunctionPtr funcs, - DGAModePtr modes, - int num -){ - ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum]; - DGAScreenPtr pScreenPriv; - int i; - - if(!funcs || !funcs->SetMode || !funcs->OpenFramebuffer) - return FALSE; - - if(!modes || num <= 0) - return FALSE; - - if (!dixRegisterPrivateKey(&DGAScreenKeyRec, PRIVATE_SCREEN, 0)) - return FALSE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - if (!pScreenPriv) - { - if(!(pScreenPriv = (DGAScreenPtr)malloc(sizeof(DGAScreenRec)))) - return FALSE; - dixSetPrivate(&pScreen->devPrivates, &DGAScreenKeyRec, pScreenPriv); - pScreenPriv->CloseScreen = pScreen->CloseScreen; - pScreen->CloseScreen = DGACloseScreen; - pScreenPriv->DestroyColormap = pScreen->DestroyColormap; - pScreen->DestroyColormap = DGADestroyColormap; - pScreenPriv->InstallColormap = pScreen->InstallColormap; - pScreen->InstallColormap = DGAInstallColormap; - pScreenPriv->UninstallColormap = pScreen->UninstallColormap; - pScreen->UninstallColormap = DGAUninstallColormap; - } - - pScreenPriv->pScrn = pScrn; - pScreenPriv->numModes = num; - pScreenPriv->modes = modes; - pScreenPriv->current = NULL; - - pScreenPriv->funcs = funcs; - pScreenPriv->input = 0; - pScreenPriv->client = NULL; - pScreenPriv->fakedVisuals = NULL; - pScreenPriv->dgaColormap = NULL; - pScreenPriv->savedColormap = NULL; - pScreenPriv->grabMouse = FALSE; - pScreenPriv->grabKeyboard = FALSE; - - for(i = 0; i < num; i++) - modes[i].num = i + 1; - -#ifdef PANORAMIX - if(!noPanoramiXExtension) - for(i = 0; i < num; i++) - modes[i].flags &= ~DGA_PIXMAP_AVAILABLE; -#endif - - return TRUE; -} - -/* DGAReInitModes allows the driver to re-initialize - * the DGA mode list. - */ - -Bool -DGAReInitModes( - ScreenPtr pScreen, - DGAModePtr modes, - int num -){ - DGAScreenPtr pScreenPriv; - int i; - - /* No DGA? Ignore call (but don't make it look like it failed) */ - if(!DGAScreenKeyRegistered) - return TRUE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - /* Same as above */ - if(!pScreenPriv) - return TRUE; - - /* Can't do this while DGA is active */ - if(pScreenPriv->current) - return FALSE; - - /* Quick sanity check */ - if(!num) - modes = NULL; - else if(!modes) - num = 0; - - pScreenPriv->numModes = num; - pScreenPriv->modes = modes; - - /* This practically disables DGA. So be it. */ - if(!num) - return TRUE; - - for(i = 0; i < num; i++) - modes[i].num = i + 1; - -#ifdef PANORAMIX - if(!noPanoramiXExtension) - for(i = 0; i < num; i++) - modes[i].flags &= ~DGA_PIXMAP_AVAILABLE; -#endif - - return TRUE; -} - -static void -FreeMarkedVisuals(ScreenPtr pScreen) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - FakedVisualList *prev, *curr, *tmp; - - if(!pScreenPriv->fakedVisuals) - return; - - prev = NULL; - curr = pScreenPriv->fakedVisuals; - - while(curr) { - if(curr->free) { - tmp = curr; - curr = curr->next; - if(prev) - prev->next = curr; - else - pScreenPriv->fakedVisuals = curr; - free(tmp->pVisual); - free(tmp); - } else { - prev = curr; - curr = curr->next; - } - } -} - -static Bool -DGACloseScreen(int i, ScreenPtr pScreen) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - if (XDGAEventBase) { - mieqSetHandler(ET_DGAEvent, NULL); - } - - FreeMarkedVisuals(pScreen); - - pScreen->CloseScreen = pScreenPriv->CloseScreen; - pScreen->DestroyColormap = pScreenPriv->DestroyColormap; - pScreen->InstallColormap = pScreenPriv->InstallColormap; - pScreen->UninstallColormap = pScreenPriv->UninstallColormap; - - /* DGAShutdown() should have ensured that no DGA - screen were active by here */ - - free(pScreenPriv); - - return((*pScreen->CloseScreen)(i, pScreen)); -} - - -static void -DGADestroyColormap(ColormapPtr pmap) -{ - ScreenPtr pScreen = pmap->pScreen; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - VisualPtr pVisual = pmap->pVisual; - - if(pScreenPriv->fakedVisuals) { - FakedVisualList *curr = pScreenPriv->fakedVisuals; - - while(curr) { - if(curr->pVisual == pVisual) { - /* We can't get rid of them yet since FreeColormap - still needs the pVisual during the cleanup */ - curr->free = TRUE; - break; - } - curr = curr->next; - } - } - - if(pScreenPriv->DestroyColormap) { - pScreen->DestroyColormap = pScreenPriv->DestroyColormap; - (*pScreen->DestroyColormap)(pmap); - pScreen->DestroyColormap = DGADestroyColormap; - } -} - - -static void -DGAInstallColormap(ColormapPtr pmap) -{ - ScreenPtr pScreen = pmap->pScreen; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - if(pScreenPriv->current && pScreenPriv->dgaColormap) { - if (pmap != pScreenPriv->dgaColormap) { - pScreenPriv->savedColormap = pmap; - pmap = pScreenPriv->dgaColormap; - } - } - - pScreen->InstallColormap = pScreenPriv->InstallColormap; - (*pScreen->InstallColormap)(pmap); - pScreen->InstallColormap = DGAInstallColormap; -} - -static void -DGAUninstallColormap(ColormapPtr pmap) -{ - ScreenPtr pScreen = pmap->pScreen; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - if(pScreenPriv->current && pScreenPriv->dgaColormap) { - if (pmap == pScreenPriv->dgaColormap) { - pScreenPriv->dgaColormap = NULL; - } - } - - pScreen->UninstallColormap = pScreenPriv->UninstallColormap; - (*pScreen->UninstallColormap)(pmap); - pScreen->UninstallColormap = DGAUninstallColormap; -} - -int -xf86SetDGAMode( - int index, - int num, - DGADevicePtr devRet -){ - ScreenPtr pScreen = screenInfo.screens[index]; - DGAScreenPtr pScreenPriv; - ScrnInfoPtr pScrn; - DGADevicePtr device; - PixmapPtr pPix = NULL; - DGAModePtr pMode = NULL; - - /* First check if DGAInit was successful on this screen */ - if (!DGAScreenKeyRegistered) - return BadValue; - pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - if (!pScreenPriv) - return BadValue; - pScrn = pScreenPriv->pScrn; - - if(!num) { - if(pScreenPriv->current) { - PixmapPtr oldPix = pScreenPriv->current->pPix; - if(oldPix) { - if(oldPix->drawable.id) - FreeResource(oldPix->drawable.id, RT_NONE); - else - (*pScreen->DestroyPixmap)(oldPix); - } - free(pScreenPriv->current); - pScreenPriv->current = NULL; - pScrn->vtSema = TRUE; - (*pScreenPriv->funcs->SetMode)(pScrn, NULL); - if(pScreenPriv->savedColormap) { - (*pScreen->InstallColormap)(pScreenPriv->savedColormap); - pScreenPriv->savedColormap = NULL; - } - pScreenPriv->dgaColormap = NULL; - (*pScrn->EnableDisableFBAccess)(index, TRUE); - - FreeMarkedVisuals(pScreen); - } - - pScreenPriv->grabMouse = FALSE; - pScreenPriv->grabKeyboard = FALSE; - - return Success; - } - - if(!pScrn->vtSema && !pScreenPriv->current) /* Really switched away */ - return BadAlloc; - - if((num > 0) && (num <= pScreenPriv->numModes)) - pMode = &(pScreenPriv->modes[num - 1]); - else - return BadValue; - - if(!(device = (DGADevicePtr)malloc(sizeof(DGADeviceRec)))) - return BadAlloc; - - if(!pScreenPriv->current) { - Bool oldVTSema = pScrn->vtSema; - - pScrn->vtSema = FALSE; /* kludge until we rewrite VT switching */ - (*pScrn->EnableDisableFBAccess)(index, FALSE); - pScrn->vtSema = oldVTSema; - } - - if(!(*pScreenPriv->funcs->SetMode)(pScrn, pMode)) { - free(device); - return BadAlloc; - } - - pScrn->currentMode = pMode->mode; - - if(!pScreenPriv->current && !pScreenPriv->input) { - /* if it's multihead we need to warp the cursor off of - our screen so it doesn't get trapped */ - } - - pScrn->vtSema = FALSE; - - if(pScreenPriv->current) { - PixmapPtr oldPix = pScreenPriv->current->pPix; - if(oldPix) { - if(oldPix->drawable.id) - FreeResource(oldPix->drawable.id, RT_NONE); - else - (*pScreen->DestroyPixmap)(oldPix); - } - free(pScreenPriv->current); - pScreenPriv->current = NULL; - } - - if(pMode->flags & DGA_PIXMAP_AVAILABLE) { - if((pPix = (*pScreen->CreatePixmap)(pScreen, 0, 0, pMode->depth, 0))) { - (*pScreen->ModifyPixmapHeader)(pPix, - pMode->pixmapWidth, pMode->pixmapHeight, - pMode->depth, pMode->bitsPerPixel, - pMode->bytesPerScanline, - (pointer)(pMode->address)); - } - } - - devRet->mode = device->mode = pMode; - devRet->pPix = device->pPix = pPix; - pScreenPriv->current = device; - pScreenPriv->pixmapMode = FALSE; - pScreenPriv->grabMouse = TRUE; - pScreenPriv->grabKeyboard = TRUE; - - return Success; -} - - - -/*********** exported ones ***************/ - -void -DGASetInputMode(int index, Bool keyboard, Bool mouse) -{ - ScreenPtr pScreen = screenInfo.screens[index]; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - if (pScreenPriv) - { - pScreenPriv->grabMouse = mouse; - pScreenPriv->grabKeyboard = keyboard; - - if (!mieq_installed) { - mieqSetHandler(ET_DGAEvent, DGAHandleEvent); - mieq_installed = 1; - } - } -} - -Bool -DGAChangePixmapMode(int index, int *x, int *y, int mode) -{ - DGAScreenPtr pScreenPriv; - DGADevicePtr pDev; - DGAModePtr pMode; - PixmapPtr pPix; - - if(!DGAScreenKeyRegistered) - return FALSE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - if(!pScreenPriv || !pScreenPriv->current || !pScreenPriv->current->pPix) - return FALSE; - - pDev = pScreenPriv->current; - pPix = pDev->pPix; - pMode = pDev->mode; - - if(mode) { - int shift = 2; - - if(*x > (pMode->pixmapWidth - pMode->viewportWidth)) - *x = pMode->pixmapWidth - pMode->viewportWidth; - if(*y > (pMode->pixmapHeight - pMode->viewportHeight)) - *y = pMode->pixmapHeight - pMode->viewportHeight; - - switch(xf86Screens[index]->bitsPerPixel) { - case 16: shift = 1; break; - case 32: shift = 0; break; - default: break; - } - - if(BITMAP_SCANLINE_PAD == 64) - shift++; - - *x = (*x >> shift) << shift; - - pPix->drawable.x = *x; - pPix->drawable.y = *y; - pPix->drawable.width = pMode->viewportWidth; - pPix->drawable.height = pMode->viewportHeight; - } else { - pPix->drawable.x = 0; - pPix->drawable.y = 0; - pPix->drawable.width = pMode->pixmapWidth; - pPix->drawable.height = pMode->pixmapHeight; - } - pPix->drawable.serialNumber = NEXT_SERIAL_NUMBER; - pScreenPriv->pixmapMode = mode; - - return TRUE; -} - -Bool -DGAAvailable(int index) -{ - if(!DGAScreenKeyRegistered) - return FALSE; - - if(DGA_GET_SCREEN_PRIV(screenInfo.screens[index])) - return TRUE; - - return FALSE; -} - -Bool -DGAActive(int index) -{ - DGAScreenPtr pScreenPriv; - - if(!DGAScreenKeyRegistered) - return FALSE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - if(pScreenPriv && pScreenPriv->current) - return TRUE; - - return FALSE; -} - - - -/* Called by the event code in case the server is abruptly terminated */ - -void -DGAShutdown(void) -{ - ScrnInfoPtr pScrn; - int i; - - if(!DGAScreenKeyRegistered) - return; - - for(i = 0; i < screenInfo.numScreens; i++) { - pScrn = xf86Screens[i]; - - (void)(*pScrn->SetDGAMode)(pScrn->scrnIndex, 0, NULL); - } -} - -/* Called by the extension to initialize a mode */ - -int -DGASetMode( - int index, - int num, - XDGAModePtr mode, - PixmapPtr *pPix -){ - ScrnInfoPtr pScrn = xf86Screens[index]; - DGADeviceRec device; - int ret; - - /* We rely on the extension to check that DGA is available */ - - ret = (*pScrn->SetDGAMode)(index, num, &device); - if((ret == Success) && num) { - DGACopyModeInfo(device.mode, mode); - *pPix = device.pPix; - } - - return ret; -} - -/* Called from the extension to let the DDX know which events are requested */ - -void -DGASelectInput( - int index, - ClientPtr client, - long mask -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is available */ - pScreenPriv->client = client; - pScreenPriv->input = mask; -} - -int -DGAGetViewportStatus(int index) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is active */ - - if (!pScreenPriv->funcs->GetViewport) - return 0; - - return (*pScreenPriv->funcs->GetViewport)(pScreenPriv->pScrn); -} - -int -DGASetViewport( - int index, - int x, int y, - int mode -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - if (pScreenPriv->funcs->SetViewport) - (*pScreenPriv->funcs->SetViewport)(pScreenPriv->pScrn, x, y, mode); - return Success; -} - - -static int -BitsClear(CARD32 data) -{ - int bits = 0; - CARD32 mask; - - for(mask = 1; mask; mask <<= 1) { - if(!(data & mask)) bits++; - else break; - } - - return bits; -} - -int -DGACreateColormap(int index, ClientPtr client, int id, int mode, int alloc) -{ - ScreenPtr pScreen = screenInfo.screens[index]; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - FakedVisualList *fvlp; - VisualPtr pVisual; - DGAModePtr pMode; - ColormapPtr pmap; - - if(!mode || (mode > pScreenPriv->numModes)) - return BadValue; - - if((alloc != AllocNone) && (alloc != AllocAll)) - return BadValue; - - pMode = &(pScreenPriv->modes[mode - 1]); - - if(!(pVisual = malloc(sizeof(VisualRec)))) - return BadAlloc; - - pVisual->vid = FakeClientID(0); - pVisual->class = pMode->visualClass; - pVisual->nplanes = pMode->depth; - pVisual->ColormapEntries = 1 << pMode->depth; - pVisual->bitsPerRGBValue = (pMode->depth + 2) / 3; - - switch (pVisual->class) { - case PseudoColor: - case GrayScale: - case StaticGray: - pVisual->bitsPerRGBValue = 8; /* not quite */ - pVisual->redMask = 0; - pVisual->greenMask = 0; - pVisual->blueMask = 0; - pVisual->offsetRed = 0; - pVisual->offsetGreen = 0; - pVisual->offsetBlue = 0; - break; - case DirectColor: - case TrueColor: - pVisual->ColormapEntries = 1 << pVisual->bitsPerRGBValue; - /* fall through */ - case StaticColor: - pVisual->redMask = pMode->red_mask; - pVisual->greenMask = pMode->green_mask; - pVisual->blueMask = pMode->blue_mask; - pVisual->offsetRed = BitsClear(pVisual->redMask); - pVisual->offsetGreen = BitsClear(pVisual->greenMask); - pVisual->offsetBlue = BitsClear(pVisual->blueMask); - } - - if(!(fvlp = malloc(sizeof(FakedVisualList)))) { - free(pVisual); - return BadAlloc; - } - - fvlp->free = FALSE; - fvlp->pVisual = pVisual; - fvlp->next = pScreenPriv->fakedVisuals; - pScreenPriv->fakedVisuals = fvlp; - - LEGAL_NEW_RESOURCE(id, client); - - return CreateColormap(id, pScreen, pVisual, &pmap, alloc, client->index); -} - -/* Called by the extension to install a colormap on DGA active screens */ - -void -DGAInstallCmap(ColormapPtr cmap) -{ - ScreenPtr pScreen = cmap->pScreen; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - /* We rely on the extension to check that DGA is active */ - - if(!pScreenPriv->dgaColormap) - pScreenPriv->savedColormap = GetInstalledmiColormap(pScreen); - - pScreenPriv->dgaColormap = cmap; - - (*pScreen->InstallColormap)(cmap); -} - -int -DGASync(int index) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is active */ - - if (pScreenPriv->funcs->Sync) - (*pScreenPriv->funcs->Sync)(pScreenPriv->pScrn); - - return Success; -} - -int -DGAFillRect( - int index, - int x, int y, int w, int h, - unsigned long color -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is active */ - - if(pScreenPriv->funcs->FillRect && - (pScreenPriv->current->mode->flags & DGA_FILL_RECT)) { - - (*pScreenPriv->funcs->FillRect)(pScreenPriv->pScrn, x, y, w, h, color); - return Success; - } - return BadMatch; -} - -int -DGABlitRect( - int index, - int srcx, int srcy, - int w, int h, - int dstx, int dsty -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is active */ - - if(pScreenPriv->funcs->BlitRect && - (pScreenPriv->current->mode->flags & DGA_BLIT_RECT)) { - - (*pScreenPriv->funcs->BlitRect)(pScreenPriv->pScrn, - srcx, srcy, w, h, dstx, dsty); - return Success; - } - return BadMatch; -} - -int -DGABlitTransRect( - int index, - int srcx, int srcy, - int w, int h, - int dstx, int dsty, - unsigned long color -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is active */ - - if(pScreenPriv->funcs->BlitTransRect && - (pScreenPriv->current->mode->flags & DGA_BLIT_RECT_TRANS)) { - - (*pScreenPriv->funcs->BlitTransRect)(pScreenPriv->pScrn, - srcx, srcy, w, h, dstx, dsty, color); - return Success; - } - return BadMatch; -} - - -int -DGAGetModes(int index) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - /* We rely on the extension to check that DGA is available */ - - return pScreenPriv->numModes; -} - - -int -DGAGetModeInfo( - int index, - XDGAModePtr mode, - int num -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - /* We rely on the extension to check that DGA is available */ - - if((num <= 0) || (num > pScreenPriv->numModes)) - return BadValue; - - DGACopyModeInfo(&(pScreenPriv->modes[num - 1]), mode); - - return Success; -} - - -static void -DGACopyModeInfo( - DGAModePtr mode, - XDGAModePtr xmode -){ - DisplayModePtr dmode = mode->mode; - - xmode->num = mode->num; - xmode->name = dmode->name; - xmode->VSync_num = (int)(dmode->VRefresh * 1000.0); - xmode->VSync_den = 1000; - xmode->flags = mode->flags; - xmode->imageWidth = mode->imageWidth; - xmode->imageHeight = mode->imageHeight; - xmode->pixmapWidth = mode->pixmapWidth; - xmode->pixmapHeight = mode->pixmapHeight; - xmode->bytesPerScanline = mode->bytesPerScanline; - xmode->byteOrder = mode->byteOrder; - xmode->depth = mode->depth; - xmode->bitsPerPixel = mode->bitsPerPixel; - xmode->red_mask = mode->red_mask; - xmode->green_mask = mode->green_mask; - xmode->blue_mask = mode->blue_mask; - xmode->visualClass = mode->visualClass; - xmode->viewportWidth = mode->viewportWidth; - xmode->viewportHeight = mode->viewportHeight; - xmode->xViewportStep = mode->xViewportStep; - xmode->yViewportStep = mode->yViewportStep; - xmode->maxViewportX = mode->maxViewportX; - xmode->maxViewportY = mode->maxViewportY; - xmode->viewportFlags = mode->viewportFlags; - xmode->reserved1 = mode->reserved1; - xmode->reserved2 = mode->reserved2; - xmode->offset = mode->offset; - - if(dmode->Flags & V_INTERLACE) xmode->flags |= DGA_INTERLACED; - if(dmode->Flags & V_DBLSCAN) xmode->flags |= DGA_DOUBLESCAN; -} - - -Bool -DGAVTSwitch(void) -{ - ScreenPtr pScreen; - int i; - - for(i = 0; i < screenInfo.numScreens; i++) { - pScreen = screenInfo.screens[i]; - - /* Alternatively, this could send events to DGA clients */ - - if(DGAScreenKeyRegistered) { - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - if(pScreenPriv && pScreenPriv->current) - return FALSE; - } - } - - return TRUE; -} - -Bool -DGAStealKeyEvent(DeviceIntPtr dev, int index, int key_code, int is_down) -{ - DGAScreenPtr pScreenPriv; - DGAEvent event; - - if(!DGAScreenKeyRegistered) /* no DGA */ - return FALSE; - - if (key_code < 8 || key_code > 255) - return FALSE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - if(!pScreenPriv || !pScreenPriv->grabKeyboard) /* no direct mode */ - return FALSE; - - memset(&event, 0, sizeof(event)); - event.header = ET_Internal; - event.type = ET_DGAEvent; - event.length = sizeof(event); - event.time = GetTimeInMillis(); - event.subtype = (is_down ? ET_KeyPress : ET_KeyRelease); - event.detail = key_code; - event.dx = 0; - event.dy = 0; - mieqEnqueue (dev, (InternalEvent*)&event); - - return TRUE; -} - -static int DGAMouseX, DGAMouseY; - -Bool -DGAStealMotionEvent(DeviceIntPtr dev, int index, int dx, int dy) -{ - DGAScreenPtr pScreenPriv; - DGAEvent event; - - if(!DGAScreenKeyRegistered) /* no DGA */ - return FALSE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - if(!pScreenPriv || !pScreenPriv->grabMouse) /* no direct mode */ - return FALSE; - - DGAMouseX += dx; - if (DGAMouseX < 0) - DGAMouseX = 0; - else if (DGAMouseX > screenInfo.screens[index]->width) - DGAMouseX = screenInfo.screens[index]->width; - DGAMouseY += dy; - if (DGAMouseY < 0) - DGAMouseY = 0; - else if (DGAMouseY > screenInfo.screens[index]->height) - DGAMouseY = screenInfo.screens[index]->height; - - memset(&event, 0, sizeof(event)); - event.header = ET_Internal; - event.type = ET_DGAEvent; - event.length = sizeof(event); - event.time = GetTimeInMillis(); - event.subtype = ET_Motion; - event.detail = 0; - event.dx = dx; - event.dy = dy; - mieqEnqueue (dev, (InternalEvent*)&event); - return TRUE; -} - -Bool -DGAStealButtonEvent(DeviceIntPtr dev, int index, int button, int is_down) -{ - DGAScreenPtr pScreenPriv; - DGAEvent event; - - if(!DGAScreenKeyRegistered) /* no DGA */ - return FALSE; - - pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - if (!pScreenPriv || !pScreenPriv->grabMouse) - return FALSE; - - memset(&event, 0, sizeof(event)); - event.header = ET_Internal; - event.type = ET_DGAEvent; - event.length = sizeof(event); - event.time = GetTimeInMillis(); - event.subtype = (is_down ? ET_ButtonPress : ET_ButtonRelease); - event.detail = button; - event.dx = 0; - event.dy = 0; - mieqEnqueue (dev, (InternalEvent*)&event); - - return TRUE; -} - -/* We have the power to steal or modify events that are about to get queued */ - -Bool -DGAIsDgaEvent (xEvent *e) -{ - int coreEquiv; - if (!DGAScreenKeyRegistered || XDGAEventBase == 0) - return FALSE; - coreEquiv = e->u.u.type - *XDGAEventBase; - if (KeyPress <= coreEquiv && coreEquiv <= MotionNotify) - return TRUE; - return FALSE; -} - -#define NoSuchEvent 0x80000000 /* so doesn't match NoEventMask */ -static Mask filters[] = -{ - NoSuchEvent, /* 0 */ - NoSuchEvent, /* 1 */ - KeyPressMask, /* KeyPress */ - KeyReleaseMask, /* KeyRelease */ - ButtonPressMask, /* ButtonPress */ - ButtonReleaseMask, /* ButtonRelease */ - PointerMotionMask, /* MotionNotify (initial state) */ -}; - -static void -DGAProcessKeyboardEvent (ScreenPtr pScreen, DGAEvent *event, DeviceIntPtr keybd) -{ - KeyClassPtr keyc = keybd->key; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - DeviceIntPtr pointer = GetPairedDevice(keybd); - DeviceEvent ev; - - memset(&ev, 0, sizeof(ev)); - ev.length = sizeof(ev); - ev.detail.key = event->detail; - ev.type = event->subtype; - ev.root_x = 0; - ev.root_y = 0; - ev.corestate = XkbStateFieldFromRec(&keyc->xkbInfo->state); - ev.corestate |= pointer->button->state; - - UpdateDeviceState(keybd, &ev); - - /* - * Deliver the DGA event - */ - if (pScreenPriv->client) - { - dgaEvent de; - de.u.u.type = *XDGAEventBase + GetCoreType((InternalEvent*)&ev); - de.u.u.detail = event->detail; - de.u.event.time = event->time; - de.u.event.dx = 0; - de.u.event.dy = 0; - de.u.event.screen = pScreen->myNum; - de.u.event.state = ev.corestate; - - /* If the DGA client has selected input, then deliver based on the usual filter */ - TryClientEvents (pScreenPriv->client, keybd, (xEvent *)&de, 1, - filters[ev.type], pScreenPriv->input, 0); - } - else - { - /* If the keyboard is actively grabbed, deliver a grabbed core event */ - if (keybd->deviceGrab.grab && !keybd->deviceGrab.fromPassiveGrab) - { - ev.detail.key = event->detail; - ev.time = event->time; - ev.root_x = event->dx; - ev.root_y = event->dy; - ev.corestate = event->state; - ev.deviceid = keybd->id; - DeliverGrabbedEvent ((InternalEvent*)&ev, keybd, FALSE); - } - } -} - -static void -DGAProcessPointerEvent (ScreenPtr pScreen, DGAEvent *event, DeviceIntPtr mouse) -{ - ButtonClassPtr butc = mouse->button; - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - DeviceEvent ev; - DeviceIntPtr master = GetMaster(mouse, MASTER_KEYBOARD); - - memset(&ev, 0, sizeof(ev)); - ev.header = ET_Internal; - ev.length = sizeof(ev); - ev.type = event->subtype; - ev.corestate = butc ? butc->state : 0; - if (master && master->key) - ev.corestate |= XkbStateFieldFromRec(&master->key->xkbInfo->state); - - UpdateDeviceState(mouse, &ev); - - /* - * Deliver the DGA event - */ - if (pScreenPriv->client) - { - dgaEvent de; - int coreEquiv; - - coreEquiv = GetCoreType((InternalEvent*)&ev); - - de.u.u.type = *XDGAEventBase + coreEquiv; - de.u.u.detail = event->detail; - de.u.event.time = event->time; - de.u.event.dx = 0; - de.u.event.dy = 0; - de.u.event.screen = pScreen->myNum; - de.u.event.state = ev.corestate; - - /* If the DGA client has selected input, then deliver based on the usual filter */ - TryClientEvents (pScreenPriv->client, mouse, (xEvent *)&de, 1, - filters[coreEquiv], pScreenPriv->input, 0); - } - else - { - /* If the pointer is actively grabbed, deliver a grabbed core event */ - if (mouse->deviceGrab.grab && !mouse->deviceGrab.fromPassiveGrab) - { - ev.detail.button = event->detail; - ev.time = event->time; - ev.root_x = event->dx; - ev.root_y = event->dy; - ev.corestate = event->state; - /* DGA is core only, so valuators.data doesn't actually matter. - * Mask must be set for EventToCore to create motion events. */ - SetBit(ev.valuators.mask, 0); - SetBit(ev.valuators.mask, 1); - DeliverGrabbedEvent ((InternalEvent*)&ev, mouse, FALSE); - } - } -} - -Bool -DGAOpenFramebuffer( - int index, - char **name, - unsigned char **mem, - int *size, - int *offset, - int *flags -){ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is available */ - - return (*pScreenPriv->funcs->OpenFramebuffer)(pScreenPriv->pScrn, - name, mem, size, offset, flags); -} - -void -DGACloseFramebuffer(int index) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - - /* We rely on the extension to check that DGA is available */ - if(pScreenPriv->funcs->CloseFramebuffer) - (*pScreenPriv->funcs->CloseFramebuffer)(pScreenPriv->pScrn); -} - -/* For DGA 1.0 backwards compatibility only */ - -int -DGAGetOldDGAMode(int index) -{ - DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); - ScrnInfoPtr pScrn = pScreenPriv->pScrn; - DGAModePtr mode; - int i, w, h, p; - - /* We rely on the extension to check that DGA is available */ - - w = pScrn->currentMode->HDisplay; - h = pScrn->currentMode->VDisplay; - p = pad_to_int32(pScrn->displayWidth * bits_to_bytes(pScrn->bitsPerPixel)); - - for(i = 0; i < pScreenPriv->numModes; i++) { - mode = &(pScreenPriv->modes[i]); - - if((mode->viewportWidth == w) && (mode->viewportHeight == h) && - (mode->bytesPerScanline == p) && - (mode->bitsPerPixel == pScrn->bitsPerPixel) && - (mode->depth == pScrn->depth)) { - - return mode->num; - } - } - - return 0; -} - -static void -DGAHandleEvent(int screen_num, InternalEvent *ev, DeviceIntPtr device) -{ - DGAEvent *event= &ev->dga_event; - ScreenPtr pScreen = screenInfo.screens[screen_num]; - DGAScreenPtr pScreenPriv; - - /* no DGA */ - if (!DGAScreenKeyRegistered || XDGAEventBase == 0) - return; - pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); - - /* DGA not initialized on this screen */ - if (!pScreenPriv) - return; - - switch (event->subtype) { - case KeyPress: - case KeyRelease: - DGAProcessKeyboardEvent (pScreen, event, device); - break; - case MotionNotify: - case ButtonPress: - case ButtonRelease: - DGAProcessPointerEvent (pScreen, event, device); - break; - default: - break; - } -} +/* + * Copyright (c) 1998-2002 by The XFree86 Project, Inc. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR + * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, + * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR + * OTHER DEALINGS IN THE SOFTWARE. + * + * Except as contained in this notice, the name of the copyright holder(s) + * and author(s) shall not be used in advertising or otherwise to promote + * the sale, use or other dealings in this Software without prior written + * authorization from the copyright holder(s) and author(s). + * + * Written by Mark Vojkovich + */ + +#ifdef HAVE_XORG_CONFIG_H +#include +#endif + +#include "xf86.h" +#include "xf86str.h" +#include "xf86Priv.h" +#include "dgaproc.h" +#include +#include "colormapst.h" +#include "pixmapstr.h" +#include "inputstr.h" +#include "globals.h" +#include "servermd.h" +#include "micmap.h" +#include "xkbsrv.h" +#include "xf86Xinput.h" +#include "exglobals.h" +#include "exevents.h" +#include "eventstr.h" +#include "eventconvert.h" + +#include "mi.h" + +static DevPrivateKeyRec DGAScreenKeyRec; +#define DGAScreenKeyRegistered dixPrivateKeyRegistered(&DGAScreenKeyRec) +static Bool mieq_installed; + +static Bool DGACloseScreen(int i, ScreenPtr pScreen); +static void DGADestroyColormap(ColormapPtr pmap); +static void DGAInstallColormap(ColormapPtr pmap); +static void DGAUninstallColormap(ColormapPtr pmap); +static void DGAHandleEvent(int screen_num, InternalEvent *event, + DeviceIntPtr device); + +static void +DGACopyModeInfo( + DGAModePtr mode, + XDGAModePtr xmode +); + +int *XDGAEventBase = NULL; + +#define DGA_GET_SCREEN_PRIV(pScreen) ((DGAScreenPtr) \ + dixLookupPrivate(&(pScreen)->devPrivates, &DGAScreenKeyRec)) + + +typedef struct _FakedVisualList{ + Bool free; + VisualPtr pVisual; + struct _FakedVisualList *next; +} FakedVisualList; + + +typedef struct { + ScrnInfoPtr pScrn; + int numModes; + DGAModePtr modes; + CloseScreenProcPtr CloseScreen; + DestroyColormapProcPtr DestroyColormap; + InstallColormapProcPtr InstallColormap; + UninstallColormapProcPtr UninstallColormap; + DGADevicePtr current; + DGAFunctionPtr funcs; + int input; + ClientPtr client; + int pixmapMode; + FakedVisualList *fakedVisuals; + ColormapPtr dgaColormap; + ColormapPtr savedColormap; + Bool grabMouse; + Bool grabKeyboard; +} DGAScreenRec, *DGAScreenPtr; + +Bool +DGAInit( + ScreenPtr pScreen, + DGAFunctionPtr funcs, + DGAModePtr modes, + int num +){ + ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum]; + DGAScreenPtr pScreenPriv; + int i; + + if(!funcs || !funcs->SetMode || !funcs->OpenFramebuffer) + return FALSE; + + if(!modes || num <= 0) + return FALSE; + + if (!dixRegisterPrivateKey(&DGAScreenKeyRec, PRIVATE_SCREEN, 0)) + return FALSE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + if (!pScreenPriv) + { + if(!(pScreenPriv = (DGAScreenPtr)malloc(sizeof(DGAScreenRec)))) + return FALSE; + dixSetPrivate(&pScreen->devPrivates, &DGAScreenKeyRec, pScreenPriv); + pScreenPriv->CloseScreen = pScreen->CloseScreen; + pScreen->CloseScreen = DGACloseScreen; + pScreenPriv->DestroyColormap = pScreen->DestroyColormap; + pScreen->DestroyColormap = DGADestroyColormap; + pScreenPriv->InstallColormap = pScreen->InstallColormap; + pScreen->InstallColormap = DGAInstallColormap; + pScreenPriv->UninstallColormap = pScreen->UninstallColormap; + pScreen->UninstallColormap = DGAUninstallColormap; + } + + pScreenPriv->pScrn = pScrn; + pScreenPriv->numModes = num; + pScreenPriv->modes = modes; + pScreenPriv->current = NULL; + + pScreenPriv->funcs = funcs; + pScreenPriv->input = 0; + pScreenPriv->client = NULL; + pScreenPriv->fakedVisuals = NULL; + pScreenPriv->dgaColormap = NULL; + pScreenPriv->savedColormap = NULL; + pScreenPriv->grabMouse = FALSE; + pScreenPriv->grabKeyboard = FALSE; + + for(i = 0; i < num; i++) + modes[i].num = i + 1; + +#ifdef PANORAMIX + if(!noPanoramiXExtension) + for(i = 0; i < num; i++) + modes[i].flags &= ~DGA_PIXMAP_AVAILABLE; +#endif + + return TRUE; +} + +/* DGAReInitModes allows the driver to re-initialize + * the DGA mode list. + */ + +Bool +DGAReInitModes( + ScreenPtr pScreen, + DGAModePtr modes, + int num +){ + DGAScreenPtr pScreenPriv; + int i; + + /* No DGA? Ignore call (but don't make it look like it failed) */ + if(!DGAScreenKeyRegistered) + return TRUE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + /* Same as above */ + if(!pScreenPriv) + return TRUE; + + /* Can't do this while DGA is active */ + if(pScreenPriv->current) + return FALSE; + + /* Quick sanity check */ + if(!num) + modes = NULL; + else if(!modes) + num = 0; + + pScreenPriv->numModes = num; + pScreenPriv->modes = modes; + + /* This practically disables DGA. So be it. */ + if(!num) + return TRUE; + + for(i = 0; i < num; i++) + modes[i].num = i + 1; + +#ifdef PANORAMIX + if(!noPanoramiXExtension) + for(i = 0; i < num; i++) + modes[i].flags &= ~DGA_PIXMAP_AVAILABLE; +#endif + + return TRUE; +} + +static void +FreeMarkedVisuals(ScreenPtr pScreen) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + FakedVisualList *prev, *curr, *tmp; + + if(!pScreenPriv->fakedVisuals) + return; + + prev = NULL; + curr = pScreenPriv->fakedVisuals; + + while(curr) { + if(curr->free) { + tmp = curr; + curr = curr->next; + if(prev) + prev->next = curr; + else + pScreenPriv->fakedVisuals = curr; + free(tmp->pVisual); + free(tmp); + } else { + prev = curr; + curr = curr->next; + } + } +} + +static Bool +DGACloseScreen(int i, ScreenPtr pScreen) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + if (mieq_installed) { + mieqSetHandler(ET_DGAEvent, NULL); + mieq_installed = FALSE; + } + + FreeMarkedVisuals(pScreen); + + pScreen->CloseScreen = pScreenPriv->CloseScreen; + pScreen->DestroyColormap = pScreenPriv->DestroyColormap; + pScreen->InstallColormap = pScreenPriv->InstallColormap; + pScreen->UninstallColormap = pScreenPriv->UninstallColormap; + + /* DGAShutdown() should have ensured that no DGA + screen were active by here */ + + free(pScreenPriv); + + return((*pScreen->CloseScreen)(i, pScreen)); +} + + +static void +DGADestroyColormap(ColormapPtr pmap) +{ + ScreenPtr pScreen = pmap->pScreen; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + VisualPtr pVisual = pmap->pVisual; + + if(pScreenPriv->fakedVisuals) { + FakedVisualList *curr = pScreenPriv->fakedVisuals; + + while(curr) { + if(curr->pVisual == pVisual) { + /* We can't get rid of them yet since FreeColormap + still needs the pVisual during the cleanup */ + curr->free = TRUE; + break; + } + curr = curr->next; + } + } + + if(pScreenPriv->DestroyColormap) { + pScreen->DestroyColormap = pScreenPriv->DestroyColormap; + (*pScreen->DestroyColormap)(pmap); + pScreen->DestroyColormap = DGADestroyColormap; + } +} + + +static void +DGAInstallColormap(ColormapPtr pmap) +{ + ScreenPtr pScreen = pmap->pScreen; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + if(pScreenPriv->current && pScreenPriv->dgaColormap) { + if (pmap != pScreenPriv->dgaColormap) { + pScreenPriv->savedColormap = pmap; + pmap = pScreenPriv->dgaColormap; + } + } + + pScreen->InstallColormap = pScreenPriv->InstallColormap; + (*pScreen->InstallColormap)(pmap); + pScreen->InstallColormap = DGAInstallColormap; +} + +static void +DGAUninstallColormap(ColormapPtr pmap) +{ + ScreenPtr pScreen = pmap->pScreen; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + if(pScreenPriv->current && pScreenPriv->dgaColormap) { + if (pmap == pScreenPriv->dgaColormap) { + pScreenPriv->dgaColormap = NULL; + } + } + + pScreen->UninstallColormap = pScreenPriv->UninstallColormap; + (*pScreen->UninstallColormap)(pmap); + pScreen->UninstallColormap = DGAUninstallColormap; +} + +int +xf86SetDGAMode( + int index, + int num, + DGADevicePtr devRet +){ + ScreenPtr pScreen = screenInfo.screens[index]; + DGAScreenPtr pScreenPriv; + ScrnInfoPtr pScrn; + DGADevicePtr device; + PixmapPtr pPix = NULL; + DGAModePtr pMode = NULL; + + /* First check if DGAInit was successful on this screen */ + if (!DGAScreenKeyRegistered) + return BadValue; + pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + if (!pScreenPriv) + return BadValue; + pScrn = pScreenPriv->pScrn; + + if(!num) { + if(pScreenPriv->current) { + PixmapPtr oldPix = pScreenPriv->current->pPix; + if(oldPix) { + if(oldPix->drawable.id) + FreeResource(oldPix->drawable.id, RT_NONE); + else + (*pScreen->DestroyPixmap)(oldPix); + } + free(pScreenPriv->current); + pScreenPriv->current = NULL; + pScrn->vtSema = TRUE; + (*pScreenPriv->funcs->SetMode)(pScrn, NULL); + if(pScreenPriv->savedColormap) { + (*pScreen->InstallColormap)(pScreenPriv->savedColormap); + pScreenPriv->savedColormap = NULL; + } + pScreenPriv->dgaColormap = NULL; + (*pScrn->EnableDisableFBAccess)(index, TRUE); + + FreeMarkedVisuals(pScreen); + } + + pScreenPriv->grabMouse = FALSE; + pScreenPriv->grabKeyboard = FALSE; + + return Success; + } + + if(!pScrn->vtSema && !pScreenPriv->current) /* Really switched away */ + return BadAlloc; + + if((num > 0) && (num <= pScreenPriv->numModes)) + pMode = &(pScreenPriv->modes[num - 1]); + else + return BadValue; + + if(!(device = (DGADevicePtr)malloc(sizeof(DGADeviceRec)))) + return BadAlloc; + + if(!pScreenPriv->current) { + Bool oldVTSema = pScrn->vtSema; + + pScrn->vtSema = FALSE; /* kludge until we rewrite VT switching */ + (*pScrn->EnableDisableFBAccess)(index, FALSE); + pScrn->vtSema = oldVTSema; + } + + if(!(*pScreenPriv->funcs->SetMode)(pScrn, pMode)) { + free(device); + return BadAlloc; + } + + pScrn->currentMode = pMode->mode; + + if(!pScreenPriv->current && !pScreenPriv->input) { + /* if it's multihead we need to warp the cursor off of + our screen so it doesn't get trapped */ + } + + pScrn->vtSema = FALSE; + + if(pScreenPriv->current) { + PixmapPtr oldPix = pScreenPriv->current->pPix; + if(oldPix) { + if(oldPix->drawable.id) + FreeResource(oldPix->drawable.id, RT_NONE); + else + (*pScreen->DestroyPixmap)(oldPix); + } + free(pScreenPriv->current); + pScreenPriv->current = NULL; + } + + if(pMode->flags & DGA_PIXMAP_AVAILABLE) { + if((pPix = (*pScreen->CreatePixmap)(pScreen, 0, 0, pMode->depth, 0))) { + (*pScreen->ModifyPixmapHeader)(pPix, + pMode->pixmapWidth, pMode->pixmapHeight, + pMode->depth, pMode->bitsPerPixel, + pMode->bytesPerScanline, + (pointer)(pMode->address)); + } + } + + devRet->mode = device->mode = pMode; + devRet->pPix = device->pPix = pPix; + pScreenPriv->current = device; + pScreenPriv->pixmapMode = FALSE; + pScreenPriv->grabMouse = TRUE; + pScreenPriv->grabKeyboard = TRUE; + + if (!mieq_installed) { + mieqSetHandler(ET_DGAEvent, DGAHandleEvent); + mieq_installed = TRUE; + } + + return Success; +} + + + +/*********** exported ones ***************/ + +void +DGASetInputMode(int index, Bool keyboard, Bool mouse) +{ + ScreenPtr pScreen = screenInfo.screens[index]; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + if (pScreenPriv) + { + pScreenPriv->grabMouse = mouse; + pScreenPriv->grabKeyboard = keyboard; + + if (!mieq_installed) { + mieqSetHandler(ET_DGAEvent, DGAHandleEvent); + mieq_installed = TRUE; + } + } +} + +Bool +DGAChangePixmapMode(int index, int *x, int *y, int mode) +{ + DGAScreenPtr pScreenPriv; + DGADevicePtr pDev; + DGAModePtr pMode; + PixmapPtr pPix; + + if(!DGAScreenKeyRegistered) + return FALSE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + if(!pScreenPriv || !pScreenPriv->current || !pScreenPriv->current->pPix) + return FALSE; + + pDev = pScreenPriv->current; + pPix = pDev->pPix; + pMode = pDev->mode; + + if(mode) { + int shift = 2; + + if(*x > (pMode->pixmapWidth - pMode->viewportWidth)) + *x = pMode->pixmapWidth - pMode->viewportWidth; + if(*y > (pMode->pixmapHeight - pMode->viewportHeight)) + *y = pMode->pixmapHeight - pMode->viewportHeight; + + switch(xf86Screens[index]->bitsPerPixel) { + case 16: shift = 1; break; + case 32: shift = 0; break; + default: break; + } + + if(BITMAP_SCANLINE_PAD == 64) + shift++; + + *x = (*x >> shift) << shift; + + pPix->drawable.x = *x; + pPix->drawable.y = *y; + pPix->drawable.width = pMode->viewportWidth; + pPix->drawable.height = pMode->viewportHeight; + } else { + pPix->drawable.x = 0; + pPix->drawable.y = 0; + pPix->drawable.width = pMode->pixmapWidth; + pPix->drawable.height = pMode->pixmapHeight; + } + pPix->drawable.serialNumber = NEXT_SERIAL_NUMBER; + pScreenPriv->pixmapMode = mode; + + return TRUE; +} + +Bool +DGAAvailable(int index) +{ + if(!DGAScreenKeyRegistered) + return FALSE; + + if(DGA_GET_SCREEN_PRIV(screenInfo.screens[index])) + return TRUE; + + return FALSE; +} + +Bool +DGAActive(int index) +{ + DGAScreenPtr pScreenPriv; + + if(!DGAScreenKeyRegistered) + return FALSE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + if(pScreenPriv && pScreenPriv->current) + return TRUE; + + return FALSE; +} + + + +/* Called by the event code in case the server is abruptly terminated */ + +void +DGAShutdown(void) +{ + ScrnInfoPtr pScrn; + int i; + + if(!DGAScreenKeyRegistered) + return; + + for(i = 0; i < screenInfo.numScreens; i++) { + pScrn = xf86Screens[i]; + + (void)(*pScrn->SetDGAMode)(pScrn->scrnIndex, 0, NULL); + } +} + +/* Called by the extension to initialize a mode */ + +int +DGASetMode( + int index, + int num, + XDGAModePtr mode, + PixmapPtr *pPix +){ + ScrnInfoPtr pScrn = xf86Screens[index]; + DGADeviceRec device; + int ret; + + /* We rely on the extension to check that DGA is available */ + + ret = (*pScrn->SetDGAMode)(index, num, &device); + if((ret == Success) && num) { + DGACopyModeInfo(device.mode, mode); + *pPix = device.pPix; + } + + return ret; +} + +/* Called from the extension to let the DDX know which events are requested */ + +void +DGASelectInput( + int index, + ClientPtr client, + long mask +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is available */ + pScreenPriv->client = client; + pScreenPriv->input = mask; +} + +int +DGAGetViewportStatus(int index) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is active */ + + if (!pScreenPriv->funcs->GetViewport) + return 0; + + return (*pScreenPriv->funcs->GetViewport)(pScreenPriv->pScrn); +} + +int +DGASetViewport( + int index, + int x, int y, + int mode +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + if (pScreenPriv->funcs->SetViewport) + (*pScreenPriv->funcs->SetViewport)(pScreenPriv->pScrn, x, y, mode); + return Success; +} + + +static int +BitsClear(CARD32 data) +{ + int bits = 0; + CARD32 mask; + + for(mask = 1; mask; mask <<= 1) { + if(!(data & mask)) bits++; + else break; + } + + return bits; +} + +int +DGACreateColormap(int index, ClientPtr client, int id, int mode, int alloc) +{ + ScreenPtr pScreen = screenInfo.screens[index]; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + FakedVisualList *fvlp; + VisualPtr pVisual; + DGAModePtr pMode; + ColormapPtr pmap; + + if(!mode || (mode > pScreenPriv->numModes)) + return BadValue; + + if((alloc != AllocNone) && (alloc != AllocAll)) + return BadValue; + + pMode = &(pScreenPriv->modes[mode - 1]); + + if(!(pVisual = malloc(sizeof(VisualRec)))) + return BadAlloc; + + pVisual->vid = FakeClientID(0); + pVisual->class = pMode->visualClass; + pVisual->nplanes = pMode->depth; + pVisual->ColormapEntries = 1 << pMode->depth; + pVisual->bitsPerRGBValue = (pMode->depth + 2) / 3; + + switch (pVisual->class) { + case PseudoColor: + case GrayScale: + case StaticGray: + pVisual->bitsPerRGBValue = 8; /* not quite */ + pVisual->redMask = 0; + pVisual->greenMask = 0; + pVisual->blueMask = 0; + pVisual->offsetRed = 0; + pVisual->offsetGreen = 0; + pVisual->offsetBlue = 0; + break; + case DirectColor: + case TrueColor: + pVisual->ColormapEntries = 1 << pVisual->bitsPerRGBValue; + /* fall through */ + case StaticColor: + pVisual->redMask = pMode->red_mask; + pVisual->greenMask = pMode->green_mask; + pVisual->blueMask = pMode->blue_mask; + pVisual->offsetRed = BitsClear(pVisual->redMask); + pVisual->offsetGreen = BitsClear(pVisual->greenMask); + pVisual->offsetBlue = BitsClear(pVisual->blueMask); + } + + if(!(fvlp = malloc(sizeof(FakedVisualList)))) { + free(pVisual); + return BadAlloc; + } + + fvlp->free = FALSE; + fvlp->pVisual = pVisual; + fvlp->next = pScreenPriv->fakedVisuals; + pScreenPriv->fakedVisuals = fvlp; + + LEGAL_NEW_RESOURCE(id, client); + + return CreateColormap(id, pScreen, pVisual, &pmap, alloc, client->index); +} + +/* Called by the extension to install a colormap on DGA active screens */ + +void +DGAInstallCmap(ColormapPtr cmap) +{ + ScreenPtr pScreen = cmap->pScreen; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + /* We rely on the extension to check that DGA is active */ + + if(!pScreenPriv->dgaColormap) + pScreenPriv->savedColormap = GetInstalledmiColormap(pScreen); + + pScreenPriv->dgaColormap = cmap; + + (*pScreen->InstallColormap)(cmap); +} + +int +DGASync(int index) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is active */ + + if (pScreenPriv->funcs->Sync) + (*pScreenPriv->funcs->Sync)(pScreenPriv->pScrn); + + return Success; +} + +int +DGAFillRect( + int index, + int x, int y, int w, int h, + unsigned long color +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is active */ + + if(pScreenPriv->funcs->FillRect && + (pScreenPriv->current->mode->flags & DGA_FILL_RECT)) { + + (*pScreenPriv->funcs->FillRect)(pScreenPriv->pScrn, x, y, w, h, color); + return Success; + } + return BadMatch; +} + +int +DGABlitRect( + int index, + int srcx, int srcy, + int w, int h, + int dstx, int dsty +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is active */ + + if(pScreenPriv->funcs->BlitRect && + (pScreenPriv->current->mode->flags & DGA_BLIT_RECT)) { + + (*pScreenPriv->funcs->BlitRect)(pScreenPriv->pScrn, + srcx, srcy, w, h, dstx, dsty); + return Success; + } + return BadMatch; +} + +int +DGABlitTransRect( + int index, + int srcx, int srcy, + int w, int h, + int dstx, int dsty, + unsigned long color +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is active */ + + if(pScreenPriv->funcs->BlitTransRect && + (pScreenPriv->current->mode->flags & DGA_BLIT_RECT_TRANS)) { + + (*pScreenPriv->funcs->BlitTransRect)(pScreenPriv->pScrn, + srcx, srcy, w, h, dstx, dsty, color); + return Success; + } + return BadMatch; +} + + +int +DGAGetModes(int index) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + /* We rely on the extension to check that DGA is available */ + + return pScreenPriv->numModes; +} + + +int +DGAGetModeInfo( + int index, + XDGAModePtr mode, + int num +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + /* We rely on the extension to check that DGA is available */ + + if((num <= 0) || (num > pScreenPriv->numModes)) + return BadValue; + + DGACopyModeInfo(&(pScreenPriv->modes[num - 1]), mode); + + return Success; +} + + +static void +DGACopyModeInfo( + DGAModePtr mode, + XDGAModePtr xmode +){ + DisplayModePtr dmode = mode->mode; + + xmode->num = mode->num; + xmode->name = dmode->name; + xmode->VSync_num = (int)(dmode->VRefresh * 1000.0); + xmode->VSync_den = 1000; + xmode->flags = mode->flags; + xmode->imageWidth = mode->imageWidth; + xmode->imageHeight = mode->imageHeight; + xmode->pixmapWidth = mode->pixmapWidth; + xmode->pixmapHeight = mode->pixmapHeight; + xmode->bytesPerScanline = mode->bytesPerScanline; + xmode->byteOrder = mode->byteOrder; + xmode->depth = mode->depth; + xmode->bitsPerPixel = mode->bitsPerPixel; + xmode->red_mask = mode->red_mask; + xmode->green_mask = mode->green_mask; + xmode->blue_mask = mode->blue_mask; + xmode->visualClass = mode->visualClass; + xmode->viewportWidth = mode->viewportWidth; + xmode->viewportHeight = mode->viewportHeight; + xmode->xViewportStep = mode->xViewportStep; + xmode->yViewportStep = mode->yViewportStep; + xmode->maxViewportX = mode->maxViewportX; + xmode->maxViewportY = mode->maxViewportY; + xmode->viewportFlags = mode->viewportFlags; + xmode->reserved1 = mode->reserved1; + xmode->reserved2 = mode->reserved2; + xmode->offset = mode->offset; + + if(dmode->Flags & V_INTERLACE) xmode->flags |= DGA_INTERLACED; + if(dmode->Flags & V_DBLSCAN) xmode->flags |= DGA_DOUBLESCAN; +} + + +Bool +DGAVTSwitch(void) +{ + ScreenPtr pScreen; + int i; + + for(i = 0; i < screenInfo.numScreens; i++) { + pScreen = screenInfo.screens[i]; + + /* Alternatively, this could send events to DGA clients */ + + if(DGAScreenKeyRegistered) { + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + if(pScreenPriv && pScreenPriv->current) + return FALSE; + } + } + + return TRUE; +} + +Bool +DGAStealKeyEvent(DeviceIntPtr dev, int index, int key_code, int is_down) +{ + DGAScreenPtr pScreenPriv; + DGAEvent event; + + if(!DGAScreenKeyRegistered) /* no DGA */ + return FALSE; + + if (key_code < 8 || key_code > 255) + return FALSE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + if(!pScreenPriv || !pScreenPriv->grabKeyboard) /* no direct mode */ + return FALSE; + + memset(&event, 0, sizeof(event)); + event.header = ET_Internal; + event.type = ET_DGAEvent; + event.length = sizeof(event); + event.time = GetTimeInMillis(); + event.subtype = (is_down ? ET_KeyPress : ET_KeyRelease); + event.detail = key_code; + event.dx = 0; + event.dy = 0; + mieqEnqueue (dev, (InternalEvent*)&event); + + return TRUE; +} + +Bool +DGAStealMotionEvent(DeviceIntPtr dev, int index, int dx, int dy) +{ + DGAScreenPtr pScreenPriv; + DGAEvent event; + + if(!DGAScreenKeyRegistered) /* no DGA */ + return FALSE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + if(!pScreenPriv || !pScreenPriv->grabMouse) /* no direct mode */ + return FALSE; + + memset(&event, 0, sizeof(event)); + event.header = ET_Internal; + event.type = ET_DGAEvent; + event.length = sizeof(event); + event.time = GetTimeInMillis(); + event.subtype = ET_Motion; + event.detail = 0; + event.dx = dx; + event.dy = dy; + mieqEnqueue (dev, (InternalEvent*)&event); + return TRUE; +} + +Bool +DGAStealButtonEvent(DeviceIntPtr dev, int index, int button, int is_down) +{ + DGAScreenPtr pScreenPriv; + DGAEvent event; + + if(!DGAScreenKeyRegistered) /* no DGA */ + return FALSE; + + pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + if (!pScreenPriv || !pScreenPriv->grabMouse) + return FALSE; + + memset(&event, 0, sizeof(event)); + event.header = ET_Internal; + event.type = ET_DGAEvent; + event.length = sizeof(event); + event.time = GetTimeInMillis(); + event.subtype = (is_down ? ET_ButtonPress : ET_ButtonRelease); + event.detail = button; + event.dx = 0; + event.dy = 0; + mieqEnqueue (dev, (InternalEvent*)&event); + + return TRUE; +} + +/* We have the power to steal or modify events that are about to get queued */ + +#define NoSuchEvent 0x80000000 /* so doesn't match NoEventMask */ +static Mask filters[] = +{ + NoSuchEvent, /* 0 */ + NoSuchEvent, /* 1 */ + KeyPressMask, /* KeyPress */ + KeyReleaseMask, /* KeyRelease */ + ButtonPressMask, /* ButtonPress */ + ButtonReleaseMask, /* ButtonRelease */ + PointerMotionMask, /* MotionNotify (initial state) */ +}; + +static void +DGAProcessKeyboardEvent (ScreenPtr pScreen, DGAEvent *event, DeviceIntPtr keybd) +{ + KeyClassPtr keyc = keybd->key; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + DeviceIntPtr pointer = GetPairedDevice(keybd); + DeviceEvent ev; + + memset(&ev, 0, sizeof(ev)); + ev.header = ET_Internal; + ev.length = sizeof(ev); + ev.detail.key = event->detail; + ev.type = event->subtype; + ev.root_x = 0; + ev.root_y = 0; + ev.corestate = XkbStateFieldFromRec(&keyc->xkbInfo->state); + ev.corestate |= pointer->button->state; + + UpdateDeviceState(keybd, &ev); + + /* + * Deliver the DGA event + */ + if (pScreenPriv->client) + { + dgaEvent de; + de.u.u.type = *XDGAEventBase + GetCoreType((InternalEvent*)&ev); + de.u.u.detail = event->detail; + de.u.event.time = event->time; + de.u.event.dx = event->dx; + de.u.event.dy = event->dy; + de.u.event.screen = pScreen->myNum; + de.u.event.state = ev.corestate; + + /* If the DGA client has selected input, then deliver based on the usual filter */ + TryClientEvents (pScreenPriv->client, keybd, (xEvent *)&de, 1, + filters[ev.type], pScreenPriv->input, 0); + } + else + { + /* If the keyboard is actively grabbed, deliver a grabbed core event */ + if (keybd->deviceGrab.grab && !keybd->deviceGrab.fromPassiveGrab) + { + ev.detail.key = event->detail; + ev.time = event->time; + ev.root_x = event->dx; + ev.root_y = event->dy; + ev.corestate = event->state; + ev.deviceid = keybd->id; + DeliverGrabbedEvent ((InternalEvent*)&ev, keybd, FALSE); + } + } +} + +static void +DGAProcessPointerEvent (ScreenPtr pScreen, DGAEvent *event, DeviceIntPtr mouse) +{ + ButtonClassPtr butc = mouse->button; + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + DeviceEvent ev; + DeviceIntPtr master = GetMaster(mouse, MASTER_KEYBOARD); + + memset(&ev, 0, sizeof(ev)); + ev.header = ET_Internal; + ev.length = sizeof(ev); + ev.type = event->subtype; + ev.corestate = butc ? butc->state : 0; + if (master && master->key) + ev.corestate |= XkbStateFieldFromRec(&master->key->xkbInfo->state); + + UpdateDeviceState(mouse, &ev); + + /* + * Deliver the DGA event + */ + if (pScreenPriv->client) + { + dgaEvent de; + int coreEquiv; + + coreEquiv = GetCoreType((InternalEvent*)&ev); + + de.u.u.type = *XDGAEventBase + coreEquiv; + de.u.u.detail = event->detail; + de.u.event.time = event->time; + de.u.event.dx = event->dx; + de.u.event.dy = event->dy; + de.u.event.screen = pScreen->myNum; + de.u.event.state = ev.corestate; + + /* If the DGA client has selected input, then deliver based on the usual filter */ + TryClientEvents (pScreenPriv->client, mouse, (xEvent *)&de, 1, + filters[coreEquiv], pScreenPriv->input, 0); + } + else + { + /* If the pointer is actively grabbed, deliver a grabbed core event */ + if (mouse->deviceGrab.grab && !mouse->deviceGrab.fromPassiveGrab) + { + ev.detail.button = event->detail; + ev.time = event->time; + ev.root_x = event->dx; + ev.root_y = event->dy; + ev.corestate = event->state; + /* DGA is core only, so valuators.data doesn't actually matter. + * Mask must be set for EventToCore to create motion events. */ + SetBit(ev.valuators.mask, 0); + SetBit(ev.valuators.mask, 1); + DeliverGrabbedEvent ((InternalEvent*)&ev, mouse, FALSE); + } + } +} + +Bool +DGAOpenFramebuffer( + int index, + char **name, + unsigned char **mem, + int *size, + int *offset, + int *flags +){ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is available */ + + return (*pScreenPriv->funcs->OpenFramebuffer)(pScreenPriv->pScrn, + name, mem, size, offset, flags); +} + +void +DGACloseFramebuffer(int index) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + + /* We rely on the extension to check that DGA is available */ + if(pScreenPriv->funcs->CloseFramebuffer) + (*pScreenPriv->funcs->CloseFramebuffer)(pScreenPriv->pScrn); +} + +/* For DGA 1.0 backwards compatibility only */ + +int +DGAGetOldDGAMode(int index) +{ + DGAScreenPtr pScreenPriv = DGA_GET_SCREEN_PRIV(screenInfo.screens[index]); + ScrnInfoPtr pScrn = pScreenPriv->pScrn; + DGAModePtr mode; + int i, w, h, p; + + /* We rely on the extension to check that DGA is available */ + + w = pScrn->currentMode->HDisplay; + h = pScrn->currentMode->VDisplay; + p = pad_to_int32(pScrn->displayWidth * bits_to_bytes(pScrn->bitsPerPixel)); + + for(i = 0; i < pScreenPriv->numModes; i++) { + mode = &(pScreenPriv->modes[i]); + + if((mode->viewportWidth == w) && (mode->viewportHeight == h) && + (mode->bytesPerScanline == p) && + (mode->bitsPerPixel == pScrn->bitsPerPixel) && + (mode->depth == pScrn->depth)) { + + return mode->num; + } + } + + return 0; +} + +static void +DGAHandleEvent(int screen_num, InternalEvent *ev, DeviceIntPtr device) +{ + DGAEvent *event= &ev->dga_event; + ScreenPtr pScreen = screenInfo.screens[screen_num]; + DGAScreenPtr pScreenPriv; + + /* no DGA */ + if (!DGAScreenKeyRegistered || XDGAEventBase == 0) + return; + pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen); + + /* DGA not initialized on this screen */ + if (!pScreenPriv) + return; + + if (!IsMaster(device)) + return; + + switch (event->subtype) { + case KeyPress: + case KeyRelease: + DGAProcessKeyboardEvent (pScreen, event, device); + break; + case MotionNotify: + case ButtonPress: + case ButtonRelease: + DGAProcessPointerEvent (pScreen, event, device); + break; + default: + break; + } +} diff --git a/xorg-server/hw/xfree86/common/xf86Module.h b/xorg-server/hw/xfree86/common/xf86Module.h index 0e7be4dd7..49a98bd05 100644 --- a/xorg-server/hw/xfree86/common/xf86Module.h +++ b/xorg-server/hw/xfree86/common/xf86Module.h @@ -1,212 +1,212 @@ -/* - * Copyright (c) 1997-2003 by The XFree86 Project, Inc. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR - * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, - * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR - * OTHER DEALINGS IN THE SOFTWARE. - * - * Except as contained in this notice, the name of the copyright holder(s) - * and author(s) shall not be used in advertising or otherwise to promote - * the sale, use or other dealings in this Software without prior written - * authorization from the copyright holder(s) and author(s). - */ - -/* - * This file contains the parts of the loader interface that are visible - * to modules. This is the only loader-related header that modules should - * include. - * - * It should include a bare minimum of other headers. - * - * Longer term, the module/loader code should probably live directly under - * Xserver/. - * - * XXX This file arguably belongs in xfree86/loader/. - */ - -#ifndef _XF86MODULE_H -#define _XF86MODULE_H - -#include "misc.h" -#ifndef NULL -#define NULL ((void *)0) -#endif - -typedef enum { - LD_RESOLV_IFDONE = 0, /* only check if no more - delays pending */ - LD_RESOLV_NOW = 1, /* finish one delay step */ - LD_RESOLV_FORCE = 2 /* force checking... */ -} LoaderResolveOptions; - -#define DEFAULT_LIST ((char *)-1) - -/* This indicates a special module that doesn't have the usual entry point */ -#define EXTERN_MODULE ((pointer)-1) - -/* Built-in ABI classes. These definitions must not be changed. */ -#define ABI_CLASS_NONE NULL -#define ABI_CLASS_ANSIC "X.Org ANSI C Emulation" -#define ABI_CLASS_VIDEODRV "X.Org Video Driver" -#define ABI_CLASS_XINPUT "X.Org XInput driver" -#define ABI_CLASS_EXTENSION "X.Org Server Extension" -#define ABI_CLASS_FONT "X.Org Font Renderer" - -#define ABI_MINOR_MASK 0x0000FFFF -#define ABI_MAJOR_MASK 0xFFFF0000 -#define GET_ABI_MINOR(v) ((v) & ABI_MINOR_MASK) -#define GET_ABI_MAJOR(v) (((v) & ABI_MAJOR_MASK) >> 16) -#define SET_ABI_VERSION(maj, min) \ - ((((maj) << 16) & ABI_MAJOR_MASK) | ((min) & ABI_MINOR_MASK)) - -/* - * ABI versions. Each version has a major and minor revision. Modules - * using lower minor revisions must work with servers of a higher minor - * revision. There is no compatibility between different major revisions. - * Whenever the ABI_ANSIC_VERSION is changed, the others must also be - * changed. The minor revision mask is 0x0000FFFF and the major revision - * mask is 0xFFFF0000. - */ -#define ABI_ANSIC_VERSION SET_ABI_VERSION(0, 4) -#define ABI_VIDEODRV_VERSION SET_ABI_VERSION(9, 0) -#define ABI_XINPUT_VERSION SET_ABI_VERSION(12, 1) -#define ABI_EXTENSION_VERSION SET_ABI_VERSION(5, 0) -#define ABI_FONT_VERSION SET_ABI_VERSION(0, 6) - -#define MODINFOSTRING1 0xef23fdc5 -#define MODINFOSTRING2 0x10dc023a - -#ifndef MODULEVENDORSTRING -#define MODULEVENDORSTRING "X.Org Foundation" -#endif - -/* Error return codes for errmaj. New codes must only be added at the end. */ -typedef enum { - LDR_NOERROR = 0, - LDR_NOMEM, /* memory allocation failed */ - LDR_NOENT, /* Module file does not exist */ - LDR_NOSUBENT, /* pre-requsite file to be sub-loaded does not exist */ - LDR_NOSPACE, /* internal module array full */ - LDR_NOMODOPEN, /* module file could not be opened (check errmin) */ - LDR_UNKTYPE, /* file is not a recognized module type */ - LDR_NOLOAD, /* type specific loader failed */ - LDR_ONCEONLY, /* Module should only be loaded once (not an error) */ - LDR_NOPORTOPEN, /* could not open port (check errmin) */ - LDR_NOHARDWARE, /* could not query/initialize the hardware device */ - LDR_MISMATCH, /* the module didn't match the spec'd requirments */ - LDR_BADUSAGE, /* LoadModule is called with bad arguments */ - LDR_INVALID, /* The module doesn't have a valid ModuleData object */ - LDR_BADOS, /* The module doesn't support the OS */ - LDR_MODSPECIFIC /* A module-specific error in the SetupProc */ -} LoaderErrorCode; - -/* - * Some common module classes. The moduleclass can be used to identify - * that modules loaded are of the correct type. This is a finer - * classification than the ABI classes even though the default set of - * classes have the same names. For example, not all modules that require - * the video driver ABI are themselves video drivers. - */ -#define MOD_CLASS_NONE NULL -#define MOD_CLASS_VIDEODRV "X.Org Video Driver" -#define MOD_CLASS_XINPUT "X.Org XInput Driver" -#define MOD_CLASS_FONT "X.Org Font Renderer" -#define MOD_CLASS_EXTENSION "X.Org Server Extension" - -/* This structure is expected to be returned by the initfunc */ -typedef struct { - const char * modname; /* name of module, e.g. "foo" */ - const char * vendor; /* vendor specific string */ - CARD32 _modinfo1_; /* constant MODINFOSTRING1/2 to find */ - CARD32 _modinfo2_; /* infoarea with a binary editor or sign tool */ - CARD32 xf86version; /* contains XF86_VERSION_CURRENT */ - CARD8 majorversion; /* module-specific major version */ - CARD8 minorversion; /* module-specific minor version */ - CARD16 patchlevel; /* module-specific patch level */ - const char * abiclass; /* ABI class that the module uses */ - CARD32 abiversion; /* ABI version */ - const char * moduleclass; /* module class description */ - CARD32 checksum[4]; /* contains a digital signature of the */ - /* version info structure */ -} XF86ModuleVersionInfo; - -/* - * This structure can be used to callers of LoadModule and LoadSubModule to - * specify version and/or ABI requirements. - */ -typedef struct { - CARD8 majorversion; /* module-specific major version */ - CARD8 minorversion; /* moudle-specific minor version */ - CARD16 patchlevel; /* module-specific patch level */ - const char * abiclass; /* ABI class that the module uses */ - CARD32 abiversion; /* ABI version */ - const char * moduleclass; /* module class */ -} XF86ModReqInfo; - -/* values to indicate unspecified fields in XF86ModReqInfo. */ -#define MAJOR_UNSPEC 0xFF -#define MINOR_UNSPEC 0xFF -#define PATCH_UNSPEC 0xFFFF -#define ABI_VERS_UNSPEC 0xFFFFFFFF - -#define MODULE_VERSION_NUMERIC(maj, min, patch) \ - ((((maj) & 0xFF) << 24) | (((min) & 0xFF) << 16) | (patch & 0xFFFF)) -#define GET_MODULE_MAJOR_VERSION(vers) (((vers) >> 24) & 0xFF) -#define GET_MODULE_MINOR_VERSION(vers) (((vers) >> 16) & 0xFF) -#define GET_MODULE_PATCHLEVEL(vers) ((vers) & 0xFFFF) - -#define INITARGS void - -typedef void (*InitExtension)(INITARGS); - -typedef struct { - InitExtension initFunc; - const char * name; - Bool *disablePtr; - InitExtension setupFunc; - const char ** initDependencies; -} ExtensionModule; - -extern _X_EXPORT ExtensionModule *ExtensionModuleList; - -/* Prototypes for Loader functions that are exported to modules */ -extern _X_EXPORT pointer LoadSubModule(pointer, const char *, const char **, - const char **, pointer, const XF86ModReqInfo *, - int *, int *); -extern _X_EXPORT void UnloadSubModule(pointer); -extern _X_EXPORT void UnloadModule (pointer); -extern _X_EXPORT pointer LoaderSymbol(const char *); -extern _X_EXPORT char **LoaderListDirs(const char **, const char **); -extern _X_EXPORT void LoaderFreeDirList(char **); -extern _X_EXPORT void LoaderErrorMsg(const char *, const char *, int, int); -extern _X_EXPORT void LoadExtension(ExtensionModule *, Bool); -extern _X_EXPORT void LoaderGetOS(const char **name, int *major, int *minor, int *teeny); -extern _X_EXPORT Bool LoaderShouldIgnoreABI(void); -extern _X_EXPORT int LoaderGetABIVersion(const char *abiclass); - -typedef pointer (*ModuleSetupProc)(pointer, pointer, int *, int *); -typedef void (*ModuleTearDownProc)(pointer); -#define MODULESETUPPROTO(func) pointer func(pointer, pointer, int*, int*) -#define MODULETEARDOWNPROTO(func) void func(pointer) - -typedef struct { - XF86ModuleVersionInfo * vers; - ModuleSetupProc setup; - ModuleTearDownProc teardown; -} XF86ModuleData; - -#endif /* _XF86STR_H */ +/* + * Copyright (c) 1997-2003 by The XFree86 Project, Inc. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR + * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, + * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR + * OTHER DEALINGS IN THE SOFTWARE. + * + * Except as contained in this notice, the name of the copyright holder(s) + * and author(s) shall not be used in advertising or otherwise to promote + * the sale, use or other dealings in this Software without prior written + * authorization from the copyright holder(s) and author(s). + */ + +/* + * This file contains the parts of the loader interface that are visible + * to modules. This is the only loader-related header that modules should + * include. + * + * It should include a bare minimum of other headers. + * + * Longer term, the module/loader code should probably live directly under + * Xserver/. + * + * XXX This file arguably belongs in xfree86/loader/. + */ + +#ifndef _XF86MODULE_H +#define _XF86MODULE_H + +#include "misc.h" +#ifndef NULL +#define NULL ((void *)0) +#endif + +typedef enum { + LD_RESOLV_IFDONE = 0, /* only check if no more + delays pending */ + LD_RESOLV_NOW = 1, /* finish one delay step */ + LD_RESOLV_FORCE = 2 /* force checking... */ +} LoaderResolveOptions; + +#define DEFAULT_LIST ((char *)-1) + +/* This indicates a special module that doesn't have the usual entry point */ +#define EXTERN_MODULE ((pointer)-1) + +/* Built-in ABI classes. These definitions must not be changed. */ +#define ABI_CLASS_NONE NULL +#define ABI_CLASS_ANSIC "X.Org ANSI C Emulation" +#define ABI_CLASS_VIDEODRV "X.Org Video Driver" +#define ABI_CLASS_XINPUT "X.Org XInput driver" +#define ABI_CLASS_EXTENSION "X.Org Server Extension" +#define ABI_CLASS_FONT "X.Org Font Renderer" + +#define ABI_MINOR_MASK 0x0000FFFF +#define ABI_MAJOR_MASK 0xFFFF0000 +#define GET_ABI_MINOR(v) ((v) & ABI_MINOR_MASK) +#define GET_ABI_MAJOR(v) (((v) & ABI_MAJOR_MASK) >> 16) +#define SET_ABI_VERSION(maj, min) \ + ((((maj) << 16) & ABI_MAJOR_MASK) | ((min) & ABI_MINOR_MASK)) + +/* + * ABI versions. Each version has a major and minor revision. Modules + * using lower minor revisions must work with servers of a higher minor + * revision. There is no compatibility between different major revisions. + * Whenever the ABI_ANSIC_VERSION is changed, the others must also be + * changed. The minor revision mask is 0x0000FFFF and the major revision + * mask is 0xFFFF0000. + */ +#define ABI_ANSIC_VERSION SET_ABI_VERSION(0, 4) +#define ABI_VIDEODRV_VERSION SET_ABI_VERSION(9, 0) +#define ABI_XINPUT_VERSION SET_ABI_VERSION(12, 2) +#define ABI_EXTENSION_VERSION SET_ABI_VERSION(5, 0) +#define ABI_FONT_VERSION SET_ABI_VERSION(0, 6) + +#define MODINFOSTRING1 0xef23fdc5 +#define MODINFOSTRING2 0x10dc023a + +#ifndef MODULEVENDORSTRING +#define MODULEVENDORSTRING "X.Org Foundation" +#endif + +/* Error return codes for errmaj. New codes must only be added at the end. */ +typedef enum { + LDR_NOERROR = 0, + LDR_NOMEM, /* memory allocation failed */ + LDR_NOENT, /* Module file does not exist */ + LDR_NOSUBENT, /* pre-requsite file to be sub-loaded does not exist */ + LDR_NOSPACE, /* internal module array full */ + LDR_NOMODOPEN, /* module file could not be opened (check errmin) */ + LDR_UNKTYPE, /* file is not a recognized module type */ + LDR_NOLOAD, /* type specific loader failed */ + LDR_ONCEONLY, /* Module should only be loaded once (not an error) */ + LDR_NOPORTOPEN, /* could not open port (check errmin) */ + LDR_NOHARDWARE, /* could not query/initialize the hardware device */ + LDR_MISMATCH, /* the module didn't match the spec'd requirments */ + LDR_BADUSAGE, /* LoadModule is called with bad arguments */ + LDR_INVALID, /* The module doesn't have a valid ModuleData object */ + LDR_BADOS, /* The module doesn't support the OS */ + LDR_MODSPECIFIC /* A module-specific error in the SetupProc */ +} LoaderErrorCode; + +/* + * Some common module classes. The moduleclass can be used to identify + * that modules loaded are of the correct type. This is a finer + * classification than the ABI classes even though the default set of + * classes have the same names. For example, not all modules that require + * the video driver ABI are themselves video drivers. + */ +#define MOD_CLASS_NONE NULL +#define MOD_CLASS_VIDEODRV "X.Org Video Driver" +#define MOD_CLASS_XINPUT "X.Org XInput Driver" +#define MOD_CLASS_FONT "X.Org Font Renderer" +#define MOD_CLASS_EXTENSION "X.Org Server Extension" + +/* This structure is expected to be returned by the initfunc */ +typedef struct { + const char * modname; /* name of module, e.g. "foo" */ + const char * vendor; /* vendor specific string */ + CARD32 _modinfo1_; /* constant MODINFOSTRING1/2 to find */ + CARD32 _modinfo2_; /* infoarea with a binary editor or sign tool */ + CARD32 xf86version; /* contains XF86_VERSION_CURRENT */ + CARD8 majorversion; /* module-specific major version */ + CARD8 minorversion; /* module-specific minor version */ + CARD16 patchlevel; /* module-specific patch level */ + const char * abiclass; /* ABI class that the module uses */ + CARD32 abiversion; /* ABI version */ + const char * moduleclass; /* module class description */ + CARD32 checksum[4]; /* contains a digital signature of the */ + /* version info structure */ +} XF86ModuleVersionInfo; + +/* + * This structure can be used to callers of LoadModule and LoadSubModule to + * specify version and/or ABI requirements. + */ +typedef struct { + CARD8 majorversion; /* module-specific major version */ + CARD8 minorversion; /* moudle-specific minor version */ + CARD16 patchlevel; /* module-specific patch level */ + const char * abiclass; /* ABI class that the module uses */ + CARD32 abiversion; /* ABI version */ + const char * moduleclass; /* module class */ +} XF86ModReqInfo; + +/* values to indicate unspecified fields in XF86ModReqInfo. */ +#define MAJOR_UNSPEC 0xFF +#define MINOR_UNSPEC 0xFF +#define PATCH_UNSPEC 0xFFFF +#define ABI_VERS_UNSPEC 0xFFFFFFFF + +#define MODULE_VERSION_NUMERIC(maj, min, patch) \ + ((((maj) & 0xFF) << 24) | (((min) & 0xFF) << 16) | (patch & 0xFFFF)) +#define GET_MODULE_MAJOR_VERSION(vers) (((vers) >> 24) & 0xFF) +#define GET_MODULE_MINOR_VERSION(vers) (((vers) >> 16) & 0xFF) +#define GET_MODULE_PATCHLEVEL(vers) ((vers) & 0xFFFF) + +#define INITARGS void + +typedef void (*InitExtension)(INITARGS); + +typedef struct { + InitExtension initFunc; + const char * name; + Bool *disablePtr; + InitExtension setupFunc; + const char ** initDependencies; +} ExtensionModule; + +extern _X_EXPORT ExtensionModule *ExtensionModuleList; + +/* Prototypes for Loader functions that are exported to modules */ +extern _X_EXPORT pointer LoadSubModule(pointer, const char *, const char **, + const char **, pointer, const XF86ModReqInfo *, + int *, int *); +extern _X_EXPORT void UnloadSubModule(pointer); +extern _X_EXPORT void UnloadModule (pointer); +extern _X_EXPORT pointer LoaderSymbol(const char *); +extern _X_EXPORT char **LoaderListDirs(const char **, const char **); +extern _X_EXPORT void LoaderFreeDirList(char **); +extern _X_EXPORT void LoaderErrorMsg(const char *, const char *, int, int); +extern _X_EXPORT void LoadExtension(ExtensionModule *, Bool); +extern _X_EXPORT void LoaderGetOS(const char **name, int *major, int *minor, int *teeny); +extern _X_EXPORT Bool LoaderShouldIgnoreABI(void); +extern _X_EXPORT int LoaderGetABIVersion(const char *abiclass); + +typedef pointer (*ModuleSetupProc)(pointer, pointer, int *, int *); +typedef void (*ModuleTearDownProc)(pointer); +#define MODULESETUPPROTO(func) pointer func(pointer, pointer, int*, int*) +#define MODULETEARDOWNPROTO(func) void func(pointer) + +typedef struct { + XF86ModuleVersionInfo * vers; + ModuleSetupProc setup; + ModuleTearDownProc teardown; +} XF86ModuleData; + +#endif /* _XF86STR_H */ diff --git a/xorg-server/hw/xfree86/common/xf86Xinput.c b/xorg-server/hw/xfree86/common/xf86Xinput.c index b9006ab07..74365e10b 100644 --- a/xorg-server/hw/xfree86/common/xf86Xinput.c +++ b/xorg-server/hw/xfree86/common/xf86Xinput.c @@ -1011,11 +1011,6 @@ xf86PostMotionEventM(DeviceIntPtr device, DeviceEvent *event; int flags = 0; -#if XFreeXDGA - int index; - int dx = 0, dy = 0; -#endif - if (valuator_mask_num_valuators(mask) > 0) { if (is_absolute) @@ -1029,7 +1024,9 @@ xf86PostMotionEventM(DeviceIntPtr device, if (valuator_mask_isset(mask, 0) || valuator_mask_isset(mask, 1)) if (miPointerGetScreen(device)) { - index = miPointerGetScreen(device)->myNum; + int index = miPointerGetScreen(device)->myNum; + int dx = 0, dy = 0; + if (valuator_mask_isset(mask, 0)) { dx = valuator_mask_get(mask, 0); @@ -1160,10 +1157,6 @@ xf86PostButtonEventM(DeviceIntPtr device, int i = 0, nevents = 0; int flags = 0; -#if XFreeXDGA - int index; -#endif - if (valuator_mask_num_valuators(mask) > 0) { if (is_absolute) @@ -1174,7 +1167,8 @@ xf86PostButtonEventM(DeviceIntPtr device, #if XFreeXDGA if (miPointerGetScreen(device)) { - index = miPointerGetScreen(device)->myNum; + int index = miPointerGetScreen(device)->myNum; + if (DGAStealButtonEvent(device, index, button, is_down)) return; } @@ -1240,6 +1234,19 @@ xf86PostKeyEventM(DeviceIntPtr device, { int i = 0, nevents = 0; +#if XFreeXDGA + DeviceIntPtr pointer; + + /* Some pointers send key events, paired device is wrong then. */ + pointer = IsPointerDevice(device) ? device : GetPairedDevice(device); + if (miPointerGetScreen(pointer)) { + int index = miPointerGetScreen(pointer)->myNum; + + if (DGAStealKeyEvent(device, index, key_code, is_down)) + return; + } +#endif + if (is_absolute) { nevents = GetKeyboardValuatorEvents(xf86Events, device, is_down ? KeyPress : KeyRelease, diff --git a/xorg-server/hw/xfree86/dixmods/extmod/dgaproc.h b/xorg-server/hw/xfree86/dixmods/extmod/dgaproc.h index 6745a6e7a..a13a51794 100644 --- a/xorg-server/hw/xfree86/dixmods/extmod/dgaproc.h +++ b/xorg-server/hw/xfree86/dixmods/extmod/dgaproc.h @@ -124,7 +124,6 @@ extern _X_EXPORT Bool DGAStealButtonEvent(DeviceIntPtr dev, int Index, int butto int is_down); extern _X_EXPORT Bool DGAStealMotionEvent(DeviceIntPtr dev, int Index, int dx, int dy); extern _X_EXPORT Bool DGAStealKeyEvent(DeviceIntPtr dev, int Index, int key_code, int is_down); -extern _X_EXPORT Bool DGAIsDgaEvent (xEvent *e); extern _X_EXPORT Bool DGAOpenFramebuffer(int Index, char **name, unsigned char **mem, int *size, int *offset, int *flags); diff --git a/xorg-server/hw/xfree86/modes/xf86Crtc.c b/xorg-server/hw/xfree86/modes/xf86Crtc.c index b08f57f34..47d3ad14c 100644 --- a/xorg-server/hw/xfree86/modes/xf86Crtc.c +++ b/xorg-server/hw/xfree86/modes/xf86Crtc.c @@ -1,3280 +1,3282 @@ -/* - * Copyright © 2006 Keith Packard - * Copyright © 2008 Red Hat, Inc. - * - * Permission to use, copy, modify, distribute, and sell this software and its - * documentation for any purpose is hereby granted without fee, provided that - * the above copyright notice appear in all copies and that both that copyright - * notice and this permission notice appear in supporting documentation, and - * that the name of the copyright holders not be used in advertising or - * publicity pertaining to distribution of the software without specific, - * written prior permission. The copyright holders make no representations - * about the suitability of this software for any purpose. It is provided "as - * is" without express or implied warranty. - * - * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, - * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO - * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR - * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, - * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER - * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE - * OF THIS SOFTWARE. - */ - -#ifdef HAVE_XORG_CONFIG_H -#include -#else -#ifdef HAVE_CONFIG_H -#include -#endif -#endif - -#include -#include -#include - -#include "xf86.h" -#include "xf86DDC.h" -#include "xf86Crtc.h" -#include "xf86Modes.h" -#include "xf86Priv.h" -#include "xf86RandR12.h" -#include "X11/extensions/render.h" -#include "X11/extensions/dpmsconst.h" -#include "X11/Xatom.h" -#include "picturestr.h" - -#include "xf86xv.h" - -#define NO_OUTPUT_DEFAULT_WIDTH 1024 -#define NO_OUTPUT_DEFAULT_HEIGHT 768 -/* - * Initialize xf86CrtcConfig structure - */ - -int xf86CrtcConfigPrivateIndex = -1; - -void -xf86CrtcConfigInit (ScrnInfoPtr scrn, - const xf86CrtcConfigFuncsRec *funcs) -{ - xf86CrtcConfigPtr config; - - if (xf86CrtcConfigPrivateIndex == -1) - xf86CrtcConfigPrivateIndex = xf86AllocateScrnInfoPrivateIndex(); - config = xnfcalloc (1, sizeof (xf86CrtcConfigRec)); - - config->funcs = funcs; - - scrn->privates[xf86CrtcConfigPrivateIndex].ptr = config; -} - -void -xf86CrtcSetSizeRange (ScrnInfoPtr scrn, - int minWidth, int minHeight, - int maxWidth, int maxHeight) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - - config->minWidth = minWidth; - config->minHeight = minHeight; - config->maxWidth = maxWidth; - config->maxHeight = maxHeight; -} - -void -xf86CrtcSetScanoutFormats(ScrnInfoPtr scrn, - int num_formats, - xf86CrtcScanoutFormat *formats) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - - config->num_scanout_formats = num_formats; - config->scanout_formats = formats; -} - -/* - * Crtc functions - */ -xf86CrtcPtr -xf86CrtcCreate (ScrnInfoPtr scrn, - const xf86CrtcFuncsRec *funcs) -{ - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); - xf86CrtcPtr crtc, *crtcs; - - crtc = calloc(sizeof (xf86CrtcRec), 1); - if (!crtc) - return NULL; - crtc->version = XF86_CRTC_VERSION; - crtc->scrn = scrn; - crtc->funcs = funcs; -#ifdef RANDR_12_INTERFACE - crtc->randr_crtc = NULL; -#endif - crtc->rotation = RR_Rotate_0; - crtc->desiredRotation = RR_Rotate_0; - pixman_transform_init_identity (&crtc->crtc_to_framebuffer); - pixman_f_transform_init_identity (&crtc->f_crtc_to_framebuffer); - pixman_f_transform_init_identity (&crtc->f_framebuffer_to_crtc); - pixman_f_transform_init_identity (&crtc->f_screen_to_crtc); - pixman_f_transform_init_identity (&crtc->user_sprite_position_transform); - pixman_f_transform_init_identity (&crtc->f_crtc_to_cursor); - pixman_f_transform_init_identity (&crtc->user_sprite_image_transform); - crtc->filter = NULL; - crtc->params = NULL; - crtc->nparams = 0; - crtc->filter_width = 0; - crtc->filter_height = 0; - crtc->transform_in_use = FALSE; - crtc->sprite_transform_in_use = FALSE; - crtc->transformPresent = FALSE; - crtc->desiredTransformPresent = FALSE; - memset (&crtc->bounds, '\0', sizeof (crtc->bounds)); - - /* Preallocate gamma at a sensible size. */ - crtc->gamma_size = 256; - crtc->gamma_red = malloc(3 * crtc->gamma_size * sizeof (CARD16)); - if (!crtc->gamma_red) { - free(crtc); - return NULL; - } - crtc->gamma_green = crtc->gamma_red + crtc->gamma_size; - crtc->gamma_blue = crtc->gamma_green + crtc->gamma_size; - - if (xf86_config->crtc) - crtcs = realloc(xf86_config->crtc, - (xf86_config->num_crtc + 1) * sizeof (xf86CrtcPtr)); - else - crtcs = malloc((xf86_config->num_crtc + 1) * sizeof (xf86CrtcPtr)); - if (!crtcs) - { - free(crtc); - return NULL; - } - xf86_config->crtc = crtcs; - xf86_config->crtc[xf86_config->num_crtc++] = crtc; - return crtc; -} - -void -xf86CrtcDestroy (xf86CrtcPtr crtc) -{ - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(crtc->scrn); - int c; - - (*crtc->funcs->destroy) (crtc); - for (c = 0; c < xf86_config->num_crtc; c++) - if (xf86_config->crtc[c] == crtc) - { - memmove (&xf86_config->crtc[c], - &xf86_config->crtc[c+1], - ((xf86_config->num_crtc - (c + 1)) * sizeof(void*))); - xf86_config->num_crtc--; - break; - } - free(crtc->params); - free(crtc->gamma_red); - free(crtc); -} - - -/** - * Return whether any outputs are connected to the specified pipe - */ - -Bool -xf86CrtcInUse (xf86CrtcPtr crtc) -{ - ScrnInfoPtr pScrn = crtc->scrn; - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); - int o; - - for (o = 0; o < xf86_config->num_output; o++) - if (xf86_config->output[o]->crtc == crtc) - return TRUE; - return FALSE; -} - -void -xf86CrtcSetScreenSubpixelOrder (ScreenPtr pScreen) -{ - int subpixel_order = SubPixelUnknown; - Bool has_none = FALSE; - ScrnInfoPtr scrn = xf86Screens[pScreen->myNum]; - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); - int c, o; - - for (c = 0; c < xf86_config->num_crtc; c++) - { - xf86CrtcPtr crtc = xf86_config->crtc[c]; - - for (o = 0; o < xf86_config->num_output; o++) - { - xf86OutputPtr output = xf86_config->output[o]; - - if (output->crtc == crtc) - { - switch (output->subpixel_order) { - case SubPixelNone: - has_none = TRUE; - break; - case SubPixelUnknown: - break; - default: - subpixel_order = output->subpixel_order; - break; - } - } - if (subpixel_order != SubPixelUnknown) - break; - } - if (subpixel_order != SubPixelUnknown) - { - static const int circle[4] = { - SubPixelHorizontalRGB, - SubPixelVerticalRGB, - SubPixelHorizontalBGR, - SubPixelVerticalBGR, - }; - int rotate; - int c; - for (rotate = 0; rotate < 4; rotate++) - if (crtc->rotation & (1 << rotate)) - break; - for (c = 0; c < 4; c++) - if (circle[c] == subpixel_order) - break; - c = (c + rotate) & 0x3; - if ((crtc->rotation & RR_Reflect_X) && !(c & 1)) - c ^= 2; - if ((crtc->rotation & RR_Reflect_Y) && (c & 1)) - c ^= 2; - subpixel_order = circle[c]; - break; - } - } - if (subpixel_order == SubPixelUnknown && has_none) - subpixel_order = SubPixelNone; - PictureSetSubpixelOrder (pScreen, subpixel_order); -} - -/** - * Sets the given video mode on the given crtc - */ -Bool -xf86CrtcSet(xf86CrtcPtr crtc, xf86CrtcSetRec *set) -{ - ScrnInfoPtr scrn = crtc->scrn; - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); - int i; - Bool ret = FALSE; - Bool didLock = FALSE; - DisplayModePtr adjusted_mode = NULL; - DisplayModeRec saved_mode; - int saved_x, saved_y; - Rotation saved_rotation; - RRTransformRec saved_transform; - Bool saved_transform_present; - PixmapPtr saved_scanout_pixmap; - - crtc->enabled = xf86CrtcInUse (crtc); - - /* We only hit this if someone explicitly sends a "disabled" modeset. */ - if (!crtc->enabled) - { - /* Check everything for stuff that should be off. */ - xf86DisableUnusedFunctions(scrn); - return TRUE; - } - - /* See if nothing has changed */ - if (!set->flags) - return TRUE; - - saved_mode = crtc->mode; - saved_x = crtc->x; - saved_y = crtc->y; - saved_rotation = crtc->rotation; - saved_scanout_pixmap = crtc->scanoutPixmap; - if (crtc->transformPresent) { - RRTransformInit (&saved_transform); - RRTransformCopy (&saved_transform, &crtc->transform); - } - saved_transform_present = crtc->transformPresent; - - /* Update crtc values up front so the driver can rely on them for mode - * setting. - */ - if (set->flags & XF86CrtcSetMode) - crtc->mode = *set->mode; - if (set->flags & XF86CrtcSetOrigin) { - crtc->x = set->x; - crtc->y = set->y; - } - if (set->flags & XF86CrtcSetRotation) - crtc->rotation = set->rotation; - if (set->flags & XF86CrtcSetScanoutPixmap) - crtc->scanoutPixmap = set->scanout_pixmap; - - if (set->flags & XF86CrtcSetTransform) { - if (set->transform) { - RRTransformCopy (&crtc->transform, set->transform); - crtc->transformPresent = TRUE; - } else - crtc->transformPresent = FALSE; - } - - if (crtc->funcs->set) { - ret = crtc->funcs->set(crtc, set->flags); - goto done; - } - - if (set->flags == XF86CrtcSetOrigin && crtc->funcs->set_origin) { - ret = xf86CrtcRotate(crtc); - if (ret) - crtc->funcs->set_origin(crtc, crtc->x, crtc->y); - goto done; - } - - if (crtc->funcs->set_mode_major) { - ret = crtc->funcs->set_mode_major(crtc, &crtc->mode, - crtc->rotation, - crtc->x, crtc->y); - goto done; - } - - adjusted_mode = xf86DuplicateMode(&crtc->mode); - - didLock = crtc->funcs->lock (crtc); - /* Pass our mode to the outputs and the CRTC to give them a chance to - * adjust it according to limitations or output properties, and also - * a chance to reject the mode entirely. - */ - for (i = 0; i < xf86_config->num_output; i++) { - xf86OutputPtr output = xf86_config->output[i]; - - if (output->crtc != crtc) - continue; - - if (!output->funcs->mode_fixup(output, &crtc->mode, adjusted_mode)) { - goto done; - } - } - - if (!crtc->funcs->mode_fixup(crtc, &crtc->mode, adjusted_mode)) { - goto done; - } - - if (!xf86CrtcRotate (crtc)) - goto done; - - /* Prepare the outputs and CRTCs before setting the mode. */ - for (i = 0; i < xf86_config->num_output; i++) { - xf86OutputPtr output = xf86_config->output[i]; - - if (output->crtc != crtc) - continue; - - /* Disable the output as the first thing we do. */ - output->funcs->prepare(output); - } - - crtc->funcs->prepare(crtc); - - /* Set up the DPLL and any output state that needs to adjust or depend - * on the DPLL. - */ - crtc->funcs->mode_set(crtc, &crtc->mode, adjusted_mode, crtc->x, crtc->y); - for (i = 0; i < xf86_config->num_output; i++) - { - xf86OutputPtr output = xf86_config->output[i]; - if (output->crtc == crtc) - output->funcs->mode_set(output, &crtc->mode, adjusted_mode); - } - - /* Only upload when needed, to avoid unneeded delays. */ - if (!crtc->active && crtc->funcs->gamma_set) - crtc->funcs->gamma_set(crtc, crtc->gamma_red, crtc->gamma_green, - crtc->gamma_blue, crtc->gamma_size); - - /* Now, enable the clocks, plane, pipe, and outputs that we set up. */ - crtc->funcs->commit(crtc); - for (i = 0; i < xf86_config->num_output; i++) - { - xf86OutputPtr output = xf86_config->output[i]; - if (output->crtc == crtc) - output->funcs->commit(output); - } - - ret = TRUE; - -done: - if (ret) { - crtc->active = TRUE; - if (scrn->pScreen) - xf86CrtcSetScreenSubpixelOrder (scrn->pScreen); - if (scrn->ModeSet) - scrn->ModeSet(scrn); - } else { - crtc->x = saved_x; - crtc->y = saved_y; - crtc->rotation = saved_rotation; - crtc->mode = saved_mode; - if (saved_transform_present) - RRTransformCopy (&crtc->transform, &saved_transform); - crtc->transformPresent = saved_transform_present; - crtc->scanoutPixmap = saved_scanout_pixmap; - } - - if (adjusted_mode) { - free(adjusted_mode->name); - free(adjusted_mode); - } - - if (didLock) - crtc->funcs->unlock (crtc); - - return ret; -} - -/** - * Pans the screen, does not change the mode - */ -void -xf86CrtcSetOrigin (xf86CrtcPtr crtc, int x, int y) -{ - xf86CrtcSetRec set; - - if (x != crtc->x || y != crtc->y) { - set.x = x; - set.y = y; - set.flags = XF86CrtcSetOrigin; - (void) xf86CrtcSet(crtc, &set); - } -} - -/* - * Output functions - */ - -extern XF86ConfigPtr xf86configptr; - -typedef enum { - OPTION_PREFERRED_MODE, - OPTION_POSITION, - OPTION_BELOW, - OPTION_RIGHT_OF, - OPTION_ABOVE, - OPTION_LEFT_OF, - OPTION_ENABLE, - OPTION_DISABLE, - OPTION_MIN_CLOCK, - OPTION_MAX_CLOCK, - OPTION_IGNORE, - OPTION_ROTATE, - OPTION_PANNING, - OPTION_PRIMARY, - OPTION_DEFAULT_MODES, -} OutputOpts; - -static OptionInfoRec xf86OutputOptions[] = { - {OPTION_PREFERRED_MODE, "PreferredMode", OPTV_STRING, {0}, FALSE }, - {OPTION_POSITION, "Position", OPTV_STRING, {0}, FALSE }, - {OPTION_BELOW, "Below", OPTV_STRING, {0}, FALSE }, - {OPTION_RIGHT_OF, "RightOf", OPTV_STRING, {0}, FALSE }, - {OPTION_ABOVE, "Above", OPTV_STRING, {0}, FALSE }, - {OPTION_LEFT_OF, "LeftOf", OPTV_STRING, {0}, FALSE }, - {OPTION_ENABLE, "Enable", OPTV_BOOLEAN, {0}, FALSE }, - {OPTION_DISABLE, "Disable", OPTV_BOOLEAN, {0}, FALSE }, - {OPTION_MIN_CLOCK, "MinClock", OPTV_FREQ, {0}, FALSE }, - {OPTION_MAX_CLOCK, "MaxClock", OPTV_FREQ, {0}, FALSE }, - {OPTION_IGNORE, "Ignore", OPTV_BOOLEAN, {0}, FALSE }, - {OPTION_ROTATE, "Rotate", OPTV_STRING, {0}, FALSE }, - {OPTION_PANNING, "Panning", OPTV_STRING, {0}, FALSE }, - {OPTION_PRIMARY, "Primary", OPTV_BOOLEAN, {0}, FALSE }, - {OPTION_DEFAULT_MODES, "DefaultModes", OPTV_BOOLEAN, {0}, FALSE }, - {-1, NULL, OPTV_NONE, {0}, FALSE }, -}; - -enum { - OPTION_MODEDEBUG, -}; - -static OptionInfoRec xf86DeviceOptions[] = { - {OPTION_MODEDEBUG, "ModeDebug", OPTV_BOOLEAN, {0}, FALSE }, - {-1, NULL, OPTV_NONE, {0}, FALSE }, -}; - -static void -xf86OutputSetMonitor (xf86OutputPtr output) -{ - char *option_name; - char *monitor; - - if (!output->name) - return; - - free(output->options); - - output->options = xnfalloc (sizeof (xf86OutputOptions)); - memcpy (output->options, xf86OutputOptions, sizeof (xf86OutputOptions)); - - XNFasprintf(&option_name, "monitor-%s", output->name); - monitor = xf86findOptionValue (output->scrn->options, option_name); - if (!monitor) - monitor = output->name; - else - xf86MarkOptionUsedByName (output->scrn->options, option_name); - free(option_name); - output->conf_monitor = xf86findMonitor (monitor, - xf86configptr->conf_monitor_lst); - /* - * Find the monitor section of the screen and use that - */ - if (!output->conf_monitor && output->use_screen_monitor) - output->conf_monitor = xf86findMonitor (output->scrn->monitor->id, - xf86configptr->conf_monitor_lst); - if (output->conf_monitor) - { - xf86DrvMsg (output->scrn->scrnIndex, X_INFO, - "Output %s using monitor section %s\n", - output->name, output->conf_monitor->mon_identifier); - xf86ProcessOptions (output->scrn->scrnIndex, - output->conf_monitor->mon_option_lst, - output->options); - } - else - xf86DrvMsg (output->scrn->scrnIndex, X_INFO, - "Output %s has no monitor section\n", - output->name); -} - -static Bool -xf86OutputEnabled (xf86OutputPtr output, Bool strict) -{ - Bool enable, disable; - - /* check to see if this output was enabled in the config file */ - if (xf86GetOptValBool (output->options, OPTION_ENABLE, &enable) && enable) - { - xf86DrvMsg (output->scrn->scrnIndex, X_INFO, - "Output %s enabled by config file\n", output->name); - return TRUE; - } - /* or if this output was disabled in the config file */ - if (xf86GetOptValBool (output->options, OPTION_DISABLE, &disable) && disable) - { - xf86DrvMsg (output->scrn->scrnIndex, X_INFO, - "Output %s disabled by config file\n", output->name); - return FALSE; - } - - /* If not, try to only light up the ones we know are connected */ - if (strict) { - enable = output->status == XF86OutputStatusConnected; - } - /* But if that fails, try to light up even outputs we're unsure of */ - else { - enable = output->status != XF86OutputStatusDisconnected; - } - - xf86DrvMsg (output->scrn->scrnIndex, X_INFO, - "Output %s %sconnected\n", output->name, enable ? "" : "dis"); - return enable; -} - -static Bool -xf86OutputIgnored (xf86OutputPtr output) -{ - return xf86ReturnOptValBool (output->options, OPTION_IGNORE, FALSE); -} - -static char *direction[4] = { - "normal", - "left", - "inverted", - "right" -}; - -static Rotation -xf86OutputInitialRotation (xf86OutputPtr output) -{ - char *rotate_name = xf86GetOptValString (output->options, - OPTION_ROTATE); - int i; - - if (!rotate_name) { - if (output->initial_rotation) - return output->initial_rotation; - return RR_Rotate_0; - } - - for (i = 0; i < 4; i++) - if (xf86nameCompare (direction[i], rotate_name) == 0) - return 1 << i; - return RR_Rotate_0; -} - -xf86OutputPtr -xf86OutputCreate (ScrnInfoPtr scrn, - const xf86OutputFuncsRec *funcs, - const char *name) -{ - xf86OutputPtr output, *outputs; - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); - int len; - Bool primary; - - if (name) - len = strlen (name) + 1; - else - len = 0; - - output = calloc(sizeof (xf86OutputRec) + len, 1); - if (!output) - return NULL; - output->scrn = scrn; - output->funcs = funcs; - if (name) - { - output->name = (char *) (output + 1); - strcpy (output->name, name); - } - output->subpixel_order = SubPixelUnknown; - /* - * Use the old per-screen monitor section for the first output - */ - output->use_screen_monitor = (xf86_config->num_output == 0); -#ifdef RANDR_12_INTERFACE - output->randr_output = NULL; -#endif - if (name) - { - xf86OutputSetMonitor (output); - if (xf86OutputIgnored (output)) - { - free(output); - return FALSE; - } - } - - - if (xf86_config->output) - outputs = realloc(xf86_config->output, - (xf86_config->num_output + 1) * sizeof (xf86OutputPtr)); - else - outputs = malloc((xf86_config->num_output + 1) * sizeof (xf86OutputPtr)); - if (!outputs) - { - free(output); - return NULL; - } - - xf86_config->output = outputs; - - if (xf86GetOptValBool (output->options, OPTION_PRIMARY, &primary) && primary) - { - memmove(xf86_config->output + 1, xf86_config->output, - xf86_config->num_output * sizeof (xf86OutputPtr)); - xf86_config->output[0] = output; - } - else - { - xf86_config->output[xf86_config->num_output] = output; - } - - xf86_config->num_output++; - - return output; -} - -Bool -xf86OutputRename (xf86OutputPtr output, const char *name) -{ - char *newname = strdup(name); - - if (!newname) - return FALSE; /* so sorry... */ - - if (output->name && output->name != (char *) (output + 1)) - free(output->name); - output->name = newname; - xf86OutputSetMonitor (output); - if (xf86OutputIgnored (output)) - return FALSE; - return TRUE; -} - -void -xf86OutputUseScreenMonitor (xf86OutputPtr output, Bool use_screen_monitor) -{ - if (use_screen_monitor != output->use_screen_monitor) - { - output->use_screen_monitor = use_screen_monitor; - xf86OutputSetMonitor (output); - } -} - -void -xf86OutputDestroy (xf86OutputPtr output) -{ - ScrnInfoPtr scrn = output->scrn; - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); - int o; - - (*output->funcs->destroy) (output); - while (output->probed_modes) - xf86DeleteMode (&output->probed_modes, output->probed_modes); - for (o = 0; o < xf86_config->num_output; o++) - if (xf86_config->output[o] == output) - { - memmove (&xf86_config->output[o], - &xf86_config->output[o+1], - ((xf86_config->num_output - (o + 1)) * sizeof(void*))); - xf86_config->num_output--; - break; - } - if (output->name && output->name != (char *) (output + 1)) - free(output->name); - free(output); -} - -/* - * Called during CreateScreenResources to hook up RandR - */ -static Bool -xf86CrtcCreateScreenResources (ScreenPtr screen) -{ - ScrnInfoPtr scrn = xf86Screens[screen->myNum]; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - - screen->CreateScreenResources = config->CreateScreenResources; - - if (!(*screen->CreateScreenResources)(screen)) - return FALSE; - - if (!xf86RandR12CreateScreenResources (screen)) - return FALSE; - - return TRUE; -} - -/* - * Clean up config on server reset - */ -static Bool -xf86CrtcCloseScreen (int index, ScreenPtr screen) -{ - ScrnInfoPtr scrn = xf86Screens[screen->myNum]; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o, c; - - screen->CloseScreen = config->CloseScreen; - - xf86RotateCloseScreen (screen); - - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - - output->randr_output = NULL; - } - for (c = 0; c < config->num_crtc; c++) - { - xf86CrtcPtr crtc = config->crtc[c]; - - crtc->randr_crtc = NULL; - } - xf86RandR12CloseScreen (screen); - - return screen->CloseScreen (index, screen); -} - -/* - * Called at ScreenInit time to set up - */ -#ifdef RANDR_13_INTERFACE -int -#else -Bool -#endif -xf86CrtcScreenInit (ScreenPtr screen) -{ - ScrnInfoPtr scrn = xf86Screens[screen->myNum]; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int c; - - /* Rotation */ - xf86DrvMsg(scrn->scrnIndex, X_INFO, "RandR 1.2 enabled, ignore the following RandR disabled message.\n"); - xf86DisableRandR(); /* Disable old RandR extension support */ - xf86RandR12Init (screen); - - /* support all rotations if every crtc has the shadow alloc funcs */ - for (c = 0; c < config->num_crtc; c++) - { - xf86CrtcPtr crtc = config->crtc[c]; - if (!crtc->funcs->shadow_allocate || !crtc->funcs->shadow_create) - break; - } - if (c == config->num_crtc) - { - xf86RandR12SetRotations (screen, RR_Rotate_0 | RR_Rotate_90 | - RR_Rotate_180 | RR_Rotate_270 | - RR_Reflect_X | RR_Reflect_Y); - xf86RandR12SetTransformSupport (screen, TRUE); - } - else - { - xf86RandR12SetRotations (screen, RR_Rotate_0); - xf86RandR12SetTransformSupport (screen, FALSE); - } - - /* Wrap CreateScreenResources so we can initialize the RandR code */ - config->CreateScreenResources = screen->CreateScreenResources; - screen->CreateScreenResources = xf86CrtcCreateScreenResources; - - config->CloseScreen = screen->CloseScreen; - screen->CloseScreen = xf86CrtcCloseScreen; - -#ifdef XFreeXDGA - _xf86_di_dga_init_internal(screen); -#endif -#ifdef RANDR_13_INTERFACE - return RANDR_INTERFACE_VERSION; -#else - return TRUE; -#endif -} - -static DisplayModePtr -xf86DefaultMode (xf86OutputPtr output, int width, int height) -{ - DisplayModePtr target_mode = NULL; - DisplayModePtr mode; - int target_diff = 0; - int target_preferred = 0; - int mm_height; - - mm_height = output->mm_height; - if (!mm_height) - mm_height = (768 * 25.4) / DEFAULT_DPI; - /* - * Pick a mode closest to DEFAULT_DPI - */ - for (mode = output->probed_modes; mode; mode = mode->next) - { - int dpi; - int preferred = (((mode->type & M_T_PREFERRED) != 0) + - ((mode->type & M_T_USERPREF) != 0)); - int diff; - - if (xf86ModeWidth (mode, output->initial_rotation) > width || - xf86ModeHeight (mode, output->initial_rotation) > height) - continue; - - /* yes, use VDisplay here, not xf86ModeHeight */ - dpi = (mode->VDisplay * 254) / (mm_height * 10); - diff = dpi - DEFAULT_DPI; - diff = diff < 0 ? -diff : diff; - if (target_mode == NULL || (preferred > target_preferred) || - (preferred == target_preferred && diff < target_diff)) - { - target_mode = mode; - target_diff = diff; - target_preferred = preferred; - } - } - return target_mode; -} - -static DisplayModePtr -xf86ClosestMode (xf86OutputPtr output, - DisplayModePtr match, Rotation match_rotation, - int width, int height) -{ - DisplayModePtr target_mode = NULL; - DisplayModePtr mode; - int target_diff = 0; - - /* - * Pick a mode closest to the specified mode - */ - for (mode = output->probed_modes; mode; mode = mode->next) - { - int dx, dy; - int diff; - - if (xf86ModeWidth (mode, output->initial_rotation) > width || - xf86ModeHeight (mode, output->initial_rotation) > height) - continue; - - /* exact matches are preferred */ - if (output->initial_rotation == match_rotation && - xf86ModesEqual (mode, match)) - return mode; - - dx = xf86ModeWidth (match, match_rotation) - xf86ModeWidth (mode, output->initial_rotation); - dy = xf86ModeHeight (match, match_rotation) - xf86ModeHeight (mode, output->initial_rotation); - diff = dx * dx + dy * dy; - if (target_mode == NULL || diff < target_diff) - { - target_mode = mode; - target_diff = diff; - } - } - return target_mode; -} - -static DisplayModePtr -xf86OutputHasPreferredMode (xf86OutputPtr output, int width, int height) -{ - DisplayModePtr mode; - - for (mode = output->probed_modes; mode; mode = mode->next) - { - if (xf86ModeWidth (mode, output->initial_rotation) > width || - xf86ModeHeight (mode, output->initial_rotation) > height) - continue; - - if (mode->type & M_T_PREFERRED) - return mode; - } - return NULL; -} - -static DisplayModePtr -xf86OutputHasUserPreferredMode (xf86OutputPtr output) -{ - DisplayModePtr mode, first = output->probed_modes; - - for (mode = first; mode && mode->next != first; mode = mode->next) - if (mode->type & M_T_USERPREF) - return mode; - - return NULL; -} - -static int -xf86PickCrtcs (ScrnInfoPtr scrn, - xf86CrtcPtr *best_crtcs, - DisplayModePtr *modes, - int n, - int width, - int height) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int c, o; - xf86OutputPtr output; - xf86CrtcPtr crtc; - xf86CrtcPtr *crtcs; - xf86CrtcPtr best_crtc; - int best_score; - int score; - int my_score; - - if (n == config->num_output) - return 0; - output = config->output[n]; - - /* - * Compute score with this output disabled - */ - best_crtcs[n] = NULL; - best_crtc = NULL; - best_score = xf86PickCrtcs (scrn, best_crtcs, modes, n+1, width, height); - if (modes[n] == NULL) - return best_score; - - crtcs = malloc(config->num_output * sizeof (xf86CrtcPtr)); - if (!crtcs) - return best_score; - - my_score = 1; - /* Score outputs that are known to be connected higher */ - if (output->status == XF86OutputStatusConnected) - my_score++; - /* Score outputs with preferred modes higher */ - if (xf86OutputHasPreferredMode (output, width, height)) - my_score++; - /* - * Select a crtc for this output and - * then attempt to configure the remaining - * outputs - */ - for (c = 0; c < config->num_crtc; c++) - { - if ((output->possible_crtcs & (1 << c)) == 0) - continue; - - crtc = config->crtc[c]; - /* - * Check to see if some other output is - * using this crtc - */ - for (o = 0; o < n; o++) - if (best_crtcs[o] == crtc) - break; - if (o < n) - { - /* - * If the two outputs desire the same mode, - * see if they can be cloned - */ - if (xf86ModesEqual (modes[o], modes[n]) && - config->output[o]->initial_rotation == config->output[n]->initial_rotation && - config->output[o]->initial_x == config->output[n]->initial_x && - config->output[o]->initial_y == config->output[n]->initial_y) - { - if ((output->possible_clones & (1 << o)) == 0) - continue; /* nope, try next CRTC */ - } - else - continue; /* different modes, can't clone */ - } - crtcs[n] = crtc; - memcpy (crtcs, best_crtcs, n * sizeof (xf86CrtcPtr)); - score = my_score + xf86PickCrtcs (scrn, crtcs, modes, n+1, width, height); - if (score > best_score) - { - best_crtc = crtc; - best_score = score; - memcpy (best_crtcs, crtcs, config->num_output * sizeof (xf86CrtcPtr)); - } - } - free(crtcs); - return best_score; -} - - -/* - * Compute the virtual size necessary to place all of the available - * crtcs in the specified configuration. - * - * canGrow indicates that the driver can make the screen larger than its initial - * configuration. If FALSE, this function will enlarge the screen to include - * the largest available mode. - */ - -static void -xf86DefaultScreenLimits (ScrnInfoPtr scrn, int *widthp, int *heightp, - Bool canGrow) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int width = 0, height = 0; - int o; - int c; - int s; - - for (c = 0; c < config->num_crtc; c++) - { - int crtc_width = 0, crtc_height = 0; - xf86CrtcPtr crtc = config->crtc[c]; - - if (crtc->enabled) - { - crtc_width = crtc->desiredX + xf86ModeWidth (&crtc->desiredMode, crtc->desiredRotation); - crtc_height = crtc->desiredY + xf86ModeHeight (&crtc->desiredMode, crtc->desiredRotation); - } - if (!canGrow) { - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - - for (s = 0; s < config->num_crtc; s++) - if (output->possible_crtcs & (1 << s)) - { - DisplayModePtr mode; - for (mode = output->probed_modes; mode; mode = mode->next) - { - if (mode->HDisplay > crtc_width) - crtc_width = mode->HDisplay; - if (mode->VDisplay > crtc_width) - crtc_width = mode->VDisplay; - if (mode->VDisplay > crtc_height) - crtc_height = mode->VDisplay; - if (mode->HDisplay > crtc_height) - crtc_height = mode->HDisplay; - } - } - } - } - if (crtc_width > width) - width = crtc_width; - if (crtc_height > height) - height = crtc_height; - } - if (config->maxWidth && width > config->maxWidth) width = config->maxWidth; - if (config->maxHeight && height > config->maxHeight) height = config->maxHeight; - if (config->minWidth && width < config->minWidth) width = config->minWidth; - if (config->minHeight && height < config->minHeight) height = config->minHeight; - *widthp = width; - *heightp = height; -} - -#define POSITION_UNSET -100000 - -/* - * check if the user configured any outputs at all - * with either a position or a relative setting or a mode. - */ -static Bool -xf86UserConfiguredOutputs(ScrnInfoPtr scrn, DisplayModePtr *modes) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o; - Bool user_conf = FALSE; - - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - char *position; - char *relative_name; - OutputOpts relation; - int r; - static const OutputOpts relations[] = { - OPTION_BELOW, OPTION_RIGHT_OF, OPTION_ABOVE, OPTION_LEFT_OF - }; - - position = xf86GetOptValString (output->options, - OPTION_POSITION); - if (position) - user_conf = TRUE; - - relation = 0; - relative_name = NULL; - for (r = 0; r < 4; r++) - { - relation = relations[r]; - relative_name = xf86GetOptValString (output->options, - relation); - if (relative_name) - break; - } - if (relative_name) - user_conf = TRUE; - - modes[o] = xf86OutputHasUserPreferredMode(output); - if (modes[o]) - user_conf = TRUE; - } - - return user_conf; -} - -static Bool -xf86InitialOutputPositions (ScrnInfoPtr scrn, DisplayModePtr *modes) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o; - int min_x, min_y; - - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - - output->initial_x = output->initial_y = POSITION_UNSET; - } - - /* - * Loop until all outputs are set - */ - for (;;) - { - Bool any_set = FALSE; - Bool keep_going = FALSE; - - for (o = 0; o < config->num_output; o++) - { - static const OutputOpts relations[] = { - OPTION_BELOW, OPTION_RIGHT_OF, OPTION_ABOVE, OPTION_LEFT_OF - }; - xf86OutputPtr output = config->output[o]; - xf86OutputPtr relative; - char *relative_name; - char *position; - OutputOpts relation; - int r; - - if (output->initial_x != POSITION_UNSET) - continue; - position = xf86GetOptValString (output->options, - OPTION_POSITION); - /* - * Absolute position wins - */ - if (position) - { - int x, y; - if (sscanf (position, "%d %d", &x, &y) == 2) - { - output->initial_x = x; - output->initial_y = y; - } - else - { - xf86DrvMsg (scrn->scrnIndex, X_ERROR, - "Output %s position not of form \"x y\"\n", - output->name); - output->initial_x = output->initial_y = 0; - } - any_set = TRUE; - continue; - } - /* - * Next comes relative positions - */ - relation = 0; - relative_name = NULL; - for (r = 0; r < 4; r++) - { - relation = relations[r]; - relative_name = xf86GetOptValString (output->options, - relation); - if (relative_name) - break; - } - if (relative_name) - { - int or; - relative = NULL; - for (or = 0; or < config->num_output; or++) - { - xf86OutputPtr out_rel = config->output[or]; - XF86ConfMonitorPtr rel_mon = out_rel->conf_monitor; - - if (rel_mon) - { - if (xf86nameCompare (rel_mon->mon_identifier, - relative_name) == 0) - { - relative = config->output[or]; - break; - } - } - if (strcmp (out_rel->name, relative_name) == 0) - { - relative = config->output[or]; - break; - } - } - if (!relative) - { - xf86DrvMsg (scrn->scrnIndex, X_ERROR, - "Cannot position output %s relative to unknown output %s\n", - output->name, relative_name); - output->initial_x = 0; - output->initial_y = 0; - any_set = TRUE; - continue; - } - if (!modes[or]) - { - xf86DrvMsg (scrn->scrnIndex, X_ERROR, - "Cannot position output %s relative to output %s without modes\n", - output->name, relative_name); - output->initial_x = 0; - output->initial_y = 0; - any_set = TRUE; - continue; - } - if (relative->initial_x == POSITION_UNSET) - { - keep_going = TRUE; - continue; - } - output->initial_x = relative->initial_x; - output->initial_y = relative->initial_y; - switch (relation) { - case OPTION_BELOW: - output->initial_y += xf86ModeHeight (modes[or], relative->initial_rotation); - break; - case OPTION_RIGHT_OF: - output->initial_x += xf86ModeWidth (modes[or], relative->initial_rotation); - break; - case OPTION_ABOVE: - if (modes[o]) - output->initial_y -= xf86ModeHeight (modes[o], output->initial_rotation); - break; - case OPTION_LEFT_OF: - if (modes[o]) - output->initial_x -= xf86ModeWidth (modes[o], output->initial_rotation); - break; - default: - break; - } - any_set = TRUE; - continue; - } - - /* Nothing set, just stick them at 0,0 */ - output->initial_x = 0; - output->initial_y = 0; - any_set = TRUE; - } - if (!keep_going) - break; - if (!any_set) - { - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - if (output->initial_x == POSITION_UNSET) - { - xf86DrvMsg (scrn->scrnIndex, X_ERROR, - "Output position loop. Moving %s to 0,0\n", - output->name); - output->initial_x = output->initial_y = 0; - break; - } - } - } - } - - /* - * normalize positions - */ - min_x = 1000000; - min_y = 1000000; - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - - if (output->initial_x < min_x) - min_x = output->initial_x; - if (output->initial_y < min_y) - min_y = output->initial_y; - } - - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - - output->initial_x -= min_x; - output->initial_y -= min_y; - } - return TRUE; -} - -static void -xf86InitialPanning (ScrnInfoPtr scrn) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o; - - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - char *panning = xf86GetOptValString (output->options, OPTION_PANNING); - int width, height, left, top; - int track_width, track_height, track_left, track_top; - int brdr[4]; - - memset (&output->initialTotalArea, 0, sizeof(BoxRec)); - memset (&output->initialTrackingArea, 0, sizeof(BoxRec)); - memset (output->initialBorder, 0, 4*sizeof(INT16)); - - if (! panning) - continue; - - switch (sscanf (panning, "%dx%d+%d+%d/%dx%d+%d+%d/%d/%d/%d/%d", - &width, &height, &left, &top, - &track_width, &track_height, &track_left, &track_top, - &brdr[0], &brdr[1], &brdr[2], &brdr[3])) { - case 12: - output->initialBorder[0] = brdr[0]; - output->initialBorder[1] = brdr[1]; - output->initialBorder[2] = brdr[2]; - output->initialBorder[3] = brdr[3]; - /* fall through */ - case 8: - output->initialTrackingArea.x1 = track_left; - output->initialTrackingArea.y1 = track_top; - output->initialTrackingArea.x2 = track_left + track_width; - output->initialTrackingArea.y2 = track_top + track_height; - /* fall through */ - case 4: - output->initialTotalArea.x1 = left; - output->initialTotalArea.y1 = top; - /* fall through */ - case 2: - output->initialTotalArea.x2 = output->initialTotalArea.x1 + width; - output->initialTotalArea.y2 = output->initialTotalArea.y1 + height; - break; - default: - xf86DrvMsg (scrn->scrnIndex, X_ERROR, - "Broken panning specification '%s' for output %s in config file\n", - panning, output->name); - } - } -} - -/** Return - 0 + if a should be earlier, same or later than b in list - */ -static int -xf86ModeCompare (DisplayModePtr a, DisplayModePtr b) -{ - int diff; - - diff = ((b->type & M_T_PREFERRED) != 0) - ((a->type & M_T_PREFERRED) != 0); - if (diff) - return diff; - diff = b->HDisplay * b->VDisplay - a->HDisplay * a->VDisplay; - if (diff) - return diff; - diff = b->Clock - a->Clock; - return diff; -} - -/** - * Insertion sort input in-place and return the resulting head - */ -static DisplayModePtr -xf86SortModes (DisplayModePtr input) -{ - DisplayModePtr output = NULL, i, o, n, *op, prev; - - /* sort by preferred status and pixel area */ - while (input) - { - i = input; - input = input->next; - for (op = &output; (o = *op); op = &o->next) - if (xf86ModeCompare (o, i) > 0) - break; - i->next = *op; - *op = i; - } - /* prune identical modes */ - for (o = output; o && (n = o->next); o = n) - { - if (!strcmp (o->name, n->name) && xf86ModesEqual (o, n)) - { - o->next = n->next; - free(n->name); - free(n); - n = o; - } - } - /* hook up backward links */ - prev = NULL; - for (o = output; o; o = o->next) - { - o->prev = prev; - prev = o; - } - return output; -} - -static char * -preferredMode(ScrnInfoPtr pScrn, xf86OutputPtr output) -{ - char *preferred_mode = NULL; - - /* Check for a configured preference for a particular mode */ - preferred_mode = xf86GetOptValString (output->options, - OPTION_PREFERRED_MODE); - if (preferred_mode) - return preferred_mode; - - if (pScrn->display->modes && *pScrn->display->modes) - preferred_mode = *pScrn->display->modes; - - return preferred_mode; -} - -static void -GuessRangeFromModes(MonPtr mon, DisplayModePtr mode) -{ - if (!mon || !mode) - return; - - mon->nHsync = 1; - mon->hsync[0].lo = 1024.0; - mon->hsync[0].hi = 0.0; - - mon->nVrefresh = 1; - mon->vrefresh[0].lo = 1024.0; - mon->vrefresh[0].hi = 0.0; - - while (mode) { - if (!mode->HSync) - mode->HSync = ((float) mode->Clock ) / ((float) mode->HTotal); - - if (!mode->VRefresh) - mode->VRefresh = (1000.0 * ((float) mode->Clock)) / - ((float) (mode->HTotal * mode->VTotal)); - - if (mode->HSync < mon->hsync[0].lo) - mon->hsync[0].lo = mode->HSync; - - if (mode->HSync > mon->hsync[0].hi) - mon->hsync[0].hi = mode->HSync; - - if (mode->VRefresh < mon->vrefresh[0].lo) - mon->vrefresh[0].lo = mode->VRefresh; - - if (mode->VRefresh > mon->vrefresh[0].hi) - mon->vrefresh[0].hi = mode->VRefresh; - - mode = mode->next; - } - - /* stretch out the bottom to fit 640x480@60 */ - if (mon->hsync[0].lo > 31.0) - mon->hsync[0].lo = 31.0; - if (mon->vrefresh[0].lo > 58.0) - mon->vrefresh[0].lo = 58.0; -} - -enum det_monrec_source { - sync_config, sync_edid, sync_default -}; - -struct det_monrec_parameter { - MonRec *mon_rec; - int *max_clock; - Bool set_hsync; - Bool set_vrefresh; - enum det_monrec_source *sync_source; -}; - -static void handle_detailed_monrec(struct detailed_monitor_section *det_mon, - void *data) -{ - enum { sync_config, sync_edid, sync_default }; - struct det_monrec_parameter *p; - p = (struct det_monrec_parameter *)data; - - if (det_mon->type == DS_RANGES) { - struct monitor_ranges *ranges = &det_mon->section.ranges; - if (p->set_hsync && ranges->max_h) { - p->mon_rec->hsync[p->mon_rec->nHsync].lo = ranges->min_h; - p->mon_rec->hsync[p->mon_rec->nHsync].hi = ranges->max_h; - p->mon_rec->nHsync++; - if (*p->sync_source == sync_default) - *p->sync_source = sync_edid; - } - if (p->set_vrefresh && ranges->max_v) { - p->mon_rec->vrefresh[p->mon_rec->nVrefresh].lo = ranges->min_v; - p->mon_rec->vrefresh[p->mon_rec->nVrefresh].hi = ranges->max_v; - p->mon_rec->nVrefresh++; - if (*p->sync_source == sync_default) - *p->sync_source = sync_edid; - } - if (ranges->max_clock * 1000 > *p->max_clock) - *p->max_clock = ranges->max_clock * 1000; - } -} - -void -xf86ProbeOutputModes (ScrnInfoPtr scrn, int maxX, int maxY) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o; - - /* When canGrow was TRUE in the initial configuration we have to - * compare against the maximum values so that we don't drop modes. - * When canGrow was FALSE, the maximum values would have been clamped - * anyway. - */ - if (maxX == 0 || maxY == 0) { - maxX = config->maxWidth; - maxY = config->maxHeight; - } - - /* Probe the list of modes for each output. */ - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - DisplayModePtr mode; - DisplayModePtr config_modes = NULL, output_modes, default_modes = NULL; - char *preferred_mode; - xf86MonPtr edid_monitor; - XF86ConfMonitorPtr conf_monitor; - MonRec mon_rec; - int min_clock = 0; - int max_clock = 0; - double clock; - Bool add_default_modes = xf86ReturnOptValBool(output->options, OPTION_DEFAULT_MODES, TRUE); - Bool debug_modes = config->debug_modes || - xf86Initialising; - enum det_monrec_source sync_source = sync_default; - - while (output->probed_modes != NULL) - xf86DeleteMode(&output->probed_modes, output->probed_modes); - - /* - * Check connection status - */ - output->status = (*output->funcs->detect)(output); - - if (output->status == XF86OutputStatusDisconnected && - !xf86ReturnOptValBool(output->options, OPTION_ENABLE, FALSE)) - { - xf86OutputSetEDID (output, NULL); - continue; - } - - memset (&mon_rec, '\0', sizeof (mon_rec)); - - conf_monitor = output->conf_monitor; - - if (conf_monitor) - { - int i; - - for (i = 0; i < conf_monitor->mon_n_hsync; i++) - { - mon_rec.hsync[mon_rec.nHsync].lo = conf_monitor->mon_hsync[i].lo; - mon_rec.hsync[mon_rec.nHsync].hi = conf_monitor->mon_hsync[i].hi; - mon_rec.nHsync++; - sync_source = sync_config; - } - for (i = 0; i < conf_monitor->mon_n_vrefresh; i++) - { - mon_rec.vrefresh[mon_rec.nVrefresh].lo = conf_monitor->mon_vrefresh[i].lo; - mon_rec.vrefresh[mon_rec.nVrefresh].hi = conf_monitor->mon_vrefresh[i].hi; - mon_rec.nVrefresh++; - sync_source = sync_config; - } - config_modes = xf86GetMonitorModes (scrn, conf_monitor); - } - - output_modes = (*output->funcs->get_modes) (output); - - edid_monitor = output->MonInfo; - - if (edid_monitor) - { - struct det_monrec_parameter p; - struct disp_features *features = &edid_monitor->features; - - /* if display is not continuous-frequency, don't add default modes */ - if (!GTF_SUPPORTED(features->msc)) - add_default_modes = FALSE; - - p.mon_rec = &mon_rec; - p.max_clock = &max_clock; - p.set_hsync = mon_rec.nHsync == 0; - p.set_vrefresh = mon_rec.nVrefresh == 0; - p.sync_source = &sync_source; - - xf86ForEachDetailedBlock(edid_monitor, - handle_detailed_monrec, - &p); - } - - if (xf86GetOptValFreq (output->options, OPTION_MIN_CLOCK, - OPTUNITS_KHZ, &clock)) - min_clock = (int) clock; - if (xf86GetOptValFreq (output->options, OPTION_MAX_CLOCK, - OPTUNITS_KHZ, &clock)) - max_clock = (int) clock; - - /* If we still don't have a sync range, guess wildly */ - if (!mon_rec.nHsync || !mon_rec.nVrefresh) - GuessRangeFromModes(&mon_rec, output_modes); - - /* - * These limits will end up setting a 1024x768@60Hz mode by default, - * which seems like a fairly good mode to use when nothing else is - * specified - */ - if (mon_rec.nHsync == 0) - { - mon_rec.hsync[0].lo = 31.0; - mon_rec.hsync[0].hi = 55.0; - mon_rec.nHsync = 1; - } - if (mon_rec.nVrefresh == 0) - { - mon_rec.vrefresh[0].lo = 58.0; - mon_rec.vrefresh[0].hi = 62.0; - mon_rec.nVrefresh = 1; - } - - if (add_default_modes) - default_modes = xf86GetDefaultModes (); - - /* - * If this is not an RB monitor, remove RB modes from the default - * pool. RB modes from the config or the monitor itself are fine. - */ - if (!mon_rec.reducedblanking) - xf86ValidateModesReducedBlanking (scrn, default_modes); - - if (sync_source == sync_config) - { - /* - * Check output and config modes against sync range from config file - */ - xf86ValidateModesSync (scrn, output_modes, &mon_rec); - xf86ValidateModesSync (scrn, config_modes, &mon_rec); - } - /* - * Check default modes against sync range - */ - xf86ValidateModesSync (scrn, default_modes, &mon_rec); - /* - * Check default modes against monitor max clock - */ - if (max_clock) { - xf86ValidateModesClocks(scrn, default_modes, - &min_clock, &max_clock, 1); - xf86ValidateModesClocks(scrn, output_modes, - &min_clock, &max_clock, 1); - } - - output->probed_modes = NULL; - output->probed_modes = xf86ModesAdd (output->probed_modes, config_modes); - output->probed_modes = xf86ModesAdd (output->probed_modes, output_modes); - output->probed_modes = xf86ModesAdd (output->probed_modes, default_modes); - - /* - * Check all modes against max size, interlace, and doublescan - */ - if (maxX && maxY) - xf86ValidateModesSize (scrn, output->probed_modes, - maxX, maxY, 0); - - { - int flags = (output->interlaceAllowed ? V_INTERLACE : 0) | - (output->doubleScanAllowed ? V_DBLSCAN : 0); - xf86ValidateModesFlags (scrn, output->probed_modes, flags); - } - - /* - * Check all modes against output - */ - for (mode = output->probed_modes; mode != NULL; mode = mode->next) - if (mode->status == MODE_OK) - mode->status = (*output->funcs->mode_valid)(output, mode); - - xf86PruneInvalidModes(scrn, &output->probed_modes, debug_modes); - - output->probed_modes = xf86SortModes (output->probed_modes); - - /* Check for a configured preference for a particular mode */ - preferred_mode = preferredMode(scrn, output); - - if (preferred_mode) - { - for (mode = output->probed_modes; mode; mode = mode->next) - { - if (!strcmp (preferred_mode, mode->name)) - { - if (mode != output->probed_modes) - { - if (mode->prev) - mode->prev->next = mode->next; - if (mode->next) - mode->next->prev = mode->prev; - mode->next = output->probed_modes; - output->probed_modes->prev = mode; - mode->prev = NULL; - output->probed_modes = mode; - } - mode->type |= (M_T_PREFERRED|M_T_USERPREF); - break; - } - } - } - - output->initial_rotation = xf86OutputInitialRotation (output); - - if (debug_modes) { - if (output->probed_modes != NULL) { - xf86DrvMsg(scrn->scrnIndex, X_INFO, - "Printing probed modes for output %s\n", - output->name); - } else { - xf86DrvMsg(scrn->scrnIndex, X_INFO, - "No remaining probed modes for output %s\n", - output->name); - } - } - for (mode = output->probed_modes; mode != NULL; mode = mode->next) - { - /* The code to choose the best mode per pipe later on will require - * VRefresh to be set. - */ - mode->VRefresh = xf86ModeVRefresh(mode); - xf86SetModeCrtc(mode, INTERLACE_HALVE_V); - - if (debug_modes) - xf86PrintModeline(scrn->scrnIndex, mode); - } - } -} - - -/** - * Copy one of the output mode lists to the ScrnInfo record - */ - -/* XXX where does this function belong? Here? */ -void -xf86RandR12GetOriginalVirtualSize(ScrnInfoPtr scrn, int *x, int *y); - -static DisplayModePtr -biggestMode(DisplayModePtr a, DisplayModePtr b) -{ - int A, B; - - if (!a) - return b; - if (!b) - return a; - - A = a->HDisplay * a->VDisplay; - B = b->HDisplay * b->VDisplay; - - if (A > B) - return a; - - return b; -} - -static xf86OutputPtr -SetCompatOutput(xf86CrtcConfigPtr config) -{ - xf86OutputPtr output = NULL, test = NULL; - DisplayModePtr maxmode = NULL, testmode, mode; - int o, compat = -1, count, mincount = 0; - - /* Look for one that's definitely connected */ - for (o = 0; o < config->num_output; o++) - { - test = config->output[o]; - if (!test->crtc) - continue; - if (test->status != XF86OutputStatusConnected) - continue; - if (!test->probed_modes) - continue; - - testmode = mode = test->probed_modes; - for (count = 0; mode; mode = mode->next, count++) - testmode = biggestMode(testmode, mode); - - if (!output) { - output = test; - compat = o; - maxmode = testmode; - mincount = count; - } else if (maxmode == biggestMode(maxmode, testmode)) { - output = test; - compat = o; - maxmode = testmode; - mincount = count; - } else if ((maxmode->HDisplay == testmode->HDisplay) && - (maxmode->VDisplay == testmode->VDisplay) && - count <= mincount) { - output = test; - compat = o; - maxmode = testmode; - mincount = count; - } - } - - /* If we didn't find one, take anything we can get */ - if (!output) - { - for (o = 0; o < config->num_output; o++) - { - test = config->output[o]; - if (!test->crtc) - continue; - if (!test->probed_modes) - continue; - - if (!output) { - output = test; - compat = o; - } else if (test->probed_modes->HDisplay < output->probed_modes->HDisplay) { - output = test; - compat = o; - } - } - } - - if (compat >= 0) { - config->compat_output = compat; - } else { - /* Don't change the compat output when no valid outputs found */ - output = config->output[config->compat_output]; - } - - return output; -} - -void -xf86SetScrnInfoModes (ScrnInfoPtr scrn) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - xf86OutputPtr output; - xf86CrtcPtr crtc; - DisplayModePtr last, mode = NULL; - - output = SetCompatOutput(config); - - if (!output) - return; /* punt */ - - crtc = output->crtc; - - /* Clear any existing modes from scrn->modes */ - while (scrn->modes != NULL) - xf86DeleteMode(&scrn->modes, scrn->modes); - - /* Set scrn->modes to the mode list for the 'compat' output */ - scrn->modes = xf86DuplicateModes(scrn, output->probed_modes); - - if (crtc) { - for (mode = scrn->modes; mode; mode = mode->next) - if (xf86ModesEqual (mode, &crtc->desiredMode)) - break; - } - - if (scrn->modes != NULL) { - /* For some reason, scrn->modes is circular, unlike the other mode - * lists. How great is that? - */ - for (last = scrn->modes; last && last->next; last = last->next) - ; - last->next = scrn->modes; - scrn->modes->prev = last; - if (mode) { - while (scrn->modes != mode) - scrn->modes = scrn->modes->next; - } - } - scrn->currentMode = scrn->modes; -#ifdef XFreeXDGA - if (scrn->pScreen) - _xf86_di_dga_reinit_internal(scrn->pScreen); -#endif -} - -static Bool -xf86CollectEnabledOutputs(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, - Bool *enabled) -{ - Bool any_enabled = FALSE; - int o; - - for (o = 0; o < config->num_output; o++) - any_enabled |= enabled[o] = xf86OutputEnabled(config->output[o], TRUE); - - if (!any_enabled) { - xf86DrvMsg(scrn->scrnIndex, X_WARNING, - "No outputs definitely connected, trying again...\n"); - - for (o = 0; o < config->num_output; o++) - any_enabled |= enabled[o] = xf86OutputEnabled(config->output[o], FALSE); - } - - return any_enabled; -} - -static Bool -nextEnabledOutput(xf86CrtcConfigPtr config, Bool *enabled, int *index) -{ - int o = *index; - - for (o++; o < config->num_output; o++) { - if (enabled[o]) { - *index = o; - return TRUE; - } - } - - return FALSE; -} - -static Bool -aspectMatch(float a, float b) -{ - return fabs(1 - (a / b)) < 0.05; -} - -static DisplayModePtr -nextAspectMode(xf86OutputPtr o, DisplayModePtr last, float aspect) -{ - DisplayModePtr m = NULL; - - if (!o) - return NULL; - - if (!last) - m = o->probed_modes; - else - m = last->next; - - for (; m; m = m->next) - if (aspectMatch(aspect, (float)m->HDisplay / (float)m->VDisplay)) - return m; - - return NULL; -} - -static DisplayModePtr -bestModeForAspect(xf86CrtcConfigPtr config, Bool *enabled, float aspect) -{ - int o = -1, p; - DisplayModePtr mode = NULL, test = NULL, match = NULL; - - if (!nextEnabledOutput(config, enabled, &o)) - return NULL; - while ((mode = nextAspectMode(config->output[o], mode, aspect))) { - test = mode; - for (p = o; nextEnabledOutput(config, enabled, &p); ) { - test = xf86OutputFindClosestMode(config->output[p], mode); - if (!test) - break; - if (test->HDisplay != mode->HDisplay || - test->VDisplay != mode->VDisplay) { - test = NULL; - break; - } - } - - /* if we didn't match it on all outputs, try the next one */ - if (!test) - continue; - - /* if it's bigger than the last one, save it */ - if (!match || (test->HDisplay > match->HDisplay)) - match = test; - } - - /* return the biggest one found */ - return match; -} - -static Bool -xf86TargetPreferred(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, - DisplayModePtr *modes, Bool *enabled, - int width, int height) -{ - int o, p; - int max_pref_width = 0, max_pref_height = 0; - DisplayModePtr *preferred, *preferred_match; - Bool ret = FALSE; - - preferred = xnfcalloc(config->num_output, sizeof(DisplayModePtr)); - preferred_match = xnfcalloc(config->num_output, sizeof(DisplayModePtr)); - - /* Check if the preferred mode is available on all outputs */ - for (p = -1; nextEnabledOutput(config, enabled, &p); ) { - Rotation r = config->output[p]->initial_rotation; - DisplayModePtr mode; - if ((preferred[p] = xf86OutputHasPreferredMode(config->output[p], - width, height))) { - int pref_width = xf86ModeWidth(preferred[p], r); - int pref_height = xf86ModeHeight(preferred[p], r); - Bool all_match = TRUE; - - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - Bool match = FALSE; - xf86OutputPtr output = config->output[o]; - if (o == p) - continue; - - for (mode = output->probed_modes; mode; mode = mode->next) { - Rotation r = output->initial_rotation; - if (xf86ModeWidth(mode, r) == pref_width && - xf86ModeHeight(mode, r) == pref_height) { - preferred[o] = mode; - match = TRUE; - } - } - - all_match &= match; - } - - if (all_match && - (pref_width*pref_height > max_pref_width*max_pref_height)) { - for (o = -1; nextEnabledOutput(config, enabled, &o); ) - preferred_match[o] = preferred[o]; - max_pref_width = pref_width; - max_pref_height = pref_height; - ret = TRUE; - } - } - } - - /* - * If there's no preferred mode, but only one monitor, pick the - * biggest mode for its aspect ratio, assuming one exists. - */ - if (!ret) do { - int i = 0; - float aspect = 0.0; - - /* count the number of enabled outputs */ - for (i = 0, p = -1; nextEnabledOutput(config, enabled, &p); i++) ; - - if (i != 1) - break; - - p = -1; - nextEnabledOutput(config, enabled, &p); - if (config->output[p]->mm_height) - aspect = (float)config->output[p]->mm_width / - (float)config->output[p]->mm_height; - - if (aspect) - preferred_match[p] = bestModeForAspect(config, enabled, aspect); - - if (preferred_match[p]) - ret = TRUE; - - } while (0); - - if (ret) { - /* oh good, there is a match. stash the selected modes and return. */ - memcpy(modes, preferred_match, - config->num_output * sizeof(DisplayModePtr)); - } - - free(preferred); - free(preferred_match); - return ret; -} - -static Bool -xf86TargetAspect(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, - DisplayModePtr *modes, Bool *enabled, - int width, int height) -{ - int o; - float aspect = 0.0, *aspects; - xf86OutputPtr output; - Bool ret = FALSE; - DisplayModePtr guess = NULL, aspect_guess = NULL, base_guess = NULL; - - aspects = xnfcalloc(config->num_output, sizeof(float)); - - /* collect the aspect ratios */ - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - output = config->output[o]; - if (output->mm_height) - aspects[o] = (float)output->mm_width / (float)output->mm_height; - else - aspects[o] = 4.0 / 3.0; - } - - /* check that they're all the same */ - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - output = config->output[o]; - if (!aspect) { - aspect = aspects[o]; - } else if (!aspectMatch(aspect, aspects[o])) { - goto no_aspect_match; - } - } - - /* if they're all 4:3, just skip ahead and save effort */ - if (!aspectMatch(aspect, 4.0/3.0)) - aspect_guess = bestModeForAspect(config, enabled, aspect); - -no_aspect_match: - base_guess = bestModeForAspect(config, enabled, 4.0/3.0); - - guess = biggestMode(base_guess, aspect_guess); - - if (!guess) - goto out; - - /* found a mode that works everywhere, now apply it */ - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - modes[o] = xf86OutputFindClosestMode(config->output[o], guess); - } - ret = TRUE; - -out: - free(aspects); - return ret; -} - -static Bool -xf86TargetFallback(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, - DisplayModePtr *modes, Bool *enabled, - int width, int height) -{ - DisplayModePtr target_mode = NULL; - Rotation target_rotation = RR_Rotate_0; - DisplayModePtr default_mode; - int default_preferred, target_preferred = 0, o; - - /* User preferred > preferred > other modes */ - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - default_mode = xf86DefaultMode (config->output[o], width, height); - if (!default_mode) - continue; - - default_preferred = (((default_mode->type & M_T_PREFERRED) != 0) + - ((default_mode->type & M_T_USERPREF) != 0)); - - if (default_preferred > target_preferred || !target_mode) { - target_mode = default_mode; - target_preferred = default_preferred; - target_rotation = config->output[o]->initial_rotation; - config->compat_output = o; - } - } - - if (target_mode) - modes[config->compat_output] = target_mode; - - /* Fill in other output modes */ - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - if (!modes[o]) - modes[o] = xf86ClosestMode(config->output[o], target_mode, - target_rotation, width, height); - } - - return target_mode != NULL; -} - -static Bool -xf86TargetUserpref(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, - DisplayModePtr *modes, Bool *enabled, - int width, int height) -{ - int o; - - if (xf86UserConfiguredOutputs(scrn, modes)) - return xf86TargetFallback(scrn, config, modes, enabled, width, height); - - for (o = -1; nextEnabledOutput(config, enabled, &o); ) - if (xf86OutputHasUserPreferredMode(config->output[o])) - return - xf86TargetFallback(scrn, config, modes, enabled, width, height); - - return FALSE; -} - -static Bool -xf86CrtcSetInitialGamma(xf86CrtcPtr crtc, float gamma_red, float gamma_green, - float gamma_blue) -{ - int i, size = 256; - CARD16 *red, *green, *blue; - - red = malloc(3 * size * sizeof(CARD16)); - green = red + size; - blue = green + size; - - /* Only cause warning if user wanted gamma to be set. */ - if (!crtc->funcs->gamma_set && (gamma_red != 1.0 || gamma_green != 1.0 || gamma_blue != 1.0)) { - free(red); - return FALSE; - } else if (!crtc->funcs->gamma_set) { - free(red); - return TRUE; - } - - /* At this early stage none of the randr-interface stuff is up. - * So take the default gamma size for lack of something better. - */ - for (i = 0; i < size; i++) { - if (gamma_red == 1.0) - red[i] = i << 8; - else - red[i] = (CARD16)(pow((double)i/(double)(size - 1), - 1. / (double)gamma_red) * (double)(size - 1) * 256); - - if (gamma_green == 1.0) - green[i] = i << 8; - else - green[i] = (CARD16)(pow((double)i/(double)(size - 1), - 1. / (double)gamma_green) * (double)(size - 1) * 256); - - if (gamma_blue == 1.0) - blue[i] = i << 8; - else - blue[i] = (CARD16)(pow((double)i/(double)(size - 1), - 1. / (double)gamma_blue) * (double)(size - 1) * 256); - } - - /* Default size is 256, so anything else is failure. */ - if (size != crtc->gamma_size) { - free(red); - return FALSE; - } - - crtc->gamma_size = size; - memcpy (crtc->gamma_red, red, crtc->gamma_size * sizeof (CARD16)); - memcpy (crtc->gamma_green, green, crtc->gamma_size * sizeof (CARD16)); - memcpy (crtc->gamma_blue, blue, crtc->gamma_size * sizeof (CARD16)); - - /* Do not set gamma now, delay until the crtc is activated. */ - - free(red); - - return TRUE; -} - -static Bool -xf86OutputSetInitialGamma(xf86OutputPtr output) -{ - XF86ConfMonitorPtr mon = output->conf_monitor; - float gamma_red = 1.0, gamma_green = 1.0, gamma_blue = 1.0; - - if (!mon) - return TRUE; - - if (!output->crtc) - return FALSE; - - /* Get configured values, where they exist. */ - if (mon->mon_gamma_red >= GAMMA_MIN && - mon->mon_gamma_red <= GAMMA_MAX) - gamma_red = mon->mon_gamma_red; - - if (mon->mon_gamma_green >= GAMMA_MIN && - mon->mon_gamma_green <= GAMMA_MAX) - gamma_green = mon->mon_gamma_green; - - if (mon->mon_gamma_blue >= GAMMA_MIN && - mon->mon_gamma_blue <= GAMMA_MAX) - gamma_blue = mon->mon_gamma_blue; - - /* This avoids setting gamma 1.0 in case another cloned output on this crtc has a specific gamma. */ - if (gamma_red != 1.0 || gamma_green != 1.0 || gamma_blue != 1.0) { - xf86DrvMsg(output->scrn->scrnIndex, X_INFO, "Output %s wants gamma correction (%.1f, %.1f, %.1f)\n", output->name, gamma_red, gamma_green, gamma_blue); - return xf86CrtcSetInitialGamma(output->crtc, gamma_red, gamma_green, gamma_blue); - }else - return TRUE; -} - -/** - * Construct default screen configuration - * - * Given auto-detected (and, eventually, configured) values, - * construct a usable configuration for the system - * - * canGrow indicates that the driver can resize the screen to larger than its - * initially configured size via the config->funcs->resize hook. If TRUE, this - * function will set virtualX and virtualY to match the initial configuration - * and leave config->max{Width,Height} alone. If FALSE, it will bloat - * virtual[XY] to include the largest modes and set config->max{Width,Height} - * accordingly. - */ - -Bool -xf86InitialConfiguration (ScrnInfoPtr scrn, Bool canGrow) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o, c; - xf86CrtcPtr *crtcs; - DisplayModePtr *modes; - Bool *enabled; - int width, height; - int i = scrn->scrnIndex; - Bool have_outputs = TRUE; - Bool ret; - - /* Set up the device options */ - config->options = xnfalloc (sizeof (xf86DeviceOptions)); - memcpy (config->options, xf86DeviceOptions, sizeof (xf86DeviceOptions)); - xf86ProcessOptions (scrn->scrnIndex, - scrn->options, - config->options); - config->debug_modes = xf86ReturnOptValBool (config->options, - OPTION_MODEDEBUG, FALSE); - - if (scrn->display->virtualX) - width = scrn->display->virtualX; - else - width = config->maxWidth; - if (scrn->display->virtualY) - height = scrn->display->virtualY; - else - height = config->maxHeight; - - xf86ProbeOutputModes (scrn, width, height); - - crtcs = xnfcalloc (config->num_output, sizeof (xf86CrtcPtr)); - modes = xnfcalloc (config->num_output, sizeof (DisplayModePtr)); - enabled = xnfcalloc (config->num_output, sizeof (Bool)); - - ret = xf86CollectEnabledOutputs(scrn, config, enabled); - if (ret == FALSE && canGrow) { - xf86DrvMsg(i, X_WARNING, "Unable to find connected outputs - setting %dx%d initial framebuffer\n", - NO_OUTPUT_DEFAULT_WIDTH, NO_OUTPUT_DEFAULT_HEIGHT); - have_outputs = FALSE; - } else { - if (xf86TargetUserpref(scrn, config, modes, enabled, width, height)) - xf86DrvMsg(i, X_INFO, "Using user preference for initial modes\n"); - else if (xf86TargetPreferred(scrn, config, modes, enabled, width, height)) - xf86DrvMsg(i, X_INFO, "Using exact sizes for initial modes\n"); - else if (xf86TargetAspect(scrn, config, modes, enabled, width, height)) - xf86DrvMsg(i, X_INFO, "Using fuzzy aspect match for initial modes\n"); - else if (xf86TargetFallback(scrn, config, modes, enabled, width, height)) - xf86DrvMsg(i, X_INFO, "Using sloppy heuristic for initial modes\n"); - else - xf86DrvMsg(i, X_WARNING, "Unable to find initial modes\n"); - } - - for (o = -1; nextEnabledOutput(config, enabled, &o); ) { - if (!modes[o]) - xf86DrvMsg (scrn->scrnIndex, X_ERROR, - "Output %s enabled but has no modes\n", - config->output[o]->name); - else - xf86DrvMsg (scrn->scrnIndex, X_INFO, - "Output %s using initial mode %s\n", - config->output[o]->name, modes[o]->name); - } - - /* - * Set the position of each output - */ - if (!xf86InitialOutputPositions (scrn, modes)) - { - free(crtcs); - free(modes); - return FALSE; - } - - /* - * Set initial panning of each output - */ - xf86InitialPanning (scrn); - - /* - * Assign CRTCs to fit output configuration - */ - if (have_outputs && !xf86PickCrtcs (scrn, crtcs, modes, 0, width, height)) - { - free(crtcs); - free(modes); - return FALSE; - } - - /* XXX override xf86 common frame computation code */ - - scrn->display->frameX0 = 0; - scrn->display->frameY0 = 0; - - for (c = 0; c < config->num_crtc; c++) - { - xf86CrtcPtr crtc = config->crtc[c]; - - crtc->enabled = FALSE; - memset (&crtc->desiredMode, '\0', sizeof (crtc->desiredMode)); - /* Set default gamma for all crtc's. */ - /* This is done to avoid problems later on with cloned outputs. */ - xf86CrtcSetInitialGamma(crtc, 1.0, 1.0, 1.0); - } - - if (xf86_crtc_supports_gamma(scrn)) - xf86DrvMsg(scrn->scrnIndex, X_INFO, "Using default gamma of (1.0, 1.0, 1.0) unless otherwise stated.\n"); - - /* - * Set initial configuration - */ - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - DisplayModePtr mode = modes[o]; - xf86CrtcPtr crtc = crtcs[o]; - - if (mode && crtc) - { - crtc->desiredMode = *mode; - crtc->desiredRotation = output->initial_rotation; - crtc->desiredX = output->initial_x; - crtc->desiredY = output->initial_y; - crtc->desiredTransformPresent = FALSE; - crtc->enabled = TRUE; - memcpy (&crtc->panningTotalArea, &output->initialTotalArea, sizeof(BoxRec)); - memcpy (&crtc->panningTrackingArea, &output->initialTrackingArea, sizeof(BoxRec)); - memcpy (crtc->panningBorder, output->initialBorder, 4*sizeof(INT16)); - output->crtc = crtc; - if (!xf86OutputSetInitialGamma(output)) - xf86DrvMsg (scrn->scrnIndex, X_WARNING, "Initial gamma correction for output %s: failed.\n", output->name); - } else { - output->crtc = NULL; - } - } - - if (scrn->display->virtualX == 0) - { - /* - * Expand virtual size to cover the current config and potential mode - * switches, if the driver can't enlarge the screen later. - */ - xf86DefaultScreenLimits (scrn, &width, &height, canGrow); - - if (have_outputs == FALSE) { - if (width < NO_OUTPUT_DEFAULT_WIDTH && height < NO_OUTPUT_DEFAULT_HEIGHT) { - width = NO_OUTPUT_DEFAULT_WIDTH; - height = NO_OUTPUT_DEFAULT_HEIGHT; - } - } - - scrn->display->virtualX = width; - scrn->display->virtualY = height; - } - - if (width > scrn->virtualX) - scrn->virtualX = width; - if (height > scrn->virtualY) - scrn->virtualY = height; - - /* - * Make sure the configuration isn't too small. - */ - if (width < config->minWidth || height < config->minHeight) - return FALSE; - - /* - * Limit the crtc config to virtual[XY] if the driver can't grow the - * desktop. - */ - if (!canGrow) - { - xf86CrtcSetSizeRange (scrn, config->minWidth, config->minHeight, - width, height); - } - - if (have_outputs) { - /* Mirror output modes to scrn mode list */ - xf86SetScrnInfoModes (scrn); - } else { - /* Clear any existing modes from scrn->modes */ - while (scrn->modes != NULL) - xf86DeleteMode(&scrn->modes, scrn->modes); - scrn->modes = xf86ModesAdd(scrn->modes, - xf86CVTMode(width, height, 60, 0, 0)); - } - - - free(crtcs); - free(modes); - return TRUE; -} - -/* - * Check the CRTC we're going to map each output to vs. it's current - * CRTC. If they don't match, we have to disable the output and the CRTC - * since the driver will have to re-route things. - */ -static void -xf86PrepareOutputs (ScrnInfoPtr scrn) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int o; - - for (o = 0; o < config->num_output; o++) { - xf86OutputPtr output = config->output[o]; -#if RANDR_GET_CRTC_INTERFACE - /* Disable outputs that are unused or will be re-routed */ - if (!output->funcs->get_crtc || - output->crtc != (*output->funcs->get_crtc)(output) || - output->crtc == NULL) -#endif - (*output->funcs->dpms)(output, DPMSModeOff); - } -} - -static void -xf86PrepareCrtcs (ScrnInfoPtr scrn) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int c; - - for (c = 0; c < config->num_crtc; c++) { -#if RANDR_GET_CRTC_INTERFACE - xf86CrtcPtr crtc = config->crtc[c]; - xf86OutputPtr output = NULL; - uint32_t desired_outputs = 0, current_outputs = 0; - int o; - - for (o = 0; o < config->num_output; o++) { - output = config->output[o]; - if (output->crtc == crtc) - desired_outputs |= (1<funcs->get_crtc) { - desired_outputs = 0; - break; - } - if ((*output->funcs->get_crtc)(output) == crtc) - current_outputs |= (1<funcs->dpms)(crtc, DPMSModeOff); -#else - (*crtc->funcs->dpms)(crtc, DPMSModeOff); -#endif - } -} - -/* - * Using the desired mode information in each crtc, set - * modes (used in EnterVT functions, or at server startup) - */ - -Bool -xf86SetDesiredModes (ScrnInfoPtr scrn) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - xf86CrtcPtr crtc = config->crtc[0]; - int c; - - /* A driver with this hook will take care of this */ - if (!crtc->funcs->set_mode_major) { - xf86PrepareOutputs(scrn); - xf86PrepareCrtcs(scrn); - } - - for (c = 0; c < config->num_crtc; c++) - { - xf86OutputPtr output = NULL; - xf86CrtcSetRec set; - int o; - RRTransformPtr transform; - - crtc = config->crtc[c]; - - /* Skip disabled CRTCs */ - if (!crtc->enabled) - continue; - - if (xf86CompatOutput(scrn) && xf86CompatCrtc(scrn) == crtc) - output = xf86CompatOutput(scrn); - else - { - for (o = 0; o < config->num_output; o++) - if (config->output[o]->crtc == crtc) - { - output = config->output[o]; - break; - } - } - /* paranoia */ - if (!output) - continue; - - /* Mark that we'll need to re-set the mode for sure */ - memset(&crtc->mode, 0, sizeof(crtc->mode)); - if (!crtc->desiredMode.CrtcHDisplay) - { - DisplayModePtr mode = xf86OutputFindClosestMode (output, scrn->currentMode); - - if (!mode) - return FALSE; - crtc->desiredMode = *mode; - crtc->desiredRotation = RR_Rotate_0; - crtc->desiredTransformPresent = FALSE; - crtc->desiredX = 0; - crtc->desiredY = 0; - } - - if (crtc->desiredTransformPresent) - transform = &crtc->desiredTransform; - else - transform = NULL; - set.mode = &crtc->desiredMode; - set.rotation = crtc->desiredRotation; - set.transform = transform; - set.x = crtc->desiredX; - set.y = crtc->desiredY; - set.flags = (XF86CrtcSetMode | XF86CrtcSetOutput | - XF86CrtcSetOrigin | XF86CrtcSetTransform | - XF86CrtcSetRotation); - if (!xf86CrtcSet(crtc, &set)) - return FALSE; - } - - xf86DisableUnusedFunctions(scrn); - return TRUE; -} - -/** - * In the current world order, there are lists of modes per output, which may - * or may not include the mode that was asked to be set by XFree86's mode - * selection. Find the closest one, in the following preference order: - * - * - Equality - * - Closer in size to the requested mode, but no larger - * - Closer in refresh rate to the requested mode. - */ - -DisplayModePtr -xf86OutputFindClosestMode (xf86OutputPtr output, DisplayModePtr desired) -{ - DisplayModePtr best = NULL, scan = NULL; - - for (scan = output->probed_modes; scan != NULL; scan = scan->next) - { - /* If there's an exact match, we're done. */ - if (xf86ModesEqual(scan, desired)) { - best = desired; - break; - } - - /* Reject if it's larger than the desired mode. */ - if (scan->HDisplay > desired->HDisplay || - scan->VDisplay > desired->VDisplay) - { - continue; - } - - /* - * If we haven't picked a best mode yet, use the first - * one in the size range - */ - if (best == NULL) - { - best = scan; - continue; - } - - /* Find if it's closer to the right size than the current best - * option. - */ - if ((scan->HDisplay > best->HDisplay && - scan->VDisplay >= best->VDisplay) || - (scan->HDisplay >= best->HDisplay && - scan->VDisplay > best->VDisplay)) - { - best = scan; - continue; - } - - /* Find if it's still closer to the right refresh than the current - * best resolution. - */ - if (scan->HDisplay == best->HDisplay && - scan->VDisplay == best->VDisplay && - (fabs(scan->VRefresh - desired->VRefresh) < - fabs(best->VRefresh - desired->VRefresh))) { - best = scan; - } - } - return best; -} - -/** - * When setting a mode through XFree86-VidModeExtension or XFree86-DGA, - * take the specified mode and apply it to the crtc connected to the compat - * output. Then, find similar modes for the other outputs, as with the - * InitialConfiguration code above. The goal is to clone the desired - * mode across all outputs that are currently active. - */ - -Bool -xf86SetSingleMode (ScrnInfoPtr pScrn, DisplayModePtr desired, Rotation rotation) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn); - Bool ok = TRUE; - xf86OutputPtr compat_output; - DisplayModePtr compat_mode = NULL; - int c; - - /* - * Let the compat output drive the final mode selection - */ - compat_output = xf86CompatOutput(pScrn); - if (compat_output) - compat_mode = xf86OutputFindClosestMode (compat_output, desired); - if (compat_mode) - desired = compat_mode; - - for (c = 0; c < config->num_crtc; c++) - { - xf86CrtcPtr crtc = config->crtc[c]; - DisplayModePtr crtc_mode = NULL; - int o; - xf86CrtcSetRec set; - - if (!crtc->enabled) - continue; - - for (o = 0; o < config->num_output; o++) - { - xf86OutputPtr output = config->output[o]; - DisplayModePtr output_mode; - - /* skip outputs not on this crtc */ - if (output->crtc != crtc) - continue; - - if (crtc_mode) - { - output_mode = xf86OutputFindClosestMode (output, crtc_mode); - if (output_mode != crtc_mode) - output->crtc = NULL; - } - else - crtc_mode = xf86OutputFindClosestMode (output, desired); - } - if (!crtc_mode) - { - crtc->enabled = FALSE; - continue; - } - set.mode = crtc_mode; - set.rotation = rotation; - set.transform = NULL; - set.x = 0; - set.y = 0; - set.flags = (XF86CrtcSetMode | XF86CrtcSetOutput | - XF86CrtcSetOrigin | XF86CrtcSetTransform | - XF86CrtcSetRotation); - if (!xf86CrtcSet (crtc, &set)) - ok = FALSE; - else - { - crtc->desiredMode = *crtc_mode; - crtc->desiredRotation = rotation; - crtc->desiredTransformPresent = FALSE; - crtc->desiredX = 0; - crtc->desiredY = 0; - } - } - xf86DisableUnusedFunctions(pScrn); -#ifdef RANDR_12_INTERFACE - xf86RandR12TellChanged (pScrn->pScreen); -#endif - return ok; -} - - -/** - * Set the DPMS power mode of all outputs and CRTCs. - * - * If the new mode is off, it will turn off outputs and then CRTCs. - * Otherwise, it will affect CRTCs before outputs. - */ -void -xf86DPMSSet(ScrnInfoPtr scrn, int mode, int flags) -{ - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - int i; - - if (!scrn->vtSema) - return; - - if (mode == DPMSModeOff) { - for (i = 0; i < config->num_output; i++) { - xf86OutputPtr output = config->output[i]; - if (output->crtc != NULL) - (*output->funcs->dpms) (output, mode); - } - } - - for (i = 0; i < config->num_crtc; i++) { - xf86CrtcPtr crtc = config->crtc[i]; - if (crtc->enabled) - (*crtc->funcs->dpms) (crtc, mode); - } - - if (mode != DPMSModeOff) { - for (i = 0; i < config->num_output; i++) { - xf86OutputPtr output = config->output[i]; - if (output->crtc != NULL) - (*output->funcs->dpms) (output, mode); - } - } -} - -/** - * Implement the screensaver by just calling down into the driver DPMS hooks. - * - * Even for monitors with no DPMS support, by the definition of our DPMS hooks, - * the outputs will still get disabled (blanked). - */ -Bool -xf86SaveScreen(ScreenPtr pScreen, int mode) -{ - ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum]; - - if (xf86IsUnblank(mode)) - xf86DPMSSet(pScrn, DPMSModeOn, 0); - else - xf86DPMSSet(pScrn, DPMSModeOff, 0); - - return TRUE; -} - -/** - * Disable all inactive crtcs and outputs - */ -void -xf86DisableUnusedFunctions(ScrnInfoPtr pScrn) -{ - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); - int o, c; - - for (o = 0; o < xf86_config->num_output; o++) - { - xf86OutputPtr output = xf86_config->output[o]; - if (!output->crtc) - (*output->funcs->dpms)(output, DPMSModeOff); - } - - for (c = 0; c < xf86_config->num_crtc; c++) - { - xf86CrtcPtr crtc = xf86_config->crtc[c]; - - if (!crtc->enabled) - { - crtc->funcs->dpms(crtc, DPMSModeOff); - memset(&crtc->mode, 0, sizeof(crtc->mode)); - xf86RotateDestroy(crtc); - crtc->active = FALSE; - } - } - if (pScrn->pScreen) - xf86_crtc_notify(pScrn->pScreen); - if (pScrn->ModeSet) - pScrn->ModeSet(pScrn); -} - -#ifdef RANDR_12_INTERFACE - -#define EDID_ATOM_NAME "EDID" - -/** - * Set the RandR EDID property - */ -static void -xf86OutputSetEDIDProperty (xf86OutputPtr output, void *data, int data_len) -{ - Atom edid_atom = MakeAtom(EDID_ATOM_NAME, sizeof(EDID_ATOM_NAME) - 1, TRUE); - - /* This may get called before the RandR resources have been created */ - if (output->randr_output == NULL) - return; - - if (data_len != 0) { - RRChangeOutputProperty(output->randr_output, edid_atom, XA_INTEGER, 8, - PropModeReplace, data_len, data, FALSE, TRUE); - } else { - RRDeleteOutputProperty(output->randr_output, edid_atom); - } -} - -#endif - -/* Pull out a phyiscal size from a detailed timing if available. */ -struct det_phySize_parameter { - xf86OutputPtr output; - ddc_quirk_t quirks; - Bool ret; -}; - -static void handle_detailed_physical_size(struct detailed_monitor_section - *det_mon, void *data) -{ - struct det_phySize_parameter *p; - p = (struct det_phySize_parameter *)data; - - if (p->ret == TRUE ) - return ; - - xf86DetTimingApplyQuirks(det_mon, p->quirks, - p->output->MonInfo->features.hsize, - p->output->MonInfo->features.vsize); - if (det_mon->type == DT && - det_mon->section.d_timings.h_size != 0 && - det_mon->section.d_timings.v_size != 0) { - - p->output->mm_width = det_mon->section.d_timings.h_size; - p->output->mm_height = det_mon->section.d_timings.v_size; - p->ret = TRUE; - } -} - -/** - * Set the EDID information for the specified output - */ -void -xf86OutputSetEDID (xf86OutputPtr output, xf86MonPtr edid_mon) -{ - ScrnInfoPtr scrn = output->scrn; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - Bool debug_modes = config->debug_modes || xf86Initialising; -#ifdef RANDR_12_INTERFACE - int size; -#endif - - free(output->MonInfo); - - output->MonInfo = edid_mon; - - if (debug_modes) { - xf86DrvMsg(scrn->scrnIndex, X_INFO, "EDID for output %s\n", - output->name); - xf86PrintEDID(edid_mon); - } - - /* Set the DDC properties for the 'compat' output */ - if (output == xf86CompatOutput(scrn)) - xf86SetDDCproperties(scrn, edid_mon); - -#ifdef RANDR_12_INTERFACE - /* Set the RandR output properties */ - size = 0; - if (edid_mon) - { - if (edid_mon->ver.version == 1) { - size = 128; - if (edid_mon->flags & EDID_COMPLETE_RAWDATA) - size += edid_mon->no_sections * 128; - } else if (edid_mon->ver.version == 2) - size = 256; - } - xf86OutputSetEDIDProperty (output, edid_mon ? edid_mon->rawData : NULL, size); -#endif - - if (edid_mon) { - - struct det_phySize_parameter p; - p.output = output; - p.quirks = xf86DDCDetectQuirks(scrn->scrnIndex,edid_mon, FALSE); - p.ret = FALSE; - xf86ForEachDetailedBlock(edid_mon, - handle_detailed_physical_size, &p); - - /* if no mm size is available from a detailed timing, check the max size field */ - if ((!output->mm_width || !output->mm_height) && - (edid_mon->features.hsize && edid_mon->features.vsize)) - { - output->mm_width = edid_mon->features.hsize * 10; - output->mm_height = edid_mon->features.vsize * 10; - } - } -} - -/** - * Return the list of modes supported by the EDID information - * stored in 'output' - */ -DisplayModePtr -xf86OutputGetEDIDModes (xf86OutputPtr output) -{ - ScrnInfoPtr scrn = output->scrn; - xf86MonPtr edid_mon = output->MonInfo; - - if (!edid_mon) - return NULL; - return xf86DDCGetModes(scrn->scrnIndex, edid_mon); -} - -/* maybe we should care about DDC1? meh. */ -xf86MonPtr -xf86OutputGetEDID (xf86OutputPtr output, I2CBusPtr pDDCBus) -{ - ScrnInfoPtr scrn = output->scrn; - xf86MonPtr mon; - - mon = xf86DoEEDID(scrn->scrnIndex, pDDCBus, TRUE); - if (mon) - xf86DDCApplyQuirks(scrn->scrnIndex, mon); - - return mon; -} - -static char *_xf86ConnectorNames[] = { - "None", "VGA", "DVI-I", "DVI-D", - "DVI-A", "Composite", "S-Video", - "Component", "LFP", "Proprietary", - "HDMI", "DisplayPort", - }; -char * -xf86ConnectorGetName(xf86ConnectorType connector) -{ - return _xf86ConnectorNames[connector]; -} - -static void -x86_crtc_box_intersect(BoxPtr dest, BoxPtr a, BoxPtr b) -{ - dest->x1 = a->x1 > b->x1 ? a->x1 : b->x1; - dest->x2 = a->x2 < b->x2 ? a->x2 : b->x2; - dest->y1 = a->y1 > b->y1 ? a->y1 : b->y1; - dest->y2 = a->y2 < b->y2 ? a->y2 : b->y2; - - if (dest->x1 >= dest->x2 || dest->y1 >= dest->y2) - dest->x1 = dest->x2 = dest->y1 = dest->y2 = 0; -} - -static void -x86_crtc_box(xf86CrtcPtr crtc, BoxPtr crtc_box) -{ - if (crtc->enabled) { - crtc_box->x1 = crtc->x; - crtc_box->x2 = crtc->x + xf86ModeWidth(&crtc->mode, crtc->rotation); - crtc_box->y1 = crtc->y; - crtc_box->y2 = crtc->y + xf86ModeHeight(&crtc->mode, crtc->rotation); - } else - crtc_box->x1 = crtc_box->x2 = crtc_box->y1 = crtc_box->y2 = 0; -} - -static int -xf86_crtc_box_area(BoxPtr box) -{ - return (int) (box->x2 - box->x1) * (int) (box->y2 - box->y1); -} - -/* - * Return the crtc covering 'box'. If two crtcs cover a portion of - * 'box', then prefer 'desired'. If 'desired' is NULL, then prefer the crtc - * with greater coverage - */ - -static xf86CrtcPtr -xf86_covering_crtc(ScrnInfoPtr pScrn, - BoxPtr box, - xf86CrtcPtr desired, - BoxPtr crtc_box_ret) -{ - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); - xf86CrtcPtr crtc, best_crtc; - int coverage, best_coverage; - int c; - BoxRec crtc_box, cover_box; - - best_crtc = NULL; - best_coverage = 0; - crtc_box_ret->x1 = 0; - crtc_box_ret->x2 = 0; - crtc_box_ret->y1 = 0; - crtc_box_ret->y2 = 0; - for (c = 0; c < xf86_config->num_crtc; c++) { - crtc = xf86_config->crtc[c]; - x86_crtc_box(crtc, &crtc_box); - x86_crtc_box_intersect(&cover_box, &crtc_box, box); - coverage = xf86_crtc_box_area(&cover_box); - if (coverage && crtc == desired) { - *crtc_box_ret = crtc_box; - return crtc; - } else if (coverage > best_coverage) { - *crtc_box_ret = crtc_box; - best_crtc = crtc; - best_coverage = coverage; - } - } - return best_crtc; -} - -/* - * For overlay video, compute the relevant CRTC and - * clip video to that. - * - * returning FALSE means there was a memory failure of some kind, - * not that the video shouldn't be displayed - */ - -Bool -xf86_crtc_clip_video_helper(ScrnInfoPtr pScrn, - xf86CrtcPtr *crtc_ret, - xf86CrtcPtr desired_crtc, - BoxPtr dst, - INT32 *xa, - INT32 *xb, - INT32 *ya, - INT32 *yb, - RegionPtr reg, - INT32 width, - INT32 height) -{ - Bool ret; - RegionRec crtc_region_local; - RegionPtr crtc_region = reg; - - if (crtc_ret) { - BoxRec crtc_box; - xf86CrtcPtr crtc = xf86_covering_crtc(pScrn, dst, - desired_crtc, - &crtc_box); - - if (crtc) { - RegionInit(&crtc_region_local, &crtc_box, 1); - crtc_region = &crtc_region_local; - RegionIntersect(crtc_region, crtc_region, reg); - } - *crtc_ret = crtc; - } - - ret = xf86XVClipVideoHelper(dst, xa, xb, ya, yb, - crtc_region, width, height); - - if (crtc_region != reg) - RegionUninit(&crtc_region_local); - - return ret; -} - -xf86_crtc_notify_proc_ptr -xf86_wrap_crtc_notify (ScreenPtr screen, xf86_crtc_notify_proc_ptr new) -{ - if (xf86CrtcConfigPrivateIndex != -1) - { - ScrnInfoPtr scrn = xf86Screens[screen->myNum]; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - xf86_crtc_notify_proc_ptr old; - - old = config->xf86_crtc_notify; - config->xf86_crtc_notify = new; - return old; - } - return NULL; -} - -void -xf86_unwrap_crtc_notify(ScreenPtr screen, xf86_crtc_notify_proc_ptr old) -{ - if (xf86CrtcConfigPrivateIndex != -1) - { - ScrnInfoPtr scrn = xf86Screens[screen->myNum]; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - - config->xf86_crtc_notify = old; - } -} - -void -xf86_crtc_notify(ScreenPtr screen) -{ - ScrnInfoPtr scrn = xf86Screens[screen->myNum]; - xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); - - if (config->xf86_crtc_notify) - config->xf86_crtc_notify(screen); -} - -Bool -xf86_crtc_supports_gamma(ScrnInfoPtr pScrn) -{ - if (xf86CrtcConfigPrivateIndex != -1) { - xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); - xf86CrtcPtr crtc; - - /* for multiple drivers loaded we need this */ - if (!xf86_config) - return FALSE; - if (xf86_config->num_crtc == 0) - return FALSE; - crtc = xf86_config->crtc[0]; - - return crtc->funcs->gamma_set != NULL; - } - - return FALSE; -} +/* + * Copyright © 2006 Keith Packard + * Copyright © 2008 Red Hat, Inc. + * + * Permission to use, copy, modify, distribute, and sell this software and its + * documentation for any purpose is hereby granted without fee, provided that + * the above copyright notice appear in all copies and that both that copyright + * notice and this permission notice appear in supporting documentation, and + * that the name of the copyright holders not be used in advertising or + * publicity pertaining to distribution of the software without specific, + * written prior permission. The copyright holders make no representations + * about the suitability of this software for any purpose. It is provided "as + * is" without express or implied warranty. + * + * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, + * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO + * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR + * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, + * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER + * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THIS SOFTWARE. + */ + +#ifdef HAVE_XORG_CONFIG_H +#include +#else +#ifdef HAVE_CONFIG_H +#include +#endif +#endif + +#include +#include +#include + +#include "xf86.h" +#include "xf86DDC.h" +#include "xf86Crtc.h" +#include "xf86Modes.h" +#include "xf86Priv.h" +#include "xf86RandR12.h" +#include "X11/extensions/render.h" +#include "X11/extensions/dpmsconst.h" +#include "X11/Xatom.h" +#include "picturestr.h" + +#include "xf86xv.h" + +#define NO_OUTPUT_DEFAULT_WIDTH 1024 +#define NO_OUTPUT_DEFAULT_HEIGHT 768 +/* + * Initialize xf86CrtcConfig structure + */ + +int xf86CrtcConfigPrivateIndex = -1; + +void +xf86CrtcConfigInit (ScrnInfoPtr scrn, + const xf86CrtcConfigFuncsRec *funcs) +{ + xf86CrtcConfigPtr config; + + if (xf86CrtcConfigPrivateIndex == -1) + xf86CrtcConfigPrivateIndex = xf86AllocateScrnInfoPrivateIndex(); + config = xnfcalloc (1, sizeof (xf86CrtcConfigRec)); + + config->funcs = funcs; + + scrn->privates[xf86CrtcConfigPrivateIndex].ptr = config; +} + +void +xf86CrtcSetSizeRange (ScrnInfoPtr scrn, + int minWidth, int minHeight, + int maxWidth, int maxHeight) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + + config->minWidth = minWidth; + config->minHeight = minHeight; + config->maxWidth = maxWidth; + config->maxHeight = maxHeight; +} + +void +xf86CrtcSetScanoutFormats(ScrnInfoPtr scrn, + int num_formats, + xf86CrtcScanoutFormat *formats) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + + config->num_scanout_formats = num_formats; + config->scanout_formats = formats; +} + +/* + * Crtc functions + */ +xf86CrtcPtr +xf86CrtcCreate (ScrnInfoPtr scrn, + const xf86CrtcFuncsRec *funcs) +{ + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); + xf86CrtcPtr crtc, *crtcs; + + crtc = calloc(sizeof (xf86CrtcRec), 1); + if (!crtc) + return NULL; + crtc->version = XF86_CRTC_VERSION; + crtc->scrn = scrn; + crtc->funcs = funcs; +#ifdef RANDR_12_INTERFACE + crtc->randr_crtc = NULL; +#endif + crtc->rotation = RR_Rotate_0; + crtc->desiredRotation = RR_Rotate_0; + pixman_transform_init_identity (&crtc->crtc_to_framebuffer); + pixman_f_transform_init_identity (&crtc->f_crtc_to_framebuffer); + pixman_f_transform_init_identity (&crtc->f_framebuffer_to_crtc); + pixman_f_transform_init_identity (&crtc->f_screen_to_crtc); + pixman_f_transform_init_identity (&crtc->user_sprite_position_transform); + pixman_f_transform_init_identity (&crtc->f_crtc_to_cursor); + pixman_f_transform_init_identity (&crtc->user_sprite_image_transform); + crtc->filter = NULL; + crtc->params = NULL; + crtc->nparams = 0; + crtc->filter_width = 0; + crtc->filter_height = 0; + crtc->transform_in_use = FALSE; + crtc->sprite_transform_in_use = FALSE; + crtc->transformPresent = FALSE; + crtc->desiredTransformPresent = FALSE; + memset (&crtc->bounds, '\0', sizeof (crtc->bounds)); + + /* Preallocate gamma at a sensible size. */ + crtc->gamma_size = 256; + crtc->gamma_red = malloc(3 * crtc->gamma_size * sizeof (CARD16)); + if (!crtc->gamma_red) { + free(crtc); + return NULL; + } + crtc->gamma_green = crtc->gamma_red + crtc->gamma_size; + crtc->gamma_blue = crtc->gamma_green + crtc->gamma_size; + + if (xf86_config->crtc) + crtcs = realloc(xf86_config->crtc, + (xf86_config->num_crtc + 1) * sizeof (xf86CrtcPtr)); + else + crtcs = malloc((xf86_config->num_crtc + 1) * sizeof (xf86CrtcPtr)); + if (!crtcs) + { + free(crtc); + return NULL; + } + xf86_config->crtc = crtcs; + xf86_config->crtc[xf86_config->num_crtc++] = crtc; + return crtc; +} + +void +xf86CrtcDestroy (xf86CrtcPtr crtc) +{ + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(crtc->scrn); + int c; + + (*crtc->funcs->destroy) (crtc); + for (c = 0; c < xf86_config->num_crtc; c++) + if (xf86_config->crtc[c] == crtc) + { + memmove (&xf86_config->crtc[c], + &xf86_config->crtc[c+1], + ((xf86_config->num_crtc - (c + 1)) * sizeof(void*))); + xf86_config->num_crtc--; + break; + } + free(crtc->params); + free(crtc->gamma_red); + free(crtc); +} + + +/** + * Return whether any outputs are connected to the specified pipe + */ + +Bool +xf86CrtcInUse (xf86CrtcPtr crtc) +{ + ScrnInfoPtr pScrn = crtc->scrn; + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); + int o; + + for (o = 0; o < xf86_config->num_output; o++) + if (xf86_config->output[o]->crtc == crtc) + return TRUE; + return FALSE; +} + +void +xf86CrtcSetScreenSubpixelOrder (ScreenPtr pScreen) +{ + int subpixel_order = SubPixelUnknown; + Bool has_none = FALSE; + ScrnInfoPtr scrn = xf86Screens[pScreen->myNum]; + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); + int c, o; + + for (c = 0; c < xf86_config->num_crtc; c++) + { + xf86CrtcPtr crtc = xf86_config->crtc[c]; + + for (o = 0; o < xf86_config->num_output; o++) + { + xf86OutputPtr output = xf86_config->output[o]; + + if (output->crtc == crtc) + { + switch (output->subpixel_order) { + case SubPixelNone: + has_none = TRUE; + break; + case SubPixelUnknown: + break; + default: + subpixel_order = output->subpixel_order; + break; + } + } + if (subpixel_order != SubPixelUnknown) + break; + } + if (subpixel_order != SubPixelUnknown) + { + static const int circle[4] = { + SubPixelHorizontalRGB, + SubPixelVerticalRGB, + SubPixelHorizontalBGR, + SubPixelVerticalBGR, + }; + int rotate; + int c; + for (rotate = 0; rotate < 4; rotate++) + if (crtc->rotation & (1 << rotate)) + break; + for (c = 0; c < 4; c++) + if (circle[c] == subpixel_order) + break; + c = (c + rotate) & 0x3; + if ((crtc->rotation & RR_Reflect_X) && !(c & 1)) + c ^= 2; + if ((crtc->rotation & RR_Reflect_Y) && (c & 1)) + c ^= 2; + subpixel_order = circle[c]; + break; + } + } + if (subpixel_order == SubPixelUnknown && has_none) + subpixel_order = SubPixelNone; + PictureSetSubpixelOrder (pScreen, subpixel_order); +} + +/** + * Sets the given video mode on the given crtc + */ +Bool +xf86CrtcSet(xf86CrtcPtr crtc, xf86CrtcSetRec *set) +{ + ScrnInfoPtr scrn = crtc->scrn; + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); + int i; + Bool ret = FALSE; + Bool didLock = FALSE; + DisplayModePtr adjusted_mode = NULL; + DisplayModeRec saved_mode; + int saved_x, saved_y; + Rotation saved_rotation; + RRTransformRec saved_transform; + Bool saved_transform_present; + PixmapPtr saved_scanout_pixmap; + + crtc->enabled = xf86CrtcInUse (crtc); + + /* We only hit this if someone explicitly sends a "disabled" modeset. */ + if (!crtc->enabled) + { + /* Check everything for stuff that should be off. */ + xf86DisableUnusedFunctions(scrn); + return TRUE; + } + + /* See if nothing has changed */ + if (!set->flags) + return TRUE; + + saved_mode = crtc->mode; + saved_x = crtc->x; + saved_y = crtc->y; + saved_rotation = crtc->rotation; + saved_scanout_pixmap = crtc->scanoutPixmap; + if (crtc->transformPresent) { + RRTransformInit (&saved_transform); + RRTransformCopy (&saved_transform, &crtc->transform); + } + saved_transform_present = crtc->transformPresent; + + /* Update crtc values up front so the driver can rely on them for mode + * setting. + */ + if (set->flags & XF86CrtcSetMode) + crtc->mode = *set->mode; + if (set->flags & XF86CrtcSetOrigin) { + crtc->x = set->x; + crtc->y = set->y; + } + if (set->flags & XF86CrtcSetRotation) + crtc->rotation = set->rotation; + if (set->flags & XF86CrtcSetScanoutPixmap) + crtc->scanoutPixmap = set->scanout_pixmap; + + if (set->flags & XF86CrtcSetTransform) { + if (set->transform) { + RRTransformCopy (&crtc->transform, set->transform); + crtc->transformPresent = TRUE; + } else + crtc->transformPresent = FALSE; + } + + if (crtc->funcs->set) { + ret = crtc->funcs->set(crtc, set->flags); + goto done; + } + + if (set->flags == XF86CrtcSetOrigin && crtc->funcs->set_origin) { + ret = xf86CrtcRotate(crtc); + if (ret) + crtc->funcs->set_origin(crtc, crtc->x, crtc->y); + goto done; + } + + if (crtc->funcs->set_mode_major) { + ret = crtc->funcs->set_mode_major(crtc, &crtc->mode, + crtc->rotation, + crtc->x, crtc->y); + goto done; + } + + adjusted_mode = xf86DuplicateMode(&crtc->mode); + + didLock = crtc->funcs->lock (crtc); + /* Pass our mode to the outputs and the CRTC to give them a chance to + * adjust it according to limitations or output properties, and also + * a chance to reject the mode entirely. + */ + for (i = 0; i < xf86_config->num_output; i++) { + xf86OutputPtr output = xf86_config->output[i]; + + if (output->crtc != crtc) + continue; + + if (!output->funcs->mode_fixup(output, &crtc->mode, adjusted_mode)) { + goto done; + } + } + + if (!crtc->funcs->mode_fixup(crtc, &crtc->mode, adjusted_mode)) { + goto done; + } + + if (!xf86CrtcRotate (crtc)) + goto done; + + /* Prepare the outputs and CRTCs before setting the mode. */ + for (i = 0; i < xf86_config->num_output; i++) { + xf86OutputPtr output = xf86_config->output[i]; + + if (output->crtc != crtc) + continue; + + /* Disable the output as the first thing we do. */ + output->funcs->prepare(output); + } + + crtc->funcs->prepare(crtc); + + /* Set up the DPLL and any output state that needs to adjust or depend + * on the DPLL. + */ + crtc->funcs->mode_set(crtc, &crtc->mode, adjusted_mode, crtc->x, crtc->y); + for (i = 0; i < xf86_config->num_output; i++) + { + xf86OutputPtr output = xf86_config->output[i]; + if (output->crtc == crtc) + output->funcs->mode_set(output, &crtc->mode, adjusted_mode); + } + + /* Only upload when needed, to avoid unneeded delays. */ + if (!crtc->active && crtc->funcs->gamma_set) + crtc->funcs->gamma_set(crtc, crtc->gamma_red, crtc->gamma_green, + crtc->gamma_blue, crtc->gamma_size); + + /* Now, enable the clocks, plane, pipe, and outputs that we set up. */ + crtc->funcs->commit(crtc); + for (i = 0; i < xf86_config->num_output; i++) + { + xf86OutputPtr output = xf86_config->output[i]; + if (output->crtc == crtc) + output->funcs->commit(output); + } + + ret = TRUE; + +done: + if (ret) { + crtc->active = TRUE; + if (scrn->pScreen) + xf86CrtcSetScreenSubpixelOrder (scrn->pScreen); + if (scrn->ModeSet) + scrn->ModeSet(scrn); + } else { + crtc->x = saved_x; + crtc->y = saved_y; + crtc->rotation = saved_rotation; + crtc->mode = saved_mode; + if (saved_transform_present) + RRTransformCopy (&crtc->transform, &saved_transform); + crtc->transformPresent = saved_transform_present; + crtc->scanoutPixmap = saved_scanout_pixmap; + } + + if (adjusted_mode) { + free(adjusted_mode->name); + free(adjusted_mode); + } + + if (didLock) + crtc->funcs->unlock (crtc); + + return ret; +} + +/** + * Pans the screen, does not change the mode + */ +void +xf86CrtcSetOrigin (xf86CrtcPtr crtc, int x, int y) +{ + xf86CrtcSetRec set; + + if (x != crtc->x || y != crtc->y) { + set.x = x; + set.y = y; + set.flags = XF86CrtcSetOrigin; + (void) xf86CrtcSet(crtc, &set); + } +} + +/* + * Output functions + */ + +extern XF86ConfigPtr xf86configptr; + +typedef enum { + OPTION_PREFERRED_MODE, + OPTION_POSITION, + OPTION_BELOW, + OPTION_RIGHT_OF, + OPTION_ABOVE, + OPTION_LEFT_OF, + OPTION_ENABLE, + OPTION_DISABLE, + OPTION_MIN_CLOCK, + OPTION_MAX_CLOCK, + OPTION_IGNORE, + OPTION_ROTATE, + OPTION_PANNING, + OPTION_PRIMARY, + OPTION_DEFAULT_MODES, +} OutputOpts; + +static OptionInfoRec xf86OutputOptions[] = { + {OPTION_PREFERRED_MODE, "PreferredMode", OPTV_STRING, {0}, FALSE }, + {OPTION_POSITION, "Position", OPTV_STRING, {0}, FALSE }, + {OPTION_BELOW, "Below", OPTV_STRING, {0}, FALSE }, + {OPTION_RIGHT_OF, "RightOf", OPTV_STRING, {0}, FALSE }, + {OPTION_ABOVE, "Above", OPTV_STRING, {0}, FALSE }, + {OPTION_LEFT_OF, "LeftOf", OPTV_STRING, {0}, FALSE }, + {OPTION_ENABLE, "Enable", OPTV_BOOLEAN, {0}, FALSE }, + {OPTION_DISABLE, "Disable", OPTV_BOOLEAN, {0}, FALSE }, + {OPTION_MIN_CLOCK, "MinClock", OPTV_FREQ, {0}, FALSE }, + {OPTION_MAX_CLOCK, "MaxClock", OPTV_FREQ, {0}, FALSE }, + {OPTION_IGNORE, "Ignore", OPTV_BOOLEAN, {0}, FALSE }, + {OPTION_ROTATE, "Rotate", OPTV_STRING, {0}, FALSE }, + {OPTION_PANNING, "Panning", OPTV_STRING, {0}, FALSE }, + {OPTION_PRIMARY, "Primary", OPTV_BOOLEAN, {0}, FALSE }, + {OPTION_DEFAULT_MODES, "DefaultModes", OPTV_BOOLEAN, {0}, FALSE }, + {-1, NULL, OPTV_NONE, {0}, FALSE }, +}; + +enum { + OPTION_MODEDEBUG, +}; + +static OptionInfoRec xf86DeviceOptions[] = { + {OPTION_MODEDEBUG, "ModeDebug", OPTV_BOOLEAN, {0}, FALSE }, + {-1, NULL, OPTV_NONE, {0}, FALSE }, +}; + +static void +xf86OutputSetMonitor (xf86OutputPtr output) +{ + char *option_name; + char *monitor; + + if (!output->name) + return; + + free(output->options); + + output->options = xnfalloc (sizeof (xf86OutputOptions)); + memcpy (output->options, xf86OutputOptions, sizeof (xf86OutputOptions)); + + XNFasprintf(&option_name, "monitor-%s", output->name); + monitor = xf86findOptionValue (output->scrn->options, option_name); + if (!monitor) + monitor = output->name; + else + xf86MarkOptionUsedByName (output->scrn->options, option_name); + free(option_name); + output->conf_monitor = xf86findMonitor (monitor, + xf86configptr->conf_monitor_lst); + /* + * Find the monitor section of the screen and use that + */ + if (!output->conf_monitor && output->use_screen_monitor) + output->conf_monitor = xf86findMonitor (output->scrn->monitor->id, + xf86configptr->conf_monitor_lst); + if (output->conf_monitor) + { + xf86DrvMsg (output->scrn->scrnIndex, X_INFO, + "Output %s using monitor section %s\n", + output->name, output->conf_monitor->mon_identifier); + xf86ProcessOptions (output->scrn->scrnIndex, + output->conf_monitor->mon_option_lst, + output->options); + } + else + xf86DrvMsg (output->scrn->scrnIndex, X_INFO, + "Output %s has no monitor section\n", + output->name); +} + +static Bool +xf86OutputEnabled (xf86OutputPtr output, Bool strict) +{ + Bool enable, disable; + + /* check to see if this output was enabled in the config file */ + if (xf86GetOptValBool (output->options, OPTION_ENABLE, &enable) && enable) + { + xf86DrvMsg (output->scrn->scrnIndex, X_INFO, + "Output %s enabled by config file\n", output->name); + return TRUE; + } + /* or if this output was disabled in the config file */ + if (xf86GetOptValBool (output->options, OPTION_DISABLE, &disable) && disable) + { + xf86DrvMsg (output->scrn->scrnIndex, X_INFO, + "Output %s disabled by config file\n", output->name); + return FALSE; + } + + /* If not, try to only light up the ones we know are connected */ + if (strict) { + enable = output->status == XF86OutputStatusConnected; + } + /* But if that fails, try to light up even outputs we're unsure of */ + else { + enable = output->status != XF86OutputStatusDisconnected; + } + + xf86DrvMsg (output->scrn->scrnIndex, X_INFO, + "Output %s %sconnected\n", output->name, enable ? "" : "dis"); + return enable; +} + +static Bool +xf86OutputIgnored (xf86OutputPtr output) +{ + return xf86ReturnOptValBool (output->options, OPTION_IGNORE, FALSE); +} + +static char *direction[4] = { + "normal", + "left", + "inverted", + "right" +}; + +static Rotation +xf86OutputInitialRotation (xf86OutputPtr output) +{ + char *rotate_name = xf86GetOptValString (output->options, + OPTION_ROTATE); + int i; + + if (!rotate_name) { + if (output->initial_rotation) + return output->initial_rotation; + return RR_Rotate_0; + } + + for (i = 0; i < 4; i++) + if (xf86nameCompare (direction[i], rotate_name) == 0) + return 1 << i; + return RR_Rotate_0; +} + +xf86OutputPtr +xf86OutputCreate (ScrnInfoPtr scrn, + const xf86OutputFuncsRec *funcs, + const char *name) +{ + xf86OutputPtr output, *outputs; + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); + int len; + Bool primary; + + if (name) + len = strlen (name) + 1; + else + len = 0; + + output = calloc(sizeof (xf86OutputRec) + len, 1); + if (!output) + return NULL; + output->scrn = scrn; + output->funcs = funcs; + if (name) + { + output->name = (char *) (output + 1); + strcpy (output->name, name); + } + output->subpixel_order = SubPixelUnknown; + /* + * Use the old per-screen monitor section for the first output + */ + output->use_screen_monitor = (xf86_config->num_output == 0); +#ifdef RANDR_12_INTERFACE + output->randr_output = NULL; +#endif + if (name) + { + xf86OutputSetMonitor (output); + if (xf86OutputIgnored (output)) + { + free(output); + return FALSE; + } + } + + + if (xf86_config->output) + outputs = realloc(xf86_config->output, + (xf86_config->num_output + 1) * sizeof (xf86OutputPtr)); + else + outputs = malloc((xf86_config->num_output + 1) * sizeof (xf86OutputPtr)); + if (!outputs) + { + free(output); + return NULL; + } + + xf86_config->output = outputs; + + if (xf86GetOptValBool (output->options, OPTION_PRIMARY, &primary) && primary) + { + memmove(xf86_config->output + 1, xf86_config->output, + xf86_config->num_output * sizeof (xf86OutputPtr)); + xf86_config->output[0] = output; + } + else + { + xf86_config->output[xf86_config->num_output] = output; + } + + xf86_config->num_output++; + + return output; +} + +Bool +xf86OutputRename (xf86OutputPtr output, const char *name) +{ + char *newname = strdup(name); + + if (!newname) + return FALSE; /* so sorry... */ + + if (output->name && output->name != (char *) (output + 1)) + free(output->name); + output->name = newname; + xf86OutputSetMonitor (output); + if (xf86OutputIgnored (output)) + return FALSE; + return TRUE; +} + +void +xf86OutputUseScreenMonitor (xf86OutputPtr output, Bool use_screen_monitor) +{ + if (use_screen_monitor != output->use_screen_monitor) + { + output->use_screen_monitor = use_screen_monitor; + xf86OutputSetMonitor (output); + } +} + +void +xf86OutputDestroy (xf86OutputPtr output) +{ + ScrnInfoPtr scrn = output->scrn; + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); + int o; + + (*output->funcs->destroy) (output); + while (output->probed_modes) + xf86DeleteMode (&output->probed_modes, output->probed_modes); + for (o = 0; o < xf86_config->num_output; o++) + if (xf86_config->output[o] == output) + { + memmove (&xf86_config->output[o], + &xf86_config->output[o+1], + ((xf86_config->num_output - (o + 1)) * sizeof(void*))); + xf86_config->num_output--; + break; + } + if (output->name && output->name != (char *) (output + 1)) + free(output->name); + free(output); +} + +/* + * Called during CreateScreenResources to hook up RandR + */ +static Bool +xf86CrtcCreateScreenResources (ScreenPtr screen) +{ + ScrnInfoPtr scrn = xf86Screens[screen->myNum]; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + + screen->CreateScreenResources = config->CreateScreenResources; + + if (!(*screen->CreateScreenResources)(screen)) + return FALSE; + + if (!xf86RandR12CreateScreenResources (screen)) + return FALSE; + + return TRUE; +} + +/* + * Clean up config on server reset + */ +static Bool +xf86CrtcCloseScreen (int index, ScreenPtr screen) +{ + ScrnInfoPtr scrn = xf86Screens[screen->myNum]; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o, c; + + screen->CloseScreen = config->CloseScreen; + + xf86RotateCloseScreen (screen); + + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + + output->randr_output = NULL; + } + for (c = 0; c < config->num_crtc; c++) + { + xf86CrtcPtr crtc = config->crtc[c]; + + crtc->randr_crtc = NULL; + } + xf86RandR12CloseScreen (screen); + + return screen->CloseScreen (index, screen); +} + +/* + * Called at ScreenInit time to set up + */ +#ifdef RANDR_13_INTERFACE +int +#else +Bool +#endif +xf86CrtcScreenInit (ScreenPtr screen) +{ + ScrnInfoPtr scrn = xf86Screens[screen->myNum]; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int c; + + /* Rotation */ + xf86DrvMsg(scrn->scrnIndex, X_INFO, "RandR 1.2 enabled, ignore the following RandR disabled message.\n"); + xf86DisableRandR(); /* Disable old RandR extension support */ + xf86RandR12Init (screen); + + /* support all rotations if every crtc has the shadow alloc funcs */ + for (c = 0; c < config->num_crtc; c++) + { + xf86CrtcPtr crtc = config->crtc[c]; + if (!crtc->funcs->shadow_allocate || !crtc->funcs->shadow_create) + break; + } + if (c == config->num_crtc) + { + xf86RandR12SetRotations (screen, RR_Rotate_0 | RR_Rotate_90 | + RR_Rotate_180 | RR_Rotate_270 | + RR_Reflect_X | RR_Reflect_Y); + xf86RandR12SetTransformSupport (screen, TRUE); + } + else + { + xf86RandR12SetRotations (screen, RR_Rotate_0); + xf86RandR12SetTransformSupport (screen, FALSE); + } + + /* Wrap CreateScreenResources so we can initialize the RandR code */ + config->CreateScreenResources = screen->CreateScreenResources; + screen->CreateScreenResources = xf86CrtcCreateScreenResources; + + config->CloseScreen = screen->CloseScreen; + screen->CloseScreen = xf86CrtcCloseScreen; + +#ifdef XFreeXDGA + _xf86_di_dga_init_internal(screen); +#endif +#ifdef RANDR_13_INTERFACE + return RANDR_INTERFACE_VERSION; +#else + return TRUE; +#endif +} + +static DisplayModePtr +xf86DefaultMode (xf86OutputPtr output, int width, int height) +{ + DisplayModePtr target_mode = NULL; + DisplayModePtr mode; + int target_diff = 0; + int target_preferred = 0; + int mm_height; + + mm_height = output->mm_height; + if (!mm_height) + mm_height = (768 * 25.4) / DEFAULT_DPI; + /* + * Pick a mode closest to DEFAULT_DPI + */ + for (mode = output->probed_modes; mode; mode = mode->next) + { + int dpi; + int preferred = (((mode->type & M_T_PREFERRED) != 0) + + ((mode->type & M_T_USERPREF) != 0)); + int diff; + + if (xf86ModeWidth (mode, output->initial_rotation) > width || + xf86ModeHeight (mode, output->initial_rotation) > height) + continue; + + /* yes, use VDisplay here, not xf86ModeHeight */ + dpi = (mode->VDisplay * 254) / (mm_height * 10); + diff = dpi - DEFAULT_DPI; + diff = diff < 0 ? -diff : diff; + if (target_mode == NULL || (preferred > target_preferred) || + (preferred == target_preferred && diff < target_diff)) + { + target_mode = mode; + target_diff = diff; + target_preferred = preferred; + } + } + return target_mode; +} + +static DisplayModePtr +xf86ClosestMode (xf86OutputPtr output, + DisplayModePtr match, Rotation match_rotation, + int width, int height) +{ + DisplayModePtr target_mode = NULL; + DisplayModePtr mode; + int target_diff = 0; + + /* + * Pick a mode closest to the specified mode + */ + for (mode = output->probed_modes; mode; mode = mode->next) + { + int dx, dy; + int diff; + + if (xf86ModeWidth (mode, output->initial_rotation) > width || + xf86ModeHeight (mode, output->initial_rotation) > height) + continue; + + /* exact matches are preferred */ + if (output->initial_rotation == match_rotation && + xf86ModesEqual (mode, match)) + return mode; + + dx = xf86ModeWidth (match, match_rotation) - xf86ModeWidth (mode, output->initial_rotation); + dy = xf86ModeHeight (match, match_rotation) - xf86ModeHeight (mode, output->initial_rotation); + diff = dx * dx + dy * dy; + if (target_mode == NULL || diff < target_diff) + { + target_mode = mode; + target_diff = diff; + } + } + return target_mode; +} + +static DisplayModePtr +xf86OutputHasPreferredMode (xf86OutputPtr output, int width, int height) +{ + DisplayModePtr mode; + + for (mode = output->probed_modes; mode; mode = mode->next) + { + if (xf86ModeWidth (mode, output->initial_rotation) > width || + xf86ModeHeight (mode, output->initial_rotation) > height) + continue; + + if (mode->type & M_T_PREFERRED) + return mode; + } + return NULL; +} + +static DisplayModePtr +xf86OutputHasUserPreferredMode (xf86OutputPtr output) +{ + DisplayModePtr mode, first = output->probed_modes; + + for (mode = first; mode && mode->next != first; mode = mode->next) + if (mode->type & M_T_USERPREF) + return mode; + + return NULL; +} + +static int +xf86PickCrtcs (ScrnInfoPtr scrn, + xf86CrtcPtr *best_crtcs, + DisplayModePtr *modes, + int n, + int width, + int height) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int c, o; + xf86OutputPtr output; + xf86CrtcPtr crtc; + xf86CrtcPtr *crtcs; + xf86CrtcPtr best_crtc; + int best_score; + int score; + int my_score; + + if (n == config->num_output) + return 0; + output = config->output[n]; + + /* + * Compute score with this output disabled + */ + best_crtcs[n] = NULL; + best_crtc = NULL; + best_score = xf86PickCrtcs (scrn, best_crtcs, modes, n+1, width, height); + if (modes[n] == NULL) + return best_score; + + crtcs = malloc(config->num_output * sizeof (xf86CrtcPtr)); + if (!crtcs) + return best_score; + + my_score = 1; + /* Score outputs that are known to be connected higher */ + if (output->status == XF86OutputStatusConnected) + my_score++; + /* Score outputs with preferred modes higher */ + if (xf86OutputHasPreferredMode (output, width, height)) + my_score++; + /* + * Select a crtc for this output and + * then attempt to configure the remaining + * outputs + */ + for (c = 0; c < config->num_crtc; c++) + { + if ((output->possible_crtcs & (1 << c)) == 0) + continue; + + crtc = config->crtc[c]; + /* + * Check to see if some other output is + * using this crtc + */ + for (o = 0; o < n; o++) + if (best_crtcs[o] == crtc) + break; + if (o < n) + { + /* + * If the two outputs desire the same mode, + * see if they can be cloned + */ + if (xf86ModesEqual (modes[o], modes[n]) && + config->output[o]->initial_rotation == config->output[n]->initial_rotation && + config->output[o]->initial_x == config->output[n]->initial_x && + config->output[o]->initial_y == config->output[n]->initial_y) + { + if ((output->possible_clones & (1 << o)) == 0) + continue; /* nope, try next CRTC */ + } + else + continue; /* different modes, can't clone */ + } + crtcs[n] = crtc; + memcpy (crtcs, best_crtcs, n * sizeof (xf86CrtcPtr)); + score = my_score + xf86PickCrtcs (scrn, crtcs, modes, n+1, width, height); + if (score > best_score) + { + best_crtc = crtc; + best_score = score; + memcpy (best_crtcs, crtcs, config->num_output * sizeof (xf86CrtcPtr)); + } + } + free(crtcs); + return best_score; +} + + +/* + * Compute the virtual size necessary to place all of the available + * crtcs in the specified configuration. + * + * canGrow indicates that the driver can make the screen larger than its initial + * configuration. If FALSE, this function will enlarge the screen to include + * the largest available mode. + */ + +static void +xf86DefaultScreenLimits (ScrnInfoPtr scrn, int *widthp, int *heightp, + Bool canGrow) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int width = 0, height = 0; + int o; + int c; + int s; + + for (c = 0; c < config->num_crtc; c++) + { + int crtc_width = 0, crtc_height = 0; + xf86CrtcPtr crtc = config->crtc[c]; + + if (crtc->enabled) + { + crtc_width = crtc->desiredX + xf86ModeWidth (&crtc->desiredMode, crtc->desiredRotation); + crtc_height = crtc->desiredY + xf86ModeHeight (&crtc->desiredMode, crtc->desiredRotation); + } + if (!canGrow) { + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + + for (s = 0; s < config->num_crtc; s++) + if (output->possible_crtcs & (1 << s)) + { + DisplayModePtr mode; + for (mode = output->probed_modes; mode; mode = mode->next) + { + if (mode->HDisplay > crtc_width) + crtc_width = mode->HDisplay; + if (mode->VDisplay > crtc_width) + crtc_width = mode->VDisplay; + if (mode->VDisplay > crtc_height) + crtc_height = mode->VDisplay; + if (mode->HDisplay > crtc_height) + crtc_height = mode->HDisplay; + } + } + } + } + if (crtc_width > width) + width = crtc_width; + if (crtc_height > height) + height = crtc_height; + } + if (config->maxWidth && width > config->maxWidth) width = config->maxWidth; + if (config->maxHeight && height > config->maxHeight) height = config->maxHeight; + if (config->minWidth && width < config->minWidth) width = config->minWidth; + if (config->minHeight && height < config->minHeight) height = config->minHeight; + *widthp = width; + *heightp = height; +} + +#define POSITION_UNSET -100000 + +/* + * check if the user configured any outputs at all + * with either a position or a relative setting or a mode. + */ +static Bool +xf86UserConfiguredOutputs(ScrnInfoPtr scrn, DisplayModePtr *modes) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o; + Bool user_conf = FALSE; + + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + char *position; + char *relative_name; + OutputOpts relation; + int r; + static const OutputOpts relations[] = { + OPTION_BELOW, OPTION_RIGHT_OF, OPTION_ABOVE, OPTION_LEFT_OF + }; + + position = xf86GetOptValString (output->options, + OPTION_POSITION); + if (position) + user_conf = TRUE; + + relation = 0; + relative_name = NULL; + for (r = 0; r < 4; r++) + { + relation = relations[r]; + relative_name = xf86GetOptValString (output->options, + relation); + if (relative_name) + break; + } + if (relative_name) + user_conf = TRUE; + + modes[o] = xf86OutputHasUserPreferredMode(output); + if (modes[o]) + user_conf = TRUE; + } + + return user_conf; +} + +static Bool +xf86InitialOutputPositions (ScrnInfoPtr scrn, DisplayModePtr *modes) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o; + int min_x, min_y; + + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + + output->initial_x = output->initial_y = POSITION_UNSET; + } + + /* + * Loop until all outputs are set + */ + for (;;) + { + Bool any_set = FALSE; + Bool keep_going = FALSE; + + for (o = 0; o < config->num_output; o++) + { + static const OutputOpts relations[] = { + OPTION_BELOW, OPTION_RIGHT_OF, OPTION_ABOVE, OPTION_LEFT_OF + }; + xf86OutputPtr output = config->output[o]; + xf86OutputPtr relative; + char *relative_name; + char *position; + OutputOpts relation; + int r; + + if (output->initial_x != POSITION_UNSET) + continue; + position = xf86GetOptValString (output->options, + OPTION_POSITION); + /* + * Absolute position wins + */ + if (position) + { + int x, y; + if (sscanf (position, "%d %d", &x, &y) == 2) + { + output->initial_x = x; + output->initial_y = y; + } + else + { + xf86DrvMsg (scrn->scrnIndex, X_ERROR, + "Output %s position not of form \"x y\"\n", + output->name); + output->initial_x = output->initial_y = 0; + } + any_set = TRUE; + continue; + } + /* + * Next comes relative positions + */ + relation = 0; + relative_name = NULL; + for (r = 0; r < 4; r++) + { + relation = relations[r]; + relative_name = xf86GetOptValString (output->options, + relation); + if (relative_name) + break; + } + if (relative_name) + { + int or; + relative = NULL; + for (or = 0; or < config->num_output; or++) + { + xf86OutputPtr out_rel = config->output[or]; + XF86ConfMonitorPtr rel_mon = out_rel->conf_monitor; + + if (rel_mon) + { + if (xf86nameCompare (rel_mon->mon_identifier, + relative_name) == 0) + { + relative = config->output[or]; + break; + } + } + if (strcmp (out_rel->name, relative_name) == 0) + { + relative = config->output[or]; + break; + } + } + if (!relative) + { + xf86DrvMsg (scrn->scrnIndex, X_ERROR, + "Cannot position output %s relative to unknown output %s\n", + output->name, relative_name); + output->initial_x = 0; + output->initial_y = 0; + any_set = TRUE; + continue; + } + if (!modes[or]) + { + xf86DrvMsg (scrn->scrnIndex, X_ERROR, + "Cannot position output %s relative to output %s without modes\n", + output->name, relative_name); + output->initial_x = 0; + output->initial_y = 0; + any_set = TRUE; + continue; + } + if (relative->initial_x == POSITION_UNSET) + { + keep_going = TRUE; + continue; + } + output->initial_x = relative->initial_x; + output->initial_y = relative->initial_y; + switch (relation) { + case OPTION_BELOW: + output->initial_y += xf86ModeHeight (modes[or], relative->initial_rotation); + break; + case OPTION_RIGHT_OF: + output->initial_x += xf86ModeWidth (modes[or], relative->initial_rotation); + break; + case OPTION_ABOVE: + if (modes[o]) + output->initial_y -= xf86ModeHeight (modes[o], output->initial_rotation); + break; + case OPTION_LEFT_OF: + if (modes[o]) + output->initial_x -= xf86ModeWidth (modes[o], output->initial_rotation); + break; + default: + break; + } + any_set = TRUE; + continue; + } + + /* Nothing set, just stick them at 0,0 */ + output->initial_x = 0; + output->initial_y = 0; + any_set = TRUE; + } + if (!keep_going) + break; + if (!any_set) + { + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + if (output->initial_x == POSITION_UNSET) + { + xf86DrvMsg (scrn->scrnIndex, X_ERROR, + "Output position loop. Moving %s to 0,0\n", + output->name); + output->initial_x = output->initial_y = 0; + break; + } + } + } + } + + /* + * normalize positions + */ + min_x = 1000000; + min_y = 1000000; + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + + if (output->initial_x < min_x) + min_x = output->initial_x; + if (output->initial_y < min_y) + min_y = output->initial_y; + } + + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + + output->initial_x -= min_x; + output->initial_y -= min_y; + } + return TRUE; +} + +static void +xf86InitialPanning (ScrnInfoPtr scrn) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o; + + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + char *panning = xf86GetOptValString (output->options, OPTION_PANNING); + int width, height, left, top; + int track_width, track_height, track_left, track_top; + int brdr[4]; + + memset (&output->initialTotalArea, 0, sizeof(BoxRec)); + memset (&output->initialTrackingArea, 0, sizeof(BoxRec)); + memset (output->initialBorder, 0, 4*sizeof(INT16)); + + if (! panning) + continue; + + switch (sscanf (panning, "%dx%d+%d+%d/%dx%d+%d+%d/%d/%d/%d/%d", + &width, &height, &left, &top, + &track_width, &track_height, &track_left, &track_top, + &brdr[0], &brdr[1], &brdr[2], &brdr[3])) { + case 12: + output->initialBorder[0] = brdr[0]; + output->initialBorder[1] = brdr[1]; + output->initialBorder[2] = brdr[2]; + output->initialBorder[3] = brdr[3]; + /* fall through */ + case 8: + output->initialTrackingArea.x1 = track_left; + output->initialTrackingArea.y1 = track_top; + output->initialTrackingArea.x2 = track_left + track_width; + output->initialTrackingArea.y2 = track_top + track_height; + /* fall through */ + case 4: + output->initialTotalArea.x1 = left; + output->initialTotalArea.y1 = top; + /* fall through */ + case 2: + output->initialTotalArea.x2 = output->initialTotalArea.x1 + width; + output->initialTotalArea.y2 = output->initialTotalArea.y1 + height; + break; + default: + xf86DrvMsg (scrn->scrnIndex, X_ERROR, + "Broken panning specification '%s' for output %s in config file\n", + panning, output->name); + } + } +} + +/** Return - 0 + if a should be earlier, same or later than b in list + */ +static int +xf86ModeCompare (DisplayModePtr a, DisplayModePtr b) +{ + int diff; + + diff = ((b->type & M_T_PREFERRED) != 0) - ((a->type & M_T_PREFERRED) != 0); + if (diff) + return diff; + diff = b->HDisplay * b->VDisplay - a->HDisplay * a->VDisplay; + if (diff) + return diff; + diff = b->Clock - a->Clock; + return diff; +} + +/** + * Insertion sort input in-place and return the resulting head + */ +static DisplayModePtr +xf86SortModes (DisplayModePtr input) +{ + DisplayModePtr output = NULL, i, o, n, *op, prev; + + /* sort by preferred status and pixel area */ + while (input) + { + i = input; + input = input->next; + for (op = &output; (o = *op); op = &o->next) + if (xf86ModeCompare (o, i) > 0) + break; + i->next = *op; + *op = i; + } + /* prune identical modes */ + for (o = output; o && (n = o->next); o = n) + { + if (!strcmp (o->name, n->name) && xf86ModesEqual (o, n)) + { + o->next = n->next; + free(n->name); + free(n); + n = o; + } + } + /* hook up backward links */ + prev = NULL; + for (o = output; o; o = o->next) + { + o->prev = prev; + prev = o; + } + return output; +} + +static char * +preferredMode(ScrnInfoPtr pScrn, xf86OutputPtr output) +{ + char *preferred_mode = NULL; + + /* Check for a configured preference for a particular mode */ + preferred_mode = xf86GetOptValString (output->options, + OPTION_PREFERRED_MODE); + if (preferred_mode) + return preferred_mode; + + if (pScrn->display->modes && *pScrn->display->modes) + preferred_mode = *pScrn->display->modes; + + return preferred_mode; +} + +static void +GuessRangeFromModes(MonPtr mon, DisplayModePtr mode) +{ + if (!mon || !mode) + return; + + mon->nHsync = 1; + mon->hsync[0].lo = 1024.0; + mon->hsync[0].hi = 0.0; + + mon->nVrefresh = 1; + mon->vrefresh[0].lo = 1024.0; + mon->vrefresh[0].hi = 0.0; + + while (mode) { + if (!mode->HSync) + mode->HSync = ((float) mode->Clock ) / ((float) mode->HTotal); + + if (!mode->VRefresh) + mode->VRefresh = (1000.0 * ((float) mode->Clock)) / + ((float) (mode->HTotal * mode->VTotal)); + + if (mode->HSync < mon->hsync[0].lo) + mon->hsync[0].lo = mode->HSync; + + if (mode->HSync > mon->hsync[0].hi) + mon->hsync[0].hi = mode->HSync; + + if (mode->VRefresh < mon->vrefresh[0].lo) + mon->vrefresh[0].lo = mode->VRefresh; + + if (mode->VRefresh > mon->vrefresh[0].hi) + mon->vrefresh[0].hi = mode->VRefresh; + + mode = mode->next; + } + + /* stretch out the bottom to fit 640x480@60 */ + if (mon->hsync[0].lo > 31.0) + mon->hsync[0].lo = 31.0; + if (mon->vrefresh[0].lo > 58.0) + mon->vrefresh[0].lo = 58.0; +} + +enum det_monrec_source { + sync_config, sync_edid, sync_default +}; + +struct det_monrec_parameter { + MonRec *mon_rec; + int *max_clock; + Bool set_hsync; + Bool set_vrefresh; + enum det_monrec_source *sync_source; +}; + +static void handle_detailed_monrec(struct detailed_monitor_section *det_mon, + void *data) +{ + enum { sync_config, sync_edid, sync_default }; + struct det_monrec_parameter *p; + p = (struct det_monrec_parameter *)data; + + if (det_mon->type == DS_RANGES) { + struct monitor_ranges *ranges = &det_mon->section.ranges; + if (p->set_hsync && ranges->max_h) { + p->mon_rec->hsync[p->mon_rec->nHsync].lo = ranges->min_h; + p->mon_rec->hsync[p->mon_rec->nHsync].hi = ranges->max_h; + p->mon_rec->nHsync++; + if (*p->sync_source == sync_default) + *p->sync_source = sync_edid; + } + if (p->set_vrefresh && ranges->max_v) { + p->mon_rec->vrefresh[p->mon_rec->nVrefresh].lo = ranges->min_v; + p->mon_rec->vrefresh[p->mon_rec->nVrefresh].hi = ranges->max_v; + p->mon_rec->nVrefresh++; + if (*p->sync_source == sync_default) + *p->sync_source = sync_edid; + } + if (ranges->max_clock * 1000 > *p->max_clock) + *p->max_clock = ranges->max_clock * 1000; + } +} + +void +xf86ProbeOutputModes (ScrnInfoPtr scrn, int maxX, int maxY) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o; + + /* When canGrow was TRUE in the initial configuration we have to + * compare against the maximum values so that we don't drop modes. + * When canGrow was FALSE, the maximum values would have been clamped + * anyway. + */ + if (maxX == 0 || maxY == 0) { + maxX = config->maxWidth; + maxY = config->maxHeight; + } + + /* Probe the list of modes for each output. */ + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + DisplayModePtr mode; + DisplayModePtr config_modes = NULL, output_modes, default_modes = NULL; + char *preferred_mode; + xf86MonPtr edid_monitor; + XF86ConfMonitorPtr conf_monitor; + MonRec mon_rec; + int min_clock = 0; + int max_clock = 0; + double clock; + Bool add_default_modes = xf86ReturnOptValBool(output->options, OPTION_DEFAULT_MODES, TRUE); + Bool debug_modes = config->debug_modes || + xf86Initialising; + enum det_monrec_source sync_source = sync_default; + + while (output->probed_modes != NULL) + xf86DeleteMode(&output->probed_modes, output->probed_modes); + + /* + * Check connection status + */ + output->status = (*output->funcs->detect)(output); + + if (output->status == XF86OutputStatusDisconnected && + !xf86ReturnOptValBool(output->options, OPTION_ENABLE, FALSE)) + { + xf86OutputSetEDID (output, NULL); + continue; + } + + memset (&mon_rec, '\0', sizeof (mon_rec)); + + conf_monitor = output->conf_monitor; + + if (conf_monitor) + { + int i; + + for (i = 0; i < conf_monitor->mon_n_hsync; i++) + { + mon_rec.hsync[mon_rec.nHsync].lo = conf_monitor->mon_hsync[i].lo; + mon_rec.hsync[mon_rec.nHsync].hi = conf_monitor->mon_hsync[i].hi; + mon_rec.nHsync++; + sync_source = sync_config; + } + for (i = 0; i < conf_monitor->mon_n_vrefresh; i++) + { + mon_rec.vrefresh[mon_rec.nVrefresh].lo = conf_monitor->mon_vrefresh[i].lo; + mon_rec.vrefresh[mon_rec.nVrefresh].hi = conf_monitor->mon_vrefresh[i].hi; + mon_rec.nVrefresh++; + sync_source = sync_config; + } + config_modes = xf86GetMonitorModes (scrn, conf_monitor); + } + + output_modes = (*output->funcs->get_modes) (output); + + edid_monitor = output->MonInfo; + + if (edid_monitor) + { + struct det_monrec_parameter p; + struct disp_features *features = &edid_monitor->features; + + /* if display is not continuous-frequency, don't add default modes */ + if (!GTF_SUPPORTED(features->msc)) + add_default_modes = FALSE; + + p.mon_rec = &mon_rec; + p.max_clock = &max_clock; + p.set_hsync = mon_rec.nHsync == 0; + p.set_vrefresh = mon_rec.nVrefresh == 0; + p.sync_source = &sync_source; + + xf86ForEachDetailedBlock(edid_monitor, + handle_detailed_monrec, + &p); + } + + if (xf86GetOptValFreq (output->options, OPTION_MIN_CLOCK, + OPTUNITS_KHZ, &clock)) + min_clock = (int) clock; + if (xf86GetOptValFreq (output->options, OPTION_MAX_CLOCK, + OPTUNITS_KHZ, &clock)) + max_clock = (int) clock; + + /* If we still don't have a sync range, guess wildly */ + if (!mon_rec.nHsync || !mon_rec.nVrefresh) + GuessRangeFromModes(&mon_rec, output_modes); + + /* + * These limits will end up setting a 1024x768@60Hz mode by default, + * which seems like a fairly good mode to use when nothing else is + * specified + */ + if (mon_rec.nHsync == 0) + { + mon_rec.hsync[0].lo = 31.0; + mon_rec.hsync[0].hi = 55.0; + mon_rec.nHsync = 1; + } + if (mon_rec.nVrefresh == 0) + { + mon_rec.vrefresh[0].lo = 58.0; + mon_rec.vrefresh[0].hi = 62.0; + mon_rec.nVrefresh = 1; + } + + if (add_default_modes) + default_modes = xf86GetDefaultModes (); + + /* + * If this is not an RB monitor, remove RB modes from the default + * pool. RB modes from the config or the monitor itself are fine. + */ + if (!mon_rec.reducedblanking) + xf86ValidateModesReducedBlanking (scrn, default_modes); + + if (sync_source == sync_config) + { + /* + * Check output and config modes against sync range from config file + */ + xf86ValidateModesSync (scrn, output_modes, &mon_rec); + xf86ValidateModesSync (scrn, config_modes, &mon_rec); + } + /* + * Check default modes against sync range + */ + xf86ValidateModesSync (scrn, default_modes, &mon_rec); + /* + * Check default modes against monitor max clock + */ + if (max_clock) { + xf86ValidateModesClocks(scrn, default_modes, + &min_clock, &max_clock, 1); + xf86ValidateModesClocks(scrn, output_modes, + &min_clock, &max_clock, 1); + } + + output->probed_modes = NULL; + output->probed_modes = xf86ModesAdd (output->probed_modes, config_modes); + output->probed_modes = xf86ModesAdd (output->probed_modes, output_modes); + output->probed_modes = xf86ModesAdd (output->probed_modes, default_modes); + + /* + * Check all modes against max size, interlace, and doublescan + */ + if (maxX && maxY) + xf86ValidateModesSize (scrn, output->probed_modes, + maxX, maxY, 0); + + { + int flags = (output->interlaceAllowed ? V_INTERLACE : 0) | + (output->doubleScanAllowed ? V_DBLSCAN : 0); + xf86ValidateModesFlags (scrn, output->probed_modes, flags); + } + + /* + * Check all modes against output + */ + for (mode = output->probed_modes; mode != NULL; mode = mode->next) + if (mode->status == MODE_OK) + mode->status = (*output->funcs->mode_valid)(output, mode); + + xf86PruneInvalidModes(scrn, &output->probed_modes, debug_modes); + + output->probed_modes = xf86SortModes (output->probed_modes); + + /* Check for a configured preference for a particular mode */ + preferred_mode = preferredMode(scrn, output); + + if (preferred_mode) + { + for (mode = output->probed_modes; mode; mode = mode->next) + { + if (!strcmp (preferred_mode, mode->name)) + { + if (mode != output->probed_modes) + { + if (mode->prev) + mode->prev->next = mode->next; + if (mode->next) + mode->next->prev = mode->prev; + mode->next = output->probed_modes; + output->probed_modes->prev = mode; + mode->prev = NULL; + output->probed_modes = mode; + } + mode->type |= (M_T_PREFERRED|M_T_USERPREF); + break; + } + } + } + + output->initial_rotation = xf86OutputInitialRotation (output); + + if (debug_modes) { + if (output->probed_modes != NULL) { + xf86DrvMsg(scrn->scrnIndex, X_INFO, + "Printing probed modes for output %s\n", + output->name); + } else { + xf86DrvMsg(scrn->scrnIndex, X_INFO, + "No remaining probed modes for output %s\n", + output->name); + } + } + for (mode = output->probed_modes; mode != NULL; mode = mode->next) + { + /* The code to choose the best mode per pipe later on will require + * VRefresh to be set. + */ + mode->VRefresh = xf86ModeVRefresh(mode); + xf86SetModeCrtc(mode, INTERLACE_HALVE_V); + + if (debug_modes) + xf86PrintModeline(scrn->scrnIndex, mode); + } + } +} + + +/** + * Copy one of the output mode lists to the ScrnInfo record + */ + +/* XXX where does this function belong? Here? */ +void +xf86RandR12GetOriginalVirtualSize(ScrnInfoPtr scrn, int *x, int *y); + +static DisplayModePtr +biggestMode(DisplayModePtr a, DisplayModePtr b) +{ + int A, B; + + if (!a) + return b; + if (!b) + return a; + + A = a->HDisplay * a->VDisplay; + B = b->HDisplay * b->VDisplay; + + if (A > B) + return a; + + return b; +} + +static xf86OutputPtr +SetCompatOutput(xf86CrtcConfigPtr config) +{ + xf86OutputPtr output = NULL, test = NULL; + DisplayModePtr maxmode = NULL, testmode, mode; + int o, compat = -1, count, mincount = 0; + + /* Look for one that's definitely connected */ + for (o = 0; o < config->num_output; o++) + { + test = config->output[o]; + if (!test->crtc) + continue; + if (test->status != XF86OutputStatusConnected) + continue; + if (!test->probed_modes) + continue; + + testmode = mode = test->probed_modes; + for (count = 0; mode; mode = mode->next, count++) + testmode = biggestMode(testmode, mode); + + if (!output) { + output = test; + compat = o; + maxmode = testmode; + mincount = count; + } else if (maxmode == biggestMode(maxmode, testmode)) { + output = test; + compat = o; + maxmode = testmode; + mincount = count; + } else if ((maxmode->HDisplay == testmode->HDisplay) && + (maxmode->VDisplay == testmode->VDisplay) && + count <= mincount) { + output = test; + compat = o; + maxmode = testmode; + mincount = count; + } + } + + /* If we didn't find one, take anything we can get */ + if (!output) + { + for (o = 0; o < config->num_output; o++) + { + test = config->output[o]; + if (!test->crtc) + continue; + if (!test->probed_modes) + continue; + + if (!output) { + output = test; + compat = o; + } else if (test->probed_modes->HDisplay < output->probed_modes->HDisplay) { + output = test; + compat = o; + } + } + } + + if (compat >= 0) { + config->compat_output = compat; + } else { + /* Don't change the compat output when no valid outputs found */ + output = config->output[config->compat_output]; + } + + return output; +} + +void +xf86SetScrnInfoModes (ScrnInfoPtr scrn) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + xf86OutputPtr output; + xf86CrtcPtr crtc; + DisplayModePtr last, mode = NULL; + + output = SetCompatOutput(config); + + if (!output) + return; /* punt */ + + crtc = output->crtc; + + /* Clear any existing modes from scrn->modes */ + while (scrn->modes != NULL) + xf86DeleteMode(&scrn->modes, scrn->modes); + + /* Set scrn->modes to the mode list for the 'compat' output */ + scrn->modes = xf86DuplicateModes(scrn, output->probed_modes); + + if (crtc) { + for (mode = scrn->modes; mode; mode = mode->next) + if (xf86ModesEqual (mode, &crtc->desiredMode)) + break; + } + + if (scrn->modes != NULL) { + /* For some reason, scrn->modes is circular, unlike the other mode + * lists. How great is that? + */ + for (last = scrn->modes; last && last->next; last = last->next) + ; + last->next = scrn->modes; + scrn->modes->prev = last; + if (mode) { + while (scrn->modes != mode) + scrn->modes = scrn->modes->next; + } + } + scrn->currentMode = scrn->modes; +#ifdef XFreeXDGA + if (scrn->pScreen) + _xf86_di_dga_reinit_internal(scrn->pScreen); +#endif +} + +static Bool +xf86CollectEnabledOutputs(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, + Bool *enabled) +{ + Bool any_enabled = FALSE; + int o; + + for (o = 0; o < config->num_output; o++) + any_enabled |= enabled[o] = xf86OutputEnabled(config->output[o], TRUE); + + if (!any_enabled) { + xf86DrvMsg(scrn->scrnIndex, X_WARNING, + "No outputs definitely connected, trying again...\n"); + + for (o = 0; o < config->num_output; o++) + any_enabled |= enabled[o] = xf86OutputEnabled(config->output[o], FALSE); + } + + return any_enabled; +} + +static Bool +nextEnabledOutput(xf86CrtcConfigPtr config, Bool *enabled, int *index) +{ + int o = *index; + + for (o++; o < config->num_output; o++) { + if (enabled[o]) { + *index = o; + return TRUE; + } + } + + return FALSE; +} + +static Bool +aspectMatch(float a, float b) +{ + return fabs(1 - (a / b)) < 0.05; +} + +static DisplayModePtr +nextAspectMode(xf86OutputPtr o, DisplayModePtr last, float aspect) +{ + DisplayModePtr m = NULL; + + if (!o) + return NULL; + + if (!last) + m = o->probed_modes; + else + m = last->next; + + for (; m; m = m->next) + if (aspectMatch(aspect, (float)m->HDisplay / (float)m->VDisplay)) + return m; + + return NULL; +} + +static DisplayModePtr +bestModeForAspect(xf86CrtcConfigPtr config, Bool *enabled, float aspect) +{ + int o = -1, p; + DisplayModePtr mode = NULL, test = NULL, match = NULL; + + if (!nextEnabledOutput(config, enabled, &o)) + return NULL; + while ((mode = nextAspectMode(config->output[o], mode, aspect))) { + test = mode; + for (p = o; nextEnabledOutput(config, enabled, &p); ) { + test = xf86OutputFindClosestMode(config->output[p], mode); + if (!test) + break; + if (test->HDisplay != mode->HDisplay || + test->VDisplay != mode->VDisplay) { + test = NULL; + break; + } + } + + /* if we didn't match it on all outputs, try the next one */ + if (!test) + continue; + + /* if it's bigger than the last one, save it */ + if (!match || (test->HDisplay > match->HDisplay)) + match = test; + } + + /* return the biggest one found */ + return match; +} + +static Bool +xf86TargetPreferred(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, + DisplayModePtr *modes, Bool *enabled, + int width, int height) +{ + int o, p; + int max_pref_width = 0, max_pref_height = 0; + DisplayModePtr *preferred, *preferred_match; + Bool ret = FALSE; + + preferred = xnfcalloc(config->num_output, sizeof(DisplayModePtr)); + preferred_match = xnfcalloc(config->num_output, sizeof(DisplayModePtr)); + + /* Check if the preferred mode is available on all outputs */ + for (p = -1; nextEnabledOutput(config, enabled, &p); ) { + Rotation r = config->output[p]->initial_rotation; + DisplayModePtr mode; + if ((preferred[p] = xf86OutputHasPreferredMode(config->output[p], + width, height))) { + int pref_width = xf86ModeWidth(preferred[p], r); + int pref_height = xf86ModeHeight(preferred[p], r); + Bool all_match = TRUE; + + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + Bool match = FALSE; + xf86OutputPtr output = config->output[o]; + if (o == p) + continue; + + for (mode = output->probed_modes; mode; mode = mode->next) { + Rotation r = output->initial_rotation; + if (xf86ModeWidth(mode, r) == pref_width && + xf86ModeHeight(mode, r) == pref_height) { + preferred[o] = mode; + match = TRUE; + } + } + + all_match &= match; + } + + if (all_match && + (pref_width*pref_height > max_pref_width*max_pref_height)) { + for (o = -1; nextEnabledOutput(config, enabled, &o); ) + preferred_match[o] = preferred[o]; + max_pref_width = pref_width; + max_pref_height = pref_height; + ret = TRUE; + } + } + } + + /* + * If there's no preferred mode, but only one monitor, pick the + * biggest mode for its aspect ratio, assuming one exists. + */ + if (!ret) do { + int i = 0; + float aspect = 0.0; + + /* count the number of enabled outputs */ + for (i = 0, p = -1; nextEnabledOutput(config, enabled, &p); i++) ; + + if (i != 1) + break; + + p = -1; + nextEnabledOutput(config, enabled, &p); + if (config->output[p]->mm_height) + aspect = (float)config->output[p]->mm_width / + (float)config->output[p]->mm_height; + + if (aspect) + preferred_match[p] = bestModeForAspect(config, enabled, aspect); + + if (preferred_match[p]) + ret = TRUE; + + } while (0); + + if (ret) { + /* oh good, there is a match. stash the selected modes and return. */ + memcpy(modes, preferred_match, + config->num_output * sizeof(DisplayModePtr)); + } + + free(preferred); + free(preferred_match); + return ret; +} + +static Bool +xf86TargetAspect(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, + DisplayModePtr *modes, Bool *enabled, + int width, int height) +{ + int o; + float aspect = 0.0, *aspects; + xf86OutputPtr output; + Bool ret = FALSE; + DisplayModePtr guess = NULL, aspect_guess = NULL, base_guess = NULL; + + aspects = xnfcalloc(config->num_output, sizeof(float)); + + /* collect the aspect ratios */ + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + output = config->output[o]; + if (output->mm_height) + aspects[o] = (float)output->mm_width / (float)output->mm_height; + else + aspects[o] = 4.0 / 3.0; + } + + /* check that they're all the same */ + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + output = config->output[o]; + if (!aspect) { + aspect = aspects[o]; + } else if (!aspectMatch(aspect, aspects[o])) { + goto no_aspect_match; + } + } + + /* if they're all 4:3, just skip ahead and save effort */ + if (!aspectMatch(aspect, 4.0/3.0)) + aspect_guess = bestModeForAspect(config, enabled, aspect); + +no_aspect_match: + base_guess = bestModeForAspect(config, enabled, 4.0/3.0); + + guess = biggestMode(base_guess, aspect_guess); + + if (!guess) + goto out; + + /* found a mode that works everywhere, now apply it */ + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + modes[o] = xf86OutputFindClosestMode(config->output[o], guess); + } + ret = TRUE; + +out: + free(aspects); + return ret; +} + +static Bool +xf86TargetFallback(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, + DisplayModePtr *modes, Bool *enabled, + int width, int height) +{ + DisplayModePtr target_mode = NULL; + Rotation target_rotation = RR_Rotate_0; + DisplayModePtr default_mode; + int default_preferred, target_preferred = 0, o; + + /* User preferred > preferred > other modes */ + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + default_mode = xf86DefaultMode (config->output[o], width, height); + if (!default_mode) + continue; + + default_preferred = (((default_mode->type & M_T_PREFERRED) != 0) + + ((default_mode->type & M_T_USERPREF) != 0)); + + if (default_preferred > target_preferred || !target_mode) { + target_mode = default_mode; + target_preferred = default_preferred; + target_rotation = config->output[o]->initial_rotation; + config->compat_output = o; + } + } + + if (target_mode) + modes[config->compat_output] = target_mode; + + /* Fill in other output modes */ + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + if (!modes[o]) + modes[o] = xf86ClosestMode(config->output[o], target_mode, + target_rotation, width, height); + } + + return target_mode != NULL; +} + +static Bool +xf86TargetUserpref(ScrnInfoPtr scrn, xf86CrtcConfigPtr config, + DisplayModePtr *modes, Bool *enabled, + int width, int height) +{ + int o; + + if (xf86UserConfiguredOutputs(scrn, modes)) + return xf86TargetFallback(scrn, config, modes, enabled, width, height); + + for (o = -1; nextEnabledOutput(config, enabled, &o); ) + if (xf86OutputHasUserPreferredMode(config->output[o])) + return + xf86TargetFallback(scrn, config, modes, enabled, width, height); + + return FALSE; +} + +static Bool +xf86CrtcSetInitialGamma(xf86CrtcPtr crtc, float gamma_red, float gamma_green, + float gamma_blue) +{ + int i, size = 256; + CARD16 *red, *green, *blue; + + red = malloc(3 * size * sizeof(CARD16)); + green = red + size; + blue = green + size; + + /* Only cause warning if user wanted gamma to be set. */ + if (!crtc->funcs->gamma_set && (gamma_red != 1.0 || gamma_green != 1.0 || gamma_blue != 1.0)) { + free(red); + return FALSE; + } else if (!crtc->funcs->gamma_set) { + free(red); + return TRUE; + } + + /* At this early stage none of the randr-interface stuff is up. + * So take the default gamma size for lack of something better. + */ + for (i = 0; i < size; i++) { + if (gamma_red == 1.0) + red[i] = i << 8; + else + red[i] = (CARD16)(pow((double)i/(double)(size - 1), + 1. / (double)gamma_red) * (double)(size - 1) * 256); + + if (gamma_green == 1.0) + green[i] = i << 8; + else + green[i] = (CARD16)(pow((double)i/(double)(size - 1), + 1. / (double)gamma_green) * (double)(size - 1) * 256); + + if (gamma_blue == 1.0) + blue[i] = i << 8; + else + blue[i] = (CARD16)(pow((double)i/(double)(size - 1), + 1. / (double)gamma_blue) * (double)(size - 1) * 256); + } + + /* Default size is 256, so anything else is failure. */ + if (size != crtc->gamma_size) { + free(red); + return FALSE; + } + + crtc->gamma_size = size; + memcpy (crtc->gamma_red, red, crtc->gamma_size * sizeof (CARD16)); + memcpy (crtc->gamma_green, green, crtc->gamma_size * sizeof (CARD16)); + memcpy (crtc->gamma_blue, blue, crtc->gamma_size * sizeof (CARD16)); + + /* Do not set gamma now, delay until the crtc is activated. */ + + free(red); + + return TRUE; +} + +static Bool +xf86OutputSetInitialGamma(xf86OutputPtr output) +{ + XF86ConfMonitorPtr mon = output->conf_monitor; + float gamma_red = 1.0, gamma_green = 1.0, gamma_blue = 1.0; + + if (!mon) + return TRUE; + + if (!output->crtc) + return FALSE; + + /* Get configured values, where they exist. */ + if (mon->mon_gamma_red >= GAMMA_MIN && + mon->mon_gamma_red <= GAMMA_MAX) + gamma_red = mon->mon_gamma_red; + + if (mon->mon_gamma_green >= GAMMA_MIN && + mon->mon_gamma_green <= GAMMA_MAX) + gamma_green = mon->mon_gamma_green; + + if (mon->mon_gamma_blue >= GAMMA_MIN && + mon->mon_gamma_blue <= GAMMA_MAX) + gamma_blue = mon->mon_gamma_blue; + + /* This avoids setting gamma 1.0 in case another cloned output on this crtc has a specific gamma. */ + if (gamma_red != 1.0 || gamma_green != 1.0 || gamma_blue != 1.0) { + xf86DrvMsg(output->scrn->scrnIndex, X_INFO, "Output %s wants gamma correction (%.1f, %.1f, %.1f)\n", output->name, gamma_red, gamma_green, gamma_blue); + return xf86CrtcSetInitialGamma(output->crtc, gamma_red, gamma_green, gamma_blue); + }else + return TRUE; +} + +/** + * Construct default screen configuration + * + * Given auto-detected (and, eventually, configured) values, + * construct a usable configuration for the system + * + * canGrow indicates that the driver can resize the screen to larger than its + * initially configured size via the config->funcs->resize hook. If TRUE, this + * function will set virtualX and virtualY to match the initial configuration + * and leave config->max{Width,Height} alone. If FALSE, it will bloat + * virtual[XY] to include the largest modes and set config->max{Width,Height} + * accordingly. + */ + +Bool +xf86InitialConfiguration (ScrnInfoPtr scrn, Bool canGrow) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o, c; + xf86CrtcPtr *crtcs; + DisplayModePtr *modes; + Bool *enabled; + int width, height; + int i = scrn->scrnIndex; + Bool have_outputs = TRUE; + Bool ret; + + /* Set up the device options */ + config->options = xnfalloc (sizeof (xf86DeviceOptions)); + memcpy (config->options, xf86DeviceOptions, sizeof (xf86DeviceOptions)); + xf86ProcessOptions (scrn->scrnIndex, + scrn->options, + config->options); + config->debug_modes = xf86ReturnOptValBool (config->options, + OPTION_MODEDEBUG, FALSE); + + if (scrn->display->virtualX) + width = scrn->display->virtualX; + else + width = config->maxWidth; + if (scrn->display->virtualY) + height = scrn->display->virtualY; + else + height = config->maxHeight; + + xf86ProbeOutputModes (scrn, width, height); + + crtcs = xnfcalloc (config->num_output, sizeof (xf86CrtcPtr)); + modes = xnfcalloc (config->num_output, sizeof (DisplayModePtr)); + enabled = xnfcalloc (config->num_output, sizeof (Bool)); + + ret = xf86CollectEnabledOutputs(scrn, config, enabled); + if (ret == FALSE && canGrow) { + xf86DrvMsg(i, X_WARNING, "Unable to find connected outputs - setting %dx%d initial framebuffer\n", + NO_OUTPUT_DEFAULT_WIDTH, NO_OUTPUT_DEFAULT_HEIGHT); + have_outputs = FALSE; + } else { + if (xf86TargetUserpref(scrn, config, modes, enabled, width, height)) + xf86DrvMsg(i, X_INFO, "Using user preference for initial modes\n"); + else if (xf86TargetPreferred(scrn, config, modes, enabled, width, height)) + xf86DrvMsg(i, X_INFO, "Using exact sizes for initial modes\n"); + else if (xf86TargetAspect(scrn, config, modes, enabled, width, height)) + xf86DrvMsg(i, X_INFO, "Using fuzzy aspect match for initial modes\n"); + else if (xf86TargetFallback(scrn, config, modes, enabled, width, height)) + xf86DrvMsg(i, X_INFO, "Using sloppy heuristic for initial modes\n"); + else + xf86DrvMsg(i, X_WARNING, "Unable to find initial modes\n"); + } + + for (o = -1; nextEnabledOutput(config, enabled, &o); ) { + if (!modes[o]) + xf86DrvMsg (scrn->scrnIndex, X_ERROR, + "Output %s enabled but has no modes\n", + config->output[o]->name); + else + xf86DrvMsg (scrn->scrnIndex, X_INFO, + "Output %s using initial mode %s\n", + config->output[o]->name, modes[o]->name); + } + + /* + * Set the position of each output + */ + if (!xf86InitialOutputPositions (scrn, modes)) + { + free(crtcs); + free(modes); + return FALSE; + } + + /* + * Set initial panning of each output + */ + xf86InitialPanning (scrn); + + /* + * Assign CRTCs to fit output configuration + */ + if (have_outputs && !xf86PickCrtcs (scrn, crtcs, modes, 0, width, height)) + { + free(crtcs); + free(modes); + return FALSE; + } + + /* XXX override xf86 common frame computation code */ + + scrn->display->frameX0 = 0; + scrn->display->frameY0 = 0; + + for (c = 0; c < config->num_crtc; c++) + { + xf86CrtcPtr crtc = config->crtc[c]; + + crtc->enabled = FALSE; + memset (&crtc->desiredMode, '\0', sizeof (crtc->desiredMode)); + /* Set default gamma for all crtc's. */ + /* This is done to avoid problems later on with cloned outputs. */ + xf86CrtcSetInitialGamma(crtc, 1.0, 1.0, 1.0); + } + + if (xf86_crtc_supports_gamma(scrn)) + xf86DrvMsg(scrn->scrnIndex, X_INFO, "Using default gamma of (1.0, 1.0, 1.0) unless otherwise stated.\n"); + + /* + * Set initial configuration + */ + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + DisplayModePtr mode = modes[o]; + xf86CrtcPtr crtc = crtcs[o]; + + if (mode && crtc) + { + crtc->desiredMode = *mode; + crtc->desiredRotation = output->initial_rotation; + crtc->desiredX = output->initial_x; + crtc->desiredY = output->initial_y; + crtc->desiredTransformPresent = FALSE; + crtc->enabled = TRUE; + memcpy (&crtc->panningTotalArea, &output->initialTotalArea, sizeof(BoxRec)); + memcpy (&crtc->panningTrackingArea, &output->initialTrackingArea, sizeof(BoxRec)); + memcpy (crtc->panningBorder, output->initialBorder, 4*sizeof(INT16)); + output->crtc = crtc; + if (!xf86OutputSetInitialGamma(output)) + xf86DrvMsg (scrn->scrnIndex, X_WARNING, "Initial gamma correction for output %s: failed.\n", output->name); + } else { + output->crtc = NULL; + } + } + + if (scrn->display->virtualX == 0) + { + /* + * Expand virtual size to cover the current config and potential mode + * switches, if the driver can't enlarge the screen later. + */ + xf86DefaultScreenLimits (scrn, &width, &height, canGrow); + + if (have_outputs == FALSE) { + if (width < NO_OUTPUT_DEFAULT_WIDTH && height < NO_OUTPUT_DEFAULT_HEIGHT) { + width = NO_OUTPUT_DEFAULT_WIDTH; + height = NO_OUTPUT_DEFAULT_HEIGHT; + } + } + + scrn->display->virtualX = width; + scrn->display->virtualY = height; + } + + if (width > scrn->virtualX) + scrn->virtualX = width; + if (height > scrn->virtualY) + scrn->virtualY = height; + + /* + * Make sure the configuration isn't too small. + */ + if (width < config->minWidth || height < config->minHeight) + return FALSE; + + /* + * Limit the crtc config to virtual[XY] if the driver can't grow the + * desktop. + */ + if (!canGrow) + { + xf86CrtcSetSizeRange (scrn, config->minWidth, config->minHeight, + width, height); + } + + if (have_outputs) { + /* Mirror output modes to scrn mode list */ + xf86SetScrnInfoModes (scrn); + } else { + /* Clear any existing modes from scrn->modes */ + while (scrn->modes != NULL) + xf86DeleteMode(&scrn->modes, scrn->modes); + scrn->modes = xf86ModesAdd(scrn->modes, + xf86CVTMode(width, height, 60, 0, 0)); + } + + + free(crtcs); + free(modes); + return TRUE; +} + +/* + * Check the CRTC we're going to map each output to vs. it's current + * CRTC. If they don't match, we have to disable the output and the CRTC + * since the driver will have to re-route things. + */ +static void +xf86PrepareOutputs (ScrnInfoPtr scrn) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int o; + + for (o = 0; o < config->num_output; o++) { + xf86OutputPtr output = config->output[o]; +#if RANDR_GET_CRTC_INTERFACE + /* Disable outputs that are unused or will be re-routed */ + if (!output->funcs->get_crtc || + output->crtc != (*output->funcs->get_crtc)(output) || + output->crtc == NULL) +#endif + (*output->funcs->dpms)(output, DPMSModeOff); + } +} + +static void +xf86PrepareCrtcs (ScrnInfoPtr scrn) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int c; + + for (c = 0; c < config->num_crtc; c++) { +#if RANDR_GET_CRTC_INTERFACE + xf86CrtcPtr crtc = config->crtc[c]; + xf86OutputPtr output = NULL; + uint32_t desired_outputs = 0, current_outputs = 0; + int o; + + for (o = 0; o < config->num_output; o++) { + output = config->output[o]; + if (output->crtc == crtc) + desired_outputs |= (1<funcs->get_crtc) { + desired_outputs = 0; + break; + } + if ((*output->funcs->get_crtc)(output) == crtc) + current_outputs |= (1<funcs->dpms)(crtc, DPMSModeOff); +#else + (*crtc->funcs->dpms)(crtc, DPMSModeOff); +#endif + } +} + +/* + * Using the desired mode information in each crtc, set + * modes (used in EnterVT functions, or at server startup) + */ + +Bool +xf86SetDesiredModes (ScrnInfoPtr scrn) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + xf86CrtcPtr crtc = config->crtc[0]; + int c; + + /* A driver with this hook will take care of this */ + if (!crtc->funcs->set_mode_major) { + xf86PrepareOutputs(scrn); + xf86PrepareCrtcs(scrn); + } + + for (c = 0; c < config->num_crtc; c++) + { + xf86OutputPtr output = NULL; + xf86CrtcSetRec set; + int o; + RRTransformPtr transform; + + crtc = config->crtc[c]; + + /* Skip disabled CRTCs */ + if (!crtc->enabled) + continue; + + if (xf86CompatOutput(scrn) && xf86CompatCrtc(scrn) == crtc) + output = xf86CompatOutput(scrn); + else + { + for (o = 0; o < config->num_output; o++) + if (config->output[o]->crtc == crtc) + { + output = config->output[o]; + break; + } + } + /* paranoia */ + if (!output) + continue; + + /* Mark that we'll need to re-set the mode for sure */ + memset(&crtc->mode, 0, sizeof(crtc->mode)); + if (!crtc->desiredMode.CrtcHDisplay) + { + DisplayModePtr mode = xf86OutputFindClosestMode (output, scrn->currentMode); + + if (!mode) + return FALSE; + crtc->desiredMode = *mode; + crtc->desiredRotation = RR_Rotate_0; + crtc->desiredTransformPresent = FALSE; + crtc->desiredX = 0; + crtc->desiredY = 0; + } + + if (crtc->desiredTransformPresent) + transform = &crtc->desiredTransform; + else + transform = NULL; + set.mode = &crtc->desiredMode; + set.rotation = crtc->desiredRotation; + set.transform = transform; + set.x = crtc->desiredX; + set.y = crtc->desiredY; + set.flags = (XF86CrtcSetMode | XF86CrtcSetOutput | + XF86CrtcSetOrigin | XF86CrtcSetTransform | + XF86CrtcSetRotation); + if (!xf86CrtcSet(crtc, &set)) + return FALSE; + } + + xf86DisableUnusedFunctions(scrn); + return TRUE; +} + +/** + * In the current world order, there are lists of modes per output, which may + * or may not include the mode that was asked to be set by XFree86's mode + * selection. Find the closest one, in the following preference order: + * + * - Equality + * - Closer in size to the requested mode, but no larger + * - Closer in refresh rate to the requested mode. + */ + +DisplayModePtr +xf86OutputFindClosestMode (xf86OutputPtr output, DisplayModePtr desired) +{ + DisplayModePtr best = NULL, scan = NULL; + + for (scan = output->probed_modes; scan != NULL; scan = scan->next) + { + /* If there's an exact match, we're done. */ + if (xf86ModesEqual(scan, desired)) { + best = desired; + break; + } + + /* Reject if it's larger than the desired mode. */ + if (scan->HDisplay > desired->HDisplay || + scan->VDisplay > desired->VDisplay) + { + continue; + } + + /* + * If we haven't picked a best mode yet, use the first + * one in the size range + */ + if (best == NULL) + { + best = scan; + continue; + } + + /* Find if it's closer to the right size than the current best + * option. + */ + if ((scan->HDisplay > best->HDisplay && + scan->VDisplay >= best->VDisplay) || + (scan->HDisplay >= best->HDisplay && + scan->VDisplay > best->VDisplay)) + { + best = scan; + continue; + } + + /* Find if it's still closer to the right refresh than the current + * best resolution. + */ + if (scan->HDisplay == best->HDisplay && + scan->VDisplay == best->VDisplay && + (fabs(scan->VRefresh - desired->VRefresh) < + fabs(best->VRefresh - desired->VRefresh))) { + best = scan; + } + } + return best; +} + +/** + * When setting a mode through XFree86-VidModeExtension or XFree86-DGA, + * take the specified mode and apply it to the crtc connected to the compat + * output. Then, find similar modes for the other outputs, as with the + * InitialConfiguration code above. The goal is to clone the desired + * mode across all outputs that are currently active. + */ + +Bool +xf86SetSingleMode (ScrnInfoPtr pScrn, DisplayModePtr desired, Rotation rotation) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn); + Bool ok = TRUE; + xf86OutputPtr compat_output; + DisplayModePtr compat_mode = NULL; + int c; + + /* + * Let the compat output drive the final mode selection + */ + compat_output = xf86CompatOutput(pScrn); + if (compat_output) + compat_mode = xf86OutputFindClosestMode (compat_output, desired); + if (compat_mode) + desired = compat_mode; + + for (c = 0; c < config->num_crtc; c++) + { + xf86CrtcPtr crtc = config->crtc[c]; + DisplayModePtr crtc_mode = NULL; + int o; + xf86CrtcSetRec set; + + if (!crtc->enabled) + continue; + + for (o = 0; o < config->num_output; o++) + { + xf86OutputPtr output = config->output[o]; + DisplayModePtr output_mode; + + /* skip outputs not on this crtc */ + if (output->crtc != crtc) + continue; + + if (crtc_mode) + { + output_mode = xf86OutputFindClosestMode (output, crtc_mode); + if (output_mode != crtc_mode) + output->crtc = NULL; + } + else + crtc_mode = xf86OutputFindClosestMode (output, desired); + } + if (!crtc_mode) + { + crtc->enabled = FALSE; + continue; + } + set.mode = crtc_mode; + set.rotation = rotation; + set.transform = NULL; + set.x = 0; + set.y = 0; + set.flags = (XF86CrtcSetMode | XF86CrtcSetOutput | + XF86CrtcSetOrigin | XF86CrtcSetTransform | + XF86CrtcSetRotation); + if (!xf86CrtcSet (crtc, &set)) + ok = FALSE; + else + { + crtc->desiredMode = *crtc_mode; + crtc->desiredRotation = rotation; + crtc->desiredTransformPresent = FALSE; + crtc->desiredX = 0; + crtc->desiredY = 0; + } + } + xf86DisableUnusedFunctions(pScrn); +#ifdef RANDR_12_INTERFACE + xf86RandR12TellChanged (pScrn->pScreen); +#endif + return ok; +} + + +/** + * Set the DPMS power mode of all outputs and CRTCs. + * + * If the new mode is off, it will turn off outputs and then CRTCs. + * Otherwise, it will affect CRTCs before outputs. + */ +void +xf86DPMSSet(ScrnInfoPtr scrn, int mode, int flags) +{ + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + int i; + + if (!scrn->vtSema) + return; + + if (mode == DPMSModeOff) { + for (i = 0; i < config->num_output; i++) { + xf86OutputPtr output = config->output[i]; + if (output->crtc != NULL) + (*output->funcs->dpms) (output, mode); + } + } + + for (i = 0; i < config->num_crtc; i++) { + xf86CrtcPtr crtc = config->crtc[i]; + if (crtc->enabled) + (*crtc->funcs->dpms) (crtc, mode); + } + + if (mode != DPMSModeOff) { + for (i = 0; i < config->num_output; i++) { + xf86OutputPtr output = config->output[i]; + if (output->crtc != NULL) + (*output->funcs->dpms) (output, mode); + } + } +} + +/** + * Implement the screensaver by just calling down into the driver DPMS hooks. + * + * Even for monitors with no DPMS support, by the definition of our DPMS hooks, + * the outputs will still get disabled (blanked). + */ +Bool +xf86SaveScreen(ScreenPtr pScreen, int mode) +{ + ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum]; + + if (xf86IsUnblank(mode)) + xf86DPMSSet(pScrn, DPMSModeOn, 0); + else + xf86DPMSSet(pScrn, DPMSModeOff, 0); + + return TRUE; +} + +/** + * Disable all inactive crtcs and outputs + */ +void +xf86DisableUnusedFunctions(ScrnInfoPtr pScrn) +{ + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); + int o, c; + + for (o = 0; o < xf86_config->num_output; o++) + { + xf86OutputPtr output = xf86_config->output[o]; + if (!output->crtc) + (*output->funcs->dpms)(output, DPMSModeOff); + } + + for (c = 0; c < xf86_config->num_crtc; c++) + { + xf86CrtcPtr crtc = xf86_config->crtc[c]; + + if (!crtc->enabled) + { + crtc->funcs->dpms(crtc, DPMSModeOff); + memset(&crtc->mode, 0, sizeof(crtc->mode)); + xf86RotateDestroy(crtc); + crtc->active = FALSE; + } + } + if (pScrn->pScreen) + xf86_crtc_notify(pScrn->pScreen); + if (pScrn->ModeSet) + pScrn->ModeSet(pScrn); +} + +#ifdef RANDR_12_INTERFACE + +#define EDID_ATOM_NAME "EDID" + +/** + * Set the RandR EDID property + */ +static void +xf86OutputSetEDIDProperty (xf86OutputPtr output, void *data, int data_len) +{ + Atom edid_atom = MakeAtom(EDID_ATOM_NAME, sizeof(EDID_ATOM_NAME) - 1, TRUE); + + /* This may get called before the RandR resources have been created */ + if (output->randr_output == NULL) + return; + + if (data_len != 0) { + RRChangeOutputProperty(output->randr_output, edid_atom, XA_INTEGER, 8, + PropModeReplace, data_len, data, FALSE, TRUE); + } else { + RRDeleteOutputProperty(output->randr_output, edid_atom); + } +} + +#endif + +/* Pull out a phyiscal size from a detailed timing if available. */ +struct det_phySize_parameter { + xf86OutputPtr output; + ddc_quirk_t quirks; + Bool ret; +}; + +static void handle_detailed_physical_size(struct detailed_monitor_section + *det_mon, void *data) +{ + struct det_phySize_parameter *p; + p = (struct det_phySize_parameter *)data; + + if (p->ret == TRUE ) + return ; + + xf86DetTimingApplyQuirks(det_mon, p->quirks, + p->output->MonInfo->features.hsize, + p->output->MonInfo->features.vsize); + if (det_mon->type == DT && + det_mon->section.d_timings.h_size != 0 && + det_mon->section.d_timings.v_size != 0) { + + p->output->mm_width = det_mon->section.d_timings.h_size; + p->output->mm_height = det_mon->section.d_timings.v_size; + p->ret = TRUE; + } +} + +/** + * Set the EDID information for the specified output + */ +void +xf86OutputSetEDID (xf86OutputPtr output, xf86MonPtr edid_mon) +{ + ScrnInfoPtr scrn = output->scrn; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + Bool debug_modes = config->debug_modes || xf86Initialising; +#ifdef RANDR_12_INTERFACE + int size; +#endif + + free(output->MonInfo); + + output->MonInfo = edid_mon; + output->mm_width = 0; + output->mm_height = 0; + + if (debug_modes) { + xf86DrvMsg(scrn->scrnIndex, X_INFO, "EDID for output %s\n", + output->name); + xf86PrintEDID(edid_mon); + } + + /* Set the DDC properties for the 'compat' output */ + if (output == xf86CompatOutput(scrn)) + xf86SetDDCproperties(scrn, edid_mon); + +#ifdef RANDR_12_INTERFACE + /* Set the RandR output properties */ + size = 0; + if (edid_mon) + { + if (edid_mon->ver.version == 1) { + size = 128; + if (edid_mon->flags & EDID_COMPLETE_RAWDATA) + size += edid_mon->no_sections * 128; + } else if (edid_mon->ver.version == 2) + size = 256; + } + xf86OutputSetEDIDProperty (output, edid_mon ? edid_mon->rawData : NULL, size); +#endif + + if (edid_mon) { + + struct det_phySize_parameter p; + p.output = output; + p.quirks = xf86DDCDetectQuirks(scrn->scrnIndex,edid_mon, FALSE); + p.ret = FALSE; + xf86ForEachDetailedBlock(edid_mon, + handle_detailed_physical_size, &p); + + /* if no mm size is available from a detailed timing, check the max size field */ + if ((!output->mm_width || !output->mm_height) && + (edid_mon->features.hsize && edid_mon->features.vsize)) + { + output->mm_width = edid_mon->features.hsize * 10; + output->mm_height = edid_mon->features.vsize * 10; + } + } +} + +/** + * Return the list of modes supported by the EDID information + * stored in 'output' + */ +DisplayModePtr +xf86OutputGetEDIDModes (xf86OutputPtr output) +{ + ScrnInfoPtr scrn = output->scrn; + xf86MonPtr edid_mon = output->MonInfo; + + if (!edid_mon) + return NULL; + return xf86DDCGetModes(scrn->scrnIndex, edid_mon); +} + +/* maybe we should care about DDC1? meh. */ +xf86MonPtr +xf86OutputGetEDID (xf86OutputPtr output, I2CBusPtr pDDCBus) +{ + ScrnInfoPtr scrn = output->scrn; + xf86MonPtr mon; + + mon = xf86DoEEDID(scrn->scrnIndex, pDDCBus, TRUE); + if (mon) + xf86DDCApplyQuirks(scrn->scrnIndex, mon); + + return mon; +} + +static char *_xf86ConnectorNames[] = { + "None", "VGA", "DVI-I", "DVI-D", + "DVI-A", "Composite", "S-Video", + "Component", "LFP", "Proprietary", + "HDMI", "DisplayPort", + }; +char * +xf86ConnectorGetName(xf86ConnectorType connector) +{ + return _xf86ConnectorNames[connector]; +} + +static void +x86_crtc_box_intersect(BoxPtr dest, BoxPtr a, BoxPtr b) +{ + dest->x1 = a->x1 > b->x1 ? a->x1 : b->x1; + dest->x2 = a->x2 < b->x2 ? a->x2 : b->x2; + dest->y1 = a->y1 > b->y1 ? a->y1 : b->y1; + dest->y2 = a->y2 < b->y2 ? a->y2 : b->y2; + + if (dest->x1 >= dest->x2 || dest->y1 >= dest->y2) + dest->x1 = dest->x2 = dest->y1 = dest->y2 = 0; +} + +static void +x86_crtc_box(xf86CrtcPtr crtc, BoxPtr crtc_box) +{ + if (crtc->enabled) { + crtc_box->x1 = crtc->x; + crtc_box->x2 = crtc->x + xf86ModeWidth(&crtc->mode, crtc->rotation); + crtc_box->y1 = crtc->y; + crtc_box->y2 = crtc->y + xf86ModeHeight(&crtc->mode, crtc->rotation); + } else + crtc_box->x1 = crtc_box->x2 = crtc_box->y1 = crtc_box->y2 = 0; +} + +static int +xf86_crtc_box_area(BoxPtr box) +{ + return (int) (box->x2 - box->x1) * (int) (box->y2 - box->y1); +} + +/* + * Return the crtc covering 'box'. If two crtcs cover a portion of + * 'box', then prefer 'desired'. If 'desired' is NULL, then prefer the crtc + * with greater coverage + */ + +static xf86CrtcPtr +xf86_covering_crtc(ScrnInfoPtr pScrn, + BoxPtr box, + xf86CrtcPtr desired, + BoxPtr crtc_box_ret) +{ + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); + xf86CrtcPtr crtc, best_crtc; + int coverage, best_coverage; + int c; + BoxRec crtc_box, cover_box; + + best_crtc = NULL; + best_coverage = 0; + crtc_box_ret->x1 = 0; + crtc_box_ret->x2 = 0; + crtc_box_ret->y1 = 0; + crtc_box_ret->y2 = 0; + for (c = 0; c < xf86_config->num_crtc; c++) { + crtc = xf86_config->crtc[c]; + x86_crtc_box(crtc, &crtc_box); + x86_crtc_box_intersect(&cover_box, &crtc_box, box); + coverage = xf86_crtc_box_area(&cover_box); + if (coverage && crtc == desired) { + *crtc_box_ret = crtc_box; + return crtc; + } else if (coverage > best_coverage) { + *crtc_box_ret = crtc_box; + best_crtc = crtc; + best_coverage = coverage; + } + } + return best_crtc; +} + +/* + * For overlay video, compute the relevant CRTC and + * clip video to that. + * + * returning FALSE means there was a memory failure of some kind, + * not that the video shouldn't be displayed + */ + +Bool +xf86_crtc_clip_video_helper(ScrnInfoPtr pScrn, + xf86CrtcPtr *crtc_ret, + xf86CrtcPtr desired_crtc, + BoxPtr dst, + INT32 *xa, + INT32 *xb, + INT32 *ya, + INT32 *yb, + RegionPtr reg, + INT32 width, + INT32 height) +{ + Bool ret; + RegionRec crtc_region_local; + RegionPtr crtc_region = reg; + + if (crtc_ret) { + BoxRec crtc_box; + xf86CrtcPtr crtc = xf86_covering_crtc(pScrn, dst, + desired_crtc, + &crtc_box); + + if (crtc) { + RegionInit(&crtc_region_local, &crtc_box, 1); + crtc_region = &crtc_region_local; + RegionIntersect(crtc_region, crtc_region, reg); + } + *crtc_ret = crtc; + } + + ret = xf86XVClipVideoHelper(dst, xa, xb, ya, yb, + crtc_region, width, height); + + if (crtc_region != reg) + RegionUninit(&crtc_region_local); + + return ret; +} + +xf86_crtc_notify_proc_ptr +xf86_wrap_crtc_notify (ScreenPtr screen, xf86_crtc_notify_proc_ptr new) +{ + if (xf86CrtcConfigPrivateIndex != -1) + { + ScrnInfoPtr scrn = xf86Screens[screen->myNum]; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + xf86_crtc_notify_proc_ptr old; + + old = config->xf86_crtc_notify; + config->xf86_crtc_notify = new; + return old; + } + return NULL; +} + +void +xf86_unwrap_crtc_notify(ScreenPtr screen, xf86_crtc_notify_proc_ptr old) +{ + if (xf86CrtcConfigPrivateIndex != -1) + { + ScrnInfoPtr scrn = xf86Screens[screen->myNum]; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + + config->xf86_crtc_notify = old; + } +} + +void +xf86_crtc_notify(ScreenPtr screen) +{ + ScrnInfoPtr scrn = xf86Screens[screen->myNum]; + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); + + if (config->xf86_crtc_notify) + config->xf86_crtc_notify(screen); +} + +Bool +xf86_crtc_supports_gamma(ScrnInfoPtr pScrn) +{ + if (xf86CrtcConfigPrivateIndex != -1) { + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); + xf86CrtcPtr crtc; + + /* for multiple drivers loaded we need this */ + if (!xf86_config) + return FALSE; + if (xf86_config->num_crtc == 0) + return FALSE; + crtc = xf86_config->crtc[0]; + + return crtc->funcs->gamma_set != NULL; + } + + return FALSE; +} diff --git a/xorg-server/hw/xfree86/parser/Makefile.am b/xorg-server/hw/xfree86/parser/Makefile.am index fb5d49e88..1cd70e7a5 100644 --- a/xorg-server/hw/xfree86/parser/Makefile.am +++ b/xorg-server/hw/xfree86/parser/Makefile.am @@ -1,6 +1,6 @@ if INSTALL_LIBXF86CONFIG noinst_LTLIBRARIES = libxf86config_internal.la -lib_LIBRARIES = libxf86config.a +lib_LTLIBRARIES = libxf86config.la LIBHEADERS = \ xf86Optrec.h \ xf86Parser.h @@ -30,10 +30,11 @@ INTERNAL_SOURCES= \ libxf86config_internal_la_SOURCES = \ $(INTERNAL_SOURCES) -libxf86config_a_SOURCES = \ +libxf86config_la_SOURCES = \ $(top_srcdir)/os/xprintf.c \ $(INTERNAL_SOURCES) -libxf86config_a_CFLAGS = $(AM_CFLAGS) +libxf86config_la_CFLAGS = $(AM_CFLAGS) +libxf86config_la_LDFLAGS = -static AM_CFLAGS = $(DIX_CFLAGS) $(XORG_CFLAGS) \ -DSYSCONFDIR=\"$(sysconfdir)\" \ diff --git a/xorg-server/hw/xquartz/bundle/Info.plist.cpp b/xorg-server/hw/xquartz/bundle/Info.plist.cpp index 892eb5c19..2e568ffeb 100644 --- a/xorg-server/hw/xquartz/bundle/Info.plist.cpp +++ b/xorg-server/hw/xquartz/bundle/Info.plist.cpp @@ -1,47 +1,47 @@ - - - - - CFBundleDevelopmentRegion - English - CFBundleExecutable - X11 - CFBundleGetInfoString - LAUNCHD_ID_PREFIX.X11 - CFBundleIconFile - X11.icns - CFBundleIdentifier - LAUNCHD_ID_PREFIX.X11 - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - APPLE_APPLICATION_NAME - CFBundlePackageType - APPL - CFBundleShortVersionString - 2.6.0 - CFBundleVersion - 2.6.0 - CFBundleSignature - x11a - CSResourcesFileMapped - -#ifdef XQUARTZ_SPARKLE - SUEnableAutomaticChecks - - SUPublicDSAKeyFile - sparkle.pem - SUFeedURL - http://xquartz.macosforge.org/downloads/sparkle/release.xml -#endif - NSHumanReadableCopyright - © 2003-2010 Apple Inc. -© 2003 XFree86 Project, Inc. -© 2003-2010 X.org Foundation, Inc. - - NSMainNibFile - main - NSPrincipalClass - X11Application - - + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + X11 + CFBundleGetInfoString + LAUNCHD_ID_PREFIX.X11 + CFBundleIconFile + X11.icns + CFBundleIdentifier + LAUNCHD_ID_PREFIX.X11 + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + APPLE_APPLICATION_NAME + CFBundlePackageType + APPL + CFBundleShortVersionString + 2.6.1 + CFBundleVersion + 2.6.1 + CFBundleSignature + x11a + CSResourcesFileMapped + +#ifdef XQUARTZ_SPARKLE + SUEnableAutomaticChecks + + SUPublicDSAKeyFile + sparkle.pem + SUFeedURL + http://xquartz.macosforge.org/downloads/sparkle/release.xml +#endif + NSHumanReadableCopyright + © 2003-2011 Apple Inc. +© 2003 XFree86 Project, Inc. +© 2003-2011 X.org Foundation, Inc. + + NSMainNibFile + main + NSPrincipalClass + X11Application + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/locversion.plist index 89bff961c..f95033644 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - nl - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + nl + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/designable.nib index 0c48586f7..4b030d359 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/designable.nib @@ -1,3604 +1,3758 @@ - - - - 1040 - 11A79a - 784 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 784 - - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Over X11 - - 2147483647 - - - - - - Voorkeuren... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Voorzieningen - - 1048576 - 2147483647 - - - submenuAction: - - Voorzieningen - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Schermvullende weergave aan/uit - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Verberg X11 - h - 1048576 - 2147483647 - - - 42 - - - - Verberg andere - h - 1572864 - 2147483647 - - - - - - Toon alles - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Stop X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Programma's - - 1048576 - 2147483647 - - - submenuAction: - - Programma's - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Pas aan... - - 1048576 - 2147483647 - - - - - - - - - Wijzig - - 1048576 - 2147483647 - - - submenuAction: - - Wijzig - - - - Kopieer - c - 1048576 - 2147483647 - - - - - - - - - Venster - - 1048576 - 2147483647 - - - submenuAction: - - Venster - - - - Sluit - w - 1048576 - 2147483647 - - - - - - Minimaliseer - m - 1048576 - 2147483647 - - - - - - Vergroot/verklein - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Blader door vensters - ` - 1048840 - 2147483647 - - - - - - Blader omgekeerd door vensters - ~ - 1179914 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Alles op voorgrond - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Help - - 1048576 - 2147483647 - - - submenuAction: - - Help - - - - X11 Help - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 364}, {564, 308}} - 1350041600 - X11-voorkeuren - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {538, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 215}, {402, 18}} - - YES - - 67239424 - 0 - Emuleer drieknopsmuis - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 55}, {480, 42}} - - YES - - 67239424 - 4194304 - Als u deze optie inschakelt, kan het gebruik van toetscombinaties voor menucommado's conflicteren met X11-programma's die de Meta-modifier gebruiken. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 179}, {468, 34}} - - YES - - 67239424 - 4194304 - SG91ZCB0aWpkZW5zIGhldCBrbGlra2VuIGRlIE9wdGlvbi0gb2YgQ29tbWFuZC10b2V0cyBpbmdlZHJ1 -a3Qgb20gZGUgbWlkZGVsc3RlIG11aXNrbm9wIG9mIGRlIHJlY2h0ZXJtdWlza25vcCB0ZSBhY3RpdmVy -ZW4uCg - - - - - - - - - - 256 - {{18, 99}, {402, 18}} - - YES - - 67239424 - 0 - Activeer toetscombinaties onder X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 126}, {468, 29}} - - YES - - 67239424 - 4194304 - Maakt het mogelijk dat wijzigingen in het invoermenu de X11-toetsenbordindeling overschrijven. - - - - - - - - - - 256 - {{18, 157}, {402, 18}} - - YES - - 67239424 - 0 - Volg toetsenbordindeling van systeem - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 8}, {468, 31}} - - YES - - 67239424 - 4194304 - Indien ingeschakeld, worden met de Option-toetsen de X11-toetssymbolen Alt_L en Alt_R verstuurd in plaats van Mode_switch. - - - - - - - - - 256 - {{18, 41}, {402, 18}} - - YES - - 67239424 - 0 - Option-toetsen versturen Alt_L en Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {518, 246}} - - - Invoer - - - - - - 2 - - - - 256 - - - - 256 - {{18, 61}, {402, 18}} - - YES - - 67239424 - 0 - Gebruik waarschuwingssignaal van systeem - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 13}, {468, 42}} - - YES - - 67239424 - 4194304 - Voor X11-geluidssignalen wordt het waarschuwingssignaal van het systeem gebruikt, zoals ingesteld in het tabblad 'Geluidseffecten' van het systeemvoorkeurenpaneel 'Geluid'. - - - - - - - - - - 256 - {{74, 202}, {168, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Van beeldscherm - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 kleuren - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Duizenden - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Miljoenen - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 206}, {58, 20}} - - YES - - 67239424 - 4194304 - Kleuren: - - - - - - - - - - 256 - {{36, 184}, {392, 14}} - - YES - - 67239424 - 4194304 - Deze instelling wordt actief wanneer X11 opnieuw wordt gestart. - - - - - - - - - - 256 - {{18, 150}, {409, 23}} - - YES - - 67239424 - 0 - Schermvullende weergave - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 84}, {409, 23}} - - YES - - 67239424 - 0 - Toon menubalk automatisch in schermvullende weergave - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 113}, {468, 31}} - - YES - - 67239424 - 4194304 - Schakelt het X11-rootvenster in. Gebruik de toetscombinatie Command + Option + A om de schermvullende weergave te starten en te stoppen. - - - - - - - - - {{10, 33}, {518, 246}} - - Uitvoer - - - - - - 2 - - - - 256 - - - - 256 - {{12, 222}, {409, 23}} - - YES - - 67239424 - 0 - Schakel synchronisatie in - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{30, 174}, {473, 42}} - - YES - - 67239424 - 4194304 - Schakelt het menuonderdeel 'kopieer' in en maakt synchronisatie mogelijk tussen het klembord van OS X en de CLIPBOARD- en PRIMARY-buffer van X11. - - - - - - - - - 256 - {{28, 96}, {409, 23}} - - YES - - 67239424 - 0 - Werk CLIPBOARD bij als plakbord wordt gewijzigd - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{28, 71}, {409, 23}} - - YES - - 67239424 - 0 - Werk PRIMARY (middenklik) bij als plakbord wordt gewijzigd - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{28, 51}, {486, 18}} - - YES - - 67239424 - 0 - Werk plakbord onmiddellijk bij wanneer nieuwe tekst wordt geselecteerd - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{28, 159}, {409, 23}} - - YES - - 67239424 - 0 - Werk plakbord bij als CLIPBOARD wordt gewijzigd - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{42, 125}, {461, 28}} - - YES - - 67239424 - 4194304 - Schakel deze optie uit als u xclipboard, klipper of een ander programma voor X11-klembordbeheer wilt gebruiken. - - - - - - - - - 256 - {{42, 19}, {461, 28}} - - YES - - 67239424 - 4194304 - Vanwege beperkingen in het X11-protocol werkt deze optie mogelijk niet altijd in alle programma's. - - - - - - - - {{10, 33}, {518, 246}} - - Plakbord - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Klik in inactieve vensters - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {481, 31}} - - YES - - 67239424 - 4194304 - Indien ingeschakeld, wordt een muisklik in een inactief venster toegepast in dat venster en wordt het venster geactiveerd. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Focus volgt muis - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 129}, {481, 16}} - - YES - - 67239424 - 4194304 - Focus van het X11-venster volgt de aanwijzer. Dit heeft ongewenste effecten. - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - Focus op nieuwe vensters - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 59}, {481, 42}} - - YES - - 67239424 - 4194304 - Indien ingeschakeld, wordt bij aanmaak van een nieuw X11-venster X11.app op de voorgrond geplaatst (in plaats van Finder.app, Terminal.app, enz.). - - - - - - - - {{10, 33}, {518, 246}} - - Vensters - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Voer identiteitscontrole uit voor verbindingen - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 119}, {402, 18}} - - YES - - 67239424 - 0 - Sta verbindingen van netwerkclients toe - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 148}, {468, 56}} - - YES - - 67239424 - 4194304 - Wanneer u X11 start, worden er Xauthority-toegangscontrolesleutels aangemaakt. Als het IP-adres van het systeem wordt gewijzigd, worden deze toetsen ongeldig waardoor het mogelijk is dat X11-programma's niet kunnen worden gestart. - - - - - - - - - - 256 - {{36, 57}, {468, 56}} - - YES - - 67239424 - 4194304 - Als u deze optie inschakelt, moet 'Voer identiteitscontrole uit voor verbindingen' ook worden ingeschakeld ter beveiliging van het systeem. Als deze optie is uitgeschakeld, worden verbindingen van externe programma's niet toegestaan. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Deze instellingen worden actief wanneer X11 opnieuw wordt gestart. - - - - - - - - - {{10, 33}, {518, 246}} - - Beveiliging - - - - - - - 0 - YES - YES - - - - - - {564, 308} - - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {454, 271}} - 1350041600 - X11-programmamenu - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {100, 32}} - - YES - - 67239424 - 137887744 - Dupliceer - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {100, 32}} - - YES - - 67239424 - 137887744 - Verwijder - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 121.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Naam - - - 3 - MC4zMzMzMzI5OQA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Tekstcel - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 99 - 40 - 1000 - - 75628096 - 2048 - Commando - - - - - - 338820672 - 1024 - Tekstcel - - - - - - - 3 - YES - YES - - - - 71 - 10 - 1000 - - 75628096 - 2048 - Toetsen - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Tekstcel - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492380000000002 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460000000004 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {100, 32}} - - YES - - -2080244224 - 137887744 - Voeg toe - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Menu - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Programma's - - 1048576 - 2147483647 - - - submenuAction: - - Programma's - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Pas aan… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{310, 988}, {127, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{370, 868}, {313, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 565}, {564, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 565}, {564, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{203, 978}, {131, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {356, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{440, 988}, {128, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{84, 998}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{157, 808}, {319, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Over X11 + + 2147483647 + + + + + + Voorkeuren... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Voorzieningen + + 1048576 + 2147483647 + + + submenuAction: + + Voorzieningen + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Schermvullende weergave aan/uit + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Verberg X11 + h + 1048576 + 2147483647 + + + 42 + + + + Verberg andere + h + 1572864 + 2147483647 + + + + + + Toon alles + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Stop X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Programma's + + 1048576 + 2147483647 + + + submenuAction: + + Programma's + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Pas aan... + + 1048576 + 2147483647 + + + + + + + + + Wijzig + + 1048576 + 2147483647 + + + submenuAction: + + Wijzig + + + + Kopieer + c + 1048576 + 2147483647 + + + + + + + + + Venster + + 1048576 + 2147483647 + + + submenuAction: + + Venster + + + + Sluit + w + 1048576 + 2147483647 + + + + + + Minimaliseer + m + 1048576 + 2147483647 + + + + + + Vergroot/verklein + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Blader door vensters + ` + 1048840 + 2147483647 + + + + + + Blader omgekeerd door vensters + ~ + 1179914 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Alles op voorgrond + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Help + + 1048576 + 2147483647 + + + submenuAction: + + Help + + + + X11 Help + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 364}, {564, 308}} + 1350041600 + X11-voorkeuren + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {538, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 215}, {402, 18}} + + YES + + 67239424 + 0 + Emuleer drieknopsmuis + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 55}, {480, 42}} + + YES + + 67239424 + 4194304 + Als u deze optie inschakelt, kan het gebruik van toetscombinaties voor menucommado's conflicteren met X11-programma's die de Meta-modifier gebruiken. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 179}, {468, 34}} + + YES + + 67239424 + 4194304 + SG91ZCB0aWpkZW5zIGhldCBrbGlra2VuIGRlIE9wdGlvbi0gb2YgQ29tbWFuZC10b2V0cyBpbmdlZHJ1 +a3Qgb20gZGUgbWlkZGVsc3RlIG11aXNrbm9wIG9mIGRlIHJlY2h0ZXJtdWlza25vcCB0ZSBhY3RpdmVy +ZW4uCg + + + + + + + + + + 256 + {{18, 99}, {402, 18}} + + YES + + 67239424 + 0 + Activeer toetscombinaties onder X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 126}, {468, 29}} + + YES + + 67239424 + 4194304 + Maakt het mogelijk dat wijzigingen in het invoermenu de X11-toetsenbordindeling overschrijven. + + + + + + + + + + 256 + {{18, 157}, {402, 18}} + + YES + + 67239424 + 0 + Volg toetsenbordindeling van systeem + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 8}, {468, 31}} + + YES + + 67239424 + 4194304 + Indien ingeschakeld, worden met de Option-toetsen de X11-toetssymbolen Alt_L en Alt_R verstuurd in plaats van Mode_switch. + + + + + + + + + 256 + {{18, 41}, {402, 18}} + + YES + + 67239424 + 0 + Option-toetsen versturen Alt_L en Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {518, 246}} + + Invoer + + + + + + 2 + + + + 256 + + + + 256 + {{74, 202}, {168, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Van beeldscherm + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 kleuren + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Duizenden + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Miljoenen + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 206}, {58, 20}} + + YES + + 67239424 + 4194304 + Kleuren: + + + + + + + + + + 256 + {{36, 184}, {392, 14}} + + YES + + 67239424 + 4194304 + Deze instelling wordt actief wanneer X11 opnieuw wordt gestart. + + + + + + + + + + 256 + {{18, 150}, {409, 23}} + + YES + + 67239424 + 0 + Schermvullende weergave + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 84}, {409, 23}} + + YES + + 67239424 + 0 + Toon menubalk automatisch in schermvullende weergave + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 113}, {468, 31}} + + YES + + 67239424 + 4194304 + Schakelt het X11-rootvenster in. Gebruik de toetscombinatie Command + Option + A om de schermvullende weergave te starten en te stoppen. + + + + + + + + + {{10, 33}, {518, 246}} + + + Uitvoer + + + + + + 2 + + + + 256 + + + + 256 + {{12, 222}, {409, 23}} + + YES + + 67239424 + 0 + Schakel synchronisatie in + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{30, 174}, {473, 42}} + + YES + + 67239424 + 4194304 + Schakelt het menuonderdeel 'kopieer' in en maakt synchronisatie mogelijk tussen het klembord van OS X en de CLIPBOARD- en PRIMARY-buffer van X11. + + + + + + + + + 256 + {{28, 96}, {409, 23}} + + YES + + 67239424 + 0 + Werk CLIPBOARD bij als plakbord wordt gewijzigd + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{28, 71}, {409, 23}} + + YES + + 67239424 + 0 + Werk PRIMARY (middenklik) bij als plakbord wordt gewijzigd + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{28, 51}, {486, 18}} + + YES + + 67239424 + 0 + Werk plakbord onmiddellijk bij wanneer nieuwe tekst wordt geselecteerd + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{28, 159}, {409, 23}} + + YES + + 67239424 + 0 + Werk plakbord bij als CLIPBOARD wordt gewijzigd + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{42, 125}, {461, 28}} + + YES + + 67239424 + 4194304 + Schakel deze optie uit als u xclipboard, klipper of een ander programma voor X11-klembordbeheer wilt gebruiken. + + + + + + + + + 256 + {{42, 19}, {461, 28}} + + YES + + 67239424 + 4194304 + Vanwege beperkingen in het X11-protocol werkt deze optie mogelijk niet altijd in alle programma's. + + + + + + + + {{10, 33}, {518, 246}} + + Plakbord + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Klik in inactieve vensters + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {481, 31}} + + YES + + 67239424 + 4194304 + Indien ingeschakeld, wordt een muisklik in een inactief venster toegepast in dat venster en wordt het venster geactiveerd. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Focus volgt muis + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 129}, {481, 16}} + + YES + + 67239424 + 4194304 + Focus van het X11-venster volgt de aanwijzer. Dit heeft ongewenste effecten. + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + Focus op nieuwe vensters + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 59}, {481, 42}} + + YES + + 67239424 + 4194304 + Indien ingeschakeld, wordt bij aanmaak van een nieuw X11-venster X11.app op de voorgrond geplaatst (in plaats van Finder.app, Terminal.app, enz.). + + + + + + + + {{10, 33}, {518, 246}} + + Vensters + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Voer identiteitscontrole uit voor verbindingen + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 119}, {402, 18}} + + YES + + 67239424 + 0 + Sta verbindingen van netwerkclients toe + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 148}, {468, 56}} + + YES + + 67239424 + 4194304 + Wanneer u X11 start, worden er Xauthority-toegangscontrolesleutels aangemaakt. Als het IP-adres van het systeem wordt gewijzigd, worden deze toetsen ongeldig waardoor het mogelijk is dat X11-programma's niet kunnen worden gestart. + + + + + + + + + + 256 + {{36, 57}, {468, 56}} + + YES + + 67239424 + 4194304 + Als u deze optie inschakelt, moet 'Voer identiteitscontrole uit voor verbindingen' ook worden ingeschakeld ter beveiliging van het systeem. Als deze optie is uitgeschakeld, worden verbindingen van externe programma's niet toegestaan. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Deze instellingen worden actief wanneer X11 opnieuw wordt gestart. + + + + + + + + + {{10, 33}, {518, 246}} + + Beveiliging + + + + + + + 0 + YES + YES + + + + + + {564, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {454, 271}} + 1350041600 + X11-programmamenu + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {100, 32}} + + YES + + 67239424 + 137887744 + Dupliceer + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {100, 32}} + + YES + + 67239424 + 137887744 + Verwijder + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 121.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Naam + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Tekstcel + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 99 + 40 + 1000 + + 75628096 + 2048 + Commando + + + + + + 338820672 + 1024 + Tekstcel + + + + + + + 3 + YES + YES + + + + 71 + 10 + 1000 + + 75628096 + 2048 + Toetsen + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Tekstcel + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {100, 32}} + + YES + + -2080244224 + 137887744 + Voeg toe + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Menu + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Programma's + + 1048576 + 2147483647 + + + submenuAction: + + Programma's + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Pas aan… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/keyedobjects.nib index 9523b392e..4063cfba9 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/Dutch.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/German.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/German.lproj/locversion.plist index 2db6f0f2e..313b57752 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/German.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/German.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - de - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + de + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/designable.nib index 96ddae515..d34ff7266 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/designable.nib @@ -1,3595 +1,3507 @@ - - - - 1040 - 10A432 - 732 - 1038 - 437.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 732 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - PluginDependencyRecalculationVersion - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Ãœber X11 - - 2147483647 - - - - - - Einstellungen … - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Dienste - - 1048576 - 2147483647 - - - submenuAction: - - Dienste - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Vollbildmodus ein-/ausschalten - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - X11 ausblenden - h - 1048576 - 2147483647 - - - 42 - - - - Andere ausblenden - h - 1572864 - 2147483647 - - - - - - Alle einblenden - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - X11 beenden - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Programme - - 1048576 - 2147483647 - - - submenuAction: - - Programme - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Anpassen … - - 1048576 - 2147483647 - - - - - - - - - Bearbeiten - - 1048576 - 2147483647 - - - submenuAction: - - Bearbeiten - - - - Kopieren - c - 1048576 - 2147483647 - - - - - - - - - Fenster - - 1048576 - 2147483647 - - - submenuAction: - - Fenster - - - - Schließen - w - 1048576 - 2147483647 - - - - - - Im Dock ablegen - m - 1048576 - 2147483647 - - - - - - Zoomen - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Vorwärts blättern - < - 1048576 - 2147483647 - - - - - - Rückwärts blättern - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Alle nach vorne bringen - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Hilfe - - 1048576 - 2147483647 - - - submenuAction: - - Hilfe - - - - X11 Hilfe - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{2350, 1291}, {613, 302}} - 1350041600 - X11 Einstellungen - NSPanel - - View - - {3.40282e+38, 3.40282e+38} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {579, 286}} - - - - - - 1 - - - - 256 - - - - 256 - {{18, 211}, {402, 18}} - - - YES - - 67239424 - 0 - Drei Maustasten nachbilden - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 60}, {376, 28}} - - - YES - - 67239424 - 4194304 - Bei Aktivierung können die Tastenentsprechungen für die Menüleiste die X11-Programme stören, die Meta-Sondertasten verwenden. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2ODY1AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 171}, {385, 34}} - - - YES - - 67239424 - 4194304 - SGFsdGVuIFNpZSBiZWltIEtsaWNrZW4gZGllIFdhaGx0YXN0ZSBvZGVyIGRpZSBCZWZlaGxzdGFzdGUg -Z2VkcsO8Y2t0LCB1bSBkaWUgbWl0dGxlcmUgb2RlciBkaWUgcmVjaHRlIE1hdXN0YXN0ZSB6dSBha3Rp -dmllcmVuLgo - - - - - - - - - - 256 - {{18, 94}, {402, 18}} - - - YES - - 67239424 - 0 - Tastenentsprechungen unter X11 aktivieren - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 118}, {385, 28}} - - - YES - - 67239424 - 4194304 - Bei Aktivierung kann Ihre aktuelle X11-Keymap durch Änderungen des Tastaturmenüs überschrieben werden. - - - - - - - - - - 256 - {{18, 152}, {402, 18}} - - - YES - - 67239424 - 0 - Tastaturbelegung des Systems verwenden - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - - YES - - 67239424 - 4194304 - Bei Aktivierung entsprechen die Wahltasten Alt_L und Alt_R X11-Tastensymbolen anstatt „Mode_switch“. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - - YES - - 67239424 - 0 - Wahltasten entsprechen Alt_L und Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {559, 240}} - - - - Eingabe - - - - - - 2 - - - - 256 - - - - 256 - {{15, 61}, {402, 18}} - - YES - - 67239424 - 0 - System-Warneffekte verwenden - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{33, 27}, {385, 28}} - - YES - - 67239424 - 4194304 - X11 verwendet als akustischen Signalton den Standard-Warnton, wie in der Systemeinstellung „Toneffekte“ festgelegt. - - - - - - - - - - 256 - {{74, 210}, {197, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Vom Monitor - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 Farben - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - 32768 Farben - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - 16,7 Millionen Farben - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 214}, {55, 20}} - - YES - - 67239424 - 4194304 - Farben: - - - - - - - - - - 256 - {{36, 192}, {392, 14}} - - YES - - 67239424 - 4194304 - Diese Option wird beim nächsten Start von X11 wirksam. - - - - - - - - - - 256 - {{15, 158}, {409, 23}} - - YES - - 67239424 - 0 - Vollbildmodus - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 81}, {409, 23}} - - YES - - 67239424 - 0 - Menüleiste automatisch im Vollbildmodus anzeigen - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{33, 110}, {383, 42}} - - YES - - 67239424 - 4194304 - Hiermit wird das X11-Hauptfenster aktiviert. Verwenden Sie die Tastenkombination Befehl+Wahl+A, um den Vollbildmodus ein- oder auszuschalten. - - - - - - - - - {{10, 33}, {559, 240}} - - Ausgabe - - - - - - 2 - - - - 256 - - - - 256 - {{18, 216}, {409, 23}} - - YES - - 67239424 - 0 - Synchronisierung aktivieren - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 182}, {464, 28}} - - YES - - 67239424 - 4194304 - Aktiviert das Menüobjekt „Kopieren“ und ermöglicht die Synchronisierung zwischen dem „OSX Pasteboard“ und den Pufferspeichern „CLIPBOARD“ und „PRIMARY“ von X11. - - - - - - - - - 256 - {{34, 100}, {436, 18}} - - YES - - 67239424 - 0 - CLIPBOARD aktualisieren, wenn Pasteboard geändert wird - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 72}, {463, 18}} - - YES - - 67239424 - 0 - PRIMARY (Mittel-Klick) aktualisieren, wenn Pasteboard geändert wird - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 43}, {498, 18}} - - YES - - 67239424 - 0 - Pasteboard sofort aktualisieren, wenn Text ausgewählt wird - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 158}, {438, 18}} - - YES - - 67239424 - 0 - Pasteboard aktualisieren, wenn CLIPBOARD geändert wird - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 129}, {401, 28}} - - YES - - 67239424 - 4194304 - Deaktivieren Sie diese Option, wenn Sie „xclipboard“, „klipper“ oder einen beliebigen anderen X11-Zwischenablage-Manager verwenden möchten. - - - - - - - - - 256 - {{48, 9}, {497, 28}} - - YES - - 67239424 - 4194304 - Aufgrund von Einschränkungen im X11-Protokoll funktioniert diese Option in manchen Programmen u. U. nicht immer. - - - - - - - - {{10, 33}, {559, 240}} - - Zwischenablage - - - - - - 2 - - - - 256 - - - - 256 - {{15, 206}, {213, 18}} - - YES - - 67239424 - 0 - Durch inaktive Fenster klicken - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 172}, {456, 28}} - - YES - - 67239424 - 4194304 - Bei Aktivierung wird beim Klicken auf ein inaktives Fenster der Mausklick zusätzlich an dieses Fenster weitergegeben. - - - - - - - - - 256 - {{15, 145}, {155, 18}} - - YES - - 67239424 - 0 - Fokus folgt der Maus - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 122}, {442, 17}} - - YES - - 67239424 - 4194304 - Der Fokus des X11-Fensters folgt dem Cursor. Dies hat einige nachteilige Effekte. - - - - - - - - - 256 - {{15, 101}, {402, 18}} - - YES - - 67239424 - 0 - Fokus auf neuem Fenster - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 53}, {456, 42}} - - YES - - 67239424 - 4194304 - Bei Aktivierung wird beim Erzeugen eines neuen X11-Fensters das „X11.app“ in den Vordergrund gebracht (anstelle von „Finder.app“, „Terminal.app“ usw.). - - - - - - - - {{10, 33}, {559, 240}} - - Fenster - - - - - - - 256 - - - - 256 - {{18, 204}, {215, 18}} - - YES - - 67239424 - 0 - Verbindungen authentifizieren - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 121}, {312, 18}} - - YES - - 67239424 - 0 - Verbindungen von Netzwerk-Clients erlauben - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 150}, {463, 48}} - - YES - - 67239424 - 4194304 - Beim Starten von X11 werden Xauthority-Schlüssel zur Zugriffskontrolle erstellt. Wenn sich die IP-Adresse des Systems ändert, sind diese Schlüssel nicht mehr gültig. Möglicherweise können die X11-Programme dann nicht mehr gestartet werden. - - - - - - - - - - 256 - {{36, 59}, {463, 56}} - - YES - - 67239424 - 4194304 - Bei Aktivierung muss „Verbindungen authentifizieren“ ebenfalls aktiviert sein, damit die Sicherheit des System gewährleistet ist. Bei Deaktivierung sind Verbindungen von entfernten Programmen nicht erlaubt. - - - - - - - - - - 256 - {{20, -22}, {404, 14}} - - YES - - 67239424 - 4194304 - Diese Optionen werden beim nächsten Start von X11 wirksam. - - - - - - - - - {{10, 33}, {559, 240}} - - Sicherheit - - - - - - - 0 - YES - YES - - - - - - {613, 302} - - - - {{0, 0}, {1440, 878}} - {320, 262} - {3.40282e+38, 3.40282e+38} - x11_prefs - - - 11 - 2 - {{360, 400}, {512, 271}} - 1350041600 - X11-Programmmenü - NSPanel - - View - - {3.40282e+38, 3.40282e+38} - {512, 240} - - - 256 - - - - 265 - {{340, 191}, {158, 32}} - - YES - - 67239424 - 137887744 - Duplizieren - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {158, 32}} - - YES - - 67239424 - 137887744 - Entfernen - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 122.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Name - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Textzelle - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 100 - 40 - 1000 - - 75628096 - 2048 - Befehl - - - - - - 338820672 - 1024 - Textzelle - - - - - - - 3 - YES - YES - - - - 69 - 10 - 1000 - - 75628096 - 2048 - Kurzbefehl - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Textzelle - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - 4 - - - - {{20, 20}, {318, 231}} - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {158, 32}} - - YES - - -2080244224 - 137887744 - Objekt hinzufügen - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {512, 271} - - {{0, 0}, {1440, 878}} - {512, 262} - {3.40282e+38, 3.40282e+38} - x11_apps - - - Menü - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Programme - - 1048576 - 2147483647 - - - submenuAction: - - Programme - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Anpassen … - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 554}, {613, 302}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 554}, {613, 302}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {512, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {512, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {512, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - + + + + 1040 + 11A194b + 787 + 1079 + 502.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 787 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Ãœber X11 + + 2147483647 + + + + + + Einstellungen … + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Dienste + + 1048576 + 2147483647 + + + submenuAction: + + Dienste + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Vollbildmodus ein-/ausschalten + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + X11 ausblenden + h + 1048576 + 2147483647 + + + 42 + + + + Andere ausblenden + h + 1572864 + 2147483647 + + + + + + Alle einblenden + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + X11 beenden + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Programme + + 1048576 + 2147483647 + + + submenuAction: + + Programme + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Anpassen … + + 1048576 + 2147483647 + + + + + + + + + Bearbeiten + + 1048576 + 2147483647 + + + submenuAction: + + Bearbeiten + + + + Kopieren + c + 1048576 + 2147483647 + + + + + + + + + Fenster + + 1048576 + 2147483647 + + + submenuAction: + + Fenster + + + + Schließen + w + 1048576 + 2147483647 + + + + + + Im Dock ablegen + m + 1048576 + 2147483647 + + + + + + Zoomen + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Vorwärts blättern + < + 1048576 + 2147483647 + + + + + + Rückwärts blättern + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Alle nach vorne bringen + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Hilfe + + 1048576 + 2147483647 + + + submenuAction: + + Hilfe + + + + X11 Hilfe + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{2350, 1291}, {613, 302}} + 1350041600 + X11 Einstellungen + NSPanel + + View + + + {3.4028235e+38, 3.4028235e+38} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {579, 286}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 211}, {402, 18}} + + YES + + 67239424 + 0 + Drei Maustasten nachbilden + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 60}, {376, 28}} + + YES + + 67239424 + 4194304 + Bei Aktivierung können die Tastenentsprechungen für die Menüleiste die X11-Programme stören, die Meta-Sondertasten verwenden. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2ODY1AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 171}, {385, 34}} + + YES + + 67239424 + 4194304 + SGFsdGVuIFNpZSBiZWltIEtsaWNrZW4gZGllIFdhaGx0YXN0ZSBvZGVyIGRpZSBCZWZlaGxzdGFzdGUg +Z2VkcsO8Y2t0LCB1bSBkaWUgbWl0dGxlcmUgb2RlciBkaWUgcmVjaHRlIE1hdXN0YXN0ZSB6dSBha3Rp +dmllcmVuLgo + + + + + + + + + + 256 + {{18, 94}, {402, 18}} + + YES + + 67239424 + 0 + Tastenentsprechungen unter X11 aktivieren + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 118}, {385, 28}} + + YES + + 67239424 + 4194304 + Bei Aktivierung kann Ihre aktuelle X11-Keymap durch Änderungen des Tastaturmenüs überschrieben werden. + + + + + + + + + + 256 + {{18, 152}, {402, 18}} + + YES + + 67239424 + 0 + Tastaturbelegung des Systems verwenden + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + Bei Aktivierung entsprechen die Wahltasten Alt_L und Alt_R X11-Tastensymbolen anstatt „Mode_switch“. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Wahltasten entsprechen Alt_L und Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {559, 240}} + + + Eingabe + + + + + + 2 + + + + 256 + + + + 256 + {{74, 210}, {197, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + 16,7 Millionen Farben + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + YES + + + OtherViews + + + + + Vom Monitor + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + + + 256 Farben + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + 32768 Farben + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + + 3 + 3 + YES + YES + 1 + + + + + 256 + {{17, 214}, {55, 20}} + + YES + + 67239424 + 4194304 + Farben: + + + + + + + + + + 256 + {{36, 192}, {392, 14}} + + YES + + 67239424 + 4194304 + Diese Option wird beim nächsten Start von X11 wirksam. + + + + + + + + + + 256 + {{15, 158}, {409, 23}} + + YES + + 67239424 + 0 + Vollbildmodus + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 81}, {409, 23}} + + YES + + 67239424 + 0 + Menüleiste automatisch im Vollbildmodus anzeigen + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{33, 110}, {383, 42}} + + YES + + 67239424 + 4194304 + Hiermit wird das X11-Hauptfenster aktiviert. Verwenden Sie die Tastenkombination Befehl+Wahl+A, um den Vollbildmodus ein- oder auszuschalten. + + + + + + + + + {{10, 33}, {559, 240}} + + Ausgabe + + + + + + 2 + + + + 256 + + + + 256 + {{18, 216}, {409, 23}} + + YES + + 67239424 + 0 + Synchronisierung aktivieren + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 182}, {464, 28}} + + YES + + 67239424 + 4194304 + Aktiviert das Menüobjekt „Kopieren“ und ermöglicht die Synchronisierung zwischen dem „OSX Pasteboard“ und den Pufferspeichern „CLIPBOARD“ und „PRIMARY“ von X11. + + + + + + + + + 256 + {{34, 100}, {436, 18}} + + YES + + 67239424 + 0 + CLIPBOARD aktualisieren, wenn Pasteboard geändert wird + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 72}, {463, 18}} + + YES + + 67239424 + 0 + PRIMARY (Mittel-Klick) aktualisieren, wenn Pasteboard geändert wird + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 43}, {498, 18}} + + YES + + 67239424 + 0 + Pasteboard sofort aktualisieren, wenn Text ausgewählt wird + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 158}, {438, 18}} + + YES + + 67239424 + 0 + Pasteboard aktualisieren, wenn CLIPBOARD geändert wird + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 124}, {401, 28}} + + YES + + 67239424 + 4194304 + Deaktivieren Sie diese Option, wenn Sie „xclipboard“, „klipper“ oder einen beliebigen anderen X11-Zwischenablage-Manager verwenden möchten. + + + + + + + + + 256 + {{48, 9}, {497, 28}} + + YES + + 67239424 + 4194304 + Aufgrund von Einschränkungen im X11-Protokoll funktioniert diese Option in manchen Programmen u. U. nicht immer. + + + + + + + + {{10, 33}, {559, 240}} + + Zwischenablage + + + + + + 2 + + + + 256 + + + + 256 + {{15, 206}, {213, 18}} + + YES + + 67239424 + 0 + Durch inaktive Fenster klicken + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 172}, {456, 28}} + + YES + + 67239424 + 4194304 + Bei Aktivierung wird beim Klicken auf ein inaktives Fenster der Mausklick zusätzlich an dieses Fenster weitergegeben. + + + + + + + + + 256 + {{15, 145}, {155, 18}} + + YES + + 67239424 + 0 + Fokus folgt der Maus + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 122}, {442, 17}} + + YES + + 67239424 + 4194304 + Der Fokus des X11-Fensters folgt dem Cursor. Dies hat einige nachteilige Effekte. + + + + + + + + + 256 + {{15, 101}, {402, 18}} + + YES + + 67239424 + 0 + Fokus auf neuem Fenster + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 53}, {456, 42}} + + YES + + 67239424 + 4194304 + Bei Aktivierung wird beim Erzeugen eines neuen X11-Fensters das „X11.app“ in den Vordergrund gebracht (anstelle von „Finder.app“, „Terminal.app“ usw.). + + + + + + + + {{10, 33}, {559, 240}} + + Fenster + + + + + + + 256 + + + + 256 + {{18, 204}, {215, 18}} + + YES + + 67239424 + 0 + Verbindungen authentifizieren + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 121}, {312, 18}} + + YES + + 67239424 + 0 + Verbindungen von Netzwerk-Clients erlauben + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 150}, {463, 48}} + + YES + + 67239424 + 4194304 + Beim Starten von X11 werden Xauthority-Schlüssel zur Zugriffskontrolle erstellt. Wenn sich die IP-Adresse des Systems ändert, sind diese Schlüssel nicht mehr gültig. Möglicherweise können die X11-Programme dann nicht mehr gestartet werden. + + + + + + + + + + 256 + {{36, 59}, {463, 56}} + + YES + + 67239424 + 4194304 + Bei Aktivierung muss „Verbindungen authentifizieren“ ebenfalls aktiviert sein, damit die Sicherheit des System gewährleistet ist. Bei Deaktivierung sind Verbindungen von entfernten Programmen nicht erlaubt. + + + + + + + + + + 256 + {{20, -22}, {404, 14}} + + YES + + 67239424 + 4194304 + Diese Optionen werden beim nächsten Start von X11 wirksam. + + + + + + + + + {{10, 33}, {559, 240}} + + Sicherheit + + + + + + + 0 + YES + YES + + + + + + {613, 302} + + {{0, 0}, {1440, 878}} + {320, 262} + {3.4028235e+38, 3.4028235e+38} + x11_prefs + + + 11 + 2 + {{360, 400}, {512, 271}} + 1350041600 + X11-Programmmenü + NSPanel + + View + + + {3.4028235e+38, 3.4028235e+38} + {512, 240} + + + 256 + + + + 265 + {{340, 191}, {158, 32}} + + YES + + 67239424 + 137887744 + Duplizieren + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {158, 32}} + + YES + + 67239424 + 137887744 + Entfernen + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 122.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Name + + + 3 + MC4zMzMzMzI5ODU2AA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Textzelle + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 100 + 40 + 1000 + + 75628096 + 2048 + Befehl + + + + + + 338820672 + 1024 + Textzelle + + + + + + + 3 + YES + YES + + + + 69 + 10 + 1000 + + 75628096 + 2048 + Kurzbefehl + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Textzelle + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492377042770386 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460384368896 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 50 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {158, 32}} + + YES + + -2080244224 + 137887744 + Objekt hinzufügen + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {512, 271} + + {{0, 0}, {1440, 878}} + {512, 262} + {3.4028235e+38, 3.4028235e+38} + x11_apps + + + Menü + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Programme + + 1048576 + 2147483647 + + + submenuAction: + + Programme + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Anpassen … + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{390, 203}, {613, 302}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{390, 203}, {613, 302}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {512, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{476, 379}, {215, 83}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/keyedobjects.nib index 20ede8b1c..f5df325d4 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/locversion.plist index 8e99c823e..54ff76e94 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - it - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + it + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/designable.nib index 0cf6b2e1d..37333dc50 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/designable.nib @@ -1,3591 +1,3761 @@ - - - - 1040 - 11A79a - 732 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 732 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Informazioni su X11 - - 2147483647 - - - - - - Preferenze... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Servizi - - 1048576 - 2147483647 - - - submenuAction: - - Servizi - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Alterna A tutto schermo - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Nascondi X11 - h - 1048576 - 2147483647 - - - 42 - - - - Nascondi altre - h - 1572864 - 2147483647 - - - - - - Mostra tutte - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Esci da X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Applicazioni - - 1048576 - 2147483647 - - - submenuAction: - - Applicazioni - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizza... - - 1048576 - 2147483647 - - - - - - - - - Composizione - - 1048576 - 2147483647 - - - submenuAction: - - Composizione - - - - Copia - c - 1048576 - 2147483647 - - - - - - - - - Finestra - - 1048576 - 2147483647 - - - submenuAction: - - Finestra - - - - Chiudi - w - 1048576 - 2147483647 - - - - - - Contrai - m - 1048576 - 2147483647 - - - - - - Ridimensiona - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Naviga tra le finestre - < - 1048576 - 2147483647 - - - - - - Inverti navigazione tra le finestre - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Porta tutto in primo piano - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Aiuto - - 1048576 - 2147483647 - - - submenuAction: - - Aiuto - - - - Aiuto X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{345, 450}, {664, 308}} - 1350041600 - Preferenze X11 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {638, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{75, 210}, {402, 18}} - - YES - - 67239424 - 0 - Emula mouse a tre pulsanti - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{93, 50}, {450, 31}} - - YES - - 67239424 - 4194304 - Se abilitati, gli equivalenti da tastiera della barra dei menu potrebbero interferire con le applicazioni X11 che utilizzano il modificatore Meta. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{93, 162}, {450, 42}} - - YES - - 67239424 - 4194304 - UGVyIGF0dGl2YXJlIGlsIHB1bHNhbnRlIGRlc3RybyBvIHF1ZWxsbyBjZW50cmFsZSBkZWwgbW91c2Us -IGZhaSBjbGljIHRlbmVuZG8gcHJlbXV0byBpbCBwdWxzYW50ZSBPcHppb25lIG8gaWwgcHVsc2FudGUg -Q29tYW5kby4KA - - - - - - - - - - 256 - {{75, 87}, {402, 18}} - - YES - - 67239424 - 0 - Abilita equivalenti da tastiera con X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{93, 111}, {450, 29}} - - YES - - 67239424 - 4194304 - Consente le modifiche del menu tastiera per riscrivere l'attuale mappa dei tasti X11. - - - - - - - - - - 256 - {{75, 146}, {402, 18}} - - YES - - 67239424 - 0 - Segui layout di tastiera di sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{93, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - Se abilitati, i tasti Opzione inviano i simboli dei tasti X11 Alt_L e Alt_R anziché Mode_switch. - - - - - - - - - 256 - {{75, 32}, {402, 18}} - - YES - - 67239424 - 0 - I tasti Opzione inviano Alt_L e Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {618, 246}} - - - Ingresso - - - - - - 2 - - - - 256 - - - - 256 - {{66, 57}, {402, 18}} - - YES - - 67239424 - 0 - Utilizza effetto avviso sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{84, 23}, {457, 28}} - - YES - - 67239424 - 4194304 - I bip di X11 utilizzeranno l'avviso sistema, come definito nel pannello Preferenze di Sistema degli Effetti sonori. - - - - - - - - - - 256 - {{115, 201}, {128, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Dal monitor - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 Colori - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Migliaia - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Milioni - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{65, 205}, {51, 20}} - - YES - - 67239424 - 4194304 - Colori: - - - - - - - - - - 256 - {{84, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Queste opzioni diventeranno effettive al successivo riavvio di X11. - - - - - - - - - - 256 - {{66, 149}, {409, 23}} - - YES - - 67239424 - 0 - Modalità a tutto schermo - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{85, 88}, {474, 18}} - - YES - - 67239424 - 0 - Mostra automaticamente la barra dei menu in modalità a tutto schermo - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{84, 112}, {457, 31}} - - YES - - 67239424 - 4194304 - Abilita la finestra root di X11. Utilizza la combinazione di tasti Comando-Opzione-A per attivare e disattivare la modalità a tutto schermo. - - - - - - - - - {{10, 33}, {618, 246}} - - Uscita - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - Abilita sincronizzazione - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {474, 28}} - - YES - - 67239424 - 4194304 - Abilita l'elemento “copia†del menu e consenti la sincronizzazione degli appunti di OSX e i buffer CLIPBOARD e PRIMARY di X11. - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - Aggiorna CLIPBOARD quando gli appunti cambiano - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {577, 23}} - - YES - - 67239424 - 0 - Aggiorna PRIMARY (clic con il pulsante centrale) quando gli appunti cambiano - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 51}, {470, 18}} - - YES - - 67239424 - 0 - Aggiorna immediatamente gli appunti quando si seleziona nuovo testo - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - Aggiorna gli appunti quando CLIPBOARD cambia - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {457, 28}} - - YES - - 67239424 - 4194304 - Se desideri utilizzare xclipboard, klipper o qualsiasi altro gestore di appunti di X11, disabilita questa opzione. - - - - - - - - - 256 - {{48, 19}, {462, 28}} - - YES - - 67239424 - 4194304 - A causa delle limitazioni del protocollo di X11, questa opzione in alcune applicazioni potrebbe non funzionare sempre. - - - - - - - - {{10, 33}, {618, 246}} - - Appunti - - - - - - 2 - - - - 256 - - - - 256 - {{72, 212}, {402, 18}} - - YES - - 67239424 - 0 - Clic finestre inattive - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{89, 175}, {453, 31}} - - YES - - 67239424 - 4194304 - Quando il riquadro è attivato, facendo clic su una finestra inattiva, il clic del mouse passerà a tale finestra e la attiverà. - - - - - - - - - 256 - {{72, 151}, {402, 18}} - - YES - - 67239424 - 0 - Messa a fuoco mediante il mouse - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{89, 117}, {460, 28}} - - YES - - 67239424 - 4194304 - La messa a fuoco della finestra di X11 avviene mediante il cursore. Questo può avere effetti controproducenti. - - - - - - - - - 256 - {{72, 96}, {402, 18}} - - YES - - 67239424 - 0 - Messa a fuoco sulle nuove finestre - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{89, 48}, {460, 42}} - - YES - - 67239424 - 4194304 - Quando il riquadro è attivato, la creazione di una nuova finestra di X11 farà spostare X11.app in primo piano (invece di Finder.app, Terminal.app, etc.) - - - - - - - - {{10, 33}, {618, 246}} - - Windows - - - - - - - 256 - - - - 256 - {{78, 210}, {402, 18}} - - YES - - 67239424 - 0 - Autentica connessioni - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{78, 124}, {402, 18}} - - YES - - 67239424 - 0 - Consente le connessioni da client network - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{96, 148}, {446, 56}} - - YES - - 67239424 - 4194304 - All'avvio di X11 verranno create le chiavi Xauthority per il controllo d'accesso. Se l'indirizzo IP del sistema cambia, tali chiavi non sono più valide. Questa situazione potrebbe bloccare l'avvio delle applicazioni X11. - - - - - - - - - - 256 - {{96, 62}, {446, 56}} - - YES - - 67239424 - 4194304 - Se possibile, per garantire la sicurezza del sistema deve essere inoltre abilitata la funzione Autentica connessioni. Quando questa funzione non è attiva, non sono consentite le connessioni dalle applicazioni remote. - - - - - - - - - - 256 - {{80, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Queste opzioni diventeranno effettive al successivo riavvio di X11. - - - - - - - - - {{10, 33}, {618, 246}} - - Protezione - - - - - - - 0 - YES - YES - - - - - - {664, 308} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {546, 271}} - 1350041600 - Menu applicazioni X11 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{372, 191}, {160, 32}} - - YES - - 67239424 - 137887744 - Duplica - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{372, 159}, {160, 32}} - - YES - - 67239424 - 137887744 - Rimuovi - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {333, 198} - - YES - - - 256 - {333, 17} - - - - - - 256 - {{334, 0}, {16, 17}} - - - - - 132.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Nome - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Cella di testo - - - - - 3 - MQA - - - - 3 - YES - YES - - - - - 110 - 40 - 1000 - - 75628096 - 2048 - Comando - - - - - - 338820672 - 1024 - Cella di testo - - - - - - - 3 - YES - YES - - - - - 81 - 10 - 1000 - - 75628096 - 2048 - Abbreviazione - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Cella di testo - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {333, 198}} - - - - - 4 - - - - 256 - {{334, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {333, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {333, 17}} - - - - - 4 - - - - {{20, 20}, {350, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{372, 223}, {160, 32}} - - YES - - -2080244224 - 137887744 - Aggiungi elemento - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {546, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Menu - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Applicazioni - - 1048576 - 2147483647 - - - submenuAction: - - Applicazioni - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizza… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {664, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{507, 548}, {664, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {546, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {546, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Informazioni su X11 + + 2147483647 + + + + + + Preferenze... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Servizi + + 1048576 + 2147483647 + + + submenuAction: + + Servizi + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Alterna A tutto schermo + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Nascondi X11 + h + 1048576 + 2147483647 + + + 42 + + + + Nascondi altre + h + 1572864 + 2147483647 + + + + + + Mostra tutte + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Esci da X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Applicazioni + + 1048576 + 2147483647 + + + submenuAction: + + Applicazioni + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizza... + + 1048576 + 2147483647 + + + + + + + + + Composizione + + 1048576 + 2147483647 + + + submenuAction: + + Composizione + + + + Copia + c + 1048576 + 2147483647 + + + + + + + + + Finestra + + 1048576 + 2147483647 + + + submenuAction: + + Finestra + + + + Chiudi + w + 1048576 + 2147483647 + + + + + + Contrai + m + 1048576 + 2147483647 + + + + + + Ridimensiona + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Naviga tra le finestre + < + 1048576 + 2147483647 + + + + + + Inverti navigazione tra le finestre + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Porta tutto in primo piano + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Aiuto + + 1048576 + 2147483647 + + + submenuAction: + + Aiuto + + + + Aiuto X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{345, 450}, {664, 308}} + 1350041600 + Preferenze X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {638, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{75, 210}, {402, 18}} + + YES + + 67239424 + 0 + Emula mouse a tre pulsanti + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{93, 50}, {450, 31}} + + YES + + 67239424 + 4194304 + Se abilitati, gli equivalenti da tastiera della barra dei menu potrebbero interferire con le applicazioni X11 che utilizzano il modificatore Meta. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{93, 162}, {450, 42}} + + YES + + 67239424 + 4194304 + UGVyIGF0dGl2YXJlIGlsIHB1bHNhbnRlIGRlc3RybyBvIHF1ZWxsbyBjZW50cmFsZSBkZWwgbW91c2Us +IGZhaSBjbGljIHRlbmVuZG8gcHJlbXV0byBpbCBwdWxzYW50ZSBPcHppb25lIG8gaWwgcHVsc2FudGUg +Q29tYW5kby4KA + + + + + + + + + + 256 + {{75, 87}, {402, 18}} + + YES + + 67239424 + 0 + Abilita equivalenti da tastiera con X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{93, 111}, {450, 29}} + + YES + + 67239424 + 4194304 + Consente le modifiche del menu tastiera per riscrivere l'attuale mappa dei tasti X11. + + + + + + + + + + 256 + {{75, 146}, {402, 18}} + + YES + + 67239424 + 0 + Segui layout di tastiera di sistema + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{93, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + Se abilitati, i tasti Opzione inviano i simboli dei tasti X11 Alt_L e Alt_R anziché Mode_switch. + + + + + + + + + 256 + {{75, 32}, {402, 18}} + + YES + + 67239424 + 0 + I tasti Opzione inviano Alt_L e Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {618, 246}} + + Ingresso + + + + + + 2 + + + + 256 + + + + 256 + {{115, 201}, {128, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Dal monitor + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 Colori + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Migliaia + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Milioni + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{65, 205}, {51, 20}} + + YES + + 67239424 + 4194304 + Colori: + + + + + + + + + + 256 + {{84, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Queste opzioni diventeranno effettive al successivo riavvio di X11. + + + + + + + + + + 256 + {{66, 149}, {409, 23}} + + YES + + 67239424 + 0 + Modalità a tutto schermo + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{85, 88}, {474, 18}} + + YES + + 67239424 + 0 + Mostra automaticamente la barra dei menu in modalità a tutto schermo + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{84, 112}, {457, 31}} + + YES + + 67239424 + 4194304 + Abilita la finestra root di X11. Utilizza la combinazione di tasti Comando-Opzione-A per attivare e disattivare la modalità a tutto schermo. + + + + + + + + + {{10, 33}, {618, 246}} + + + Uscita + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + Abilita sincronizzazione + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {474, 28}} + + YES + + 67239424 + 4194304 + Abilita l'elemento “copia†del menu e consenti la sincronizzazione degli appunti di OSX e i buffer CLIPBOARD e PRIMARY di X11. + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + Aggiorna CLIPBOARD quando gli appunti cambiano + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {577, 23}} + + YES + + 67239424 + 0 + Aggiorna PRIMARY (clic con il pulsante centrale) quando gli appunti cambiano + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 51}, {470, 18}} + + YES + + 67239424 + 0 + Aggiorna immediatamente gli appunti quando si seleziona nuovo testo + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + Aggiorna gli appunti quando CLIPBOARD cambia + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {457, 28}} + + YES + + 67239424 + 4194304 + Se desideri utilizzare xclipboard, klipper o qualsiasi altro gestore di appunti di X11, disabilita questa opzione. + + + + + + + + + 256 + {{48, 19}, {462, 28}} + + YES + + 67239424 + 4194304 + A causa delle limitazioni del protocollo di X11, questa opzione in alcune applicazioni potrebbe non funzionare sempre. + + + + + + + + {{10, 33}, {618, 246}} + + Appunti + + + + + + 2 + + + + 256 + + + + 256 + {{72, 212}, {402, 18}} + + YES + + 67239424 + 0 + Clic finestre inattive + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{89, 175}, {453, 31}} + + YES + + 67239424 + 4194304 + Quando il riquadro è attivato, facendo clic su una finestra inattiva, il clic del mouse passerà a tale finestra e la attiverà. + + + + + + + + + 256 + {{72, 151}, {402, 18}} + + YES + + 67239424 + 0 + Messa a fuoco mediante il mouse + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{89, 117}, {460, 28}} + + YES + + 67239424 + 4194304 + La messa a fuoco della finestra di X11 avviene mediante il cursore. Questo può avere effetti controproducenti. + + + + + + + + + 256 + {{72, 96}, {402, 18}} + + YES + + 67239424 + 0 + Messa a fuoco sulle nuove finestre + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{89, 48}, {460, 42}} + + YES + + 67239424 + 4194304 + Quando il riquadro è attivato, la creazione di una nuova finestra di X11 farà spostare X11.app in primo piano (invece di Finder.app, Terminal.app, etc.) + + + + + + + + {{10, 33}, {618, 246}} + + Finestre + + + + + + + 256 + + + + 256 + {{78, 210}, {402, 18}} + + YES + + 67239424 + 0 + Autentica connessioni + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{78, 124}, {402, 18}} + + YES + + 67239424 + 0 + Consente le connessioni da client network + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{96, 148}, {446, 56}} + + YES + + 67239424 + 4194304 + All'avvio di X11 verranno create le chiavi Xauthority per il controllo d'accesso. Se l'indirizzo IP del sistema cambia, tali chiavi non sono più valide. Questa situazione potrebbe bloccare l'avvio delle applicazioni X11. + + + + + + + + + + 256 + {{96, 62}, {446, 56}} + + YES + + 67239424 + 4194304 + Se possibile, per garantire la sicurezza del sistema deve essere inoltre abilitata la funzione Autentica connessioni. Quando questa funzione non è attiva, non sono consentite le connessioni dalle applicazioni remote. + + + + + + + + + + 256 + {{80, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Queste opzioni diventeranno effettive al successivo riavvio di X11. + + + + + + + + + {{10, 33}, {618, 246}} + + Protezione + + + + + + + 0 + YES + YES + + + + + + {664, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {546, 271}} + 1350041600 + Menu applicazioni X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{372, 191}, {160, 32}} + + YES + + 67239424 + 137887744 + Duplica + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{372, 159}, {160, 32}} + + YES + + 67239424 + 137887744 + Rimuovi + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {333, 198} + + YES + + + 256 + {333, 17} + + + + + + 256 + {{334, 0}, {16, 17}} + + + + + 132.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Nome + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Cella di testo + + + + + 3 + MQA + + + + 3 + YES + YES + + + + + 110 + 40 + 1000 + + 75628096 + 2048 + Comando + + + + + + 338820672 + 1024 + Cella di testo + + + + + + + 3 + YES + YES + + + + + 81 + 10 + 1000 + + 75628096 + 2048 + Abbreviazione + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Cella di testo + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {333, 198}} + + + + + 4 + + + + 256 + {{334, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {333, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {333, 17}} + + + + + 4 + + + + {{20, 20}, {350, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{372, 223}, {160, 32}} + + YES + + -2080244224 + 137887744 + Aggiungi elemento + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {546, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Menu + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Applicazioni + + 1048576 + 2147483647 + + + submenuAction: + + Applicazioni + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizza… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/keyedobjects.nib index 79c41ea58..794de812f 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/Italian.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/locversion.plist index 2edd96855..0c81bd02a 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - ja - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + ja + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/designable.nib index 32436b500..2803baa8d 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/designable.nib @@ -1,3623 +1,3522 @@ - - - - 1040 - 11A79a - 784 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 784 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - X11 ã«ã¤ã„㦠- - 2147483647 - - - - - - 環境設定... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - サービス - - 1048576 - 2147483647 - - - submenuAction: - - サービス - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - フルスクリーンを切り替ãˆã‚‹ - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - X11 ã‚’éš ã™ - h - 1048576 - 2147483647 - - - 42 - - - - ã»ã‹ã‚’éš ã™ - h - 1572864 - 2147483647 - - - - - - ã™ã¹ã¦ã‚’表示 - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - X11 を終了 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - アプリケーション - - 1048576 - 2147483647 - - - submenuAction: - - アプリケーション - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - カスタマイズ... - - 1048576 - 2147483647 - - - - - - - - - 編集 - - 1048576 - 2147483647 - - - submenuAction: - - 編集 - - - - コピー - c - 1048576 - 2147483647 - - - - - - - - - ウインドウ - - 1048576 - 2147483647 - - - submenuAction: - - ウインドウ - - - - é–‰ã˜ã‚‹ - w - 1048576 - 2147483647 - - - - - - ã—ã¾ã† - m - 1048576 - 2147483647 - - - - - - 拡大ï¼ç¸®å° - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ウインドウを巡回 -  - 1048576 - 2147483647 - - - - - - ウインドウを逆方å‘ã«å·¡å›ž -  - 1179648 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ã™ã¹ã¦ã‚’手å‰ã«ç§»å‹• - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - ヘルプ - - 1048576 - 2147483647 - - - submenuAction: - - ヘルプ - - - - X11 ヘルプ - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{319, 328}, {584, 308}} - 1350041600 - X11 ã®ç’°å¢ƒè¨­å®š - NSPanel - - View - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {558, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - 3 ボタンマウスをエミュレート - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 59}, {466, 28}} - - YES - - 67239424 - 4194304 - 有効ã«ã™ã‚‹ã¨ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼ãƒãƒ¼ã®ä»£æ›¿ã‚­ãƒ¼ã«ã‚ˆã£ã¦ X11 アプリケーションã®ãƒ¡ã‚¿ä¿®é£¾ã‚­ãƒ¼ã‚’使用ã§ããªããªã‚‹å ´åˆãŒã‚ã‚Šã¾ã™ã€‚ - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2ODY1AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 176}, {466, 28}} - - YES - - 67239424 - 4194304 - T3B0aW9uIOOCreODvOOCkuaKvOOBl+OBn+OBvuOBvuOCr+ODquODg+OCr+OBmeOCi+OBqOODnuOCpuOC -ueOBruS4reODnOOCv+ODs+aTjeS9nOOBq+OBquOCiuOAgeOCs+ODnuODs+ODieOCreODvOOCkuaKvOOB -l+OBn+OBvuOBvuOCr+ODquODg+OCr+OBmeOCi+OBqOODnuOCpuOCueOBruWPs+ODnOOCv+ODs+aTjeS9 -nOOBq+OBquOCiuOBvuOBmeOAggo - - - - - - - - - - 256 - {{18, 93}, {402, 18}} - - YES - - 67239424 - 0 - X11 ã®ä»£æ›¿ã‚­ãƒ¼ã‚’有効ã«ã™ã‚‹ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 123}, {466, 17}} - - YES - - 67239424 - 4194304 - 入力メニューを変更ã—ã¦ç¾åœ¨ã® X11 キーマップを上書ãã™ã‚‹ã“ã¨ã‚’許å¯ã—ã¾ã™ã€‚ - - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 0 - システムã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ãƒ¬ã‚¤ã‚¢ã‚¦ãƒˆã«å¾“ㆠ- - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - 有効ã«ã™ã‚‹ã¨ã€option キー 㧠Mode_switch ã®ä»£ã‚ã‚Šã« X11 キーシンボル㮠Alt_L 㨠Alt_R ãŒé€ä¿¡ã•ã‚Œã¾ã™ã€‚ - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 0 - Option キー㧠Alt_L 㨠Alt_R ãŒé€ä¿¡ã•ã‚Œã¾ã™ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {538, 246}} - - - 入力 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 51}, {402, 18}} - - YES - - 67239424 - 0 - システムã®è­¦å‘Šã‚¨ãƒ•ã‚§ã‚¯ãƒˆã‚’使用 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 17}, {460, 28}} - - YES - - 67239424 - 4194304 - X11 ã®ãƒ“ープ音ã®ãŸã‚ã«ã€â€œã‚µã‚¦ãƒ³ãƒ‰ã‚¨ãƒ•ã‚§ã‚¯ãƒˆâ€ã‚·ã‚¹ãƒ†ãƒ ç’°å¢ƒè¨­å®šãƒ‘ãƒãƒ«ã«å®šç¾©ã•ã‚Œã¦ã„るシステム標準ã®è­¦å‘ŠéŸ³ã‚’使用ã—ã¾ã™ã€‚ - - - - - - - - - - 256 - {{75, 201}, {163, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - ディスプレイã‹ã‚‰ - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 色 - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - ç´„ 32000 色 - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - ç´„ 1670 万色 - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {56, 19}} - - YES - - 67239424 - 4194304 - カラー: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - ã“ã®ã‚ªãƒ—ションã¯ã€æ¬¡å›ž X11 ã‚’èµ·å‹•ã—ãŸã¨ãã«æœ‰åŠ¹ã«ãªã‚Šã¾ã™ã€‚ - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - フルスクリーンモード - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {409, 23}} - - YES - - 67239424 - 0 - フルスクリーンモードã§ãƒ¡ãƒ‹ãƒ¥ãƒ¼ãƒãƒ¼ã‚’自動的ã«è¡¨ç¤º - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 113}, {468, 30}} - - YES - - 67239424 - 4194304 - X11 ã®ãƒ«ãƒ¼ãƒˆã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦ã‚’有効ã«ã—ã¾ã™ã€‚フルスクリーンモードã«åˆ‡ã‚Šæ›¿ãˆãŸã‚Šã€ãƒ•ãƒ«ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ãƒ¢ãƒ¼ãƒ‰ã‚’終了ã™ã‚‹ã¨ãã¯ã€ã‚³ãƒžãƒ³ãƒ‰ + Option + A キーを押ã—ã¾ã™ã€‚ - - - - - - - - - {{10, 33}, {538, 246}} - - 出力 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - åŒæœŸã‚’有効ã«ã™ã‚‹ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {463, 28}} - - YES - - 67239424 - 4194304 - “コピーâ€ãƒ¡ãƒ‹ãƒ¥ãƒ¼é …目を有効ã«ã—ã¦ã€OSX ã®ãƒšãƒ¼ã‚¹ãƒˆãƒœãƒ¼ãƒ‰ã¨ X11 ã® CLIPBOARD ãƒãƒƒãƒ•ã‚¡ãŠã‚ˆã³ PRIMARY ãƒãƒƒãƒ•ã‚¡ã‚’åŒæœŸã§ãるよã†ã«ã—ã¾ã™ã€‚ - - - - - - - - - 256 - {{37, 96}, {414, 18}} - - YES - - 67239424 - 0 - ペーストボードãŒå¤‰æ›´ã•ã‚ŒãŸã¨ãã« CLIPBOARD をアップデート - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 71}, {489, 18}} - - YES - - 67239424 - 0 - ペーストボードãŒå¤‰æ›´ã•ã‚ŒãŸã¨ãã« PRIMARY (中クリック)をアップデート - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 46}, {451, 18}} - - YES - - 67239424 - 0 - æ–°ã—ã„テキストãŒé¸æŠžã•ã‚ŒãŸã‚‰ã€ã™ãã«ãƒšãƒ¼ã‚¹ãƒˆãƒœãƒ¼ãƒ‰ã‚’アップデート - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 159}, {410, 18}} - - YES - - 67239424 - 0 - CLIPBOARD ãŒå¤‰æ›´ã•ã‚ŒãŸã¨ãã«ãƒšãƒ¼ã‚¹ãƒˆãƒœãƒ¼ãƒ‰ã‚’アップデート - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{55, 125}, {445, 28}} - - YES - - 67239424 - 4194304 - xclipboardã€klipperã€ãã®ä»–ã® X11 クリップボードマãƒãƒ¼ã‚¸ãƒ£ã‚’使用ã—ãŸã„å ´åˆã¯ã€ã“ã®ã‚ªãƒ—ションを無効ã«ã—ã¦ãã ã•ã„。 - - - - - - - - - 256 - {{55, 12}, {451, 28}} - - YES - - 67239424 - 4194304 - X11 プロトコルã®åˆ¶é™ã«ã‚ˆã‚Šã€ã“ã®ã‚ªãƒ—ションã¯ã€ä¸€éƒ¨ã®ã‚¢ãƒ—リケーションã§æ©Ÿèƒ½ã—ãªã„å ´åˆãŒã‚ã‚Šã¾ã™ã€‚ - - - - - - - - {{10, 33}, {538, 246}} - - ペーストボード - - - - - - 2 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - é¸æŠžã•ã‚Œã¦ã„ãªã„ウインドウを直接クリック - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 176}, {466, 28}} - - YES - - 67239424 - 4194304 - 有効ã«ã—ãŸå ´åˆã€é¸æŠžã•ã‚Œã¦ã„ãªã„ウインドウをクリックã—ãŸã¨ãã«ã€ãã®ã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦ã‚’一番手å‰ã«è¡¨ç¤ºã™ã‚‹ã ã‘ã§ãªãã€ã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦å†…ã®é …目を直接クリックã—ã¾ã™ã€‚ - - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 0 - フォーカスをマウスã¨ä¸€ç·’ã«ç§»å‹• - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 126}, {490, 14}} - - YES - - 67239424 - 4194304 - X11 ウインドウã®ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ãŒã‚«ãƒ¼ã‚½ãƒ«ã¨ä¸€ç·’ã«ç§»å‹•ã—ã¾ã™ã€‚逆効果ã«ãªã‚‹å ´åˆã‚‚ã‚ã‚Šã¾ã™ã€‚ - - - - - - - - - - 256 - {{18, 96}, {402, 18}} - - YES - - 67239424 - 0 - æ–°è¦ã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦ã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 62}, {464, 28}} - - YES - - 67239424 - 4194304 - 有効ã«ã—ãŸå ´åˆã€æ–°ã—ã„ X11 ウインドウを作æˆã™ã‚‹ã¨ã€Finder.app ã‚„ ターミナル.app ãªã©ã®ä»£ã‚ã‚Šã«ã€X11.app ãŒå‰é¢ã«ç§»å‹•ã—ã¾ã™ã€‚ - - - - - - - - - {{10, 33}, {538, 246}} - - ウインドウ - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - 接続をèªè¨¼ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 132}, {402, 18}} - - YES - - 67239424 - 0 - ãƒãƒƒãƒˆãƒ¯ãƒ¼ã‚¯ãƒ»ã‚¯ãƒ©ã‚¤ã‚¢ãƒ³ãƒˆã‹ã‚‰ã®æŽ¥ç¶šã‚’è¨±å¯ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {465, 42}} - - YES - - 67239424 - 4194304 - X11 ã®èµ·å‹•æ™‚ã«ã€Xauthority アクセス制御キーを作æˆã—ã¾ã™ã€‚システム㮠IP アドレスãŒå¤‰æ›´ã•ã‚Œã‚‹ã¨ã€ã“れらã®ã‚­ãƒ¼ãŒç„¡åŠ¹ã«ãªã‚Šã€X11 アプリケーションãŒèµ·å‹•ã—ãªããªã‚‹ã“ã¨ãŒã‚ã‚Šã¾ã™ã€‚ - - - - - - - - - - 256 - {{36, 84}, {465, 42}} - - YES - - 67239424 - 4194304 - 有効ã«ã™ã‚‹å ´åˆã¯ã€ã‚·ã‚¹ãƒ†ãƒ ã®ã‚»ã‚­ãƒ¥ãƒªãƒ†ã‚£ã‚’維æŒã™ã‚‹ãŸã‚ã«ã€â€œæŽ¥ç¶šã‚’èªè¨¼â€ã‚‚有効ã«ã—ã¦ãã ã•ã„。無効ã«ã™ã‚‹ã¨ã€ãƒªãƒ¢ãƒ¼ãƒˆã‚¢ãƒ—リケーションã‹ã‚‰ã®æŽ¥ç¶šã¯æ‹’å¦ã•ã‚Œã¾ã™ã€‚ - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - ã“れらã®ã‚ªãƒ—ションã¯ã€æ¬¡å›ž X11 ã‚’èµ·å‹•ã—ãŸã¨ãã«æœ‰åŠ¹ã«ãªã‚Šã¾ã™ã€‚ - - - - - - - - - {{10, 33}, {538, 246}} - - セキュリティ - - - - - - - 0 - YES - YES - - - - - - {584, 308} - - {{0, 0}, {1440, 878}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_prefs - - - 11 - 2 - {{360, 402}, {454, 271}} - 1350041600 - X11 アプリケーションメニュー - NSPanel - - View - - {3.4028235e+38, 3.4028235e+38} - {454, 271} - - - 256 - - - - 265 - {{340, 191}, {105, 32}} - - - YES - - 67239424 - 137887744 - 複製 - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {105, 32}} - - - YES - - 67239424 - 137887744 - å–り除ã - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - - YES - - - 256 - {301, 17} - - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - - 103 - 43 - 1000 - - 75628096 - 2048 - åå‰ - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - テキストセル - - - - - 3 - MQA - - - - 3 - YES - YES - - - - - 100 - 40 - 1000 - - 75628096 - 2048 - コマンド - - - - - - 338820672 - 1024 - テキストセル - - - - - - - 3 - YES - YES - - - - - 89 - 30 - 1000 - - 75628096 - 2048 - ショートカット - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - テキストセル - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - - 1 - - _doScroller: - 0.94357365369796753 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {105, 32}} - - - YES - - -2080244224 - 137887744 - 項目を追加 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - - - {{0, 0}, {1440, 878}} - {454, 293} - {3.4028235e+38, 3.4028235e+38} - x11_apps - - - メニュー - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - アプリケーション - - 1048576 - 2147483647 - - - submenuAction: - - アプリケーション - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - カスタマイズ... - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 565}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 565}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - IBBuiltInLabel-Red - - - {3.40282e+38, 3.40282e+38} - {454, 271} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A194b + 787 + 1079 + 502.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 787 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + X11 ã«ã¤ã„㦠+ + 2147483647 + + + + + + 環境設定... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + サービス + + 1048576 + 2147483647 + + + submenuAction: + + サービス + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + フルスクリーンを切り替ãˆã‚‹ + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + X11 ã‚’éš ã™ + h + 1048576 + 2147483647 + + + 42 + + + + ã»ã‹ã‚’éš ã™ + h + 1572864 + 2147483647 + + + + + + ã™ã¹ã¦ã‚’表示 + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + X11 を終了 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + アプリケーション + + 1048576 + 2147483647 + + + submenuAction: + + アプリケーション + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + カスタマイズ... + + 1048576 + 2147483647 + + + + + + + + + 編集 + + 1048576 + 2147483647 + + + submenuAction: + + 編集 + + + + コピー + c + 1048576 + 2147483647 + + + + + + + + + ウインドウ + + 1048576 + 2147483647 + + + submenuAction: + + ウインドウ + + + + é–‰ã˜ã‚‹ + w + 1048576 + 2147483647 + + + + + + ã—ã¾ã† + m + 1048576 + 2147483647 + + + + + + 拡大ï¼ç¸®å° + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ウインドウを巡回 +  + 1048576 + 2147483647 + + + + + + ウインドウを逆方å‘ã«å·¡å›ž +  + 1179648 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ã™ã¹ã¦ã‚’手å‰ã«ç§»å‹• + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + ヘルプ + + 1048576 + 2147483647 + + + submenuAction: + + ヘルプ + + + + X11 ヘルプ + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{319, 328}, {584, 308}} + 1350041600 + X11 ã®ç’°å¢ƒè¨­å®š + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {558, 292}} + + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + 3 ボタンマウスをエミュレート + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 59}, {466, 28}} + + YES + + 67239424 + 4194304 + 有効ã«ã™ã‚‹ã¨ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼ãƒãƒ¼ã®ä»£æ›¿ã‚­ãƒ¼ã«ã‚ˆã£ã¦ X11 アプリケーションã®ãƒ¡ã‚¿ä¿®é£¾ã‚­ãƒ¼ã‚’使用ã§ããªããªã‚‹å ´åˆãŒã‚ã‚Šã¾ã™ã€‚ + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 176}, {466, 28}} + + YES + + 67239424 + 4194304 + T3B0aW9uIOOCreODvOOCkuaKvOOBl+OBn+OBvuOBvuOCr+ODquODg+OCr+OBmeOCi+OBqOODnuOCpuOC +ueOBruS4reODnOOCv+ODs+aTjeS9nOOBq+OBquOCiuOAgeOCs+ODnuODs+ODieOCreODvOOCkuaKvOOB +l+OBn+OBvuOBvuOCr+ODquODg+OCr+OBmeOCi+OBqOODnuOCpuOCueOBruWPs+ODnOOCv+ODs+aTjeS9 +nOOBq+OBquOCiuOBvuOBmeOAggo + + + + + + + + + + 256 + {{18, 93}, {402, 18}} + + YES + + 67239424 + 0 + X11 ã®ä»£æ›¿ã‚­ãƒ¼ã‚’有効ã«ã™ã‚‹ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 123}, {466, 17}} + + YES + + 67239424 + 4194304 + 入力メニューを変更ã—ã¦ç¾åœ¨ã® X11 キーマップを上書ãã™ã‚‹ã“ã¨ã‚’許å¯ã—ã¾ã™ã€‚ + + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 0 + システムã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ãƒ¬ã‚¤ã‚¢ã‚¦ãƒˆã«å¾“ㆠ+ + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {466, 31}} + + YES + + 67239424 + 4194304 + 有効ã«ã™ã‚‹ã¨ã€option キー 㧠Mode_switch ã®ä»£ã‚ã‚Šã« X11 キーシンボル㮠Alt_L 㨠Alt_R ãŒé€ä¿¡ã•ã‚Œã¾ã™ã€‚ + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Option ã‚­ãƒ¼ã§ Alt_L 㨠Alt_R ãŒé€ä¿¡ã•ã‚Œã¾ã™ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {538, 246}} + + 入力 + + + + + + 2 + + + + 256 + + + + 256 + {{75, 201}, {163, 26}} + + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + ディスプレイã‹ã‚‰ + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 色 + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + ç´„ 32000 色 + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + ç´„ 1670 万色 + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {56, 19}} + + + YES + + 67239424 + 4194304 + カラー: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + + YES + + 67239424 + 4194304 + ã“ã®ã‚ªãƒ—ションã¯ã€æ¬¡å›ž X11 ã‚’èµ·å‹•ã—ãŸã¨ãã«æœ‰åŠ¹ã«ãªã‚Šã¾ã™ã€‚ + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + + YES + + 67239424 + 0 + フルスクリーンモード + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {409, 23}} + + + YES + + 67239424 + 0 + フルスクリーンモードã§ãƒ¡ãƒ‹ãƒ¥ãƒ¼ãƒãƒ¼ã‚’自動的ã«è¡¨ç¤º + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 113}, {468, 30}} + + + YES + + 67239424 + 4194304 + X11 ã®ãƒ«ãƒ¼ãƒˆã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦ã‚’有効ã«ã—ã¾ã™ã€‚フルスクリーンモードã«åˆ‡ã‚Šæ›¿ãˆãŸã‚Šã€ãƒ•ãƒ«ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ãƒ¢ãƒ¼ãƒ‰ã‚’終了ã™ã‚‹ã¨ãã¯ã€ã‚³ãƒžãƒ³ãƒ‰ + Option + A キーを押ã—ã¾ã™ã€‚ + + + + + + + + + {{10, 33}, {538, 246}} + + + + 出力 + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + åŒæœŸã‚’有効ã«ã™ã‚‹ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {488, 28}} + + YES + + 67239424 + 4194304 + “コピーâ€ãƒ¡ãƒ‹ãƒ¥ãƒ¼é …目を有効ã«ã—ã¦ã€OSX ã®ãƒšãƒ¼ã‚¹ãƒˆãƒœãƒ¼ãƒ‰ã¨ X11 ã® CLIPBOARD ãƒãƒƒãƒ•ã‚¡ãŠã‚ˆã³ PRIMARY ãƒãƒƒãƒ•ã‚¡ã‚’åŒæœŸã§ãるよã†ã«ã—ã¾ã™ã€‚ + + + + + + + + + 256 + {{37, 96}, {414, 18}} + + YES + + 67239424 + 0 + ペーストボードãŒå¤‰æ›´ã•ã‚ŒãŸã¨ãã« CLIPBOARD をアップデート + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 71}, {486, 18}} + + YES + + 67239424 + 0 + ペーストボードãŒå¤‰æ›´ã•ã‚ŒãŸã¨ãã« PRIMARY (中クリック)をアップデート + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 46}, {451, 18}} + + YES + + 67239424 + 0 + æ–°ã—ã„テキストãŒé¸æŠžã•ã‚ŒãŸã‚‰ã€ã™ãã«ãƒšãƒ¼ã‚¹ãƒˆãƒœãƒ¼ãƒ‰ã‚’アップデート + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 159}, {410, 18}} + + YES + + 67239424 + 0 + CLIPBOARD ãŒå¤‰æ›´ã•ã‚ŒãŸã¨ãã«ãƒšãƒ¼ã‚¹ãƒˆãƒœãƒ¼ãƒ‰ã‚’アップデート + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{55, 125}, {469, 28}} + + YES + + 67239424 + 4194304 + xclipboardã€klipperã€ãã®ä»–ã® X11 クリップボードマãƒãƒ¼ã‚¸ãƒ£ã‚’使用ã—ãŸã„å ´åˆã¯ã€ã“ã®ã‚ªãƒ—ションを無効ã«ã—ã¦ãã ã•ã„。 + + + + + + + + + 256 + {{55, 12}, {469, 28}} + + YES + + 67239424 + 4194304 + X11 プロトコルã®åˆ¶é™ã«ã‚ˆã‚Šã€ã“ã®ã‚ªãƒ—ションã¯ã€ä¸€éƒ¨ã®ã‚¢ãƒ—リケーションã§æ©Ÿèƒ½ã—ãªã„å ´åˆãŒã‚ã‚Šã¾ã™ã€‚ + + + + + + + + {{10, 33}, {538, 246}} + + ペーストボード + + + + + + 2 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + é¸æŠžã•ã‚Œã¦ã„ãªã„ウインドウを直接クリック + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 176}, {474, 28}} + + YES + + 67239424 + 4194304 + 有効ã«ã—ãŸå ´åˆã€é¸æŠžã•ã‚Œã¦ã„ãªã„ウインドウをクリックã—ãŸã¨ãã«ã€ãã®ã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦ã‚’一番手å‰ã«è¡¨ç¤ºã™ã‚‹ã ã‘ã§ãªãã€ã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦å†…ã®é …目を直接クリックã—ã¾ã™ã€‚ + + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 0 + フォーカスをマウスã¨ä¸€ç·’ã«ç§»å‹• + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 126}, {474, 14}} + + YES + + 67239424 + 4194304 + X11 ウインドウã®ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ãŒã‚«ãƒ¼ã‚½ãƒ«ã¨ä¸€ç·’ã«ç§»å‹•ã—ã¾ã™ã€‚逆効果ã«ãªã‚‹å ´åˆã‚‚ã‚ã‚Šã¾ã™ã€‚ + + + + + + + + + + 256 + {{18, 96}, {402, 18}} + + YES + + 67239424 + 0 + æ–°è¦ã‚¦ã‚¤ãƒ³ãƒ‰ã‚¦ã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 62}, {474, 28}} + + YES + + 67239424 + 4194304 + 有効ã«ã—ãŸå ´åˆã€æ–°ã—ã„ X11 ウインドウを作æˆã™ã‚‹ã¨ã€Finder.app ã‚„ ターミナル.app ãªã©ã®ä»£ã‚ã‚Šã«ã€X11.app ãŒå‰é¢ã«ç§»å‹•ã—ã¾ã™ã€‚ + + + + + + + + + {{10, 33}, {538, 246}} + + ウインドウ + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + 接続をèªè¨¼ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 132}, {402, 18}} + + YES + + 67239424 + 0 + ãƒãƒƒãƒˆãƒ¯ãƒ¼ã‚¯ãƒ»ã‚¯ãƒ©ã‚¤ã‚¢ãƒ³ãƒˆã‹ã‚‰ã®æŽ¥ç¶šã‚’è¨±å¯ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {465, 42}} + + YES + + 67239424 + 4194304 + X11 ã®èµ·å‹•æ™‚ã«ã€Xauthority アクセス制御キーを作æˆã—ã¾ã™ã€‚システム㮠IP アドレスãŒå¤‰æ›´ã•ã‚Œã‚‹ã¨ã€ã“れらã®ã‚­ãƒ¼ãŒç„¡åŠ¹ã«ãªã‚Šã€X11 アプリケーションãŒèµ·å‹•ã—ãªããªã‚‹ã“ã¨ãŒã‚ã‚Šã¾ã™ã€‚ + + + + + + + + + + 256 + {{36, 84}, {465, 42}} + + YES + + 67239424 + 4194304 + 有効ã«ã™ã‚‹å ´åˆã¯ã€ã‚·ã‚¹ãƒ†ãƒ ã®ã‚»ã‚­ãƒ¥ãƒªãƒ†ã‚£ã‚’維æŒã™ã‚‹ãŸã‚ã«ã€â€œæŽ¥ç¶šã‚’èªè¨¼â€ã‚‚有効ã«ã—ã¦ãã ã•ã„。無効ã«ã™ã‚‹ã¨ã€ãƒªãƒ¢ãƒ¼ãƒˆã‚¢ãƒ—リケーションã‹ã‚‰ã®æŽ¥ç¶šã¯æ‹’å¦ã•ã‚Œã¾ã™ã€‚ + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + ã“れらã®ã‚ªãƒ—ションã¯ã€æ¬¡å›ž X11 ã‚’èµ·å‹•ã—ãŸã¨ãã«æœ‰åŠ¹ã«ãªã‚Šã¾ã™ã€‚ + + + + + + + + + {{10, 33}, {538, 246}} + + セキュリティ + + + + + + + 0 + YES + YES + + + + + + {584, 308} + + + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{360, 402}, {454, 271}} + 1350041600 + X11 アプリケーションメニュー + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {454, 271} + + + 256 + + + + 265 + {{340, 191}, {105, 32}} + + YES + + 67239424 + 137887744 + 複製 + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {105, 32}} + + YES + + 67239424 + 137887744 + å–り除ã + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 103 + 43 + 1000 + + 75628096 + 2048 + åå‰ + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + テキストセル + + + + + 3 + MQA + + + + 3 + YES + YES + + + + + 100 + 40 + 1000 + + 75628096 + 2048 + コマンド + + + + + + 338820672 + 1024 + テキストセル + + + + + + + 3 + YES + YES + + + + + 89 + 30 + 1000 + + 75628096 + 2048 + ショートカット + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + テキストセル + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 50 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {105, 32}} + + YES + + -2080244224 + 137887744 + 項目を追加 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1440, 878}} + {454, 293} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + メニュー + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + アプリケーション + + 1048576 + 2147483647 + + + submenuAction: + + アプリケーション + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + カスタマイズ... + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{539, 548}, {584, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{539, 548}, {584, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {454, 271} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 836}, {394, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/keyedobjects.nib index c1a0d5b75..46d376334 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/locversion.plist index 469caad4a..3e9ae7e4d 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 99 - LprojLocale - es - LprojRevisionLevel - 1 - LprojVersion - 99 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + es + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/designable.nib index ebf843c50..a5d0f36ba 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/designable.nib @@ -1,3603 +1,3760 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Acerca de X11 - - 2147483647 - - - - - - Preferencias... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Servicios - - 1048576 - 2147483647 - - - submenuAction: - - Servicios - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Activar/desactivar pantalla completa - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Ocultar X11 - h - 1048576 - 2147483647 - - - 42 - - - - Ocultar otros - h - 1572864 - 2147483647 - - - - - - Mostrar todo - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Salir de X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Aplicaciones - - 1048576 - 2147483647 - - - submenuAction: - - Aplicaciones - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizar... - - 1048576 - 2147483647 - - - - - - - - - Edición - - 1048576 - 2147483647 - - - submenuAction: - - Edición - - - - Copiar - c - 1048576 - 2147483647 - - - - - - - - - Ventana - - 1048576 - 2147483647 - - - submenuAction: - - Ventana - - - - Cerrar - w - 1048576 - 2147483647 - - - - - - Minimizar - m - 1048576 - 2147483647 - - - - - - Zoom - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Recorrer ventanas - < - 1048576 - 2147483647 - - - - - - Recorrer ventanas al revés - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Traer todo al frente - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Ayuda - - 1048576 - 2147483647 - - - submenuAction: - - Ayuda - - - - Ayuda X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{345, 450}, {619, 308}} - 1350041600 - Preferencias de X11 - NSPanel - - View - - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {593, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 215}, {402, 18}} - - YES - - 67239424 - 0 - Simular ratón de tres botones - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 65}, {501, 28}} - - YES - - 67239424 - 4194304 - Cuando esta opción está activada, puede que los equivalentes de teclado de la barra de menús interfieran con las aplicaciones X11 que usen el modificador Meta. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2ODY1AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 181}, {501, 28}} - - YES - - 67239424 - 4194304 - TWFudGVuZ2EgcHVsc2FkYXMgbGFzIHRlY2xhcyBPcGNpw7NuIG8gQ29tYW5kbyBhbCBoYWNlciBjbGlj -IHBhcmEgYWN0aXZhciBlbCBib3TDs24gY2VudHJhbCBvIGRlcmVjaG8gZGVsIHJhdMOzbi4KA - - - - - - - - - - 256 - {{18, 99}, {402, 18}} - - YES - - 67239424 - 0 - Activar equivalentes de teclado en X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 123}, {501, 28}} - - YES - - 67239424 - 4194304 - Permite que los cambios en el menú de teclado reemplacen la distribución de teclas actual de X11. - - - - - - - - - - 256 - {{18, 157}, {402, 18}} - - YES - - 67239424 - 0 - Seguir la distribución de teclado del sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 7}, {501, 28}} - - YES - - 67239424 - 4194304 - Si esta opción está seleccionada, las teclas Opción envían los símbolos de tecla de X11 Alt_L y Alt_R en vez de Mode_switch. - - - - - - - - - 256 - {{18, 41}, {402, 18}} - - YES - - 67239424 - 0 - Las teclas Opción envían Alt_L y Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {573, 246}} - - - Entrada - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - Usar el efecto de alerta del sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {511, 28}} - - YES - - 67239424 - 4194304 - Los sonidos de X11 usarán el sonido de alerta estándar del sistema definido en la pestaña “Efectos de sonido†del panel Sonido de Preferencias del Sistema. - - - - - - - - - - 256 - {{77, 202}, {168, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - De la pantalla - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 colores - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Miles - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Millones - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {58, 20}} - - YES - - 67239424 - 4194304 - Colores: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Esta opción será efectiva la próxima vez que se inicie X11. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - Modalidad de pantalla completa - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 88}, {533, 18}} - - YES - - 67239424 - 0 - Mostrar barra de menús automáticamente en la modalidad de pantalla completa - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 112}, {511, 31}} - - YES - - 67239424 - 4194304 - Activa la ventana raíz de X11. Use la combinación de teclas Comando + Opción + A para entrar o salir de la modalidad de pantalla completa. - - - - - - - - - {{10, 33}, {573, 246}} - - Salida - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - Activar sincronización - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {501, 28}} - - YES - - 67239424 - 4194304 - Activa el ítem de menú “copiar†y permite sincronizar el portapapeles de OSX y los búfers CLIPBOARD y PRIMARY de X11. - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - Actualizar el CLIPBOARD cuando cambie el portapapeles - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {529, 23}} - - YES - - 67239424 - 0 - Actualizar el PRIMARY (clic con el botón central) cuando cambie el portapapeles - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 51}, {495, 18}} - - YES - - 67239424 - 0 - Actualizar el portapapeles de inmediato cuando se seleccione texto nuevo - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - Actualizar el portapapeles cuando cambie el CLIPBOARD - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{52, 125}, {485, 28}} - - YES - - 67239424 - 4194304 - Desactive esta opción si desea usar xclipboard, klipper o cualquier otro gestor de portapapeles de X11. - - - - - - - - - 256 - {{52, 17}, {485, 28}} - - YES - - 67239424 - 4194304 - A causa de las limitaciones del protocolo de X11, puede que esta opción no funcione siempre en algunas aplicaciones. - - - - - - - - {{10, 33}, {573, 246}} - - Portapapeles - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Hacer clic para pasar de una ventana inactiva a otra - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{33, 175}, {501, 31}} - - YES - - 67239424 - 4194304 - Cuando está activada, al hacer clic en una ventana inactiva, la ventana se activa y además el clic del ratón se transmite a ella. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Enfocar la posición del ratón - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{33, 117}, {501, 28}} - - YES - - 67239424 - 4194304 - El punto de enfoque de la ventana de X11 sigue el cursor. Esto conlleva algunos inconvenientes. - - - - - - - - - 256 - {{15, 93}, {402, 18}} - - YES - - 67239424 - 0 - Enfocar las ventanas nuevas - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{33, 45}, {501, 42}} - - YES - - 67239424 - 4194304 - Cuando está activada, al crear una nueva ventana de X11 el archivo X11.app se sitúa en primer plano (por encima de Finder.app, Terminal.app, etc.) - - - - - - - - {{10, 33}, {573, 246}} - - Ventanas - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Autenticar conexiones - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - Permitir conexiones de clientes de red - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {501, 42}} - - YES - - 67239424 - 4194304 - Al iniciar X11 se crearán unas claves de control de acceso Xauthority. Si la dirección IP del sistema cambia, estas claves dejarán de ser válidas, lo que impediría que pudiesen ejecutarse las aplicaciones X11. - - - - - - - - - - 256 - {{36, 71}, {501, 56}} - - YES - - 67239424 - 4194304 - Si esta opción está activada, la opción “Autenticar conexiones†también debe estarlo para garantizar la seguridad del sistema. Si está desactivada, las conexiones de aplicaciones remotas no están permitidas. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Estas opciones serán efectivas la próxima vez que se inicie X11. - - - - - - - - - {{10, 33}, {573, 246}} - - Seguridad - - - - - - - 0 - YES - YES - - - - - - {619, 308} - - - {{0, 0}, {1280, 938}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_prefs - - - 11 - 2 - {{302, 440}, {454, 271}} - 1350041600 - Menú de aplicaciones X11 - NSPanel - - View - - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {110, 32}} - - YES - - 67239424 - 137887744 - Duplicar - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {110, 32}} - - YES - - 67239424 - 137887744 - Eliminar - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 105 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Nombre - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Celda de texto - - - - - 3 - MQA - - - - 3 - YES - YES - - - - - 88 - 40 - 1000 - - 75628096 - 2048 - Comando - - - - - - 338820672 - 1024 - Celda de texto - - - - - - - 3 - YES - YES - - - - - 99 - 10 - 1000 - - 75628096 - 2048 - Función rápida - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Celda de texto - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.96474361419677734 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {114, 32}} - - YES - - -2080244224 - 137887744 - Añadir ítem - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - - {{0, 0}, {1280, 938}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_apps - - - Menú - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Aplicaciones - - 1048576 - 2147483647 - - - submenuAction: - - Aplicaciones - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizar… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 565}, {619, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 565}, {619, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 986}, {375, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Acerca de X11 + + 2147483647 + + + + + + Preferencias... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Servicios + + 1048576 + 2147483647 + + + submenuAction: + + Servicios + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Activar/desactivar pantalla completa + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Ocultar X11 + h + 1048576 + 2147483647 + + + 42 + + + + Ocultar otros + h + 1572864 + 2147483647 + + + + + + Mostrar todo + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Salir de X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Aplicaciones + + 1048576 + 2147483647 + + + submenuAction: + + Aplicaciones + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizar... + + 1048576 + 2147483647 + + + + + + + + + Edición + + 1048576 + 2147483647 + + + submenuAction: + + Edición + + + + Copiar + c + 1048576 + 2147483647 + + + + + + + + + Ventana + + 1048576 + 2147483647 + + + submenuAction: + + Ventana + + + + Cerrar + w + 1048576 + 2147483647 + + + + + + Minimizar + m + 1048576 + 2147483647 + + + + + + Zoom + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Recorrer ventanas + < + 1048576 + 2147483647 + + + + + + Recorrer ventanas al revés + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Traer todo al frente + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Ayuda + + 1048576 + 2147483647 + + + submenuAction: + + Ayuda + + + + Ayuda X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{345, 450}, {619, 308}} + 1350041600 + Preferencias de X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {593, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 215}, {402, 18}} + + YES + + 67239424 + 0 + Simular ratón de tres botones + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 65}, {501, 28}} + + YES + + 67239424 + 4194304 + Cuando esta opción está activada, puede que los equivalentes de teclado de la barra de menús interfieran con las aplicaciones X11 que usen el modificador Meta. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 181}, {501, 28}} + + YES + + 67239424 + 4194304 + TWFudGVuZ2EgcHVsc2FkYXMgbGFzIHRlY2xhcyBPcGNpw7NuIG8gQ29tYW5kbyBhbCBoYWNlciBjbGlj +IHBhcmEgYWN0aXZhciBlbCBib3TDs24gY2VudHJhbCBvIGRlcmVjaG8gZGVsIHJhdMOzbi4KA + + + + + + + + + + 256 + {{18, 99}, {402, 18}} + + YES + + 67239424 + 0 + Activar equivalentes de teclado en X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 123}, {501, 28}} + + YES + + 67239424 + 4194304 + Permite que los cambios en el menú de teclado reemplacen la distribución de teclas actual de X11. + + + + + + + + + + 256 + {{18, 157}, {402, 18}} + + YES + + 67239424 + 0 + Seguir la distribución de teclado del sistema + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 7}, {501, 28}} + + YES + + 67239424 + 4194304 + Si esta opción está seleccionada, las teclas Opción envían los símbolos de tecla de X11 Alt_L y Alt_R en vez de Mode_switch. + + + + + + + + + 256 + {{18, 41}, {402, 18}} + + YES + + 67239424 + 0 + Las teclas Opción envían Alt_L y Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {573, 246}} + + Entrada + + + + + + 2 + + + + 256 + + + + 256 + {{77, 202}, {168, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + De la pantalla + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 colores + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Miles + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Millones + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {58, 20}} + + YES + + 67239424 + 4194304 + Colores: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Esta opción será efectiva la próxima vez que se inicie X11. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + Modalidad de pantalla completa + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 88}, {533, 18}} + + YES + + 67239424 + 0 + Mostrar barra de menús automáticamente en la modalidad de pantalla completa + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 112}, {511, 31}} + + YES + + 67239424 + 4194304 + Activa la ventana raíz de X11. Use la combinación de teclas Comando + Opción + A para entrar o salir de la modalidad de pantalla completa. + + + + + + + + + {{10, 33}, {573, 246}} + + + Salida + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + Activar sincronización + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {501, 28}} + + YES + + 67239424 + 4194304 + Activa el ítem de menú “copiar†y permite sincronizar el portapapeles de OSX y los búfers CLIPBOARD y PRIMARY de X11. + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + Actualizar el CLIPBOARD cuando cambie el portapapeles + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {529, 23}} + + YES + + 67239424 + 0 + Actualizar el PRIMARY (clic con el botón central) cuando cambie el portapapeles + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 51}, {495, 18}} + + YES + + 67239424 + 0 + Actualizar el portapapeles de inmediato cuando se seleccione texto nuevo + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + Actualizar el portapapeles cuando cambie el CLIPBOARD + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{52, 125}, {485, 28}} + + YES + + 67239424 + 4194304 + Desactive esta opción si desea usar xclipboard, klipper o cualquier otro gestor de portapapeles de X11. + + + + + + + + + 256 + {{52, 17}, {485, 28}} + + YES + + 67239424 + 4194304 + A causa de las limitaciones del protocolo de X11, puede que esta opción no funcione siempre en algunas aplicaciones. + + + + + + + + {{10, 33}, {573, 246}} + + Portapapeles + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Hacer clic para pasar de una ventana inactiva a otra + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{33, 175}, {501, 31}} + + YES + + 67239424 + 4194304 + Cuando está activada, al hacer clic en una ventana inactiva, la ventana se activa y además el clic del ratón se transmite a ella. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Enfocar la posición del ratón + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{33, 117}, {501, 28}} + + YES + + 67239424 + 4194304 + El punto de enfoque de la ventana de X11 sigue el cursor. Esto conlleva algunos inconvenientes. + + + + + + + + + 256 + {{15, 93}, {402, 18}} + + YES + + 67239424 + 0 + Enfocar las ventanas nuevas + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{33, 45}, {501, 42}} + + YES + + 67239424 + 4194304 + Cuando está activada, al crear una nueva ventana de X11 el archivo X11.app se sitúa en primer plano (por encima de Finder.app, Terminal.app, etc.) + + + + + + + + {{10, 33}, {573, 246}} + + Ventanas + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Autenticar conexiones + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + Permitir conexiones de clientes de red + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {501, 42}} + + YES + + 67239424 + 4194304 + Al iniciar X11 se crearán unas claves de control de acceso Xauthority. Si la dirección IP del sistema cambia, estas claves dejarán de ser válidas, lo que impediría que pudiesen ejecutarse las aplicaciones X11. + + + + + + + + + + 256 + {{36, 71}, {501, 56}} + + YES + + 67239424 + 4194304 + Si esta opción está activada, la opción “Autenticar conexiones†también debe estarlo para garantizar la seguridad del sistema. Si está desactivada, las conexiones de aplicaciones remotas no están permitidas. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Estas opciones serán efectivas la próxima vez que se inicie X11. + + + + + + + + + {{10, 33}, {573, 246}} + + Seguridad + + + + + + + 0 + YES + YES + + + + + + {619, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {454, 271}} + 1350041600 + Menú de aplicaciones X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {110, 32}} + + YES + + 67239424 + 137887744 + Duplicar + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {110, 32}} + + YES + + 67239424 + 137887744 + Eliminar + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 105 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Nombre + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Celda de texto + + + + + 3 + MQA + + + + 3 + YES + YES + + + + + 88 + 40 + 1000 + + 75628096 + 2048 + Comando + + + + + + 338820672 + 1024 + Celda de texto + + + + + + + 3 + YES + YES + + + + + 99 + 10 + 1000 + + 75628096 + 2048 + Función rápida + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Celda de texto + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {114, 32}} + + YES + + -2080244224 + 137887744 + Añadir ítem + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Menú + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Aplicaciones + + 1048576 + 2147483647 + + + submenuAction: + + Aplicaciones + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizar… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/keyedobjects.nib index 4626ac776..8ca8ccf60 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/Spanish.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/locversion.plist index 30ee9ca2d..0fd47106e 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 100 - LprojLocale - ar - LprojRevisionLevel - 1 - LprojVersion - 100 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + ar + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/designable.nib index 1fac447f3..f5cc32825 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/designable.nib @@ -1,3584 +1,3747 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - حول X11 - - 2147483647 - - - - - - تÙضيلات... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - خدمات - - 1048576 - 2147483647 - - - submenuAction: - - خدمات - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - تبديل ملء الشاشة - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - إخÙاء X11 - h - 1048576 - 2147483647 - - - 42 - - - - إخÙاء الأخرى - h - 1572864 - 2147483647 - - - - - - إظهار الكل - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - إنهاء X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - التطبيقات - - 1048576 - 2147483647 - - - submenuAction: - - التطبيقات - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - تخصيص... - - 1048576 - 2147483647 - - - - - - - - - تحرير - - 1048576 - 2147483647 - - - submenuAction: - - تحرير - - - - نسخ - c - 1048576 - 2147483647 - - - - - - - - - ناÙذة - - 1048576 - 2147483647 - - - submenuAction: - - ناÙذة - - - - إغلاق - w - 1048576 - 2147483647 - - - - - - تصغير - m - 1048576 - 2147483647 - - - - - - تكبير/تصغير - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - تدوير عبر النواÙØ° - ` - 1048840 - 2147483647 - - - - - - عكس التدوير عبر النواÙØ° - ~ - 1179914 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - إحضار الكل إلى الأمام - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - مساعدة - - 1048576 - 2147483647 - - - submenuAction: - - مساعدة - - - - مساعدة X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 364}, {484, 308}} - 1350041600 - تÙضيلات X11 - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 67108992 - مصادقة الاتصالات - - LucidaGrande - 13 - 1044 - - - 1210864127 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 67108992 - السماح بالاتصالات من عملاء الشبكة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, 162}, {385, 42}} - - YES - - 67239424 - 71303296 - يؤدي بدء تشغيل X11 إلى إنشاء Ù…Ùاتيح تحكم ÙÙŠ وصول Xauthority. ÙÙŠ حالة تغيير عنوان IP للنظام، تصبح هذه المÙاتيح غير صالحة، مما قد يؤدي إلى الحيلولة دون بدء تشغيل تطبيقات X11. - - LucidaGrande - 11 - 3100 - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{17, 85}, {385, 42}} - - YES - - 67239424 - 71303296 - ÙÙŠ حالة التمكين، يجب أيضًا تمكين مصادقة الاتصالات للتأكد من تأمين النظام. ÙˆÙÙŠ حالة التعطيل، لا يتم السماح بالاتصالات من تطبيقات بعيدة. - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 71303296 - يتم تنÙيذ هذه الخيارات ÙÙŠ المرة التالية لبدء تشغيل X11. - - - - - - - - {{10, 33}, {438, 246}} - - الأمان - - - - - - 2 - - - - 256 - - - - 256 - {{17, 212}, {402, 18}} - - YES - - 67239424 - 67108992 - النقر خلال النواÙØ° غير النشطة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{19, 175}, {385, 31}} - - YES - - 67239424 - 71303296 - عند تمكينه، سيؤدي النقر على ناÙذة غير نشطة إلى مرور نقرة الماوس هذه عبر هذه الناÙذة بالإضاÙØ© إلى تنشيطها. - - - - - - - - - 256 - {{17, 151}, {402, 18}} - - YES - - 67239424 - 67108992 - التركيز تبعًا لموضع مؤشر الماوس - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{19, 128}, {385, 17}} - - YES - - 67239424 - 71303296 - يتبع تركيز ناÙذة X11 موضع المؤشر، ولهذا بعض الآثار السلبية. - - - - - - - - - 256 - {{17, 107}, {402, 18}} - - YES - - 67239424 - 67108992 - التركيز على النواÙØ° الجديدة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{19, 73}, {385, 28}} - - YES - - 67239424 - 71303296 - عند تمكينه، سيؤدي إنشاء ناÙذة X11 جديدة إلى انتقال تطبيق X11.app إلى المقدمة (بدلاً من Finder.app أو Terminal.app وما إلى ذلك) - - - - - - - - {{10, 33}, {438, 246}} - - نواÙØ° - - - - - - 2 - - - - 256 - - - - 256 - {{11, 222}, {409, 23}} - - YES - - 67239424 - 67108992 - تمكين المزامنة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, 188}, {385, 28}} - - YES - - 67239424 - 71303296 - يقوم بتمكين عنصر القائمة "نسخ" ويسمح بالمزامنة بين لوحة اللصق ÙÙŠ OSX وحاÙظة X11 وذاكرات التخزين المؤقت الأساسية. - - - - - - - - - 256 - {{-8, 96}, {409, 23}} - - YES - - 67239424 - 67108992 - تحديث الحاÙظة عند إجراء تغييرات على لوحة اللصق - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{-8, 71}, {409, 23}} - - YES - - 67239424 - 67108992 - تحديث الذاكرة الأساسية (نقر بالزر الأوسط) عند إجراء تغييرات على لوحة اللصق - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{-8, 46}, {409, 23}} - - YES - - 67239424 - 67108992 - تحديث لوحة اللصق على الÙور عند تحديد نص جديد - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{-8, 159}, {409, 23}} - - YES - - 67239424 - 67108992 - تحديث لوحة اللصق عند إجراء تغييرات على الحاÙظة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{2, 125}, {385, 28}} - - YES - - 67239424 - 71303296 - قم بتعطيل هذا الخيار إذا كنت ترغب ÙÙŠ استخدام xclipboard أوklipper أو أية أداة أخرى لإدارة حاÙظة X11. - - - - - - - - - 256 - {{17, 14}, {370, 28}} - - YES - - 67239424 - 71303296 - نظرًا للقيود الموجودة ÙÙŠ بروتوكول X11ØŒ قد لا يعمل هذا الخيار دومًا ÙÙŠ بعض التطبيقات. - - - - - - - - {{10, 33}, {438, 246}} - - لوحة اللصق - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 67108992 - استخدام تأثير تنبيه النظام - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, 29}, {385, 28}} - - YES - - 67239424 - 71303296 - تستخدم إشارات X11 الصوتية التنبيه القياسي للنظام، كما هو محدد ÙÙŠ لوحة تÙضيلات النظام لمؤثرات الصوت. - - - - - - - - - 256 - {{253, 202}, {128, 26}} - - YES - - -2076049856 - 67110016 - - - 111821055 - 1 - - LucidaGrande - 13 - 16 - - - - - - - - 400 - 75 - - - من شاشة العرض - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - ٢٥٦ لونًا - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - آلا٠- - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - ملايين - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{383, 205}, {55, 20}} - - YES - - 67239424 - 4194432 - الألوان: - - - - - - - - - 256 - {{10, 183}, {392, 14}} - - YES - - 67239424 - 71303296 - يتم تنÙيذ هذا الخيار ÙÙŠ المرة التالية لبدء تشغيل X11. - - - - - - - - - 256 - {{11, 149}, {409, 23}} - - YES - - 67239424 - 67108992 - وضع ملء الشاشة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{-8, 83}, {409, 23}} - - YES - - 67239424 - 67108992 - إظهار تلقائي لشريط القائمة ÙÙŠ وضع ملء الشاشة - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, 112}, {385, 31}} - - YES - - 67239424 - 71303296 - تمكين ناÙذة X11 root. استخدم ضغط Ù…Ùاتيح الأوامر-الاختيار-A لدخول ومغادرة وضع ملء الشاشة. - - - - - - - - {{10, 33}, {438, 246}} - - الإخراج - - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 67108992 - مضاهاة ماوس ثلاثي الأزرار - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, 60}, {385, 31}} - - YES - - 67239424 - 71303296 - ÙÙŠ حالة التمكين، قد تتداخل مكاÙئات Ù…Ùاتيح شريط القائمة مع تطبيقات X11 التي تستخدم Ù…Ùتاح تعديل Meta. - - - - - - - - - 256 - {{17, 162}, {385, 42}} - - YES - - 67239424 - 71303296 - 2KfYtti62Lcg2YXYuSDYp9mE2KfYs9iq2YXYsdin2LEg2LnZhNmJINmF2YHYqtin2K0g2KfZhNin2K7Y -qtmK2KfYsSDYo9mIINmF2YHYqtin2K0g2KfZhNij2YjYp9mF2LEg2KPYq9mG2KfYoSDYp9mE2YbZgtix -INmE2KrZhti02YrYtyDYstixINin2YTZhdin2YjYsyDYp9mE2KPZiNiz2Lcg2KPZiCDYp9mE2KPZitmF -2YYuCg - - - - - - - - - 256 - {{18, 97}, {402, 18}} - - YES - - 67239424 - 67108992 - تمكين مكاÙئات المÙاتيح ÙÙŠ X11 - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, 126}, {385, 14}} - - YES - - 67239424 - 71303296 - السماح لتغييرات قائمة الإدخال بالكتابة Ùوق مخطط Ù…Ùاتيح X11 الحالي. - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 67108992 - اتباع تصميم لوحة Ù…Ùاتيح النظام - - - 1210864127 - 2 - - - - - 200 - 25 - - - - - 256 - {{17, -1}, {385, 31}} - - YES - - 67239424 - 71303296 - عند تمكينها، تقوم Ù…Ùاتيح الاختيار بإرسال علامات المÙتاح Alt_L Ùˆ Alt_R X11 بدلًا من Mode_switch. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 67108992 - Ù…Ùاتيح الاختيار تقوم بإرسال Alt_L Ùˆ Alt_R - - - 1210864127 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - الإدخال - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {454, 271}} - 1350041600 - قائمة تطبيقات X11 - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 268 - {{14, 191}, {100, 32}} - - YES - - 67239424 - 137887872 - تكرار - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 268 - {{14, 159}, {100, 32}} - - YES - - 67239424 - 137887872 - إزالة - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 71 - 10 - 1000 - - 75628096 - 67110912 - Ù…Ùتاح اختصار - - - 6 - System - headerColor - - 3 - MQA - - - - 6 - System - headerTextColor - - - - - 338820672 - 67110016 - Text Cell - - LucidaGrande - 12 - 16 - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 99 - 40 - 1000 - - 75628096 - 67110912 - الأوامر - - - 3 - MC4zMzMzMzI5ODU2AA - - - - - 338820672 - 67110016 - Text Cell - - - - - - 3 - YES - YES - - - - 121.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 67110912 - الاسم - - - - - - 338820672 - 67110016 - Text Cell - - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{116, 20}, {318, 231}} - - - 50 - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 268 - {{14, 223}, {100, 32}} - - YES - - -2080244224 - 137887872 - إضاÙØ© عنصر - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - قائمة - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - التطبيقات - - 1048576 - 2147483647 - - - submenuAction: - - التطبيقات - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - تخصيص… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{631, 535}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{631, 535}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{209, 293}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{209, 293}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + حول X11 + + 2147483647 + + + + + + تÙضيلات... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + خدمات + + 1048576 + 2147483647 + + + submenuAction: + + خدمات + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + تبديل ملء الشاشة + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + إخÙاء X11 + h + 1048576 + 2147483647 + + + 42 + + + + إخÙاء الأخرى + h + 1572864 + 2147483647 + + + + + + إظهار الكل + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + إنهاء X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + التطبيقات + + 1048576 + 2147483647 + + + submenuAction: + + تطبيقات + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + تخصيص... + + 1048576 + 2147483647 + + + + + + + + + تحرير + + 1048576 + 2147483647 + + + submenuAction: + + تحرير + + + + نسخ + c + 1048576 + 2147483647 + + + + + + + + + ناÙذة + + 1048576 + 2147483647 + + + submenuAction: + + ناÙذة + + + + إغلاق + w + 1048576 + 2147483647 + + + + + + تصغير + m + 1048576 + 2147483647 + + + + + + تكبير/تصغير + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + تدوير عبر النواÙØ° + ` + 1048840 + 2147483647 + + + + + + عكس التدوير عبر النواÙØ° + ~ + 1179914 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + إحضار الكل إلى الأمام + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + مساعدة + + 1048576 + 2147483647 + + + submenuAction: + + مساعدة + + + + مساعدة X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 364}, {484, 308}} + 1350041600 + تÙضيلات X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 67108992 + مصادقة الاتصالات + + LucidaGrande + 13 + 1044 + + + 1210864127 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 67108992 + السماح بالاتصالات من عملاء الشبكة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{17, 162}, {385, 42}} + + YES + + 67239424 + 71303296 + يؤدي بدء تشغيل X11 إلى إنشاء Ù…Ùاتيح تحكم ÙÙŠ وصول Xauthority. ÙÙŠ حالة تغيير عنوان IP للنظام، تصبح هذه المÙاتيح غير صالحة، مما قد يؤدي إلى الحيلولة دون بدء تشغيل تطبيقات X11. + + LucidaGrande + 11 + 3100 + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{17, 85}, {385, 42}} + + YES + + 67239424 + 71303296 + ÙÙŠ حالة التمكين، يجب أيضًا تمكين مصادقة الاتصالات للتأكد من تأمين النظام. ÙˆÙÙŠ حالة التعطيل، لا يتم السماح بالاتصالات من تطبيقات بعيدة. + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 71303296 + يتم تنÙيذ هذه الخيارات ÙÙŠ المرة التالية لبدء تشغيل X11. + + + + + + + + {{10, 33}, {438, 246}} + + الأمان + + + + + + 2 + + + + 256 + + + + 256 + {{17, 212}, {402, 18}} + + YES + + 67239424 + 67108992 + النقر خلال النواÙØ° غير النشطة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{19, 175}, {385, 31}} + + YES + + 67239424 + 71303296 + عند تمكينه، سيؤدي النقر على ناÙذة غير نشطة إلى مرور نقرة الماوس هذه عبر هذه الناÙذة بالإضاÙØ© إلى تنشيطها. + + + + + + + + + 256 + {{17, 151}, {402, 18}} + + YES + + 67239424 + 67108992 + التركيز تبعًا لموضع مؤشر الماوس + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{19, 128}, {385, 17}} + + YES + + 67239424 + 71303296 + يتبع تركيز ناÙذة X11 موضع المؤشر، ولهذا بعض الآثار السلبية. + + + + + + + + + 256 + {{17, 107}, {402, 18}} + + YES + + 67239424 + 67108992 + التركيز على النواÙØ° الجديدة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{19, 73}, {385, 28}} + + YES + + 67239424 + 71303296 + عند تمكينه، سيؤدي إنشاء ناÙذة X11 جديدة إلى انتقال تطبيق X11.app إلى المقدمة (بدلاً من Finder.app أو Terminal.app وما إلى ذلك) + + + + + + + + {{10, 33}, {438, 246}} + + النواÙØ° + + + + + + 2 + + + + 256 + + + + 256 + {{11, 222}, {409, 23}} + + YES + + 67239424 + 67108992 + تمكين المزامنة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{17, 188}, {385, 28}} + + YES + + 67239424 + 71303296 + يقوم بتمكين عنصر القائمة "نسخ" ويسمح بالمزامنة بين لوحة اللصق ÙÙŠ OSX وحاÙظة X11 وذاكرات التخزين المؤقت الأساسية. + + + + + + + + + 256 + {{-8, 96}, {409, 23}} + + YES + + 67239424 + 67108992 + تحديث الحاÙظة عند إجراء تغييرات على لوحة اللصق + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{-8, 71}, {409, 23}} + + YES + + 67239424 + 67108992 + تحديث الذاكرة الأساسية (نقر بالزر الأوسط) عند إجراء تغييرات على لوحة اللصق + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{-8, 46}, {409, 23}} + + YES + + 67239424 + 67108992 + تحديث لوحة اللصق على الÙور عند تحديد نص جديد + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{-8, 159}, {409, 23}} + + YES + + 67239424 + 67108992 + تحديث لوحة اللصق عند إجراء تغييرات على الحاÙظة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{2, 125}, {385, 28}} + + YES + + 67239424 + 71303296 + قم بتعطيل هذا الخيار إذا كنت ترغب ÙÙŠ استخدام xclipboard أوklipper أو أية أداة أخرى لإدارة حاÙظة X11. + + + + + + + + + 256 + {{17, 14}, {370, 28}} + + YES + + 67239424 + 71303296 + نظرًا للقيود الموجودة ÙÙŠ بروتوكول X11ØŒ قد لا يعمل هذا الخيار دومًا ÙÙŠ بعض التطبيقات. + + + + + + + + {{10, 33}, {438, 246}} + + لوحة اللصق + + + + + + 2 + + + + 256 + + + + 256 + {{253, 202}, {128, 26}} + + YES + + -2076049856 + 67110016 + + + 111821055 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + من شاشة العرض + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + ٢٥٦ لونًا + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + آلا٠+ + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + ملايين + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{383, 205}, {55, 20}} + + YES + + 67239424 + 4194432 + الألوان: + + + + + + + + + 256 + {{10, 183}, {392, 14}} + + YES + + 67239424 + 71303296 + يتم تنÙيذ هذا الخيار ÙÙŠ المرة التالية لبدء تشغيل X11. + + + + + + + + + 256 + {{11, 149}, {409, 23}} + + YES + + 67239424 + 67108992 + وضع ملء الشاشة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{-8, 83}, {409, 23}} + + YES + + 67239424 + 67108992 + إظهار تلقائي لشريط القائمة ÙÙŠ وضع ملء الشاشة + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{17, 112}, {385, 31}} + + YES + + 67239424 + 71303296 + تمكين ناÙذة X11 root. استخدم ضغط Ù…Ùاتيح الأوامر-الاختيار-A لدخول ومغادرة وضع ملء الشاشة. + + + + + + + + {{10, 33}, {438, 246}} + + + الإخراج + + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 67108992 + مضاهاة ماوس ثلاثي الأزرار + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{17, 60}, {385, 31}} + + YES + + 67239424 + 71303296 + ÙÙŠ حالة التمكين، قد تتداخل مكاÙئات Ù…Ùاتيح شريط القائمة مع تطبيقات X11 التي تستخدم Ù…Ùتاح تعديل Meta. + + + + + + + + + 256 + {{17, 162}, {385, 42}} + + YES + + 67239424 + 71303296 + 2KfYtti62Lcg2YXYuSDYp9mE2KfYs9iq2YXYsdin2LEg2LnZhNmJINmF2YHYqtin2K0g2KfZhNin2K7Y +qtmK2KfYsSDYo9mIINmF2YHYqtin2K0g2KfZhNij2YjYp9mF2LEg2KPYq9mG2KfYoSDYp9mE2YbZgtix +INmE2KrZhti02YrYtyDYstixINin2YTZhdin2YjYsyDYp9mE2KPZiNiz2Lcg2KPZiCDYp9mE2KPZitmF +2YYuCg + + + + + + + + + 256 + {{18, 97}, {402, 18}} + + YES + + 67239424 + 67108992 + تمكين مكاÙئات المÙاتيح ÙÙŠ X11 + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{17, 126}, {385, 14}} + + YES + + 67239424 + 71303296 + السماح لتغييرات قائمة الإدخال بالكتابة Ùوق مخطط Ù…Ùاتيح X11 الحالي. + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 67108992 + اتباع تصميم لوحة Ù…Ùاتيح النظام + + + 1210864127 + 2 + + + + + 200 + 25 + + + + + 256 + {{17, -1}, {385, 31}} + + YES + + 67239424 + 71303296 + عند تمكينها، تقوم Ù…Ùاتيح الاختيار بإرسال علامات المÙتاح Alt_L Ùˆ Alt_R X11 بدلًا من Mode_switch. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 67108992 + Ù…Ùاتيح الاختيار تقوم بإرسال Alt_L Ùˆ Alt_R + + + 1210864127 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + الإدخال + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {454, 271}} + 1350041600 + قائمة تطبيقات X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 268 + {{14, 191}, {100, 32}} + + YES + + 67239424 + 137887872 + تكرار + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 268 + {{14, 159}, {100, 32}} + + YES + + 67239424 + 137887872 + إزالة + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 71 + 10 + 1000 + + 75628096 + 67110912 + Ù…Ùتاح اختصار + + + 6 + System + headerColor + + 3 + MQA + + + + 6 + System + headerTextColor + + + + + 338820672 + 67110016 + Text Cell + + LucidaGrande + 12 + 16 + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 99 + 40 + 1000 + + 75628096 + 67110912 + الأوامر + + + 3 + MC4zMzMzMzI5OQA + + + + + 338820672 + 67110016 + Text Cell + + + + + + 3 + YES + YES + + + + 121.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 67110912 + الاسم + + + + + + 338820672 + 67110016 + Text Cell + + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{116, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 268 + {{14, 223}, {100, 32}} + + YES + + -2080244224 + 137887872 + إضاÙØ© عنصر + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + قائمة + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + التطبيقات + + 1048576 + 2147483647 + + + submenuAction: + + تطبيقات + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + تخصيص… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/keyedobjects.nib index 97032d978..f78f6a9c7 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/ar.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/da.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/da.lproj/locversion.plist index 3cba12a62..de5508ec1 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/da.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/da.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 100 - LprojLocale - da - LprojRevisionLevel - 1 - LprojVersion - 100 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + da + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/designable.nib index 430a58303..fb13cdcdf 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/designable.nib @@ -1,3590 +1,3758 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Om X11 - - 2147483647 - - - - - - Indstillinger... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tjenester - - 1048576 - 2147483647 - - - submenuAction: - - Tjenester - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - SlÃ¥ Fuld skærm til og fra - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Skjul X11 - h - 1048576 - 2147483647 - - - 42 - - - - Skul andre - h - 1572864 - 2147483647 - - - - - - Vis alle - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Slut X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Programmer - - 1048576 - 2147483647 - - - submenuAction: - - Programmer - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tilpas... - - 1048576 - 2147483647 - - - - - - - - - Rediger - - 1048576 - 2147483647 - - - submenuAction: - - Rediger - - - - Kopier - c - 1048576 - 2147483647 - - - - - - - - - Vindue - - 1048576 - 2147483647 - - - submenuAction: - - Vindue - - - - Luk - w - 1048576 - 2147483647 - - - - - - Minimer - m - 1048576 - 2147483647 - - - - - - Zoom - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - GennemgÃ¥ vinduer - < - 1048576 - 2147483647 - - - - - - GennemgÃ¥ vinduer modsat - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Anbring alle forrest - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Hjælp - - 1048576 - 2147483647 - - - submenuAction: - - Hjælp - - - - X11-hjælp - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{319, 328}, {484, 308}} - 1350041600 - X11-indstillinger - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Emuler mus med tre knapper - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 63}, {355, 28}} - - YES - - 67239424 - 4194304 - NÃ¥r tastaturgenveje pÃ¥ menulinjen er slÃ¥et til, kan de hindre X11-programmer, der bruger "Meta modifier", i at fungere. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 162}, {385, 42}} - - YES - - 67239424 - 4194304 - SG9sZCBBbHRlcm5hdGl2LSBlbGxlciBLb21tYW5kb3Rhc3RlbiBuZWRlLCBtZW5zIGR1IGtsaWtrZXIs -IGZvciBhdCBha3RpdmVyZSBkZW4gbWlkdGVyc3RlIGVsbGVyIGRlbiBow7hqcmUga25hcCBww6UgbXVz -ZW4uCg - - - - - - - - - - 256 - {{18, 97}, {402, 18}} - - YES - - 67239424 - 0 - SlÃ¥ tastaturgenveje til under X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 126}, {385, 14}} - - YES - - 67239424 - 4194304 - Sikrer, at ændringer kan overskrive den aktuelle X11-tastoversigt. - - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 0 - Følg systemets tastaturlayout - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - NÃ¥r det er slÃ¥et til, sender Alternativtasterne Alt_L og Alt_R X11-nøglesymboler i stedet for Mode_switch. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 0 - Alternativtaster sender Alt_L og Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - Indtastning - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - Brug systemets advarsler - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {351, 28}} - - YES - - 67239424 - 4194304 - Advarselslyde i X11 bruger systemets standardadvarsler, som er defineret i Lydeffekter i Systemindstillinger. - - - - - - - - - - 256 - {{70, 202}, {128, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Fra skærm - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 farver - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Tusinder - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Millioner - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {55, 20}} - - YES - - 67239424 - 4194304 - Farver: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Denne indstilling træder i kraft, nÃ¥r X11 startes igen. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - Fuld skærm - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {383, 23}} - - YES - - 67239424 - 0 - Vis automatisk menulinjen, nÃ¥r der bruges fuld skærm - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 115}, {351, 28}} - - YES - - 67239424 - 4194304 - SlÃ¥r X11 root-vinduet til. Brug Kommando-Alternativ-A til at slÃ¥ funktionen fuld skærm til og fra. - - - - - - - - - {{10, 33}, {438, 246}} - - Resultat - - - - - - 2 - - - - 256 - - - - 256 - {{13, 222}, {409, 23}} - - YES - - 67239424 - 0 - SlÃ¥ synkronisering til - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{31, 188}, {392, 28}} - - YES - - 67239424 - 4194304 - SlÃ¥r kommandoen "kopier" til og gør det muligt at synkronisere mellem OSX-opslagstavlen og X11-UDKLIPSHOLDEREN og de PRIMÆRE buffere. - - - - - - - - - 256 - {{29, 96}, {398, 23}} - - YES - - 67239424 - 0 - Opdater CLIPBOARD, nÃ¥r opslagstavlen ændres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{29, 71}, {400, 23}} - - YES - - 67239424 - 0 - Opdater PRIMARY (klik i midten), nÃ¥r opslagstavlen ændres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{29, 51}, {404, 18}} - - YES - - 67239424 - 0 - Opdater opslagstavlen med det samme, nÃ¥r ny tekst er valgt - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{29, 159}, {398, 23}} - - YES - - 67239424 - 0 - Opdater opslagstavlen, nÃ¥r CLIPBOARD ændres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{43, 125}, {385, 28}} - - YES - - 67239424 - 4194304 - SlÃ¥ denne indstilling fra, hvis du ikke vil bruge xclipboard, klipper eller andre X11-værktøjer til administration af udklipsholderen. - - - - - - - - - 256 - {{43, 14}, {385, 28}} - - YES - - 67239424 - 4194304 - Pga. begrænsninger i X11-protokollen virker denne indstilling mÃ¥ske ikke i nogle programmer. - - - - - - - - {{10, 33}, {438, 246}} - - Opslagstavle - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Klik igennem passive vinduer - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {390, 31}} - - YES - - 67239424 - 4194304 - NÃ¥r denne mulighed er slÃ¥et til, vil musen, nÃ¥r du klikker pÃ¥ et passivt vindue, klikke igennem vinduet ud over at gøre det aktivt. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Fokus følger musen - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 128}, {385, 17}} - - YES - - 67239424 - 4194304 - Fokus i X11-vinduet følger markøren. - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - Fokus pÃ¥ nye vinduer - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 59}, {390, 42}} - - YES - - 67239424 - 4194304 - NÃ¥r denne mulighed er slÃ¥et til, vil programmet X11, nÃ¥r der oprettes et nyt X11-vindue, anbringes forrest (i stedet for Finder, Terminal osv.). - - - - - - - - {{10, 33}, {438, 246}} - - Vinduer - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Godkend forbindelser - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - Tillad forbindelser fra netværksklienter - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {379, 42}} - - YES - - 67239424 - 4194304 - NÃ¥r X11 startes, oprettes Xauthority-taster til adgangskontrol. Hvis systemets IP-adresse ændres, bliver disse taster ugyldige, og det kan forhindre X11-programmer i at starte. - - - - - - - - - - 256 - {{36, 85}, {380, 42}} - - YES - - 67239424 - 4194304 - Hvis de er slÃ¥et til, skal Godkend forbindelser ogsÃ¥ slÃ¥s til for at sikre systemets sikkerhed. NÃ¥r de er slÃ¥et fra, tillades forbindelser fra eksterne programmer ikke. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Disse indstillinger træder i kraft, nÃ¥r X11 startes igen. - - - - - - - - - {{10, 33}, {438, 246}} - - Sikkerhed - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{360, 400}, {454, 271}} - 1350041600 - X11-programmenu - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {112, 32}} - - YES - - 67239424 - 137887744 - Dubler - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {112, 32}} - - YES - - 67239424 - 137887744 - Fjern - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 122.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Navn - - - 3 - MC4zMzMzMzI5OQA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 100 - 40 - 1000 - - 75628096 - 2048 - Kommando - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - 69 - 10 - 1000 - - 75628096 - 2048 - Genvej - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492380000000002 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460000000004 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {112, 32}} - - YES - - -2080244224 - 137887744 - Tilføj emne - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Menu - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Programmer - - 1048576 - 2147483647 - - - submenuAction: - - Programmer - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Indstil… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 565}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 565}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Om X11 + + 2147483647 + + + + + + Indstillinger... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tjenester + + 1048576 + 2147483647 + + + submenuAction: + + Tjenester + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + SlÃ¥ Fuld skærm til og fra + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Skjul X11 + h + 1048576 + 2147483647 + + + 42 + + + + Skul andre + h + 1572864 + 2147483647 + + + + + + Vis alle + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Slut X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Programmer + + 1048576 + 2147483647 + + + submenuAction: + + Programmer + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tilpas... + + 1048576 + 2147483647 + + + + + + + + + Rediger + + 1048576 + 2147483647 + + + submenuAction: + + Rediger + + + + Kopier + c + 1048576 + 2147483647 + + + + + + + + + Vindue + + 1048576 + 2147483647 + + + submenuAction: + + Vindue + + + + Luk + w + 1048576 + 2147483647 + + + + + + Minimer + m + 1048576 + 2147483647 + + + + + + Zoom + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + GennemgÃ¥ vinduer + < + 1048576 + 2147483647 + + + + + + GennemgÃ¥ vinduer modsat + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Anbring alle forrest + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Hjælp + + 1048576 + 2147483647 + + + submenuAction: + + Hjælp + + + + X11-hjælp + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{319, 328}, {484, 308}} + 1350041600 + X11-indstillinger + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Emuler mus med tre knapper + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 63}, {355, 28}} + + YES + + 67239424 + 4194304 + NÃ¥r tastaturgenveje pÃ¥ menulinjen er slÃ¥et til, kan de hindre X11-programmer, der bruger "Meta modifier", i at fungere. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + SG9sZCBBbHRlcm5hdGl2LSBlbGxlciBLb21tYW5kb3Rhc3RlbiBuZWRlLCBtZW5zIGR1IGtsaWtrZXIs +IGZvciBhdCBha3RpdmVyZSBkZW4gbWlkdGVyc3RlIGVsbGVyIGRlbiBow7hqcmUga25hcCBww6UgbXVz +ZW4uCg + + + + + + + + + + 256 + {{18, 97}, {402, 18}} + + YES + + 67239424 + 0 + SlÃ¥ tastaturgenveje til under X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 126}, {385, 14}} + + YES + + 67239424 + 4194304 + Sikrer, at ændringer kan overskrive den aktuelle X11-tastoversigt. + + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 0 + Følg systemets tastaturlayout + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + NÃ¥r det er slÃ¥et til, sender Alternativtasterne Alt_L og Alt_R X11-nøglesymboler i stedet for Mode_switch. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Alternativtaster sender Alt_L og Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + Indtastning + + + + + + 2 + + + + 256 + + + + 256 + {{70, 202}, {128, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Fra skærm + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 farver + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Tusinder + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Millioner + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {55, 20}} + + YES + + 67239424 + 4194304 + Farver: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Denne indstilling træder i kraft, nÃ¥r X11 startes igen. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + Fuld skærm + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {383, 23}} + + YES + + 67239424 + 0 + Vis automatisk menulinjen, nÃ¥r der bruges fuld skærm + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 115}, {351, 28}} + + YES + + 67239424 + 4194304 + SlÃ¥r X11 root-vinduet til. Brug Kommando-Alternativ-A til at slÃ¥ funktionen fuld skærm til og fra. + + + + + + + + + {{10, 33}, {438, 246}} + + + Resultat + + + + + + 2 + + + + 256 + + + + 256 + {{13, 222}, {409, 23}} + + YES + + 67239424 + 0 + SlÃ¥ synkronisering til + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{31, 188}, {392, 28}} + + YES + + 67239424 + 4194304 + SlÃ¥r kommandoen "kopier" til og gør det muligt at synkronisere mellem OSX-opslagstavlen og X11-UDKLIPSHOLDEREN og de PRIMÆRE buffere. + + + + + + + + + 256 + {{29, 96}, {398, 23}} + + YES + + 67239424 + 0 + Opdater CLIPBOARD, nÃ¥r opslagstavlen ændres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{29, 71}, {400, 23}} + + YES + + 67239424 + 0 + Opdater PRIMARY (klik i midten), nÃ¥r opslagstavlen ændres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{29, 51}, {404, 18}} + + YES + + 67239424 + 0 + Opdater opslagstavlen med det samme, nÃ¥r ny tekst er valgt + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{29, 159}, {398, 23}} + + YES + + 67239424 + 0 + Opdater opslagstavlen, nÃ¥r CLIPBOARD ændres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{43, 125}, {385, 28}} + + YES + + 67239424 + 4194304 + SlÃ¥ denne indstilling fra, hvis du ikke vil bruge xclipboard, klipper eller andre X11-værktøjer til administration af udklipsholderen. + + + + + + + + + 256 + {{43, 14}, {385, 28}} + + YES + + 67239424 + 4194304 + Pga. begrænsninger i X11-protokollen virker denne indstilling mÃ¥ske ikke i nogle programmer. + + + + + + + + {{10, 33}, {438, 246}} + + Opslagstavle + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Klik igennem passive vinduer + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {390, 31}} + + YES + + 67239424 + 4194304 + NÃ¥r denne mulighed er slÃ¥et til, vil musen, nÃ¥r du klikker pÃ¥ et passivt vindue, klikke igennem vinduet ud over at gøre det aktivt. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Fokus følger musen + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 128}, {385, 17}} + + YES + + 67239424 + 4194304 + Fokus i X11-vinduet følger markøren. + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + Fokus pÃ¥ nye vinduer + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 59}, {390, 42}} + + YES + + 67239424 + 4194304 + NÃ¥r denne mulighed er slÃ¥et til, vil programmet X11, nÃ¥r der oprettes et nyt X11-vindue, anbringes forrest (i stedet for Finder, Terminal osv.). + + + + + + + + {{10, 33}, {438, 246}} + + Vinduer + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Godkend forbindelser + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + Tillad forbindelser fra netværksklienter + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {379, 42}} + + YES + + 67239424 + 4194304 + NÃ¥r X11 startes, oprettes Xauthority-taster til adgangskontrol. Hvis systemets IP-adresse ændres, bliver disse taster ugyldige, og det kan forhindre X11-programmer i at starte. + + + + + + + + + + 256 + {{36, 85}, {380, 42}} + + YES + + 67239424 + 4194304 + Hvis de er slÃ¥et til, skal Godkend forbindelser ogsÃ¥ slÃ¥s til for at sikre systemets sikkerhed. NÃ¥r de er slÃ¥et fra, tillades forbindelser fra eksterne programmer ikke. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Disse indstillinger træder i kraft, nÃ¥r X11 startes igen. + + + + + + + + + {{10, 33}, {438, 246}} + + Sikkerhed + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{360, 400}, {454, 271}} + 1350041600 + X11-programmenu + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {112, 32}} + + YES + + 67239424 + 137887744 + Dubler + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {112, 32}} + + YES + + 67239424 + 137887744 + Fjern + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 122.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Navn + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 100 + 40 + 1000 + + 75628096 + 2048 + Kommando + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + 69 + 10 + 1000 + + 75628096 + 2048 + Genvej + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {112, 32}} + + YES + + -2080244224 + 137887744 + Tilføj emne + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Menu + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Programmer + + 1048576 + 2147483647 + + + submenuAction: + + Programmer + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Indstil… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/keyedobjects.nib index 918cbc465..eefa1cf65 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/da.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/locversion.plist index d11622020..4e86b4083 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - fi - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + fi + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/designable.nib index d506b7bfe..3f654decd 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/designable.nib @@ -1,3603 +1,3518 @@ - - - - 1040 - 11A79a - 732 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 732 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Tietoja: X11 - - 2147483647 - - - - - - Asetukset... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Palvelut - - 1048576 - 2147483647 - - - submenuAction: - - Palvelut - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Vaihda koko näytön tila - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Kätke X11 - h - 1048576 - 2147483647 - - - 42 - - - - Kätke muut - h - 1572864 - 2147483647 - - - - - - Näytä kaikki - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Lopeta X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Ohjelmat - - 1048576 - 2147483647 - - - submenuAction: - - Ohjelmat - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Muokkaa... - - 1048576 - 2147483647 - - - - - - - - - Muokkaa - - 1048576 - 2147483647 - - - submenuAction: - - Muokkaa - - - - Kopioi - c - 1048576 - 2147483647 - - - - - - - - - Ikkuna - - 1048576 - 2147483647 - - - submenuAction: - - Ikkuna - - - - Sulje - w - 1048576 - 2147483647 - - - - - - Pienennä - m - 1048576 - 2147483647 - - - - - - Zoomaa - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Käy ikkunoita läpi - < - 1048576 - 2147483647 - - - - - - Käy ikkunoita läpi käänteisessä järjestyksessä - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tuo kaikki eteen - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Ohje - - 1048576 - 2147483647 - - - submenuAction: - - Ohje - - - - X11-ohje - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 349}, {625, 323}} - 1350041600 - X11-asetukset - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {604, 307}} - - - - - 1 - - - - 256 - - - - 256 - {{38, 225}, {402, 18}} - - YES - - 67239424 - 0 - Emuloi kolmenäppäimistä hiirtä - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{56, 67}, {488, 28}} - - YES - - 67239424 - 4194304 - Kun käytössä, valikkorivin näppäinvastineet saattavat häiritä X11-ohjelmia, jotka käyttävät Meta-muuntonäppäintä. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{56, 177}, {488, 42}} - - YES - - 67239424 - 4194304 - QWt0aXZvaSBoaWlyZW4ga2Vza2ktIHRhaSBvaWtlYSBwYWluaWtlIHBpdMOkbcOkbGzDpCBPcHRpby0g -dGFpIEtvbWVudG8tbsOkcHDDpGltacOkIHBhaW5ldHR1bmEgb3NvaXRldHRhZXNzYS4KA - - - - - - - - - - 256 - {{38, 101}, {402, 18}} - - YES - - 67239424 - 0 - Ota käyttöön näppäinvastineet X11:ssä - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{56, 137}, {385, 14}} - - YES - - 67239424 - 4194304 - Salli syöttövalikon muutosten korvata nykyinen X11-näppäinkartta. - - - - - - - - - - 256 - {{38, 157}, {402, 18}} - - YES - - 67239424 - 0 - Noudata järjestelmän näppäinasettelua - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{56, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - Kun käytössä, Optio-näppäimet lähettävät Alt_L- ja Alt_R X11 -näppäinsymbolit Mode_switchin sijaan. - - - - - - - - - 256 - {{38, 36}, {402, 18}} - - YES - - 67239424 - 0 - Optio-näppäimet lähettävät Alt_L:n ja Alt_R:n - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {584, 261}} - - - Syöte - - - - - - 2 - - - - 256 - - - - 256 - {{42, 74}, {402, 18}} - - YES - - 67239424 - 0 - Käytä järjestelmän varoitustehostetta - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{60, 40}, {488, 28}} - - YES - - 67239424 - 4194304 - X11:n äänimerkit käyttävät normaalia järjestelmävaroitusta, joka määritellään Äänitehosteet-järjestelmäasetuspaneelissa. - - - - - - - - - - 256 - {{83, 217}, {118, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Näytöltä - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 väriä - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Tuhansia - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Miljoonia - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{41, 220}, {55, 20}} - - YES - - 67239424 - 4194304 - Värit: - - - - - - - - - - 256 - {{60, 198}, {392, 14}} - - YES - - 67239424 - 4194304 - Tämä valinta tulee voimaan, kun X11 avataan seuraavan kerran. - - - - - - - - - - 256 - {{42, 164}, {409, 23}} - - YES - - 67239424 - 0 - Koko näytön tila - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{61, 98}, {409, 23}} - - YES - - 67239424 - 0 - Näytä valikkorivi automaattisesti koko näytön tilassa - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{60, 130}, {496, 28}} - - YES - - 67239424 - 4194304 - Ottaa käyttöön X11:n juuri-ikkunan. Voit siirtyä koko näytön tilaan ja siitä pois painamalla Komento-Optio-A. - - - - - - - - - {{10, 33}, {584, 261}} - - Tuloste - - - - - - 2 - - - - 256 - - - - 256 - {{1, 229}, {409, 23}} - - YES - - 67239424 - 0 - Ota synkronointi käyttöön - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{20, 181}, {534, 42}} - - YES - - 67239424 - 4194304 - Ottaa käyttöön Kopioi-valikkokohteen ja mahdollistaa synkronoinnin Mac OS X:n leikepöydän ja X11:n leikepöydän ja ensisijaisen valinnan puskurin välillä. - - - - - - - - - 256 - {{11, 102}, {410, 18}} - - YES - - 67239424 - 0 - Päivitä X11:n leikepöytä, kun Mac OS X:n leikepöytä muuttuu - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{11, 69}, {572, 18}} - - YES - - 67239424 - 0 - Päivitä X11:n ensisijainen valinta (keskiosoitus), kun Mac OS X:n leikepöytä muuttuu - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{11, 33}, {409, 23}} - - YES - - 67239424 - 0 - Päivitä Mac OS X:n leikepöytä heti, kun uutta tekstiä valitaan - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{11, 165}, {438, 18}} - - YES - - 67239424 - 0 - Päivitä Mac OS X:n leikepöytä, kun X11:n leikepöytä muuttuu - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{25, 131}, {522, 28}} - - YES - - 67239424 - 4194304 - Poista tämä valinta käytöstä, jos haluat käyttää xclipboardia, klipperiä tai muuta X11-leikepöytäohjelmaa. - - - - - - - - - 256 - {{25, 2}, {522, 28}} - - YES - - 67239424 - 4194304 - X11-protokollan rajoitusten vuoksi tämä valinta ei välttämättä aina toimi kaikissa ohjelmissa. - - - - - - - - {{10, 33}, {584, 261}} - - Leikepöytä - - - - - - 2 - - - - 256 - - - - 256 - {{55, 227}, {318, 18}} - - YES - - 67239424 - 0 - Huomioi osoitukset ei-aktiivisiin ikkunoihin - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{63, 190}, {488, 31}} - - YES - - 67239424 - 4194304 - Kun käytössä, ei-aktiivisen ikkunan osoittaminen saa hiiren osoituksen kulkemaan kyseiselle ikkunalle sen aktivoimisen lisäksi. - - - - - - - - - 256 - {{55, 166}, {402, 18}} - - YES - - 67239424 - 0 - Kohdistus seuraa hiirtä - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{63, 143}, {407, 17}} - - YES - - 67239424 - 4194304 - X11:n ikkunakohdistus seuraa osoitinta. Tällä on joitakin haittavaikutuksia. - - - - - - - - - 256 - {{55, 119}, {402, 18}} - - YES - - 67239424 - 0 - Kohdista uusiin ikkunoihin - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{63, 85}, {488, 28}} - - YES - - 67239424 - 4194304 - Kun käytössä, uuden X11-ikkunan luominen saa X11.appin siirtymään etualalle (Finder.appin, Pääte.appin jne. sijasta). - - - - - - - - {{10, 33}, {584, 261}} - - Ikkunat - - - - - - - 256 - - - - 256 - {{47, 225}, {402, 18}} - - YES - - 67239424 - 0 - Todenna yhteydet - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{47, 148}, {402, 18}} - - YES - - 67239424 - 0 - Salli yhteydet verkkoasiakkailta - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{65, 177}, {488, 42}} - - YES - - 67239424 - 4194304 - X11:n avaaminen luo Xauthority-pääsynhallinta-avaimia. Jos järjestelmän IP-osoite muuttuu, näistä avaimista tulee virheellisiä, mikä saattaa estää X11-ohjelmia avautumasta. - - - - - - - - - - 256 - {{65, 100}, {488, 42}} - - YES - - 67239424 - 4194304 - Jos tämä otetaan käyttöön, â€Todenna yhteydet†pitää myös ottaa käyttöön järjestelmän turvallisuuden varmistamiseksi. Kun tämä on pois käytöstä, yhteyksiä etäohjelmista ei sallita. - - - - - - - - - - 256 - {{49, -16}, {363, 17}} - - YES - - 67239424 - 4194304 - Nämä valinnat tulevat voimaan, kun X11 avataan seuraavan kerran. - - - - - - - - - {{10, 33}, {584, 261}} - - Suojaus - - - - - - - 0 - YES - YES - - - - - - {625, 323} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {469, 271}} - 1350041600 - X11-ohjelmavalikko - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {115, 32}} - - YES - - 67239424 - 137887744 - Monista - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {115, 32}} - - YES - - 67239424 - 137887744 - Poista - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 121.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Nimi - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 99 - 40 - 1000 - - 75628096 - 2048 - Komento - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - 71 - 10 - 1000 - - 75628096 - 2048 - Oikotie - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {115, 32}} - - YES - - -2080244224 - 137887744 - Lisää kohde - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {469, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Valikko - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Ohjelmat - - 1048576 - 2147483647 - - - submenuAction: - - Ohjelmat - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Muokkaa… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 533}, {625, 323}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 533}, {625, 323}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {469, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {469, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - + + + + 1040 + 11A194b + 787 + 1079 + 502.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 787 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Tietoja: X11 + + 2147483647 + + + + + + Asetukset... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Palvelut + + 1048576 + 2147483647 + + + submenuAction: + + Palvelut + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Vaihda koko näytön tila + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Kätke X11 + h + 1048576 + 2147483647 + + + 42 + + + + Kätke muut + h + 1572864 + 2147483647 + + + + + + Näytä kaikki + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Lopeta X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Ohjelmat + + 1048576 + 2147483647 + + + submenuAction: + + Ohjelmat + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Muokkaa... + + 1048576 + 2147483647 + + + + + + + + + Muokkaa + + 1048576 + 2147483647 + + + submenuAction: + + Muokkaa + + + + Kopioi + c + 1048576 + 2147483647 + + + + + + + + + Ikkuna + + 1048576 + 2147483647 + + + submenuAction: + + Ikkuna + + + + Sulje + w + 1048576 + 2147483647 + + + + + + Pienennä + m + 1048576 + 2147483647 + + + + + + Zoomaa + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Käy ikkunoita läpi + < + 1048576 + 2147483647 + + + + + + Käy ikkunoita läpi käänteisessä järjestyksessä + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tuo kaikki eteen + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Ohje + + 1048576 + 2147483647 + + + submenuAction: + + Ohje + + + + X11-ohje + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 349}, {625, 323}} + 1350041600 + X11-asetukset + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {604, 307}} + + + + + 1 + + + + 256 + + + + 256 + {{38, 225}, {402, 18}} + + YES + + 67239424 + 0 + Emuloi kolmenäppäimistä hiirtä + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{56, 67}, {488, 28}} + + YES + + 67239424 + 4194304 + Kun käytössä, valikkorivin näppäinvastineet saattavat häiritä X11-ohjelmia, jotka käyttävät Meta-muuntonäppäintä. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{56, 177}, {488, 42}} + + YES + + 67239424 + 4194304 + QWt0aXZvaSBoaWlyZW4ga2Vza2ktIHRhaSBvaWtlYSBwYWluaWtlIHBpdMOkbcOkbGzDpCBPcHRpby0g +dGFpIEtvbWVudG8tbsOkcHDDpGltacOkIHBhaW5ldHR1bmEgb3NvaXRldHRhZXNzYS4KA + + + + + + + + + + 256 + {{38, 101}, {402, 18}} + + YES + + 67239424 + 0 + Ota käyttöön näppäinvastineet X11:ssä + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{56, 137}, {385, 14}} + + YES + + 67239424 + 4194304 + Salli syöttövalikon muutosten korvata nykyinen X11-näppäinkartta. + + + + + + + + + + 256 + {{38, 157}, {402, 18}} + + YES + + 67239424 + 0 + Noudata järjestelmän näppäinasettelua + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{56, -1}, {488, 31}} + + YES + + 67239424 + 4194304 + Kun käytössä, Optio-näppäimet lähettävät Alt_L- ja Alt_R X11 -näppäinsymbolit Mode_switchin sijaan. + + + + + + + + + 256 + {{38, 36}, {402, 18}} + + YES + + 67239424 + 0 + Optio-näppäimet lähettävät Alt_L:n ja Alt_R:n + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {584, 261}} + + Syöte + + + + + + 2 + + + + 256 + + + + 256 + {{83, 217}, {118, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Näytöltä + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 väriä + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Tuhansia + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Miljoonia + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{41, 220}, {45, 20}} + + YES + + 67239424 + 4194304 + Värit: + + + + + + + + + + 256 + {{60, 198}, {392, 14}} + + YES + + 67239424 + 4194304 + Tämä valinta tulee voimaan, kun X11 avataan seuraavan kerran. + + + + + + + + + + 256 + {{42, 164}, {409, 23}} + + YES + + 67239424 + 0 + Koko näytön tila + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{61, 98}, {409, 23}} + + YES + + 67239424 + 0 + Näytä valikkorivi automaattisesti koko näytön tilassa + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{60, 130}, {496, 28}} + + YES + + 67239424 + 4194304 + Ottaa käyttöön X11:n juuri-ikkunan. Voit siirtyä koko näytön tilaan ja siitä pois painamalla Komento-Optio-A. + + + + + + + + + {{10, 33}, {584, 261}} + + + Tuloste + + + + + + 2 + + + + 256 + + + + 256 + {{1, 229}, {409, 23}} + + YES + + 67239424 + 0 + Ota synkronointi käyttöön + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{20, 189}, {527, 34}} + + YES + + 67239424 + 4194304 + Ottaa käyttöön Kopioi-valikkokohteen ja mahdollistaa synkronoinnin Mac OS X:n leikepöydän ja X11:n leikepöydän ja ensisijaisen valinnan puskurin välillä. + + + + + + + + + 256 + {{11, 102}, {410, 18}} + + YES + + 67239424 + 0 + Päivitä X11:n leikepöytä, kun Mac OS X:n leikepöytä muuttuu + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{11, 69}, {572, 18}} + + YES + + 67239424 + 0 + Päivitä X11:n ensisijainen valinta (keskiosoitus), kun Mac OS X:n leikepöytä muuttuu + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{11, 33}, {409, 23}} + + YES + + 67239424 + 0 + Päivitä Mac OS X:n leikepöytä heti, kun uutta tekstiä valitaan + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{11, 165}, {438, 18}} + + YES + + 67239424 + 0 + Päivitä Mac OS X:n leikepöytä, kun X11:n leikepöytä muuttuu + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{25, 131}, {522, 28}} + + YES + + 67239424 + 4194304 + Poista tämä valinta käytöstä, jos haluat käyttää xclipboardia, klipperiä tai muuta X11-leikepöytäohjelmaa. + + + + + + + + + 256 + {{25, 2}, {522, 28}} + + YES + + 67239424 + 4194304 + X11-protokollan rajoitusten vuoksi tämä valinta ei välttämättä aina toimi kaikissa ohjelmissa. + + + + + + + + {{10, 33}, {584, 261}} + + Leikepöytä + + + + + + 2 + + + + 256 + + + + 256 + {{55, 227}, {318, 18}} + + YES + + 67239424 + 0 + Huomioi osoitukset ei-aktiivisiin ikkunoihin + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{63, 190}, {488, 31}} + + YES + + 67239424 + 4194304 + Kun käytössä, ei-aktiivisen ikkunan osoittaminen saa hiiren osoituksen kulkemaan kyseiselle ikkunalle sen aktivoimisen lisäksi. + + + + + + + + + 256 + {{55, 166}, {402, 18}} + + YES + + 67239424 + 0 + Kohdistus seuraa hiirtä + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{63, 143}, {407, 17}} + + YES + + 67239424 + 4194304 + X11:n ikkunakohdistus seuraa osoitinta. Tällä on joitakin haittavaikutuksia. + + + + + + + + + 256 + {{55, 119}, {402, 18}} + + YES + + 67239424 + 0 + Kohdista uusiin ikkunoihin + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{63, 85}, {488, 28}} + + YES + + 67239424 + 4194304 + Kun käytössä, uuden X11-ikkunan luominen saa X11.appin siirtymään etualalle (Finder.appin, Pääte.appin jne. sijasta). + + + + + + + + {{10, 33}, {584, 261}} + + Ikkunat + + + + + + + 256 + + + + 256 + {{47, 225}, {402, 18}} + + YES + + 67239424 + 0 + Todenna yhteydet + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{47, 148}, {402, 18}} + + YES + + 67239424 + 0 + Salli yhteydet verkkoasiakkailta + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{65, 177}, {488, 42}} + + YES + + 67239424 + 4194304 + X11:n avaaminen luo Xauthority-pääsynhallinta-avaimia. Jos järjestelmän IP-osoite muuttuu, näistä avaimista tulee virheellisiä, mikä saattaa estää X11-ohjelmia avautumasta. + + + + + + + + + + 256 + {{65, 100}, {488, 42}} + + YES + + 67239424 + 4194304 + Jos tämä otetaan käyttöön, â€Todenna yhteydet†pitää myös ottaa käyttöön järjestelmän turvallisuuden varmistamiseksi. Kun tämä on pois käytöstä, yhteyksiä etäohjelmista ei sallita. + + + + + + + + + + 256 + {{49, -16}, {363, 17}} + + YES + + 67239424 + 4194304 + Nämä valinnat tulevat voimaan, kun X11 avataan seuraavan kerran. + + + + + + + + + {{10, 33}, {584, 261}} + + Suojaus + + + + + + + 0 + YES + YES + + + + + + {625, 323} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {469, 271}} + 1350041600 + X11-ohjelmavalikko + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {450, 240} + + + 256 + + + + 265 + {{340, 191}, {115, 32}} + + + YES + + 67239424 + 137887744 + Monista + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {115, 32}} + + + YES + + 67239424 + 137887744 + Poista + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + + YES + + + 256 + {301, 17} + + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + + 121.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Nimi + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 99 + 40 + 1000 + + 75628096 + 2048 + Komento + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + 71 + 10 + 1000 + + 75628096 + 2048 + Oikotie + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + + + {{1, 17}, {301, 198}} + + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + + 50 + + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {115, 32}} + + + YES + + -2080244224 + 137887744 + Lisää kohde + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {469, 271} + + + + {{0, 0}, {1280, 938}} + {450, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Valikko + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Ohjelmat + + 1048576 + 2147483647 + + + submenuAction: + + Ohjelmat + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Muokkaa… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 533}, {625, 323}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{507, 533}, {625, 323}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {469, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {469, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {450, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/keyedobjects.nib index da8c1acf8..3aa05c19a 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/fi.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/locversion.plist index b4b4b6286..fe42fb24c 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - ko - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + ko + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/designable.nib index ddbc67935..3a0f69d9f 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/designable.nib @@ -1,3583 +1,3758 @@ - - - - 1040 - 11A79a - 732 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 732 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - X11ì— ê´€í•˜ì—¬ - - 2147483647 - - - - - - 환경설정... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 서비스 - - 1048576 - 2147483647 - - - submenuAction: - - 서비스 - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ì „ì²´ 화면 토글 - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - X11 가리기 - h - 1048576 - 2147483647 - - - 42 - - - - 기타 가리기 - h - 1572864 - 2147483647 - - - - - - ëª¨ë‘ ë³´ê¸° - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - X11 종료 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - ì‘ìš© 프로그램 - - 1048576 - 2147483647 - - - submenuAction: - - ì‘ìš© 프로그램 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 사용ìží™”... - - 1048576 - 2147483647 - - - - - - - - - 편집 - - 1048576 - 2147483647 - - - submenuAction: - - 편집 - - - - 복사하기 - c - 1048576 - 2147483647 - - - - - - - - - 윈ë„ìš° - - 1048576 - 2147483647 - - - submenuAction: - - 윈ë„ìš° - - - - 닫기 - w - 1048576 - 2147483647 - - - - - - 윈ë„ìš° 축소 - m - 1048576 - 2147483647 - - - - - - 확대/축소 - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 윈ë„ìš° 순환 - ` - 1048840 - 2147483647 - - - - - - 윈ë„ìš° 역순환 - ~ - 1179914 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ëª¨ë‘ ì•žìœ¼ë¡œ 가져오기 - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - ë„ì›€ë§ - - 1048576 - 2147483647 - - - submenuAction: - - ë„ì›€ë§ - - - - X11 ë„ì›€ë§ - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 364}, {484, 308}} - 1350041600 - X11 환경설정 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - 3중 í´ë¦­ 마우스 ì—뮬레ì´íŠ¸ - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 63}, {383, 28}} - - YES - - 67239424 - 4194304 - 활성화ë˜ë©´, 메뉴 막대와 ë™ë“±í•œ 키가 메타 ì¡°í•©ì„ ì‚¬ìš©í•˜ëŠ” X11 ì‘ìš© í”„ë¡œê·¸ëž¨ì„ ë°©í•´í•  수 있습니다. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 162}, {385, 42}} - - YES - - 67239424 - 4194304 - 66eI7Jqw7IqkIOykkeqwhCDrmJDripQg7Jik66W47Kq9IOuyhO2KvOydhCDtmZzshLHtmZTtlZjroKTr -qbQsIO2BtOumre2VmOuKlCDrj5nslYggT3B0aW9uIOuYkOuKlCBDb21tYW5kIO2CpOulvCDtlajqu5gg -64iE66W06rOgIOyeiOycvOyLreyLnOyYpC4KA - - - - - - - - - - 256 - {{18, 97}, {402, 18}} - - YES - - 67239424 - 0 - X11ì˜ ë™ë“±í•œ 키 활성화 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 126}, {385, 14}} - - YES - - 67239424 - 4194304 - ìž…ë ¥ 메뉴 ë³€ê²½ì‚¬í•­ì´ í˜„ìž¬ X11 í‚¤ë§µì„ ë®ì–´ì“°ë„ë¡ í—ˆìš©í•©ë‹ˆë‹¤. - - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 0 - 시스템 키보드 ë ˆì´ì•„웃 따르기 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - 활성화하면, Option 키는 Mode_switch ëŒ€ì‹ ì— Alt_L ë° Alt_R X11 키 기호를 보냅니다. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 0 - Option 키로 Alt_L ë° Alt_R 보내기 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - ìž…ë ¥ - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - 시스템 경고 효과 사용 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {379, 28}} - - YES - - 67239424 - 4194304 - X11 경고ìŒì€ 사운드 효과 시스템 환경설정 패ë„ì—ì„œ ì •ì˜ëœ 표준 시스템 경고를 사용합니다. - - - - - - - - - - 256 - {{58, 202}, {129, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - 모니터ì—ì„œ - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 ìƒ‰ìƒ - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - 수만 ìƒ‰ìƒ - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - 수백만 ìƒ‰ìƒ - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {39, 20}} - - YES - - 67239424 - 4194304 - 색ìƒ: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - ì´ ì˜µì…˜ì€ X11ì„ ë‹¤ì‹œ 실행하면 ì ìš©ë©ë‹ˆë‹¤. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - ì „ì²´ 화면 모드 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {409, 23}} - - YES - - 67239424 - 0 - 메뉴 막대를 ì „ì²´ 화면 모드로 ìžë™ 보기 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 112}, {357, 28}} - - YES - - 67239424 - 4194304 - X11 루트 윈ë„우를 활성화합니다. ì „ì²´ 화면 모드로 ë‘거나 전환하려면 Command-Option-A 키를 사용하십시오. - - - - - - - - - {{10, 33}, {438, 246}} - - 출력 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - ë™ê¸°í™” 활성화 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {385, 28}} - - YES - - 67239424 - 4194304 - "복사하기" 메뉴 í•­ëª©ì„ í™œì„±í™”í•˜ê³  OSX 붙ì´ê¸° ë³´ë“œ, X11 í´ë¦½ë³´ë“œ ë° PRIMARY ë²„í¼ ê°„ì˜ ë™ê¸°í™”를 허용합니다. - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - 붙ì´ê¸° 보드가 변경ë˜ë©´ CLIPBOARD ì—…ë°ì´íŠ¸ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {409, 23}} - - YES - - 67239424 - 0 - 붙ì´ê¸° 보드가 변경ë˜ë©´ PRIMARY(중간 í´ë¦­) ì—…ë°ì´íŠ¸ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 46}, {409, 23}} - - YES - - 67239424 - 0 - 새로운 í…스트가 ì„ íƒë˜ë©´ 바로 붙ì´ê¸° ë³´ë“œ ì—…ë°ì´íŠ¸ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - CLIPBOARDê°€ 변경ë˜ë©´ 붙ì´ê¸° ë³´ë“œ ì—…ë°ì´íŠ¸ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {385, 28}} - - YES - - 67239424 - 4194304 - xclipboard, klipper ë˜ëŠ” 기타 다른 X11 í´ë¦½ë³´ë“œ 관리ìžë¥¼ 사용하려면 ì´ ì˜µì…˜ì„ ë¹„í™œì„±í™”í•˜ì‹­ì‹œì˜¤. - - - - - - - - - 256 - {{48, 14}, {370, 28}} - - YES - - 67239424 - 4194304 - X11 프로토콜 제한 ë•Œë¬¸ì— ì´ ì˜µì…˜ì€ ì¼ë¶€ ì‘ìš© 프로그램ì—ì„œ í•­ìƒ ìž‘ë™í•˜ì§€ ì•Šì„ ìˆ˜ë„ ìžˆìŠµë‹ˆë‹¤. - - - - - - - - {{10, 33}, {438, 246}} - - 붙ì´ê¸° ë³´ë“œ - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - 비활성 윈ë„ìš° í´ë¦­ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {385, 31}} - - YES - - 67239424 - 4194304 - 활성화ë˜ì—ˆì„ ë•Œ 비활성 윈ë„우를 í´ë¦­í•˜ë©´ 마우스 í´ë¦­ì´ 비활성 윈ë„ìš°ë¡œ í†µê³¼ë  ë¿ë§Œ ì•„ë‹ˆë¼ ë¹„í™œì„± 윈ë„ìš°ê°€ 활성화ë©ë‹ˆë‹¤. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - 마우스를 ë”°ë¼ ì´ˆì  ì´ë™ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 117}, {415, 28}} - - YES - - 67239424 - 4194304 - X11 윈ë„ìš° ì´ˆì ì€ 해당 커서를 따릅니다. ì´ê²ƒì€ ì¼ë¶€ ì—­ê¸°ëŠ¥ì„ ê°€ì§€ê³  있습니다. - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - 새로운 윈ë„ìš°ì— ì´ˆì  ë‘기 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 73}, {385, 28}} - - YES - - 67239424 - 4194304 - 활성화ë˜ì—ˆì„ ë•Œ 새로운 X11 윈ë„우를 ìƒì„±í•˜ë©´ (Finder.app ë° í„°ë¯¸ë„.app 등 대신) X11.appì´ ë§¨ 앞으로 ì´ë™ë©ë‹ˆë‹¤. - - - - - - - - {{10, 33}, {438, 246}} - - 윈ë„ìš° - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - ì—°ê²° ì¸ì¦ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - ë„¤íŠ¸ì›Œí¬ í´ë¼ì´ì–¸íŠ¸ì—ì„œì˜ ì—°ê²°ì„ í—ˆìš© - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {385, 42}} - - YES - - 67239424 - 4194304 - X11ì„ ì‹¤í–‰í•˜ë©´ Xauthority ì—°ê²° 제어 키를 ìƒì„±í•©ë‹ˆë‹¤. ì‹œìŠ¤í…œì˜ IP 주소를 변경하면, ì´ í‚¤ë“¤ì´ ìœ íš¨í•˜ì§€ 않게 ë˜ì–´ X11 ì‘ìš© í”„ë¡œê·¸ëž¨ì´ ì‹¤í–‰ë˜ì§€ ì•Šì„ ìˆ˜ 있습니다. - - - - - - - - - - 256 - {{36, 99}, {380, 28}} - - YES - - 67239424 - 4194304 - 활성화ë˜ë©´, 시스템 ë³´ì•ˆì„ í™•ì¸í•˜ê¸° 위해 ì—°ê²° ì¸ì¦ë„ 활성화ë˜ì–´ì•¼ 합니다. 비활성화ë˜ë©´, ì›ê²© ì‘ìš© 프로그램 ì—°ê²°ì´ í—ˆìš©ë˜ì§€ 않습니다. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - ì´ë“¤ ì˜µì…˜ì€ X11ì„ ë‹¤ìŒì— 실행하면 ì ìš©ë©ë‹ˆë‹¤. - - - - - - - - - {{10, 33}, {438, 246}} - - 보안 - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {454, 271}} - 1350041600 - X11 ì‘ìš© 프로그램 메뉴 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {100, 32}} - - YES - - 67239424 - 137887744 - 복제 - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {100, 32}} - - YES - - 67239424 - 137887744 - 제거 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 121.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - ì´ë¦„ - - - 3 - MC4zMzMzMzI5OQA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 99 - 40 - 1000 - - 75628096 - 2048 - 명령 - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - 71 - 10 - 1000 - - 75628096 - 2048 - 단축키 - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492380000000002 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460000000004 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {100, 32}} - - YES - - -2080244224 - 137887744 - 항목 추가 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - 메뉴 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ì‘ìš© 프로그램 - - 1048576 - 2147483647 - - - submenuAction: - - ì‘ìš© 프로그램 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 사용ìží™”… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 565}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 565}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + X11ì— ê´€í•˜ì—¬ + + 2147483647 + + + + + + 환경설정... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 서비스 + + 1048576 + 2147483647 + + + submenuAction: + + 서비스 + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ì „ì²´ 화면 토글 + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + X11 가리기 + h + 1048576 + 2147483647 + + + 42 + + + + 기타 가리기 + h + 1572864 + 2147483647 + + + + + + ëª¨ë‘ ë³´ê¸° + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + X11 종료 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + ì‘ìš© 프로그램 + + 1048576 + 2147483647 + + + submenuAction: + + ì‘ìš© 프로그램 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 사용ìží™”... + + 1048576 + 2147483647 + + + + + + + + + 편집 + + 1048576 + 2147483647 + + + submenuAction: + + 편집 + + + + 복사하기 + c + 1048576 + 2147483647 + + + + + + + + + 윈ë„ìš° + + 1048576 + 2147483647 + + + submenuAction: + + 윈ë„ìš° + + + + 닫기 + w + 1048576 + 2147483647 + + + + + + 윈ë„ìš° 축소 + m + 1048576 + 2147483647 + + + + + + 확대/축소 + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 윈ë„ìš° 순환 + ` + 1048840 + 2147483647 + + + + + + 윈ë„ìš° 역순환 + ~ + 1179914 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ëª¨ë‘ ì•žìœ¼ë¡œ 가져오기 + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + ë„ì›€ë§ + + 1048576 + 2147483647 + + + submenuAction: + + ë„ì›€ë§ + + + + X11 ë„ì›€ë§ + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 364}, {484, 308}} + 1350041600 + X11 환경설정 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + 3중 í´ë¦­ 마우스 ì—뮬레ì´íŠ¸ + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 63}, {383, 28}} + + YES + + 67239424 + 4194304 + 활성화ë˜ë©´, 메뉴 막대와 ë™ë“±í•œ 키가 메타 ì¡°í•©ì„ ì‚¬ìš©í•˜ëŠ” X11 ì‘ìš© í”„ë¡œê·¸ëž¨ì„ ë°©í•´í•  수 있습니다. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + 66eI7Jqw7IqkIOykkeqwhCDrmJDripQg7Jik66W47Kq9IOuyhO2KvOydhCDtmZzshLHtmZTtlZjroKTr +qbQsIO2BtOumre2VmOuKlCDrj5nslYggT3B0aW9uIOuYkOuKlCBDb21tYW5kIO2CpOulvCDtlajqu5gg +64iE66W06rOgIOyeiOycvOyLreyLnOyYpC4KA + + + + + + + + + + 256 + {{18, 97}, {402, 18}} + + YES + + 67239424 + 0 + X11ì˜ ë™ë“±í•œ 키 활성화 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 126}, {385, 14}} + + YES + + 67239424 + 4194304 + ìž…ë ¥ 메뉴 ë³€ê²½ì‚¬í•­ì´ í˜„ìž¬ X11 í‚¤ë§µì„ ë®ì–´ì“°ë„ë¡ í—ˆìš©í•©ë‹ˆë‹¤. + + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 0 + 시스템 키보드 ë ˆì´ì•„웃 따르기 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + 활성화하면, Option 키는 Mode_switch ëŒ€ì‹ ì— Alt_L ë° Alt_R X11 키 기호를 보냅니다. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Option 키로 Alt_L ë° Alt_R 보내기 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + ìž…ë ¥ + + + + + + 2 + + + + 256 + + + + 256 + {{58, 202}, {129, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + 모니터ì—ì„œ + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 ìƒ‰ìƒ + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + 수만 ìƒ‰ìƒ + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + 수백만 ìƒ‰ìƒ + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {39, 20}} + + YES + + 67239424 + 4194304 + 색ìƒ: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + ì´ ì˜µì…˜ì€ X11ì„ ë‹¤ì‹œ 실행하면 ì ìš©ë©ë‹ˆë‹¤. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + ì „ì²´ 화면 모드 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {409, 23}} + + YES + + 67239424 + 0 + 메뉴 막대를 ì „ì²´ 화면 모드로 ìžë™ 보기 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 112}, {357, 28}} + + YES + + 67239424 + 4194304 + X11 루트 윈ë„우를 활성화합니다. ì „ì²´ 화면 모드로 ë‘거나 전환하려면 Command-Option-A 키를 사용하십시오. + + + + + + + + + {{10, 33}, {438, 246}} + + + 출력 + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + ë™ê¸°í™” 활성화 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {385, 28}} + + YES + + 67239424 + 4194304 + "복사하기" 메뉴 í•­ëª©ì„ í™œì„±í™”í•˜ê³  OSX 붙ì´ê¸° ë³´ë“œ, X11 í´ë¦½ë³´ë“œ ë° PRIMARY ë²„í¼ ê°„ì˜ ë™ê¸°í™”를 허용합니다. + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + 붙ì´ê¸° 보드가 변경ë˜ë©´ CLIPBOARD ì—…ë°ì´íŠ¸ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {409, 23}} + + YES + + 67239424 + 0 + 붙ì´ê¸° 보드가 변경ë˜ë©´ PRIMARY(중간 í´ë¦­) ì—…ë°ì´íŠ¸ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 46}, {409, 23}} + + YES + + 67239424 + 0 + 새로운 í…스트가 ì„ íƒë˜ë©´ 바로 붙ì´ê¸° ë³´ë“œ ì—…ë°ì´íŠ¸ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + CLIPBOARDê°€ 변경ë˜ë©´ 붙ì´ê¸° ë³´ë“œ ì—…ë°ì´íŠ¸ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {385, 28}} + + YES + + 67239424 + 4194304 + xclipboard, klipper ë˜ëŠ” 기타 다른 X11 í´ë¦½ë³´ë“œ 관리ìžë¥¼ 사용하려면 ì´ ì˜µì…˜ì„ ë¹„í™œì„±í™”í•˜ì‹­ì‹œì˜¤. + + + + + + + + + 256 + {{48, 14}, {370, 28}} + + YES + + 67239424 + 4194304 + X11 프로토콜 제한 ë•Œë¬¸ì— ì´ ì˜µì…˜ì€ ì¼ë¶€ ì‘ìš© 프로그램ì—ì„œ í•­ìƒ ìž‘ë™í•˜ì§€ ì•Šì„ ìˆ˜ë„ ìžˆìŠµë‹ˆë‹¤. + + + + + + + + {{10, 33}, {438, 246}} + + 붙ì´ê¸° ë³´ë“œ + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + 비활성 윈ë„ìš° í´ë¦­ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {385, 31}} + + YES + + 67239424 + 4194304 + 활성화ë˜ì—ˆì„ ë•Œ 비활성 윈ë„우를 í´ë¦­í•˜ë©´ 마우스 í´ë¦­ì´ 비활성 윈ë„ìš°ë¡œ í†µê³¼ë  ë¿ë§Œ ì•„ë‹ˆë¼ ë¹„í™œì„± 윈ë„ìš°ê°€ 활성화ë©ë‹ˆë‹¤. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + 마우스를 ë”°ë¼ ì´ˆì  ì´ë™ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 117}, {415, 28}} + + YES + + 67239424 + 4194304 + X11 윈ë„ìš° ì´ˆì ì€ 해당 커서를 따릅니다. ì´ê²ƒì€ ì¼ë¶€ ì—­ê¸°ëŠ¥ì„ ê°€ì§€ê³  있습니다. + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + 새로운 윈ë„ìš°ì— ì´ˆì  ë‘기 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 73}, {385, 28}} + + YES + + 67239424 + 4194304 + 활성화ë˜ì—ˆì„ ë•Œ 새로운 X11 윈ë„우를 ìƒì„±í•˜ë©´ (Finder.app ë° í„°ë¯¸ë„.app 등 대신) X11.appì´ ë§¨ 앞으로 ì´ë™ë©ë‹ˆë‹¤. + + + + + + + + {{10, 33}, {438, 246}} + + 윈ë„ìš° + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + ì—°ê²° ì¸ì¦ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + ë„¤íŠ¸ì›Œí¬ í´ë¼ì´ì–¸íŠ¸ì—ì„œì˜ ì—°ê²°ì„ í—ˆìš© + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + X11ì„ ì‹¤í–‰í•˜ë©´ Xauthority ì—°ê²° 제어 키를 ìƒì„±í•©ë‹ˆë‹¤. ì‹œìŠ¤í…œì˜ IP 주소를 변경하면, ì´ í‚¤ë“¤ì´ ìœ íš¨í•˜ì§€ 않게 ë˜ì–´ X11 ì‘ìš© í”„ë¡œê·¸ëž¨ì´ ì‹¤í–‰ë˜ì§€ ì•Šì„ ìˆ˜ 있습니다. + + + + + + + + + + 256 + {{36, 99}, {380, 28}} + + YES + + 67239424 + 4194304 + 활성화ë˜ë©´, 시스템 ë³´ì•ˆì„ í™•ì¸í•˜ê¸° 위해 ì—°ê²° ì¸ì¦ë„ 활성화ë˜ì–´ì•¼ 합니다. 비활성화ë˜ë©´, ì›ê²© ì‘ìš© 프로그램 ì—°ê²°ì´ í—ˆìš©ë˜ì§€ 않습니다. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + ì´ë“¤ ì˜µì…˜ì€ X11ì„ ë‹¤ìŒì— 실행하면 ì ìš©ë©ë‹ˆë‹¤. + + + + + + + + + {{10, 33}, {438, 246}} + + 보안 + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {454, 271}} + 1350041600 + X11 ì‘ìš© 프로그램 메뉴 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {100, 32}} + + YES + + 67239424 + 137887744 + 복제 + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {100, 32}} + + YES + + 67239424 + 137887744 + 제거 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 121.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + ì´ë¦„ + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 99 + 40 + 1000 + + 75628096 + 2048 + 명령 + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + 71 + 10 + 1000 + + 75628096 + 2048 + 단축키 + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {100, 32}} + + YES + + -2080244224 + 137887744 + 항목 추가 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + 메뉴 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ì‘ìš© 프로그램 + + 1048576 + 2147483647 + + + submenuAction: + + ì‘ìš© 프로그램 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 사용ìží™”… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/keyedobjects.nib index f61614314..e7fd919ef 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/ko.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/no.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/no.lproj/locversion.plist index a001c8bf9..0a1e68a7c 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/no.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/no.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - no - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + no + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/designable.nib index 89e2f9c76..305f02a4a 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/designable.nib @@ -1,3604 +1,3758 @@ - - - - 1040 - 11A79a - 784 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 784 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Om X11 - - 2147483647 - - - - - - Valg... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tjenester - - 1048576 - 2147483647 - - - submenuAction: - - Tjenester - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - SlÃ¥ fullskjermmodus pÃ¥/av - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Skjul X11 - h - 1048576 - 2147483647 - - - 42 - - - - Skjul andre - h - 1572864 - 2147483647 - - - - - - Vis alle - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Avslutt X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Programmer - - 1048576 - 2147483647 - - - submenuAction: - - Programmer - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tilpass... - - 1048576 - 2147483647 - - - - - - - - - Rediger - - 1048576 - 2147483647 - - - submenuAction: - - Rediger - - - - Kopier - c - 1048576 - 2147483647 - - - - - - - - - Vindu - - 1048576 - 2147483647 - - - submenuAction: - - Vindu - - - - Lukk - w - 1048576 - 2147483647 - - - - - - Minimer - m - 1048576 - 2147483647 - - - - - - Zoom - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Bla gjennom vinduer - < - 1048576 - 2147483647 - - - - - - Bla baklengs gjennom vinduer - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Legg alle øverst - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Hjelp - - 1048576 - 2147483647 - - - submenuAction: - - Hjelp - - - - X11-hjelp - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 364}, {484, 308}} - 1350041600 - X11-valg - NSPanel - - View - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - - YES - - 67239424 - 0 - Emuler mus med tre knapper - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 60}, {385, 28}} - - - YES - - 67239424 - 4194304 - NÃ¥r aktivert, kan tastaturkommandoer for menylinjen komme i konflikt med X11-programmer som bruker metatasten. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2ODY1AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 162}, {385, 42}} - - - YES - - 67239424 - 4194304 - SG9sZCBuZWRlIFRpbHZhbGctIGVsbGVyIEtvbW1hbmRvLXRhc3RlbiBtZW5zIGR1IGtsaWtrZXIgZm9y -IMOlIGFrdGl2ZXJlIGRlbiBtaWR0cmUgZWxsZXIgaMO4eXJlIG11c2VrbmFwcGVuLgo - - - - - - - - - - 256 - {{18, 94}, {402, 18}} - - - YES - - 67239424 - 0 - Aktiver tastaturkommandoer i X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 118}, {385, 28}} - - - YES - - 67239424 - 4194304 - Gir deg mulighet til Ã¥ legge inn menyendringer som overskriver den nÃ¥værende X11-tastaturlayouten. - - - - - - - - - - 256 - {{18, 152}, {402, 18}} - - - YES - - 67239424 - 0 - Følg systemets tastaturlayout - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - - YES - - 67239424 - 4194304 - NÃ¥r dette er aktivert, sender Tilvalg-tastene Alt_L og Alt_R X11-nøkkelsymboler i stedet for Mode_switch. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - - YES - - 67239424 - 0 - Tilvalg-tastene sender Alt_L og Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - - Inndata - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - Bruk systemvarseleffekt - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {375, 28}} - - YES - - 67239424 - 4194304 - X11-lyder vil bruke lyden for et vanlig systemvarsel slik denne lyden er definert i Lydeffekter-valgpanelet. - - - - - - - - - - 256 - {{68, 202}, {134, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Fra skjerm - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 farger - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Tusener - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Millioner - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 208}, {49, 17}} - - YES - - 67239424 - 4194304 - Farger: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Denne innstillingen trer i kraft neste gang X11 startes. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - Fullskjermmodus - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {373, 23}} - - YES - - 67239424 - 0 - Vis menylinjen automatisk i fullskjermmodus - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 115}, {375, 28}} - - YES - - 67239424 - 4194304 - Aktiverer X11-rotvinduet. SlÃ¥ fullskjermmodus pÃ¥ og av ved Ã¥ trykke pÃ¥ Kommando-Tilvalg-A samtidig. - - - - - - - - - {{10, 33}, {438, 246}} - - Utdata - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - Aktiver synkronisering - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {385, 28}} - - YES - - 67239424 - 4194304 - Aktiverer «kopier»-menyobjektet og gjør det mulig Ã¥ synkronisere mellom bufrene i OSX Pasteboard, X11 CLIPBOARD og PRIMARY. - - - - - - - - - 256 - {{34, 96}, {383, 23}} - - YES - - 67239424 - 0 - Oppdater CLIPBOARD nÃ¥r Utklipp endres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {383, 23}} - - YES - - 67239424 - 0 - Oppdater PRIMARY (midtklikk) nÃ¥r Utklipp endres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 46}, {383, 23}} - - YES - - 67239424 - 0 - Oppdater Utklipp umiddelbart nÃ¥r ny tekst markeres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {383, 23}} - - YES - - 67239424 - 0 - Oppdater Utklipp nÃ¥r CLIPBOARD endres - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {370, 28}} - - YES - - 67239424 - 4194304 - Deaktiver dette valget hvis du vil bruke xclipboard, klipper eller andre X11-utklippshÃ¥ndterere. - - - - - - - - - 256 - {{48, 14}, {370, 28}} - - YES - - 67239424 - 4194304 - PÃ¥ grunn av begrensninger i X11-protokollen, er det mulig at dette valget ikke fungerer i alle programmer. - - - - - - - - {{10, 33}, {438, 246}} - - Utklipp - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Registrer klikk i inaktive vinduer - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {385, 31}} - - YES - - 67239424 - 4194304 - NÃ¥r denne funksjonen er aktivert, registreres museklikk i inaktive vinduer nÃ¥r du klikker i dem, i tillegg til at vinduene aktiveres. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Fokus følger musen - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 128}, {385, 17}} - - YES - - 67239424 - 4194304 - X11-vindufokus følger markøren. Kan være upraktisk i bruk. - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - Fokuser pÃ¥ nye vinduer - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 73}, {385, 28}} - - YES - - 67239424 - 4194304 - NÃ¥r denne funksjonen er aktivert, legges X11.app øverst (i stedet for Finder.app, Terminal.app osv.) nÃ¥r du oppretter et nytt X11-vindu. - - - - - - - - {{10, 33}, {438, 246}} - - Vinduer - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Godkjenn tilkoblinger - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - Tillat tilkoblinger fra nettverksklienter - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {383, 42}} - - YES - - 67239424 - 4194304 - NÃ¥r du starter X11, opprettes det Xauthority-tilgangskontrolltaster. Hvis maskinens IP-adresse endres, kan ikke disse tastene brukes, noe som kan hindre X11-programmer fra Ã¥ starte. - - - - - - - - - - 256 - {{36, 85}, {364, 42}} - - YES - - 67239424 - 4194304 - Hvis dette er aktivert, mÃ¥ du for Ã¥ sikre systemet, ogsÃ¥ aktivere Godkjenn tilkoblinger. NÃ¥r dette ikke er aktivert, er tilkoblinger fra eksterne programmer ikke tillatt. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Disse innstillingene trer i kraft neste gang X11 startes. - - - - - - - - - {{10, 33}, {438, 246}} - - Sikkerhet - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - - - {{0, 0}, {1280, 938}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_prefs - - - 11 - 2 - {{302, 440}, {485, 271}} - 1350041600 - X11-programmeny - NSPanel - - View - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {131, 32}} - - YES - - 67239424 - 137887744 - Dupliser - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {131, 32}} - - YES - - 67239424 - 137887744 - Fjern - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 121.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Navn - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Tekstrute - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 99 - 40 - 1000 - - 75628096 - 2048 - Kommando - - - - - - 338820672 - 1024 - Tekstrute - - - - - - - 3 - YES - YES - - - - 71 - 10 - 1000 - - 75628096 - 2048 - Snarvei - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Tekstrute - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {131, 32}} - - YES - - -2080244224 - 137887744 - Legg til objekt - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {485, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_apps - - - Meny - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Programmer - - 1048576 - 2147483647 - - - submenuAction: - - Programmer - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tilpass… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 548}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {485, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {485, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Om X11 + + 2147483647 + + + + + + Valg... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tjenester + + 1048576 + 2147483647 + + + submenuAction: + + Tjenester + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + SlÃ¥ fullskjermmodus pÃ¥/av + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Skjul X11 + h + 1048576 + 2147483647 + + + 42 + + + + Skjul andre + h + 1572864 + 2147483647 + + + + + + Vis alle + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Avslutt X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Programmer + + 1048576 + 2147483647 + + + submenuAction: + + Programmer + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tilpass... + + 1048576 + 2147483647 + + + + + + + + + Rediger + + 1048576 + 2147483647 + + + submenuAction: + + Rediger + + + + Kopier + c + 1048576 + 2147483647 + + + + + + + + + Vindu + + 1048576 + 2147483647 + + + submenuAction: + + Vindu + + + + Lukk + w + 1048576 + 2147483647 + + + + + + Minimer + m + 1048576 + 2147483647 + + + + + + Zoom + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Bla gjennom vinduer + < + 1048576 + 2147483647 + + + + + + Bla baklengs gjennom vinduer + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Legg alle øverst + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Hjelp + + 1048576 + 2147483647 + + + submenuAction: + + Hjelp + + + + X11-hjelp + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 364}, {484, 308}} + 1350041600 + X11-valg + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Emuler mus med tre knapper + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 60}, {385, 28}} + + YES + + 67239424 + 4194304 + NÃ¥r aktivert, kan tastaturkommandoer for menylinjen komme i konflikt med X11-programmer som bruker metatasten. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + SG9sZCBuZWRlIFRpbHZhbGctIGVsbGVyIEtvbW1hbmRvLXRhc3RlbiBtZW5zIGR1IGtsaWtrZXIgZm9y +IMOlIGFrdGl2ZXJlIGRlbiBtaWR0cmUgZWxsZXIgaMO4eXJlIG11c2VrbmFwcGVuLgo + + + + + + + + + + 256 + {{18, 94}, {402, 18}} + + YES + + 67239424 + 0 + Aktiver tastaturkommandoer i X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 118}, {385, 28}} + + YES + + 67239424 + 4194304 + Gir deg mulighet til Ã¥ legge inn menyendringer som overskriver den nÃ¥værende X11-tastaturlayouten. + + + + + + + + + + 256 + {{18, 152}, {402, 18}} + + YES + + 67239424 + 0 + Følg systemets tastaturlayout + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + NÃ¥r dette er aktivert, sender Tilvalg-tastene Alt_L og Alt_R X11-nøkkelsymboler i stedet for Mode_switch. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Tilvalg-tastene sender Alt_L og Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + Inndata + + + + + + 2 + + + + 256 + + + + 256 + {{68, 202}, {134, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Fra skjerm + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 farger + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Tusener + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Millioner + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 208}, {49, 17}} + + YES + + 67239424 + 4194304 + Farger: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Denne innstillingen trer i kraft neste gang X11 startes. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + Fullskjermmodus + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {373, 23}} + + YES + + 67239424 + 0 + Vis menylinjen automatisk i fullskjermmodus + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 115}, {375, 28}} + + YES + + 67239424 + 4194304 + Aktiverer X11-rotvinduet. SlÃ¥ fullskjermmodus pÃ¥ og av ved Ã¥ trykke pÃ¥ Kommando-Tilvalg-A samtidig. + + + + + + + + + {{10, 33}, {438, 246}} + + + Utdata + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + Aktiver synkronisering + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {385, 28}} + + YES + + 67239424 + 4194304 + Aktiverer «kopier»-menyobjektet og gjør det mulig Ã¥ synkronisere mellom bufrene i OSX Pasteboard, X11 CLIPBOARD og PRIMARY. + + + + + + + + + 256 + {{34, 96}, {383, 23}} + + YES + + 67239424 + 0 + Oppdater CLIPBOARD nÃ¥r Utklipp endres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {383, 23}} + + YES + + 67239424 + 0 + Oppdater PRIMARY (midtklikk) nÃ¥r Utklipp endres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 46}, {383, 23}} + + YES + + 67239424 + 0 + Oppdater Utklipp umiddelbart nÃ¥r ny tekst markeres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {383, 23}} + + YES + + 67239424 + 0 + Oppdater Utklipp nÃ¥r CLIPBOARD endres + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {370, 28}} + + YES + + 67239424 + 4194304 + Deaktiver dette valget hvis du vil bruke xclipboard, klipper eller andre X11-utklippshÃ¥ndterere. + + + + + + + + + 256 + {{48, 14}, {370, 28}} + + YES + + 67239424 + 4194304 + PÃ¥ grunn av begrensninger i X11-protokollen, er det mulig at dette valget ikke fungerer i alle programmer. + + + + + + + + {{10, 33}, {438, 246}} + + Utklipp + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Registrer klikk i inaktive vinduer + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {385, 31}} + + YES + + 67239424 + 4194304 + NÃ¥r denne funksjonen er aktivert, registreres museklikk i inaktive vinduer nÃ¥r du klikker i dem, i tillegg til at vinduene aktiveres. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Fokus følger musen + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 128}, {385, 17}} + + YES + + 67239424 + 4194304 + X11-vindufokus følger markøren. Kan være upraktisk i bruk. + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + Fokuser pÃ¥ nye vinduer + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 73}, {385, 28}} + + YES + + 67239424 + 4194304 + NÃ¥r denne funksjonen er aktivert, legges X11.app øverst (i stedet for Finder.app, Terminal.app osv.) nÃ¥r du oppretter et nytt X11-vindu. + + + + + + + + {{10, 33}, {438, 246}} + + Vinduer + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Godkjenn tilkoblinger + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + Tillat tilkoblinger fra nettverksklienter + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {383, 42}} + + YES + + 67239424 + 4194304 + NÃ¥r du starter X11, opprettes det Xauthority-tilgangskontrolltaster. Hvis maskinens IP-adresse endres, kan ikke disse tastene brukes, noe som kan hindre X11-programmer fra Ã¥ starte. + + + + + + + + + + 256 + {{36, 85}, {364, 42}} + + YES + + 67239424 + 4194304 + Hvis dette er aktivert, mÃ¥ du for Ã¥ sikre systemet, ogsÃ¥ aktivere Godkjenn tilkoblinger. NÃ¥r dette ikke er aktivert, er tilkoblinger fra eksterne programmer ikke tillatt. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Disse innstillingene trer i kraft neste gang X11 startes. + + + + + + + + + {{10, 33}, {438, 246}} + + Sikkerhet + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {485, 271}} + 1350041600 + X11-programmeny + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {131, 32}} + + YES + + 67239424 + 137887744 + Dupliser + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {131, 32}} + + YES + + 67239424 + 137887744 + Fjern + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 121.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Navn + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Tekstrute + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 99 + 40 + 1000 + + 75628096 + 2048 + Kommando + + + + + + 338820672 + 1024 + Tekstrute + + + + + + + 3 + YES + YES + + + + 71 + 10 + 1000 + + 75628096 + 2048 + Snarvei + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Tekstrute + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {131, 32}} + + YES + + -2080244224 + 137887744 + Legg til objekt + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {485, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Meny + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Programmer + + 1048576 + 2147483647 + + + submenuAction: + + Programmer + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tilpass… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/keyedobjects.nib index a287eabf8..87a12b611 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/no.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/locversion.plist index 64befbabd..be85c462a 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 100 - LprojLocale - pl - LprojRevisionLevel - 1 - LprojVersion - 100 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + pl + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/designable.nib index 082a39e19..1c6c8bbdf 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/designable.nib @@ -1,3601 +1,3763 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - X11… - - 2147483647 - - - - - - Preferencje… - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - UsÅ‚ugi - - 1048576 - 2147483647 - - - submenuAction: - - UsÅ‚ugi - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - PrzeÅ‚Ä…czaj peÅ‚ny ekran - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Ukryj X11 - h - 1048576 - 2147483647 - - - 42 - - - - Ukryj pozostaÅ‚e - h - 1572864 - 2147483647 - - - - - - Pokaż wszystkie - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ZakoÅ„cz X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Programy - - 1048576 - 2147483647 - - - submenuAction: - - Programy - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Dostosuj… - - 1048576 - 2147483647 - - - - - - - - - Edycja - - 1048576 - 2147483647 - - - submenuAction: - - Edycja - - - - Kopiuj - c - 1048576 - 2147483647 - - - - - - - - - Okno - - 1048576 - 2147483647 - - - submenuAction: - - Okno - - - - Zamknij - w - 1048576 - 2147483647 - - - - - - Minimalizuj okno - m - 1048576 - 2147483647 - - - - - - Zoom - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - PrzeÅ‚Ä…czaj miÄ™dzy oknami - ` - 1048576 - 2147483647 - - - - - - PrzeÅ‚Ä…czaj wstecz pomiÄ™dzy oknami - ` - 1179648 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Umieść wszystko na wierzchu - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Pomoc - - 1048576 - 2147483647 - - - submenuAction: - - Pomoc - - - - Pomoc X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{288, 302}, {584, 308}} - 1350041600 - Preferencje X11 - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {558, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{68, 210}, {402, 18}} - - YES - - 67239424 - 0 - Emuluj mysz z trzema przyciskami - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{86, 58}, {385, 31}} - - YES - - 67239424 - 4194304 - Równoważniki klawiszowe paska menu bÄ™dÄ… mogÅ‚y kolidować z programami X11 używajÄ…cymi modyfikatora Meta. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{86, 170}, {374, 34}} - - YES - - 67239424 - 4194304 - S2xpa25pxJljaWUgeiBwcnp5dHJ6eW1hbnltIGtsYXdpc3plbSBPcGNqYSBsdWIgQ29tbWFuZCBlbXVs -dWplIMWbcm9ka293eSBsdWIgcHJhd3kgcHJ6eWNpc2sgbXlzenkuCg - - - - - - - - - - 256 - {{68, 92}, {402, 18}} - - YES - - 67239424 - 0 - WÅ‚Ä…cz równoważniki klawiszowe w Å›rodowisku X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{86, 118}, {385, 31}} - - YES - - 67239424 - 4194304 - Umożliwia zastÄ…pienie bieżącej mapy klawiszy X11 zmianami w menu wejÅ›cia. - - - - - - - - - - 256 - {{68, 151}, {402, 18}} - - YES - - 67239424 - 0 - Stosuj systemowy ukÅ‚ad klawiatury - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{86, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - NaciÅ›niÄ™cie klawisza Opcja spowoduje wysÅ‚anie symboli klawiszy X11 Alt_L i Alt_R X11, a nie Mode_switch. - - - - - - - - - 256 - {{68, 36}, {402, 18}} - - YES - - 67239424 - 0 - Klawisze Opcja dziaÅ‚ajÄ… jak prawy i lewy klawisz Alt - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {538, 246}} - - - WejÅ›cie - - - - - - 2 - - - - 256 - - - - 256 - {{64, 63}, {402, 18}} - - YES - - 67239424 - 0 - Korzystaj z systemowych dźwiÄ™ków komunikatów - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{82, 29}, {385, 28}} - - YES - - 67239424 - 4194304 - X11 bÄ™dzie korzystaÅ‚ ze standardowych systemowych dźwiÄ™ków komunikatów, zdefiniowanych na karcie preferencji Efekty dźwiÄ™kowe. - - - - - - - - - - 256 - {{120, 202}, {128, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Z monitora - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 kolorów - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - TysiÄ…ce - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Miliony - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{63, 205}, {55, 20}} - - YES - - 67239424 - 4194304 - Kolory: - - - - - - - - - - 256 - {{82, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Opcja bÄ™dzie aktywna po ponownym uruchomieniu X11. - - - - - - - - - - 256 - {{64, 149}, {409, 23}} - - YES - - 67239424 - 0 - Tryb peÅ‚nego ekranu - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{83, 83}, {390, 23}} - - YES - - 67239424 - 0 - Pokazuj autom. pasek menu w trybie peÅ‚nego ekranu - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{82, 112}, {385, 31}} - - YES - - 67239424 - 4194304 - WÅ‚Ä…cza okno główne X11. Do wÅ‚Ä…czania i wyÅ‚Ä…czania trybu peÅ‚nego ekranu sÅ‚użą klawisze Command-Opcja-A. - - - - - - - - - {{10, 33}, {538, 246}} - - WyjÅ›cie - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - WÅ‚Ä…cz synchronizacjÄ™ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {385, 28}} - - YES - - 67239424 - 4194304 - Aktywuje menu kopiowania i umożliwia synchronizowanie schowka OS X z buforami X11 (CLIPBOARD i PRIMARY). - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - Uaktualniaj bufor CLIPBOARD zmianami Schowka - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 76}, {489, 18}} - - YES - - 67239424 - 0 - Uaktualniaj bufor PRIMARY (Å›rodkowy przycisk myszy) zmianami Schowka - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 51}, {432, 18}} - - YES - - 67239424 - 0 - Uaktualniaj Schowek natychmiast po zaznaczeniu nowego tekstu - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - Uaktualniaj Schowek zmianami bufora CLIPBOARD - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {385, 28}} - - YES - - 67239424 - 4194304 - WyÅ‚Ä…czenie opcji pozwala korzystać z menedżerów schowka X11 takich jak np. xclipboard lub, klipper. - - - - - - - - - 256 - {{48, 19}, {370, 28}} - - YES - - 67239424 - 4194304 - Z powodu ograniczeÅ„ protokoÅ‚u X11 funkcja może czasami nie dziaÅ‚ać w niektórych programach. - - - - - - - - {{10, 33}, {538, 246}} - - Schowek - - - - - - 2 - - - - 256 - - - - 256 - {{65, 212}, {402, 18}} - - YES - - 67239424 - 0 - Fokus w nieaktywnym oknie jednym klikniÄ™ciem - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{73, 175}, {385, 31}} - - YES - - 67239424 - 4194304 - KlikniÄ™cie nieaktywnego okna bÄ™dzie powodowaÅ‚o jego uaktywnienie i przeniesienie do niego fokusu. - - - - - - - - - - 256 - {{65, 151}, {402, 18}} - - YES - - 67239424 - 0 - Fokus podąża za myszÄ… - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{73, 129}, {401, 17}} - - YES - - 67239424 - 4194304 - Fokus okien X11 podąża za kursorem (ma to pewne niekorzystne skutki). - - - - - - - - - - 256 - {{65, 107}, {402, 18}} - - YES - - 67239424 - 0 - Fokus w nowych oknach - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{73, 59}, {390, 42}} - - YES - - 67239424 - 4194304 - Otwarcie nowego okna X11 bÄ™dzie powodowaÅ‚o umieszczenie programu X11.app na wierzchu (zamiast Finder.app, Terminal.app itd.). - - - - - - - - - {{10, 33}, {538, 246}} - - Okna - - - - - - - 256 - - - - 256 - {{34, 210}, {402, 18}} - - YES - - 67239424 - 0 - Uwierzytelniaj poÅ‚Ä…czenia - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 133}, {402, 18}} - - YES - - 67239424 - 0 - Pozwalaj na poÅ‚Ä…czenia od klientów sieciowych - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{52, 162}, {452, 42}} - - YES - - 67239424 - 4194304 - Uruchomienie X11 utworzy klucze kontroli dostÄ™pu Xauthority. JeÅ›li adres IP systemu zmieni siÄ™, klucze te stracÄ… ważność, co może uniemożliwić uruchamianie programów X11. - - - - - - - - - - 256 - {{52, 85}, {452, 42}} - - YES - - 67239424 - 4194304 - Gdy pole jest zaznaczone, dla bezpieczeÅ„stwa wÅ‚Ä…czona musi być także opcja Uwierzytelniaj poÅ‚Ä…czenia. Gdy pole nie jest zaznaczone, poÅ‚Ä…czenia ze zdalnych programów nie sÄ… dozwolone. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Te opcje bÄ™dÄ… aktywne po nastÄ™pnym uruchomieniu X11. - - - - - - - - - {{10, 33}, {538, 246}} - - Zabezpieczenia - - - - - - - 0 - YES - YES - - - - - - {584, 308} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{333, 380}, {454, 271}} - 1350041600 - Menu programów X11 - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {104, 32}} - - YES - - 67239424 - 137887744 - Powiel - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {104, 32}} - - YES - - 67239424 - 137887744 - UsuÅ„ - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 122.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Nazwa - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Komórka tekstowa - - - - - 3 - MQA - - - - 3 - YES - YES - - - - - 100 - 40 - 1000 - - 75628096 - 2048 - Polecenie - - - - - - 338820672 - 1024 - Komórka tekstowa - - - - - - - 3 - YES - YES - - - - - 69 - 10 - 1000 - - 75628096 - 2048 - Skrót - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Komórka tekstowa - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {104, 32}} - - YES - - -2080244224 - 137887744 - Dodaj rzecz - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Menu - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Programy - - 1048576 - 2147483647 - - - submenuAction: - - Programy - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Dostosuj… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {584, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{507, 548}, {584, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + X11… + + 2147483647 + + + + + + Preferencje… + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + UsÅ‚ugi + + 1048576 + 2147483647 + + + submenuAction: + + UsÅ‚ugi + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + PrzeÅ‚Ä…czaj peÅ‚ny ekran + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Ukryj X11 + h + 1048576 + 2147483647 + + + 42 + + + + Ukryj pozostaÅ‚e + h + 1572864 + 2147483647 + + + + + + Pokaż wszystkie + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ZakoÅ„cz X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Programy + + 1048576 + 2147483647 + + + submenuAction: + + Programy + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Dostosuj… + + 1048576 + 2147483647 + + + + + + + + + Edycja + + 1048576 + 2147483647 + + + submenuAction: + + Edycja + + + + Kopiuj + c + 1048576 + 2147483647 + + + + + + + + + Okno + + 1048576 + 2147483647 + + + submenuAction: + + Okno + + + + Zamknij + w + 1048576 + 2147483647 + + + + + + Minimalizuj okno + m + 1048576 + 2147483647 + + + + + + Zoom + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + PrzeÅ‚Ä…czaj miÄ™dzy oknami + ` + 1048576 + 2147483647 + + + + + + PrzeÅ‚Ä…czaj wstecz pomiÄ™dzy oknami + ` + 1179648 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Umieść wszystko na wierzchu + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Pomoc + + 1048576 + 2147483647 + + + submenuAction: + + Pomoc + + + + Pomoc X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{288, 302}, {584, 308}} + 1350041600 + Preferencje X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {558, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{68, 210}, {402, 18}} + + YES + + 67239424 + 0 + Emuluj mysz z trzema przyciskami + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{86, 58}, {385, 31}} + + YES + + 67239424 + 4194304 + Równoważniki klawiszowe paska menu bÄ™dÄ… mogÅ‚y kolidować z programami X11 używajÄ…cymi modyfikatora Meta. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{86, 170}, {374, 34}} + + YES + + 67239424 + 4194304 + S2xpa25pxJljaWUgeiBwcnp5dHJ6eW1hbnltIGtsYXdpc3plbSBPcGNqYSBsdWIgQ29tbWFuZCBlbXVs +dWplIMWbcm9ka293eSBsdWIgcHJhd3kgcHJ6eWNpc2sgbXlzenkuCg + + + + + + + + + + 256 + {{68, 92}, {402, 18}} + + YES + + 67239424 + 0 + WÅ‚Ä…cz równoważniki klawiszowe w Å›rodowisku X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{86, 118}, {385, 31}} + + YES + + 67239424 + 4194304 + Umożliwia zastÄ…pienie bieżącej mapy klawiszy X11 zmianami w menu wejÅ›cia. + + + + + + + + + + 256 + {{68, 151}, {402, 18}} + + YES + + 67239424 + 0 + Stosuj systemowy ukÅ‚ad klawiatury + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{86, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + NaciÅ›niÄ™cie klawisza Opcja spowoduje wysÅ‚anie symboli klawiszy X11 Alt_L i Alt_R X11, a nie Mode_switch. + + + + + + + + + 256 + {{68, 36}, {402, 18}} + + YES + + 67239424 + 0 + Klawisze Opcja dziaÅ‚ajÄ… jak prawy i lewy klawisz Alt + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {538, 246}} + + WejÅ›cie + + + + + + 2 + + + + 256 + + + + 256 + {{120, 202}, {128, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Z monitora + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 kolorów + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + TysiÄ…ce + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Miliony + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{63, 205}, {55, 20}} + + YES + + 67239424 + 4194304 + Kolory: + + + + + + + + + + 256 + {{82, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Opcja bÄ™dzie aktywna po ponownym uruchomieniu X11. + + + + + + + + + + 256 + {{64, 149}, {409, 23}} + + YES + + 67239424 + 0 + Tryb peÅ‚nego ekranu + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{83, 83}, {390, 23}} + + YES + + 67239424 + 0 + Pokazuj autom. pasek menu w trybie peÅ‚nego ekranu + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{82, 112}, {385, 31}} + + YES + + 67239424 + 4194304 + WÅ‚Ä…cza okno główne X11. Do wÅ‚Ä…czania i wyÅ‚Ä…czania trybu peÅ‚nego ekranu sÅ‚użą klawisze Command-Opcja-A. + + + + + + + + + {{10, 33}, {538, 246}} + + + WyjÅ›cie + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + WÅ‚Ä…cz synchronizacjÄ™ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {385, 28}} + + YES + + 67239424 + 4194304 + Aktywuje menu kopiowania i umożliwia synchronizowanie schowka OS X z buforami X11 (CLIPBOARD i PRIMARY). + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + Uaktualniaj bufor CLIPBOARD zmianami Schowka + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 76}, {489, 18}} + + YES + + 67239424 + 0 + Uaktualniaj bufor PRIMARY (Å›rodkowy przycisk myszy) zmianami Schowka + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 51}, {432, 18}} + + YES + + 67239424 + 0 + Uaktualniaj Schowek natychmiast po zaznaczeniu nowego tekstu + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + Uaktualniaj Schowek zmianami bufora CLIPBOARD + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {385, 28}} + + YES + + 67239424 + 4194304 + WyÅ‚Ä…czenie opcji pozwala korzystać z menedżerów schowka X11 takich jak np. xclipboard lub, klipper. + + + + + + + + + 256 + {{48, 19}, {370, 28}} + + YES + + 67239424 + 4194304 + Z powodu ograniczeÅ„ protokoÅ‚u X11 funkcja może czasami nie dziaÅ‚ać w niektórych programach. + + + + + + + + {{10, 33}, {538, 246}} + + Schowek + + + + + + 2 + + + + 256 + + + + 256 + {{65, 212}, {402, 18}} + + YES + + 67239424 + 0 + Fokus w nieaktywnym oknie jednym klikniÄ™ciem + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{73, 175}, {385, 31}} + + YES + + 67239424 + 4194304 + KlikniÄ™cie nieaktywnego okna bÄ™dzie powodowaÅ‚o jego uaktywnienie i przeniesienie do niego fokusu. + + + + + + + + + + 256 + {{65, 151}, {402, 18}} + + YES + + 67239424 + 0 + Fokus podąża za myszÄ… + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{73, 129}, {401, 17}} + + YES + + 67239424 + 4194304 + Fokus okien X11 podąża za kursorem (ma to pewne niekorzystne skutki). + + + + + + + + + + 256 + {{65, 107}, {402, 18}} + + YES + + 67239424 + 0 + Fokus w nowych oknach + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{73, 59}, {390, 42}} + + YES + + 67239424 + 4194304 + Otwarcie nowego okna X11 bÄ™dzie powodowaÅ‚o umieszczenie programu X11.app na wierzchu (zamiast Finder.app, Terminal.app itd.). + + + + + + + + + {{10, 33}, {538, 246}} + + Okna + + + + + + + 256 + + + + 256 + {{34, 210}, {402, 18}} + + YES + + 67239424 + 0 + Uwierzytelniaj poÅ‚Ä…czenia + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 133}, {402, 18}} + + YES + + 67239424 + 0 + Pozwalaj na poÅ‚Ä…czenia od klientów sieciowych + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{52, 162}, {452, 42}} + + YES + + 67239424 + 4194304 + Uruchomienie X11 utworzy klucze kontroli dostÄ™pu Xauthority. JeÅ›li adres IP systemu zmieni siÄ™, klucze te stracÄ… ważność, co może uniemożliwić uruchamianie programów X11. + + + + + + + + + + 256 + {{52, 85}, {452, 42}} + + YES + + 67239424 + 4194304 + Gdy pole jest zaznaczone, dla bezpieczeÅ„stwa wÅ‚Ä…czona musi być także opcja Uwierzytelniaj poÅ‚Ä…czenia. Gdy pole nie jest zaznaczone, poÅ‚Ä…czenia ze zdalnych programów nie sÄ… dozwolone. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Te opcje bÄ™dÄ… aktywne po nastÄ™pnym uruchomieniu X11. + + + + + + + + + {{10, 33}, {538, 246}} + + Zabezpieczenia + + + + + + + 0 + YES + YES + + + + + + {584, 308} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{333, 380}, {454, 271}} + 1350041600 + Menu programów X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {104, 32}} + + YES + + 67239424 + 137887744 + Powiel + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {104, 32}} + + YES + + 67239424 + 137887744 + UsuÅ„ + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 122.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Nazwa + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Komórka tekstowa + + + + + 3 + MQA + + + + 3 + YES + YES + + + + + 100 + 40 + 1000 + + 75628096 + 2048 + Polecenie + + + + + + 338820672 + 1024 + Komórka tekstowa + + + + + + + 3 + YES + YES + + + + + 69 + 10 + 1000 + + 75628096 + 2048 + Skrót + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Komórka tekstowa + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {104, 32}} + + YES + + -2080244224 + 137887744 + Dodaj rzecz + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Menu + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Programy + + 1048576 + 2147483647 + + + submenuAction: + + Programy + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Dostosuj… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/keyedobjects.nib index 62f4065f6..273298a5b 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/pl.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/locversion.plist index 443fca6e3..74d039bb9 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 100 - LprojLocale - pt - LprojRevisionLevel - 1 - LprojVersion - 100 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + pt + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/designable.nib index 2c386a880..0f376316b 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/designable.nib @@ -1,3618 +1,3759 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Sobre o X11 - - 2147483647 - - - - - - Preferências... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Serviços - - 1048576 - 2147483647 - - - submenuAction: - - Serviços - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Alternar Tela Cheia - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Ocultar X11 - h - 1048576 - 2147483647 - - - 42 - - - - Ocultar Outros - h - 1572864 - 2147483647 - - - - - - Mostrar Tudo - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Encerrar X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Aplicativos - - 1048576 - 2147483647 - - - submenuAction: - - Aplicativos - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizar... - - 1048576 - 2147483647 - - - - - - - - - Editar - - 1048576 - 2147483647 - - - submenuAction: - - Editar - - - - Copiar - c - 1048576 - 2147483647 - - - - - - - - - Janela - - 1048576 - 2147483647 - - - submenuAction: - - Janela - - - - Fechar - w - 1048576 - 2147483647 - - - - - - Minimizar - m - 1048576 - 2147483647 - - - - - - Reduzir/Ampliar - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Percorrer Janelas - ` - 1048840 - 2147483647 - - - - - - Percorrer Janelas no Sentido Inverso - ` - 1179648 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Trazer Todas Para a Frente - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Ajuda - - 1048576 - 2147483647 - - - submenuAction: - - Ajuda - - - - Ajuda X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 364}, {644, 308}} - 1350041600 - Preferências X11 - NSPanel - - View - - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {618, 292}} - - - - - - 1 - - - - 256 - - - - 256 - {{18, 214}, {402, 18}} - - - YES - - 67239424 - 0 - Emular mouse de três botões - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 60}, {548, 31}} - - - YES - - 67239424 - 4194304 - Se ativadas, as teclas equivalentes da barra de menus podem interferir com os aplicativos do X11 que usem o modificador Meta. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2ODY1AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 166}, {548, 42}} - - - YES - - 67239424 - 4194304 - TWFudGVuaGEgcHJlc3Npb25hZGFzIGFzIHRlY2xhcyBPcMOnw6NvIG91IENvbWFuZG8gYW8gY2xpY2Fy -IHBhcmEgYXRpdmFyIG8gYm90w6NvIGRhIGRpcmVpdGEgb3UgbyBib3TDo28gY2VudHJhbCBkbyBtb3Vz -ZS4KA - - - - - - - - - - 256 - {{18, 97}, {402, 18}} - - - YES - - 67239424 - 0 - Ativar as teclas equivalentes sob X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 121}, {548, 28}} - - - YES - - 67239424 - 4194304 - Permite que as alterações feitas no menu de leiautes de teclado sobrescrevam o mapa de teclado atual do X11. - - - - - - - - - - 256 - {{18, 153}, {402, 18}} - - - YES - - 67239424 - 0 - Seguir o leiaute de teclado do sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {548, 31}} - - - YES - - 67239424 - 4194304 - Quando esta opção está marcada, as teclas opção enviam os símbolos de tecla do X11 Alt_L e Alt_R em vez de Mode_switch. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - - YES - - 67239424 - 0 - As teclas Opção enviam Alt_L e Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {598, 246}} - - - - Entrada - - - - - - 2 - - - - 256 - - - - 256 - {{18, 70}, {402, 18}} - - YES - - 67239424 - 0 - Usar o efeito de aviso do sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 36}, {548, 28}} - - YES - - 67239424 - 4194304 - Os bipes do X11 usarão o aviso do sistema padrão, conforme definido no painel de preferências do sistema Efeitos Sonoros. - - - - - - - - - - 256 - {{64, 202}, {128, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Da Tela - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 Cores - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Milhares - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Milhões - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 191}, {45, 34}} - - YES - - 67239424 - 4194304 - Cores: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Esta opção passa a funcionar quando o X11 é executado novamente. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - Modo de tela cheia - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 97}, {409, 23}} - - YES - - 67239424 - 0 - Mostrar automatic. a barra de menus no modo de tela cheia - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 126}, {548, 17}} - - YES - - 67239424 - 4194304 - Ativa a janela raiz do X11. Usar o toque Comando-Opção-A para digitar e sair do modo tela cheia. - - - - - - - - - {{10, 33}, {598, 246}} - - Saída - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - Ativar sincronização - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {536, 28}} - - YES - - 67239424 - 4194304 - Ativa o item de menu "copiar" e permite a sincronização entre a Ãrea de Colagem do OSX e a ÃREA DE TRANSFERÊNCIA e os buffers PRINCIPAIS do X11. - - - - - - - - - 256 - {{37, 96}, {511, 23}} - - YES - - 67239424 - 0 - Atualizar a ÃREA DE TRANSFERÊNCIA quando a Ãrea de Colagem for alterada - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 71}, {501, 23}} - - YES - - 67239424 - 0 - Atualizar PRINCIPAL (clique central) quando a Ãrea de Colagem for alterada - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 46}, {553, 23}} - - YES - - 67239424 - 0 - Atualizar a Ãrea de Colagem imediatamente quando um novo texto for selecionado - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 159}, {511, 23}} - - YES - - 67239424 - 0 - Atualizar a Ãrea de Colagem quando a ÃREA DE TRANSFERÊNCIA for alterada - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{55, 125}, {529, 28}} - - YES - - 67239424 - 4194304 - Desative esta opção quando quiser usar o xclipboard, o klipper ou qualquer outro gerenciador de área de transferência do X11. - - - - - - - - - 256 - {{55, 14}, {526, 28}} - - YES - - 67239424 - 4194304 - Devido a limitações no protocolo do X11, talvez esta opção nem sempre funcione em alguns aplicativos. - - - - - - - - {{10, 33}, {598, 246}} - - Ãrea de Colagem - - - - - - 2 - - - - 256 - - - - 256 - {{18, 212}, {402, 18}} - - YES - - 67239424 - 0 - Clicar em Janelas Inativas - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 175}, {542, 31}} - - YES - - 67239424 - 4194304 - Quando esta opção está selecionada, a ação de clicar em uma janela inativa faz com que o clique do mouse seja ativado para essa janela, a qual também é ativada. - - - - - - - - - 256 - {{18, 151}, {402, 18}} - - YES - - 67239424 - 0 - O Foco Segue o Mouse - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 128}, {441, 17}} - - YES - - 67239424 - 4194304 - O foco da janela do X11 segue o cursor. Esta opção tem alguns inconvenientes. - - - - - - - - - 256 - {{18, 107}, {402, 18}} - - YES - - 67239424 - 0 - Foco nas Novas Janelas - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 73}, {542, 28}} - - YES - - 67239424 - 4194304 - Quando esta opção está ativada, a criação de uma nova janela do X11 move o X11.app para o segundo plano (em vez do Finder.app, Terminal.app, etc.) - - - - - - - - {{10, 33}, {598, 246}} - - Janelas - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Autenticar conexões - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 145}, {402, 18}} - - YES - - 67239424 - 0 - Permitir conexões de clientes da rede - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 169}, {539, 35}} - - YES - - 67239424 - 4194304 - A execução do X11 criará as chaves de controle de acesso Xauthority. Se mudar o endereço de IP do sistema, essas chaves tornam-se inválidas, o que pode impedir a execução dos aplicativos do X11. - - - - - - - - - - 256 - {{36, 97}, {555, 42}} - - YES - - 67239424 - 4194304 - Se ativadas, as conexões Autenticar também podem ser ativadas para garantir a segurança do sistema. Se desativadas, as conexões dos aplicativos remotos não são permitidas. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Estas opções passam a funcionar quanto o X11 é executado em seguida. - - - - - - - - - {{10, 33}, {598, 246}} - - Segurança - - - - - - - 0 - YES - YES - - - - - - {644, 308} - - - - {{0, 0}, {1280, 938}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_prefs - - - 11 - 2 - {{302, 440}, {519, 271}} - 1350041600 - Menu de Aplicativos do X11 - NSPanel - - View - - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 265 - {{372, 191}, {132, 32}} - - - YES - - 67239424 - 137887744 - Duplicar - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{372, 159}, {132, 32}} - - - YES - - 67239424 - 137887744 - Remover - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {333, 198} - - - YES - - - 256 - {333, 17} - - - - - - - 256 - {{334, 0}, {16, 17}} - - - - - - 132.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Nome - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 110 - 40 - 1000 - - 75628096 - 2048 - Comando - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - 81 - 10 - 1000 - - 75628096 - 2048 - Atalho - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {333, 198}} - - - - - - 4 - - - - 256 - {{334, 17}, {15, 198}} - - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {333, 15}} - - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {333, 17}} - - - - - - 4 - - - - {{20, 20}, {350, 231}} - - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{372, 223}, {132, 32}} - - - YES - - -2080244224 - 137887744 - Adicionar Item - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {519, 271} - - - - {{0, 0}, {1280, 938}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_apps - - - Menu - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Aplicativos - - 1048576 - 2147483647 - - - submenuAction: - - Aplicativos - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizar… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {644, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 548}, {644, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {519, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {519, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 836}, {337, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Sobre o X11 + + 2147483647 + + + + + + Preferências... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Serviços + + 1048576 + 2147483647 + + + submenuAction: + + Serviços + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Alternar Tela Cheia + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Ocultar X11 + h + 1048576 + 2147483647 + + + 42 + + + + Ocultar Outros + h + 1572864 + 2147483647 + + + + + + Mostrar Tudo + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Encerrar X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Aplicativos + + 1048576 + 2147483647 + + + submenuAction: + + Aplicativos + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizar... + + 1048576 + 2147483647 + + + + + + + + + Editar + + 1048576 + 2147483647 + + + submenuAction: + + Editar + + + + Copiar + c + 1048576 + 2147483647 + + + + + + + + + Janela + + 1048576 + 2147483647 + + + submenuAction: + + Janela + + + + Fechar + w + 1048576 + 2147483647 + + + + + + Minimizar + m + 1048576 + 2147483647 + + + + + + Reduzir/Ampliar + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Percorrer Janelas + ` + 1048840 + 2147483647 + + + + + + Percorrer Janelas no Sentido Inverso + ` + 1179648 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Trazer Todas Para a Frente + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Ajuda + + 1048576 + 2147483647 + + + submenuAction: + + Ajuda + + + + Ajuda X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 364}, {644, 308}} + 1350041600 + Preferências X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {618, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 214}, {402, 18}} + + YES + + 67239424 + 0 + Emular mouse de três botões + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 60}, {548, 31}} + + YES + + 67239424 + 4194304 + Se ativadas, as teclas equivalentes da barra de menus podem interferir com os aplicativos do X11 que usem o modificador Meta. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 166}, {548, 42}} + + YES + + 67239424 + 4194304 + TWFudGVuaGEgcHJlc3Npb25hZGFzIGFzIHRlY2xhcyBPcMOnw6NvIG91IENvbWFuZG8gYW8gY2xpY2Fy +IHBhcmEgYXRpdmFyIG8gYm90w6NvIGRhIGRpcmVpdGEgb3UgbyBib3TDo28gY2VudHJhbCBkbyBtb3Vz +ZS4KA + + + + + + + + + + 256 + {{18, 97}, {402, 18}} + + YES + + 67239424 + 0 + Ativar as teclas equivalentes sob X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 121}, {548, 28}} + + YES + + 67239424 + 4194304 + Permite que as alterações feitas no menu de leiautes de teclado sobrescrevam o mapa de teclado atual do X11. + + + + + + + + + + 256 + {{18, 153}, {402, 18}} + + YES + + 67239424 + 0 + Seguir o leiaute de teclado do sistema + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {548, 31}} + + YES + + 67239424 + 4194304 + Quando esta opção está marcada, as teclas opção enviam os símbolos de tecla do X11 Alt_L e Alt_R em vez de Mode_switch. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + As teclas Opção enviam Alt_L e Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {598, 246}} + + Entrada + + + + + + 2 + + + + 256 + + + + 256 + {{64, 202}, {128, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Da Tela + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 Cores + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Milhares + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Milhões + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 191}, {45, 34}} + + YES + + 67239424 + 4194304 + Cores: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Esta opção passa a funcionar quando o X11 é executado novamente. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + Modo de tela cheia + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 97}, {409, 23}} + + YES + + 67239424 + 0 + Mostrar automatic. a barra de menus no modo de tela cheia + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 126}, {548, 17}} + + YES + + 67239424 + 4194304 + Ativa a janela raiz do X11. Usar o toque Comando-Opção-A para digitar e sair do modo tela cheia. + + + + + + + + + {{10, 33}, {598, 246}} + + + Saída + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + Ativar sincronização + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {536, 28}} + + YES + + 67239424 + 4194304 + Ativa o item de menu "copiar" e permite a sincronização entre a Ãrea de Colagem do OSX e a ÃREA DE TRANSFERÊNCIA e os buffers PRINCIPAIS do X11. + + + + + + + + + 256 + {{37, 96}, {511, 23}} + + YES + + 67239424 + 0 + Atualizar a ÃREA DE TRANSFERÊNCIA quando a Ãrea de Colagem for alterada + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 71}, {501, 23}} + + YES + + 67239424 + 0 + Atualizar PRINCIPAL (clique central) quando a Ãrea de Colagem for alterada + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 46}, {553, 23}} + + YES + + 67239424 + 0 + Atualizar a Ãrea de Colagem imediatamente quando um novo texto for selecionado + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 159}, {511, 23}} + + YES + + 67239424 + 0 + Atualizar a Ãrea de Colagem quando a ÃREA DE TRANSFERÊNCIA for alterada + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{55, 125}, {529, 28}} + + YES + + 67239424 + 4194304 + Desative esta opção quando quiser usar o xclipboard, o klipper ou qualquer outro gerenciador de área de transferência do X11. + + + + + + + + + 256 + {{55, 14}, {526, 28}} + + YES + + 67239424 + 4194304 + Devido a limitações no protocolo do X11, talvez esta opção nem sempre funcione em alguns aplicativos. + + + + + + + + {{10, 33}, {598, 246}} + + Ãrea de Colagem + + + + + + 2 + + + + 256 + + + + 256 + {{18, 212}, {402, 18}} + + YES + + 67239424 + 0 + Clicar em Janelas Inativas + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 175}, {542, 31}} + + YES + + 67239424 + 4194304 + Quando esta opção está selecionada, a ação de clicar em uma janela inativa faz com que o clique do mouse seja ativado para essa janela, a qual também é ativada. + + + + + + + + + 256 + {{18, 151}, {402, 18}} + + YES + + 67239424 + 0 + O Foco Segue o Mouse + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 128}, {441, 17}} + + YES + + 67239424 + 4194304 + O foco da janela do X11 segue o cursor. Esta opção tem alguns inconvenientes. + + + + + + + + + 256 + {{18, 107}, {402, 18}} + + YES + + 67239424 + 0 + Foco nas Novas Janelas + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 73}, {542, 28}} + + YES + + 67239424 + 4194304 + Quando esta opção está ativada, a criação de uma nova janela do X11 move o X11.app para o segundo plano (em vez do Finder.app, Terminal.app, etc.) + + + + + + + + {{10, 33}, {598, 246}} + + Janelas + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Autenticar conexões + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 145}, {402, 18}} + + YES + + 67239424 + 0 + Permitir conexões de clientes da rede + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 169}, {539, 35}} + + YES + + 67239424 + 4194304 + A execução do X11 criará as chaves de controle de acesso Xauthority. Se mudar o endereço de IP do sistema, essas chaves tornam-se inválidas, o que pode impedir a execução dos aplicativos do X11. + + + + + + + + + + 256 + {{36, 97}, {555, 42}} + + YES + + 67239424 + 4194304 + Se ativadas, as conexões Autenticar também podem ser ativadas para garantir a segurança do sistema. Se desativadas, as conexões dos aplicativos remotos não são permitidas. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Estas opções passam a funcionar quanto o X11 é executado em seguida. + + + + + + + + + {{10, 33}, {598, 246}} + + Segurança + + + + + + + 0 + YES + YES + + + + + + {644, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {519, 271}} + 1350041600 + Menu de Aplicativos do X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{372, 191}, {132, 32}} + + YES + + 67239424 + 137887744 + Duplicar + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{372, 159}, {132, 32}} + + YES + + 67239424 + 137887744 + Remover + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {333, 198} + + YES + + + 256 + {333, 17} + + + + + + 256 + {{334, 0}, {16, 17}} + + + + + 132.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Nome + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 110 + 40 + 1000 + + 75628096 + 2048 + Comando + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + 81 + 10 + 1000 + + 75628096 + 2048 + Atalho + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {333, 198}} + + + + + 4 + + + + 256 + {{334, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {333, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {333, 17}} + + + + + 4 + + + + {{20, 20}, {350, 231}} + + + 133170 + + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{372, 223}, {132, 32}} + + YES + + -2080244224 + 137887744 + Adicionar Item + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {519, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Menu + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Aplicativos + + 1048576 + 2147483647 + + + submenuAction: + + Aplicativos + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizar… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/keyedobjects.nib index d84701f2e..ab90fb0ff 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/pt.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/locversion.plist index 509b5765a..5c98e2a68 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - pt_PT - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + pt_PT + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/designable.nib index db1d5c968..2494443e6 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/designable.nib @@ -1,3582 +1,3514 @@ - - - - 1040 - 11A79a - 732 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 732 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Acerca do X11 - - 2147483647 - - - - - - Preferências... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Serviços - - 1048576 - 2147483647 - - - submenuAction: - - Serviços - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Alternar ecrã completo - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Ocultar o X11 - h - 1048576 - 2147483647 - - - 42 - - - - Ocultar outras aplicações - h - 1572864 - 2147483647 - - - - - - Mostrar tudo - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Sair do X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Aplicações - - 1048576 - 2147483647 - - - submenuAction: - - Aplicações - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizar... - - 1048576 - 2147483647 - - - - - - - - - Edição - - 1048576 - 2147483647 - - - submenuAction: - - Edição - - - - Copiar - c - 1048576 - 2147483647 - - - - - - - - - Janela - - 1048576 - 2147483647 - - - submenuAction: - - Janela - - - - Fechar - w - 1048576 - 2147483647 - - - - - - Minimizar - m - 1048576 - 2147483647 - - - - - - Zoom - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Percorrer janelas - ) - 1048576 - 2147483647 - - - - - - Percorrer janelas no sentido inverso - ( - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Passar tudo para a frente - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Ajuda - - 1048576 - 2147483647 - - - submenuAction: - - Ajuda - - - - Ajuda do X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{319, 328}, {633, 308}} - 1350041600 - Preferências do X11 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {607, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Simular rato de três botões - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 57}, {510, 28}} - - YES - - 67239424 - 4194304 - Se estiverem activas, as teclas equivalentes da barra de menus podem interferir nas aplicações X11 que utilizam o modificador Meta. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 162}, {510, 42}} - - YES - - 67239424 - 4194304 - QW8gY2xpY2FyLCBtYW50ZW5oYSBwcmVtaWRhcyBhcyB0ZWNsYXMgT3DDp8OjbyBvdSBDb21hbmRvIHBh -cmEgYWN0aXZhciBvcyBib3TDtWVzIGNlbnRyYWwgb3UgZGlyZWl0byBkbyByYXRvLgo - - - - - - - - - - 256 - {{18, 91}, {402, 18}} - - YES - - 67239424 - 0 - Activar as equivalências de teclado para X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 121}, {510, 19}} - - YES - - 67239424 - 4194304 - Permite que alterações do menu de entrada se sobreponham ao actual mapa de teclas do X11. - - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 0 - Seguir a disposição do teclado do sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - Quando activadas, as teclas de opção enviam símbolos de teclas X11 Alt_L e Alt_R em vez de alternar_modo. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 0 - As teclas de opção enviam Alt_L e Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {587, 246}} - - - Entrada - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - Utilizar o efeito de alerta do sistema - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 15}, {521, 42}} - - YES - - 67239424 - 4194304 - Os sinais sonoros do X11 utilizarão o alerta padrão do sistema, tal como estiver definido em Efeitos sonoros, nas preferências do sistema. - - - - - - - - - - 256 - {{68, 201}, {131, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - Do monitor - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 cores - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Milhares - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Milhões - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {55, 20}} - - YES - - 67239424 - 4194304 - Cores: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Esta opção entrará em vigor da próxima vez que o X11 for executado. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - Modo ecrã completo - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 88}, {476, 18}} - - YES - - 67239424 - 0 - Mostrar automaticamente a barra de menus em modo de ecrã completo - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 115}, {521, 28}} - - YES - - 67239424 - 4194304 - Activa a janela raiz do X11. Utilize a combinação de teclas Comando-Opção-A para entrar e sair do modo de ecrã completo. - - - - - - - - - {{10, 33}, {587, 246}} - - Saída - - - - - - 2 - - - - 256 - - - - 256 - {{8, 222}, {409, 23}} - - YES - - 67239424 - 0 - Activar sincronização - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{26, 188}, {540, 28}} - - YES - - 67239424 - 4194304 - Activa o elemento de menu "copiar" e permite a sincronização entre a área de colagem do OS X e os buffers CLIPBOARD e PRIMARY do X11. - - - - - - - - - 256 - {{24, 96}, {409, 23}} - - YES - - 67239424 - 0 - Actualizar CLIPBOARD quando a área de colagem for alterada - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{24, 74}, {560, 18}} - - YES - - 67239424 - 0 - Actualizar PRIMARY (clique no botão do meio) quando a área de colagem for alterada - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{24, 46}, {544, 23}} - - YES - - 67239424 - 0 - Actualizar área de colagem assim que for seleccionado novo texto - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{24, 164}, {410, 18}} - - YES - - 67239424 - 0 - Actualizar a área de colagem quando CLIPBOARD for alterado - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{38, 125}, {509, 28}} - - YES - - 67239424 - 4194304 - Desactive esta opção se pretender utilizar o xclipboard, o klipper ou qualquer outro gestor de clipboard X11. - - - - - - - - - 256 - {{38, 14}, {534, 28}} - - YES - - 67239424 - 4194304 - Devido a limitações do protocolo X11, esta opção nem sempre funcionará em algumas aplicações. - - - - - - - - {{10, 33}, {587, 246}} - - Ãrea de colagem - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Clique atravessa janelas inactivas - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {519, 31}} - - YES - - 67239424 - 4194304 - Se assinalar esta opção, ao clicar numa janela inactiva, o clique não só a traz para a frente como activa a janela completamente. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Foco segue o rato - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 125}, {490, 20}} - - YES - - 67239424 - 4194304 - O foco da janela do X11 segue o cursor. Isto tem alguns efeitos adversos. - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - Foco em janelas novas - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 73}, {509, 28}} - - YES - - 67239424 - 4194304 - A criação de uma nova janela X11 faz com que X11.app venha para primeiro plano (em vez de Finder.app, Terminal.app, etc.). - - - - - - - - {{10, 33}, {587, 246}} - - Janelas - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Autenticar ligações - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - Permitir ligações de clientes da rede - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {496, 42}} - - YES - - 67239424 - 4194304 - Lançar o X11 cria chaves Xauthority de controlo de acesso. Se o endereço IP do sistema for alterado, estas chaves perdem a validade, podendo, assim, impossibilitar a execução das aplicações X11. - - - - - - - - - - 256 - {{36, 71}, {496, 56}} - - YES - - 67239424 - 4194304 - Se activar esta opção, precisa igualmente de activar a opção “Autenticar ligações†para garantir a segurança do sistema. Se não activar esta opção, não são permitidas ligações a partir de aplicações remotas. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Estas opções entrarão em vigor da próxima vez que o X11 for executado. - - - - - - - - - {{10, 33}, {587, 246}} - - Segurança - - - - - - - 0 - YES - YES - - - - - - {633, 308} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{360, 400}, {477, 271}} - 1350041600 - Menu Aplicação do X11 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{318, 191}, {155, 32}} - - YES - - 67239424 - 137887744 - Duplicar - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{318, 159}, {155, 32}} - - YES - - 67239424 - 137887744 - Remover - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {279, 198} - - YES - - - 256 - {279, 17} - - - - - - 256 - {{280, 0}, {16, 17}} - - - - - 99.731002807617188 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Nome - - - 3 - MC4zMzMzMzI5OQA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Célula de texto - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 101 - 40 - 1000 - - 75628096 - 2048 - Comando - - - - - - 338820672 - 1024 - Célula de texto - - - - - - - 3 - YES - YES - - - - 69 - 10 - 1000 - - 75628096 - 2048 - Atalho - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Célula de texto - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {279, 198}} - - - - - 4 - - - - 256 - {{280, 17}, {15, 198}} - - - _doScroller: - 0.99492380000000002 - - - - 256 - {{1, 215}, {279, 15}} - - 1 - - _doScroller: - 0.68852460000000004 - - - - 2304 - - - - {{1, 0}, {279, 17}} - - - - - 4 - - - - {{20, 20}, {296, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{318, 223}, {155, 32}} - - YES - - -2080244224 - 137887744 - Adicionar elemento - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {477, 271} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Menu - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Aplicações - - 1048576 - 2147483647 - - - submenuAction: - - Aplicações - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Personalizar… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 565}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 565}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - + + + + 1040 + 11A194b + 787 + 1079 + 502.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 787 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Acerca do X11 + + 2147483647 + + + + + + Preferências... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Serviços + + 1048576 + 2147483647 + + + submenuAction: + + Serviços + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Alternar ecrã completo + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Ocultar o X11 + h + 1048576 + 2147483647 + + + 42 + + + + Ocultar outras aplicações + h + 1572864 + 2147483647 + + + + + + Mostrar tudo + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Sair do X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Aplicações + + 1048576 + 2147483647 + + + submenuAction: + + Aplicações + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizar... + + 1048576 + 2147483647 + + + + + + + + + Edição + + 1048576 + 2147483647 + + + submenuAction: + + Edição + + + + Copiar + c + 1048576 + 2147483647 + + + + + + + + + Janela + + 1048576 + 2147483647 + + + submenuAction: + + Janela + + + + Fechar + w + 1048576 + 2147483647 + + + + + + Minimizar + m + 1048576 + 2147483647 + + + + + + Zoom + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Percorrer janelas + ) + 1048576 + 2147483647 + + + + + + Percorrer janelas no sentido inverso + ( + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Passar tudo para a frente + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Ajuda + + 1048576 + 2147483647 + + + submenuAction: + + Ajuda + + + + Ajuda do X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{319, 328}, {633, 308}} + 1350041600 + Preferências do X11 + NSPanel + + View + + + {3.4028235e+38, 3.4028235e+38} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {607, 292}} + + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Simular rato de três botões + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 57}, {510, 28}} + + YES + + 67239424 + 4194304 + Se estiverem activas, as teclas equivalentes da barra de menus podem interferir nas aplicações X11 que utilizam o modificador Meta. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2ODY1AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 162}, {510, 42}} + + YES + + 67239424 + 4194304 + QW8gY2xpY2FyLCBtYW50ZW5oYSBwcmVtaWRhcyBhcyB0ZWNsYXMgT3DDp8OjbyBvdSBDb21hbmRvIHBh +cmEgYWN0aXZhciBvcyBib3TDtWVzIGNlbnRyYWwgb3UgZGlyZWl0byBkbyByYXRvLgo + + + + + + + + + + 256 + {{18, 91}, {402, 18}} + + YES + + 67239424 + 0 + Activar as equivalências de teclado para X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 121}, {510, 19}} + + YES + + 67239424 + 4194304 + Permite que alterações do menu de entrada se sobreponham ao actual mapa de teclas do X11. + + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 0 + Seguir a disposição do teclado do sistema + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + Quando activadas, as teclas de opção enviam símbolos de teclas X11 Alt_L e Alt_R em vez de alternar_modo. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + As teclas de opção enviam Alt_L e Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {587, 246}} + + Entrada + + + + + + 2 + + + + 256 + + + + 256 + {{68, 201}, {131, 26}} + + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + Do monitor + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 cores + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Milhares + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Milhões + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {55, 20}} + + + YES + + 67239424 + 4194304 + Cores: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + + YES + + 67239424 + 4194304 + Esta opção entrará em vigor da próxima vez que o X11 for executado. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + + YES + + 67239424 + 0 + Modo ecrã completo + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 88}, {476, 18}} + + + YES + + 67239424 + 0 + Mostrar automaticamente a barra de menus em modo de ecrã completo + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 115}, {521, 28}} + + + YES + + 67239424 + 4194304 + Activa a janela raiz do X11. Utilize a combinação de teclas Comando-Opção-A para entrar e sair do modo de ecrã completo. + + + + + + + + + {{10, 33}, {587, 246}} + + + + Saída + + + + + + 2 + + + + 256 + + + + 256 + {{8, 222}, {409, 23}} + + YES + + 67239424 + 0 + Activar sincronização + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{26, 188}, {540, 28}} + + YES + + 67239424 + 4194304 + Activa o elemento de menu "copiar" e permite a sincronização entre a área de colagem do OS X e os buffers CLIPBOARD e PRIMARY do X11. + + + + + + + + + 256 + {{24, 101}, {409, 23}} + + YES + + 67239424 + 0 + Actualizar CLIPBOARD quando a área de colagem for alterada + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{24, 79}, {560, 18}} + + YES + + 67239424 + 0 + Actualizar PRIMARY (clique no botão do meio) quando a área de colagem for alterada + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{24, 53}, {544, 22}} + + YES + + 67239424 + 0 + Actualizar área de colagem assim que for seleccionado novo texto + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{24, 164}, {410, 18}} + + YES + + 67239424 + 0 + Actualizar a área de colagem quando CLIPBOARD for alterado + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{38, 130}, {509, 28}} + + YES + + 67239424 + 4194304 + Desactive esta opção se pretender utilizar o xclipboard, o klipper ou qualquer outro gestor de clipboard X11. + + + + + + + + + 256 + {{38, 19}, {534, 28}} + + YES + + 67239424 + 4194304 + Devido a limitações do protocolo X11, esta opção nem sempre funcionará em algumas aplicações. + + + + + + + + {{10, 33}, {587, 246}} + + Ãrea de colagem + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Clique atravessa janelas inactivas + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {519, 31}} + + YES + + 67239424 + 4194304 + Se assinalar esta opção, ao clicar numa janela inactiva, o clique não só a traz para a frente como activa a janela completamente. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Foco segue o rato + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 125}, {490, 20}} + + YES + + 67239424 + 4194304 + O foco da janela do X11 segue o cursor. Isto tem alguns efeitos adversos. + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + Foco em janelas novas + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 73}, {509, 28}} + + YES + + 67239424 + 4194304 + A criação de uma nova janela X11 faz com que X11.app venha para primeiro plano (em vez de Finder.app, Terminal.app, etc.). + + + + + + + + {{10, 33}, {587, 246}} + + Janelas + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Autenticar ligações + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + Permitir ligações de clientes da rede + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {496, 42}} + + YES + + 67239424 + 4194304 + Lançar o X11 cria chaves Xauthority de controlo de acesso. Se o endereço IP do sistema for alterado, estas chaves perdem a validade, podendo, assim, impossibilitar a execução das aplicações X11. + + + + + + + + + + 256 + {{36, 71}, {496, 56}} + + YES + + 67239424 + 4194304 + Se activar esta opção, precisa igualmente de activar a opção “Autenticar ligações†para garantir a segurança do sistema. Se não activar esta opção, não são permitidas ligações a partir de aplicações remotas. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Estas opções entrarão em vigor da próxima vez que o X11 for executado. + + + + + + + + + {{10, 33}, {587, 246}} + + Segurança + + + + + + + 0 + YES + YES + + + + + + {633, 308} + + + + {{0, 0}, {1440, 878}} + {320, 262} + {3.4028235e+38, 3.4028235e+38} + x11_prefs + + + 11 + 2 + {{360, 400}, {477, 271}} + 1350041600 + Menu Aplicação do X11 + NSPanel + + View + + + {3.4028235e+38, 3.4028235e+38} + {320, 240} + + + 256 + + + + 265 + {{318, 191}, {155, 32}} + + YES + + 67239424 + 137887744 + Duplicar + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{318, 159}, {155, 32}} + + YES + + 67239424 + 137887744 + Remover + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {279, 198} + + YES + + + 256 + {279, 17} + + + + + + 256 + {{280, 0}, {16, 17}} + + + + + 99.731002807617188 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Nome + + + 3 + MC4zMzMzMzI5ODU2AA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Célula de texto + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 101 + 40 + 1000 + + 75628096 + 2048 + Comando + + + + + + 338820672 + 1024 + Célula de texto + + + + + + + 3 + YES + YES + + + + 69 + 10 + 1000 + + 75628096 + 2048 + Atalho + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Célula de texto + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + + + {{1, 17}, {279, 198}} + + + + + 4 + + + + 256 + {{280, 17}, {15, 198}} + + + _doScroller: + 0.99492377042770386 + + + + 256 + {{1, 215}, {279, 15}} + + 1 + + _doScroller: + 0.68852460384368896 + + + + 2304 + + + + {{1, 0}, {279, 17}} + + + + + 4 + + + + {{20, 20}, {296, 231}} + + + 50 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{318, 223}, {155, 32}} + + YES + + -2080244224 + 137887744 + Adicionar elemento + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {477, 271} + + {{0, 0}, {1440, 878}} + {320, 262} + {3.4028235e+38, 3.4028235e+38} + x11_apps + + + Menu + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Aplicações + + 1048576 + 2147483647 + + + submenuAction: + + Aplicações + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Personalizar… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 548}, {633, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{507, 548}, {633, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/keyedobjects.nib index efae77699..4cf336129 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/pt_PT.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/locversion.plist index 31cfc79cd..253725c41 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 97 - LprojLocale - ru - LprojRevisionLevel - 1 - LprojVersion - 97 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + ru + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/designable.nib index 0e33a8ced..97e1506f3 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/designable.nib @@ -1,3584 +1,3758 @@ - - - - 1040 - 11A79a - 732 - 1059 - 478.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 732 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - О программе X11 - - 2147483647 - - - - - - ÐаÑтройки… - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Службы - - 1048576 - 2147483647 - - - submenuAction: - - Службы - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Переключение полноÑкранного режима - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Скрыть X11 - h - 1048576 - 2147483647 - - - 42 - - - - Скрыть оÑтальные - h - 1572864 - 2147483647 - - - - - - Показать вÑе - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Завершить X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Программы - - 1048576 - 2147483647 - - - submenuAction: - - Программы - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ÐаÑтроить… - - 1048576 - 2147483647 - - - - - - - - - Правка - - 1048576 - 2147483647 - - - submenuAction: - - Правка - - - - Копировать - c - 1048576 - 2147483647 - - - - - - - - - Окно - - 1048576 - 2147483647 - - - submenuAction: - - Окно - - - - Закрыть - w - 1048576 - 2147483647 - - - - - - Убрать в Dock - m - 1048576 - 2147483647 - - - - - - Изменить маÑштаб - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Круговое переключение окон - ` - 1048576 - 2147483647 - - - - - - Обратное круговое переключение окон - ` - 1179648 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Ð’Ñе окна - на передний план - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Справка - - 1048576 - 2147483647 - - - submenuAction: - - Справка - - - - Справка X11 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{266, 364}, {604, 308}} - 1350041600 - ÐаÑтройки X11 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {578, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{44, 210}, {402, 18}} - - YES - - 67239424 - 0 - Эмулировать трехкнопочную мышь - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{62, 49}, {474, 42}} - - YES - - 67239424 - 4194304 - ЕÑли включено, Ñквиваленты клавиш Ñтроки меню могут переÑекатьÑÑ Ñ Ñквивалентами в программах X11, иÑпользующих мета-модификатор. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{62, 172}, {452, 32}} - - YES - - 67239424 - 4194304 - 0KPQtNC10YDQttC40LLQsNC50YLQtSDQvdCw0LbQsNGC0YvQvNC4INC60L3QvtC/0LrQuCBPcHRpb24g -0LjQu9C4IENvbW1hbmQg0L/RgNC4INCw0LrRgtC40LLQsNGG0LjQuCDRgdGA0LXQtNC90LXQuSDQuNC7 -0Lgg0L/RgNCw0LLQvtC5INC60L3QvtC/0L7QuiDQvNGL0YjQuC4KA - - - - - - - - - - 256 - {{44, 97}, {402, 18}} - - YES - - 67239424 - 0 - Включить Ñквиваленты клавиш в X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{62, 121}, {452, 21}} - - YES - - 67239424 - 4194304 - Разрешать Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¼ÐµÐ½ÑŽ ввода Ð´Ð»Ñ Ð¿ÐµÑ€ÐµÐ·Ð°Ð¿Ð¸Ñи текущей X11-карты ключей. - - - - - - - - - - 256 - {{44, 148}, {402, 18}} - - YES - - 67239424 - 0 - Следовать ÑиÑтемной раÑкладке клавиатуры - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{62, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - ЕÑли включено, клавиши Option отправлÑÑŽÑ‚ Ñимволы X11 клавиш Alt_L и Alt_R X11, вмеÑто Mode_switch. - - - - - - - - - 256 - {{44, 36}, {402, 18}} - - YES - - 67239424 - 0 - Клавиши Option отправлÑÑŽÑ‚ Alt_L и Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {558, 246}} - - - Вход - - - - - - 2 - - - - 256 - - - - 256 - {{23, 70}, {402, 18}} - - YES - - 67239424 - 0 - ИÑпользовать ÑиÑтемный Ñффект предупреждений - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{41, 31}, {494, 33}} - - YES - - 67239424 - 4194304 - Звуковые Ñигналы X11 будут иÑпользовать Ñтандартные ÑиÑтемные предупреждениÑ, как Ñто определено в панели «Звуковые Ñффекты» СиÑтемных наÑтроек. - - - - - - - - - - 256 - {{70, 201}, {132, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - С Ñкрана - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 цветов - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - ТыÑÑчи - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Миллионы - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{22, 205}, {52, 20}} - - YES - - 67239424 - 4194304 - Цвета: - - - - - - - - - - 256 - {{41, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Этот параметр вÑтупит в Ñилу при Ñледующем запуÑке X11. - - - - - - - - - - 256 - {{23, 150}, {409, 23}} - - YES - - 67239424 - 0 - ПолноÑкранный режим - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{42, 92}, {470, 18}} - - YES - - 67239424 - 0 - ÐвтоматичеÑки показывать Ñтроку меню в полноÑкранном режиме - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{41, 116}, {494, 28}} - - YES - - 67239424 - 4194304 - Включает корневое окно X11. ИÑпользуйте Ñочетание клавиш «Command-Option-A» Ð´Ð»Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¸ Ð²Ñ‹ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¿Ð¾Ð»Ð½Ð¾Ñкранного режима. - - - - - - - - - {{10, 33}, {558, 246}} - - Выход - - - - - - 2 - - - - 256 - - - - 256 - {{5, 222}, {409, 23}} - - YES - - 67239424 - 0 - Включить Ñинхронизацию - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 188}, {513, 28}} - - YES - - 67239424 - 4194304 - Включает объект меню «Копировать» и разрешает Ñинхронизацию между буфером обмена OS X и буферами X11 CLIPBOARD/PRIMARY. - - - - - - - - - 256 - {{21, 96}, {409, 23}} - - YES - - 67239424 - 0 - ОбновлÑÑ‚ÑŒ CLIPBOARD при изменениÑÑ… в буфере обмена - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{21, 74}, {532, 18}} - - YES - - 67239424 - 0 - ОбновлÑÑ‚ÑŒ PRIMARY (ÑреднÑÑ ÐºÐ½Ð¾Ð¿ÐºÐ° мыши) при изменениÑÑ… в буфере обмена - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{21, 52}, {414, 18}} - - YES - - 67239424 - 0 - ОбновлÑÑ‚ÑŒ буфер обмена Ñразу поÑле выбора нового текÑта - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{21, 159}, {409, 23}} - - YES - - 67239424 - 0 - ОбновлÑÑ‚ÑŒ буфер обмена при изменениÑÑ… в CLIPBOARD - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{35, 125}, {501, 28}} - - YES - - 67239424 - 4194304 - Отключите Ñтот параметр, еÑли хотите иÑпользовать xclipboard, klipper или иную другую программу-менеджер буфера обмена X11. - - - - - - - - - 256 - {{35, 18}, {501, 28}} - - YES - - 67239424 - 4194304 - Ð’ ÑвÑзи Ñ Ð¾Ð³Ñ€Ð°Ð½Ð¸Ñ‡ÐµÐ½Ð¸Ñми в протоколе X11 Ñтот параметр, возможно, в некоторых программах иногда работать не будет. - - - - - - - - {{10, 33}, {558, 246}} - - Буфер обмена - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Сквозное нажатие неактивных окон - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {500, 31}} - - YES - - 67239424 - 4194304 - ЕÑли включено, нажатие неактивного окна повлечет за Ñобой не только его активацию, но и Ñквозное прохождение мыши к Ñтому окну. - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Ð¤Ð¾ÐºÑƒÑ Ñледует за мышью - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 117}, {500, 28}} - - YES - - 67239424 - 4194304 - Ð¤Ð¾ÐºÑƒÑ Ð¾ÐºÐ½Ð° X11 Ñледует за движением курÑора, что имеет некоторые отрицательные поÑледÑтвиÑ. - - - - - - - - - 256 - {{15, 93}, {402, 18}} - - YES - - 67239424 - 0 - Ð¤Ð¾ÐºÑƒÑ â€“ на новые окна - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 54}, {500, 33}} - - YES - - 67239424 - 4194304 - ЕÑли включено, Ñоздание нового окна X11 повлечет за Ñобой перемещение на передний план X11.app (вмеÑто Finder.app, Terminal.app и Ñ‚.д.) - - - - - - - - {{10, 33}, {558, 246}} - - Окна - - - - - - - 256 - - - - 256 - {{26, 210}, {402, 18}} - - YES - - 67239424 - 0 - ПроверÑÑ‚ÑŒ идентификации подключений - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{26, 128}, {402, 18}} - - YES - - 67239424 - 0 - Разрешать Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¸Ð· клиентÑких Ñетей - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{44, 157}, {481, 47}} - - YES - - 67239424 - 4194304 - ЗапуÑк X11 ÑоздаÑÑ‚ ключи доÑтупа-ÐºÐ¾Ð½Ñ‚Ñ€Ð¾Ð»Ñ Xauthority. ЕÑли ÑиÑтемный IP-Ð°Ð´Ñ€ÐµÑ Ð¸Ð·Ð¼ÐµÐ½ÑетÑÑ, Ñти ключи ÑтановÑÑ‚ÑÑ Ð½ÐµÐ´ÐµÐ¹Ñтвительными, что может препÑÑ‚Ñтвовать запуÑку программ X11. - - - - - - - - - - 256 - {{44, 74}, {481, 48}} - - YES - - 67239424 - 4194304 - ЕÑли включено, проверка идентификации подключений должна быть также включена Ð´Ð»Ñ Ð³Ð°Ñ€Ð°Ð½Ñ‚Ð¸Ð¸ работы ÑиÑтемы безопаÑноÑти. ЕÑли выключено, Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¸Ð· удаленных программ недоÑтупны. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Эти параметры вÑтупÑÑ‚ в Ñилу при Ñледующем запуÑке X11. - - - - - - - - - {{10, 33}, {558, 246}} - - БезопаÑноÑÑ‚ÑŒ - - - - - - - 0 - YES - YES - - - - - - {604, 308} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {504, 271}} - 1350041600 - Программное меню X11 - NSPanel - - View - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{380, 191}, {118, 32}} - - YES - - 67239424 - 137887744 - Дублировать - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{380, 159}, {118, 32}} - - YES - - 67239424 - 137887744 - Удалить - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {351, 198} - - YES - - - 256 - {351, 17} - - - - - - 256 - {{352, 0}, {16, 17}} - - - - - 138.73101806640625 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Ð˜Ð¼Ñ - - - 3 - MC4zMzMzMzI5OQA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 116 - 40 - 1000 - - 75628096 - 2048 - Команда - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - 86.999969482421875 - 10 - 1000 - - 75628096 - 2048 - Соч. кл. - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {351, 198}} - - - - - 4 - - - - 256 - {{352, 17}, {15, 198}} - - - _doScroller: - 0.99492380000000002 - - - - 256 - {{1, 215}, {351, 15}} - - 1 - - _doScroller: - 0.68852460000000004 - - - - 2304 - - - - {{1, 0}, {351, 17}} - - - - - 4 - - - - {{10, 20}, {368, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{380, 223}, {118, 32}} - - YES - - -2080244224 - 137887744 - Доб. объект - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {504, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Меню - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Программы - - 1048576 - 2147483647 - - - submenuAction: - - Программы - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - ÐаÑтроить… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {604, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{507, 548}, {604, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + О программе X11 + + 2147483647 + + + + + + ÐаÑтройки… + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Службы + + 1048576 + 2147483647 + + + submenuAction: + + Службы + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Переключение полноÑкранного режима + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Скрыть X11 + h + 1048576 + 2147483647 + + + 42 + + + + Скрыть оÑтальные + h + 1572864 + 2147483647 + + + + + + Показать вÑе + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Завершить X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Программы + + 1048576 + 2147483647 + + + submenuAction: + + Программы + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ÐаÑтроить… + + 1048576 + 2147483647 + + + + + + + + + Правка + + 1048576 + 2147483647 + + + submenuAction: + + Правка + + + + Копировать + c + 1048576 + 2147483647 + + + + + + + + + Окно + + 1048576 + 2147483647 + + + submenuAction: + + Окно + + + + Закрыть + w + 1048576 + 2147483647 + + + + + + Убрать в Dock + m + 1048576 + 2147483647 + + + + + + Изменить маÑштаб + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Круговое переключение окон + ` + 1048576 + 2147483647 + + + + + + Обратное круговое переключение окон + ` + 1179648 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Ð’Ñе окна — на передний план + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Справка + + 1048576 + 2147483647 + + + submenuAction: + + Справка + + + + Справка X11 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{266, 364}, {604, 308}} + 1350041600 + ÐаÑтройки X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {578, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{44, 210}, {402, 18}} + + YES + + 67239424 + 0 + Эмулировать трехкнопочную мышь + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{62, 49}, {474, 42}} + + YES + + 67239424 + 4194304 + ЕÑли включено, Ñквиваленты клавиш Ñтроки меню могут переÑекатьÑÑ Ñ Ñквивалентами в программах X11, иÑпользующих мета-модификатор. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{62, 172}, {452, 32}} + + YES + + 67239424 + 4194304 + 0KPQtNC10YDQttC40LLQsNC50YLQtSDQvdCw0LbQsNGC0YvQvNC4INC60L3QvtC/0LrQuCBPcHRpb24g +0LjQu9C4IENvbW1hbmQg0L/RgNC4INCw0LrRgtC40LLQsNGG0LjQuCDRgdGA0LXQtNC90LXQuSDQuNC7 +0Lgg0L/RgNCw0LLQvtC5INC60L3QvtC/0L7QuiDQvNGL0YjQuC4KA + + + + + + + + + + 256 + {{44, 97}, {402, 18}} + + YES + + 67239424 + 0 + Включить Ñквиваленты клавиш в X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{62, 121}, {452, 21}} + + YES + + 67239424 + 4194304 + Разрешать Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¼ÐµÐ½ÑŽ ввода Ð´Ð»Ñ Ð¿ÐµÑ€ÐµÐ·Ð°Ð¿Ð¸Ñи текущей X11-карты ключей. + + + + + + + + + + 256 + {{44, 148}, {402, 18}} + + YES + + 67239424 + 0 + Следовать ÑиÑтемной раÑкладке клавиатуры + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{62, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + ЕÑли включено, клавиши Option отправлÑÑŽÑ‚ Ñимволы X11 клавиш Alt_L и Alt_R X11, вмеÑто Mode_switch. + + + + + + + + + 256 + {{44, 36}, {402, 18}} + + YES + + 67239424 + 0 + Клавиши Option отправлÑÑŽÑ‚ Alt_L и Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {558, 246}} + + Вход + + + + + + 2 + + + + 256 + + + + 256 + {{70, 201}, {132, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + С Ñкрана + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 цветов + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + ТыÑÑчи + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Миллионы + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{22, 205}, {52, 20}} + + YES + + 67239424 + 4194304 + Цвета: + + + + + + + + + + 256 + {{41, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Этот параметр вÑтупит в Ñилу при Ñледующем запуÑке X11. + + + + + + + + + + 256 + {{23, 150}, {409, 23}} + + YES + + 67239424 + 0 + ПолноÑкранный режим + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{42, 92}, {470, 18}} + + YES + + 67239424 + 0 + ÐвтоматичеÑки показывать Ñтроку меню в полноÑкранном режиме + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{41, 116}, {494, 28}} + + YES + + 67239424 + 4194304 + Включает корневое окно X11. ИÑпользуйте Ñочетание клавиш «Command-Option-A» Ð´Ð»Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¸ Ð²Ñ‹ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¿Ð¾Ð»Ð½Ð¾Ñкранного режима. + + + + + + + + + {{10, 33}, {558, 246}} + + + Выход + + + + + + 2 + + + + 256 + + + + 256 + {{5, 222}, {409, 23}} + + YES + + 67239424 + 0 + Включить Ñинхронизацию + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 188}, {513, 28}} + + YES + + 67239424 + 4194304 + Включает объект меню «Копировать» и разрешает Ñинхронизацию между буфером обмена OS X и буферами X11 CLIPBOARD/PRIMARY. + + + + + + + + + 256 + {{21, 96}, {409, 23}} + + YES + + 67239424 + 0 + ОбновлÑÑ‚ÑŒ CLIPBOARD при изменениÑÑ… в буфере обмена + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{21, 74}, {532, 18}} + + YES + + 67239424 + 0 + ОбновлÑÑ‚ÑŒ PRIMARY (ÑреднÑÑ ÐºÐ½Ð¾Ð¿ÐºÐ° мыши) при изменениÑÑ… в буфере обмена + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{21, 52}, {414, 18}} + + YES + + 67239424 + 0 + ОбновлÑÑ‚ÑŒ буфер обмена Ñразу поÑле выбора нового текÑта + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{21, 159}, {409, 23}} + + YES + + 67239424 + 0 + ОбновлÑÑ‚ÑŒ буфер обмена при изменениÑÑ… в CLIPBOARD + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{35, 125}, {501, 28}} + + YES + + 67239424 + 4194304 + Отключите Ñтот параметр, еÑли хотите иÑпользовать xclipboard, klipper или иную другую программу-менеджер буфера обмена X11. + + + + + + + + + 256 + {{35, 18}, {501, 28}} + + YES + + 67239424 + 4194304 + Ð’ ÑвÑзи Ñ Ð¾Ð³Ñ€Ð°Ð½Ð¸Ñ‡ÐµÐ½Ð¸Ñми в протоколе X11 Ñтот параметр, возможно, в некоторых программах иногда работать не будет. + + + + + + + + {{10, 33}, {558, 246}} + + Буфер обмена + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Сквозное нажатие неактивных окон + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {500, 31}} + + YES + + 67239424 + 4194304 + ЕÑли включено, нажатие неактивного окна повлечет за Ñобой не только его активацию, но и Ñквозное прохождение мыши к Ñтому окну. + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Ð¤Ð¾ÐºÑƒÑ Ñледует за мышью + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 117}, {500, 28}} + + YES + + 67239424 + 4194304 + Ð¤Ð¾ÐºÑƒÑ Ð¾ÐºÐ½Ð° X11 Ñледует за движением курÑора, что имеет некоторые отрицательные поÑледÑтвиÑ. + + + + + + + + + 256 + {{15, 93}, {402, 18}} + + YES + + 67239424 + 0 + Ð¤Ð¾ÐºÑƒÑ â€“ на новые окна + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 54}, {500, 33}} + + YES + + 67239424 + 4194304 + ЕÑли включено, Ñоздание нового окна X11 повлечет за Ñобой перемещение на передний план X11.app (вмеÑто Finder.app, Terminal.app и Ñ‚. д.) + + + + + + + + {{10, 33}, {558, 246}} + + Окна + + + + + + + 256 + + + + 256 + {{26, 210}, {402, 18}} + + YES + + 67239424 + 0 + ПроверÑÑ‚ÑŒ аутентификации подключений + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{26, 128}, {402, 18}} + + YES + + 67239424 + 0 + Разрешать Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¸Ð· клиентÑких Ñетей + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{44, 157}, {481, 47}} + + YES + + 67239424 + 4194304 + ЗапуÑк X11 ÑоздаÑÑ‚ ключи доÑтупа-ÐºÐ¾Ð½Ñ‚Ñ€Ð¾Ð»Ñ Xauthority. ЕÑли ÑиÑтемный IP-Ð°Ð´Ñ€ÐµÑ Ð¸Ð·Ð¼ÐµÐ½ÑетÑÑ, Ñти ключи ÑтановÑÑ‚ÑÑ Ð½ÐµÐ´ÐµÐ¹Ñтвительными, что может препÑÑ‚Ñтвовать запуÑку программ X11. + + + + + + + + + + 256 + {{44, 74}, {481, 48}} + + YES + + 67239424 + 4194304 + ЕÑли включено, проверка аутентификации подключений должна быть также включена Ð´Ð»Ñ Ð³Ð°Ñ€Ð°Ð½Ñ‚Ð¸Ð¸ работы ÑиÑтемы безопаÑноÑти. ЕÑли выключено, Ð¿Ð¾Ð´ÐºÐ»ÑŽÑ‡ÐµÐ½Ð¸Ñ Ð¸Ð· удаленных программ недоÑтупны. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Эти параметры вÑтупÑÑ‚ в Ñилу при Ñледующем запуÑке X11. + + + + + + + + + {{10, 33}, {558, 246}} + + БезопаÑноÑÑ‚ÑŒ + + + + + + + 0 + YES + YES + + + + + + {604, 308} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {504, 271}} + 1350041600 + Программное меню X11 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{380, 191}, {118, 32}} + + YES + + 67239424 + 137887744 + Дублировать + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{380, 159}, {118, 32}} + + YES + + 67239424 + 137887744 + Удалить + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {351, 198} + + YES + + + 256 + {351, 17} + + + + + + 256 + {{352, 0}, {16, 17}} + + + + + 138.73101806640625 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Ð˜Ð¼Ñ + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 116 + 40 + 1000 + + 75628096 + 2048 + Команда + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + 86.999969482421875 + 10 + 1000 + + 75628096 + 2048 + Соч. кл. + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {351, 198}} + + + + + 4 + + + + 256 + {{352, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {351, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {351, 17}} + + + + + 4 + + + + {{10, 20}, {368, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{380, 223}, {118, 32}} + + YES + + -2080244224 + 137887744 + Доб. объект + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {504, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Меню + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Программы + + 1048576 + 2147483647 + + + submenuAction: + + Программы + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + ÐаÑтроить… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/keyedobjects.nib index 9c5cc85e7..4d441f7ef 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/ru.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/locversion.plist index b86ec7136..ad63d54e4 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 99 - LprojLocale - sv - LprojRevisionLevel - 1 - LprojVersion - 99 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + sv + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/designable.nib index 16b01eb79..715848e35 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/designable.nib @@ -1,3597 +1,3764 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - Om X11 - - 2147483647 - - - - - - Inställningar... - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Tjänster - - 1048576 - 2147483647 - - - submenuAction: - - Tjänster - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Växla helskärmsläge - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Göm X11 - h - 1048576 - 2147483647 - - - 42 - - - - Göm övriga - h - 1572864 - 2147483647 - - - - - - Visa alla - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Avsluta X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - Program - - 1048576 - 2147483647 - - - submenuAction: - - Program - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Anpassa... - - 1048576 - 2147483647 - - - - - - - - - Redigera - - 1048576 - 2147483647 - - - submenuAction: - - Redigera - - - - Kopiera - c - 1048576 - 2147483647 - - - - - - - - - Fönster - - 1048576 - 2147483647 - - - submenuAction: - - Fönster - - - - Stäng - w - 1048576 - 2147483647 - - - - - - Minimera - m - 1048576 - 2147483647 - - - - - - Zooma - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Bläddra genom fönster - < - 1048576 - 2147483647 - - - - - - Bläddra genom fönster baklänges - > - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Lägg alla överst - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - Hjälp - - 1048576 - 2147483647 - - - submenuAction: - - Hjälp - - - - X11 Hjälp - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{288, 302}, {484, 308}} - 1350041600 - X11-inställningar - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Emulera treknappsmus - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 56}, {385, 31}} - - YES - - 67239424 - 4194304 - Om de är aktiverade kan tangenter som motsvarar menyraden hamna i konflikt med X11-program som använder metamodifieraren. - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 164}, {385, 42}} - - YES - - 67239424 - 4194304 - SMOlbGwgbmVkIGFsdGVybmF0aXYtIGVsbGVyIGtvbW1hbmRvdGFuZ2VudGVuIG7DpHIgZHUga2xpY2th -ciBzw6UgYWt0aXZlcmFzIG11c2VucyBtaXR0LSByZXNwZWt0aXZlIGjDtmdlcmtuYXBwLgo - - - - - - - - - - 256 - {{18, 91}, {402, 18}} - - YES - - 67239424 - 0 - Aktivera tangentmotsvarigheter i X11 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 116}, {400, 29}} - - YES - - 67239424 - 4194304 - TillÃ¥ter att ändringar i inmatningsmenyn skriver över de befintliga X11-tangentkopplingarna. - - - - - - - - - - 256 - {{18, 149}, {402, 18}} - - YES - - 67239424 - 0 - Följ datorns tangentbordslayout - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 1}, {385, 31}} - - YES - - 67239424 - 4194304 - När aktiverad kommer alt-tangenterna att skicka tangentsymboler Alt_L och Alt_R X11 istället för Mode_switch. - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 0 - Alt-tangenter sänder Alt_L och Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - Indata - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - Använd systemets varningseffekt - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {385, 28}} - - YES - - 67239424 - 4194304 - X11-ljudet blir det vanliga systemvarningsljudet som valts pÃ¥ inställningspanelen Ljudeffekter i Systeminställningar. - - - - - - - - - - 256 - {{74, 202}, {154, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - FrÃ¥n bildskärm - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 färger - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - Tusentals - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - Miljontals - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {55, 20}} - - YES - - 67239424 - 4194304 - Färger: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - Alternativet börjar gälla nästa gÃ¥ng X11 öppnas. - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - Helskärmsläge - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {409, 23}} - - YES - - 67239424 - 0 - Visa menyfältet automatiskt i helskärmsläge - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 112}, {385, 31}} - - YES - - 67239424 - 4194304 - Aktiverar X11:s rotfönster. Tryck ned kommando-alt-A för att växla till och frÃ¥n helskärmsläge. - - - - - - - - - {{10, 33}, {438, 246}} - - Utdata - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - Aktivera synkronisering - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {397, 28}} - - YES - - 67239424 - 4194304 - Aktiverar menyalternativet â€Kopiera†och gör det möjligt att synkronisera mellan urklipp i OSX och CLIPBOARD- och PRIMARY-buffertarna i X11. - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - Uppdatera CLIPBOARD när urklipp ändras - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {409, 23}} - - YES - - 67239424 - 0 - Uppdatera PRIMARY (mellanklick) när urklipp ändras - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 46}, {409, 23}} - - YES - - 67239424 - 0 - Uppdatera urklipp sÃ¥ snart ny text markeras - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - Uppdatera urklipp när CLIPBOARD ändras - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {385, 28}} - - YES - - 67239424 - 4194304 - Avaktivera det här alternativet om du vill använda xclipboard, klipper, eller nÃ¥gon annan urklippshanterare i X11. - - - - - - - - - 256 - {{48, 14}, {370, 28}} - - YES - - 67239424 - 4194304 - PÃ¥ grund av begränsningar i X11-protokollet kanske det här alternativet inte fungerar i vissa program. - - - - - - - - {{10, 33}, {438, 246}} - - Urklipp - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - Klicka igenom inaktiva fönster - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{32, 175}, {385, 31}} - - YES - - 67239424 - 4194304 - TWVkIGRldCBow6RyIGFsdGVybmF0aXZldCBrb21tZXIgZXR0IGtsaWNrIHDDpSBldHQgaW5ha3RpdnQg -ZsO2bnN0ZXIgYsOlZGUgYWt0aXZlcmEgZsO2bnN0cmV0IG9jaCBsw6V0YSBtdXNrbGlja2V0IHDDpXZl -cmthIGlubmVow6VsbGV0Lgo - - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - Fokus följer mus - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{32, 128}, {385, 17}} - - YES - - 67239424 - 4194304 - Fönsterfokus i X11 följer pekaren. Det här har nÃ¥gra bieffekter. - - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - Fokus pÃ¥ nya fönster - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{32, 73}, {385, 28}} - - YES - - 67239424 - 4194304 - Med det här alternativet kommer skapandet av ett nytt X11-fönster att lägga X11 överst (istället för Finder, Terminal, etc.) - - - - - - - - - {{10, 33}, {438, 246}} - - Fönster - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - Autentisera anslutningar - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - TillÃ¥t anslutningar frÃ¥n nätverksklienter - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {385, 42}} - - YES - - 67239424 - 4194304 - När du öppnar X11 skapas Xauthority-nycklar som kontrollerar Ã¥tkomst. Om datorns IP-adress ändras blir nycklarna ogiltiga vilket kan förhindra att X11-program öppnas. - - - - - - - - - - 256 - {{36, 85}, {385, 42}} - - YES - - 67239424 - 4194304 - Om det är aktiverat mÃ¥ste Autentisera anslutningar ocksÃ¥ vara aktiverat för att säkerställa säkerheten i systemet. Om det är avaktiverat tillÃ¥ts inte anslutningar frÃ¥n fjärrprogram. - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - Alternativen börjar gälla nästa gÃ¥ng X11 öppnas. - - - - - - - - - {{10, 33}, {438, 246}} - - Säkerhet - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{302, 440}, {496, 271}} - 1350041600 - X11 Programmeny - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {142, 32}} - - YES - - 67239424 - 137887744 - Duplicera - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {142, 32}} - - YES - - 67239424 - 137887744 - Ta bort - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 122.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - Namn - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - - 100 - 40 - 1000 - - 75628096 - 2048 - Kommando - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - - 69 - 10 - 1000 - - 75628096 - 2048 - Kortkom. - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {142, 32}} - - YES - - -2080244224 - 137887744 - Lägg till objekt - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {496, 271} - - {{0, 0}, {1440, 878}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - Meny - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Program - - 1048576 - 2147483647 - - - submenuAction: - - Program - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - Anpassa… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 548}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {496, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {496, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + Om X11 + + 2147483647 + + + + + + Inställningar... + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Tjänster + + 1048576 + 2147483647 + + + submenuAction: + + Tjänster + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Växla helskärmsläge + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Göm X11 + h + 1048576 + 2147483647 + + + 42 + + + + Göm övriga + h + 1572864 + 2147483647 + + + + + + Visa alla + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Avsluta X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + Program + + 1048576 + 2147483647 + + + submenuAction: + + Program + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Anpassa... + + 1048576 + 2147483647 + + + + + + + + + Redigera + + 1048576 + 2147483647 + + + submenuAction: + + Redigera + + + + Kopiera + c + 1048576 + 2147483647 + + + + + + + + + Fönster + + 1048576 + 2147483647 + + + submenuAction: + + Fönster + + + + Stäng + w + 1048576 + 2147483647 + + + + + + Minimera + m + 1048576 + 2147483647 + + + + + + Zooma + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Bläddra genom fönster + < + 1048576 + 2147483647 + + + + + + Bläddra genom fönster baklänges + > + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Lägg alla överst + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Hjälp + + 1048576 + 2147483647 + + + submenuAction: + + Hjälp + + + + X11 Hjälp + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{288, 302}, {484, 308}} + 1350041600 + X11-inställningar + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Emulera treknappsmus + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 56}, {385, 31}} + + YES + + 67239424 + 4194304 + Om de är aktiverade kan tangenter som motsvarar menyraden hamna i konflikt med X11-program som använder metamodifieraren. + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 164}, {385, 42}} + + YES + + 67239424 + 4194304 + SMOlbGwgbmVkIGFsdGVybmF0aXYtIGVsbGVyIGtvbW1hbmRvdGFuZ2VudGVuIG7DpHIgZHUga2xpY2th +ciBzw6UgYWt0aXZlcmFzIG11c2VucyBtaXR0LSByZXNwZWt0aXZlIGjDtmdlcmtuYXBwLgo + + + + + + + + + + 256 + {{18, 91}, {402, 18}} + + YES + + 67239424 + 0 + Aktivera tangentmotsvarigheter i X11 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 116}, {400, 29}} + + YES + + 67239424 + 4194304 + TillÃ¥ter att ändringar i inmatningsmenyn skriver över de befintliga X11-tangentkopplingarna. + + + + + + + + + + 256 + {{18, 149}, {402, 18}} + + YES + + 67239424 + 0 + Följ datorns tangentbordslayout + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 1}, {385, 31}} + + YES + + 67239424 + 4194304 + När aktiverad kommer alt-tangenterna att skicka tangentsymboler Alt_L och Alt_R X11 istället för Mode_switch. + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Alt-tangenter sänder Alt_L och Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + Indata + + + + + + 2 + + + + 256 + + + + 256 + {{74, 202}, {154, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + FrÃ¥n bildskärm + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 färger + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + Tusentals + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + Miljontals + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {55, 20}} + + YES + + 67239424 + 4194304 + Färger: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + Alternativet börjar gälla nästa gÃ¥ng X11 öppnas. + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + Helskärmsläge + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {409, 23}} + + YES + + 67239424 + 0 + Visa menyfältet automatiskt i helskärmsläge + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 112}, {385, 31}} + + YES + + 67239424 + 4194304 + Aktiverar X11:s rotfönster. Tryck ned kommando-alt-A för att växla till och frÃ¥n helskärmsläge. + + + + + + + + + {{10, 33}, {438, 246}} + + + Utdata + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + Aktivera synkronisering + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {397, 28}} + + YES + + 67239424 + 4194304 + Aktiverar menyalternativet â€Kopiera†och gör det möjligt att synkronisera mellan urklipp i OSX och CLIPBOARD- och PRIMARY-buffertarna i X11. + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + Uppdatera CLIPBOARD när urklipp ändras + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {409, 23}} + + YES + + 67239424 + 0 + Uppdatera PRIMARY (mellanklick) när urklipp ändras + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 46}, {409, 23}} + + YES + + 67239424 + 0 + Uppdatera urklipp sÃ¥ snart ny text markeras + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + Uppdatera urklipp när CLIPBOARD ändras + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {385, 28}} + + YES + + 67239424 + 4194304 + Avaktivera det här alternativet om du vill använda xclipboard, klipper, eller nÃ¥gon annan urklippshanterare i X11. + + + + + + + + + 256 + {{48, 14}, {370, 28}} + + YES + + 67239424 + 4194304 + PÃ¥ grund av begränsningar i X11-protokollet kanske det här alternativet inte fungerar i vissa program. + + + + + + + + {{10, 33}, {438, 246}} + + Urklipp + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + Klicka igenom inaktiva fönster + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{32, 175}, {385, 31}} + + YES + + 67239424 + 4194304 + Med det här alternativet kommer ett klick pÃ¥ ett inaktivt fönster bÃ¥de aktivera fönstret och lÃ¥ta musklicket pÃ¥verka innehÃ¥llet. + + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + Fokus följer mus + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{32, 128}, {385, 17}} + + YES + + 67239424 + 4194304 + Fönsterfokus i X11 följer pekaren. Det här har nÃ¥gra bieffekter. + + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + Fokus pÃ¥ nya fönster + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{32, 73}, {385, 28}} + + YES + + 67239424 + 4194304 + Med det här alternativet kommer skapandet av ett nytt X11-fönster att lägga X11 överst (istället för Finder, Terminal, etc.) + + + + + + + + + {{10, 33}, {438, 246}} + + Fönster + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + Autentisera anslutningar + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + TillÃ¥t anslutningar frÃ¥n nätverksklienter + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + När du öppnar X11 skapas Xauthority-nycklar som kontrollerar Ã¥tkomst. Om datorns IP-adress ändras blir nycklarna ogiltiga vilket kan förhindra att X11-program öppnas. + + + + + + + + + + 256 + {{36, 85}, {385, 42}} + + YES + + 67239424 + 4194304 + Om det är aktiverat mÃ¥ste Autentisera anslutningar ocksÃ¥ vara aktiverat för att säkerställa säkerheten i systemet. Om det är avaktiverat tillÃ¥ts inte anslutningar frÃ¥n fjärrprogram. + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + Alternativen börjar gälla nästa gÃ¥ng X11 öppnas. + + + + + + + + + {{10, 33}, {438, 246}} + + Säkerhet + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{302, 440}, {496, 271}} + 1350041600 + X11 Programmeny + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {142, 32}} + + YES + + 67239424 + 137887744 + Duplicera + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {142, 32}} + + YES + + 67239424 + 137887744 + Ta bort + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 122.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + Namn + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + + 100 + 40 + 1000 + + 75628096 + 2048 + Kommando + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + + 69 + 10 + 1000 + + 75628096 + 2048 + Kortkom. + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {142, 32}} + + YES + + -2080244224 + 137887744 + Lägg till objekt + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {496, 271} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + Meny + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Program + + 1048576 + 2147483647 + + + submenuAction: + + Program + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Anpassa… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/keyedobjects.nib index 5b17831b9..3087e65ce 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/sv.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/Localizable.strings b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/Localizable.strings index 7706fe541..042f9483a 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/Localizable.strings and b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/Localizable.strings differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/locversion.plist index 294731779..47c52a9f8 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 99 - LprojLocale - zh_CN - LprojRevisionLevel - 1 - LprojVersion - 99 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + zh_CN + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/designable.nib index 423872f15..4ed57f3ab 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/designable.nib @@ -1,3597 +1,3517 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - 关于 X11 - - 2147483647 - - - - - - å好设置… - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - æœåŠ¡ - - 1048576 - 2147483647 - - - submenuAction: - - æœåŠ¡ - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 开关全å±å¹• - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - éšè— X11 - h - 1048576 - 2147483647 - - - 42 - - - - éšè—其他 - h - 1572864 - 2147483647 - - - - - - 全部显示 - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 退出 X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - åº”ç”¨ç¨‹åº - - 1048576 - 2147483647 - - - submenuAction: - - åº”ç”¨ç¨‹åº - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 自定… - - 1048576 - 2147483647 - - - - - - - - - 编辑 - - 1048576 - 2147483647 - - - submenuAction: - - 编辑 - - - - æ‹·è´ - c - 1048576 - 2147483647 - - - - - - - - - çª—å£ - - 1048576 - 2147483647 - - - submenuAction: - - çª—å£ - - - - 关闭 - w - 1048576 - 2147483647 - - - - - - 最å°åŒ– - m - 1048576 - 2147483647 - - - - - - 缩放 - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - å¾ªçŽ¯æ˜¾ç¤ºçª—å£ - ` - 1048840 - 2147483647 - - - - - - åå‘å¾ªçŽ¯æ˜¾ç¤ºçª—å£ - ~ - 1179914 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - å‰ç½®å…¨éƒ¨çª—å£ - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - 帮助 - - 1048576 - 2147483647 - - - submenuAction: - - 帮助 - - - - X11 帮助 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{240, 335}, {484, 308}} - 1350041600 - X11 å好设置 - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - 模拟三按键鼠标 - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 45}, {385, 31}} - - YES - - 67239424 - 4194304 - å¯ç”¨æ—¶ï¼Œèœå•æ ç­‰æ•ˆé”®å¯èƒ½ä¼šå¹²æ‰°ä½¿ç”¨å…ƒä¿®é¥°é”®çš„ X11 应用程åºã€‚ - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2NjY3AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 162}, {385, 42}} - - YES - - 67239424 - 4194304 - 6K+35oyJ5L2PIE9wdGlvbiDmiJYgQ29tbWFuZCDngrnmjInku6Xmv4DmtLvkuK3pl7TmiJblj7Povrnn -moTpvKDmoIfmjInplK7jgIIKA - - - - - - - - - - 256 - {{18, 82}, {402, 18}} - - YES - - 67239424 - 0 - 在 X11 环境下å¯ç”¨ç­‰æ•ˆé”® - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 126}, {385, 14}} - - YES - - 67239424 - 4194304 - å…许进行输入èœå•æ›´æ”¹ä»¥è¦†ç›–当å‰çš„ X11 键盘映射。 - - - - - - - - - - 256 - {{18, 146}, {402, 18}} - - YES - - 67239424 - 0 - ä¾ç…§ç³»ç»Ÿé”®ç›˜å¸ƒå±€ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, -1}, {385, 31}} - - YES - - 67239424 - 4194304 - 如果已å¯ç”¨ï¼Œåˆ™ Option 键会å‘é€ Alt_L å’Œ Alt_R X11 键符å·ï¼Œè€Œä¸æ˜¯å‘é€ Mode_switch。 - - - - - - - - - 256 - {{18, 36}, {402, 18}} - - YES - - 67239424 - 0 - Option 键会å‘é€ Alt_L å’Œ Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - 输入 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - 使用系统警报效果 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {405, 28}} - - YES - - 67239424 - 4194304 - X11 警笛将使用标准的系统警报,具体如“声音效果â€ç³»ç»Ÿå好设置é¢æ¿ä¸­æ‰€å®šä¹‰ã€‚ - - - - - - - - - - 256 - {{59, 202}, {128, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - 从显示器 - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 ç§é¢œè‰² - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - ä¸Šä¸‡ç§ - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - 上åƒä¸‡ç§ - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 206}, {43, 20}} - - YES - - 67239424 - 4194304 - 颜色: - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - 此选项会在å†æ¬¡å¼€å¯ X11 时生效。 - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - å…¨å±å¹•æ¨¡å¼ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {409, 23}} - - YES - - 67239424 - 0 - 以全å±å¹•æ¨¡å¼è‡ªåŠ¨æ˜¾ç¤ºèœå•æ  - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 112}, {405, 31}} - - YES - - 67239424 - 4194304 - å¯ç”¨ X11 根窗å£ã€‚使用 Command-Option-A 击键æ¥è¿›å…¥å’Œç¦»å¼€å…¨å±å¹•æ¨¡å¼ã€‚ - - - - - - - - - {{10, 33}, {438, 246}} - - 输出 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - å¯ç”¨åŒæ­¥ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {385, 28}} - - YES - - 67239424 - 4194304 - å¯ç”¨â€œæ‹·è´â€èœå•é¡¹å¹¶å…许 OSX“粘贴æ¿â€ä¸Ž X11 CLIPBOARD å’Œ PRIMARY 缓冲区之间åŒæ­¥ã€‚ - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - 粘贴æ¿æ”¹å˜æ—¶æ›´æ–° CLIPBOARD - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {409, 23}} - - YES - - 67239424 - 0 - 粘贴æ¿æ”¹å˜æ—¶æ›´æ–° PRIMARY(点按鼠标中间键) - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 46}, {409, 23}} - - YES - - 67239424 - 0 - 选定新文本时立å³æ›´æ–°ç²˜è´´æ¿ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - CLIPBOARD 改å˜æ—¶æ›´æ–°ç²˜è´´æ¿ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {385, 28}} - - YES - - 67239424 - 4194304 - 如果您想è¦ä½¿ç”¨ xclipboardã€klipper 或其他任何 X11 剪切æ¿ç®¡ç†ç¨‹åºï¼Œè¯·åœç”¨æ­¤é€‰é¡¹ã€‚ - - - - - - - - - 256 - {{48, 14}, {370, 28}} - - YES - - 67239424 - 4194304 - 由于 X11 å议中的é™åˆ¶ï¼Œæ­¤é€‰é¡¹åœ¨æŸäº›åº”用程åºä¸­å¯èƒ½æ— æ³•å·¥ä½œã€‚ - - - - - - - - {{10, 33}, {438, 246}} - - ç²˜è´´æ¿ - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - 点按å„个ä¸æ´»è·ƒçª—å£ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {385, 31}} - - YES - - 67239424 - 4194304 - å¯ç”¨æ—¶ï¼Œç‚¹æŒ‰ä¸æ´»è·ƒçª—å£ä¼šæ¿€æ´»çª—å£ï¼Œé™¤æ­¤ä»¥å¤–,还将导致鼠标点按传递到该窗å£ã€‚ - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - 焦点跟éšé¼ æ ‡ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 128}, {385, 17}} - - YES - - 67239424 - 4194304 - X11 窗å£ç„¦ç‚¹è·Ÿéšå…‰æ ‡ã€‚这会产生一些ä¸å¥½çš„效果。 - - - - - - - - - 256 - {{15, 107}, {402, 18}} - - YES - - 67239424 - 0 - èšç„¦æ–°çª—å£ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 73}, {385, 28}} - - YES - - 67239424 - 4194304 - å¯ç”¨æ—¶ï¼Œåˆ›å»ºæ–° X11 窗å£å°†å¯¼è‡´ X11.app 移到最å‰é¢ï¼ˆè€Œä¸æ˜¯ Finder.appã€ç»ˆç«¯.app 等应用程åºç§»åˆ°æœ€å‰é¢ï¼‰ã€‚ - - - - - - - - {{10, 33}, {438, 246}} - - çª—å£ - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - 鉴定连接 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - å…许从网络客户端连接 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 162}, {385, 42}} - - YES - - 67239424 - 4194304 - å¼€å¯ X11 将创建 Xauthority 访问控制按键。如果系统的 IP 地å€å·²æ›´æ”¹ï¼Œè¿™äº›æŒ‰é”®ä¼šå˜æˆæ— æ•ˆçš„,这å¯èƒ½ä¼šé˜»æ­¢ X11 应用程åºå¼€å¯ã€‚ - - - - - - - - - - 256 - {{36, 85}, {385, 42}} - - YES - - 67239424 - 4194304 - 如果已å¯ç”¨ï¼Œåˆ™å¿…须也å¯ç”¨é‰´å®šè¿žæŽ¥ä»¥ç¡®ä¿ç³»ç»Ÿå®‰å…¨ã€‚åœç”¨æ—¶ï¼Œä¸å…许远程应用程åºçš„连接。 - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - è¿™äº›é€‰é¡¹ä¼šåœ¨ä¸‹ä¸€æ¬¡å¼€å¯ X11 时生效。 - - - - - - - - - {{10, 33}, {438, 246}} - - 安全性 - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_prefs - - - 11 - 2 - {{279, 416}, {454, 271}} - 1350041600 - X11 应用程åºèœå• - NSPanel - - View - - - {1.7976931348623157e+308, 1.7976931348623157e+308} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {100, 32}} - - YES - - 67239424 - 137887744 - å¤åˆ¶ - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {100, 32}} - - YES - - 67239424 - 137887744 - 移除 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 121.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - å称 - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - - 99 - 40 - 1000 - - 75628096 - 2048 - 命令 - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - - 71 - 10 - 1000 - - 75628096 - 2048 - å¿«æ· - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {100, 32}} - - YES - - -2080244224 - 137887744 - 添加项 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - {{0, 0}, {1280, 938}} - {320, 262} - {1.7976931348623157e+308, 1.7976931348623157e+308} - x11_apps - - - èœå• - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - åº”ç”¨ç¨‹åº - - 1048576 - 2147483647 - - - submenuAction: - - åº”ç”¨ç¨‹åº - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 自定… - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 548}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + 关于 X11 + + 2147483647 + + + + + + å好设置… + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + æœåŠ¡ + + 1048576 + 2147483647 + + + submenuAction: + + æœåŠ¡ + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 开关全å±å¹• + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + éšè— X11 + h + 1048576 + 2147483647 + + + 42 + + + + éšè—其他 + h + 1572864 + 2147483647 + + + + + + 全部显示 + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 退出 X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + åº”ç”¨ç¨‹åº + + 1048576 + 2147483647 + + + submenuAction: + + åº”ç”¨ç¨‹åº + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 自定… + + 1048576 + 2147483647 + + + + + + + + + 编辑 + + 1048576 + 2147483647 + + + submenuAction: + + 编辑 + + + + æ‹·è´ + c + 1048576 + 2147483647 + + + + + + + + + çª—å£ + + 1048576 + 2147483647 + + + submenuAction: + + çª—å£ + + + + 关闭 + w + 1048576 + 2147483647 + + + + + + 最å°åŒ– + m + 1048576 + 2147483647 + + + + + + 缩放 + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + å¾ªçŽ¯æ˜¾ç¤ºçª—å£ + ` + 1048840 + 2147483647 + + + + + + åå‘å¾ªçŽ¯æ˜¾ç¤ºçª—å£ + ~ + 1179914 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + å‰ç½®å…¨éƒ¨çª—å£ + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + 帮助 + + 1048576 + 2147483647 + + + submenuAction: + + 帮助 + + + + X11 帮助 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{240, 335}, {484, 308}} + 1350041600 + X11 å好设置 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + 模拟三按键鼠标 + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 45}, {385, 31}} + + YES + + 67239424 + 4194304 + å¯ç”¨æ—¶ï¼Œèœå•æ ç­‰æ•ˆé”®å¯èƒ½ä¼šå¹²æ‰°ä½¿ç”¨å…ƒä¿®é¥°é”®çš„ X11 应用程åºã€‚ + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + 6K+35oyJ5L2PIE9wdGlvbiDmiJYgQ29tbWFuZCDngrnmjInku6Xmv4DmtLvkuK3pl7TmiJblj7Povrnn +moTpvKDmoIfmjInplK7jgIIKA + + + + + + + + + + 256 + {{18, 82}, {402, 18}} + + YES + + 67239424 + 0 + 在 X11 环境下å¯ç”¨ç­‰æ•ˆé”® + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 126}, {385, 14}} + + YES + + 67239424 + 4194304 + å…许进行输入èœå•æ›´æ”¹ä»¥è¦†ç›–当å‰çš„ X11 键盘映射。 + + + + + + + + + + 256 + {{18, 146}, {402, 18}} + + YES + + 67239424 + 0 + ä¾ç…§ç³»ç»Ÿé”®ç›˜å¸ƒå±€ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, -1}, {385, 31}} + + YES + + 67239424 + 4194304 + 如果已å¯ç”¨ï¼Œåˆ™ Option 键会å‘é€ Alt_L å’Œ Alt_R X11 键符å·ï¼Œè€Œä¸æ˜¯å‘é€ Mode_switch。 + + + + + + + + + 256 + {{18, 36}, {402, 18}} + + YES + + 67239424 + 0 + Option 键会å‘é€ Alt_L å’Œ Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + 输入 + + + + + + 2 + + + + 256 + + + + 256 + {{59, 202}, {128, 26}} + + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + 从显示器 + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 ç§é¢œè‰² + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + ä¸Šä¸‡ç§ + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + 上åƒä¸‡ç§ + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 206}, {43, 20}} + + + YES + + 67239424 + 4194304 + 颜色: + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + + YES + + 67239424 + 4194304 + 此选项会在å†æ¬¡å¼€å¯ X11 时生效。 + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + + YES + + 67239424 + 0 + å…¨å±å¹•æ¨¡å¼ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {409, 23}} + + + YES + + 67239424 + 0 + 以全å±å¹•æ¨¡å¼è‡ªåŠ¨æ˜¾ç¤ºèœå•æ  + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 112}, {405, 31}} + + + YES + + 67239424 + 4194304 + å¯ç”¨ X11 根窗å£ã€‚使用 Command-Option-A 击键æ¥è¿›å…¥å’Œç¦»å¼€å…¨å±å¹•æ¨¡å¼ã€‚ + + + + + + + + + {{10, 33}, {438, 246}} + + + + 输出 + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + å¯ç”¨åŒæ­¥ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {385, 28}} + + YES + + 67239424 + 4194304 + å¯ç”¨â€œæ‹·è´â€èœå•é¡¹å¹¶å…许 OSX“粘贴æ¿â€ä¸Ž X11 CLIPBOARD å’Œ PRIMARY 缓冲区之间åŒæ­¥ã€‚ + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + 粘贴æ¿æ”¹å˜æ—¶æ›´æ–° CLIPBOARD + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {409, 23}} + + YES + + 67239424 + 0 + 粘贴æ¿æ”¹å˜æ—¶æ›´æ–° PRIMARY(点按鼠标中间键) + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 46}, {409, 23}} + + YES + + 67239424 + 0 + 选定新文本时立å³æ›´æ–°ç²˜è´´æ¿ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + CLIPBOARD 改å˜æ—¶æ›´æ–°ç²˜è´´æ¿ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {385, 28}} + + YES + + 67239424 + 4194304 + 如果您想è¦ä½¿ç”¨ xclipboardã€klipper 或其他任何 X11 剪贴æ¿ç®¡ç†ç¨‹åºï¼Œè¯·åœç”¨æ­¤é€‰é¡¹ã€‚ + + + + + + + + + 256 + {{48, 14}, {370, 28}} + + YES + + 67239424 + 4194304 + 由于 X11 å议中的é™åˆ¶ï¼Œæ­¤é€‰é¡¹åœ¨æŸäº›åº”用程åºä¸­å¯èƒ½æ— æ³•å·¥ä½œã€‚ + + + + + + + + {{10, 33}, {438, 246}} + + ç²˜è´´æ¿ + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + 点按å„个ä¸æ´»è·ƒçª—å£ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {385, 31}} + + YES + + 67239424 + 4194304 + å¯ç”¨æ—¶ï¼Œç‚¹æŒ‰ä¸æ´»è·ƒçª—å£ä¼šæ¿€æ´»çª—å£ï¼Œé™¤æ­¤ä»¥å¤–,还将导致鼠标点按传递到该窗å£ã€‚ + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + 焦点跟éšé¼ æ ‡ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 128}, {385, 17}} + + YES + + 67239424 + 4194304 + X11 窗å£ç„¦ç‚¹è·Ÿéšå…‰æ ‡ã€‚这会产生一些ä¸å¥½çš„效果。 + + + + + + + + + 256 + {{15, 107}, {402, 18}} + + YES + + 67239424 + 0 + èšç„¦æ–°çª—å£ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 73}, {395, 28}} + + YES + + 67239424 + 4194304 + å¯ç”¨æ—¶ï¼Œåˆ›å»ºæ–° X11 窗å£å°†å¯¼è‡´ X11.app 移到最å‰é¢ï¼ˆè€Œä¸æ˜¯ Finder.appã€ç»ˆç«¯.app 等应用程åºç§»åˆ°æœ€å‰é¢ï¼‰ã€‚ + + + + + + + + {{10, 33}, {438, 246}} + + çª—å£ + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + 鉴定连接 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + å…许从网络客户端连接 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 162}, {385, 42}} + + YES + + 67239424 + 4194304 + å¼€å¯ X11 将创建 Xauthority 访问控制按键。如果系统的 IP 地å€å·²æ›´æ”¹ï¼Œè¿™äº›æŒ‰é”®ä¼šå˜æˆæ— æ•ˆçš„,这å¯èƒ½ä¼šé˜»æ­¢ X11 应用程åºå¼€å¯ã€‚ + + + + + + + + + + 256 + {{36, 85}, {385, 42}} + + YES + + 67239424 + 4194304 + 如果已å¯ç”¨ï¼Œåˆ™å¿…须也å¯ç”¨é‰´å®šè¿žæŽ¥ä»¥ç¡®ä¿ç³»ç»Ÿå®‰å…¨ã€‚åœç”¨æ—¶ï¼Œä¸å…许远程应用程åºçš„连接。 + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + è¿™äº›é€‰é¡¹ä¼šåœ¨ä¸‹ä¸€æ¬¡å¼€å¯ X11 时生效。 + + + + + + + + + {{10, 33}, {438, 246}} + + 安全性 + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{279, 416}, {454, 271}} + 1350041600 + X11 应用程åºèœå• + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {100, 32}} + + YES + + 67239424 + 137887744 + å¤åˆ¶ + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {100, 32}} + + YES + + 67239424 + 137887744 + 移除 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 121.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + å称 + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + + 99 + 40 + 1000 + + 75628096 + 2048 + 命令 + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + + 71 + 10 + 1000 + + 75628096 + 2048 + å¿«æ· + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {100, 32}} + + YES + + -2080244224 + 137887744 + 添加项目 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1280, 938}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + èœå• + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + åº”ç”¨ç¨‹åº + + 1048576 + 2147483647 + + + submenuAction: + + åº”ç”¨ç¨‹åº + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 自定… + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 548}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 548}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/keyedobjects.nib index e422e43f7..127c738cf 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/zh_CN.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/locversion.plist b/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/locversion.plist index 1d295ea56..17aeb6700 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/locversion.plist +++ b/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/locversion.plist @@ -1,14 +1,14 @@ - - - - - LprojCompatibleVersion - 98 - LprojLocale - zh_TW - LprojRevisionLevel - 1 - LprojVersion - 98 - - + + + + + LprojCompatibleVersion + 101 + LprojLocale + zh_TW + LprojRevisionLevel + 1 + LprojVersion + 101 + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/designable.nib b/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/designable.nib index 2386c0b10..e2322d346 100644 --- a/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/designable.nib +++ b/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/designable.nib @@ -1,3608 +1,3757 @@ - - - - 1040 - 11A194b - 787 - 1079 - 502.00 - - com.apple.InterfaceBuilder.CocoaPlugin - 787 - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - NSApplication - - - - FirstResponder - - - NSApplication - - - MainMenu - - - - X11 - - 1048576 - 2147483647 - - NSImage - NSMenuCheckmark - - - NSImage - NSMenuMixedState - - submenuAction: - - X11 - - - - 關於 X11 - - 2147483647 - - - - - - å好設定⋯ - , - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - æœå‹™ - - 1048576 - 2147483647 - - - submenuAction: - - æœå‹™ - - _NSServicesMenu - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 使用全螢幕 - a - 1572864 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - éš±è— X11 - h - 1048576 - 2147483647 - - - 42 - - - - éš±è—其他 - h - 1572864 - 2147483647 - - - - - - 顯示全部 - - 1048576 - 2147483647 - - - 42 - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - çµæŸ X11 - q - 1048576 - 2147483647 - - - - - _NSAppleMenu - - - - - æ‡‰ç”¨ç¨‹å¼ - - 1048576 - 2147483647 - - - submenuAction: - - æ‡‰ç”¨ç¨‹å¼ - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 自定⋯ - - 1048576 - 2147483647 - - - - - - - - - 編輯 - - 1048576 - 2147483647 - - - submenuAction: - - 編輯 - - - - æ‹·è² - c - 1048576 - 2147483647 - - - - - - - - - 視窗 - - 1048576 - 2147483647 - - - submenuAction: - - 視窗 - - - - 關閉 - w - 1048576 - 2147483647 - - - - - - ç¸®åˆ°æœ€å° - m - 1048576 - 2147483647 - - - - - - 縮放 - - 1048576 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 循環檢視視窗 - ` - 1048840 - 2147483647 - - - - - - åå‘循環檢視視窗 - ~ - 1179914 - 2147483647 - - - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 將此程å¼æ‰€æœ‰è¦–çª—ç§»è‡³æœ€å‰ - - 1048576 - 2147483647 - - - - - _NSWindowsMenu - - - - - 輔助說明 - - 1048576 - 2147483647 - - - submenuAction: - - 輔助說明 - - - - X11 輔助說明 - - 1048576 - 2147483647 - - - - - - - - _NSMainMenu - - - X11Controller - - - 3 - 2 - {{319, 329}, {484, 308}} - 1350041600 - X11 å好設定 - NSPanel - - View - - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 256 - {{13, 10}, {458, 292}} - - - - - - 1 - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - - YES - - 67239424 - 0 - 模擬三éµæ»‘é¼  - - LucidaGrande - 13 - 1044 - - - 1211912703 - 2 - - NSImage - NSSwitch - - - NSSwitch - - - - 200 - 25 - - - - - 256 - {{36, 92}, {399, 14}} - - - YES - - 67239424 - 4194304 - 當啟用時,é¸å–®åˆ—按éµçš„å°æ‡‰éµå¯èƒ½æœƒé˜»ç¤™ä½¿ç”¨ Meta 變更éµçš„ X11 應用程å¼ã€‚ - - LucidaGrande - 11 - 3100 - - - - - 6 - System - controlColor - - 3 - MC42NjY2NjY2ODY1AA - - - - 6 - System - controlTextColor - - 3 - MAA - - - - - - - 256 - {{36, 176}, {385, 28}} - - - YES - - 67239424 - 4194304 - 5oyJ5L2PIE9wdGlvbiDmiJYgQ29tbWFuZCDnmoTlkIzmmYLmjInkuIDkuIvvvIzku6XllZ/nlKjmu5Hp -vKDnmoTkuK3plpPmiJblj7PpgormjInpiJXjgIIKA - - - - - - - - - - 256 - {{18, 112}, {402, 18}} - - - YES - - 67239424 - 0 - 啟用 X11 下的按éµå°æ‡‰éµ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 141}, {385, 14}} - - - YES - - 67239424 - 4194304 - å…許輸入法é¸å–®çš„更動覆寫目å‰çš„ X11 按éµå°æ‡‰ã€‚ - - - - - - - - - - 256 - {{18, 161}, {402, 18}} - - - YES - - 67239424 - 0 - ä¾ç…§ç³»çµ±éµç›¤ä½ˆå±€ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 26}, {385, 31}} - - - YES - - 67239424 - 4194304 - 當啟用時,option éµæœƒå‚³é€ Alt_L å’Œ Alt_R X11 按éµç¬¦è™Ÿï¼Œè€Œä¸æ˜¯ Mode_switch。 - - - - - - - - - 256 - {{18, 63}, {402, 18}} - - - YES - - 67239424 - 0 - 讓 Option éµå‚³é€ Alt_L å’Œ Alt_R - - - 1211912703 - 2 - - - - - 200 - 25 - - - - {{10, 33}, {438, 246}} - - - - 輸入 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 63}, {402, 18}} - - YES - - 67239424 - 0 - 使用系統æ示效果 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 29}, {379, 28}} - - YES - - 67239424 - 4194304 - X11 çš„å—¶è²å°‡æœƒä½¿ç”¨æ¨™æº–的系統æ示è²ï¼Œå³æ‚¨åœ¨ç³»çµ±å好設定é¢æ¿çš„“音效â€ä¸­è¨­å®šçš„è²éŸ³ã€‚ - - - - - - - - - - 256 - {{55, 202}, {136, 26}} - - YES - - -2076049856 - 1024 - - - 109199615 - 1 - - LucidaGrande - 13 - 16 - - - - - - 400 - 75 - - - 來自螢幕 - - 1048576 - 2147483647 - 1 - - - _popUpItemAction: - -1 - - - YES - - - OtherViews - - - - - - 256 種é¡è‰² - - 1048576 - 2147483647 - - - _popUpItemAction: - 8 - - - - - 數è¬ç¨®é¡è‰² - - 1048576 - 2147483647 - - - _popUpItemAction: - 15 - - - - - åƒè¬ç¨®é¡è‰² - - 1048576 - 2147483647 - - - _popUpItemAction: - 24 - - - - - 3 - YES - YES - 1 - - - - - 256 - {{17, 205}, {44, 20}} - - YES - - 67239424 - 4194304 - é¡è‰²ï¼š - - - - - - - - - - 256 - {{36, 183}, {392, 14}} - - YES - - 67239424 - 4194304 - æ­¤é¸é …將會在 X11 å†æ¬¡å•Ÿå‹•å¾Œç”Ÿæ•ˆã€‚ - - - - - - - - - - 256 - {{18, 149}, {409, 23}} - - YES - - 67239424 - 0 - å…¨èž¢å¹•æ¨¡å¼ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{37, 83}, {409, 23}} - - YES - - 67239424 - 0 - 自動以全螢幕模å¼é¡¯ç¤ºé¸å–®åˆ— - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 115}, {382, 28}} - - YES - - 67239424 - 4194304 - 啟用 X11 root 視窗。使用 Command + Option + A éµç›¤çµ„åˆä¾†é€²å…¥å’Œé›¢é–‹å…¨èž¢å¹•æ¨¡å¼ã€‚ - - - - - - - - - {{10, 33}, {438, 246}} - - 輸出 - - - - - - 2 - - - - 256 - - - - 256 - {{18, 222}, {409, 23}} - - YES - - 67239424 - 0 - 啟用åŒæ­¥åŠŸèƒ½ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 188}, {385, 28}} - - YES - - 67239424 - 4194304 - 啟用“拷è²â€é¸å–®é …目,並å…許 OSX“剪貼æ¿â€èˆ‡ X11 CLIPBOARD 之間的åŒæ­¥ï¼Œä»¥åŠ PRIMARY ç·©è¡ã€‚ - - - - - - - - - 256 - {{34, 96}, {409, 23}} - - YES - - 67239424 - 0 - 當“剪貼æ¿â€æ›´æ”¹æ™‚æ›´æ–° CLIPBOARD - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 71}, {409, 23}} - - YES - - 67239424 - 0 - 當“剪貼æ¿â€æ›´æ”¹æ™‚æ›´æ–° PRIMARY(中間點按) - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 46}, {409, 23}} - - YES - - 67239424 - 0 - 當é¸å–新文字時,立å³æ›´æ–°â€œå‰ªè²¼æ¿â€ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{34, 159}, {409, 23}} - - YES - - 67239424 - 0 - 當 CLIPBOARD 更改時更新“剪貼æ¿â€ - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{48, 125}, {385, 28}} - - YES - - 67239424 - 4194304 - 若您想使用 xclipboardã€klipper 或任何其他 X11 剪貼æ¿ç®¡ç†ç¨‹å¼ï¼Œè«‹åœç”¨æ­¤é¸é …。 - - - - - - - - - 256 - {{48, 14}, {370, 28}} - - YES - - 67239424 - 4194304 - 由於 X11 通訊å”定的é™åˆ¶ï¼Œæ­¤é¸é …å¯èƒ½ç„¡æ³•åœ¨æŸäº›æ‡‰ç”¨ç¨‹å¼è£¡ä½¿ç”¨ã€‚ - - - - - - - - {{10, 33}, {438, 246}} - - å‰ªè²¼æ¿ - - - - - - 2 - - - - 256 - - - - 256 - {{15, 212}, {402, 18}} - - YES - - 67239424 - 0 - ç©¿é€è‡³æœªå•Ÿç”¨çš„視窗 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 175}, {385, 31}} - - YES - - 67239424 - 4194304 - 當啟用時,按一下未啟用的視窗將會使滑鼠按éµç©¿é€è‡³è©²è¦–窗並將其啓用。 - - - - - - - - - 256 - {{15, 151}, {402, 18}} - - YES - - 67239424 - 0 - 焦點隨著滑鼠移動 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 128}, {385, 17}} - - YES - - 67239424 - 4194304 - X11 視窗焦點會跟隨游標移動。這樣會有一些相å的效果。 - - - - - - - - - 256 - {{15, 90}, {402, 18}} - - YES - - 67239424 - 0 - 讓新視窗å–得焦點 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{23, 56}, {409, 28}} - - YES - - 67239424 - 4194304 - 當啟用時,新增的 X11 視窗將會使 X11.app(而ä¸æ˜¯ Finder.appã€çµ‚端機.app 等)移至最å‰ã€‚ - - - - - - - - {{10, 33}, {438, 246}} - - 視窗 - - - - - - - 256 - - - - 256 - {{18, 210}, {402, 18}} - - YES - - 67239424 - 0 - èªè­‰é€£ç·š - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{18, 133}, {402, 18}} - - YES - - 67239424 - 0 - å…許從網路用戶端連線 - - - 1211912703 - 2 - - - - - 200 - 25 - - - - - 256 - {{36, 176}, {385, 28}} - - YES - - 67239424 - 4194304 - å•Ÿå‹• X11 將會製作 Xauthority å–用控制按éµã€‚若系統的 IP ä½å€æ›´å‹•ï¼Œé€™äº›éµå°‡æœƒç„¡æ•ˆï¼Œé€™å¯èƒ½æœƒä»¤ X11 應用程å¼ç„¡æ³•å•Ÿå‹•ã€‚ - - - - - - - - - - 256 - {{36, 99}, {388, 28}} - - YES - - 67239424 - 4194304 - 若啟用,“èªè­‰é€£ç·šâ€å¿…須也被啟用來確ä¿ç³»çµ±å®‰å…¨ã€‚當åœç”¨æ™‚,ä¸æœƒå…許來自é ç«¯æ‡‰ç”¨ç¨‹å¼çš„連線。 - - - - - - - - - - 256 - {{20, -16}, {404, 14}} - - YES - - 67239424 - 4194304 - 這些é¸é …將會在 X11 下次啟動後生效。 - - - - - - - - - {{10, 33}, {438, 246}} - - 安全性 - - - - - - - 0 - YES - YES - - - - - - {484, 308} - - - - {{0, 0}, {1440, 878}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_prefs - - - 11 - 2 - {{360, 400}, {454, 271}} - 1350041600 - X11 應用程å¼é¸å–® - NSPanel - - View - - - {3.4028235e+38, 3.4028235e+38} - {320, 240} - - - 256 - - - - 265 - {{340, 191}, {100, 32}} - - YES - - 67239424 - 137887744 - 複製 - - - -2038284033 - 1 - - Helvetica - 13 - 16 - - - - - - 200 - 25 - - - - - 265 - {{340, 159}, {100, 32}} - - YES - - 67239424 - 137887744 - 移除 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - - 274 - - - - 2304 - - - - 256 - {301, 198} - - YES - - - 256 - {301, 17} - - - - - - 256 - {{302, 0}, {16, 17}} - - - - - 122.73100280761719 - 62.730998992919922 - 1000 - - 75628096 - 2048 - å稱 - - - 3 - MC4zMzMzMzI5ODU2AA - - - 6 - System - headerTextColor - - - - - 338820672 - 1024 - Text Cell - - - - - 3 - MQA - - - - 3 - YES - YES - - - - 100 - 40 - 1000 - - 75628096 - 2048 - 指令 - - - - - - 338820672 - 1024 - Text Cell - - - - - - - 3 - YES - YES - - - - 69 - 10 - 1000 - - 75628096 - 2048 - å¿«é€Ÿéµ - - - 6 - System - headerColor - - - - - - 338820672 - 1024 - Text Cell - - LucidaGrande - 12 - 16 - - - - YES - - 6 - System - controlBackgroundColor - - - - - 3 - YES - YES - - - - 3 - 2 - - - 6 - System - gridColor - - 3 - MC41AA - - - 17 - 1379958784 - - - 1 - -1 - 0 - YES - 0 - - - {{1, 17}, {301, 198}} - - - - - 4 - - - - 256 - {{302, 17}, {15, 198}} - - - _doScroller: - 0.99492377042770386 - - - - 256 - {{1, 215}, {301, 15}} - - 1 - - _doScroller: - 0.68852460384368896 - - - - 2304 - - - - {{1, 0}, {301, 17}} - - - - - 4 - - - - {{20, 20}, {318, 231}} - - - 50 - - - - - - QSAAAEEgAABBmAAAQZgAAA - - - - 265 - {{340, 223}, {100, 32}} - - YES - - -2080244224 - 137887744 - 加入項目 - - - -2038284033 - 1 - - - - - - 200 - 25 - - - - {454, 271} - - - {{0, 0}, {1440, 878}} - {320, 262} - {3.4028235e+38, 3.4028235e+38} - x11_apps - - - é¸å–® - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - æ‡‰ç”¨ç¨‹å¼ - - 1048576 - 2147483647 - - - submenuAction: - - æ‡‰ç”¨ç¨‹å¼ - - - - YES - YES - - - 1048576 - 2147483647 - - - - - - 自定⋯ - - 1048576 - 2147483647 - - - - - - - - - - - - - - - copy: - - - - 181 - - - - minimize_window: - - - - 202 - - - - close_window: - - - - 205 - - - - zoom_window: - - - - 206 - - - - bring_to_front: - - - - 207 - - - - hideOtherApplications: - - - - 263 - - - - apps_separator - - - - 273 - - - - apps_table - - - - 301 - - - - apps_table_delete: - - - - 303 - - - - apps_table_duplicate: - - - - 304 - - - - apps_table_show: - - - - 308 - - - - apps_table_new: - - - - 311 - - - - prefs_show: - - - - 318 - - - - x11_about_item - - - - 321 - - - - enable_auth - - - - 387 - - - - enable_tcp - - - - 388 - - - - depth - - - - 389 - - - - use_sysbeep - - - - 390 - - - - fake_buttons - - - - 391 - - - - sync_keymap - - - - 392 - - - - enable_keyequivs - - - - 393 - - - - prefs_changed: - - - - 394 - - - - prefs_changed: - - - - 395 - - - - prefs_changed: - - - - 396 - - - - prefs_changed: - - - - 397 - - - - prefs_changed: - - - - 398 - - - - prefs_changed: - - - - 399 - - - - prefs_changed: - - - - 401 - - - - prefs_panel - - - - 402 - - - - x11_help: - - - - 422 - - - - dockMenu - - - - 426 - - - - dock_menu - - - - 428 - - - - delegate - - - - 429 - - - - hide: - - - - 430 - - - - unhideAllApplications: - - - - 431 - - - - orderFrontStandardAboutPanel: - - - - 433 - - - - dock_apps_menu - - - - 530 - - - - dock_window_separator - - - - 531 - - - - apps_table_show: - - - - 534 - - - - next_window: - - - - 539 - - - - previous_window: - - - - 540 - - - - enable_fullscreen - - - - 546 - - - - enable_fullscreen_changed: - - - - 547 - - - - toggle_fullscreen: - - - - 548 - - - - toggle_fullscreen_item - - - - 549 - - - - menu - - - - 300334 - - - - terminate: - - - - 300336 - - - - prefs_changed: - - - - 300389 - - - - prefs_changed: - - - - 300390 - - - - prefs_changed: - - - - 300391 - - - - click_through - - - - 300392 - - - - focus_follows_mouse - - - - 300393 - - - - focus_on_new_window - - - - 300394 - - - - copy_menu_item - - - - 300443 - - - - sync_pasteboard - - - - 300444 - - - - sync_clipboard_to_pasteboard - - - - 300461 - - - - sync_pasteboard_to_clipboard - - - - 300462 - - - - sync_pasteboard_to_primary - - - - 300463 - - - - sync_primary_immediately - - - - 300464 - - - - prefs_changed: - - - - 300465 - - - - prefs_changed: - - - - 300466 - - - - prefs_changed: - - - - 300467 - - - - prefs_changed: - - - - 300468 - - - - prefs_changed: - - - - 300469 - - - - sync_text1 - - - - 300470 - - - - sync_text2 - - - - 300471 - - - - enable_fullscreen_menu - - - - 300474 - - - - prefs_changed: - - - - 300475 - - - - prefs_changed: - - - - 300480 - - - - option_sends_alt - - - - 300481 - - - - - - 0 - - - - - - -2 - - - File's Owner - - - -1 - - - First Responder - - - -3 - - - Application - - - 29 - - - - - - - - - - MainMenu - - - 19 - - - - - - - - 24 - - - - - - - - - - - - - - - 5 - - - - - 23 - - - - - 92 - - - - - 203 - - - - - 204 - - - - - 536 - - - - - 537 - - - - - 538 - - - - - 56 - - - - - - - - 57 - - - - - - - - - - - - - - - - - - - 58 - - - - - 129 - - - - - 131 - - - - - - - - 130 - - - - - 134 - - - - - 136 - - - - - 143 - - - - - 144 - - - - - 145 - - - - - 149 - - - - - 150 - - - - - 544 - - - - - 545 - - - - - 163 - - - - - - - - 169 - - - - - - - - 157 - - - - - 269 - - - - - - - - 270 - - - - - - - - - 272 - - - - - 305 - - - - - 419 - - - - - - - - 420 - - - - - - - - 421 - - - - - 196 - - - X11Controller - - - 244 - - - - - - PrefsPanel - - - 245 - - - - - - - - 348 - - - - - - - - - - - - 349 - - - - - - - - 351 - - - - - - - - - - - - - - - 363 - - - - - - - - 364 - - - - - - - - 365 - - - - - - - - 368 - - - - - - - - 369 - - - - - - - - 370 - - - - - - - - 352 - - - - - - - - 350 - - - - - - - - - - - - - - - 371 - - - - - - - - 372 - - - - - - - - 382 - - - - - - - - 385 - - - - - - - - 386 - - - - - - - - 541 - - - - - - - - 543 - - - - - - - - 353 - - - - - - - - 354 - - - - - - - - - - - - 374 - - - - - - - - 375 - - - - - - - - 376 - - - - - - - - 377 - - - - - - - - 379 - - - - - - - - 285 - - - - - - EditPrograms - - - 286 - - - - - - - - - - - 423 - - - - - - - DockMenu - - - 524 - - - - - 526 - - - - - - - - 527 - - - - - - - - - 532 - - - - - 533 - - - - - 100363 - - - - - 100364 - - - - - 100365 - - - - - 100368 - - - - - 100369 - - - - - 100370 - - - - - 100371 - - - - - 100372 - - - - - 100382 - - - - - - - - 100385 - - - - - 100386 - - - - - 100541 - - - - - 100543 - - - - - 100374 - - - - - 100375 - - - - - 100376 - - - - - 100377 - - - - - 100379 - - - - - 380 - - - - - - - - - - - 435 - - - - - 384 - - - - - 383 - - - - - 381 - - - - - 295 - - - - - - - - - - - 300295 - - - - - 200295 - - - - - 100295 - - - - - 296 - - - - - - - - - - 535 - - - - - - - - 575 - - - - - 298 - - - - - - - - 573 - - - - - 297 - - - - - - - - 574 - - - - - 310 - - - - - - - - 100310 - - - - - 292 - - - - - - - - 100292 - - - - - 293 - - - - - - - - 100293 - - - - - 300337 - - - - - - - - 300338 - - - - - - - - - - - - - 300358 - - - - - - - - 300359 - - - - - - - - 300360 - - - - - 300361 - - - - - 300362 - - - - - - - - 300363 - - - - - 300364 - - - - - - - - 300365 - - - - - 300368 - - - - - - - - 300369 - - - - - 300370 - - - - - - - - 300371 - - - - - 300421 - - - - - - - - 300422 - - - - - - - - - - - - - - - 300423 - - - - - - - - 300424 - - - - - - - - 300440 - - - - - 300441 - - - - - 300447 - - - - - - - - 300450 - - - - - 300451 - - - - - - - - 300452 - - - - - 300453 - - - - - - - - 300454 - - - - - 300455 - - - - - - - - 300456 - - - - - 300457 - - - - - - - - 300458 - - - - - 300459 - - - - - - - - 300460 - - - - - 300472 - - - - - - - - 300473 - - - - - 300476 - - - - - - - - 300477 - - - - - - - - 300478 - - - - - 300479 - - - - - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{168, 821}, {113, 23}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{202, 626}, {154, 153}} - com.apple.InterfaceBuilder.CocoaPlugin - - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{349, 868}, {315, 143}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{271, 666}, {301, 153}} - {{507, 548}, {484, 308}} - com.apple.InterfaceBuilder.CocoaPlugin - {{507, 548}, {484, 308}} - - {{184, 290}, {481, 345}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{58, 803}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{100, 746}, {155, 33}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{68, 585}, {454, 271}} - com.apple.InterfaceBuilder.CocoaPlugin - - - {{68, 585}, {454, 271}} - - {{433, 406}, {486, 327}} - - - {3.40282e+38, 3.40282e+38} - {320, 240} - com.apple.InterfaceBuilder.CocoaPlugin - - {{145, 1011}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{67, 819}, {336, 20}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - IBBuiltInLabel-Red - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - {{20, 641}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - {{79, 616}, {218, 203}} - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - com.apple.InterfaceBuilder.CocoaPlugin - - - - - - - 300481 - - - - - FirstResponder - NSObject - - IBUserSource - - - - - NSFormatter - NSObject - - IBUserSource - - - - - X11Controller - NSObject - - IBUserSource - - - - - - 0 - IBCocoaFramework - - com.apple.InterfaceBuilder.CocoaPlugin.macosx - - - YES - ../X11.xcodeproj - 3 - - {9, 8} - {7, 2} - {15, 15} - - - + + + + 1040 + 11A289 + 851 + 1094.2 + 521.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + X11 + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + X11 + + + + 關於 X11 + + 2147483647 + + + + + + å好設定⋯ + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + æœå‹™ + + 1048576 + 2147483647 + + + submenuAction: + + æœå‹™ + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 使用全螢幕 + a + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + éš±è— X11 + h + 1048576 + 2147483647 + + + 42 + + + + éš±è—其他 + h + 1572864 + 2147483647 + + + + + + 顯示全部 + + 1048576 + 2147483647 + + + 42 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + çµæŸ X11 + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + æ‡‰ç”¨ç¨‹å¼ + + 1048576 + 2147483647 + + + submenuAction: + + æ‡‰ç”¨ç¨‹å¼ + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 自定⋯ + + 1048576 + 2147483647 + + + + + + + + + 編輯 + + 1048576 + 2147483647 + + + submenuAction: + + 編輯 + + + + æ‹·è² + c + 1048576 + 2147483647 + + + + + + + + + 視窗 + + 1048576 + 2147483647 + + + submenuAction: + + 視窗 + + + + 關閉 + w + 1048576 + 2147483647 + + + + + + ç¸®åˆ°æœ€å° + m + 1048576 + 2147483647 + + + + + + 縮放 + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 循環檢視視窗 + ` + 1048840 + 2147483647 + + + + + + åå‘循環檢視視窗 + ~ + 1179914 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 將此程å¼æ‰€æœ‰è¦–çª—ç§»è‡³æœ€å‰ + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + 輔助說明 + + 1048576 + 2147483647 + + + submenuAction: + + 輔助說明 + + + + X11 輔助說明 + + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + X11Controller + + + 3 + 2 + {{319, 329}, {484, 308}} + 1350041600 + X11 å好設定 + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 256 + {{13, 10}, {458, 292}} + + + + + 1 + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + 模擬三éµæ»‘é¼  + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{36, 92}, {399, 14}} + + YES + + 67239424 + 4194304 + 當啟用時,é¸å–®åˆ—按éµçš„å°æ‡‰éµå¯èƒ½æœƒé˜»ç¤™ä½¿ç”¨ Meta 變更éµçš„ X11 應用程å¼ã€‚ + + LucidaGrande + 11 + 3100 + + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{36, 176}, {385, 28}} + + YES + + 67239424 + 4194304 + 5oyJ5L2PIE9wdGlvbiDmiJYgQ29tbWFuZCDnmoTlkIzmmYLmjInkuIDkuIvvvIzku6XllZ/nlKjmu5Hp +vKDnmoTkuK3plpPmiJblj7PpgormjInpiJXjgIIKA + + + + + + + + + + 256 + {{18, 112}, {402, 18}} + + YES + + 67239424 + 0 + 啟用 X11 下的按éµå°æ‡‰éµ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 141}, {385, 14}} + + YES + + 67239424 + 4194304 + å…許輸入法é¸å–®çš„更動覆寫目å‰çš„ X11 按éµå°æ‡‰ã€‚ + + + + + + + + + + 256 + {{18, 161}, {402, 18}} + + YES + + 67239424 + 0 + ä¾ç…§ç³»çµ±éµç›¤ä½ˆå±€ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 26}, {385, 31}} + + YES + + 67239424 + 4194304 + 當啟用時,option éµæœƒå‚³é€ Alt_L å’Œ Alt_R X11 按éµç¬¦è™Ÿï¼Œè€Œä¸æ˜¯ Mode_switch。 + + + + + + + + + 256 + {{18, 63}, {402, 18}} + + YES + + 67239424 + 0 + 讓 Option éµå‚³é€ Alt_L å’Œ Alt_R + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{10, 33}, {438, 246}} + + 輸入 + + + + + + 2 + + + + 256 + + + + 256 + {{55, 202}, {136, 26}} + + YES + + -2076049856 + 1024 + + + 109199615 + 1 + + LucidaGrande + 13 + 16 + + + + + + 400 + 75 + + + 來自螢幕 + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + -1 + + + YES + + + OtherViews + + + + + + 256 種é¡è‰² + + 1048576 + 2147483647 + + + _popUpItemAction: + 8 + + + + + 數è¬ç¨®é¡è‰² + + 1048576 + 2147483647 + + + _popUpItemAction: + 15 + + + + + åƒè¬ç¨®é¡è‰² + + 1048576 + 2147483647 + + + _popUpItemAction: + 24 + + + + + 3 + YES + YES + 1 + + + + + 256 + {{17, 205}, {44, 20}} + + YES + + 67239424 + 4194304 + é¡è‰²ï¼š + + + + + + + + + + 256 + {{36, 183}, {392, 14}} + + YES + + 67239424 + 4194304 + æ­¤é¸é …將會在 X11 å†æ¬¡å•Ÿå‹•å¾Œç”Ÿæ•ˆã€‚ + + + + + + + + + + 256 + {{18, 149}, {409, 23}} + + YES + + 67239424 + 0 + å…¨èž¢å¹•æ¨¡å¼ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{37, 83}, {409, 23}} + + YES + + 67239424 + 0 + 自動以全螢幕模å¼é¡¯ç¤ºé¸å–®åˆ— + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 115}, {382, 28}} + + YES + + 67239424 + 4194304 + 啟用 X11 root 視窗。使用 Command + Option + A éµç›¤çµ„åˆä¾†é€²å…¥å’Œé›¢é–‹å…¨èž¢å¹•æ¨¡å¼ã€‚ + + + + + + + + + {{10, 33}, {438, 246}} + + + 輸出 + + + + + + 2 + + + + 256 + + + + 256 + {{18, 222}, {409, 23}} + + YES + + 67239424 + 0 + 啟用åŒæ­¥åŠŸèƒ½ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 188}, {385, 28}} + + YES + + 67239424 + 4194304 + 啟用“拷è²â€é¸å–®é …目,並å…許 OSX“剪貼æ¿â€èˆ‡ X11 CLIPBOARD 之間的åŒæ­¥ï¼Œä»¥åŠ PRIMARY ç·©è¡ã€‚ + + + + + + + + + 256 + {{34, 96}, {409, 23}} + + YES + + 67239424 + 0 + 當“剪貼æ¿â€æ›´æ”¹æ™‚æ›´æ–° CLIPBOARD + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 71}, {409, 23}} + + YES + + 67239424 + 0 + 當“剪貼æ¿â€æ›´æ”¹æ™‚æ›´æ–° PRIMARY(中間點按) + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 46}, {409, 23}} + + YES + + 67239424 + 0 + 當é¸å–新文字時,立å³æ›´æ–°â€œå‰ªè²¼æ¿â€ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{34, 159}, {409, 23}} + + YES + + 67239424 + 0 + 當 CLIPBOARD 更改時更新“剪貼æ¿â€ + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{48, 125}, {385, 28}} + + YES + + 67239424 + 4194304 + 若您想使用 xclipboardã€klipper 或任何其他 X11 剪貼æ¿ç®¡ç†ç¨‹å¼ï¼Œè«‹åœç”¨æ­¤é¸é …。 + + + + + + + + + 256 + {{48, 14}, {370, 28}} + + YES + + 67239424 + 4194304 + 由於 X11 通訊å”定的é™åˆ¶ï¼Œæ­¤é¸é …å¯èƒ½ç„¡æ³•åœ¨æŸäº›æ‡‰ç”¨ç¨‹å¼è£¡ä½¿ç”¨ã€‚ + + + + + + + + {{10, 33}, {438, 246}} + + å‰ªè²¼æ¿ + + + + + + 2 + + + + 256 + + + + 256 + {{15, 212}, {402, 18}} + + YES + + 67239424 + 0 + ç©¿é€è‡³æœªå•Ÿç”¨çš„視窗 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 175}, {385, 31}} + + YES + + 67239424 + 4194304 + 當啟用時,按一下未啟用的視窗將會使滑鼠按éµç©¿é€è‡³è©²è¦–窗並將其啓用。 + + + + + + + + + 256 + {{15, 151}, {402, 18}} + + YES + + 67239424 + 0 + 焦點隨著滑鼠移動 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 128}, {385, 17}} + + YES + + 67239424 + 4194304 + X11 視窗焦點會跟隨游標移動。這樣會有一些相å的效果。 + + + + + + + + + 256 + {{15, 90}, {402, 18}} + + YES + + 67239424 + 0 + 讓新視窗å–得焦點 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{23, 56}, {409, 28}} + + YES + + 67239424 + 4194304 + 當啟用時,新增的 X11 視窗將會使 X11.app(而ä¸æ˜¯ Finder.appã€çµ‚端機.app 等)移至最å‰ã€‚ + + + + + + + + {{10, 33}, {438, 246}} + + 視窗 + + + + + + + 256 + + + + 256 + {{18, 210}, {402, 18}} + + YES + + 67239424 + 0 + èªè­‰é€£ç·š + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{18, 133}, {402, 18}} + + YES + + 67239424 + 0 + å…許從網路用戶端連線 + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{36, 176}, {385, 28}} + + YES + + 67239424 + 4194304 + å•Ÿå‹• X11 將會製作 Xauthority å–用控制按éµã€‚若系統的 IP ä½å€æ›´å‹•ï¼Œé€™äº›éµå°‡æœƒç„¡æ•ˆï¼Œé€™å¯èƒ½æœƒä»¤ X11 應用程å¼ç„¡æ³•å•Ÿå‹•ã€‚ + + + + + + + + + + 256 + {{36, 99}, {388, 28}} + + YES + + 67239424 + 4194304 + 若啟用,“èªè­‰é€£ç·šâ€å¿…須也被啟用來確ä¿ç³»çµ±å®‰å…¨ã€‚當åœç”¨æ™‚,ä¸æœƒå…許來自é ç«¯æ‡‰ç”¨ç¨‹å¼çš„連線。 + + + + + + + + + + 256 + {{20, -16}, {404, 14}} + + YES + + 67239424 + 4194304 + 這些é¸é …將會在 X11 下次啟動後生效。 + + + + + + + + + {{10, 33}, {438, 246}} + + 安全性 + + + + + + + 0 + YES + YES + + + + + + {484, 308} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_prefs + + + 11 + 2 + {{360, 400}, {454, 271}} + 1350041600 + X11 應用程å¼é¸å–® + NSPanel + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {320, 240} + + + 256 + + + + 265 + {{340, 191}, {100, 32}} + + YES + + 67239424 + 137887744 + 複製 + + + -2038284033 + 1 + + Helvetica + 13 + 16 + + + + + + 200 + 25 + + + + + 265 + {{340, 159}, {100, 32}} + + YES + + 67239424 + 137887744 + 移除 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + + 274 + + + + 2304 + + + + 256 + {301, 198} + + YES + + + 256 + {301, 17} + + + + + + 256 + {{302, 0}, {16, 17}} + + + + + 122.73100280761719 + 62.730998992919922 + 1000 + + 75628096 + 2048 + å稱 + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + + + + 338820672 + 1024 + Text Cell + + + + + 3 + MQA + + + + 3 + YES + YES + + + + 100 + 40 + 1000 + + 75628096 + 2048 + 指令 + + + + + + 338820672 + 1024 + Text Cell + + + + + + + 3 + YES + YES + + + + 69 + 10 + 1000 + + 75628096 + 2048 + å¿«é€Ÿéµ + + + 6 + System + headerColor + + + + + + 338820672 + 1024 + Text Cell + + LucidaGrande + 12 + 16 + + + + YES + + 6 + System + controlBackgroundColor + + + + + 3 + YES + YES + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 17 + 1379958784 + + + 1 + -1 + 0 + YES + 0 + 1 + + + {{1, 17}, {301, 198}} + + + + + 4 + + + + 256 + {{302, 17}, {15, 198}} + + + _doScroller: + 0.99492380000000002 + + + + 256 + {{1, 215}, {301, 15}} + + 1 + + _doScroller: + 0.68852460000000004 + + + + 2304 + + + + {{1, 0}, {301, 17}} + + + + + 4 + + + + {{20, 20}, {318, 231}} + + + 133170 + + + + + QSAAAEEgAABBmAAAQZgAAA + + + + 265 + {{340, 223}, {100, 32}} + + YES + + -2080244224 + 137887744 + 加入項目 + + + -2038284033 + 1 + + + + + + 200 + 25 + + + + {454, 271} + + {{0, 0}, {1440, 878}} + {320, 262} + {1.7976931348623157e+308, 1.7976931348623157e+308} + x11_apps + + + é¸å–® + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + æ‡‰ç”¨ç¨‹å¼ + + 1048576 + 2147483647 + + + submenuAction: + + æ‡‰ç”¨ç¨‹å¼ + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + 自定⋯ + + 1048576 + 2147483647 + + + + + + + + + + + + + + + copy: + + + + 181 + + + + minimize_window: + + + + 202 + + + + close_window: + + + + 205 + + + + zoom_window: + + + + 206 + + + + bring_to_front: + + + + 207 + + + + hideOtherApplications: + + + + 263 + + + + apps_separator + + + + 273 + + + + apps_table + + + + 301 + + + + apps_table_delete: + + + + 303 + + + + apps_table_duplicate: + + + + 304 + + + + apps_table_show: + + + + 308 + + + + apps_table_new: + + + + 311 + + + + prefs_show: + + + + 318 + + + + x11_about_item + + + + 321 + + + + enable_auth + + + + 387 + + + + enable_tcp + + + + 388 + + + + depth + + + + 389 + + + + fake_buttons + + + + 391 + + + + sync_keymap + + + + 392 + + + + enable_keyequivs + + + + 393 + + + + prefs_changed: + + + + 394 + + + + prefs_changed: + + + + 395 + + + + prefs_changed: + + + + 396 + + + + prefs_changed: + + + + 398 + + + + prefs_changed: + + + + 399 + + + + prefs_changed: + + + + 401 + + + + prefs_panel + + + + 402 + + + + x11_help: + + + + 422 + + + + dockMenu + + + + 426 + + + + dock_menu + + + + 428 + + + + delegate + + + + 429 + + + + hide: + + + + 430 + + + + unhideAllApplications: + + + + 431 + + + + orderFrontStandardAboutPanel: + + + + 433 + + + + dock_apps_menu + + + + 530 + + + + dock_window_separator + + + + 531 + + + + apps_table_show: + + + + 534 + + + + next_window: + + + + 539 + + + + previous_window: + + + + 540 + + + + enable_fullscreen + + + + 546 + + + + enable_fullscreen_changed: + + + + 547 + + + + toggle_fullscreen: + + + + 548 + + + + toggle_fullscreen_item + + + + 549 + + + + menu + + + + 300334 + + + + terminate: + + + + 300336 + + + + prefs_changed: + + + + 300389 + + + + prefs_changed: + + + + 300390 + + + + prefs_changed: + + + + 300391 + + + + click_through + + + + 300392 + + + + focus_follows_mouse + + + + 300393 + + + + focus_on_new_window + + + + 300394 + + + + copy_menu_item + + + + 300443 + + + + sync_pasteboard + + + + 300444 + + + + sync_clipboard_to_pasteboard + + + + 300461 + + + + sync_pasteboard_to_clipboard + + + + 300462 + + + + sync_pasteboard_to_primary + + + + 300463 + + + + sync_primary_immediately + + + + 300464 + + + + prefs_changed: + + + + 300465 + + + + prefs_changed: + + + + 300466 + + + + prefs_changed: + + + + 300467 + + + + prefs_changed: + + + + 300468 + + + + prefs_changed: + + + + 300469 + + + + sync_text1 + + + + 300470 + + + + sync_text2 + + + + 300471 + + + + enable_fullscreen_menu + + + + 300474 + + + + prefs_changed: + + + + 300475 + + + + prefs_changed: + + + + 300480 + + + + option_sends_alt + + + + 300481 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 203 + + + + + 204 + + + + + 536 + + + + + 537 + + + + + 538 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 544 + + + + + 545 + + + + + 163 + + + + + + + + 169 + + + + + + + + 157 + + + + + 269 + + + + + + + + 270 + + + + + + + + + 272 + + + + + 305 + + + + + 419 + + + + + + + + 420 + + + + + + + + 421 + + + + + 196 + + + X11Controller + + + 244 + + + + + + PrefsPanel + + + 245 + + + + + + + + 348 + + + + + + + + + + + + 349 + + + + + + + + 351 + + + + + + + + + + + + + + + 363 + + + + + + + + 364 + + + + + + + + 365 + + + + + + + + 368 + + + + + + + + 369 + + + + + + + + 370 + + + + + + + + 352 + + + + + + + + 350 + + + + + + + + + + + + + 382 + + + + + + + + 385 + + + + + + + + 386 + + + + + + + + 541 + + + + + + + + 543 + + + + + + + + 353 + + + + + + + + 354 + + + + + + + + + + + + 374 + + + + + + + + 375 + + + + + + + + 376 + + + + + + + + 377 + + + + + + + + 379 + + + + + + + + 285 + + + + + + EditPrograms + + + 286 + + + + + + + + + + + 423 + + + + + + + DockMenu + + + 524 + + + + + 526 + + + + + + + + 527 + + + + + + + + + 532 + + + + + 533 + + + + + 100363 + + + + + 100364 + + + + + 100365 + + + + + 100368 + + + + + 100369 + + + + + 100370 + + + + + 100382 + + + + + + + + 100385 + + + + + 100386 + + + + + 100541 + + + + + 100543 + + + + + 100374 + + + + + 100375 + + + + + 100376 + + + + + 100377 + + + + + 100379 + + + + + 380 + + + + + + + + + + + 435 + + + + + 384 + + + + + 383 + + + + + 381 + + + + + 295 + + + + + + + + + + + 300295 + + + + + 200295 + + + + + 100295 + + + + + 296 + + + + + + + + + + 535 + + + + + + + + 575 + + + + + 298 + + + + + + + + 573 + + + + + 297 + + + + + + + + 574 + + + + + 310 + + + + + + + + 100310 + + + + + 292 + + + + + + + + 100292 + + + + + 293 + + + + + + + + 100293 + + + + + 300337 + + + + + + + + 300338 + + + + + + + + + + + + + 300358 + + + + + + + + 300359 + + + + + + + + 300360 + + + + + 300361 + + + + + 300362 + + + + + + + + 300363 + + + + + 300364 + + + + + + + + 300365 + + + + + 300368 + + + + + + + + 300369 + + + + + 300370 + + + + + + + + 300371 + + + + + 300421 + + + + + + + + 300422 + + + + + + + + + + + + + + + 300423 + + + + + + + + 300424 + + + + + + + + 300440 + + + + + 300441 + + + + + 300447 + + + + + + + + 300450 + + + + + 300451 + + + + + + + + 300452 + + + + + 300453 + + + + + + + + 300454 + + + + + 300455 + + + + + + + + 300456 + + + + + 300457 + + + + + + + + 300458 + + + + + 300459 + + + + + + + + 300460 + + + + + 300472 + + + + + + + + 300473 + + + + + 300476 + + + + + + + + 300477 + + + + + + + + 300478 + + + + + 300479 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{168, 821}, {113, 23}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{202, 626}, {154, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{349, 868}, {315, 143}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{271, 666}, {301, 153}} + {{507, 565}, {484, 308}} + com.apple.InterfaceBuilder.CocoaPlugin + {{507, 565}, {484, 308}} + + {{184, 290}, {481, 345}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{58, 803}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{100, 746}, {155, 33}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{68, 585}, {454, 271}} + com.apple.InterfaceBuilder.CocoaPlugin + + + {{68, 585}, {454, 271}} + + {{433, 406}, {486, 327}} + + + {3.40282e+38, 3.40282e+38} + {320, 240} + com.apple.InterfaceBuilder.CocoaPlugin + + {{145, 1011}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{67, 819}, {336, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{20, 641}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + {{79, 616}, {218, 203}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 300481 + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSFormatter + NSObject + + IBUserSource + + + + + X11Controller + NSObject + + IBUserSource + + + + + + + X11Controller + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + apps_table_delete: + id + + + apps_table_done: + id + + + apps_table_duplicate: + id + + + apps_table_new: + id + + + apps_table_show: + id + + + bring_to_front: + id + + + close_window: + id + + + enable_fullscreen_changed: + id + + + minimize_window: + id + + + next_window: + id + + + prefs_changed: + id + + + prefs_show: + id + + + previous_window: + id + + + quit: + id + + + toggle_fullscreen: + id + + + x11_help: + id + + + zoom_window: + id + + + + NSMenuItem + NSTableView + NSButton + NSMenuItem + NSPopUpButton + NSMenu + NSMenu + NSMenuItem + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSPanel + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSTextField + NSTextField + NSMenuItem + NSButton + NSMenuItem + NSMenuItem + + + + apps_separator + NSMenuItem + + + apps_table + NSTableView + + + click_through + NSButton + + + copy_menu_item + NSMenuItem + + + depth + NSPopUpButton + + + dock_apps_menu + NSMenu + + + dock_menu + NSMenu + + + dock_window_separator + NSMenuItem + + + enable_auth + NSButton + + + enable_fullscreen + NSButton + + + enable_fullscreen_menu + NSButton + + + enable_keyequivs + NSButton + + + enable_tcp + NSButton + + + fake_buttons + NSButton + + + focus_follows_mouse + NSButton + + + focus_on_new_window + NSButton + + + option_sends_alt + NSButton + + + prefs_panel + NSPanel + + + sync_clipboard_to_pasteboard + NSButton + + + sync_keymap + NSButton + + + sync_pasteboard + NSButton + + + sync_pasteboard_to_clipboard + NSButton + + + sync_pasteboard_to_primary + NSButton + + + sync_primary_immediately + NSButton + + + sync_text1 + NSTextField + + + sync_text2 + NSTextField + + + toggle_fullscreen_item + NSMenuItem + + + use_sysbeep + NSButton + + + window_separator + NSMenuItem + + + x11_about_item + NSMenuItem + + + + IBDocumentRelativeSource + ../../../X11Controller.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../X11.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + + + diff --git a/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/keyedobjects.nib b/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/keyedobjects.nib index e08046e00..6872c5064 100644 Binary files a/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/keyedobjects.nib and b/xorg-server/hw/xquartz/bundle/Resources/zh_TW.lproj/main.nib/keyedobjects.nib differ diff --git a/xorg-server/hw/xquartz/darwinEvents.c b/xorg-server/hw/xquartz/darwinEvents.c index ec320b3a5..16fec4a01 100644 --- a/xorg-server/hw/xquartz/darwinEvents.c +++ b/xorg-server/hw/xquartz/darwinEvents.c @@ -1,586 +1,585 @@ -/* -Darwin event queue and event handling - -Copyright 2007-2008 Apple Inc. -Copyright 2004 Kaleb S. KEITHLEY. All Rights Reserved. -Copyright (c) 2002-2004 Torrey T. Lyons. All Rights Reserved. - -This file is based on mieq.c by Keith Packard, -which contains the following copyright: -Copyright 1990, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - */ - -#include "sanitizedCarbon.h" - -#ifdef HAVE_DIX_CONFIG_H -#include -#endif - -#include -#include -#include -#include "misc.h" -#include "windowstr.h" -#include "pixmapstr.h" -#include "inputstr.h" -#include "inpututils.h" -#include "eventstr.h" -#include "mi.h" -#include "scrnintstr.h" -#include "mipointer.h" -#include "os.h" - -#include "darwin.h" -#include "quartz.h" -#include "quartzKeyboard.h" -#include "quartzRandR.h" -#include "darwinEvents.h" - -#include -#include -#include -#include -#include - -#include - -/* Fake button press/release for scroll wheel move. */ -#define SCROLLWHEELUPFAKE 4 -#define SCROLLWHEELDOWNFAKE 5 -#define SCROLLWHEELLEFTFAKE 6 -#define SCROLLWHEELRIGHTFAKE 7 - -#include -#include "applewmExt.h" - -/* FIXME: Abstract this better */ -extern Bool QuartzModeEventHandler(int screenNum, XQuartzEvent *e, DeviceIntPtr dev); - -int darwin_all_modifier_flags = 0; // last known modifier state -int darwin_all_modifier_mask = 0; -int darwin_x11_modifier_mask = 0; - -#define FD_ADD_MAX 128 -static int fd_add[FD_ADD_MAX]; -int fd_add_count = 0; -static pthread_mutex_t fd_add_lock = PTHREAD_MUTEX_INITIALIZER; -static pthread_cond_t fd_add_ready_cond = PTHREAD_COND_INITIALIZER; -static pthread_t fd_add_tid = NULL; - -static EventListPtr darwinEvents = NULL; - -static pthread_mutex_t mieq_lock = PTHREAD_MUTEX_INITIALIZER; -static pthread_cond_t mieq_ready_cond = PTHREAD_COND_INITIALIZER; - -/*** Pthread Magics ***/ -static pthread_t create_thread(void *func, void *arg) { - pthread_attr_t attr; - pthread_t tid; - - pthread_attr_init (&attr); - pthread_attr_setscope (&attr, PTHREAD_SCOPE_SYSTEM); - pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED); - pthread_create (&tid, &attr, func, arg); - pthread_attr_destroy (&attr); - - return tid; -} - -void darwinEvents_lock(void); -void darwinEvents_lock(void) { - int err; - if((err = pthread_mutex_lock(&mieq_lock))) { - ErrorF("%s:%s:%d: Failed to lock mieq_lock: %d\n", - __FILE__, __FUNCTION__, __LINE__, err); - spewCallStack(); - } - if(darwinEvents == NULL) { - pthread_cond_wait(&mieq_ready_cond, &mieq_lock); - } -} - -void darwinEvents_unlock(void); -void darwinEvents_unlock(void) { - int err; - if((err = pthread_mutex_unlock(&mieq_lock))) { - ErrorF("%s:%s:%d: Failed to unlock mieq_lock: %d\n", - __FILE__, __FUNCTION__, __LINE__, err); - spewCallStack(); - } -} - -/* - * DarwinPressModifierKey - * Press or release the given modifier key (one of NX_MODIFIERKEY_* constants) - */ -static void DarwinPressModifierKey(int pressed, int key) { - int keycode = DarwinModifierNXKeyToNXKeycode(key, 0); - - if (keycode == 0) { - ErrorF("DarwinPressModifierKey bad keycode: key=%d\n", key); - return; - } - - DarwinSendKeyboardEvents(pressed, keycode); -} - -/* - * DarwinUpdateModifiers - * Send events to update the modifier state. - */ - -static int darwin_x11_modifier_mask_list[] = { -#ifdef NX_DEVICELCMDKEYMASK - NX_DEVICELCTLKEYMASK, NX_DEVICERCTLKEYMASK, - NX_DEVICELSHIFTKEYMASK, NX_DEVICERSHIFTKEYMASK, - NX_DEVICELCMDKEYMASK, NX_DEVICERCMDKEYMASK, - NX_DEVICELALTKEYMASK, NX_DEVICERALTKEYMASK, -#else - NX_CONTROLMASK, NX_SHIFTMASK, NX_COMMANDMASK, NX_ALTERNATEMASK, -#endif - NX_ALPHASHIFTMASK, - 0 -}; - -static int darwin_all_modifier_mask_additions[] = { NX_SECONDARYFNMASK, }; - -static void DarwinUpdateModifiers( - int pressed, // KeyPress or KeyRelease - int flags ) // modifier flags that have changed -{ - int *f; - int key; - - /* Capslock is special. This mask is the state of capslock (on/off), - * not the state of the button. Hopefully we can find a better solution. - */ - if(NX_ALPHASHIFTMASK & flags) { - DarwinPressModifierKey(KeyPress, NX_MODIFIERKEY_ALPHALOCK); - DarwinPressModifierKey(KeyRelease, NX_MODIFIERKEY_ALPHALOCK); - } - - for(f=darwin_x11_modifier_mask_list; *f; f++) - if(*f & flags && *f != NX_ALPHASHIFTMASK) { - key = DarwinModifierNXMaskToNXKey(*f); - if(key == -1) - ErrorF("DarwinUpdateModifiers: Unsupported NXMask: 0x%x\n", *f); - else - DarwinPressModifierKey(pressed, key); - } -} - -/* Generic handler for Xquartz-specifc events. When possible, these should - be moved into their own individual functions and set as handlers using - mieqSetHandler. */ - -static void DarwinEventHandler(int screenNum, InternalEvent *ie, DeviceIntPtr dev) { - XQuartzEvent *e = &(ie->xquartz_event); - - TA_SERVER(); - - switch(e->subtype) { - case kXquartzControllerNotify: - DEBUG_LOG("kXquartzControllerNotify\n"); - AppleWMSendEvent(AppleWMControllerNotify, - AppleWMControllerNotifyMask, - e->data[0], - e->data[1]); - break; - - case kXquartzPasteboardNotify: - DEBUG_LOG("kXquartzPasteboardNotify\n"); - AppleWMSendEvent(AppleWMPasteboardNotify, - AppleWMPasteboardNotifyMask, - e->data[0], - e->data[1]); - break; - - case kXquartzActivate: - DEBUG_LOG("kXquartzActivate\n"); - QuartzShow(); - AppleWMSendEvent(AppleWMActivationNotify, - AppleWMActivationNotifyMask, - AppleWMIsActive, 0); - break; - - case kXquartzDeactivate: - DEBUG_LOG("kXquartzDeactivate\n"); - AppleWMSendEvent(AppleWMActivationNotify, - AppleWMActivationNotifyMask, - AppleWMIsInactive, 0); - QuartzHide(); - break; - - case kXquartzReloadPreferences: - DEBUG_LOG("kXquartzReloadPreferences\n"); - AppleWMSendEvent(AppleWMActivationNotify, - AppleWMActivationNotifyMask, - AppleWMReloadPreferences, 0); - break; - - case kXquartzToggleFullscreen: - DEBUG_LOG("kXquartzToggleFullscreen\n"); - if(XQuartzIsRootless) - ErrorF("Ignoring kXquartzToggleFullscreen because of rootless mode."); - else - QuartzRandRToggleFullscreen(); - break; - - case kXquartzSetRootless: - DEBUG_LOG("kXquartzSetRootless\n"); - if(e->data[0]) { - QuartzRandRSetFakeRootless(); - } else { - QuartzRandRSetFakeFullscreen(FALSE); - } - break; - - case kXquartzSetRootClip: - QuartzSetRootClip((Bool)e->data[0]); - break; - - case kXquartzQuit: - GiveUp(0); - break; - - case kXquartzSpaceChanged: - DEBUG_LOG("kXquartzSpaceChanged\n"); - QuartzSpaceChanged(e->data[0]); - break; - - case kXquartzListenOnOpenFD: - ErrorF("Calling ListenOnOpenFD() for new fd: %d\n", (int)e->data[0]); - ListenOnOpenFD((int)e->data[0], 1); - break; - - case kXquartzReloadKeymap: - DarwinKeyboardReloadHandler(); - break; - - case kXquartzDisplayChanged: - DEBUG_LOG("kXquartzDisplayChanged\n"); - QuartzUpdateScreens(); -#ifdef RANDR - /* Update our RandR info */ - QuartzRandRUpdateFakeModes(TRUE); -#endif - break; - - default: - if(!QuartzModeEventHandler(screenNum, e, dev)) - ErrorF("Unknown application defined event type %d.\n", e->subtype); - } -} - -void DarwinListenOnOpenFD(int fd) { - ErrorF("DarwinListenOnOpenFD: %d\n", fd); - - pthread_mutex_lock(&fd_add_lock); - if(fd_add_count < FD_ADD_MAX) - fd_add[fd_add_count++] = fd; - else - ErrorF("FD Addition buffer at max. Dropping fd addition request.\n"); - - pthread_cond_broadcast(&fd_add_ready_cond); - pthread_mutex_unlock(&fd_add_lock); -} - -static void DarwinProcessFDAdditionQueue_thread(void *args) { - pthread_mutex_lock(&fd_add_lock); - while(true) { - while(fd_add_count) { - DarwinSendDDXEvent(kXquartzListenOnOpenFD, 1, fd_add[--fd_add_count]); - } - pthread_cond_wait(&fd_add_ready_cond, &fd_add_lock); - } -} - -Bool DarwinEQInit(void) { - int *p; - - for(p=darwin_x11_modifier_mask_list, darwin_all_modifier_mask=0; *p; p++) { - darwin_x11_modifier_mask |= *p; - } - - for(p=darwin_all_modifier_mask_additions, darwin_all_modifier_mask= darwin_x11_modifier_mask; *p; p++) { - darwin_all_modifier_mask |= *p; - } - - mieqInit(); - mieqSetHandler(ET_XQuartz, DarwinEventHandler); - - /* Note that this *could* cause a potential async issue, since we're checking - * darwinEvents without holding the lock, but darwinEvents is only ever set - * here, so I don't bother. - */ - if (!darwinEvents) { - darwinEvents = InitEventList(GetMaximumEventsNum());; - - if (!darwinEvents) - FatalError("Couldn't allocate event buffer\n"); - - darwinEvents_lock(); - pthread_cond_broadcast(&mieq_ready_cond); - darwinEvents_unlock(); - } - - if(!fd_add_tid) - fd_add_tid = create_thread(DarwinProcessFDAdditionQueue_thread, NULL); - - return TRUE; -} - -/* - * ProcessInputEvents - * Read and process events from the event queue until it is empty. - */ -void ProcessInputEvents(void) { - char nullbyte; - int x = sizeof(nullbyte); - - TA_SERVER(); - - mieqProcessInputEvents(); - - // Empty the signaling pipe - while (x == sizeof(nullbyte)) { - x = read(darwinEventReadFD, &nullbyte, sizeof(nullbyte)); - } -} - -/* Sends a null byte down darwinEventWriteFD, which will cause the - Dispatch() event loop to check out event queue */ -static void DarwinPokeEQ(void) { - char nullbyte=0; - // oh, i ... er ... christ. - write(darwinEventWriteFD, &nullbyte, sizeof(nullbyte)); -} - -/* Convert from Appkit pointer input values to X input values: - * Note: pointer_x and pointer_y are relative to the upper-left of primary - * display. - */ -static void DarwinPrepareValuators(DeviceIntPtr pDev, int *valuators, ScreenPtr screen, - float pointer_x, float pointer_y, - float pressure, float tilt_x, float tilt_y) { - /* Fix offset between darwin and X screens */ - pointer_x -= darwinMainScreenX + screen->x; - pointer_y -= darwinMainScreenY + screen->y; - - if(pointer_x < 0.0) - pointer_x = 0.0; - - if(pointer_y < 0.0) - pointer_y = 0.0; - - if(pDev == darwinPointer) { - valuators[0] = pointer_x; - valuators[1] = pointer_y; - valuators[2] = 0; - valuators[3] = 0; - valuators[4] = 0; - } else { - /* Setup our array of values */ - valuators[0] = XQUARTZ_VALUATOR_LIMIT * (pointer_x / (float)screenInfo.screens[0]->width); - valuators[1] = XQUARTZ_VALUATOR_LIMIT * (pointer_y / (float)screenInfo.screens[0]->height); - valuators[2] = XQUARTZ_VALUATOR_LIMIT * pressure; - valuators[3] = XQUARTZ_VALUATOR_LIMIT * tilt_x; - valuators[4] = XQUARTZ_VALUATOR_LIMIT * tilt_y; - } - //DEBUG_LOG("Pointer (%f, %f), Valuators: {%d,%d,%d,%d,%d}\n", pointer_x, pointer_y, - // valuators[0], valuators[1], valuators[2], valuators[3], valuators[4]); -} - -void DarwinSendPointerEvents(DeviceIntPtr pDev, int ev_type, int ev_button, float pointer_x, float pointer_y, - float pressure, float tilt_x, float tilt_y) { - static int darwinFakeMouseButtonDown = 0; - int i, num_events; - ScreenPtr screen; - int valuators[5]; - - //DEBUG_LOG("x=%f, y=%f, p=%f, tx=%f, ty=%f\n", pointer_x, pointer_y, pressure, tilt_x, tilt_y); - - if(!darwinEvents) { - DEBUG_LOG("DarwinSendPointerEvents called before darwinEvents was initialized\n"); - return; - } - - screen = miPointerGetScreen(pDev); - if(!screen) { - DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n"); - return; - } - - /* Handle fake click */ - if (ev_type == ButtonPress && darwinFakeButtons && ev_button == 1) { - if(darwinFakeMouseButtonDown != 0) { - /* We're currently "down" with another button, so release it first */ - DarwinSendPointerEvents(pDev, ButtonRelease, darwinFakeMouseButtonDown, pointer_x, pointer_y, pressure, tilt_x, tilt_y); - darwinFakeMouseButtonDown=0; - } - if (darwin_all_modifier_flags & darwinFakeMouse2Mask) { - ev_button = 2; - darwinFakeMouseButtonDown = 2; - DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask); - } else if (darwin_all_modifier_flags & darwinFakeMouse3Mask) { - ev_button = 3; - darwinFakeMouseButtonDown = 3; - DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask); - } - } - - if (ev_type == ButtonRelease && ev_button == 1) { - if(darwinFakeMouseButtonDown) { - ev_button = darwinFakeMouseButtonDown; - } - - if(darwinFakeMouseButtonDown == 2) { - DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask); - } else if(darwinFakeMouseButtonDown == 3) { - DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask); - } - - darwinFakeMouseButtonDown = 0; - } - - DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, pressure, tilt_x, tilt_y); - darwinEvents_lock(); { - ValuatorMask mask; - valuator_mask_set_range(&mask, 0, (pDev == darwinTabletCurrent) ? 5 : 2, valuators); - num_events = GetPointerEvents(darwinEvents, pDev, ev_type, ev_button, - POINTER_ABSOLUTE, &mask); - for(i=0; i 0) DarwinPokeEQ(); - } darwinEvents_unlock(); -} - -void DarwinSendKeyboardEvents(int ev_type, int keycode) { - int i, num_events; - - if(!darwinEvents) { - DEBUG_LOG("DarwinSendKeyboardEvents called before darwinEvents was initialized\n"); - return; - } - - darwinEvents_lock(); { - num_events = GetKeyboardEvents(darwinEvents, darwinKeyboard, ev_type, keycode + MIN_KEYCODE); - for(i=0; i 0) DarwinPokeEQ(); - } darwinEvents_unlock(); -} - -void DarwinSendProximityEvents(int ev_type, float pointer_x, float pointer_y) { - int i, num_events; - ScreenPtr screen; - DeviceIntPtr pDev = darwinTabletCurrent; - int valuators[5]; - - DEBUG_LOG("DarwinSendProximityEvents(%d, %f, %f)\n", ev_type, pointer_x, pointer_y); - - if(!darwinEvents) { - DEBUG_LOG("DarwinSendProximityEvents called before darwinEvents was initialized\n"); - return; - } - - screen = miPointerGetScreen(pDev); - if(!screen) { - DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n"); - return; - } - - DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, 0.0f, 0.0f, 0.0f); - darwinEvents_lock(); { - ValuatorMask mask; - valuator_mask_set_range(&mask, 0, 5, valuators); - num_events = GetProximityEvents(darwinEvents, pDev, ev_type, &mask); - for(i=0; i 0) DarwinPokeEQ(); - } darwinEvents_unlock(); -} - - -/* Send the appropriate number of button clicks to emulate scroll wheel */ -void DarwinSendScrollEvents(float count_x, float count_y, - float pointer_x, float pointer_y, - float pressure, float tilt_x, float tilt_y) { - int sign_x, sign_y; - if(!darwinEvents) { - DEBUG_LOG("DarwinSendScrollEvents called before darwinEvents was initialized\n"); - return; - } - - sign_x = count_x > 0.0f ? SCROLLWHEELLEFTFAKE : SCROLLWHEELRIGHTFAKE; - sign_y = count_y > 0.0f ? SCROLLWHEELUPFAKE : SCROLLWHEELDOWNFAKE; - count_x = fabs(count_x); - count_y = fabs(count_y); - - while ((count_x > 0.0f) || (count_y > 0.0f)) { - if (count_x > 0.0f) { - DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y); - DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y); - count_x = count_x - 1.0f; - } - if (count_y > 0.0f) { - DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y); - DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y); - count_y = count_y - 1.0f; - } - } -} - -/* Send the appropriate KeyPress/KeyRelease events to GetKeyboardEvents to - reflect changing modifier flags (alt, control, meta, etc) */ -void DarwinUpdateModKeys(int flags) { - DarwinUpdateModifiers(KeyRelease, darwin_all_modifier_flags & ~flags & darwin_x11_modifier_mask); - DarwinUpdateModifiers(KeyPress, ~darwin_all_modifier_flags & flags & darwin_x11_modifier_mask); - darwin_all_modifier_flags = flags; -} - -/* - * DarwinSendDDXEvent - * Send the X server thread a message by placing it on the event queue. - */ -void DarwinSendDDXEvent(int type, int argc, ...) { - XQuartzEvent e; - int i; - va_list args; - - memset(&e, 0, sizeof(e)); - e.header = ET_Internal; - e.type = ET_XQuartz; - e.length = sizeof(e); - e.time = GetTimeInMillis(); - e.subtype = type; - - if (argc > 0 && argc < XQUARTZ_EVENT_MAXARGS) { - va_start (args, argc); - for (i = 0; i < argc; i++) - e.data[i] = (uint32_t) va_arg (args, uint32_t); - va_end (args); - } - - darwinEvents_lock(); { - mieqEnqueue(NULL, (InternalEvent*)&e); - DarwinPokeEQ(); - } darwinEvents_unlock(); -} +/* +Darwin event queue and event handling + +Copyright 2007-2008 Apple Inc. +Copyright 2004 Kaleb S. KEITHLEY. All Rights Reserved. +Copyright (c) 2002-2004 Torrey T. Lyons. All Rights Reserved. + +This file is based on mieq.c by Keith Packard, +which contains the following copyright: +Copyright 1990, 1998 The Open Group + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation. + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + */ + +#include "sanitizedCarbon.h" + +#ifdef HAVE_DIX_CONFIG_H +#include +#endif + +#include +#include +#include +#include "misc.h" +#include "windowstr.h" +#include "pixmapstr.h" +#include "inputstr.h" +#include "inpututils.h" +#include "eventstr.h" +#include "mi.h" +#include "scrnintstr.h" +#include "mipointer.h" +#include "os.h" + +#include "darwin.h" +#include "quartz.h" +#include "quartzKeyboard.h" +#include "quartzRandR.h" +#include "darwinEvents.h" + +#include +#include +#include +#include +#include + +#include + +/* Fake button press/release for scroll wheel move. */ +#define SCROLLWHEELUPFAKE 4 +#define SCROLLWHEELDOWNFAKE 5 +#define SCROLLWHEELLEFTFAKE 6 +#define SCROLLWHEELRIGHTFAKE 7 + +#include +#include "applewmExt.h" + +/* FIXME: Abstract this better */ +extern Bool QuartzModeEventHandler(int screenNum, XQuartzEvent *e, DeviceIntPtr dev); + +int darwin_all_modifier_flags = 0; // last known modifier state +int darwin_all_modifier_mask = 0; +int darwin_x11_modifier_mask = 0; + +#define FD_ADD_MAX 128 +static int fd_add[FD_ADD_MAX]; +int fd_add_count = 0; +static pthread_mutex_t fd_add_lock = PTHREAD_MUTEX_INITIALIZER; +static pthread_cond_t fd_add_ready_cond = PTHREAD_COND_INITIALIZER; +static pthread_t fd_add_tid = NULL; + +static EventListPtr darwinEvents = NULL; + +static pthread_mutex_t mieq_lock = PTHREAD_MUTEX_INITIALIZER; +static pthread_cond_t mieq_ready_cond = PTHREAD_COND_INITIALIZER; + +/*** Pthread Magics ***/ +static pthread_t create_thread(void *func, void *arg) { + pthread_attr_t attr; + pthread_t tid; + + pthread_attr_init (&attr); + pthread_attr_setscope (&attr, PTHREAD_SCOPE_SYSTEM); + pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED); + pthread_create (&tid, &attr, func, arg); + pthread_attr_destroy (&attr); + + return tid; +} + +void darwinEvents_lock(void); +void darwinEvents_lock(void) { + int err; + if((err = pthread_mutex_lock(&mieq_lock))) { + ErrorF("%s:%s:%d: Failed to lock mieq_lock: %d\n", + __FILE__, __FUNCTION__, __LINE__, err); + spewCallStack(); + } + if(darwinEvents == NULL) { + pthread_cond_wait(&mieq_ready_cond, &mieq_lock); + } +} + +void darwinEvents_unlock(void); +void darwinEvents_unlock(void) { + int err; + if((err = pthread_mutex_unlock(&mieq_lock))) { + ErrorF("%s:%s:%d: Failed to unlock mieq_lock: %d\n", + __FILE__, __FUNCTION__, __LINE__, err); + spewCallStack(); + } +} + +/* + * DarwinPressModifierKey + * Press or release the given modifier key (one of NX_MODIFIERKEY_* constants) + */ +static void DarwinPressModifierKey(int pressed, int key) { + int keycode = DarwinModifierNXKeyToNXKeycode(key, 0); + + if (keycode == 0) { + ErrorF("DarwinPressModifierKey bad keycode: key=%d\n", key); + return; + } + + DarwinSendKeyboardEvents(pressed, keycode); +} + +/* + * DarwinUpdateModifiers + * Send events to update the modifier state. + */ + +static int darwin_x11_modifier_mask_list[] = { +#ifdef NX_DEVICELCMDKEYMASK + NX_DEVICELCTLKEYMASK, NX_DEVICERCTLKEYMASK, + NX_DEVICELSHIFTKEYMASK, NX_DEVICERSHIFTKEYMASK, + NX_DEVICELCMDKEYMASK, NX_DEVICERCMDKEYMASK, + NX_DEVICELALTKEYMASK, NX_DEVICERALTKEYMASK, +#else + NX_CONTROLMASK, NX_SHIFTMASK, NX_COMMANDMASK, NX_ALTERNATEMASK, +#endif + NX_ALPHASHIFTMASK, + 0 +}; + +static int darwin_all_modifier_mask_additions[] = { NX_SECONDARYFNMASK, }; + +static void DarwinUpdateModifiers( + int pressed, // KeyPress or KeyRelease + int flags ) // modifier flags that have changed +{ + int *f; + int key; + + /* Capslock is special. This mask is the state of capslock (on/off), + * not the state of the button. Hopefully we can find a better solution. + */ + if(NX_ALPHASHIFTMASK & flags) { + DarwinPressModifierKey(KeyPress, NX_MODIFIERKEY_ALPHALOCK); + DarwinPressModifierKey(KeyRelease, NX_MODIFIERKEY_ALPHALOCK); + } + + for(f=darwin_x11_modifier_mask_list; *f; f++) + if(*f & flags && *f != NX_ALPHASHIFTMASK) { + key = DarwinModifierNXMaskToNXKey(*f); + if(key == -1) + ErrorF("DarwinUpdateModifiers: Unsupported NXMask: 0x%x\n", *f); + else + DarwinPressModifierKey(pressed, key); + } +} + +/* Generic handler for Xquartz-specifc events. When possible, these should + be moved into their own individual functions and set as handlers using + mieqSetHandler. */ + +static void DarwinEventHandler(int screenNum, InternalEvent *ie, DeviceIntPtr dev) { + XQuartzEvent *e = &(ie->xquartz_event); + + TA_SERVER(); + + switch(e->subtype) { + case kXquartzControllerNotify: + DEBUG_LOG("kXquartzControllerNotify\n"); + AppleWMSendEvent(AppleWMControllerNotify, + AppleWMControllerNotifyMask, + e->data[0], + e->data[1]); + break; + + case kXquartzPasteboardNotify: + DEBUG_LOG("kXquartzPasteboardNotify\n"); + AppleWMSendEvent(AppleWMPasteboardNotify, + AppleWMPasteboardNotifyMask, + e->data[0], + e->data[1]); + break; + + case kXquartzActivate: + DEBUG_LOG("kXquartzActivate\n"); + QuartzShow(); + AppleWMSendEvent(AppleWMActivationNotify, + AppleWMActivationNotifyMask, + AppleWMIsActive, 0); + break; + + case kXquartzDeactivate: + DEBUG_LOG("kXquartzDeactivate\n"); + AppleWMSendEvent(AppleWMActivationNotify, + AppleWMActivationNotifyMask, + AppleWMIsInactive, 0); + QuartzHide(); + break; + + case kXquartzReloadPreferences: + DEBUG_LOG("kXquartzReloadPreferences\n"); + AppleWMSendEvent(AppleWMActivationNotify, + AppleWMActivationNotifyMask, + AppleWMReloadPreferences, 0); + break; + + case kXquartzToggleFullscreen: + DEBUG_LOG("kXquartzToggleFullscreen\n"); + if(XQuartzIsRootless) + ErrorF("Ignoring kXquartzToggleFullscreen because of rootless mode."); + else + QuartzRandRToggleFullscreen(); + break; + + case kXquartzSetRootless: + DEBUG_LOG("kXquartzSetRootless\n"); + if(e->data[0]) { + QuartzRandRSetFakeRootless(); + } else { + QuartzRandRSetFakeFullscreen(FALSE); + } + break; + + case kXquartzSetRootClip: + QuartzSetRootClip((Bool)e->data[0]); + break; + + case kXquartzQuit: + GiveUp(0); + break; + + case kXquartzSpaceChanged: + DEBUG_LOG("kXquartzSpaceChanged\n"); + QuartzSpaceChanged(e->data[0]); + break; + + case kXquartzListenOnOpenFD: + ErrorF("Calling ListenOnOpenFD() for new fd: %d\n", (int)e->data[0]); + ListenOnOpenFD((int)e->data[0], 1); + break; + + case kXquartzReloadKeymap: + DarwinKeyboardReloadHandler(); + break; + + case kXquartzDisplayChanged: + DEBUG_LOG("kXquartzDisplayChanged\n"); + QuartzUpdateScreens(); + + /* Update our RandR info */ + QuartzRandRUpdateFakeModes(TRUE); + break; + + default: + if(!QuartzModeEventHandler(screenNum, e, dev)) + ErrorF("Unknown application defined event type %d.\n", e->subtype); + } +} + +void DarwinListenOnOpenFD(int fd) { + ErrorF("DarwinListenOnOpenFD: %d\n", fd); + + pthread_mutex_lock(&fd_add_lock); + if(fd_add_count < FD_ADD_MAX) + fd_add[fd_add_count++] = fd; + else + ErrorF("FD Addition buffer at max. Dropping fd addition request.\n"); + + pthread_cond_broadcast(&fd_add_ready_cond); + pthread_mutex_unlock(&fd_add_lock); +} + +static void DarwinProcessFDAdditionQueue_thread(void *args) { + pthread_mutex_lock(&fd_add_lock); + while(true) { + while(fd_add_count) { + DarwinSendDDXEvent(kXquartzListenOnOpenFD, 1, fd_add[--fd_add_count]); + } + pthread_cond_wait(&fd_add_ready_cond, &fd_add_lock); + } +} + +Bool DarwinEQInit(void) { + int *p; + + for(p=darwin_x11_modifier_mask_list, darwin_all_modifier_mask=0; *p; p++) { + darwin_x11_modifier_mask |= *p; + } + + for(p=darwin_all_modifier_mask_additions, darwin_all_modifier_mask= darwin_x11_modifier_mask; *p; p++) { + darwin_all_modifier_mask |= *p; + } + + mieqInit(); + mieqSetHandler(ET_XQuartz, DarwinEventHandler); + + /* Note that this *could* cause a potential async issue, since we're checking + * darwinEvents without holding the lock, but darwinEvents is only ever set + * here, so I don't bother. + */ + if (!darwinEvents) { + darwinEvents = InitEventList(GetMaximumEventsNum());; + + if (!darwinEvents) + FatalError("Couldn't allocate event buffer\n"); + + darwinEvents_lock(); + pthread_cond_broadcast(&mieq_ready_cond); + darwinEvents_unlock(); + } + + if(!fd_add_tid) + fd_add_tid = create_thread(DarwinProcessFDAdditionQueue_thread, NULL); + + return TRUE; +} + +/* + * ProcessInputEvents + * Read and process events from the event queue until it is empty. + */ +void ProcessInputEvents(void) { + char nullbyte; + int x = sizeof(nullbyte); + + TA_SERVER(); + + mieqProcessInputEvents(); + + // Empty the signaling pipe + while (x == sizeof(nullbyte)) { + x = read(darwinEventReadFD, &nullbyte, sizeof(nullbyte)); + } +} + +/* Sends a null byte down darwinEventWriteFD, which will cause the + Dispatch() event loop to check out event queue */ +static void DarwinPokeEQ(void) { + char nullbyte=0; + // oh, i ... er ... christ. + write(darwinEventWriteFD, &nullbyte, sizeof(nullbyte)); +} + +/* Convert from Appkit pointer input values to X input values: + * Note: pointer_x and pointer_y are relative to the upper-left of primary + * display. + */ +static void DarwinPrepareValuators(DeviceIntPtr pDev, int *valuators, ScreenPtr screen, + float pointer_x, float pointer_y, + float pressure, float tilt_x, float tilt_y) { + /* Fix offset between darwin and X screens */ + pointer_x -= darwinMainScreenX + screen->x; + pointer_y -= darwinMainScreenY + screen->y; + + if(pointer_x < 0.0) + pointer_x = 0.0; + + if(pointer_y < 0.0) + pointer_y = 0.0; + + if(pDev == darwinPointer) { + valuators[0] = pointer_x; + valuators[1] = pointer_y; + valuators[2] = 0; + valuators[3] = 0; + valuators[4] = 0; + } else { + /* Setup our array of values */ + valuators[0] = XQUARTZ_VALUATOR_LIMIT * (pointer_x / (float)screenInfo.screens[0]->width); + valuators[1] = XQUARTZ_VALUATOR_LIMIT * (pointer_y / (float)screenInfo.screens[0]->height); + valuators[2] = XQUARTZ_VALUATOR_LIMIT * pressure; + valuators[3] = XQUARTZ_VALUATOR_LIMIT * tilt_x; + valuators[4] = XQUARTZ_VALUATOR_LIMIT * tilt_y; + } + //DEBUG_LOG("Pointer (%f, %f), Valuators: {%d,%d,%d,%d,%d}\n", pointer_x, pointer_y, + // valuators[0], valuators[1], valuators[2], valuators[3], valuators[4]); +} + +void DarwinSendPointerEvents(DeviceIntPtr pDev, int ev_type, int ev_button, float pointer_x, float pointer_y, + float pressure, float tilt_x, float tilt_y) { + static int darwinFakeMouseButtonDown = 0; + int i, num_events; + ScreenPtr screen; + int valuators[5]; + + //DEBUG_LOG("x=%f, y=%f, p=%f, tx=%f, ty=%f\n", pointer_x, pointer_y, pressure, tilt_x, tilt_y); + + if(!darwinEvents) { + DEBUG_LOG("DarwinSendPointerEvents called before darwinEvents was initialized\n"); + return; + } + + screen = miPointerGetScreen(pDev); + if(!screen) { + DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n"); + return; + } + + /* Handle fake click */ + if (ev_type == ButtonPress && darwinFakeButtons && ev_button == 1) { + if(darwinFakeMouseButtonDown != 0) { + /* We're currently "down" with another button, so release it first */ + DarwinSendPointerEvents(pDev, ButtonRelease, darwinFakeMouseButtonDown, pointer_x, pointer_y, pressure, tilt_x, tilt_y); + darwinFakeMouseButtonDown=0; + } + if (darwin_all_modifier_flags & darwinFakeMouse2Mask) { + ev_button = 2; + darwinFakeMouseButtonDown = 2; + DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask); + } else if (darwin_all_modifier_flags & darwinFakeMouse3Mask) { + ev_button = 3; + darwinFakeMouseButtonDown = 3; + DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask); + } + } + + if (ev_type == ButtonRelease && ev_button == 1) { + if(darwinFakeMouseButtonDown) { + ev_button = darwinFakeMouseButtonDown; + } + + if(darwinFakeMouseButtonDown == 2) { + DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask); + } else if(darwinFakeMouseButtonDown == 3) { + DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask); + } + + darwinFakeMouseButtonDown = 0; + } + + DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, pressure, tilt_x, tilt_y); + darwinEvents_lock(); { + ValuatorMask mask; + valuator_mask_set_range(&mask, 0, (pDev == darwinTabletCurrent) ? 5 : 2, valuators); + num_events = GetPointerEvents(darwinEvents, pDev, ev_type, ev_button, + POINTER_ABSOLUTE, &mask); + for(i=0; i 0) DarwinPokeEQ(); + } darwinEvents_unlock(); +} + +void DarwinSendKeyboardEvents(int ev_type, int keycode) { + int i, num_events; + + if(!darwinEvents) { + DEBUG_LOG("DarwinSendKeyboardEvents called before darwinEvents was initialized\n"); + return; + } + + darwinEvents_lock(); { + num_events = GetKeyboardEvents(darwinEvents, darwinKeyboard, ev_type, keycode + MIN_KEYCODE); + for(i=0; i 0) DarwinPokeEQ(); + } darwinEvents_unlock(); +} + +void DarwinSendProximityEvents(int ev_type, float pointer_x, float pointer_y) { + int i, num_events; + ScreenPtr screen; + DeviceIntPtr pDev = darwinTabletCurrent; + int valuators[5]; + + DEBUG_LOG("DarwinSendProximityEvents(%d, %f, %f)\n", ev_type, pointer_x, pointer_y); + + if(!darwinEvents) { + DEBUG_LOG("DarwinSendProximityEvents called before darwinEvents was initialized\n"); + return; + } + + screen = miPointerGetScreen(pDev); + if(!screen) { + DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n"); + return; + } + + DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, 0.0f, 0.0f, 0.0f); + darwinEvents_lock(); { + ValuatorMask mask; + valuator_mask_set_range(&mask, 0, 5, valuators); + num_events = GetProximityEvents(darwinEvents, pDev, ev_type, &mask); + for(i=0; i 0) DarwinPokeEQ(); + } darwinEvents_unlock(); +} + + +/* Send the appropriate number of button clicks to emulate scroll wheel */ +void DarwinSendScrollEvents(float count_x, float count_y, + float pointer_x, float pointer_y, + float pressure, float tilt_x, float tilt_y) { + int sign_x, sign_y; + if(!darwinEvents) { + DEBUG_LOG("DarwinSendScrollEvents called before darwinEvents was initialized\n"); + return; + } + + sign_x = count_x > 0.0f ? SCROLLWHEELLEFTFAKE : SCROLLWHEELRIGHTFAKE; + sign_y = count_y > 0.0f ? SCROLLWHEELUPFAKE : SCROLLWHEELDOWNFAKE; + count_x = fabs(count_x); + count_y = fabs(count_y); + + while ((count_x > 0.0f) || (count_y > 0.0f)) { + if (count_x > 0.0f) { + DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y); + DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y); + count_x = count_x - 1.0f; + } + if (count_y > 0.0f) { + DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y); + DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y); + count_y = count_y - 1.0f; + } + } +} + +/* Send the appropriate KeyPress/KeyRelease events to GetKeyboardEvents to + reflect changing modifier flags (alt, control, meta, etc) */ +void DarwinUpdateModKeys(int flags) { + DarwinUpdateModifiers(KeyRelease, darwin_all_modifier_flags & ~flags & darwin_x11_modifier_mask); + DarwinUpdateModifiers(KeyPress, ~darwin_all_modifier_flags & flags & darwin_x11_modifier_mask); + darwin_all_modifier_flags = flags; +} + +/* + * DarwinSendDDXEvent + * Send the X server thread a message by placing it on the event queue. + */ +void DarwinSendDDXEvent(int type, int argc, ...) { + XQuartzEvent e; + int i; + va_list args; + + memset(&e, 0, sizeof(e)); + e.header = ET_Internal; + e.type = ET_XQuartz; + e.length = sizeof(e); + e.time = GetTimeInMillis(); + e.subtype = type; + + if (argc > 0 && argc < XQUARTZ_EVENT_MAXARGS) { + va_start (args, argc); + for (i = 0; i < argc; i++) + e.data[i] = (uint32_t) va_arg (args, uint32_t); + va_end (args); + } + + darwinEvents_lock(); { + mieqEnqueue(NULL, (InternalEvent*)&e); + DarwinPokeEQ(); + } darwinEvents_unlock(); +} diff --git a/xorg-server/hw/xquartz/quartz.c b/xorg-server/hw/xquartz/quartz.c index 6c185a8eb..222a5eab0 100644 --- a/xorg-server/hw/xquartz/quartz.c +++ b/xorg-server/hw/xquartz/quartz.c @@ -63,6 +63,7 @@ #include #include #include +#include #include #include @@ -143,6 +144,26 @@ void QuartzInitOutput( int argc, char **argv ) { + /* For XQuartz, we want to just use the default signal handler to work better with CrashTracer */ + signal(SIGSEGV, SIG_DFL); + signal(SIGILL, SIG_DFL); +#ifdef SIGEMT + signal(SIGEMT, SIG_DFL); +#endif + signal(SIGFPE, SIG_DFL); +#ifdef SIGBUS + signal(SIGBUS, SIG_DFL); +#endif +#ifdef SIGSYS + signal(SIGSYS, SIG_DFL); +#endif +#ifdef SIGXCPU + signal(SIGXCPU, SIG_DFL); +#endif +#ifdef SIGXFSZ + signal(SIGXFSZ, SIG_DFL); +#endif + if (!RegisterBlockAndWakeupHandlers(QuartzBlockHandler, QuartzWakeupHandler, NULL)) @@ -244,6 +265,9 @@ void QuartzUpdateScreens(void) { DeliverEvents(pRoot, &e, 1, NullWindow); quartzProcs->UpdateScreen(pScreen); + + /* Tell RandR about the new size, so new connections get the correct info */ + RRScreenSizeNotify(pScreen); } static void pokeActivityCallback(CFRunLoopTimerRef timer, void *info) { diff --git a/xorg-server/include/eventstr.h b/xorg-server/include/eventstr.h index 1705900f8..673207ce3 100644 --- a/xorg-server/include/eventstr.h +++ b/xorg-server/include/eventstr.h @@ -1,246 +1,246 @@ -/* - * Copyright © 2009 Red Hat, Inc. - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - * - */ - -#ifndef EVENTSTR_H -#define EVENTSTR_H - -#include -/** - * @file events.h - * This file describes the event structures used internally by the X - * server during event generation and event processing. - * - * When are internal events used? - * Events from input devices are stored as internal events in the EQ and - * processed as internal events until late in the processing cycle. Only then - * do they switch to their respective wire events. - */ - -/** - * Event types. Used exclusively internal to the server, not visible on the - * protocol. - * - * Note: Keep KeyPress to Motion aligned with the core events. - * Keep ET_Raw* in the same order as KeyPress - Motion - */ -enum EventType { - ET_KeyPress = 2, - ET_KeyRelease, - ET_ButtonPress, - ET_ButtonRelease, - ET_Motion, - ET_Enter, - ET_Leave, - ET_FocusIn, - ET_FocusOut, - ET_ProximityIn, - ET_ProximityOut, - ET_DeviceChanged, - ET_Hierarchy, - ET_DGAEvent, - ET_RawKeyPress, - ET_RawKeyRelease, - ET_RawButtonPress, - ET_RawButtonRelease, - ET_RawMotion, - ET_XQuartz, - ET_Internal = 0xFF /* First byte */ -}; - -#define CHECKEVENT(ev) if (ev && ((InternalEvent*)(ev))->any.header != 0xFF) \ - FatalError("Wrong event type %d.\n", \ - ((InternalEvent*)(ev))->any.header); - -/** - * Used for ALL input device events internal in the server until - * copied into the matching protocol event. - * - * Note: We only use the device id because the DeviceIntPtr may become invalid while - * the event is in the EQ. - */ -struct _DeviceEvent -{ - unsigned char header; /**< Always ET_Internal */ - enum EventType type; /**< One of EventType */ - int length; /**< Length in bytes */ - Time time; /**< Time in ms */ - int deviceid; /**< Device to post this event for */ - int sourceid; /**< The physical source device */ - union { - uint32_t button; /**< Button number */ - uint32_t key; /**< Key code */ - } detail; - int16_t root_x; /**< Pos relative to root window in integral data */ - float root_x_frac; /**< Pos relative to root window in frac part */ - int16_t root_y; /**< Pos relative to root window in integral part */ - float root_y_frac; /**< Pos relative to root window in frac part */ - uint8_t buttons[(MAX_BUTTONS + 7)/8]; /**< Button mask */ - struct { - uint8_t mask[(MAX_VALUATORS + 7)/8]; /**< Valuator mask */ - uint8_t mode[(MAX_VALUATORS + 7)/8]; /**< Valuator mode (Abs or Rel)*/ - int32_t data[MAX_VALUATORS]; /**< Valuator data */ - int32_t data_frac[MAX_VALUATORS]; /**< Fractional part for data */ - } valuators; - struct { - uint32_t base; /**< XKB base modifiers */ - uint32_t latched; /**< XKB latched modifiers */ - uint32_t locked; /**< XKB locked modifiers */ - uint32_t effective;/**< XKB effective modifiers */ - } mods; - struct { - uint8_t base; /**< XKB base group */ - uint8_t latched; /**< XKB latched group */ - uint8_t locked; /**< XKB locked group */ - uint8_t effective;/**< XKB effective group */ - } group; - Window root; /**< Root window of the event */ - int corestate; /**< Core key/button state BEFORE the event */ - int key_repeat; /**< Internally-generated key repeat event */ -}; - - -/* Flags used in DeviceChangedEvent to signal if the slave has changed */ -#define DEVCHANGE_SLAVE_SWITCH 0x2 -/* Flags used in DeviceChangedEvent to signal whether the event was a - * pointer event or a keyboard event */ -#define DEVCHANGE_POINTER_EVENT 0x4 -#define DEVCHANGE_KEYBOARD_EVENT 0x8 -/* device capabilities changed */ -#define DEVCHANGE_DEVICE_CHANGE 0x10 - -/** - * Sent whenever a device's capabilities have changed. - */ -struct _DeviceChangedEvent -{ - unsigned char header; /**< Always ET_Internal */ - enum EventType type; /**< ET_DeviceChanged */ - int length; /**< Length in bytes */ - Time time; /**< Time in ms */ - int deviceid; /**< Device whose capabilities have changed */ - int flags; /**< Mask of ::HAS_NEW_SLAVE, - ::POINTER_EVENT, ::KEYBOARD_EVENT */ - int masterid; /**< MD when event was generated */ - int sourceid; /**< The device that caused the change */ - - struct { - int num_buttons; /**< Number of buttons */ - Atom names[MAX_BUTTONS];/**< Button names */ - } buttons; - - int num_valuators; /**< Number of axes */ - struct { - uint32_t min; /**< Minimum value */ - uint32_t max; /**< Maximum value */ - /* FIXME: frac parts of min/max */ - uint32_t resolution; /**< Resolution counts/m */ - uint8_t mode; /**< Relative or Absolute */ - Atom name; /**< Axis name */ - } valuators[MAX_VALUATORS]; - - struct { - int min_keycode; - int max_keycode; - } keys; -}; - -#if XFreeXDGA -/** - * DGAEvent, used by DGA to intercept and emulate input events. - */ -struct _DGAEvent -{ - unsigned char header; /**< Always ET_Internal */ - enum EventType type; /**< ET_DGAEvent */ - int length; /**< Length in bytes */ - Time time; /**< Time in ms */ - int subtype; /**< KeyPress, KeyRelease, ButtonPress, - ButtonRelease, MotionNotify */ - int detail; /**< Relative x coordinate */ - int dx; /**< Relative x coordinate */ - int dy; /**< Relative y coordinate */ - int screen; /**< Screen number this event applies to */ - uint16_t state; /**< Core modifier/button state */ -}; -#endif - -/** - * Raw event, contains the data as posted by the device. - */ -struct _RawDeviceEvent -{ - unsigned char header; /**< Always ET_Internal */ - enum EventType type; /**< ET_Raw */ - int length; /**< Length in bytes */ - Time time; /**< Time in ms */ - int deviceid; /**< Device to post this event for */ - int sourceid; /**< The physical source device */ - union { - uint32_t button; /**< Button number */ - uint32_t key; /**< Key code */ - } detail; - struct { - uint8_t mask[(MAX_VALUATORS + 7)/8]; /**< Valuator mask */ - int32_t data[MAX_VALUATORS]; /**< Valuator data */ - int32_t data_frac[MAX_VALUATORS]; /**< Fractional part for data */ - int32_t data_raw[MAX_VALUATORS]; /**< Valuator data as posted */ - int32_t data_raw_frac[MAX_VALUATORS];/**< Fractional part for data_raw */ - } valuators; -}; - -#ifdef XQUARTZ -#define XQUARTZ_EVENT_MAXARGS 5 -struct _XQuartzEvent { - unsigned char header; /**< Always ET_Internal */ - enum EventType type; /**< Always ET_XQuartz */ - int length; /**< Length in bytes */ - Time time; /**< Time in ms. */ - int subtype; /**< Subtype defined by XQuartz DDX */ - uint32_t data[XQUARTZ_EVENT_MAXARGS]; /**< Up to 5 32bit values passed to handler */ -}; -#endif - -/** - * Event type used inside the X server for input event - * processing. - */ -union _InternalEvent { - struct { - unsigned char header; /**< Always ET_Internal */ - enum EventType type; /**< One of ET_* */ - int length; /**< Length in bytes */ - Time time; /**< Time in ms. */ - } any; - DeviceEvent device_event; - DeviceChangedEvent changed_event; -#if XFreeXDGA - DGAEvent dga_event; -#endif - RawDeviceEvent raw_event; -#ifdef XQUARTZ - XQuartzEvent xquartz_event; -#endif -}; - -#endif +/* + * Copyright © 2009 Red Hat, Inc. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sublicense, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the next + * paragraph) shall be included in all copies or substantial portions of the + * Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + * + */ + +#ifndef EVENTSTR_H +#define EVENTSTR_H + +#include +/** + * @file events.h + * This file describes the event structures used internally by the X + * server during event generation and event processing. + * + * When are internal events used? + * Events from input devices are stored as internal events in the EQ and + * processed as internal events until late in the processing cycle. Only then + * do they switch to their respective wire events. + */ + +/** + * Event types. Used exclusively internal to the server, not visible on the + * protocol. + * + * Note: Keep KeyPress to Motion aligned with the core events. + * Keep ET_Raw* in the same order as KeyPress - Motion + */ +enum EventType { + ET_KeyPress = 2, + ET_KeyRelease, + ET_ButtonPress, + ET_ButtonRelease, + ET_Motion, + ET_Enter, + ET_Leave, + ET_FocusIn, + ET_FocusOut, + ET_ProximityIn, + ET_ProximityOut, + ET_DeviceChanged, + ET_Hierarchy, + ET_DGAEvent, + ET_RawKeyPress, + ET_RawKeyRelease, + ET_RawButtonPress, + ET_RawButtonRelease, + ET_RawMotion, + ET_XQuartz, + ET_Internal = 0xFF /* First byte */ +}; + +#define CHECKEVENT(ev) if (ev && ((InternalEvent*)(ev))->any.header != 0xFF) \ + FatalError("Wrong event type %d.\n", \ + ((InternalEvent*)(ev))->any.header); + +/** + * Used for ALL input device events internal in the server until + * copied into the matching protocol event. + * + * Note: We only use the device id because the DeviceIntPtr may become invalid while + * the event is in the EQ. + */ +struct _DeviceEvent +{ + unsigned char header; /**< Always ET_Internal */ + enum EventType type; /**< One of EventType */ + int length; /**< Length in bytes */ + Time time; /**< Time in ms */ + int deviceid; /**< Device to post this event for */ + int sourceid; /**< The physical source device */ + union { + uint32_t button; /**< Button number */ + uint32_t key; /**< Key code */ + } detail; + int16_t root_x; /**< Pos relative to root window in integral data */ + float root_x_frac; /**< Pos relative to root window in frac part */ + int16_t root_y; /**< Pos relative to root window in integral part */ + float root_y_frac; /**< Pos relative to root window in frac part */ + uint8_t buttons[(MAX_BUTTONS + 7)/8]; /**< Button mask */ + struct { + uint8_t mask[(MAX_VALUATORS + 7)/8]; /**< Valuator mask */ + uint8_t mode[(MAX_VALUATORS + 7)/8]; /**< Valuator mode (Abs or Rel)*/ + int32_t data[MAX_VALUATORS]; /**< Valuator data */ + int32_t data_frac[MAX_VALUATORS]; /**< Fractional part for data */ + } valuators; + struct { + uint32_t base; /**< XKB base modifiers */ + uint32_t latched; /**< XKB latched modifiers */ + uint32_t locked; /**< XKB locked modifiers */ + uint32_t effective;/**< XKB effective modifiers */ + } mods; + struct { + uint8_t base; /**< XKB base group */ + uint8_t latched; /**< XKB latched group */ + uint8_t locked; /**< XKB locked group */ + uint8_t effective;/**< XKB effective group */ + } group; + Window root; /**< Root window of the event */ + int corestate; /**< Core key/button state BEFORE the event */ + int key_repeat; /**< Internally-generated key repeat event */ +}; + + +/* Flags used in DeviceChangedEvent to signal if the slave has changed */ +#define DEVCHANGE_SLAVE_SWITCH 0x2 +/* Flags used in DeviceChangedEvent to signal whether the event was a + * pointer event or a keyboard event */ +#define DEVCHANGE_POINTER_EVENT 0x4 +#define DEVCHANGE_KEYBOARD_EVENT 0x8 +/* device capabilities changed */ +#define DEVCHANGE_DEVICE_CHANGE 0x10 + +/** + * Sent whenever a device's capabilities have changed. + */ +struct _DeviceChangedEvent +{ + unsigned char header; /**< Always ET_Internal */ + enum EventType type; /**< ET_DeviceChanged */ + int length; /**< Length in bytes */ + Time time; /**< Time in ms */ + int deviceid; /**< Device whose capabilities have changed */ + int flags; /**< Mask of ::HAS_NEW_SLAVE, + ::POINTER_EVENT, ::KEYBOARD_EVENT */ + int masterid; /**< MD when event was generated */ + int sourceid; /**< The device that caused the change */ + + struct { + int num_buttons; /**< Number of buttons */ + Atom names[MAX_BUTTONS];/**< Button names */ + } buttons; + + int num_valuators; /**< Number of axes */ + struct { + uint32_t min; /**< Minimum value */ + uint32_t max; /**< Maximum value */ + /* FIXME: frac parts of min/max */ + uint32_t resolution; /**< Resolution counts/m */ + uint8_t mode; /**< Relative or Absolute */ + Atom name; /**< Axis name */ + } valuators[MAX_VALUATORS]; + + struct { + int min_keycode; + int max_keycode; + } keys; +}; + +#if XFreeXDGA +/** + * DGAEvent, used by DGA to intercept and emulate input events. + */ +struct _DGAEvent +{ + unsigned char header; /**< Always ET_Internal */ + enum EventType type; /**< ET_DGAEvent */ + int length; /**< Length in bytes */ + Time time; /**< Time in ms */ + int subtype; /**< KeyPress, KeyRelease, ButtonPress, + ButtonRelease, MotionNotify */ + int detail; /**< Button number or key code */ + int dx; /**< Relative x coordinate */ + int dy; /**< Relative y coordinate */ + int screen; /**< Screen number this event applies to */ + uint16_t state; /**< Core modifier/button state */ +}; +#endif + +/** + * Raw event, contains the data as posted by the device. + */ +struct _RawDeviceEvent +{ + unsigned char header; /**< Always ET_Internal */ + enum EventType type; /**< ET_Raw */ + int length; /**< Length in bytes */ + Time time; /**< Time in ms */ + int deviceid; /**< Device to post this event for */ + int sourceid; /**< The physical source device */ + union { + uint32_t button; /**< Button number */ + uint32_t key; /**< Key code */ + } detail; + struct { + uint8_t mask[(MAX_VALUATORS + 7)/8]; /**< Valuator mask */ + int32_t data[MAX_VALUATORS]; /**< Valuator data */ + int32_t data_frac[MAX_VALUATORS]; /**< Fractional part for data */ + int32_t data_raw[MAX_VALUATORS]; /**< Valuator data as posted */ + int32_t data_raw_frac[MAX_VALUATORS];/**< Fractional part for data_raw */ + } valuators; +}; + +#ifdef XQUARTZ +#define XQUARTZ_EVENT_MAXARGS 5 +struct _XQuartzEvent { + unsigned char header; /**< Always ET_Internal */ + enum EventType type; /**< Always ET_XQuartz */ + int length; /**< Length in bytes */ + Time time; /**< Time in ms. */ + int subtype; /**< Subtype defined by XQuartz DDX */ + uint32_t data[XQUARTZ_EVENT_MAXARGS]; /**< Up to 5 32bit values passed to handler */ +}; +#endif + +/** + * Event type used inside the X server for input event + * processing. + */ +union _InternalEvent { + struct { + unsigned char header; /**< Always ET_Internal */ + enum EventType type; /**< One of ET_* */ + int length; /**< Length in bytes */ + Time time; /**< Time in ms. */ + } any; + DeviceEvent device_event; + DeviceChangedEvent changed_event; +#if XFreeXDGA + DGAEvent dga_event; +#endif + RawDeviceEvent raw_event; +#ifdef XQUARTZ + XQuartzEvent xquartz_event; +#endif +}; + +#endif diff --git a/xorg-server/m4/ax_tls.m4 b/xorg-server/m4/ax_tls.m4 new file mode 100644 index 000000000..481c3d0c8 --- /dev/null +++ b/xorg-server/m4/ax_tls.m4 @@ -0,0 +1,74 @@ +# =========================================================================== +# http://www.nongnu.org/autoconf-archive/ax_tls.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_TLS +# +# DESCRIPTION +# +# Provides a test for the compiler support of thread local storage (TLS) +# extensions. Defines TLS if it is found. Currently only knows about GCC +# and MSVC. I think SunPro uses the same as GCC, and Borland apparently +# supports either. +# +# LICENSE +# +# Copyright (c) 2008 Alan Woodland +# +# This program is free software: you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation, either version 3 of the License, or (at your +# option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General +# Public License for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program. If not, see . +# +# As a special exception, the respective Autoconf Macro's copyright owner +# gives unlimited permission to copy, distribute and modify the configure +# scripts that are the output of Autoconf when processing the Macro. You +# need not follow the terms of the GNU General Public License when using +# or distributing such scripts, even though portions of the text of the +# Macro appear in them. The GNU General Public License (GPL) does govern +# all other use of the material that constitutes the Autoconf Macro. +# +# This special exception to the GPL applies to versions of the Autoconf +# Macro released by the Autoconf Archive. When you make and distribute a +# modified version of the Autoconf Macro, you may extend this special +# exception to the GPL to apply to your modified version as well. + +AC_DEFUN([AX_TLS], [ + AC_MSG_CHECKING(for thread local storage (TLS) class) + AC_CACHE_VAL(ac_cv_tls, [ + ax_tls_keywords="__thread __declspec(thread) none" + for ax_tls_keyword in $ax_tls_keywords; do + case $ax_tls_keyword in + none) ac_cv_tls=none ; break ;; + *) + AC_TRY_COMPILE( + [#include + static void + foo(void) { + static ] $ax_tls_keyword [ int bar; + exit(1); + }], + [], + [ac_cv_tls=$ax_tls_keyword ; break], + ac_cv_tls=none + ) + esac + done +]) + + if test "$ac_cv_tls" != "none"; then + dnl AC_DEFINE([TLS], [], [If the compiler supports a TLS storage class define it to that here]) + AC_DEFINE_UNQUOTED([TLS], $ac_cv_tls, [If the compiler supports a TLS storage class define it to that here]) + fi + AC_MSG_RESULT($ac_cv_tls) +]) diff --git a/xorg-server/xkb/xkb.c b/xorg-server/xkb/xkb.c index 0f6daa573..6fd66c5e5 100644 --- a/xorg-server/xkb/xkb.c +++ b/xorg-server/xkb/xkb.c @@ -1,6735 +1,6740 @@ -/************************************************************ -Copyright (c) 1993 by Silicon Graphics Computer Systems, Inc. - -Permission to use, copy, modify, and distribute this -software and its documentation for any purpose and without -fee is hereby granted, provided that the above copyright -notice appear in all copies and that both that copyright -notice and this permission notice appear in supporting -documentation, and that the name of Silicon Graphics not be -used in advertising or publicity pertaining to distribution -of the software without specific prior written permission. -Silicon Graphics makes no representation about the suitability -of this software for any purpose. It is provided "as is" -without any express or implied warranty. - -SILICON GRAPHICS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS -SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY -AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON -GRAPHICS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL -DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, -DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE -OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH -THE USE OR PERFORMANCE OF THIS SOFTWARE. - -********************************************************/ - -#ifdef HAVE_DIX_CONFIG_H -#include -#endif - -#include -#include -#include -#include "misc.h" -#include "inputstr.h" -#define XKBSRV_NEED_FILE_FUNCS -#include -#include "extnsionst.h" -#include "xace.h" -#include "xkb.h" -#include "protocol-versions.h" - -#include -#include - -int XkbEventBase; -static int XkbErrorBase; -int XkbReqCode; -int XkbKeyboardErrorCode; -CARD32 xkbDebugFlags = 0; -static CARD32 xkbDebugCtrls = 0; - -static RESTYPE RT_XKBCLIENT; - -/***====================================================================***/ - -#define CHK_DEVICE(dev, id, client, access_mode, lf) {\ - int why;\ - int rc = lf(&(dev), id, client, access_mode, &why);\ - if (rc != Success) {\ - client->errorValue = _XkbErrCode2(why, id);\ - return rc;\ - }\ -} - -#define CHK_KBD_DEVICE(dev, id, client, mode) \ - CHK_DEVICE(dev, id, client, mode, _XkbLookupKeyboard) -#define CHK_LED_DEVICE(dev, id, client, mode) \ - CHK_DEVICE(dev, id, client, mode, _XkbLookupLedDevice) -#define CHK_BELL_DEVICE(dev, id, client, mode) \ - CHK_DEVICE(dev, id, client, mode, _XkbLookupBellDevice) -#define CHK_ANY_DEVICE(dev, id, client, mode) \ - CHK_DEVICE(dev, id, client, mode, _XkbLookupAnyDevice) - -#define CHK_ATOM_ONLY2(a,ev,er) {\ - if (((a)==None)||(!ValidAtom((a)))) {\ - (ev)= (XID)(a);\ - return er;\ - }\ -} -#define CHK_ATOM_ONLY(a) \ - CHK_ATOM_ONLY2(a,client->errorValue,BadAtom) - -#define CHK_ATOM_OR_NONE3(a,ev,er,ret) {\ - if (((a)!=None)&&(!ValidAtom((a)))) {\ - (ev)= (XID)(a);\ - (er)= BadAtom;\ - return ret;\ - }\ -} -#define CHK_ATOM_OR_NONE2(a,ev,er) {\ - if (((a)!=None)&&(!ValidAtom((a)))) {\ - (ev)= (XID)(a);\ - return er;\ - }\ -} -#define CHK_ATOM_OR_NONE(a) \ - CHK_ATOM_OR_NONE2(a,client->errorValue,BadAtom) - -#define CHK_MASK_LEGAL3(err,mask,legal,ev,er,ret) {\ - if ((mask)&(~(legal))) { \ - (ev)= _XkbErrCode2((err),((mask)&(~(legal))));\ - (er)= BadValue;\ - return ret;\ - }\ -} -#define CHK_MASK_LEGAL2(err,mask,legal,ev,er) {\ - if ((mask)&(~(legal))) { \ - (ev)= _XkbErrCode2((err),((mask)&(~(legal))));\ - return er;\ - }\ -} -#define CHK_MASK_LEGAL(err,mask,legal) \ - CHK_MASK_LEGAL2(err,mask,legal,client->errorValue,BadValue) - -#define CHK_MASK_MATCH(err,affect,value) {\ - if ((value)&(~(affect))) { \ - client->errorValue= _XkbErrCode2((err),((value)&(~(affect))));\ - return BadMatch;\ - }\ -} -#define CHK_MASK_OVERLAP(err,m1,m2) {\ - if ((m1)&(m2)) { \ - client->errorValue= _XkbErrCode2((err),((m1)&(m2)));\ - return BadMatch;\ - }\ -} -#define CHK_KEY_RANGE2(err,first,num,x,ev,er) {\ - if (((unsigned)(first)+(num)-1)>(x)->max_key_code) {\ - (ev)=_XkbErrCode4(err,(first),(num),(x)->max_key_code);\ - return er;\ - }\ - else if ( (first)<(x)->min_key_code ) {\ - (ev)=_XkbErrCode3(err+1,(first),xkb->min_key_code);\ - return er;\ - }\ -} -#define CHK_KEY_RANGE(err,first,num,x) \ - CHK_KEY_RANGE2(err,first,num,x,client->errorValue,BadValue) - -#define CHK_REQ_KEY_RANGE2(err,first,num,r,ev,er) {\ - if (((unsigned)(first)+(num)-1)>(r)->maxKeyCode) {\ - (ev)=_XkbErrCode4(err,(first),(num),(r)->maxKeyCode);\ - return er;\ - }\ - else if ( (first)<(r)->minKeyCode ) {\ - (ev)=_XkbErrCode3(err+1,(first),(r)->minKeyCode);\ - return er;\ - }\ -} -#define CHK_REQ_KEY_RANGE(err,first,num,r) \ - CHK_REQ_KEY_RANGE2(err,first,num,r,client->errorValue,BadValue) - -/***====================================================================***/ - -int -ProcXkbUseExtension(ClientPtr client) -{ - REQUEST(xkbUseExtensionReq); - xkbUseExtensionReply rep; - register int n; - int supported; - - REQUEST_SIZE_MATCH(xkbUseExtensionReq); - if (stuff->wantedMajor != SERVER_XKB_MAJOR_VERSION) { - /* pre-release version 0.65 is compatible with 1.00 */ - supported= ((SERVER_XKB_MAJOR_VERSION==1)&& - (stuff->wantedMajor==0)&&(stuff->wantedMinor==65)); - } - else supported = 1; - - if ((supported) && (!(client->xkbClientFlags&_XkbClientInitialized))) { - client->xkbClientFlags= _XkbClientInitialized; - client->vMajor= stuff->wantedMajor; - client->vMinor= stuff->wantedMinor; - } - else if (xkbDebugFlags&0x1) { - ErrorF("[xkb] Rejecting client %d (0x%lx) (wants %d.%02d, have %d.%02d)\n", - client->index, - (long)client->clientAsMask, - stuff->wantedMajor,stuff->wantedMinor, - SERVER_XKB_MAJOR_VERSION,SERVER_XKB_MINOR_VERSION); - } - memset(&rep, 0, sizeof(xkbUseExtensionReply)); - rep.type = X_Reply; - rep.supported = supported; - rep.length = 0; - rep.sequenceNumber = client->sequence; - rep.serverMajor = SERVER_XKB_MAJOR_VERSION; - rep.serverMinor = SERVER_XKB_MINOR_VERSION; - if ( client->swapped ) { - swaps(&rep.sequenceNumber, n); - swaps(&rep.serverMajor, n); - swaps(&rep.serverMinor, n); - } - WriteToClient(client,SIZEOF(xkbUseExtensionReply), (char *)&rep); - return Success; -} - -/***====================================================================***/ - -int -ProcXkbSelectEvents(ClientPtr client) -{ - unsigned legal; - DeviceIntPtr dev; - XkbInterestPtr masks; - REQUEST(xkbSelectEventsReq); - - REQUEST_AT_LEAST_SIZE(xkbSelectEventsReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixUseAccess); - - if (((stuff->affectWhich&XkbMapNotifyMask)!=0)&&(stuff->affectMap)) { - client->mapNotifyMask&= ~stuff->affectMap; - client->mapNotifyMask|= (stuff->affectMap&stuff->map); - } - if ((stuff->affectWhich&(~XkbMapNotifyMask))==0) - return Success; - - masks = XkbFindClientResource((DevicePtr)dev,client); - if (!masks){ - XID id = FakeClientID(client->index); - if (!AddResource(id,RT_XKBCLIENT,dev)) - return BadAlloc; - masks= XkbAddClientResource((DevicePtr)dev,client,id); - } - if (masks) { - union { - CARD8 *c8; - CARD16 *c16; - CARD32 *c32; - } from,to; - register unsigned bit,ndx,maskLeft,dataLeft,size; - - from.c8= (CARD8 *)&stuff[1]; - dataLeft= (stuff->length*4)-SIZEOF(xkbSelectEventsReq); - maskLeft= (stuff->affectWhich&(~XkbMapNotifyMask)); - for (ndx=0,bit=1; (maskLeft!=0); ndx++, bit<<=1) { - if ((bit&maskLeft)==0) - continue; - maskLeft&= ~bit; - switch (ndx) { - case XkbNewKeyboardNotify: - to.c16= &client->newKeyboardNotifyMask; - legal= XkbAllNewKeyboardEventsMask; - size= 2; - break; - case XkbStateNotify: - to.c16= &masks->stateNotifyMask; - legal= XkbAllStateEventsMask; - size= 2; - break; - case XkbControlsNotify: - to.c32= &masks->ctrlsNotifyMask; - legal= XkbAllControlEventsMask; - size= 4; - break; - case XkbIndicatorStateNotify: - to.c32= &masks->iStateNotifyMask; - legal= XkbAllIndicatorEventsMask; - size= 4; - break; - case XkbIndicatorMapNotify: - to.c32= &masks->iMapNotifyMask; - legal= XkbAllIndicatorEventsMask; - size= 4; - break; - case XkbNamesNotify: - to.c16= &masks->namesNotifyMask; - legal= XkbAllNameEventsMask; - size= 2; - break; - case XkbCompatMapNotify: - to.c8= &masks->compatNotifyMask; - legal= XkbAllCompatMapEventsMask; - size= 1; - break; - case XkbBellNotify: - to.c8= &masks->bellNotifyMask; - legal= XkbAllBellEventsMask; - size= 1; - break; - case XkbActionMessage: - to.c8= &masks->actionMessageMask; - legal= XkbAllActionMessagesMask; - size= 1; - break; - case XkbAccessXNotify: - to.c16= &masks->accessXNotifyMask; - legal= XkbAllAccessXEventsMask; - size= 2; - break; - case XkbExtensionDeviceNotify: - to.c16= &masks->extDevNotifyMask; - legal= XkbAllExtensionDeviceEventsMask; - size= 2; - break; - default: - client->errorValue = _XkbErrCode2(33,bit); - return BadValue; - } - - if (stuff->clear&bit) { - if (size==2) to.c16[0]= 0; - else if (size==4) to.c32[0]= 0; - else to.c8[0]= 0; - } - else if (stuff->selectAll&bit) { - if (size==2) to.c16[0]= ~0; - else if (size==4) to.c32[0]= ~0; - else to.c8[0]= ~0; - } - else { - if (dataLeft<(size*2)) - return BadLength; - if (size==2) { - CHK_MASK_MATCH(ndx,from.c16[0],from.c16[1]); - CHK_MASK_LEGAL(ndx,from.c16[0],legal); - to.c16[0]&= ~from.c16[0]; - to.c16[0]|= (from.c16[0]&from.c16[1]); - } - else if (size==4) { - CHK_MASK_MATCH(ndx,from.c32[0],from.c32[1]); - CHK_MASK_LEGAL(ndx,from.c32[0],legal); - to.c32[0]&= ~from.c32[0]; - to.c32[0]|= (from.c32[0]&from.c32[1]); - } - else { - CHK_MASK_MATCH(ndx,from.c8[0],from.c8[1]); - CHK_MASK_LEGAL(ndx,from.c8[0],legal); - to.c8[0]&= ~from.c8[0]; - to.c8[0]|= (from.c8[0]&from.c8[1]); - size= 2; - } - from.c8+= (size*2); - dataLeft-= (size*2); - } - } - if (dataLeft>2) { - ErrorF("[xkb] Extra data (%d bytes) after SelectEvents\n",dataLeft); - return BadLength; - } - return Success; - } - return BadAlloc; -} - -/***====================================================================***/ -/** - * Ring a bell on the given device for the given client. - */ -static int -_XkbBell(ClientPtr client, DeviceIntPtr dev, WindowPtr pWin, - int bellClass, int bellID, int pitch, int duration, - int percent, int forceSound, int eventOnly, Atom name) -{ - int base; - pointer ctrl; - int oldPitch, oldDuration; - int newPercent; - - if (bellClass == KbdFeedbackClass) { - KbdFeedbackPtr k; - if (bellID==XkbDfltXIId) - k= dev->kbdfeed; - else { - for (k=dev->kbdfeed; k; k=k->next) { - if (k->ctrl.id == bellID) - break; - } - } - if (!k) { - client->errorValue = _XkbErrCode2(0x5,bellID); - return BadValue; - } - base = k->ctrl.bell; - ctrl = (pointer) &(k->ctrl); - oldPitch= k->ctrl.bell_pitch; - oldDuration= k->ctrl.bell_duration; - if (pitch!=0) { - if (pitch==-1) - k->ctrl.bell_pitch= defaultKeyboardControl.bell_pitch; - else k->ctrl.bell_pitch= pitch; - } - if (duration!=0) { - if (duration==-1) - k->ctrl.bell_duration= defaultKeyboardControl.bell_duration; - else k->ctrl.bell_duration= duration; - } - } - else if (bellClass == BellFeedbackClass) { - BellFeedbackPtr b; - if (bellID==XkbDfltXIId) - b= dev->bell; - else { - for (b=dev->bell; b; b=b->next) { - if (b->ctrl.id == bellID) - break; - } - } - if (!b) { - client->errorValue = _XkbErrCode2(0x6,bellID); - return BadValue; - } - base = b->ctrl.percent; - ctrl = (pointer) &(b->ctrl); - oldPitch= b->ctrl.pitch; - oldDuration= b->ctrl.duration; - if (pitch!=0) { - if (pitch==-1) - b->ctrl.pitch= defaultKeyboardControl.bell_pitch; - else b->ctrl.pitch= pitch; - } - if (duration!=0) { - if (duration==-1) - b->ctrl.duration= defaultKeyboardControl.bell_duration; - else b->ctrl.duration= duration; - } - } - else { - client->errorValue = _XkbErrCode2(0x7, bellClass); - return BadValue; - } - - newPercent = (base * percent)/100; - if (percent < 0) - newPercent = base + newPercent; - else newPercent = base - newPercent + percent; - - XkbHandleBell(forceSound, eventOnly, - dev, newPercent, ctrl, bellClass, - name, pWin, client); - if ((pitch!=0)||(duration!=0)) { - if (bellClass == KbdFeedbackClass) { - KbdFeedbackPtr k; - k= (KbdFeedbackPtr)ctrl; - if (pitch!=0) - k->ctrl.bell_pitch= oldPitch; - if (duration!=0) - k->ctrl.bell_duration= oldDuration; - } - else { - BellFeedbackPtr b; - b= (BellFeedbackPtr)ctrl; - if (pitch!=0) - b->ctrl.pitch= oldPitch; - if (duration!=0) - b->ctrl.duration= oldDuration; - } - } - - return Success; -} - -int -ProcXkbBell(ClientPtr client) -{ - REQUEST(xkbBellReq); - DeviceIntPtr dev; - WindowPtr pWin; - int rc; - - REQUEST_SIZE_MATCH(xkbBellReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_BELL_DEVICE(dev, stuff->deviceSpec, client, DixBellAccess); - CHK_ATOM_OR_NONE(stuff->name); - - /* device-independent checks request for sane values */ - if ((stuff->forceSound)&&(stuff->eventOnly)) { - client->errorValue=_XkbErrCode3(0x1,stuff->forceSound,stuff->eventOnly); - return BadMatch; - } - if (stuff->percent < -100 || stuff->percent > 100) { - client->errorValue = _XkbErrCode2(0x2,stuff->percent); - return BadValue; - } - if (stuff->duration<-1) { - client->errorValue = _XkbErrCode2(0x3,stuff->duration); - return BadValue; - } - if (stuff->pitch<-1) { - client->errorValue = _XkbErrCode2(0x4,stuff->pitch); - return BadValue; - } - - if (stuff->bellClass == XkbDfltXIClass) { - if (dev->kbdfeed!=NULL) - stuff->bellClass= KbdFeedbackClass; - else stuff->bellClass= BellFeedbackClass; - } - - if (stuff->window!=None) { - rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess); - if (rc != Success) { - client->errorValue= stuff->window; - return rc; - } - } - else pWin= NULL; - - /* Client wants to ring a bell on the core keyboard? - Ring the bell on the core keyboard (which does nothing, but if that - fails the client is screwed anyway), and then on all extension devices. - Fail if the core keyboard fails but not the extension devices. this - may cause some keyboards to ding and others to stay silent. Fix - your client to use explicit keyboards to avoid this. - - dev is the device the client requested. - */ - rc = _XkbBell(client, dev, pWin, stuff->bellClass, stuff->bellID, - stuff->pitch, stuff->duration, stuff->percent, - stuff->forceSound, stuff->eventOnly, stuff->name); - - if ((rc == Success) && ((stuff->deviceSpec == XkbUseCoreKbd) || - (stuff->deviceSpec == XkbUseCorePtr))) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixBellAccess); - if (rc == Success) - _XkbBell(client, other, pWin, stuff->bellClass, - stuff->bellID, stuff->pitch, stuff->duration, - stuff->percent, stuff->forceSound, - stuff->eventOnly, stuff->name); - } - } - rc = Success; /* reset to success, that's what we got for the VCK */ - } - - return rc; -} - -/***====================================================================***/ - -int -ProcXkbGetState(ClientPtr client) -{ - REQUEST(xkbGetStateReq); - DeviceIntPtr dev; - xkbGetStateReply rep; - XkbStateRec *xkb; - - REQUEST_SIZE_MATCH(xkbGetStateReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - - xkb= &dev->key->xkbInfo->state; - memset(&rep, 0, sizeof(xkbGetStateReply)); - rep.type= X_Reply; - rep.sequenceNumber= client->sequence; - rep.length = 0; - rep.deviceID = dev->id; - rep.mods = XkbStateFieldFromRec(xkb) & 0xff; - rep.baseMods = xkb->base_mods; - rep.lockedMods = xkb->locked_mods; - rep.latchedMods = xkb->latched_mods; - rep.group = xkb->group; - rep.baseGroup = xkb->base_group; - rep.latchedGroup = xkb->latched_group; - rep.lockedGroup = xkb->locked_group; - rep.compatState = xkb->compat_state; - rep.ptrBtnState = xkb->ptr_buttons; - if (client->swapped) { - register int n; - swaps(&rep.sequenceNumber,n); - swaps(&rep.ptrBtnState,n); - } - WriteToClient(client, SIZEOF(xkbGetStateReply), (char *)&rep); - return Success; -} - -/***====================================================================***/ - -int -ProcXkbLatchLockState(ClientPtr client) -{ - int status; - DeviceIntPtr dev, tmpd; - XkbStateRec oldState,*newState; - CARD16 changed; - xkbStateNotify sn; - XkbEventCauseRec cause; - - REQUEST(xkbLatchLockStateReq); - REQUEST_SIZE_MATCH(xkbLatchLockStateReq); - - if (!(client->xkbClientFlags & _XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixSetAttrAccess); - CHK_MASK_MATCH(0x01, stuff->affectModLocks, stuff->modLocks); - CHK_MASK_MATCH(0x01, stuff->affectModLatches, stuff->modLatches); - - status = Success; - - for (tmpd = inputInfo.devices; tmpd; tmpd = tmpd->next) { - if ((tmpd == dev) || (!IsMaster(tmpd) && GetMaster(tmpd, MASTER_KEYBOARD) == dev)) { - if (!tmpd->key || !tmpd->key->xkbInfo) - continue; - - oldState = tmpd->key->xkbInfo->state; - newState = &tmpd->key->xkbInfo->state; - if (stuff->affectModLocks) { - newState->locked_mods &= ~stuff->affectModLocks; - newState->locked_mods |= (stuff->affectModLocks & stuff->modLocks); - } - if (status == Success && stuff->lockGroup) - newState->locked_group = stuff->groupLock; - if (status == Success && stuff->affectModLatches) - status = XkbLatchModifiers(tmpd, stuff->affectModLatches, - stuff->modLatches); - if (status == Success && stuff->latchGroup) - status = XkbLatchGroup(tmpd, stuff->groupLatch); - - if (status != Success) - return status; - - XkbComputeDerivedState(tmpd->key->xkbInfo); - - changed = XkbStateChangedFlags(&oldState, newState); - if (changed) { - sn.keycode = 0; - sn.eventType = 0; - sn.requestMajor = XkbReqCode; - sn.requestMinor = X_kbLatchLockState; - sn.changed = changed; - XkbSendStateNotify(tmpd, &sn); - changed = XkbIndicatorsToUpdate(tmpd, changed, FALSE); - if (changed) { - XkbSetCauseXkbReq(&cause, X_kbLatchLockState, client); - XkbUpdateIndicators(tmpd, changed, TRUE, NULL, &cause); - } - } - } - } - - return Success; -} - -/***====================================================================***/ - -int -ProcXkbGetControls(ClientPtr client) -{ - xkbGetControlsReply rep; - XkbControlsPtr xkb; - DeviceIntPtr dev; - register int n; - - REQUEST(xkbGetControlsReq); - REQUEST_SIZE_MATCH(xkbGetControlsReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - - xkb = dev->key->xkbInfo->desc->ctrls; - rep.type = X_Reply; - rep.length = bytes_to_int32(SIZEOF(xkbGetControlsReply)- - SIZEOF(xGenericReply)); - rep.sequenceNumber = client->sequence; - rep.deviceID = ((DeviceIntPtr)dev)->id; - rep.numGroups = xkb->num_groups; - rep.groupsWrap = xkb->groups_wrap; - rep.internalMods = xkb->internal.mask; - rep.ignoreLockMods = xkb->ignore_lock.mask; - rep.internalRealMods = xkb->internal.real_mods; - rep.ignoreLockRealMods = xkb->ignore_lock.real_mods; - rep.internalVMods = xkb->internal.vmods; - rep.ignoreLockVMods = xkb->ignore_lock.vmods; - rep.enabledCtrls = xkb->enabled_ctrls; - rep.repeatDelay = xkb->repeat_delay; - rep.repeatInterval = xkb->repeat_interval; - rep.slowKeysDelay = xkb->slow_keys_delay; - rep.debounceDelay = xkb->debounce_delay; - rep.mkDelay = xkb->mk_delay; - rep.mkInterval = xkb->mk_interval; - rep.mkTimeToMax = xkb->mk_time_to_max; - rep.mkMaxSpeed = xkb->mk_max_speed; - rep.mkCurve = xkb->mk_curve; - rep.mkDfltBtn = xkb->mk_dflt_btn; - rep.axTimeout = xkb->ax_timeout; - rep.axtCtrlsMask = xkb->axt_ctrls_mask; - rep.axtCtrlsValues = xkb->axt_ctrls_values; - rep.axtOptsMask = xkb->axt_opts_mask; - rep.axtOptsValues = xkb->axt_opts_values; - rep.axOptions = xkb->ax_options; - memcpy(rep.perKeyRepeat,xkb->per_key_repeat,XkbPerKeyBitArraySize); - if (client->swapped) { - swaps(&rep.sequenceNumber, n); - swapl(&rep.length,n); - swaps(&rep.internalVMods, n); - swaps(&rep.ignoreLockVMods, n); - swapl(&rep.enabledCtrls, n); - swaps(&rep.repeatDelay, n); - swaps(&rep.repeatInterval, n); - swaps(&rep.slowKeysDelay, n); - swaps(&rep.debounceDelay, n); - swaps(&rep.mkDelay, n); - swaps(&rep.mkInterval, n); - swaps(&rep.mkTimeToMax, n); - swaps(&rep.mkMaxSpeed, n); - swaps(&rep.mkCurve, n); - swaps(&rep.axTimeout, n); - swapl(&rep.axtCtrlsMask, n); - swapl(&rep.axtCtrlsValues, n); - swaps(&rep.axtOptsMask, n); - swaps(&rep.axtOptsValues, n); - swaps(&rep.axOptions, n); - } - WriteToClient(client, SIZEOF(xkbGetControlsReply), (char *)&rep); - return Success; -} - -int -ProcXkbSetControls(ClientPtr client) -{ - DeviceIntPtr dev, tmpd; - XkbSrvInfoPtr xkbi; - XkbControlsPtr ctrl; - XkbControlsRec new,old; - xkbControlsNotify cn; - XkbEventCauseRec cause; - XkbSrvLedInfoPtr sli; - - REQUEST(xkbSetControlsReq); - REQUEST_SIZE_MATCH(xkbSetControlsReq); - - if (!(client->xkbClientFlags & _XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); - CHK_MASK_LEGAL(0x01, stuff->changeCtrls, XkbAllControlsMask); - - for (tmpd = inputInfo.devices; tmpd; tmpd = tmpd->next) { - if (!tmpd->key || !tmpd->key->xkbInfo) - continue; - if ((tmpd == dev) || (!IsMaster(tmpd) && GetMaster(tmpd, MASTER_KEYBOARD) == dev)) { - xkbi = tmpd->key->xkbInfo; - ctrl = xkbi->desc->ctrls; - new = *ctrl; - XkbSetCauseXkbReq(&cause, X_kbSetControls, client); - - if (stuff->changeCtrls & XkbInternalModsMask) { - CHK_MASK_MATCH(0x02, stuff->affectInternalMods, - stuff->internalMods); - CHK_MASK_MATCH(0x03, stuff->affectInternalVMods, - stuff->internalVMods); - - new.internal.real_mods &= ~(stuff->affectInternalMods); - new.internal.real_mods |= (stuff->affectInternalMods & - stuff->internalMods); - new.internal.vmods &= ~(stuff->affectInternalVMods); - new.internal.vmods |= (stuff->affectInternalVMods & - stuff->internalVMods); - new.internal.mask = new.internal.real_mods | - XkbMaskForVMask(xkbi->desc, - new.internal.vmods); - } - - if (stuff->changeCtrls & XkbIgnoreLockModsMask) { - CHK_MASK_MATCH(0x4, stuff->affectIgnoreLockMods, - stuff->ignoreLockMods); - CHK_MASK_MATCH(0x5, stuff->affectIgnoreLockVMods, - stuff->ignoreLockVMods); - - new.ignore_lock.real_mods &= ~(stuff->affectIgnoreLockMods); - new.ignore_lock.real_mods |= (stuff->affectIgnoreLockMods & - stuff->ignoreLockMods); - new.ignore_lock.vmods &= ~(stuff->affectIgnoreLockVMods); - new.ignore_lock.vmods |= (stuff->affectIgnoreLockVMods & - stuff->ignoreLockVMods); - new.ignore_lock.mask = new.ignore_lock.real_mods | - XkbMaskForVMask(xkbi->desc, - new.ignore_lock.vmods); - } - - CHK_MASK_MATCH(0x06, stuff->affectEnabledCtrls, - stuff->enabledCtrls); - if (stuff->affectEnabledCtrls) { - CHK_MASK_LEGAL(0x07, stuff->affectEnabledCtrls, - XkbAllBooleanCtrlsMask); - - new.enabled_ctrls &= ~(stuff->affectEnabledCtrls); - new.enabled_ctrls |= (stuff->affectEnabledCtrls & - stuff->enabledCtrls); - } - - if (stuff->changeCtrls & XkbRepeatKeysMask) { - if (stuff->repeatDelay < 1 || stuff->repeatInterval < 1) { - client->errorValue = _XkbErrCode3(0x08, stuff->repeatDelay, - stuff->repeatInterval); - return BadValue; - } - - new.repeat_delay = stuff->repeatDelay; - new.repeat_interval = stuff->repeatInterval; - } - - if (stuff->changeCtrls & XkbSlowKeysMask) { - if (stuff->slowKeysDelay < 1) { - client->errorValue = _XkbErrCode2(0x09, - stuff->slowKeysDelay); - return BadValue; - } - - new.slow_keys_delay = stuff->slowKeysDelay; - } - - if (stuff->changeCtrls & XkbBounceKeysMask) { - if (stuff->debounceDelay < 1) { - client->errorValue = _XkbErrCode2(0x0A, - stuff->debounceDelay); - return BadValue; - } - - new.debounce_delay = stuff->debounceDelay; - } - - if (stuff->changeCtrls & XkbMouseKeysMask) { - if (stuff->mkDfltBtn > XkbMaxMouseKeysBtn) { - client->errorValue = _XkbErrCode2(0x0B, stuff->mkDfltBtn); - return BadValue; - } - - new.mk_dflt_btn = stuff->mkDfltBtn; - } - - if (stuff->changeCtrls & XkbMouseKeysAccelMask) { - if (stuff->mkDelay < 1 || stuff->mkInterval < 1 || - stuff->mkTimeToMax < 1 || stuff->mkMaxSpeed < 1 || - stuff->mkCurve < -1000) { - client->errorValue = _XkbErrCode2(0x0C,0); - return BadValue; - } - - new.mk_delay = stuff->mkDelay; - new.mk_interval = stuff->mkInterval; - new.mk_time_to_max = stuff->mkTimeToMax; - new.mk_max_speed = stuff->mkMaxSpeed; - new.mk_curve = stuff->mkCurve; - AccessXComputeCurveFactor(xkbi, &new); - } - - if (stuff->changeCtrls & XkbGroupsWrapMask) { - unsigned act, num; - - act = XkbOutOfRangeGroupAction(stuff->groupsWrap); - switch (act) { - case XkbRedirectIntoRange: - num = XkbOutOfRangeGroupNumber(stuff->groupsWrap); - if (num >= new.num_groups) { - client->errorValue = _XkbErrCode3(0x0D, new.num_groups, - num); - return BadValue; - } - case XkbWrapIntoRange: - case XkbClampIntoRange: - break; - default: - client->errorValue = _XkbErrCode2(0x0E, act); - return BadValue; - } - - new.groups_wrap= stuff->groupsWrap; - } - - CHK_MASK_LEGAL(0x0F, stuff->axOptions, XkbAX_AllOptionsMask); - if (stuff->changeCtrls & XkbAccessXKeysMask) { - new.ax_options = stuff->axOptions & XkbAX_AllOptionsMask; - } - else { - if (stuff->changeCtrls & XkbStickyKeysMask) { - new.ax_options &= ~(XkbAX_SKOptionsMask); - new.ax_options |= (stuff->axOptions & XkbAX_SKOptionsMask); - } - - if (stuff->changeCtrls & XkbAccessXFeedbackMask) { - new.ax_options &= ~(XkbAX_FBOptionsMask); - new.ax_options |= (stuff->axOptions & XkbAX_FBOptionsMask); - } - } - - if (stuff->changeCtrls & XkbAccessXTimeoutMask) { - if (stuff->axTimeout < 1) { - client->errorValue = _XkbErrCode2(0x10, stuff->axTimeout); - return BadValue; - } - CHK_MASK_MATCH(0x11, stuff->axtCtrlsMask, - stuff->axtCtrlsValues); - CHK_MASK_LEGAL(0x12, stuff->axtCtrlsMask, - XkbAllBooleanCtrlsMask); - CHK_MASK_MATCH(0x13, stuff->axtOptsMask, stuff->axtOptsValues); - CHK_MASK_LEGAL(0x14, stuff->axtOptsMask, XkbAX_AllOptionsMask); - new.ax_timeout = stuff->axTimeout; - new.axt_ctrls_mask = stuff->axtCtrlsMask; - new.axt_ctrls_values = (stuff->axtCtrlsValues & - stuff->axtCtrlsMask); - new.axt_opts_mask = stuff->axtOptsMask; - new.axt_opts_values = (stuff->axtOptsValues & - stuff->axtOptsMask); - } - - if (stuff->changeCtrls & XkbPerKeyRepeatMask) - memcpy(new.per_key_repeat, stuff->perKeyRepeat, - XkbPerKeyBitArraySize); - - old= *ctrl; - *ctrl= new; - XkbDDXChangeControls(tmpd, &old, ctrl); - - if (XkbComputeControlsNotify(tmpd, &old, ctrl, &cn, FALSE)) { - cn.keycode = 0; - cn.eventType = 0; - cn.requestMajor = XkbReqCode; - cn.requestMinor = X_kbSetControls; - XkbSendControlsNotify(tmpd, &cn); - } - - sli = XkbFindSrvLedInfo(tmpd, XkbDfltXIClass, XkbDfltXIId, 0); - if (sli) - XkbUpdateIndicators(tmpd, sli->usesControls, TRUE, NULL, - &cause); - - /* If sticky keys were disabled, clear all locks and latches */ - if ((old.enabled_ctrls & XkbStickyKeysMask) && - !(ctrl->enabled_ctrls & XkbStickyKeysMask)) - XkbClearAllLatchesAndLocks(tmpd, xkbi, TRUE, &cause); - } - } - - return Success; -} - -/***====================================================================***/ - -static int -XkbSizeKeyTypes(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - XkbKeyTypeRec *type; - unsigned i,len; - - len= 0; - if (((rep->present&XkbKeyTypesMask)==0)||(rep->nTypes<1)|| - (!xkb)||(!xkb->map)||(!xkb->map->types)) { - rep->present&= ~XkbKeyTypesMask; - rep->firstType= rep->nTypes= 0; - return 0; - } - type= &xkb->map->types[rep->firstType]; - for (i=0;inTypes;i++,type++){ - len+= SIZEOF(xkbKeyTypeWireDesc); - if (type->map_count>0) { - len+= (type->map_count*SIZEOF(xkbKTMapEntryWireDesc)); - if (type->preserve) - len+= (type->map_count*SIZEOF(xkbModsWireDesc)); - } - } - return len; -} - -static char * -XkbWriteKeyTypes( XkbDescPtr xkb, - xkbGetMapReply * rep, - char * buf, - ClientPtr client) -{ - XkbKeyTypePtr type; - unsigned i; - xkbKeyTypeWireDesc *wire; - - type= &xkb->map->types[rep->firstType]; - for (i=0;inTypes;i++,type++) { - register unsigned n; - wire= (xkbKeyTypeWireDesc *)buf; - wire->mask = type->mods.mask; - wire->realMods = type->mods.real_mods; - wire->virtualMods = type->mods.vmods; - wire->numLevels = type->num_levels; - wire->nMapEntries = type->map_count; - wire->preserve = (type->preserve!=NULL); - if (client->swapped) { - register int n; - swaps(&wire->virtualMods,n); - } - - buf= (char *)&wire[1]; - if (wire->nMapEntries>0) { - xkbKTMapEntryWireDesc * wire; - XkbKTMapEntryPtr entry; - wire= (xkbKTMapEntryWireDesc *)buf; - entry= type->map; - for (n=0;nmap_count;n++,wire++,entry++) { - wire->active= entry->active; - wire->mask= entry->mods.mask; - wire->level= entry->level; - wire->realMods= entry->mods.real_mods; - wire->virtualMods= entry->mods.vmods; - if (client->swapped) { - register int n; - swaps(&wire->virtualMods,n); - } - } - buf= (char *)wire; - if (type->preserve!=NULL) { - xkbModsWireDesc * pwire; - XkbModsPtr preserve; - pwire= (xkbModsWireDesc *)buf; - preserve= type->preserve; - for (n=0;nmap_count;n++,pwire++,preserve++) { - pwire->mask= preserve->mask; - pwire->realMods= preserve->real_mods; - pwire->virtualMods= preserve->vmods; - if (client->swapped) { - register int n; - swaps(&pwire->virtualMods,n); - } - } - buf= (char *)pwire; - } - } - } - return buf; -} - -static int -XkbSizeKeySyms(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - XkbSymMapPtr symMap; - unsigned i,len; - unsigned nSyms,nSymsThisKey; - - if (((rep->present&XkbKeySymsMask)==0)||(rep->nKeySyms<1)|| - (!xkb)||(!xkb->map)||(!xkb->map->key_sym_map)) { - rep->present&= ~XkbKeySymsMask; - rep->firstKeySym= rep->nKeySyms= 0; - rep->totalSyms= 0; - return 0; - } - len= rep->nKeySyms*SIZEOF(xkbSymMapWireDesc); - symMap = &xkb->map->key_sym_map[rep->firstKeySym]; - for (i=nSyms=0;inKeySyms;i++,symMap++) { - if (symMap->offset!=0) { - nSymsThisKey= XkbNumGroups(symMap->group_info)*symMap->width; - nSyms+= nSymsThisKey; - } - } - len+= nSyms*4; - rep->totalSyms= nSyms; - return len; -} - -static int -XkbSizeVirtualMods(XkbDescPtr xkb,xkbGetMapReply *rep) -{ -register unsigned i,nMods,bit; - - if (((rep->present&XkbVirtualModsMask)==0)||(rep->virtualMods==0)|| - (!xkb)||(!xkb->server)) { - rep->present&= ~XkbVirtualModsMask; - rep->virtualMods= 0; - return 0; - } - for (i=nMods=0,bit=1;ivirtualMods&bit) - nMods++; - } - return XkbPaddedSize(nMods); -} - -static char * -XkbWriteKeySyms(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf,ClientPtr client) -{ -register KeySym * pSym; -XkbSymMapPtr symMap; -xkbSymMapWireDesc * outMap; -register unsigned i; - - symMap = &xkb->map->key_sym_map[rep->firstKeySym]; - for (i=0;inKeySyms;i++,symMap++) { - outMap = (xkbSymMapWireDesc *)buf; - outMap->ktIndex[0] = symMap->kt_index[0]; - outMap->ktIndex[1] = symMap->kt_index[1]; - outMap->ktIndex[2] = symMap->kt_index[2]; - outMap->ktIndex[3] = symMap->kt_index[3]; - outMap->groupInfo = symMap->group_info; - outMap->width= symMap->width; - outMap->nSyms = symMap->width*XkbNumGroups(symMap->group_info); - buf= (char *)&outMap[1]; - if (outMap->nSyms==0) - continue; - - pSym = &xkb->map->syms[symMap->offset]; - memcpy((char *)buf,(char *)pSym,outMap->nSyms*4); - if (client->swapped) { - register int n,nSyms= outMap->nSyms; - swaps(&outMap->nSyms,n); - while (nSyms-->0) { - swapl(buf,n); - buf+= 4; - } - } - else buf+= outMap->nSyms*4; - } - return buf; -} - -static int -XkbSizeKeyActions(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - unsigned i,len,nActs; - register KeyCode firstKey; - - if (((rep->present&XkbKeyActionsMask)==0)||(rep->nKeyActs<1)|| - (!xkb)||(!xkb->server)||(!xkb->server->key_acts)) { - rep->present&= ~XkbKeyActionsMask; - rep->firstKeyAct= rep->nKeyActs= 0; - rep->totalActs= 0; - return 0; - } - firstKey= rep->firstKeyAct; - for (nActs=i=0;inKeyActs;i++) { - if (xkb->server->key_acts[i+firstKey]!=0) - nActs+= XkbKeyNumActions(xkb,i+firstKey); - } - len= XkbPaddedSize(rep->nKeyActs)+(nActs*SIZEOF(xkbActionWireDesc)); - rep->totalActs= nActs; - return len; -} - -static char * -XkbWriteKeyActions(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, - ClientPtr client) -{ - unsigned i; - CARD8 * numDesc; - XkbAnyAction * actDesc; - - numDesc = (CARD8 *)buf; - for (i=0;inKeyActs;i++) { - if (xkb->server->key_acts[i+rep->firstKeyAct]==0) - numDesc[i] = 0; - else numDesc[i] = XkbKeyNumActions(xkb,(i+rep->firstKeyAct)); - } - buf+= XkbPaddedSize(rep->nKeyActs); - - actDesc = (XkbAnyAction *)buf; - for (i=0;inKeyActs;i++) { - if (xkb->server->key_acts[i+rep->firstKeyAct]!=0) { - unsigned int num; - num = XkbKeyNumActions(xkb,(i+rep->firstKeyAct)); - memcpy((char *)actDesc, - (char*)XkbKeyActionsPtr(xkb,(i+rep->firstKeyAct)), - num*SIZEOF(xkbActionWireDesc)); - actDesc+= num; - } - } - buf = (char *)actDesc; - return buf; -} - -static int -XkbSizeKeyBehaviors(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - unsigned i,len,nBhvr; - XkbBehavior * bhv; - - if (((rep->present&XkbKeyBehaviorsMask)==0)||(rep->nKeyBehaviors<1)|| - (!xkb)||(!xkb->server)||(!xkb->server->behaviors)) { - rep->present&= ~XkbKeyBehaviorsMask; - rep->firstKeyBehavior= rep->nKeyBehaviors= 0; - rep->totalKeyBehaviors= 0; - return 0; - } - bhv= &xkb->server->behaviors[rep->firstKeyBehavior]; - for (nBhvr=i=0;inKeyBehaviors;i++,bhv++) { - if (bhv->type!=XkbKB_Default) - nBhvr++; - } - len= nBhvr*SIZEOF(xkbBehaviorWireDesc); - rep->totalKeyBehaviors= nBhvr; - return len; -} - -static char * -XkbWriteKeyBehaviors(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, - ClientPtr client) -{ - unsigned i; - xkbBehaviorWireDesc *wire; - XkbBehavior *pBhvr; - - wire = (xkbBehaviorWireDesc *)buf; - pBhvr= &xkb->server->behaviors[rep->firstKeyBehavior]; - for (i=0;inKeyBehaviors;i++,pBhvr++) { - if (pBhvr->type!=XkbKB_Default) { - wire->key= i+rep->firstKeyBehavior; - wire->type= pBhvr->type; - wire->data= pBhvr->data; - wire++; - } - } - buf = (char *)wire; - return buf; -} - -static int -XkbSizeExplicit(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - unsigned i,len,nRtrn; - - if (((rep->present&XkbExplicitComponentsMask)==0)||(rep->nKeyExplicit<1)|| - (!xkb)||(!xkb->server)||(!xkb->server->explicit)) { - rep->present&= ~XkbExplicitComponentsMask; - rep->firstKeyExplicit= rep->nKeyExplicit= 0; - rep->totalKeyExplicit= 0; - return 0; - } - for (nRtrn=i=0;inKeyExplicit;i++) { - if (xkb->server->explicit[i+rep->firstKeyExplicit]!=0) - nRtrn++; - } - rep->totalKeyExplicit= nRtrn; - len= XkbPaddedSize(nRtrn*2); /* two bytes per non-zero explicit component */ - return len; -} - -static char * -XkbWriteExplicit(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf,ClientPtr client) -{ -unsigned i; -char * start; -unsigned char * pExp; - - start= buf; - pExp= &xkb->server->explicit[rep->firstKeyExplicit]; - for (i=0;inKeyExplicit;i++,pExp++) { - if (*pExp!=0) { - *buf++= i+rep->firstKeyExplicit; - *buf++= *pExp; - } - } - i= XkbPaddedSize(buf-start)-(buf-start); /* pad to word boundary */ - return buf+i; -} - -static int -XkbSizeModifierMap(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - unsigned i,len,nRtrn; - - if (((rep->present&XkbModifierMapMask)==0)||(rep->nModMapKeys<1)|| - (!xkb)||(!xkb->map)||(!xkb->map->modmap)) { - rep->present&= ~XkbModifierMapMask; - rep->firstModMapKey= rep->nModMapKeys= 0; - rep->totalModMapKeys= 0; - return 0; - } - for (nRtrn=i=0;inModMapKeys;i++) { - if (xkb->map->modmap[i+rep->firstModMapKey]!=0) - nRtrn++; - } - rep->totalModMapKeys= nRtrn; - len= XkbPaddedSize(nRtrn*2); /* two bytes per non-zero modmap component */ - return len; -} - -static char * -XkbWriteModifierMap(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, - ClientPtr client) -{ -unsigned i; -char * start; -unsigned char * pMap; - - start= buf; - pMap= &xkb->map->modmap[rep->firstModMapKey]; - for (i=0;inModMapKeys;i++,pMap++) { - if (*pMap!=0) { - *buf++= i+rep->firstModMapKey; - *buf++= *pMap; - } - } - i= XkbPaddedSize(buf-start)-(buf-start); /* pad to word boundary */ - return buf+i; -} - -static int -XkbSizeVirtualModMap(XkbDescPtr xkb,xkbGetMapReply *rep) -{ - unsigned i,len,nRtrn; - - if (((rep->present&XkbVirtualModMapMask)==0)||(rep->nVModMapKeys<1)|| - (!xkb)||(!xkb->server)||(!xkb->server->vmodmap)) { - rep->present&= ~XkbVirtualModMapMask; - rep->firstVModMapKey= rep->nVModMapKeys= 0; - rep->totalVModMapKeys= 0; - return 0; - } - for (nRtrn=i=0;inVModMapKeys;i++) { - if (xkb->server->vmodmap[i+rep->firstVModMapKey]!=0) - nRtrn++; - } - rep->totalVModMapKeys= nRtrn; - len= nRtrn*SIZEOF(xkbVModMapWireDesc); - return len; -} - -static char * -XkbWriteVirtualModMap(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, - ClientPtr client) -{ -unsigned i; -xkbVModMapWireDesc * wire; -unsigned short * pMap; - - wire= (xkbVModMapWireDesc *)buf; - pMap= &xkb->server->vmodmap[rep->firstVModMapKey]; - for (i=0;inVModMapKeys;i++,pMap++) { - if (*pMap!=0) { - wire->key= i+rep->firstVModMapKey; - wire->vmods= *pMap; - wire++; - } - } - return (char *)wire; -} - -static Status -XkbComputeGetMapReplySize(XkbDescPtr xkb,xkbGetMapReply *rep) -{ -int len; - - rep->minKeyCode= xkb->min_key_code; - rep->maxKeyCode= xkb->max_key_code; - len= XkbSizeKeyTypes(xkb,rep); - len+= XkbSizeKeySyms(xkb,rep); - len+= XkbSizeKeyActions(xkb,rep); - len+= XkbSizeKeyBehaviors(xkb,rep); - len+= XkbSizeVirtualMods(xkb,rep); - len+= XkbSizeExplicit(xkb,rep); - len+= XkbSizeModifierMap(xkb,rep); - len+= XkbSizeVirtualModMap(xkb,rep); - rep->length+= (len/4); - return Success; -} - -static int -XkbSendMap(ClientPtr client,XkbDescPtr xkb,xkbGetMapReply *rep) -{ -unsigned i,len; -char *desc,*start; - - len= (rep->length*4)-(SIZEOF(xkbGetMapReply)-SIZEOF(xGenericReply)); - start= desc= calloc(1, len); - if (!start) - return BadAlloc; - if ( rep->nTypes>0 ) - desc = XkbWriteKeyTypes(xkb,rep,desc,client); - if ( rep->nKeySyms>0 ) - desc = XkbWriteKeySyms(xkb,rep,desc,client); - if ( rep->nKeyActs>0 ) - desc = XkbWriteKeyActions(xkb,rep,desc,client); - if ( rep->totalKeyBehaviors>0 ) - desc = XkbWriteKeyBehaviors(xkb,rep,desc,client); - if ( rep->virtualMods ) { - register int sz,bit; - for (i=sz=0,bit=1;ivirtualMods&bit) { - desc[sz++]= xkb->server->vmods[i]; - } - } - desc+= XkbPaddedSize(sz); - } - if ( rep->totalKeyExplicit>0 ) - desc= XkbWriteExplicit(xkb,rep,desc,client); - if ( rep->totalModMapKeys>0 ) - desc= XkbWriteModifierMap(xkb,rep,desc,client); - if ( rep->totalVModMapKeys>0 ) - desc= XkbWriteVirtualModMap(xkb,rep,desc,client); - if ((desc-start)!=(len)) { - ErrorF("[xkb] BOGUS LENGTH in write keyboard desc, expected %d, got %ld\n", - len, (unsigned long)(desc-start)); - } - if (client->swapped) { - register int n; - swaps(&rep->sequenceNumber,n); - swapl(&rep->length,n); - swaps(&rep->present,n); - swaps(&rep->totalSyms,n); - swaps(&rep->totalActs,n); - } - WriteToClient(client, (i=SIZEOF(xkbGetMapReply)), (char *)rep); - WriteToClient(client, len, start); - free((char *)start); - return Success; -} - -int -ProcXkbGetMap(ClientPtr client) -{ - DeviceIntPtr dev; - xkbGetMapReply rep; - XkbDescRec *xkb; - int n,status; - - REQUEST(xkbGetMapReq); - REQUEST_SIZE_MATCH(xkbGetMapReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - CHK_MASK_OVERLAP(0x01,stuff->full,stuff->partial); - CHK_MASK_LEGAL(0x02,stuff->full,XkbAllMapComponentsMask); - CHK_MASK_LEGAL(0x03,stuff->partial,XkbAllMapComponentsMask); - - xkb= dev->key->xkbInfo->desc; - memset(&rep, 0, sizeof(xkbGetMapReply)); - rep.type= X_Reply; - rep.sequenceNumber= client->sequence; - rep.length = (SIZEOF(xkbGetMapReply)-SIZEOF(xGenericReply))>>2; - rep.deviceID = dev->id; - rep.present = stuff->partial|stuff->full; - rep.minKeyCode = xkb->min_key_code; - rep.maxKeyCode = xkb->max_key_code; - if ( stuff->full&XkbKeyTypesMask ) { - rep.firstType = 0; - rep.nTypes = xkb->map->num_types; - } - else if (stuff->partial&XkbKeyTypesMask) { - if (((unsigned)stuff->firstType+stuff->nTypes)>xkb->map->num_types) { - client->errorValue = _XkbErrCode4(0x04,xkb->map->num_types, - stuff->firstType,stuff->nTypes); - return BadValue; - } - rep.firstType = stuff->firstType; - rep.nTypes = stuff->nTypes; - } - else rep.nTypes = 0; - rep.totalTypes = xkb->map->num_types; - - n= XkbNumKeys(xkb); - if ( stuff->full&XkbKeySymsMask ) { - rep.firstKeySym = xkb->min_key_code; - rep.nKeySyms = n; - } - else if (stuff->partial&XkbKeySymsMask) { - CHK_KEY_RANGE(0x05,stuff->firstKeySym,stuff->nKeySyms,xkb); - rep.firstKeySym = stuff->firstKeySym; - rep.nKeySyms = stuff->nKeySyms; - } - else rep.nKeySyms = 0; - rep.totalSyms= 0; - - if ( stuff->full&XkbKeyActionsMask ) { - rep.firstKeyAct= xkb->min_key_code; - rep.nKeyActs= n; - } - else if (stuff->partial&XkbKeyActionsMask) { - CHK_KEY_RANGE(0x07,stuff->firstKeyAct,stuff->nKeyActs,xkb); - rep.firstKeyAct= stuff->firstKeyAct; - rep.nKeyActs= stuff->nKeyActs; - } - else rep.nKeyActs= 0; - rep.totalActs= 0; - - if ( stuff->full&XkbKeyBehaviorsMask ) { - rep.firstKeyBehavior = xkb->min_key_code; - rep.nKeyBehaviors = n; - } - else if (stuff->partial&XkbKeyBehaviorsMask) { - CHK_KEY_RANGE(0x09,stuff->firstKeyBehavior,stuff->nKeyBehaviors,xkb); - rep.firstKeyBehavior= stuff->firstKeyBehavior; - rep.nKeyBehaviors= stuff->nKeyBehaviors; - } - else rep.nKeyBehaviors = 0; - rep.totalKeyBehaviors= 0; - - if (stuff->full&XkbVirtualModsMask) - rep.virtualMods= ~0; - else if (stuff->partial&XkbVirtualModsMask) - rep.virtualMods= stuff->virtualMods; - - if (stuff->full&XkbExplicitComponentsMask) { - rep.firstKeyExplicit= xkb->min_key_code; - rep.nKeyExplicit= n; - } - else if (stuff->partial&XkbExplicitComponentsMask) { - CHK_KEY_RANGE(0x0B,stuff->firstKeyExplicit,stuff->nKeyExplicit,xkb); - rep.firstKeyExplicit= stuff->firstKeyExplicit; - rep.nKeyExplicit= stuff->nKeyExplicit; - } - else rep.nKeyExplicit = 0; - rep.totalKeyExplicit= 0; - - if (stuff->full&XkbModifierMapMask) { - rep.firstModMapKey= xkb->min_key_code; - rep.nModMapKeys= n; - } - else if (stuff->partial&XkbModifierMapMask) { - CHK_KEY_RANGE(0x0D,stuff->firstModMapKey,stuff->nModMapKeys,xkb); - rep.firstModMapKey= stuff->firstModMapKey; - rep.nModMapKeys= stuff->nModMapKeys; - } - else rep.nModMapKeys = 0; - rep.totalModMapKeys= 0; - - if (stuff->full&XkbVirtualModMapMask) { - rep.firstVModMapKey= xkb->min_key_code; - rep.nVModMapKeys= n; - } - else if (stuff->partial&XkbVirtualModMapMask) { - CHK_KEY_RANGE(0x0F,stuff->firstVModMapKey,stuff->nVModMapKeys,xkb); - rep.firstVModMapKey= stuff->firstVModMapKey; - rep.nVModMapKeys= stuff->nVModMapKeys; - } - else rep.nVModMapKeys = 0; - rep.totalVModMapKeys= 0; - - if ((status=XkbComputeGetMapReplySize(xkb,&rep))!=Success) - return status; - return XkbSendMap(client,xkb,&rep); -} - -/***====================================================================***/ - -static int -CheckKeyTypes( ClientPtr client, - XkbDescPtr xkb, - xkbSetMapReq * req, - xkbKeyTypeWireDesc **wireRtrn, - int * nMapsRtrn, - CARD8 * mapWidthRtrn) -{ -unsigned nMaps; -register unsigned i,n; -register CARD8 * map; -register xkbKeyTypeWireDesc *wire = *wireRtrn; - - if (req->firstType>((unsigned)xkb->map->num_types)) { - *nMapsRtrn = _XkbErrCode3(0x01,req->firstType,xkb->map->num_types); - return 0; - } - if (req->flags&XkbSetMapResizeTypes) { - nMaps = req->firstType+req->nTypes; - if (nMapsfirstType,req->nTypes,4); - return 0; - } - } - else if (req->present&XkbKeyTypesMask) { - nMaps = xkb->map->num_types; - if ((req->firstType+req->nTypes)>nMaps) { - *nMapsRtrn = req->firstType+req->nTypes; - return 0; - } - } - else { - *nMapsRtrn = xkb->map->num_types; - for (i=0;imap->num_types;i++) { - mapWidthRtrn[i] = xkb->map->types[i].num_levels; - } - return 1; - } - - for (i=0;ifirstType;i++) { - mapWidthRtrn[i] = xkb->map->types[i].num_levels; - } - for (i=0;inTypes;i++) { - unsigned width; - if (client->swapped) { - register int s; - swaps(&wire->virtualMods,s); - } - n= i+req->firstType; - width= wire->numLevels; - if (width<1) { - *nMapsRtrn= _XkbErrCode3(0x04,n,width); - return 0; - } - else if ((n==XkbOneLevelIndex)&&(width!=1)) { /* must be width 1 */ - *nMapsRtrn= _XkbErrCode3(0x05,n,width); - return 0; - } - else if ((width!=2)&& - ((n==XkbTwoLevelIndex)||(n==XkbKeypadIndex)|| - (n==XkbAlphabeticIndex))) { - /* TWO_LEVEL, ALPHABETIC and KEYPAD must be width 2 */ - *nMapsRtrn= _XkbErrCode3(0x05,n,width); - return 0; - } - if (wire->nMapEntries>0) { - xkbKTSetMapEntryWireDesc * mapWire; - xkbModsWireDesc * preWire; - mapWire= (xkbKTSetMapEntryWireDesc *)&wire[1]; - preWire= (xkbModsWireDesc *)&mapWire[wire->nMapEntries]; - for (n=0;nnMapEntries;n++) { - if (client->swapped) { - register int s; - swaps(&mapWire[n].virtualMods,s); - } - if (mapWire[n].realMods&(~wire->realMods)) { - *nMapsRtrn= _XkbErrCode4(0x06,n,mapWire[n].realMods, - wire->realMods); - return 0; - } - if (mapWire[n].virtualMods&(~wire->virtualMods)) { - *nMapsRtrn= _XkbErrCode3(0x07,n,mapWire[n].virtualMods); - return 0; - } - if (mapWire[n].level>=wire->numLevels) { - *nMapsRtrn= _XkbErrCode4(0x08,n,wire->numLevels, - mapWire[n].level); - return 0; - } - if (wire->preserve) { - if (client->swapped) { - register int s; - swaps(&preWire[n].virtualMods,s); - } - if (preWire[n].realMods&(~mapWire[n].realMods)) { - *nMapsRtrn= _XkbErrCode4(0x09,n,preWire[n].realMods, - mapWire[n].realMods); - return 0; - } - if (preWire[n].virtualMods&(~mapWire[n].virtualMods)) { - *nMapsRtrn=_XkbErrCode3(0x0a,n,preWire[n].virtualMods); - return 0; - } - } - } - if (wire->preserve) - map= (CARD8 *)&preWire[wire->nMapEntries]; - else map= (CARD8 *)&mapWire[wire->nMapEntries]; - } - else map= (CARD8 *)&wire[1]; - mapWidthRtrn[i+req->firstType] = wire->numLevels; - wire= (xkbKeyTypeWireDesc *)map; - } - for (i=req->firstType+req->nTypes;imap->types[i].num_levels; - } - *nMapsRtrn = nMaps; - *wireRtrn = wire; - return 1; -} - -static int -CheckKeySyms( ClientPtr client, - XkbDescPtr xkb, - xkbSetMapReq * req, - int nTypes, - CARD8 * mapWidths, - CARD16 * symsPerKey, - xkbSymMapWireDesc ** wireRtrn, - int * errorRtrn) -{ -register unsigned i; -XkbSymMapPtr map; -xkbSymMapWireDesc* wire = *wireRtrn; - - if (!(XkbKeySymsMask&req->present)) - return 1; - CHK_REQ_KEY_RANGE2(0x11,req->firstKeySym,req->nKeySyms,req,(*errorRtrn),0); - for (i=0;inKeySyms;i++) { - KeySym *pSyms; - register unsigned nG; - if (client->swapped) { - swaps(&wire->nSyms,nG); - } - nG = XkbNumGroups(wire->groupInfo); - if (nG>XkbNumKbdGroups) { - *errorRtrn = _XkbErrCode3(0x14,i+req->firstKeySym,nG); - return 0; - } - if (nG>0) { - register int g,w; - for (g=w=0;gktIndex[g]>=(unsigned)nTypes) { - *errorRtrn= _XkbErrCode4(0x15,i+req->firstKeySym,g, - wire->ktIndex[g]); - return 0; - } - if (mapWidths[wire->ktIndex[g]]>w) - w= mapWidths[wire->ktIndex[g]]; - } - if (wire->width!=w) { - *errorRtrn= _XkbErrCode3(0x16,i+req->firstKeySym,wire->width); - return 0; - } - w*= nG; - symsPerKey[i+req->firstKeySym] = w; - if (w!=wire->nSyms) { - *errorRtrn=_XkbErrCode4(0x16,i+req->firstKeySym,wire->nSyms,w); - return 0; - } - } - else if (wire->nSyms!=0) { - *errorRtrn = _XkbErrCode3(0x17,i+req->firstKeySym,wire->nSyms); - return 0; - } - pSyms = (KeySym *)&wire[1]; - wire = (xkbSymMapWireDesc *)&pSyms[wire->nSyms]; - } - - map = &xkb->map->key_sym_map[i]; - for (;i<=(unsigned)xkb->max_key_code;i++,map++) { - register int g,nG,w; - nG= XkbKeyNumGroups(xkb,i); - for (w=g=0;gkt_index[g]>=(unsigned)nTypes) { - *errorRtrn = _XkbErrCode4(0x18,i,g,map->kt_index[g]); - return 0; - } - if (mapWidths[map->kt_index[g]]>w) - w= mapWidths[map->kt_index[g]]; - } - symsPerKey[i] = w*nG; - } - *wireRtrn = wire; - return 1; -} - -static int -CheckKeyActions( XkbDescPtr xkb, - xkbSetMapReq * req, - int nTypes, - CARD8 * mapWidths, - CARD16 * symsPerKey, - CARD8 ** wireRtrn, - int * nActsRtrn) -{ -int nActs; -CARD8 * wire = *wireRtrn; -register unsigned i; - - if (!(XkbKeyActionsMask&req->present)) - return 1; - CHK_REQ_KEY_RANGE2(0x21,req->firstKeyAct,req->nKeyActs,req,(*nActsRtrn),0); - for (nActs=i=0;inKeyActs;i++) { - if (wire[0]!=0) { - if (wire[0]==symsPerKey[i+req->firstKeyAct]) - nActs+= wire[0]; - else { - *nActsRtrn= _XkbErrCode3(0x23,i+req->firstKeyAct,wire[0]); - return 0; - } - } - wire++; - } - if (req->nKeyActs%4) - wire+= 4-(req->nKeyActs%4); - *wireRtrn = (CARD8 *)(((XkbAnyAction *)wire)+nActs); - *nActsRtrn = nActs; - return 1; -} - -static int -CheckKeyBehaviors( XkbDescPtr xkb, - xkbSetMapReq * req, - xkbBehaviorWireDesc ** wireRtrn, - int * errorRtrn) -{ -register xkbBehaviorWireDesc * wire = *wireRtrn; -register XkbServerMapPtr server = xkb->server; -register unsigned i; -unsigned first,last; - - if (((req->present&XkbKeyBehaviorsMask)==0)||(req->nKeyBehaviors<1)) { - req->present&= ~XkbKeyBehaviorsMask; - req->nKeyBehaviors= 0; - return 1; - } - first= req->firstKeyBehavior; - last= req->firstKeyBehavior+req->nKeyBehaviors-1; - if (firstminKeyCode) { - *errorRtrn = _XkbErrCode3(0x31,first,req->minKeyCode); - return 0; - } - if (last>req->maxKeyCode) { - *errorRtrn = _XkbErrCode3(0x32,last,req->maxKeyCode); - return 0; - } - - for (i=0;itotalKeyBehaviors;i++,wire++) { - if ((wire->keykey>last)) { - *errorRtrn = _XkbErrCode4(0x33,first,last,wire->key); - return 0; - } - if ((wire->type&XkbKB_Permanent)&& - ((server->behaviors[wire->key].type!=wire->type)|| - (server->behaviors[wire->key].data!=wire->data))) { - *errorRtrn = _XkbErrCode3(0x33,wire->key,wire->type); - return 0; - } - if ((wire->type==XkbKB_RadioGroup)&& - ((wire->data&(~XkbKB_RGAllowNone))>XkbMaxRadioGroups)) { - *errorRtrn= _XkbErrCode4(0x34,wire->key,wire->data, - XkbMaxRadioGroups); - return 0; - } - if ((wire->type==XkbKB_Overlay1)||(wire->type==XkbKB_Overlay2)) { - CHK_KEY_RANGE2(0x35,wire->key,1,xkb,*errorRtrn,0); - } - } - *wireRtrn = wire; - return 1; -} - -static int -CheckVirtualMods( XkbDescRec * xkb, - xkbSetMapReq * req, - CARD8 ** wireRtrn, - int * errorRtrn) -{ -register CARD8 *wire = *wireRtrn; -register unsigned i,nMods,bit; - - if (((req->present&XkbVirtualModsMask)==0)||(req->virtualMods==0)) - return 1; - for (i=nMods=0,bit=1;ivirtualMods&bit) - nMods++; - } - *wireRtrn= (wire+XkbPaddedSize(nMods)); - return 1; -} - -static int -CheckKeyExplicit( XkbDescPtr xkb, - xkbSetMapReq * req, - CARD8 ** wireRtrn, - int * errorRtrn) -{ -register CARD8 * wire = *wireRtrn; -CARD8 * start; -register unsigned i; -int first,last; - - if (((req->present&XkbExplicitComponentsMask)==0)||(req->nKeyExplicit<1)) { - req->present&= ~XkbExplicitComponentsMask; - req->nKeyExplicit= 0; - return 1; - } - first= req->firstKeyExplicit; - last= first+req->nKeyExplicit-1; - if (firstminKeyCode) { - *errorRtrn = _XkbErrCode3(0x51,first,req->minKeyCode); - return 0; - } - if (last>req->maxKeyCode) { - *errorRtrn = _XkbErrCode3(0x52,last,req->maxKeyCode); - return 0; - } - start= wire; - for (i=0;itotalKeyExplicit;i++,wire+=2) { - if ((wire[0]last)) { - *errorRtrn = _XkbErrCode4(0x53,first,last,wire[0]); - return 0; - } - if (wire[1]&(~XkbAllExplicitMask)) { - *errorRtrn= _XkbErrCode3(0x52,~XkbAllExplicitMask,wire[1]); - return 0; - } - } - wire+= XkbPaddedSize(wire-start)-(wire-start); - *wireRtrn= wire; - return 1; -} - -static int -CheckModifierMap(XkbDescPtr xkb,xkbSetMapReq *req,CARD8 **wireRtrn,int *errRtrn) -{ -register CARD8 * wire = *wireRtrn; -CARD8 * start; -register unsigned i; -int first,last; - - if (((req->present&XkbModifierMapMask)==0)||(req->nModMapKeys<1)) { - req->present&= ~XkbModifierMapMask; - req->nModMapKeys= 0; - return 1; - } - first= req->firstModMapKey; - last= first+req->nModMapKeys-1; - if (firstminKeyCode) { - *errRtrn = _XkbErrCode3(0x61,first,req->minKeyCode); - return 0; - } - if (last>req->maxKeyCode) { - *errRtrn = _XkbErrCode3(0x62,last,req->maxKeyCode); - return 0; - } - start= wire; - for (i=0;itotalModMapKeys;i++,wire+=2) { - if ((wire[0]last)) { - *errRtrn = _XkbErrCode4(0x63,first,last,wire[0]); - return 0; - } - } - wire+= XkbPaddedSize(wire-start)-(wire-start); - *wireRtrn= wire; - return 1; -} - -static int -CheckVirtualModMap( XkbDescPtr xkb, - xkbSetMapReq *req, - xkbVModMapWireDesc **wireRtrn, - int *errRtrn) -{ -register xkbVModMapWireDesc * wire = *wireRtrn; -register unsigned i; -int first,last; - - if (((req->present&XkbVirtualModMapMask)==0)||(req->nVModMapKeys<1)) { - req->present&= ~XkbVirtualModMapMask; - req->nVModMapKeys= 0; - return 1; - } - first= req->firstVModMapKey; - last= first+req->nVModMapKeys-1; - if (firstminKeyCode) { - *errRtrn = _XkbErrCode3(0x71,first,req->minKeyCode); - return 0; - } - if (last>req->maxKeyCode) { - *errRtrn = _XkbErrCode3(0x72,last,req->maxKeyCode); - return 0; - } - for (i=0;itotalVModMapKeys;i++,wire++) { - if ((wire->keykey>last)) { - *errRtrn = _XkbErrCode4(0x73,first,last,wire->key); - return 0; - } - } - *wireRtrn= wire; - return 1; -} - -static char * -SetKeyTypes( XkbDescPtr xkb, - xkbSetMapReq * req, - xkbKeyTypeWireDesc * wire, - XkbChangesPtr changes) -{ -register unsigned i; -unsigned first,last; -CARD8 *map; - - if ((unsigned)(req->firstType+req->nTypes)>xkb->map->size_types) { - i= req->firstType+req->nTypes; - if (XkbAllocClientMap(xkb,XkbKeyTypesMask,i)!=Success) { - return NULL; - } - } - if ((unsigned)(req->firstType+req->nTypes)>xkb->map->num_types) - xkb->map->num_types= req->firstType+req->nTypes; - - for (i=0;inTypes;i++) { - XkbKeyTypePtr pOld; - register unsigned n; - - if (XkbResizeKeyType(xkb,i+req->firstType,wire->nMapEntries, - wire->preserve,wire->numLevels)!=Success) { - return NULL; - } - pOld = &xkb->map->types[i+req->firstType]; - map = (CARD8 *)&wire[1]; - - pOld->mods.real_mods = wire->realMods; - pOld->mods.vmods= wire->virtualMods; - pOld->num_levels = wire->numLevels; - pOld->map_count= wire->nMapEntries; - - pOld->mods.mask= pOld->mods.real_mods| - XkbMaskForVMask(xkb,pOld->mods.vmods); - - if (wire->nMapEntries) { - xkbKTSetMapEntryWireDesc *mapWire; - xkbModsWireDesc *preWire; - unsigned tmp; - mapWire= (xkbKTSetMapEntryWireDesc *)map; - preWire= (xkbModsWireDesc *)&mapWire[wire->nMapEntries]; - for (n=0;nnMapEntries;n++) { - pOld->map[n].active= 1; - pOld->map[n].mods.mask= mapWire[n].realMods; - pOld->map[n].mods.real_mods= mapWire[n].realMods; - pOld->map[n].mods.vmods= mapWire[n].virtualMods; - pOld->map[n].level= mapWire[n].level; - if (mapWire[n].virtualMods!=0) { - tmp= XkbMaskForVMask(xkb,mapWire[n].virtualMods); - pOld->map[n].active= (tmp!=0); - pOld->map[n].mods.mask|= tmp; - } - if (wire->preserve) { - pOld->preserve[n].real_mods= preWire[n].realMods; - pOld->preserve[n].vmods= preWire[n].virtualMods; - tmp= XkbMaskForVMask(xkb,preWire[n].virtualMods); - pOld->preserve[n].mask= preWire[n].realMods|tmp; - } - } - if (wire->preserve) - map= (CARD8 *)&preWire[wire->nMapEntries]; - else map= (CARD8 *)&mapWire[wire->nMapEntries]; - } - else map= (CARD8 *)&wire[1]; - wire = (xkbKeyTypeWireDesc *)map; - } - first= req->firstType; - last= first+req->nTypes-1; /* last changed type */ - if (changes->map.changed&XkbKeyTypesMask) { - int oldLast; - oldLast= changes->map.first_type+changes->map.num_types-1; - if (changes->map.first_typemap.first_type; - if (oldLast>last) - last= oldLast; - } - changes->map.changed|= XkbKeyTypesMask; - changes->map.first_type = first; - changes->map.num_types = (last-first)+1; - return (char *)wire; -} - -static char * -SetKeySyms( ClientPtr client, - XkbDescPtr xkb, - xkbSetMapReq * req, - xkbSymMapWireDesc * wire, - XkbChangesPtr changes, - DeviceIntPtr dev) -{ -register unsigned i,s; -XkbSymMapPtr oldMap; -KeySym * newSyms; -KeySym * pSyms; -unsigned first,last; - - oldMap = &xkb->map->key_sym_map[req->firstKeySym]; - for (i=0;inKeySyms;i++,oldMap++) { - pSyms = (KeySym *)&wire[1]; - if (wire->nSyms>0) { - newSyms = XkbResizeKeySyms(xkb,i+req->firstKeySym,wire->nSyms); - for (s=0;snSyms;s++) { - newSyms[s]= pSyms[s]; - } - if (client->swapped) { - int n; - for (s=0;snSyms;s++) { - swapl(&newSyms[s],n); - } - } - } - oldMap->kt_index[0] = wire->ktIndex[0]; - oldMap->kt_index[1] = wire->ktIndex[1]; - oldMap->kt_index[2] = wire->ktIndex[2]; - oldMap->kt_index[3] = wire->ktIndex[3]; - oldMap->group_info = wire->groupInfo; - oldMap->width = wire->width; - wire= (xkbSymMapWireDesc *)&pSyms[wire->nSyms]; - } - first= req->firstKeySym; - last= first+req->nKeySyms-1; - if (changes->map.changed&XkbKeySymsMask) { - int oldLast= (changes->map.first_key_sym+changes->map.num_key_syms-1); - if (changes->map.first_key_symmap.first_key_sym; - if (oldLast>last) - last= oldLast; - } - changes->map.changed|= XkbKeySymsMask; - changes->map.first_key_sym = first; - changes->map.num_key_syms = (last-first+1); - - s= 0; - for (i=xkb->min_key_code;i<=xkb->max_key_code;i++) { - if (XkbKeyNumGroups(xkb,i)>s) - s= XkbKeyNumGroups(xkb,i); - } - if (s!=xkb->ctrls->num_groups) { - xkbControlsNotify cn; - XkbControlsRec old; - cn.keycode= 0; - cn.eventType= 0; - cn.requestMajor= XkbReqCode; - cn.requestMinor= X_kbSetMap; - old= *xkb->ctrls; - xkb->ctrls->num_groups= s; - if (XkbComputeControlsNotify(dev,&old,xkb->ctrls,&cn,FALSE)) - XkbSendControlsNotify(dev,&cn); - } - return (char *)wire; -} - -static char * -SetKeyActions( XkbDescPtr xkb, - xkbSetMapReq * req, - CARD8 * wire, - XkbChangesPtr changes) -{ -register unsigned i,first,last; -CARD8 * nActs = wire; -XkbAction * newActs; - - wire+= XkbPaddedSize(req->nKeyActs); - for (i=0;inKeyActs;i++) { - if (nActs[i]==0) - xkb->server->key_acts[i+req->firstKeyAct]= 0; - else { - newActs= XkbResizeKeyActions(xkb,i+req->firstKeyAct,nActs[i]); - memcpy((char *)newActs,(char *)wire, - nActs[i]*SIZEOF(xkbActionWireDesc)); - wire+= nActs[i]*SIZEOF(xkbActionWireDesc); - } - } - first= req->firstKeyAct; - last= (first+req->nKeyActs-1); - if (changes->map.changed&XkbKeyActionsMask) { - int oldLast; - oldLast= changes->map.first_key_act+changes->map.num_key_acts-1; - if (changes->map.first_key_actmap.first_key_act; - if (oldLast>last) - last= oldLast; - } - changes->map.changed|= XkbKeyActionsMask; - changes->map.first_key_act= first; - changes->map.num_key_acts= (last-first+1); - return (char *)wire; -} - -static char * -SetKeyBehaviors( XkbSrvInfoPtr xkbi, - xkbSetMapReq *req, - xkbBehaviorWireDesc *wire, - XkbChangesPtr changes) -{ -register unsigned i; -int maxRG = -1; -XkbDescPtr xkb = xkbi->desc; -XkbServerMapPtr server = xkb->server; -unsigned first,last; - - first= req->firstKeyBehavior; - last= req->firstKeyBehavior+req->nKeyBehaviors-1; - memset(&server->behaviors[first], 0, req->nKeyBehaviors*sizeof(XkbBehavior)); - for (i=0;itotalKeyBehaviors;i++) { - if ((server->behaviors[wire->key].type&XkbKB_Permanent)==0) { - server->behaviors[wire->key].type= wire->type; - server->behaviors[wire->key].data= wire->data; - if ((wire->type==XkbKB_RadioGroup)&&(((int)wire->data)>maxRG)) - maxRG= wire->data + 1; - } - wire++; - } - - if (maxRG>(int)xkbi->nRadioGroups) { - int sz = maxRG*sizeof(XkbRadioGroupRec); - if (xkbi->radioGroups) - xkbi->radioGroups= realloc(xkbi->radioGroups,sz); - else xkbi->radioGroups= calloc(1, sz); - if (xkbi->radioGroups) { - if (xkbi->nRadioGroups) - memset(&xkbi->radioGroups[xkbi->nRadioGroups], 0, - (maxRG-xkbi->nRadioGroups)*sizeof(XkbRadioGroupRec)); - xkbi->nRadioGroups= maxRG; - } - else xkbi->nRadioGroups= 0; - /* should compute members here */ - } - if (changes->map.changed&XkbKeyBehaviorsMask) { - unsigned oldLast; - oldLast= changes->map.first_key_behavior+ - changes->map.num_key_behaviors-1; - if (changes->map.first_key_behaviorfirstKeyBehavior) - first= changes->map.first_key_behavior; - if (oldLast>last) - last= oldLast; - } - changes->map.changed|= XkbKeyBehaviorsMask; - changes->map.first_key_behavior = first; - changes->map.num_key_behaviors = (last-first+1); - return (char *)wire; -} - -static char * -SetVirtualMods(XkbSrvInfoPtr xkbi,xkbSetMapReq *req,CARD8 *wire, - XkbChangesPtr changes) -{ -register int i,bit,nMods; -XkbServerMapPtr srv = xkbi->desc->server; - - if (((req->present&XkbVirtualModsMask)==0)||(req->virtualMods==0)) - return (char *)wire; - for (i=nMods=0,bit=1;ivirtualMods&bit) { - if (srv->vmods[i]!=wire[nMods]) { - changes->map.changed|= XkbVirtualModsMask; - changes->map.vmods|= bit; - srv->vmods[i]= wire[nMods]; - } - nMods++; - } - } - return (char *)(wire+XkbPaddedSize(nMods)); -} - -static char * -SetKeyExplicit(XkbSrvInfoPtr xkbi,xkbSetMapReq *req,CARD8 *wire, - XkbChangesPtr changes) -{ -register unsigned i,first,last; -XkbServerMapPtr xkb = xkbi->desc->server; -CARD8 * start; - - start= wire; - first= req->firstKeyExplicit; - last= req->firstKeyExplicit+req->nKeyExplicit-1; - memset(&xkb->explicit[first], 0, req->nKeyExplicit); - for (i=0;itotalKeyExplicit;i++,wire+= 2) { - xkb->explicit[wire[0]]= wire[1]; - } - if (first>0) { - if (changes->map.changed&XkbExplicitComponentsMask) { - int oldLast; - oldLast= changes->map.first_key_explicit+ - changes->map.num_key_explicit-1; - if (changes->map.first_key_explicitmap.first_key_explicit; - if (oldLast>last) - last= oldLast; - } - changes->map.first_key_explicit= first; - changes->map.num_key_explicit= (last-first)+1; - } - wire+= XkbPaddedSize(wire-start)-(wire-start); - return (char *)wire; -} - -static char * -SetModifierMap( XkbSrvInfoPtr xkbi, - xkbSetMapReq * req, - CARD8 * wire, - XkbChangesPtr changes) -{ -register unsigned i,first,last; -XkbClientMapPtr xkb = xkbi->desc->map; -CARD8 * start; - - start= wire; - first= req->firstModMapKey; - last= req->firstModMapKey+req->nModMapKeys-1; - memset(&xkb->modmap[first], 0, req->nModMapKeys); - for (i=0;itotalModMapKeys;i++,wire+= 2) { - xkb->modmap[wire[0]]= wire[1]; - } - if (first>0) { - if (changes->map.changed&XkbModifierMapMask) { - int oldLast; - oldLast= changes->map.first_modmap_key+ - changes->map.num_modmap_keys-1; - if (changes->map.first_modmap_keymap.first_modmap_key; - if (oldLast>last) - last= oldLast; - } - changes->map.first_modmap_key= first; - changes->map.num_modmap_keys= (last-first)+1; - } - wire+= XkbPaddedSize(wire-start)-(wire-start); - return (char *)wire; -} - -static char * -SetVirtualModMap( XkbSrvInfoPtr xkbi, - xkbSetMapReq * req, - xkbVModMapWireDesc * wire, - XkbChangesPtr changes) -{ -register unsigned i,first,last; -XkbServerMapPtr srv = xkbi->desc->server; - - first= req->firstVModMapKey; - last= req->firstVModMapKey+req->nVModMapKeys-1; - memset(&srv->vmodmap[first], 0, req->nVModMapKeys*sizeof(unsigned short)); - for (i=0;itotalVModMapKeys;i++,wire++) { - srv->vmodmap[wire->key]= wire->vmods; - } - if (first>0) { - if (changes->map.changed&XkbVirtualModMapMask) { - int oldLast; - oldLast= changes->map.first_vmodmap_key+ - changes->map.num_vmodmap_keys-1; - if (changes->map.first_vmodmap_keymap.first_vmodmap_key; - if (oldLast>last) - last= oldLast; - } - changes->map.first_vmodmap_key= first; - changes->map.num_vmodmap_keys= (last-first)+1; - } - return (char *)wire; -} - -/** - * Check if the given request can be applied to the given device but don't - * actually do anything.. - */ -static int -_XkbSetMapChecks(ClientPtr client, DeviceIntPtr dev, xkbSetMapReq *req, char* values) -{ - XkbSrvInfoPtr xkbi; - XkbDescPtr xkb; - int error; - int nTypes = 0, nActions; - CARD8 mapWidths[XkbMaxLegalKeyCode + 1] = {0}; - CARD16 symsPerKey[XkbMaxLegalKeyCode + 1] = {0}; - XkbSymMapPtr map; - int i; - - xkbi= dev->key->xkbInfo; - xkb = xkbi->desc; - - if ((xkb->min_key_code != req->minKeyCode)|| - (xkb->max_key_code != req->maxKeyCode)) { - if (client->vMajor!=1) { /* pre 1.0 versions of Xlib have a bug */ - req->minKeyCode= xkb->min_key_code; - req->maxKeyCode= xkb->max_key_code; - } - else { - if (!XkbIsLegalKeycode(req->minKeyCode)) { - client->errorValue = _XkbErrCode3(2, req->minKeyCode, req->maxKeyCode); - return BadValue; - } - if (req->minKeyCode > req->maxKeyCode) { - client->errorValue = _XkbErrCode3(3, req->minKeyCode, req->maxKeyCode); - return BadMatch; - } - } - } - - if ((req->present & XkbKeyTypesMask) && - (!CheckKeyTypes(client,xkb,req,(xkbKeyTypeWireDesc **)&values, - &nTypes,mapWidths))) { - client->errorValue = nTypes; - return BadValue; - } - - /* symsPerKey/mapWidths must be filled regardless of client-side flags */ - map = &xkb->map->key_sym_map[xkb->min_key_code]; - for (i=xkb->min_key_code;imax_key_code;i++,map++) { - register int g,ng,w; - ng= XkbNumGroups(map->group_info); - for (w=g=0;gkt_index[g]>=(unsigned)nTypes) { - client->errorValue = _XkbErrCode4(0x13,i,g,map->kt_index[g]); - return 0; - } - if (mapWidths[map->kt_index[g]]>w) - w= mapWidths[map->kt_index[g]]; - } - symsPerKey[i] = w*ng; - } - - if ((req->present & XkbKeySymsMask) && - (!CheckKeySyms(client,xkb,req,nTypes,mapWidths,symsPerKey, - (xkbSymMapWireDesc **)&values,&error))) { - client->errorValue = error; - return BadValue; - } - - if ((req->present & XkbKeyActionsMask) && - (!CheckKeyActions(xkb,req,nTypes,mapWidths,symsPerKey, - (CARD8 **)&values,&nActions))) { - client->errorValue = nActions; - return BadValue; - } - - if ((req->present & XkbKeyBehaviorsMask) && - (!CheckKeyBehaviors(xkb,req,(xkbBehaviorWireDesc**)&values,&error))) { - client->errorValue = error; - return BadValue; - } - - if ((req->present & XkbVirtualModsMask) && - (!CheckVirtualMods(xkb,req,(CARD8 **)&values,&error))) { - client->errorValue= error; - return BadValue; - } - if ((req->present&XkbExplicitComponentsMask) && - (!CheckKeyExplicit(xkb,req,(CARD8 **)&values,&error))) { - client->errorValue= error; - return BadValue; - } - if ((req->present&XkbModifierMapMask) && - (!CheckModifierMap(xkb,req,(CARD8 **)&values,&error))) { - client->errorValue= error; - return BadValue; - } - if ((req->present&XkbVirtualModMapMask) && - (!CheckVirtualModMap(xkb,req,(xkbVModMapWireDesc **)&values,&error))) { - client->errorValue= error; - return BadValue; - } - - if (((values-((char *)req))/4)!= req->length) { - ErrorF("[xkb] Internal error! Bad length in XkbSetMap (after check)\n"); - client->errorValue = values-((char *)&req[1]); - return BadLength; - } - - return Success; -} - -/** - * Apply the given request on the given device. - */ -static int -_XkbSetMap(ClientPtr client, DeviceIntPtr dev, xkbSetMapReq *req, char *values) -{ - XkbEventCauseRec cause; - XkbChangesRec change; - Bool sentNKN; - XkbSrvInfoPtr xkbi; - XkbDescPtr xkb; - - xkbi= dev->key->xkbInfo; - xkb = xkbi->desc; - - XkbSetCauseXkbReq(&cause,X_kbSetMap,client); - memset(&change, 0, sizeof(change)); - sentNKN = FALSE; - if ((xkb->min_key_code!=req->minKeyCode)|| - (xkb->max_key_code!=req->maxKeyCode)) { - Status status; - xkbNewKeyboardNotify nkn; - nkn.deviceID = nkn.oldDeviceID = dev->id; - nkn.oldMinKeyCode = xkb->min_key_code; - nkn.oldMaxKeyCode = xkb->max_key_code; - status= XkbChangeKeycodeRange(xkb, req->minKeyCode, - req->maxKeyCode, &change); - if (status != Success) - return status; /* oh-oh. what about the other keyboards? */ - nkn.minKeyCode = xkb->min_key_code; - nkn.maxKeyCode = xkb->max_key_code; - nkn.requestMajor = XkbReqCode; - nkn.requestMinor = X_kbSetMap; - nkn.changed = XkbNKN_KeycodesMask; - XkbSendNewKeyboardNotify(dev,&nkn); - sentNKN = TRUE; - } - - if (req->present&XkbKeyTypesMask) { - values = SetKeyTypes(xkb,req,(xkbKeyTypeWireDesc *)values,&change); - if (!values) goto allocFailure; - } - if (req->present&XkbKeySymsMask) { - values = SetKeySyms(client,xkb,req,(xkbSymMapWireDesc *)values,&change,dev); - if (!values) goto allocFailure; - } - if (req->present&XkbKeyActionsMask) { - values = SetKeyActions(xkb,req,(CARD8 *)values,&change); - if (!values) goto allocFailure; - } - if (req->present&XkbKeyBehaviorsMask) { - values= SetKeyBehaviors(xkbi,req,(xkbBehaviorWireDesc *)values,&change); - if (!values) goto allocFailure; - } - if (req->present&XkbVirtualModsMask) - values= SetVirtualMods(xkbi,req,(CARD8 *)values,&change); - if (req->present&XkbExplicitComponentsMask) - values= SetKeyExplicit(xkbi,req,(CARD8 *)values,&change); - if (req->present&XkbModifierMapMask) - values= SetModifierMap(xkbi,req,(CARD8 *)values,&change); - if (req->present&XkbVirtualModMapMask) - values= SetVirtualModMap(xkbi,req,(xkbVModMapWireDesc *)values,&change); - if (((values-((char *)req))/4)!=req->length) { - ErrorF("[xkb] Internal error! Bad length in XkbSetMap (after set)\n"); - client->errorValue = values-((char *)&req[1]); - return BadLength; - } - if (req->flags&XkbSetMapRecomputeActions) { - KeyCode first,last,firstMM,lastMM; - if (change.map.num_key_syms>0) { - first= change.map.first_key_sym; - last= first+change.map.num_key_syms-1; - } - else first= last= 0; - if (change.map.num_modmap_keys>0) { - firstMM= change.map.first_modmap_key; - lastMM= first+change.map.num_modmap_keys-1; - } - else firstMM= lastMM= 0; - if ((last>0) && (lastMM>0)) { - if (firstMMlast) - last= lastMM; - } - else if (lastMM>0) { - first= firstMM; - last= lastMM; - } - if (last>0) { - unsigned check= 0; - XkbUpdateActions(dev,first,(last-first+1),&change,&check,&cause); - if (check) - XkbCheckSecondaryEffects(xkbi,check,&change,&cause); - } - } - if (!sentNKN) - XkbSendNotification(dev,&change,&cause); - - return Success; -allocFailure: - return BadAlloc; -} - - -int -ProcXkbSetMap(ClientPtr client) -{ - DeviceIntPtr dev; - char * tmp; - int rc; - - REQUEST(xkbSetMapReq); - REQUEST_AT_LEAST_SIZE(xkbSetMapReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); - CHK_MASK_LEGAL(0x01,stuff->present,XkbAllMapComponentsMask); - - tmp = (char *)&stuff[1]; - - /* Check if we can to the SetMap on the requested device. If this - succeeds, do the same thing for all extension devices (if needed). - If any of them fails, fail. */ - rc = _XkbSetMapChecks(client, dev, stuff, tmp); - - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - { - rc = _XkbSetMapChecks(client, other, stuff, tmp); - if (rc != Success) - return rc; - } - } - } - } - - /* We know now that we will succed with the SetMap. In theory anyway. */ - rc = _XkbSetMap(client, dev, stuff, tmp); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - _XkbSetMap(client, other, stuff, tmp); - /* ignore rc. if the SetMap failed although the check above - reported true there isn't much we can do. we still need to - set all other devices, hoping that at least they stay in - sync. */ - } - } - } - - return Success; -} - -/***====================================================================***/ - -static Status -XkbComputeGetCompatMapReplySize( XkbCompatMapPtr compat, - xkbGetCompatMapReply * rep) -{ -unsigned size,nGroups; - - nGroups= 0; - if (rep->groups!=0) { - register int i,bit; - for (i=0,bit=1;igroups&bit) - nGroups++; - } - } - size= nGroups*SIZEOF(xkbModsWireDesc); - size+= (rep->nSI*SIZEOF(xkbSymInterpretWireDesc)); - rep->length= size/4; - return Success; -} - -static int -XkbSendCompatMap( ClientPtr client, - XkbCompatMapPtr compat, - xkbGetCompatMapReply * rep) -{ -char * data; -int size; - - size= rep->length*4; - if (size>0) { - data = malloc(size); - if (data) { - register unsigned i,bit; - xkbModsWireDesc * grp; - XkbSymInterpretPtr sym= &compat->sym_interpret[rep->firstSI]; - xkbSymInterpretWireDesc *wire = (xkbSymInterpretWireDesc *)data; - for (i=0;inSI;i++,sym++,wire++) { - wire->sym= sym->sym; - wire->mods= sym->mods; - wire->match= sym->match; - wire->virtualMod= sym->virtual_mod; - wire->flags= sym->flags; - memcpy((char*)&wire->act,(char*)&sym->act,sz_xkbActionWireDesc); - if (client->swapped) { - register int n; - swapl(&wire->sym,n); - } - } - if (rep->groups) { - grp = (xkbModsWireDesc *)wire; - for (i=0,bit=1;igroups&bit) { - grp->mask= compat->groups[i].mask; - grp->realMods= compat->groups[i].real_mods; - grp->virtualMods= compat->groups[i].vmods; - if (client->swapped) { - register int n; - swaps(&grp->virtualMods,n); - } - grp++; - } - } - wire= (xkbSymInterpretWireDesc*)grp; - } - } - else return BadAlloc; - } - else data= NULL; - - if (client->swapped) { - register int n; - swaps(&rep->sequenceNumber,n); - swapl(&rep->length,n); - swaps(&rep->firstSI,n); - swaps(&rep->nSI,n); - swaps(&rep->nTotalSI,n); - } - - WriteToClient(client, SIZEOF(xkbGetCompatMapReply), (char *)rep); - if (data) { - WriteToClient(client, size, data); - free((char *)data); - } - return Success; -} - -int -ProcXkbGetCompatMap(ClientPtr client) -{ - xkbGetCompatMapReply rep; - DeviceIntPtr dev; - XkbDescPtr xkb; - XkbCompatMapPtr compat; - - REQUEST(xkbGetCompatMapReq); - REQUEST_SIZE_MATCH(xkbGetCompatMapReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - - xkb = dev->key->xkbInfo->desc; - compat= xkb->compat; - - rep.type = X_Reply; - rep.deviceID = dev->id; - rep.sequenceNumber = client->sequence; - rep.length = 0; - rep.firstSI = stuff->firstSI; - rep.nSI = stuff->nSI; - if (stuff->getAllSI) { - rep.firstSI = 0; - rep.nSI = compat->num_si; - } - else if ((((unsigned)stuff->nSI)>0)&& - ((unsigned)(stuff->firstSI+stuff->nSI-1)>=compat->num_si)) { - client->errorValue = _XkbErrCode2(0x05,compat->num_si); - return BadValue; - } - rep.nTotalSI = compat->num_si; - rep.groups= stuff->groups; - XkbComputeGetCompatMapReplySize(compat,&rep); - return XkbSendCompatMap(client,compat,&rep); -} - -/** - * Apply the given request on the given device. - * If dryRun is TRUE, then value checks are performed, but the device isn't - * modified. - */ -static int -_XkbSetCompatMap(ClientPtr client, DeviceIntPtr dev, - xkbSetCompatMapReq *req, char* data, BOOL dryRun) -{ - XkbSrvInfoPtr xkbi; - XkbDescPtr xkb; - XkbCompatMapPtr compat; - int nGroups; - unsigned i,bit; - - xkbi = dev->key->xkbInfo; - xkb = xkbi->desc; - compat = xkb->compat; - - if ((req->nSI>0)||(req->truncateSI)) { - xkbSymInterpretWireDesc *wire; - if (req->firstSI>compat->num_si) { - client->errorValue = _XkbErrCode2(0x02,compat->num_si); - return BadValue; - } - wire= (xkbSymInterpretWireDesc *)data; - wire+= req->nSI; - data = (char *)wire; - } - - nGroups= 0; - if (req->groups!=0) { - for (i=0,bit=1;igroups&bit ) - nGroups++; - } - } - data+= nGroups*SIZEOF(xkbModsWireDesc); - if (((data-((char *)req))/4)!=req->length) { - return BadLength; - } - - /* Done all the checks we can do */ - if (dryRun) - return Success; - - data = (char *)&req[1]; - if (req->nSI>0) { - xkbSymInterpretWireDesc *wire = (xkbSymInterpretWireDesc *)data; - XkbSymInterpretPtr sym; - if ((unsigned)(req->firstSI+req->nSI)>compat->num_si) { - compat->num_si= req->firstSI+req->nSI; - compat->sym_interpret= realloc(compat->sym_interpret, - compat->num_si * sizeof(XkbSymInterpretRec)); - if (!compat->sym_interpret) { - compat->num_si= 0; - return BadAlloc; - } - } - else if (req->truncateSI) { - compat->num_si = req->firstSI+req->nSI; - } - sym = &compat->sym_interpret[req->firstSI]; - for (i=0;inSI;i++,wire++,sym++) { - if (client->swapped) { - int n; - swapl(&wire->sym,n); - } - sym->sym= wire->sym; - sym->mods= wire->mods; - sym->match= wire->match; - sym->flags= wire->flags; - sym->virtual_mod= wire->virtualMod; - memcpy((char *)&sym->act,(char *)&wire->act, - SIZEOF(xkbActionWireDesc)); - } - data = (char *)wire; - } - else if (req->truncateSI) { - compat->num_si = req->firstSI; - } - - if (req->groups!=0) { - unsigned i, bit; - xkbModsWireDesc *wire = (xkbModsWireDesc *)data; - for (i = 0, bit = 1; i < XkbNumKbdGroups; i++, bit <<= 1) { - if (req->groups & bit) { - if (client->swapped) { - int n; - swaps(&wire->virtualMods,n); - } - compat->groups[i].mask= wire->realMods; - compat->groups[i].real_mods= wire->realMods; - compat->groups[i].vmods= wire->virtualMods; - if (wire->virtualMods!=0) { - unsigned tmp; - tmp= XkbMaskForVMask(xkb,wire->virtualMods); - compat->groups[i].mask|= tmp; - } - data+= SIZEOF(xkbModsWireDesc); - wire= (xkbModsWireDesc *)data; - } - } - } - i= XkbPaddedSize((data-((char *)req))); - if ((i/4)!=req->length) { - ErrorF("[xkb] Internal length error on read in _XkbSetCompatMap\n"); - return BadLength; - } - - if (dev->xkb_interest) { - xkbCompatMapNotify ev; - ev.deviceID = dev->id; - ev.changedGroups = req->groups; - ev.firstSI = req->firstSI; - ev.nSI = req->nSI; - ev.nTotalSI = compat->num_si; - XkbSendCompatMapNotify(dev,&ev); - } - - if (req->recomputeActions) { - XkbChangesRec change; - unsigned check; - XkbEventCauseRec cause; - - XkbSetCauseXkbReq(&cause,X_kbSetCompatMap,client); - memset(&change, 0, sizeof(XkbChangesRec)); - XkbUpdateActions(dev,xkb->min_key_code,XkbNumKeys(xkb),&change,&check, - &cause); - if (check) - XkbCheckSecondaryEffects(xkbi,check,&change,&cause); - XkbSendNotification(dev,&change,&cause); - } - return Success; -} - -int -ProcXkbSetCompatMap(ClientPtr client) -{ - DeviceIntPtr dev; - char *data; - int rc; - - REQUEST(xkbSetCompatMapReq); - REQUEST_AT_LEAST_SIZE(xkbSetCompatMapReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); - - data = (char *)&stuff[1]; - - /* check first using a dry-run */ - rc = _XkbSetCompatMap(client, dev, stuff, data, TRUE); - if (rc != Success) - return rc; - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - { - /* dry-run */ - rc = _XkbSetCompatMap(client, other, stuff, data, TRUE); - if (rc != Success) - return rc; - } - } - } - } - - /* Yay, the dry-runs succeed. Let's apply */ - rc = _XkbSetCompatMap(client, dev, stuff, data, FALSE); - if (rc != Success) - return rc; - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - { - rc = _XkbSetCompatMap(client, other, stuff, data, FALSE); - if (rc != Success) - return rc; - } - } - } - } - - return Success; -} - -/***====================================================================***/ - -int -ProcXkbGetIndicatorState(ClientPtr client) -{ - xkbGetIndicatorStateReply rep; - XkbSrvLedInfoPtr sli; - DeviceIntPtr dev; - register int i; - - REQUEST(xkbGetIndicatorStateReq); - REQUEST_SIZE_MATCH(xkbGetIndicatorStateReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixReadAccess); - - sli= XkbFindSrvLedInfo(dev,XkbDfltXIClass,XkbDfltXIId, - XkbXI_IndicatorStateMask); - if (!sli) - return BadAlloc; - - rep.type = X_Reply; - rep.sequenceNumber = client->sequence; - rep.length = 0; - rep.deviceID = dev->id; - rep.state = sli->effectiveState; - - if (client->swapped) { - swaps(&rep.sequenceNumber,i); - swapl(&rep.state,i); - } - WriteToClient(client, SIZEOF(xkbGetIndicatorStateReply), (char *)&rep); - return Success; -} - -/***====================================================================***/ - -static Status -XkbComputeGetIndicatorMapReplySize( - XkbIndicatorPtr indicators, - xkbGetIndicatorMapReply *rep) -{ -register int i,bit; -int nIndicators; - - rep->realIndicators = indicators->phys_indicators; - for (i=nIndicators=0,bit=1;iwhich&bit) - nIndicators++; - } - rep->length = (nIndicators*SIZEOF(xkbIndicatorMapWireDesc))/4; - return Success; -} - -static int -XkbSendIndicatorMap( ClientPtr client, - XkbIndicatorPtr indicators, - xkbGetIndicatorMapReply * rep) -{ -int length; -CARD8 * map; -register int i; -register unsigned bit; - - length = rep->length*4; - if (length>0) { - CARD8 *to; - to= map= malloc(length); - if (map) { - xkbIndicatorMapWireDesc *wire = (xkbIndicatorMapWireDesc *)to; - for (i=0,bit=1;iwhich&bit) { - wire->flags= indicators->maps[i].flags; - wire->whichGroups= indicators->maps[i].which_groups; - wire->groups= indicators->maps[i].groups; - wire->whichMods= indicators->maps[i].which_mods; - wire->mods= indicators->maps[i].mods.mask; - wire->realMods= indicators->maps[i].mods.real_mods; - wire->virtualMods= indicators->maps[i].mods.vmods; - wire->ctrls= indicators->maps[i].ctrls; - if (client->swapped) { - register int n; - swaps(&wire->virtualMods,n); - swapl(&wire->ctrls,n); - } - wire++; - } - } - to = (CARD8 *)wire; - if ((to-map)!=length) { - client->errorValue = _XkbErrCode2(0xff,length); - free(map); - return BadLength; - } - } - else return BadAlloc; - } - else map = NULL; - if (client->swapped) { - swaps(&rep->sequenceNumber,i); - swapl(&rep->length,i); - swapl(&rep->which,i); - swapl(&rep->realIndicators,i); - } - WriteToClient(client, SIZEOF(xkbGetIndicatorMapReply), (char *)rep); - if (map) { - WriteToClient(client, length, (char *)map); - free((char *)map); - } - return Success; -} - -int -ProcXkbGetIndicatorMap(ClientPtr client) -{ -xkbGetIndicatorMapReply rep; -DeviceIntPtr dev; -XkbDescPtr xkb; -XkbIndicatorPtr leds; - - REQUEST(xkbGetIndicatorMapReq); - REQUEST_SIZE_MATCH(xkbGetIndicatorMapReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - - xkb= dev->key->xkbInfo->desc; - leds= xkb->indicators; - - rep.type = X_Reply; - rep.sequenceNumber = client->sequence; - rep.length = 0; - rep.deviceID = dev->id; - rep.which = stuff->which; - XkbComputeGetIndicatorMapReplySize(leds,&rep); - return XkbSendIndicatorMap(client,leds,&rep); -} - -/** - * Apply the given map to the given device. Which specifies which components - * to apply. - */ -static int -_XkbSetIndicatorMap(ClientPtr client, DeviceIntPtr dev, - int which, xkbIndicatorMapWireDesc *desc) -{ - XkbSrvInfoPtr xkbi; - XkbSrvLedInfoPtr sli; - XkbEventCauseRec cause; - int i, bit; - - xkbi = dev->key->xkbInfo; - - sli= XkbFindSrvLedInfo(dev, XkbDfltXIClass, XkbDfltXIId, - XkbXI_IndicatorMapsMask); - if (!sli) - return BadAlloc; - - for (i = 0, bit = 1; i < XkbNumIndicators; i++, bit <<= 1) { - if (which & bit) { - sli->maps[i].flags = desc->flags; - sli->maps[i].which_groups = desc->whichGroups; - sli->maps[i].groups = desc->groups; - sli->maps[i].which_mods = desc->whichMods; - sli->maps[i].mods.mask = desc->mods; - sli->maps[i].mods.real_mods = desc->mods; - sli->maps[i].mods.vmods= desc->virtualMods; - sli->maps[i].ctrls = desc->ctrls; - if (desc->virtualMods!=0) { - unsigned tmp; - tmp= XkbMaskForVMask(xkbi->desc,desc->virtualMods); - sli->maps[i].mods.mask= desc->mods|tmp; - } - desc++; - } - } - - XkbSetCauseXkbReq(&cause,X_kbSetIndicatorMap,client); - XkbApplyLedMapChanges(dev,sli,which,NULL,NULL,&cause); - - return Success; -} - -int -ProcXkbSetIndicatorMap(ClientPtr client) -{ - int i, bit; - int nIndicators; - DeviceIntPtr dev; - xkbIndicatorMapWireDesc *from; - int rc; - - REQUEST(xkbSetIndicatorMapReq); - REQUEST_AT_LEAST_SIZE(xkbSetIndicatorMapReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixSetAttrAccess); - - if (stuff->which==0) - return Success; - - for (nIndicators=i=0,bit=1;iwhich&bit) - nIndicators++; - } - if (stuff->length!=((SIZEOF(xkbSetIndicatorMapReq)+ - (nIndicators*SIZEOF(xkbIndicatorMapWireDesc)))/4)) { - return BadLength; - } - - from = (xkbIndicatorMapWireDesc *)&stuff[1]; - for (i=0,bit=1;iwhich&bit) { - if (client->swapped) { - int n; - swaps(&from->virtualMods,n); - swapl(&from->ctrls,n); - } - CHK_MASK_LEGAL(i,from->whichGroups,XkbIM_UseAnyGroup); - CHK_MASK_LEGAL(i,from->whichMods,XkbIM_UseAnyMods); - from++; - } - } - - from = (xkbIndicatorMapWireDesc *)&stuff[1]; - rc = _XkbSetIndicatorMap(client, dev, stuff->which, from); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixSetAttrAccess); - if (rc == Success) - _XkbSetIndicatorMap(client, other, stuff->which, from); - } - } - } - - return Success; -} - -/***====================================================================***/ - -int -ProcXkbGetNamedIndicator(ClientPtr client) -{ - DeviceIntPtr dev; - xkbGetNamedIndicatorReply rep; - register int i = 0; - XkbSrvLedInfoPtr sli; - XkbIndicatorMapPtr map = NULL; - - REQUEST(xkbGetNamedIndicatorReq); - REQUEST_SIZE_MATCH(xkbGetNamedIndicatorReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_LED_DEVICE(dev, stuff->deviceSpec, client, DixReadAccess); - CHK_ATOM_ONLY(stuff->indicator); - - sli= XkbFindSrvLedInfo(dev,stuff->ledClass,stuff->ledID,0); - if (!sli) - return BadAlloc; - - i= 0; - map= NULL; - if ((sli->names)&&(sli->maps)) { - for (i=0;iindicator==sli->names[i]) { - map= &sli->maps[i]; - break; - } - } - } - - rep.type= X_Reply; - rep.length = 0; - rep.sequenceNumber = client->sequence; - rep.deviceID = dev->id; - rep.indicator= stuff->indicator; - if (map!=NULL) { - rep.found= TRUE; - rep.on= ((sli->effectiveState&(1<physIndicators&(1<flags; - rep.whichGroups= map->which_groups; - rep.groups= map->groups; - rep.whichMods= map->which_mods; - rep.mods= map->mods.mask; - rep.realMods= map->mods.real_mods; - rep.virtualMods= map->mods.vmods; - rep.ctrls= map->ctrls; - rep.supported= TRUE; - } - else { - rep.found= FALSE; - rep.on= FALSE; - rep.realIndicator= FALSE; - rep.ndx= XkbNoIndicator; - rep.flags= 0; - rep.whichGroups= 0; - rep.groups= 0; - rep.whichMods= 0; - rep.mods= 0; - rep.realMods= 0; - rep.virtualMods= 0; - rep.ctrls= 0; - rep.supported= TRUE; - } - if ( client->swapped ) { - register int n; - swapl(&rep.length,n); - swaps(&rep.sequenceNumber,n); - swapl(&rep.indicator,n); - swaps(&rep.virtualMods,n); - swapl(&rep.ctrls,n); - } - - WriteToClient(client,SIZEOF(xkbGetNamedIndicatorReply), (char *)&rep); - return Success; -} - - -/** - * Find the IM on the device. - * Returns the map, or NULL if the map doesn't exist. - * If the return value is NULL, led_return is undefined. Otherwise, led_return - * is set to the led index of the map. - */ -static XkbIndicatorMapPtr -_XkbFindNamedIndicatorMap(XkbSrvLedInfoPtr sli, Atom indicator, - int *led_return) -{ - XkbIndicatorMapPtr map; - - /* search for the right indicator */ - map = NULL; - if (sli->names && sli->maps) { - int led; - - for (led = 0; (led < XkbNumIndicators) && (map == NULL); led++) { - if (sli->names[led] == indicator) { - map= &sli->maps[led]; - *led_return = led; - break; - } - } - } - - return map; -} - -/** - * Creates an indicator map on the device. If dryRun is TRUE, it only checks - * if creation is possible, but doesn't actually create it. - */ -static int -_XkbCreateIndicatorMap(DeviceIntPtr dev, Atom indicator, - int ledClass, int ledID, - XkbIndicatorMapPtr *map_return, int *led_return, - Bool dryRun) -{ - XkbSrvLedInfoPtr sli; - XkbIndicatorMapPtr map; - int led; - - sli = XkbFindSrvLedInfo(dev, ledClass, ledID, XkbXI_IndicatorsMask); - if (!sli) - return BadAlloc; - - map = _XkbFindNamedIndicatorMap(sli, indicator, &led); - - if (!map) - { - /* find first unused indicator maps and assign the name to it */ - for (led = 0, map = NULL; (led < XkbNumIndicators) && (map == NULL); led++) { - if ((sli->names) && (sli->maps) && (sli->names[led] == None) && - (!XkbIM_InUse(&sli->maps[led]))) - { - map = &sli->maps[led]; - if (!dryRun) - sli->names[led] = indicator; - break; - } - } - } - - if (!map) - return BadAlloc; - - *led_return = led; - *map_return = map; - return Success; -} - -static int -_XkbSetNamedIndicator(ClientPtr client, DeviceIntPtr dev, - xkbSetNamedIndicatorReq *stuff) -{ - unsigned int extDevReason; - unsigned int statec, namec, mapc; - XkbSrvLedInfoPtr sli; - int led = 0; - XkbIndicatorMapPtr map; - DeviceIntPtr kbd; - XkbEventCauseRec cause; - xkbExtensionDeviceNotify ed; - XkbChangesRec changes; - int rc; - - rc = _XkbCreateIndicatorMap(dev, stuff->indicator, stuff->ledClass, - stuff->ledID, &map, &led, FALSE); - if (rc != Success || !map) /* oh-oh */ - return rc; - - sli = XkbFindSrvLedInfo(dev, stuff->ledClass, stuff->ledID, - XkbXI_IndicatorsMask); - if (!sli) - return BadAlloc; - - namec = mapc = statec = 0; - extDevReason = 0; - - namec |= (1<namesPresent |= ((stuff->indicator != None) ? (1 << led) : 0); - extDevReason |= XkbXI_IndicatorNamesMask; - - if (stuff->setMap) { - map->flags = stuff->flags; - map->which_groups = stuff->whichGroups; - map->groups = stuff->groups; - map->which_mods = stuff->whichMods; - map->mods.mask = stuff->realMods; - map->mods.real_mods = stuff->realMods; - map->mods.vmods= stuff->virtualMods; - map->ctrls = stuff->ctrls; - mapc|= (1<setState) && ((map->flags & XkbIM_NoExplicit) == 0)) - { - if (stuff->on) sli->explicitState |= (1<explicitState &= ~(1<effectiveState ^ sli->explicitState) & (1 << led)); - } - - memset((char *)&ed, 0, sizeof(xkbExtensionDeviceNotify)); - memset((char *)&changes, 0, sizeof(XkbChangesRec)); - XkbSetCauseXkbReq(&cause,X_kbSetNamedIndicator,client); - if (namec) - XkbApplyLedNameChanges(dev,sli,namec,&ed,&changes,&cause); - if (mapc) - XkbApplyLedMapChanges(dev,sli,mapc,&ed,&changes,&cause); - if (statec) - XkbApplyLedStateChanges(dev,sli,statec,&ed,&changes,&cause); - - kbd = dev; - if ((sli->flags&XkbSLI_HasOwnState)==0) - kbd = inputInfo.keyboard; - XkbFlushLedEvents(dev, kbd, sli, &ed, &changes, &cause); - - return Success; -} - -int -ProcXkbSetNamedIndicator(ClientPtr client) -{ - int rc; - DeviceIntPtr dev; - int led = 0; - XkbIndicatorMapPtr map; - - REQUEST(xkbSetNamedIndicatorReq); - REQUEST_SIZE_MATCH(xkbSetNamedIndicatorReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_LED_DEVICE(dev, stuff->deviceSpec, client, DixSetAttrAccess); - CHK_ATOM_ONLY(stuff->indicator); - CHK_MASK_LEGAL(0x10,stuff->whichGroups,XkbIM_UseAnyGroup); - CHK_MASK_LEGAL(0x11,stuff->whichMods,XkbIM_UseAnyMods); - - /* Dry-run for checks */ - rc = _XkbCreateIndicatorMap(dev, stuff->indicator, - stuff->ledClass, stuff->ledID, - &map, &led, TRUE); - if (rc != Success || !map) /* couldn't be created or didn't exist */ - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd || - stuff->deviceSpec == XkbUseCorePtr) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev && - (other->kbdfeed || other->leds) && - (XaceHook(XACE_DEVICE_ACCESS, client, other, DixSetAttrAccess) == Success)) - { - rc = _XkbCreateIndicatorMap(other, stuff->indicator, - stuff->ledClass, stuff->ledID, - &map, &led, TRUE); - if (rc != Success || !map) - return rc; - } - } - } - - /* All checks passed, let's do it */ - rc = _XkbSetNamedIndicator(client, dev, stuff); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd || - stuff->deviceSpec == XkbUseCorePtr) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev && - (other->kbdfeed || other->leds) && - (XaceHook(XACE_DEVICE_ACCESS, client, other, DixSetAttrAccess) == Success)) - { - _XkbSetNamedIndicator(client, other, stuff); - } - } - } - - return Success; -} - -/***====================================================================***/ - -static CARD32 -_XkbCountAtoms(Atom *atoms,int maxAtoms,int *count) -{ -register unsigned int i,bit,nAtoms; -register CARD32 atomsPresent; - - for (i=nAtoms=atomsPresent=0,bit=1;iminKeyCode= xkb->min_key_code; - rep->maxKeyCode= xkb->max_key_code; - which= rep->which; - length= 0; - if (xkb->names!=NULL) { - if (which&XkbKeycodesNameMask) length++; - if (which&XkbGeometryNameMask) length++; - if (which&XkbSymbolsNameMask) length++; - if (which&XkbPhysSymbolsNameMask) length++; - if (which&XkbTypesNameMask) length++; - if (which&XkbCompatNameMask) length++; - } - else which&= ~XkbComponentNamesMask; - - if (xkb->map!=NULL) { - if (which&XkbKeyTypeNamesMask) - length+= xkb->map->num_types; - rep->nTypes= xkb->map->num_types; - if (which&XkbKTLevelNamesMask) { - XkbKeyTypePtr pType = xkb->map->types; - int nKTLevels = 0; - - length+= XkbPaddedSize(xkb->map->num_types)/4; - for (i=0;imap->num_types;i++,pType++) { - if (pType->level_names!=NULL) - nKTLevels+= pType->num_levels; - } - rep->nKTLevels= nKTLevels; - length+= nKTLevels; - } - } - else { - rep->nTypes= 0; - rep->nKTLevels= 0; - which&= ~(XkbKeyTypeNamesMask|XkbKTLevelNamesMask); - } - - rep->minKeyCode= xkb->min_key_code; - rep->maxKeyCode= xkb->max_key_code; - rep->indicators= 0; - rep->virtualMods= 0; - rep->groupNames= 0; - if (xkb->names!=NULL) { - if (which&XkbIndicatorNamesMask) { - int nLeds; - rep->indicators= - _XkbCountAtoms(xkb->names->indicators,XkbNumIndicators,&nLeds); - length+= nLeds; - if (nLeds==0) - which&= ~XkbIndicatorNamesMask; - } - - if (which&XkbVirtualModNamesMask) { - int nVMods; - rep->virtualMods= - _XkbCountAtoms(xkb->names->vmods,XkbNumVirtualMods,&nVMods); - length+= nVMods; - if (nVMods==0) - which&= ~XkbVirtualModNamesMask; - } - - if (which&XkbGroupNamesMask) { - int nGroups; - rep->groupNames= - _XkbCountAtoms(xkb->names->groups,XkbNumKbdGroups,&nGroups); - length+= nGroups; - if (nGroups==0) - which&= ~XkbGroupNamesMask; - } - - if ((which&XkbKeyNamesMask)&&(xkb->names->keys)) - length+= rep->nKeys; - else which&= ~XkbKeyNamesMask; - - if ((which&XkbKeyAliasesMask)&& - (xkb->names->key_aliases)&&(xkb->names->num_key_aliases>0)) { - rep->nKeyAliases= xkb->names->num_key_aliases; - length+= rep->nKeyAliases*2; - } - else { - which&= ~XkbKeyAliasesMask; - rep->nKeyAliases= 0; - } - - if ((which&XkbRGNamesMask)&&(xkb->names->num_rg>0)) - length+= xkb->names->num_rg; - else which&= ~XkbRGNamesMask; - } - else { - which&= ~(XkbIndicatorNamesMask|XkbVirtualModNamesMask); - which&= ~(XkbGroupNamesMask|XkbKeyNamesMask|XkbKeyAliasesMask); - which&= ~XkbRGNamesMask; - } - - rep->length= length; - rep->which= which; - return Success; -} - -static int -XkbSendNames(ClientPtr client,XkbDescPtr xkb,xkbGetNamesReply *rep) -{ -register unsigned i,length,which; -char * start; -char * desc; -register int n; - - length= rep->length*4; - which= rep->which; - if (client->swapped) { - swaps(&rep->sequenceNumber,n); - swapl(&rep->length,n); - swapl(&rep->which,n); - swaps(&rep->virtualMods,n); - swapl(&rep->indicators,n); - } - - start = desc = malloc(length); - if ( !start ) - return BadAlloc; - if (xkb->names) { - if (which&XkbKeycodesNameMask) { - *((CARD32 *)desc)= xkb->names->keycodes; - if (client->swapped) { - swapl(desc,n); - } - desc+= 4; - } - if (which&XkbGeometryNameMask) { - *((CARD32 *)desc)= xkb->names->geometry; - if (client->swapped) { - swapl(desc,n); - } - desc+= 4; - } - if (which&XkbSymbolsNameMask) { - *((CARD32 *)desc)= xkb->names->symbols; - if (client->swapped) { - swapl(desc,n); - } - desc+= 4; - } - if (which&XkbPhysSymbolsNameMask) { - register CARD32 *atm= (CARD32 *)desc; - atm[0]= (CARD32)xkb->names->phys_symbols; - if (client->swapped) { - swapl(&atm[0],n); - } - desc+= 4; - } - if (which&XkbTypesNameMask) { - *((CARD32 *)desc)= (CARD32)xkb->names->types; - if (client->swapped) { - swapl(desc,n); - } - desc+= 4; - } - if (which&XkbCompatNameMask) { - *((CARD32 *)desc)= (CARD32)xkb->names->compat; - if (client->swapped) { - swapl(desc,n); - } - desc+= 4; - } - if (which&XkbKeyTypeNamesMask) { - register CARD32 *atm= (CARD32 *)desc; - register XkbKeyTypePtr type= xkb->map->types; - - for (i=0;imap->num_types;i++,atm++,type++) { - *atm= (CARD32)type->name; - if (client->swapped) { - swapl(atm,n); - } - } - desc= (char *)atm; - } - if (which&XkbKTLevelNamesMask && xkb->map) { - XkbKeyTypePtr type = xkb->map->types; - register CARD32 *atm; - for (i=0;inTypes;i++,type++) { - *desc++ = type->num_levels; - } - desc+= XkbPaddedSize(rep->nTypes)-rep->nTypes; - - atm= (CARD32 *)desc; - type = xkb->map->types; - for (i=0;imap->num_types;i++,type++) { - register unsigned l; - if (type->level_names) { - for (l=0;lnum_levels;l++,atm++) { - *atm= type->level_names[l]; - if (client->swapped) { - swapl(atm,n); - } - } - desc+= type->num_levels*4; - } - } - } - if (which&XkbIndicatorNamesMask) { - desc= _XkbWriteAtoms(desc,xkb->names->indicators,XkbNumIndicators, - client->swapped); - } - if (which&XkbVirtualModNamesMask) { - desc= _XkbWriteAtoms(desc,xkb->names->vmods,XkbNumVirtualMods, - client->swapped); - } - if (which&XkbGroupNamesMask) { - desc= _XkbWriteAtoms(desc,xkb->names->groups,XkbNumKbdGroups, - client->swapped); - } - if (which&XkbKeyNamesMask) { - for (i=0;inKeys;i++,desc+= sizeof(XkbKeyNameRec)) { - *((XkbKeyNamePtr)desc)= xkb->names->keys[i+rep->firstKey]; - } - } - if (which&XkbKeyAliasesMask) { - XkbKeyAliasPtr pAl; - pAl= xkb->names->key_aliases; - for (i=0;inKeyAliases;i++,pAl++,desc+=2*XkbKeyNameLength) { - *((XkbKeyAliasPtr)desc)= *pAl; - } - } - if ((which&XkbRGNamesMask)&&(rep->nRadioGroups>0)) { - register CARD32 *atm= (CARD32 *)desc; - for (i=0;inRadioGroups;i++,atm++) { - *atm= (CARD32)xkb->names->radio_groups[i]; - if (client->swapped) { - swapl(atm,n); - } - } - desc+= rep->nRadioGroups*4; - } - } - - if ((desc-start)!=(length)) { - ErrorF("[xkb] BOGUS LENGTH in write names, expected %d, got %ld\n", - length, (unsigned long)(desc-start)); - } - WriteToClient(client, SIZEOF(xkbGetNamesReply), (char *)rep); - WriteToClient(client, length, start); - free((char *)start); - return Success; -} - -int -ProcXkbGetNames(ClientPtr client) -{ - DeviceIntPtr dev; - XkbDescPtr xkb; - xkbGetNamesReply rep; - - REQUEST(xkbGetNamesReq); - REQUEST_SIZE_MATCH(xkbGetNamesReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - CHK_MASK_LEGAL(0x01,stuff->which,XkbAllNamesMask); - - xkb = dev->key->xkbInfo->desc; - memset(&rep, 0, sizeof(xkbGetNamesReply)); - rep.type= X_Reply; - rep.sequenceNumber= client->sequence; - rep.length = 0; - rep.deviceID = dev->id; - rep.which = stuff->which; - rep.nTypes = xkb->map->num_types; - rep.firstKey = xkb->min_key_code; - rep.nKeys = XkbNumKeys(xkb); - if (xkb->names!=NULL) { - rep.nKeyAliases= xkb->names->num_key_aliases; - rep.nRadioGroups = xkb->names->num_rg; - } - else { - rep.nKeyAliases= rep.nRadioGroups= 0; - } - XkbComputeGetNamesReplySize(xkb,&rep); - return XkbSendNames(client,xkb,&rep); -} - -/***====================================================================***/ - -static CARD32 * -_XkbCheckAtoms(CARD32 *wire,int nAtoms,int swapped,Atom *pError) -{ -register int i; - - for (i=0;ikey->xkbInfo->desc; - names = xkb->names; - - - if (stuff->which & XkbKeyTypeNamesMask) { - int i; - CARD32 *old; - if ( stuff->nTypes<1 ) { - client->errorValue = _XkbErrCode2(0x02,stuff->nTypes); - return BadValue; - } - if ((unsigned)(stuff->firstType+stuff->nTypes-1)>=xkb->map->num_types) { - client->errorValue = _XkbErrCode4(0x03,stuff->firstType, - stuff->nTypes, - xkb->map->num_types); - return BadValue; - } - if (((unsigned)stuff->firstType)<=XkbLastRequiredType) { - client->errorValue = _XkbErrCode2(0x04,stuff->firstType); - return BadAccess; - } - old= tmp; - tmp= _XkbCheckAtoms(tmp,stuff->nTypes,client->swapped,&bad); - if (!tmp) { - client->errorValue= bad; - return BadAtom; - } - for (i=0;inTypes;i++,old++) { - if (!_XkbCheckTypeName((Atom)*old,stuff->firstType+i)) - client->errorValue= _XkbErrCode2(0x05,i); - } - } - if (stuff->which&XkbKTLevelNamesMask) { - unsigned i; - XkbKeyTypePtr type; - CARD8 * width; - if ( stuff->nKTLevels<1 ) { - client->errorValue = _XkbErrCode2(0x05,stuff->nKTLevels); - return BadValue; - } - if ((unsigned)(stuff->firstKTLevel+stuff->nKTLevels-1)>= - xkb->map->num_types) { - client->errorValue = _XkbErrCode4(0x06,stuff->firstKTLevel, - stuff->nKTLevels,xkb->map->num_types); - return BadValue; - } - width = (CARD8 *)tmp; - tmp= (CARD32 *)(((char *)tmp)+XkbPaddedSize(stuff->nKTLevels)); - type = &xkb->map->types[stuff->firstKTLevel]; - for (i=0;inKTLevels;i++,type++) { - if (width[i]==0) - continue; - else if (width[i]!=type->num_levels) { - client->errorValue= _XkbErrCode4(0x07,i+stuff->firstKTLevel, - type->num_levels,width[i]); - return BadMatch; - } - tmp= _XkbCheckAtoms(tmp,width[i],client->swapped,&bad); - if (!tmp) { - client->errorValue= bad; - return BadAtom; - } - } - } - if (stuff->which&XkbIndicatorNamesMask) { - if (stuff->indicators==0) { - client->errorValue= 0x08; - return BadMatch; - } - tmp= _XkbCheckMaskedAtoms(tmp,XkbNumIndicators,stuff->indicators, - client->swapped,&bad); - if (!tmp) { - client->errorValue= bad; - return BadAtom; - } - } - if (stuff->which&XkbVirtualModNamesMask) { - if (stuff->virtualMods==0) { - client->errorValue= 0x09; - return BadMatch; - } - tmp= _XkbCheckMaskedAtoms(tmp,XkbNumVirtualMods, - (CARD32)stuff->virtualMods, - client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - if (stuff->which&XkbGroupNamesMask) { - if (stuff->groupNames==0) { - client->errorValue= 0x0a; - return BadMatch; - } - tmp= _XkbCheckMaskedAtoms(tmp,XkbNumKbdGroups, - (CARD32)stuff->groupNames, - client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - if (stuff->which&XkbKeyNamesMask) { - if (stuff->firstKey<(unsigned)xkb->min_key_code) { - client->errorValue= _XkbErrCode3(0x0b,xkb->min_key_code, - stuff->firstKey); - return BadValue; - } - if (((unsigned)(stuff->firstKey+stuff->nKeys-1)>xkb->max_key_code)|| - (stuff->nKeys<1)) { - client->errorValue= _XkbErrCode4(0x0c,xkb->max_key_code, - stuff->firstKey,stuff->nKeys); - return BadValue; - } - tmp+= stuff->nKeys; - } - if ((stuff->which&XkbKeyAliasesMask)&&(stuff->nKeyAliases>0)) { - tmp+= stuff->nKeyAliases*2; - } - if (stuff->which&XkbRGNamesMask) { - if ( stuff->nRadioGroups<1 ) { - client->errorValue= _XkbErrCode2(0x0d,stuff->nRadioGroups); - return BadValue; - } - tmp= _XkbCheckAtoms(tmp,stuff->nRadioGroups,client->swapped,&bad); - if (!tmp) { - client->errorValue= bad; - return BadAtom; - } - } - if ((tmp-((CARD32 *)stuff))!=stuff->length) { - client->errorValue = stuff->length; - return BadLength; - } - - - - return Success; -} - -static int -_XkbSetNames(ClientPtr client, DeviceIntPtr dev, xkbSetNamesReq *stuff) -{ - XkbDescRec *xkb; - XkbNamesRec *names; - CARD32 *tmp; - xkbNamesNotify nn; - - tmp = (CARD32 *)&stuff[1]; - xkb = dev->key->xkbInfo->desc; - names = xkb->names; - - if (XkbAllocNames(xkb,stuff->which,stuff->nRadioGroups, - stuff->nKeyAliases)!=Success) { - return BadAlloc; - } - - memset(&nn, 0, sizeof(xkbNamesNotify)); - nn.changed= stuff->which; - tmp = (CARD32 *)&stuff[1]; - if (stuff->which&XkbKeycodesNameMask) - names->keycodes= *tmp++; - if (stuff->which&XkbGeometryNameMask) - names->geometry= *tmp++; - if (stuff->which&XkbSymbolsNameMask) - names->symbols= *tmp++; - if (stuff->which&XkbPhysSymbolsNameMask) - names->phys_symbols= *tmp++; - if (stuff->which&XkbTypesNameMask) - names->types= *tmp++; - if (stuff->which&XkbCompatNameMask) - names->compat= *tmp++; - if ((stuff->which&XkbKeyTypeNamesMask)&&(stuff->nTypes>0)) { - register unsigned i; - register XkbKeyTypePtr type; - - type= &xkb->map->types[stuff->firstType]; - for (i=0;inTypes;i++,type++) { - type->name= *tmp++; - } - nn.firstType= stuff->firstType; - nn.nTypes= stuff->nTypes; - } - if (stuff->which&XkbKTLevelNamesMask) { - register XkbKeyTypePtr type; - register unsigned i; - CARD8 *width; - - width = (CARD8 *)tmp; - tmp= (CARD32 *)(((char *)tmp)+XkbPaddedSize(stuff->nKTLevels)); - type= &xkb->map->types[stuff->firstKTLevel]; - for (i=0;inKTLevels;i++,type++) { - if (width[i]>0) { - if (type->level_names) { - register unsigned n; - for (n=0;nlevel_names[n]= tmp[n]; - } - } - tmp+= width[i]; - } - } - nn.firstLevelName= 0; - nn.nLevelNames= stuff->nTypes; - } - if (stuff->which&XkbIndicatorNamesMask) { - tmp= _XkbCopyMaskedAtoms(tmp,names->indicators,XkbNumIndicators, - stuff->indicators); - nn.changedIndicators= stuff->indicators; - } - if (stuff->which&XkbVirtualModNamesMask) { - tmp= _XkbCopyMaskedAtoms(tmp,names->vmods,XkbNumVirtualMods, - stuff->virtualMods); - nn.changedVirtualMods= stuff->virtualMods; - } - if (stuff->which&XkbGroupNamesMask) { - tmp= _XkbCopyMaskedAtoms(tmp,names->groups,XkbNumKbdGroups, - stuff->groupNames); - nn.changedVirtualMods= stuff->groupNames; - } - if (stuff->which&XkbKeyNamesMask) { - memcpy((char*)&names->keys[stuff->firstKey],(char *)tmp, - stuff->nKeys*XkbKeyNameLength); - tmp+= stuff->nKeys; - nn.firstKey= stuff->firstKey; - nn.nKeys= stuff->nKeys; - } - if (stuff->which&XkbKeyAliasesMask) { - if (stuff->nKeyAliases>0) { - register int na= stuff->nKeyAliases; - if (XkbAllocNames(xkb,XkbKeyAliasesMask,0,na)!=Success) - return BadAlloc; - memcpy((char *)names->key_aliases,(char *)tmp, - stuff->nKeyAliases*sizeof(XkbKeyAliasRec)); - tmp+= stuff->nKeyAliases*2; - } - else if (names->key_aliases!=NULL) { - free(names->key_aliases); - names->key_aliases= NULL; - names->num_key_aliases= 0; - } - nn.nAliases= names->num_key_aliases; - } - if (stuff->which&XkbRGNamesMask) { - if (stuff->nRadioGroups>0) { - register unsigned i,nrg; - nrg= stuff->nRadioGroups; - if (XkbAllocNames(xkb,XkbRGNamesMask,nrg,0)!=Success) - return BadAlloc; - - for (i=0;inRadioGroups;i++) { - names->radio_groups[i]= tmp[i]; - } - tmp+= stuff->nRadioGroups; - } - else if (names->radio_groups) { - free(names->radio_groups); - names->radio_groups= NULL; - names->num_rg= 0; - } - nn.nRadioGroups= names->num_rg; - } - if (nn.changed) { - Bool needExtEvent; - needExtEvent= (nn.changed&XkbIndicatorNamesMask)!=0; - XkbSendNamesNotify(dev,&nn); - if (needExtEvent) { - XkbSrvLedInfoPtr sli; - xkbExtensionDeviceNotify edev; - register int i; - register unsigned bit; - - sli= XkbFindSrvLedInfo(dev,XkbDfltXIClass,XkbDfltXIId, - XkbXI_IndicatorsMask); - sli->namesPresent= 0; - for (i=0,bit=1;iindicators[i]!=None) - sli->namesPresent|= bit; - } - memset(&edev, 0, sizeof(xkbExtensionDeviceNotify)); - edev.reason= XkbXI_IndicatorNamesMask; - edev.ledClass= KbdFeedbackClass; - edev.ledID= dev->kbdfeed->ctrl.id; - edev.ledsDefined= sli->namesPresent|sli->mapsPresent; - edev.ledState= sli->effectiveState; - edev.firstBtn= 0; - edev.nBtns= 0; - edev.supported= XkbXI_AllFeaturesMask; - edev.unsupported= 0; - XkbSendExtensionDeviceNotify(dev,client,&edev); - } - } - return Success; -} - -int -ProcXkbSetNames(ClientPtr client) -{ - DeviceIntPtr dev; - CARD32 *tmp; - Atom bad; - int rc; - - REQUEST(xkbSetNamesReq); - REQUEST_AT_LEAST_SIZE(xkbSetNamesReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); - CHK_MASK_LEGAL(0x01,stuff->which,XkbAllNamesMask); - - /* check device-independent stuff */ - tmp = (CARD32 *)&stuff[1]; - - if (stuff->which&XkbKeycodesNameMask) { - tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - if (stuff->which&XkbGeometryNameMask) { - tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - if (stuff->which&XkbSymbolsNameMask) { - tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - if (stuff->which&XkbPhysSymbolsNameMask) { - tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); - if (!tmp) { - client->errorValue= bad; - return BadAtom; - } - } - if (stuff->which&XkbTypesNameMask) { - tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - if (stuff->which&XkbCompatNameMask) { - tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); - if (!tmp) { - client->errorValue = bad; - return BadAtom; - } - } - - /* start of device-dependent tests */ - rc = _XkbSetNamesCheck(client, dev, stuff, tmp); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - { - rc = _XkbSetNamesCheck(client, other, stuff, tmp); - if (rc != Success) - return rc; - } - } - } - } - - /* everything is okay -- update names */ - - rc = _XkbSetNames(client, dev, stuff); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - _XkbSetNames(client, other, stuff); - } - } - } - - /* everything is okay -- update names */ - - return Success; -} - -/***====================================================================***/ - -#include "xkbgeom.h" - -#define XkbSizeCountedString(s) ((s)?((((2+strlen(s))+3)/4)*4):4) - -static char * -XkbWriteCountedString(char *wire,char *str,Bool swap) -{ - CARD16 len,*pLen; - - if (!str) - return wire; - - len= strlen(str); - pLen= (CARD16 *)wire; - *pLen= len; - if (swap) { - register int n; - swaps(pLen,n); - } - memcpy(&wire[2],str,len); - wire+= ((2+len+3)/4)*4; - return wire; -} - -static int -XkbSizeGeomProperties(XkbGeometryPtr geom) -{ -register int i,size; -XkbPropertyPtr prop; - - for (size=i=0,prop=geom->properties;inum_properties;i++,prop++) { - size+= XkbSizeCountedString(prop->name); - size+= XkbSizeCountedString(prop->value); - } - return size; -} - -static char * -XkbWriteGeomProperties(char *wire,XkbGeometryPtr geom,Bool swap) -{ -register int i; -register XkbPropertyPtr prop; - - for (i=0,prop=geom->properties;inum_properties;i++,prop++) { - wire= XkbWriteCountedString(wire,prop->name,swap); - wire= XkbWriteCountedString(wire,prop->value,swap); - } - return wire; -} - -static int -XkbSizeGeomKeyAliases(XkbGeometryPtr geom) -{ - return geom->num_key_aliases*(2*XkbKeyNameLength); -} - -static char * -XkbWriteGeomKeyAliases(char *wire,XkbGeometryPtr geom,Bool swap) -{ -register int sz; - - sz= geom->num_key_aliases*(XkbKeyNameLength*2); - if (sz>0) { - memcpy(wire,(char *)geom->key_aliases,sz); - wire+= sz; - } - return wire; -} - -static int -XkbSizeGeomColors(XkbGeometryPtr geom) -{ -register int i,size; -register XkbColorPtr color; - - for (i=size=0,color=geom->colors;inum_colors;i++,color++) { - size+= XkbSizeCountedString(color->spec); - } - return size; -} - -static char * -XkbWriteGeomColors(char *wire,XkbGeometryPtr geom,Bool swap) -{ -register int i; -register XkbColorPtr color; - - for (i=0,color=geom->colors;inum_colors;i++,color++) { - wire= XkbWriteCountedString(wire,color->spec,swap); - } - return wire; -} - -static int -XkbSizeGeomShapes(XkbGeometryPtr geom) -{ -register int i,size; -register XkbShapePtr shape; - - for (i=size=0,shape=geom->shapes;inum_shapes;i++,shape++) { - register int n; - register XkbOutlinePtr ol; - size+= SIZEOF(xkbShapeWireDesc); - for (n=0,ol=shape->outlines;nnum_outlines;n++,ol++) { - size+= SIZEOF(xkbOutlineWireDesc); - size+= ol->num_points*SIZEOF(xkbPointWireDesc); - } - } - return size; -} - -static char * -XkbWriteGeomShapes(char *wire,XkbGeometryPtr geom,Bool swap) -{ -int i; -XkbShapePtr shape; -xkbShapeWireDesc * shapeWire; - - for (i=0,shape=geom->shapes;inum_shapes;i++,shape++) { - register int o; - XkbOutlinePtr ol; - xkbOutlineWireDesc * olWire; - shapeWire= (xkbShapeWireDesc *)wire; - shapeWire->name= shape->name; - shapeWire->nOutlines= shape->num_outlines; - if (shape->primary!=NULL) - shapeWire->primaryNdx= XkbOutlineIndex(shape,shape->primary); - else shapeWire->primaryNdx= XkbNoShape; - if (shape->approx!=NULL) - shapeWire->approxNdx= XkbOutlineIndex(shape,shape->approx); - else shapeWire->approxNdx= XkbNoShape; - if (swap) { - register int n; - swapl(&shapeWire->name,n); - } - wire= (char *)&shapeWire[1]; - for (o=0,ol=shape->outlines;onum_outlines;o++,ol++) { - register int p; - XkbPointPtr pt; - xkbPointWireDesc * ptWire; - olWire= (xkbOutlineWireDesc *)wire; - olWire->nPoints= ol->num_points; - olWire->cornerRadius= ol->corner_radius; - wire= (char *)&olWire[1]; - ptWire= (xkbPointWireDesc *)wire; - for (p=0,pt=ol->points;pnum_points;p++,pt++) { - ptWire[p].x= pt->x; - ptWire[p].y= pt->y; - if (swap) { - register int n; - swaps(&ptWire[p].x,n); - swaps(&ptWire[p].y,n); - } - } - wire= (char *)&ptWire[ol->num_points]; - } - } - return wire; -} - -static int -XkbSizeGeomDoodads(int num_doodads,XkbDoodadPtr doodad) -{ -register int i,size; - - for (i=size=0;iany.type==XkbTextDoodad) { - size+= XkbSizeCountedString(doodad->text.text); - size+= XkbSizeCountedString(doodad->text.font); - } - else if (doodad->any.type==XkbLogoDoodad) { - size+= XkbSizeCountedString(doodad->logo.logo_name); - } - } - return size; -} - -static char * -XkbWriteGeomDoodads(char *wire,int num_doodads,XkbDoodadPtr doodad,Bool swap) -{ -register int i; -xkbDoodadWireDesc * doodadWire; - - for (i=0;iany.name= doodad->any.name; - doodadWire->any.type= doodad->any.type; - doodadWire->any.priority= doodad->any.priority; - doodadWire->any.top= doodad->any.top; - doodadWire->any.left= doodad->any.left; - if (swap) { - register int n; - swapl(&doodadWire->any.name,n); - swaps(&doodadWire->any.top,n); - swaps(&doodadWire->any.left,n); - } - switch (doodad->any.type) { - case XkbOutlineDoodad: - case XkbSolidDoodad: - doodadWire->shape.angle= doodad->shape.angle; - doodadWire->shape.colorNdx= doodad->shape.color_ndx; - doodadWire->shape.shapeNdx= doodad->shape.shape_ndx; - if (swap) { - register int n; - swaps(&doodadWire->shape.angle,n); - } - break; - case XkbTextDoodad: - doodadWire->text.angle= doodad->text.angle; - doodadWire->text.width= doodad->text.width; - doodadWire->text.height= doodad->text.height; - doodadWire->text.colorNdx= doodad->text.color_ndx; - if (swap) { - register int n; - swaps(&doodadWire->text.angle,n); - swaps(&doodadWire->text.width,n); - swaps(&doodadWire->text.height,n); - } - wire= XkbWriteCountedString(wire,doodad->text.text,swap); - wire= XkbWriteCountedString(wire,doodad->text.font,swap); - break; - case XkbIndicatorDoodad: - doodadWire->indicator.shapeNdx= doodad->indicator.shape_ndx; - doodadWire->indicator.onColorNdx=doodad->indicator.on_color_ndx; - doodadWire->indicator.offColorNdx= - doodad->indicator.off_color_ndx; - break; - case XkbLogoDoodad: - doodadWire->logo.angle= doodad->logo.angle; - doodadWire->logo.colorNdx= doodad->logo.color_ndx; - doodadWire->logo.shapeNdx= doodad->logo.shape_ndx; - wire= XkbWriteCountedString(wire,doodad->logo.logo_name,swap); - break; - default: - ErrorF("[xkb] Unknown doodad type %d in XkbWriteGeomDoodads\n", - doodad->any.type); - ErrorF("[xkb] Ignored\n"); - break; - } - } - return wire; -} - -static char * -XkbWriteGeomOverlay(char *wire,XkbOverlayPtr ol,Bool swap) -{ -register int r; -XkbOverlayRowPtr row; -xkbOverlayWireDesc * olWire; - - olWire= (xkbOverlayWireDesc *)wire; - olWire->name= ol->name; - olWire->nRows= ol->num_rows; - if (swap) { - register int n; - swapl(&olWire->name,n); - } - wire= (char *)&olWire[1]; - for (r=0,row=ol->rows;rnum_rows;r++,row++) { - unsigned int k; - XkbOverlayKeyPtr key; - xkbOverlayRowWireDesc * rowWire; - rowWire= (xkbOverlayRowWireDesc *)wire; - rowWire->rowUnder= row->row_under; - rowWire->nKeys= row->num_keys; - wire= (char *)&rowWire[1]; - for (k=0,key=row->keys;knum_keys;k++,key++) { - xkbOverlayKeyWireDesc * keyWire; - keyWire= (xkbOverlayKeyWireDesc *)wire; - memcpy(keyWire->over,key->over.name,XkbKeyNameLength); - memcpy(keyWire->under,key->under.name,XkbKeyNameLength); - wire= (char *)&keyWire[1]; - } - } - return wire; -} - -static int -XkbSizeGeomSections(XkbGeometryPtr geom) -{ -register int i,size; -XkbSectionPtr section; - - for (i=size=0,section=geom->sections;inum_sections;i++,section++) { - size+= SIZEOF(xkbSectionWireDesc); - if (section->rows) { - int r; - XkbRowPtr row; - for (r=0,row=section->rows;rnum_rows;row++,r++) { - size+= SIZEOF(xkbRowWireDesc); - size+= row->num_keys*SIZEOF(xkbKeyWireDesc); - } - } - if (section->doodads) - size+= XkbSizeGeomDoodads(section->num_doodads,section->doodads); - if (section->overlays) { - int o; - XkbOverlayPtr ol; - for (o=0,ol=section->overlays;onum_overlays;o++,ol++) { - int r; - XkbOverlayRowPtr row; - size+= SIZEOF(xkbOverlayWireDesc); - for (r=0,row=ol->rows;rnum_rows;r++,row++) { - size+= SIZEOF(xkbOverlayRowWireDesc); - size+= row->num_keys*SIZEOF(xkbOverlayKeyWireDesc); - } - } - } - } - return size; -} - -static char * -XkbWriteGeomSections(char *wire,XkbGeometryPtr geom,Bool swap) -{ -register int i; -XkbSectionPtr section; -xkbSectionWireDesc * sectionWire; - - for (i=0,section=geom->sections;inum_sections;i++,section++) { - sectionWire= (xkbSectionWireDesc *)wire; - sectionWire->name= section->name; - sectionWire->top= section->top; - sectionWire->left= section->left; - sectionWire->width= section->width; - sectionWire->height= section->height; - sectionWire->angle= section->angle; - sectionWire->priority= section->priority; - sectionWire->nRows= section->num_rows; - sectionWire->nDoodads= section->num_doodads; - sectionWire->nOverlays= section->num_overlays; - sectionWire->pad= 0; - if (swap) { - register int n; - swapl(§ionWire->name,n); - swaps(§ionWire->top,n); - swaps(§ionWire->left,n); - swaps(§ionWire->width,n); - swaps(§ionWire->height,n); - swaps(§ionWire->angle,n); - } - wire= (char *)§ionWire[1]; - if (section->rows) { - int r; - XkbRowPtr row; - xkbRowWireDesc * rowWire; - for (r=0,row=section->rows;rnum_rows;r++,row++) { - rowWire= (xkbRowWireDesc *)wire; - rowWire->top= row->top; - rowWire->left= row->left; - rowWire->nKeys= row->num_keys; - rowWire->vertical= row->vertical; - rowWire->pad= 0; - if (swap) { - register int n; - swaps(&rowWire->top,n); - swaps(&rowWire->left,n); - } - wire= (char *)&rowWire[1]; - if (row->keys) { - int k; - XkbKeyPtr key; - xkbKeyWireDesc * keyWire; - keyWire= (xkbKeyWireDesc *)wire; - for (k=0,key=row->keys;knum_keys;k++,key++) { - memcpy(keyWire[k].name,key->name.name,XkbKeyNameLength); - keyWire[k].gap= key->gap; - keyWire[k].shapeNdx= key->shape_ndx; - keyWire[k].colorNdx= key->color_ndx; - if (swap) { - register int n; - swaps(&keyWire[k].gap,n); - } - } - wire= (char *)&keyWire[row->num_keys]; - } - } - } - if (section->doodads) { - wire= XkbWriteGeomDoodads(wire, - section->num_doodads,section->doodads, - swap); - } - if (section->overlays) { - register int o; - for (o=0;onum_overlays;o++) { - wire= XkbWriteGeomOverlay(wire,§ion->overlays[o],swap); - } - } - } - return wire; -} - -static Status -XkbComputeGetGeometryReplySize( XkbGeometryPtr geom, - xkbGetGeometryReply * rep, - Atom name) -{ -int len; - - if (geom!=NULL) { - len= XkbSizeCountedString(geom->label_font); - len+= XkbSizeGeomProperties(geom); - len+= XkbSizeGeomColors(geom); - len+= XkbSizeGeomShapes(geom); - len+= XkbSizeGeomSections(geom); - len+= XkbSizeGeomDoodads(geom->num_doodads,geom->doodads); - len+= XkbSizeGeomKeyAliases(geom); - rep->length= len/4; - rep->found= TRUE; - rep->name= geom->name; - rep->widthMM= geom->width_mm; - rep->heightMM= geom->height_mm; - rep->nProperties= geom->num_properties; - rep->nColors= geom->num_colors; - rep->nShapes= geom->num_shapes; - rep->nSections= geom->num_sections; - rep->nDoodads= geom->num_doodads; - rep->nKeyAliases= geom->num_key_aliases; - rep->baseColorNdx= XkbGeomColorIndex(geom,geom->base_color); - rep->labelColorNdx= XkbGeomColorIndex(geom,geom->label_color); - } - else { - rep->length= 0; - rep->found= FALSE; - rep->name= name; - rep->widthMM= rep->heightMM= 0; - rep->nProperties= rep->nColors= rep->nShapes= 0; - rep->nSections= rep->nDoodads= 0; - rep->nKeyAliases= 0; - rep->labelColorNdx= rep->baseColorNdx= 0; - } - return Success; -} - -static int -XkbSendGeometry( ClientPtr client, - XkbGeometryPtr geom, - xkbGetGeometryReply * rep, - Bool freeGeom) -{ - char *desc,*start; - int len; - - if (geom!=NULL) { - len= rep->length*4; - start= desc= malloc(len); - if (!start) - return BadAlloc; - desc= XkbWriteCountedString(desc,geom->label_font,client->swapped); - if ( rep->nProperties>0 ) - desc = XkbWriteGeomProperties(desc,geom,client->swapped); - if ( rep->nColors>0 ) - desc = XkbWriteGeomColors(desc,geom,client->swapped); - if ( rep->nShapes>0 ) - desc = XkbWriteGeomShapes(desc,geom,client->swapped); - if ( rep->nSections>0 ) - desc = XkbWriteGeomSections(desc,geom,client->swapped); - if ( rep->nDoodads>0 ) - desc = XkbWriteGeomDoodads(desc,geom->num_doodads,geom->doodads, - client->swapped); - if ( rep->nKeyAliases>0 ) - desc = XkbWriteGeomKeyAliases(desc,geom,client->swapped); - if ((desc-start)!=(len)) { - ErrorF("[xkb] BOGUS LENGTH in XkbSendGeometry, expected %d, got %ld\n", - len, (unsigned long)(desc-start)); - } - } - else { - len= 0; - start= NULL; - } - if (client->swapped) { - register int n; - swaps(&rep->sequenceNumber,n); - swapl(&rep->length,n); - swapl(&rep->name,n); - swaps(&rep->widthMM,n); - swaps(&rep->heightMM,n); - swaps(&rep->nProperties,n); - swaps(&rep->nColors,n); - swaps(&rep->nShapes,n); - swaps(&rep->nSections,n); - swaps(&rep->nDoodads,n); - swaps(&rep->nKeyAliases,n); - } - WriteToClient(client, SIZEOF(xkbGetGeometryReply), (char *)rep); - if (len>0) - WriteToClient(client, len, start); - if (start!=NULL) - free((char *)start); - if (freeGeom) - XkbFreeGeometry(geom,XkbGeomAllMask,TRUE); - return Success; -} - -int -ProcXkbGetGeometry(ClientPtr client) -{ - DeviceIntPtr dev; - xkbGetGeometryReply rep; - XkbGeometryPtr geom; - Bool shouldFree; - Status status; - - REQUEST(xkbGetGeometryReq); - REQUEST_SIZE_MATCH(xkbGetGeometryReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - CHK_ATOM_OR_NONE(stuff->name); - - geom= XkbLookupNamedGeometry(dev,stuff->name,&shouldFree); - rep.type= X_Reply; - rep.deviceID= dev->id; - rep.sequenceNumber= client->sequence; - rep.length= 0; - status= XkbComputeGetGeometryReplySize(geom,&rep,stuff->name); - if (status!=Success) - return status; - else return XkbSendGeometry(client,geom,&rep,shouldFree); -} - -/***====================================================================***/ - -static char * -_GetCountedString(char **wire_inout,Bool swap) -{ -char * wire,*str; -CARD16 len,*plen; - - wire= *wire_inout; - plen= (CARD16 *)wire; - if (swap) { - register int n; - swaps(plen,n); - } - len= *plen; - str= malloc(len+1); - if (str) { - memcpy(str,&wire[2],len); - str[len]= '\0'; - } - wire+= XkbPaddedSize(len+2); - *wire_inout= wire; - return str; -} - -static Status -_CheckSetDoodad( char ** wire_inout, - XkbGeometryPtr geom, - XkbSectionPtr section, - ClientPtr client) -{ -char * wire; -xkbDoodadWireDesc * dWire; -XkbDoodadPtr doodad; - - dWire= (xkbDoodadWireDesc *)(*wire_inout); - wire= (char *)&dWire[1]; - if (client->swapped) { - register int n; - swapl(&dWire->any.name,n); - swaps(&dWire->any.top,n); - swaps(&dWire->any.left,n); - swaps(&dWire->any.angle,n); - } - CHK_ATOM_ONLY(dWire->any.name); - doodad= XkbAddGeomDoodad(geom,section,dWire->any.name); - if (!doodad) - return BadAlloc; - doodad->any.type= dWire->any.type; - doodad->any.priority= dWire->any.priority; - doodad->any.top= dWire->any.top; - doodad->any.left= dWire->any.left; - doodad->any.angle= dWire->any.angle; - switch (doodad->any.type) { - case XkbOutlineDoodad: - case XkbSolidDoodad: - if (dWire->shape.colorNdx>=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x40,geom->num_colors, - dWire->shape.colorNdx); - return BadMatch; - } - if (dWire->shape.shapeNdx>=geom->num_shapes) { - client->errorValue= _XkbErrCode3(0x41,geom->num_shapes, - dWire->shape.shapeNdx); - return BadMatch; - } - doodad->shape.color_ndx= dWire->shape.colorNdx; - doodad->shape.shape_ndx= dWire->shape.shapeNdx; - break; - case XkbTextDoodad: - if (dWire->text.colorNdx>=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x42,geom->num_colors, - dWire->text.colorNdx); - return BadMatch; - } - if (client->swapped) { - register int n; - swaps(&dWire->text.width,n); - swaps(&dWire->text.height,n); - } - doodad->text.width= dWire->text.width; - doodad->text.height= dWire->text.height; - doodad->text.color_ndx= dWire->text.colorNdx; - doodad->text.text= _GetCountedString(&wire,client->swapped); - doodad->text.font= _GetCountedString(&wire,client->swapped); - break; - case XkbIndicatorDoodad: - if (dWire->indicator.onColorNdx>=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x43,geom->num_colors, - dWire->indicator.onColorNdx); - return BadMatch; - } - if (dWire->indicator.offColorNdx>=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x44,geom->num_colors, - dWire->indicator.offColorNdx); - return BadMatch; - } - if (dWire->indicator.shapeNdx>=geom->num_shapes) { - client->errorValue= _XkbErrCode3(0x45,geom->num_shapes, - dWire->indicator.shapeNdx); - return BadMatch; - } - doodad->indicator.shape_ndx= dWire->indicator.shapeNdx; - doodad->indicator.on_color_ndx= dWire->indicator.onColorNdx; - doodad->indicator.off_color_ndx= dWire->indicator.offColorNdx; - break; - case XkbLogoDoodad: - if (dWire->logo.colorNdx>=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x46,geom->num_colors, - dWire->logo.colorNdx); - return BadMatch; - } - if (dWire->logo.shapeNdx>=geom->num_shapes) { - client->errorValue= _XkbErrCode3(0x47,geom->num_shapes, - dWire->logo.shapeNdx); - return BadMatch; - } - doodad->logo.color_ndx= dWire->logo.colorNdx; - doodad->logo.shape_ndx= dWire->logo.shapeNdx; - doodad->logo.logo_name= _GetCountedString(&wire,client->swapped); - break; - default: - client->errorValue= _XkbErrCode2(0x4F,dWire->any.type); - return BadValue; - } - *wire_inout= wire; - return Success; -} - -static Status -_CheckSetOverlay( char ** wire_inout, - XkbGeometryPtr geom, - XkbSectionPtr section, - ClientPtr client) -{ -register int r; -char * wire; -XkbOverlayPtr ol; -xkbOverlayWireDesc * olWire; -xkbOverlayRowWireDesc * rWire; - - wire= *wire_inout; - olWire= (xkbOverlayWireDesc *)wire; - if (client->swapped) { - register int n; - swapl(&olWire->name,n); - } - CHK_ATOM_ONLY(olWire->name); - ol= XkbAddGeomOverlay(section,olWire->name,olWire->nRows); - rWire= (xkbOverlayRowWireDesc *)&olWire[1]; - for (r=0;rnRows;r++) { - register int k; - xkbOverlayKeyWireDesc * kWire; - XkbOverlayRowPtr row; - - if (rWire->rowUnder>section->num_rows) { - client->errorValue= _XkbErrCode4(0x20,r,section->num_rows, - rWire->rowUnder); - return BadMatch; - } - row= XkbAddGeomOverlayRow(ol,rWire->rowUnder,rWire->nKeys); - kWire= (xkbOverlayKeyWireDesc *)&rWire[1]; - for (k=0;knKeys;k++,kWire++) { - if (XkbAddGeomOverlayKey(ol,row, - (char *)kWire->over,(char *)kWire->under)==NULL) { - client->errorValue= _XkbErrCode3(0x21,r,k); - return BadMatch; - } - } - rWire= (xkbOverlayRowWireDesc *)kWire; - } - olWire= (xkbOverlayWireDesc *)rWire; - wire= (char *)olWire; - *wire_inout= wire; - return Success; -} - -static Status -_CheckSetSections( XkbGeometryPtr geom, - xkbSetGeometryReq * req, - char ** wire_inout, - ClientPtr client) -{ -Status status; -register int s; -char * wire; -xkbSectionWireDesc * sWire; -XkbSectionPtr section; - - wire= *wire_inout; - if (req->nSections<1) - return Success; - sWire= (xkbSectionWireDesc *)wire; - for (s=0;snSections;s++) { - register int r; - xkbRowWireDesc * rWire; - if (client->swapped) { - register int n; - swapl(&sWire->name,n); - swaps(&sWire->top,n); - swaps(&sWire->left,n); - swaps(&sWire->width,n); - swaps(&sWire->height,n); - swaps(&sWire->angle,n); - } - CHK_ATOM_ONLY(sWire->name); - section= XkbAddGeomSection(geom,sWire->name,sWire->nRows, - sWire->nDoodads,sWire->nOverlays); - if (!section) - return BadAlloc; - section->priority= sWire->priority; - section->top= sWire->top; - section->left= sWire->left; - section->width= sWire->width; - section->height= sWire->height; - section->angle= sWire->angle; - rWire= (xkbRowWireDesc *)&sWire[1]; - for (r=0;rnRows;r++) { - register int k; - XkbRowPtr row; - xkbKeyWireDesc * kWire; - if (client->swapped) { - register int n; - swaps(&rWire->top,n); - swaps(&rWire->left,n); - } - row= XkbAddGeomRow(section,rWire->nKeys); - if (!row) - return BadAlloc; - row->top= rWire->top; - row->left= rWire->left; - row->vertical= rWire->vertical; - kWire= (xkbKeyWireDesc *)&rWire[1]; - for (k=0;knKeys;k++) { - XkbKeyPtr key; - key= XkbAddGeomKey(row); - if (!key) - return BadAlloc; - memcpy(key->name.name,kWire[k].name,XkbKeyNameLength); - key->gap= kWire[k].gap; - key->shape_ndx= kWire[k].shapeNdx; - key->color_ndx= kWire[k].colorNdx; - if (key->shape_ndx>=geom->num_shapes) { - client->errorValue= _XkbErrCode3(0x10,key->shape_ndx, - geom->num_shapes); - return BadMatch; - } - if (key->color_ndx>=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x11,key->color_ndx, - geom->num_colors); - return BadMatch; - } - } - rWire= (xkbRowWireDesc *)&kWire[rWire->nKeys]; - } - wire= (char *)rWire; - if (sWire->nDoodads>0) { - register int d; - for (d=0;dnDoodads;d++) { - status=_CheckSetDoodad(&wire,geom,section,client); - if (status!=Success) - return status; - } - } - if (sWire->nOverlays>0) { - register int o; - for (o=0;onOverlays;o++) { - status= _CheckSetOverlay(&wire,geom,section,client); - if (status!=Success) - return status; - } - } - sWire= (xkbSectionWireDesc *)wire; - } - wire= (char *)sWire; - *wire_inout= wire; - return Success; -} - -static Status -_CheckSetShapes( XkbGeometryPtr geom, - xkbSetGeometryReq * req, - char ** wire_inout, - ClientPtr client) -{ -register int i; -char * wire; - - wire= *wire_inout; - if (req->nShapes<1) { - client->errorValue= _XkbErrCode2(0x06,req->nShapes); - return BadValue; - } - else { - xkbShapeWireDesc * shapeWire; - XkbShapePtr shape; - register int o; - shapeWire= (xkbShapeWireDesc *)wire; - for (i=0;inShapes;i++) { - xkbOutlineWireDesc * olWire; - XkbOutlinePtr ol; - shape= XkbAddGeomShape(geom,shapeWire->name,shapeWire->nOutlines); - if (!shape) - return BadAlloc; - olWire= (xkbOutlineWireDesc *)(&shapeWire[1]); - for (o=0;onOutlines;o++) { - register int p; - XkbPointPtr pt; - xkbPointWireDesc * ptWire; - - ol= XkbAddGeomOutline(shape,olWire->nPoints); - if (!ol) - return BadAlloc; - ol->corner_radius= olWire->cornerRadius; - ptWire= (xkbPointWireDesc *)&olWire[1]; - for (p=0,pt=ol->points;pnPoints;p++,pt++) { - pt->x= ptWire[p].x; - pt->y= ptWire[p].y; - if (client->swapped) { - register int n; - swaps(&pt->x,n); - swaps(&pt->y,n); - } - } - ol->num_points= olWire->nPoints; - olWire= (xkbOutlineWireDesc *)(&ptWire[olWire->nPoints]); - } - if (shapeWire->primaryNdx!=XkbNoShape) - shape->primary= &shape->outlines[shapeWire->primaryNdx]; - if (shapeWire->approxNdx!=XkbNoShape) - shape->approx= &shape->outlines[shapeWire->approxNdx]; - shapeWire= (xkbShapeWireDesc *)olWire; - } - wire= (char *)shapeWire; - } - if (geom->num_shapes!=req->nShapes) { - client->errorValue= _XkbErrCode3(0x07,geom->num_shapes,req->nShapes); - return BadMatch; - } - - *wire_inout= wire; - return Success; -} - -static Status -_CheckSetGeom( XkbGeometryPtr geom, - xkbSetGeometryReq * req, - ClientPtr client) -{ -register int i; -Status status; -char * wire; - - wire= (char *)&req[1]; - geom->label_font= _GetCountedString(&wire,client->swapped); - - for (i=0;inProperties;i++) { - char *name,*val; - name= _GetCountedString(&wire,client->swapped); - if (!name) - return BadAlloc; - val= _GetCountedString(&wire,client->swapped); - if (!val) { - free(name); - return BadAlloc; - } - if (XkbAddGeomProperty(geom,name,val)==NULL) { - free(name); - free(val); - return BadAlloc; - } - free(name); - free(val); - } - - if (req->nColors<2) { - client->errorValue= _XkbErrCode3(0x01,2,req->nColors); - return BadValue; - } - if (req->baseColorNdx>req->nColors) { - client->errorValue=_XkbErrCode3(0x03,req->nColors,req->baseColorNdx); - return BadMatch; - } - if (req->labelColorNdx>req->nColors) { - client->errorValue= _XkbErrCode3(0x03,req->nColors,req->labelColorNdx); - return BadMatch; - } - if (req->labelColorNdx==req->baseColorNdx) { - client->errorValue= _XkbErrCode3(0x04,req->baseColorNdx, - req->labelColorNdx); - return BadMatch; - } - - for (i=0;inColors;i++) { - char *name; - name= _GetCountedString(&wire,client->swapped); - if (!name) - return BadAlloc; - if (!XkbAddGeomColor(geom,name,geom->num_colors)) { - free(name); - return BadAlloc; - } - free(name); - } - if (req->nColors!=geom->num_colors) { - client->errorValue= _XkbErrCode3(0x05,req->nColors,geom->num_colors); - return BadMatch; - } - geom->label_color= &geom->colors[req->labelColorNdx]; - geom->base_color= &geom->colors[req->baseColorNdx]; - - if ((status=_CheckSetShapes(geom,req,&wire,client))!=Success) - return status; - - if ((status=_CheckSetSections(geom,req,&wire,client))!=Success) - return status; - - for (i=0;inDoodads;i++) { - status=_CheckSetDoodad(&wire,geom,NULL,client); - if (status!=Success) - return status; - } - - for (i=0;inKeyAliases;i++) { - if (XkbAddGeomKeyAlias(geom,&wire[XkbKeyNameLength],wire)==NULL) - return BadAlloc; - wire+= 2*XkbKeyNameLength; - } - return Success; -} - -static int -_XkbSetGeometry(ClientPtr client, DeviceIntPtr dev, xkbSetGeometryReq *stuff) -{ - XkbDescPtr xkb; - Bool new_name; - xkbNewKeyboardNotify nkn; - XkbGeometryPtr geom,old; - XkbGeometrySizesRec sizes; - Status status; - - xkb= dev->key->xkbInfo->desc; - old= xkb->geom; - xkb->geom= NULL; - - sizes.which= XkbGeomAllMask; - sizes.num_properties= stuff->nProperties; - sizes.num_colors= stuff->nColors; - sizes.num_shapes= stuff->nShapes; - sizes.num_sections= stuff->nSections; - sizes.num_doodads= stuff->nDoodads; - sizes.num_key_aliases= stuff->nKeyAliases; - if ((status= XkbAllocGeometry(xkb,&sizes))!=Success) { - xkb->geom= old; - return status; - } - geom= xkb->geom; - geom->name= stuff->name; - geom->width_mm= stuff->widthMM; - geom->height_mm= stuff->heightMM; - if ((status= _CheckSetGeom(geom,stuff,client))!=Success) { - XkbFreeGeometry(geom,XkbGeomAllMask,TRUE); - xkb->geom= old; - return status; - } - new_name= (xkb->names->geometry!=geom->name); - xkb->names->geometry= geom->name; - if (old) - XkbFreeGeometry(old,XkbGeomAllMask,TRUE); - if (new_name) { - xkbNamesNotify nn; - memset(&nn, 0, sizeof(xkbNamesNotify)); - nn.changed= XkbGeometryNameMask; - XkbSendNamesNotify(dev,&nn); - } - nkn.deviceID= nkn.oldDeviceID= dev->id; - nkn.minKeyCode= nkn.oldMinKeyCode= xkb->min_key_code; - nkn.maxKeyCode= nkn.oldMaxKeyCode= xkb->max_key_code; - nkn.requestMajor= XkbReqCode; - nkn.requestMinor= X_kbSetGeometry; - nkn.changed= XkbNKN_GeometryMask; - XkbSendNewKeyboardNotify(dev,&nkn); - return Success; -} - -int -ProcXkbSetGeometry(ClientPtr client) -{ - DeviceIntPtr dev; - int rc; - - REQUEST(xkbSetGeometryReq); - REQUEST_AT_LEAST_SIZE(xkbSetGeometryReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); - CHK_ATOM_OR_NONE(stuff->name); - - rc = _XkbSetGeometry(client, dev, stuff); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - _XkbSetGeometry(client, other, stuff); - } - } - } - - return Success; -} - -/***====================================================================***/ - -int -ProcXkbPerClientFlags(ClientPtr client) -{ - DeviceIntPtr dev; - xkbPerClientFlagsReply rep; - XkbInterestPtr interest; - Mask access_mode = DixGetAttrAccess | DixSetAttrAccess; - - REQUEST(xkbPerClientFlagsReq); - REQUEST_SIZE_MATCH(xkbPerClientFlagsReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, access_mode); - CHK_MASK_LEGAL(0x01,stuff->change,XkbPCF_AllFlagsMask); - CHK_MASK_MATCH(0x02,stuff->change,stuff->value); - - interest = XkbFindClientResource((DevicePtr)dev,client); - memset(&rep, 0, sizeof(xkbPerClientFlagsReply)); - rep.type= X_Reply; - rep.length = 0; - rep.sequenceNumber = client->sequence; - if (stuff->change) { - client->xkbClientFlags&= ~stuff->change; - client->xkbClientFlags|= stuff->value; - } - if (stuff->change&XkbPCF_AutoResetControlsMask) { - Bool want; - want= stuff->value&XkbPCF_AutoResetControlsMask; - if (interest && !want) { - interest->autoCtrls= interest->autoCtrlValues= 0; - } - else if (want && (!interest)) { - XID id = FakeClientID(client->index); - if (!AddResource(id,RT_XKBCLIENT,dev)) - return BadAlloc; - interest= XkbAddClientResource((DevicePtr)dev,client,id); - if (!interest) - return BadAlloc; - } - if (interest && want ) { - register unsigned affect; - affect= stuff->ctrlsToChange; - - CHK_MASK_LEGAL(0x03,affect,XkbAllBooleanCtrlsMask); - CHK_MASK_MATCH(0x04,affect,stuff->autoCtrls); - CHK_MASK_MATCH(0x05,stuff->autoCtrls,stuff->autoCtrlValues); - - interest->autoCtrls&= ~affect; - interest->autoCtrlValues&= ~affect; - interest->autoCtrls|= stuff->autoCtrls&affect; - interest->autoCtrlValues|= stuff->autoCtrlValues&affect; - } - } - rep.supported = XkbPCF_AllFlagsMask; - rep.value= client->xkbClientFlags&XkbPCF_AllFlagsMask; - if (interest) { - rep.autoCtrls= interest->autoCtrls; - rep.autoCtrlValues= interest->autoCtrlValues; - } - else { - rep.autoCtrls= rep.autoCtrlValues= 0; - } - if ( client->swapped ) { - register int n; - swaps(&rep.sequenceNumber, n); - swapl(&rep.supported,n); - swapl(&rep.value,n); - swapl(&rep.autoCtrls,n); - swapl(&rep.autoCtrlValues,n); - } - WriteToClient(client,SIZEOF(xkbPerClientFlagsReply), (char *)&rep); - return Success; -} - -/***====================================================================***/ - -/* all latin-1 alphanumerics, plus parens, minus, underscore, slash */ -/* and wildcards */ -static unsigned char componentSpecLegal[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0xa7, 0xff, 0x87, - 0xfe, 0xff, 0xff, 0x87, 0xfe, 0xff, 0xff, 0x07, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x7f, 0xff -}; - -/* same as above but accepts percent, plus and bar too */ -static unsigned char componentExprLegal[] = { - 0x00, 0x00, 0x00, 0x00, 0x20, 0xaf, 0xff, 0x87, - 0xfe, 0xff, 0xff, 0x87, 0xfe, 0xff, 0xff, 0x17, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x7f, 0xff -}; - -static char * -GetComponentSpec(unsigned char **pWire,Bool allowExpr,int *errRtrn) -{ -int len; -register int i; -unsigned char *wire,*str,*tmp,*legal; - - if (allowExpr) legal= &componentExprLegal[0]; - else legal= &componentSpecLegal[0]; - - wire= *pWire; - len= (*(unsigned char *)wire++); - if (len>0) { - str= calloc(1, len+1); - if (str) { - tmp= str; - for (i=0;ixkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - - status= Success; - str= (unsigned char *)&stuff[1]; - memset(&list, 0, sizeof(XkbSrvListInfoRec)); - list.maxRtrn= stuff->maxNames; - list.pattern[_XkbListKeycodes]= GetComponentSpec(&str,FALSE,&status); - list.pattern[_XkbListTypes]= GetComponentSpec(&str,FALSE,&status); - list.pattern[_XkbListCompat]= GetComponentSpec(&str,FALSE,&status); - list.pattern[_XkbListSymbols]= GetComponentSpec(&str,FALSE,&status); - list.pattern[_XkbListGeometry]= GetComponentSpec(&str,FALSE,&status); - if (status!=Success) - return status; - len= str-((unsigned char *)stuff); - if ((XkbPaddedSize(len)/4)!=stuff->length) - return BadLength; - if ((status=XkbDDXList(dev,&list,client))!=Success) { - free(list.pool); - list.pool = NULL; - return status; - } - memset(&rep, 0, sizeof(xkbListComponentsReply)); - rep.type= X_Reply; - rep.deviceID = dev->id; - rep.sequenceNumber = client->sequence; - rep.length = XkbPaddedSize(list.nPool)/4; - rep.nKeymaps = 0; - rep.nKeycodes = list.nFound[_XkbListKeycodes]; - rep.nTypes = list.nFound[_XkbListTypes]; - rep.nCompatMaps = list.nFound[_XkbListCompat]; - rep.nSymbols = list.nFound[_XkbListSymbols]; - rep.nGeometries = list.nFound[_XkbListGeometry]; - rep.extra= 0; - if (list.nTotal>list.maxRtrn) - rep.extra = (list.nTotal-list.maxRtrn); - if (client->swapped) { - register int n; - swaps(&rep.sequenceNumber,n); - swapl(&rep.length,n); - swaps(&rep.nKeymaps,n); - swaps(&rep.nKeycodes,n); - swaps(&rep.nTypes,n); - swaps(&rep.nCompatMaps,n); - swaps(&rep.nSymbols,n); - swaps(&rep.nGeometries,n); - swaps(&rep.extra,n); - } - WriteToClient(client,SIZEOF(xkbListComponentsReply),(char *)&rep); - if (list.nPool && list.pool) { - WriteToClient(client,XkbPaddedSize(list.nPool), (char *)list.pool); - free(list.pool); - list.pool= NULL; - } - return Success; -} - -/***====================================================================***/ - -int -ProcXkbGetKbdByName(ClientPtr client) -{ - DeviceIntPtr dev; - DeviceIntPtr tmpd; - xkbGetKbdByNameReply rep; - xkbGetMapReply mrep; - xkbGetCompatMapReply crep; - xkbGetIndicatorMapReply irep; - xkbGetNamesReply nrep; - xkbGetGeometryReply grep; - XkbComponentNamesRec names; - XkbDescPtr xkb, new; - unsigned char * str; - char mapFile[PATH_MAX]; - unsigned len; - unsigned fwant,fneed,reported; - int status; - Bool geom_changed; - XkbSrvLedInfoPtr old_sli; - XkbSrvLedInfoPtr sli; - Mask access_mode = DixGetAttrAccess | DixManageAccess; - - REQUEST(xkbGetKbdByNameReq); - REQUEST_AT_LEAST_SIZE(xkbGetKbdByNameReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, access_mode); - - xkb = dev->key->xkbInfo->desc; - status= Success; - str= (unsigned char *)&stuff[1]; - if (GetComponentSpec(&str,TRUE,&status)) /* keymap, unsupported */ - return BadMatch; - names.keycodes= GetComponentSpec(&str,TRUE,&status); - names.types= GetComponentSpec(&str,TRUE,&status); - names.compat= GetComponentSpec(&str,TRUE,&status); - names.symbols= GetComponentSpec(&str,TRUE,&status); - names.geometry= GetComponentSpec(&str,TRUE,&status); - if (status!=Success) - return status; - len= str-((unsigned char *)stuff); - if ((XkbPaddedSize(len)/4)!=stuff->length) - return BadLength; - - CHK_MASK_LEGAL(0x01,stuff->want,XkbGBN_AllComponentsMask); - CHK_MASK_LEGAL(0x02,stuff->need,XkbGBN_AllComponentsMask); - - if (stuff->load) - fwant= XkbGBN_AllComponentsMask; - else fwant= stuff->want|stuff->need; - if ((!names.compat)&& - (fwant&(XkbGBN_CompatMapMask|XkbGBN_IndicatorMapMask))) { - names.compat= _XkbDupString("%"); - } - if ((!names.types)&&(fwant&(XkbGBN_TypesMask))) { - names.types= _XkbDupString("%"); - } - if ((!names.symbols)&&(fwant&XkbGBN_SymbolsMask)) { - names.symbols= _XkbDupString("%"); - } - geom_changed= ((names.geometry!=NULL)&&(strcmp(names.geometry,"%")!=0)); - if ((!names.geometry)&&(fwant&XkbGBN_GeometryMask)) { - names.geometry= _XkbDupString("%"); - geom_changed= FALSE; - } - - memset(mapFile, 0, PATH_MAX); - rep.type= X_Reply; - rep.deviceID = dev->id; - rep.sequenceNumber = client->sequence; - rep.length = 0; - rep.minKeyCode = xkb->min_key_code; - rep.maxKeyCode = xkb->max_key_code; - rep.loaded= FALSE; - fwant= XkbConvertGetByNameComponents(TRUE,stuff->want)|XkmVirtualModsMask; - fneed= XkbConvertGetByNameComponents(TRUE,stuff->need); - rep.reported= XkbConvertGetByNameComponents(FALSE,fwant|fneed); - if (stuff->load) { - fneed|= XkmKeymapRequired; - fwant|= XkmKeymapLegal; - } - if ((fwant|fneed)&XkmSymbolsMask) { - fneed|= XkmKeyNamesIndex|XkmTypesIndex; - fwant|= XkmIndicatorsIndex; - } - - /* We pass dev in here so we can get the old names out if needed. */ - rep.found = XkbDDXLoadKeymapByNames(dev,&names,fwant,fneed,&new, - mapFile,PATH_MAX); - rep.newKeyboard= FALSE; - rep.pad1= rep.pad2= rep.pad3= rep.pad4= 0; - - stuff->want|= stuff->need; - if (new==NULL) - rep.reported= 0; - else { - if (stuff->load) - rep.loaded= TRUE; - if (stuff->load || - ((rep.reported&XkbGBN_SymbolsMask) && (new->compat))) { - XkbChangesRec changes; - memset(&changes, 0, sizeof(changes)); - XkbUpdateDescActions(new, - new->min_key_code,XkbNumKeys(new), - &changes); - } - - if (new->map==NULL) - rep.reported&= ~(XkbGBN_SymbolsMask|XkbGBN_TypesMask); - else if (rep.reported&(XkbGBN_SymbolsMask|XkbGBN_TypesMask)) { - mrep.type= X_Reply; - mrep.deviceID = dev->id; - mrep.sequenceNumber= client->sequence; - mrep.length = ((SIZEOF(xkbGetMapReply)-SIZEOF(xGenericReply))>>2); - mrep.minKeyCode = new->min_key_code; - mrep.maxKeyCode = new->max_key_code; - mrep.present = 0; - mrep.totalSyms = mrep.totalActs = - mrep.totalKeyBehaviors= mrep.totalKeyExplicit= - mrep.totalModMapKeys= mrep.totalVModMapKeys= 0; - if (rep.reported&(XkbGBN_TypesMask|XkbGBN_ClientSymbolsMask)) { - mrep.present|= XkbKeyTypesMask; - mrep.firstType = 0; - mrep.nTypes = mrep.totalTypes= new->map->num_types; - } - else { - mrep.firstType = mrep.nTypes= 0; - mrep.totalTypes= 0; - } - if (rep.reported&XkbGBN_ClientSymbolsMask) { - mrep.present|= (XkbKeySymsMask|XkbModifierMapMask); - mrep.firstKeySym = mrep.firstModMapKey= new->min_key_code; - mrep.nKeySyms = mrep.nModMapKeys= XkbNumKeys(new); - } - else { - mrep.firstKeySym= mrep.firstModMapKey= 0; - mrep.nKeySyms= mrep.nModMapKeys= 0; - } - if (rep.reported&XkbGBN_ServerSymbolsMask) { - mrep.present|= XkbAllServerInfoMask; - mrep.virtualMods= ~0; - mrep.firstKeyAct = mrep.firstKeyBehavior = - mrep.firstKeyExplicit = new->min_key_code; - mrep.nKeyActs = mrep.nKeyBehaviors = - mrep.nKeyExplicit = XkbNumKeys(new); - mrep.firstVModMapKey= new->min_key_code; - mrep.nVModMapKeys= XkbNumKeys(new); - } - else { - mrep.virtualMods= 0; - mrep.firstKeyAct= mrep.firstKeyBehavior= - mrep.firstKeyExplicit = 0; - mrep.nKeyActs= mrep.nKeyBehaviors= mrep.nKeyExplicit= 0; - } - XkbComputeGetMapReplySize(new,&mrep); - rep.length+= SIZEOF(xGenericReply)/4+mrep.length; - } - if (new->compat==NULL) - rep.reported&= ~XkbGBN_CompatMapMask; - else if (rep.reported&XkbGBN_CompatMapMask) { - crep.type= X_Reply; - crep.deviceID= dev->id; - crep.sequenceNumber= client->sequence; - crep.length= 0; - crep.groups= XkbAllGroupsMask; - crep.firstSI= 0; - crep.nSI= crep.nTotalSI= new->compat->num_si; - XkbComputeGetCompatMapReplySize(new->compat,&crep); - rep.length+= SIZEOF(xGenericReply)/4+crep.length; - } - if (new->indicators==NULL) - rep.reported&= ~XkbGBN_IndicatorMapMask; - else if (rep.reported&XkbGBN_IndicatorMapMask) { - irep.type= X_Reply; - irep.deviceID= dev->id; - irep.sequenceNumber= client->sequence; - irep.length= 0; - irep.which= XkbAllIndicatorsMask; - XkbComputeGetIndicatorMapReplySize(new->indicators,&irep); - rep.length+= SIZEOF(xGenericReply)/4+irep.length; - } - if (new->names==NULL) - rep.reported&= ~(XkbGBN_OtherNamesMask|XkbGBN_KeyNamesMask); - else if (rep.reported&(XkbGBN_OtherNamesMask|XkbGBN_KeyNamesMask)) { - nrep.type= X_Reply; - nrep.deviceID= dev->id; - nrep.sequenceNumber= client->sequence; - nrep.length= 0; - nrep.minKeyCode= new->min_key_code; - nrep.maxKeyCode= new->max_key_code; - if (rep.reported&XkbGBN_OtherNamesMask) { - nrep.which= XkbAllNamesMask; - if (new->map!=NULL) - nrep.nTypes= new->map->num_types; - else nrep.nTypes= 0; - nrep.nKTLevels= 0; - nrep.groupNames= XkbAllGroupsMask; - nrep.virtualMods= XkbAllVirtualModsMask; - nrep.indicators= XkbAllIndicatorsMask; - nrep.nRadioGroups= new->names->num_rg; - } - else { - nrep.which= 0; - nrep.nTypes= 0; - nrep.nKTLevels= 0; - nrep.groupNames= 0; - nrep.virtualMods= 0; - nrep.indicators= 0; - nrep.nRadioGroups= 0; - } - if (rep.reported&XkbGBN_KeyNamesMask) { - nrep.which|= XkbKeyNamesMask; - nrep.firstKey= new->min_key_code; - nrep.nKeys= XkbNumKeys(new); - nrep.nKeyAliases= new->names->num_key_aliases; - if (nrep.nKeyAliases) - nrep.which|= XkbKeyAliasesMask; - } - else { - nrep.which&= ~(XkbKeyNamesMask|XkbKeyAliasesMask); - nrep.firstKey= nrep.nKeys= 0; - nrep.nKeyAliases= 0; - } - XkbComputeGetNamesReplySize(new,&nrep); - rep.length+= SIZEOF(xGenericReply)/4+nrep.length; - } - if (new->geom==NULL) - rep.reported&= ~XkbGBN_GeometryMask; - else if (rep.reported&XkbGBN_GeometryMask) { - grep.type= X_Reply; - grep.deviceID= dev->id; - grep.sequenceNumber= client->sequence; - grep.length= 0; - grep.found= TRUE; - grep.pad= 0; - grep.widthMM= grep.heightMM= 0; - grep.nProperties= grep.nColors= grep.nShapes= 0; - grep.nSections= grep.nDoodads= 0; - grep.baseColorNdx= grep.labelColorNdx= 0; - XkbComputeGetGeometryReplySize(new->geom,&grep,None); - rep.length+= SIZEOF(xGenericReply)/4+grep.length; - } - } - - reported= rep.reported; - if ( client->swapped ) { - register int n; - swaps(&rep.sequenceNumber,n); - swapl(&rep.length,n); - swaps(&rep.found,n); - swaps(&rep.reported,n); - } - WriteToClient(client,SIZEOF(xkbGetKbdByNameReply), (char *)&rep); - if (reported&(XkbGBN_SymbolsMask|XkbGBN_TypesMask)) - XkbSendMap(client,new,&mrep); - if (reported&XkbGBN_CompatMapMask) - XkbSendCompatMap(client,new->compat,&crep); - if (reported&XkbGBN_IndicatorMapMask) - XkbSendIndicatorMap(client,new->indicators,&irep); - if (reported&(XkbGBN_KeyNamesMask|XkbGBN_OtherNamesMask)) - XkbSendNames(client,new,&nrep); - if (reported&XkbGBN_GeometryMask) - XkbSendGeometry(client,new->geom,&grep,FALSE); - if (rep.loaded) { - XkbDescPtr old_xkb; - xkbNewKeyboardNotify nkn; - int i,nG,nTG; - old_xkb= xkb; - xkb= new; - dev->key->xkbInfo->desc= xkb; - new= old_xkb; /* so it'll get freed automatically */ - - *xkb->ctrls= *old_xkb->ctrls; - for (nG=nTG=0,i=xkb->min_key_code;i<=xkb->max_key_code;i++) { - nG= XkbKeyNumGroups(xkb,i); - if (nG>=XkbNumKbdGroups) { - nTG= XkbNumKbdGroups; - break; - } - if (nG>nTG) { - nTG= nG; - } - } - xkb->ctrls->num_groups= nTG; - - for (tmpd = inputInfo.devices; tmpd; tmpd = tmpd->next) { - if ((tmpd == dev) || (!IsMaster(tmpd) && GetMaster(tmpd, MASTER_KEYBOARD) == dev)) { - if (tmpd != dev) - XkbCopyDeviceKeymap(tmpd, dev); - - if (tmpd->kbdfeed && tmpd->kbdfeed->xkb_sli) { - old_sli = tmpd->kbdfeed->xkb_sli; - tmpd->kbdfeed->xkb_sli = NULL; - sli = XkbAllocSrvLedInfo(tmpd, tmpd->kbdfeed, NULL, 0); - if (sli) { - sli->explicitState = old_sli->explicitState; - sli->effectiveState = old_sli->effectiveState; - } - tmpd->kbdfeed->xkb_sli = sli; - XkbFreeSrvLedInfo(old_sli); - } - } - } - - nkn.deviceID= nkn.oldDeviceID= dev->id; - nkn.minKeyCode= new->min_key_code; - nkn.maxKeyCode= new->max_key_code; - nkn.oldMinKeyCode= xkb->min_key_code; - nkn.oldMaxKeyCode= xkb->max_key_code; - nkn.requestMajor= XkbReqCode; - nkn.requestMinor= X_kbGetKbdByName; - nkn.changed= XkbNKN_KeycodesMask; - if (geom_changed) - nkn.changed|= XkbNKN_GeometryMask; - XkbSendNewKeyboardNotify(dev,&nkn); - - if (!IsMaster(dev) && dev->u.master) - { - DeviceIntPtr master = dev->u.master; - if (master->u.lastSlave == dev) - { - XkbCopyDeviceKeymap(dev->u.master, dev); - XkbSendNewKeyboardNotify(dev,&nkn); - } - } - } - if ((new!=NULL)&&(new!=xkb)) { - XkbFreeKeyboard(new,XkbAllComponentsMask,TRUE); - new= NULL; - } - free(names.keycodes); - names.keycodes = NULL; - free(names.types); - names.types = NULL; - free(names.compat); - names.compat = NULL; - free(names.symbols); - names.symbols = NULL; - free(names.geometry); - names.geometry = NULL; - return Success; -} - -/***====================================================================***/ - -static int -ComputeDeviceLedInfoSize( DeviceIntPtr dev, - unsigned int what, - XkbSrvLedInfoPtr sli) -{ -int nNames,nMaps; -register unsigned n,bit; - - if (sli==NULL) - return 0; - nNames= nMaps= 0; - if ((what&XkbXI_IndicatorNamesMask)==0) - sli->namesPresent= 0; - if ((what&XkbXI_IndicatorMapsMask)==0) - sli->mapsPresent= 0; - - for (n=0,bit=1;nnames && sli->names[n]!=None) { - sli->namesPresent|= bit; - nNames++; - } - if (sli->maps && XkbIM_InUse(&sli->maps[n])) { - sli->mapsPresent|= bit; - nMaps++; - } - } - return (nNames*4)+(nMaps*SIZEOF(xkbIndicatorMapWireDesc)); -} - -static int -CheckDeviceLedFBs( DeviceIntPtr dev, - int class, - int id, - xkbGetDeviceInfoReply * rep, - ClientPtr client) -{ -int nFBs= 0; -int length= 0; -Bool classOk; - - if (class==XkbDfltXIClass) { - if (dev->kbdfeed) class= KbdFeedbackClass; - else if (dev->leds) class= LedFeedbackClass; - else { - client->errorValue= _XkbErrCode2(XkbErr_BadClass,class); - return XkbKeyboardErrorCode; - } - } - classOk= FALSE; - if ((dev->kbdfeed)&&((class==KbdFeedbackClass)||(class==XkbAllXIClasses))) { - KbdFeedbackPtr kf; - classOk= TRUE; - for (kf= dev->kbdfeed;(kf);kf=kf->next) { - if ((id!=XkbAllXIIds)&&(id!=XkbDfltXIId)&&(id!=kf->ctrl.id)) - continue; - nFBs++; - length+= SIZEOF(xkbDeviceLedsWireDesc); - if (!kf->xkb_sli) - kf->xkb_sli= XkbAllocSrvLedInfo(dev,kf,NULL,0); - length+= ComputeDeviceLedInfoSize(dev,rep->present,kf->xkb_sli); - if (id!=XkbAllXIIds) - break; - } - } - if ((dev->leds)&&((class==LedFeedbackClass)||(class==XkbAllXIClasses))) { - LedFeedbackPtr lf; - classOk= TRUE; - for (lf= dev->leds;(lf);lf=lf->next) { - if ((id!=XkbAllXIIds)&&(id!=XkbDfltXIId)&&(id!=lf->ctrl.id)) - continue; - nFBs++; - length+= SIZEOF(xkbDeviceLedsWireDesc); - if (!lf->xkb_sli) - lf->xkb_sli= XkbAllocSrvLedInfo(dev,NULL,lf,0); - length+= ComputeDeviceLedInfoSize(dev,rep->present,lf->xkb_sli); - if (id!=XkbAllXIIds) - break; - } - } - if (nFBs>0) { - rep->nDeviceLedFBs= nFBs; - rep->length+= (length/4); - return Success; - } - if (classOk) client->errorValue= _XkbErrCode2(XkbErr_BadId,id); - else client->errorValue= _XkbErrCode2(XkbErr_BadClass,class); - return XkbKeyboardErrorCode; -} - -static int -SendDeviceLedInfo( XkbSrvLedInfoPtr sli, - ClientPtr client) -{ -xkbDeviceLedsWireDesc wire; -int length; - - length= 0; - wire.ledClass= sli->class; - wire.ledID= sli->id; - wire.namesPresent= sli->namesPresent; - wire.mapsPresent= sli->mapsPresent; - wire.physIndicators= sli->physIndicators; - wire.state= sli->effectiveState; - if (client->swapped) { - register int n; - swaps(&wire.ledClass,n); - swaps(&wire.ledID,n); - swapl(&wire.namesPresent,n); - swapl(&wire.mapsPresent,n); - swapl(&wire.physIndicators,n); - swapl(&wire.state,n); - } - WriteToClient(client,SIZEOF(xkbDeviceLedsWireDesc),(char *)&wire); - length+= SIZEOF(xkbDeviceLedsWireDesc); - if (sli->namesPresent|sli->mapsPresent) { - register unsigned i,bit; - if (sli->namesPresent) { - CARD32 awire; - for (i=0,bit=1;inamesPresent&bit) { - awire= (CARD32)sli->names[i]; - if (client->swapped) { - register int n; - swapl(&awire,n); - } - WriteToClient(client,4,(char *)&awire); - length+= 4; - } - } - } - if (sli->mapsPresent) { - for (i=0,bit=1;imapsPresent&bit) { - iwire.flags= sli->maps[i].flags; - iwire.whichGroups= sli->maps[i].which_groups; - iwire.groups= sli->maps[i].groups; - iwire.whichMods= sli->maps[i].which_mods; - iwire.mods= sli->maps[i].mods.mask; - iwire.realMods= sli->maps[i].mods.real_mods; - iwire.virtualMods= sli->maps[i].mods.vmods; - iwire.ctrls= sli->maps[i].ctrls; - if (client->swapped) { - register int n; - swaps(&iwire.virtualMods,n); - swapl(&iwire.ctrls,n); - } - WriteToClient(client,SIZEOF(xkbIndicatorMapWireDesc), - (char *)&iwire); - length+= SIZEOF(xkbIndicatorMapWireDesc); - } - } - } - } - return length; -} - -static int -SendDeviceLedFBs( DeviceIntPtr dev, - int class, - int id, - unsigned wantLength, - ClientPtr client) -{ -int length= 0; - - if (class==XkbDfltXIClass) { - if (dev->kbdfeed) class= KbdFeedbackClass; - else if (dev->leds) class= LedFeedbackClass; - } - if ((dev->kbdfeed)&& - ((class==KbdFeedbackClass)||(class==XkbAllXIClasses))) { - KbdFeedbackPtr kf; - for (kf= dev->kbdfeed;(kf);kf=kf->next) { - if ((id==XkbAllXIIds)||(id==XkbDfltXIId)||(id==kf->ctrl.id)) { - length+= SendDeviceLedInfo(kf->xkb_sli,client); - if (id!=XkbAllXIIds) - break; - } - } - } - if ((dev->leds)&& - ((class==LedFeedbackClass)||(class==XkbAllXIClasses))) { - LedFeedbackPtr lf; - for (lf= dev->leds;(lf);lf=lf->next) { - if ((id==XkbAllXIIds)||(id==XkbDfltXIId)||(id==lf->ctrl.id)) { - length+= SendDeviceLedInfo(lf->xkb_sli,client); - if (id!=XkbAllXIIds) - break; - } - } - } - if (length==wantLength) - return Success; - else return BadLength; -} - -int -ProcXkbGetDeviceInfo(ClientPtr client) -{ -DeviceIntPtr dev; -xkbGetDeviceInfoReply rep; -int status,nDeviceLedFBs; -unsigned length,nameLen; -CARD16 ledClass,ledID; -unsigned wanted; -char * str; - - REQUEST(xkbGetDeviceInfoReq); - REQUEST_SIZE_MATCH(xkbGetDeviceInfoReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - wanted= stuff->wanted; - - CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); - CHK_MASK_LEGAL(0x01,wanted,XkbXI_AllDeviceFeaturesMask); - - if ((!dev->button)||((stuff->nBtns<1)&&(!stuff->allBtns))) - wanted&= ~XkbXI_ButtonActionsMask; - if ((!dev->kbdfeed)&&(!dev->leds)) - wanted&= ~XkbXI_IndicatorsMask; - - nameLen= XkbSizeCountedString(dev->name); - memset((char *)&rep, 0, SIZEOF(xkbGetDeviceInfoReply)); - rep.type = X_Reply; - rep.deviceID= dev->id; - rep.sequenceNumber = client->sequence; - rep.length = nameLen/4; - rep.present = wanted; - rep.supported = XkbXI_AllDeviceFeaturesMask; - rep.unsupported = 0; - rep.firstBtnWanted = rep.nBtnsWanted = 0; - rep.firstBtnRtrn = rep.nBtnsRtrn = 0; - if (dev->button) - rep.totalBtns= dev->button->numButtons; - else rep.totalBtns= 0; - rep.devType= dev->xinput_type; - rep.hasOwnState= (dev->key && dev->key->xkbInfo); - rep.nDeviceLedFBs = 0; - if (dev->kbdfeed) rep.dfltKbdFB= dev->kbdfeed->ctrl.id; - else rep.dfltKbdFB= XkbXINone; - if (dev->leds) rep.dfltLedFB= dev->leds->ctrl.id; - else rep.dfltLedFB= XkbXINone; - - ledClass= stuff->ledClass; - ledID= stuff->ledID; - - rep.firstBtnWanted= rep.nBtnsWanted= 0; - rep.firstBtnRtrn= rep.nBtnsRtrn= 0; - if (wanted&XkbXI_ButtonActionsMask) { - if (stuff->allBtns) { - stuff->firstBtn= 0; - stuff->nBtns= dev->button->numButtons; - } - - if ((stuff->firstBtn+stuff->nBtns)>dev->button->numButtons) { - client->errorValue = _XkbErrCode4(0x02,dev->button->numButtons, - stuff->firstBtn, - stuff->nBtns); - return BadValue; - } - else { - rep.firstBtnWanted= stuff->firstBtn; - rep.nBtnsWanted= stuff->nBtns; - if (dev->button->xkb_acts!=NULL) { - XkbAction *act; - register int i; - - rep.firstBtnRtrn= stuff->firstBtn; - rep.nBtnsRtrn= stuff->nBtns; - act= &dev->button->xkb_acts[rep.firstBtnWanted]; - for (i=0;itype!=XkbSA_NoAction) - break; - } - rep.firstBtnRtrn+= i; - rep.nBtnsRtrn-= i; - act= &dev->button->xkb_acts[rep.firstBtnRtrn+rep.nBtnsRtrn-1]; - for (i=0;itype!=XkbSA_NoAction) - break; - } - rep.nBtnsRtrn-= i; - } - rep.length+= (rep.nBtnsRtrn*SIZEOF(xkbActionWireDesc))/4; - } - } - - if (wanted&XkbXI_IndicatorsMask) { - status= CheckDeviceLedFBs(dev,ledClass,ledID,&rep,client); - if (status!=Success) - return status; - } - length= rep.length*4; - nDeviceLedFBs = rep.nDeviceLedFBs; - if (client->swapped) { - register int n; - swaps(&rep.sequenceNumber,n); - swapl(&rep.length,n); - swaps(&rep.present,n); - swaps(&rep.supported,n); - swaps(&rep.unsupported,n); - swaps(&rep.nDeviceLedFBs,n); - swapl(&rep.type,n); - } - WriteToClient(client,SIZEOF(xkbGetDeviceInfoReply), (char *)&rep); - - str= malloc(nameLen); - if (!str) - return BadAlloc; - XkbWriteCountedString(str,dev->name,client->swapped); - WriteToClient(client,nameLen,str); - free(str); - length-= nameLen; - - if (rep.nBtnsRtrn>0) { - int sz; - xkbActionWireDesc * awire; - sz= rep.nBtnsRtrn*SIZEOF(xkbActionWireDesc); - awire= (xkbActionWireDesc *)&dev->button->xkb_acts[rep.firstBtnRtrn]; - WriteToClient(client,sz,(char *)awire); - length-= sz; - } - if (nDeviceLedFBs>0) { - status= SendDeviceLedFBs(dev,ledClass,ledID,length,client); - if (status!=Success) - return status; - } - else if (length!=0) { - ErrorF("[xkb] Internal Error! BadLength in ProcXkbGetDeviceInfo\n"); - ErrorF("[xkb] Wrote %d fewer bytes than expected\n",length); - return BadLength; - } - return Success; -} - -static char * -CheckSetDeviceIndicators( char * wire, - DeviceIntPtr dev, - int num, - int * status_rtrn, - ClientPtr client) -{ -xkbDeviceLedsWireDesc * ledWire; -int i; -XkbSrvLedInfoPtr sli; - - ledWire= (xkbDeviceLedsWireDesc *)wire; - for (i=0;iswapped) { - register int n; - swaps(&ledWire->ledClass,n); - swaps(&ledWire->ledID,n); - swapl(&ledWire->namesPresent,n); - swapl(&ledWire->mapsPresent,n); - swapl(&ledWire->physIndicators,n); - } - - sli= XkbFindSrvLedInfo(dev,ledWire->ledClass,ledWire->ledID, - XkbXI_IndicatorsMask); - if (sli!=NULL) { - register int n; - register unsigned bit; - int nMaps,nNames; - CARD32 *atomWire; - xkbIndicatorMapWireDesc *mapWire; - - nMaps= nNames= 0; - for (n=0,bit=1;nnamesPresent&bit) - nNames++; - if (ledWire->mapsPresent&bit) - nMaps++; - } - atomWire= (CARD32 *)&ledWire[1]; - if (nNames>0) { - for (n=0;nswapped) { - register int t; - swapl(atomWire,t); - } - CHK_ATOM_OR_NONE3(((Atom)(*atomWire)),client->errorValue, - *status_rtrn,NULL); - atomWire++; - } - } - mapWire= (xkbIndicatorMapWireDesc *)atomWire; - if (nMaps>0) { - for (n=0;nswapped) { - register int t; - swaps(&mapWire->virtualMods,t); - swapl(&mapWire->ctrls,t); - } - CHK_MASK_LEGAL3(0x21,mapWire->whichGroups, - XkbIM_UseAnyGroup, - client->errorValue, - *status_rtrn,NULL); - CHK_MASK_LEGAL3(0x22,mapWire->whichMods,XkbIM_UseAnyMods, - client->errorValue, - *status_rtrn,NULL); - mapWire++; - } - } - ledWire= (xkbDeviceLedsWireDesc *)mapWire; - } - else { - /* SHOULD NEVER HAPPEN */ - return (char *)ledWire; - } - } - return (char *)ledWire; -} - -static char * -SetDeviceIndicators( char * wire, - DeviceIntPtr dev, - unsigned changed, - int num, - int * status_rtrn, - ClientPtr client, - xkbExtensionDeviceNotify *ev) -{ -xkbDeviceLedsWireDesc * ledWire; -int i; -XkbEventCauseRec cause; -unsigned namec,mapc,statec; -xkbExtensionDeviceNotify ed; -XkbChangesRec changes; -DeviceIntPtr kbd; - - memset((char *)&ed, 0, sizeof(xkbExtensionDeviceNotify)); - memset((char *)&changes, 0, sizeof(XkbChangesRec)); - XkbSetCauseXkbReq(&cause,X_kbSetDeviceInfo,client); - ledWire= (xkbDeviceLedsWireDesc *)wire; - for (i=0;iledClass,ledWire->ledID, - XkbXI_IndicatorMapsMask); - if (!sli) { - /* SHOULD NEVER HAPPEN!! */ - return (char *)ledWire; - } - - atomWire= (CARD32 *)&ledWire[1]; - if (changed&XkbXI_IndicatorNamesMask) { - namec= sli->namesPresent|ledWire->namesPresent; - memset((char *)sli->names, 0, XkbNumIndicators*sizeof(Atom)); - } - if (ledWire->namesPresent) { - sli->namesPresent= ledWire->namesPresent; - memset((char *)sli->names, 0, XkbNumIndicators*sizeof(Atom)); - for (n=0,bit=1;nnamesPresent&bit) { - sli->names[n]= (Atom)*atomWire; - if (sli->names[n]==None) - ledWire->namesPresent&= ~bit; - atomWire++; - } - } - } - mapWire= (xkbIndicatorMapWireDesc *)atomWire; - if (changed&XkbXI_IndicatorMapsMask) { - mapc= sli->mapsPresent|ledWire->mapsPresent; - sli->mapsPresent= ledWire->mapsPresent; - memset((char*)sli->maps, 0, XkbNumIndicators*sizeof(XkbIndicatorMapRec)); - } - if (ledWire->mapsPresent) { - for (n=0,bit=1;nmapsPresent&bit) { - sli->maps[n].flags= mapWire->flags; - sli->maps[n].which_groups= mapWire->whichGroups; - sli->maps[n].groups= mapWire->groups; - sli->maps[n].which_mods= mapWire->whichMods; - sli->maps[n].mods.mask= mapWire->mods; - sli->maps[n].mods.real_mods=mapWire->realMods; - sli->maps[n].mods.vmods= mapWire->virtualMods; - sli->maps[n].ctrls= mapWire->ctrls; - mapWire++; - } - } - } - if (changed&XkbXI_IndicatorStateMask) { - statec= sli->effectiveState^ledWire->state; - sli->explicitState&= ~statec; - sli->explicitState|= (ledWire->state&statec); - } - if (namec) - XkbApplyLedNameChanges(dev,sli,namec,&ed,&changes,&cause); - if (mapc) - XkbApplyLedMapChanges(dev,sli,mapc,&ed,&changes,&cause); - if (statec) - XkbApplyLedStateChanges(dev,sli,statec,&ed,&changes,&cause); - - kbd= dev; - if ((sli->flags&XkbSLI_HasOwnState)==0) - kbd = inputInfo.keyboard; - - XkbFlushLedEvents(dev,kbd,sli,&ed,&changes,&cause); - ledWire= (xkbDeviceLedsWireDesc *)mapWire; - } - return (char *)ledWire; -} - - -static int -_XkbSetDeviceInfo(ClientPtr client, DeviceIntPtr dev, - xkbSetDeviceInfoReq *stuff) -{ - char *wire; - - wire= (char *)&stuff[1]; - if (stuff->change&XkbXI_ButtonActionsMask) { - if (!dev->button) { - client->errorValue = _XkbErrCode2(XkbErr_BadClass,ButtonClass); - return XkbKeyboardErrorCode; - } - if ((stuff->firstBtn+stuff->nBtns)>dev->button->numButtons) { - client->errorValue= _XkbErrCode4(0x02,stuff->firstBtn,stuff->nBtns, - dev->button->numButtons); - return BadMatch; - } - wire+= (stuff->nBtns*SIZEOF(xkbActionWireDesc)); - } - if (stuff->change&XkbXI_IndicatorsMask) { - int status= Success; - wire= CheckSetDeviceIndicators(wire,dev,stuff->nDeviceLedFBs, - &status,client); - if (status!=Success) - return status; - } - if (((wire-((char *)stuff))/4)!=stuff->length) - return BadLength; - - return Success; -} - -static int -_XkbSetDeviceInfoCheck(ClientPtr client, DeviceIntPtr dev, - xkbSetDeviceInfoReq *stuff) -{ - char *wire; - xkbExtensionDeviceNotify ed; - - memset((char *)&ed, 0, SIZEOF(xkbExtensionDeviceNotify)); - ed.deviceID= dev->id; - wire= (char *)&stuff[1]; - if (stuff->change&XkbXI_ButtonActionsMask) { - int nBtns,sz,i; - XkbAction * acts; - DeviceIntPtr kbd; - - nBtns= dev->button->numButtons; - acts= dev->button->xkb_acts; - if (acts==NULL) { - acts= calloc(nBtns, sizeof(XkbAction)); - if (!acts) - return BadAlloc; - dev->button->xkb_acts= acts; - } - sz= stuff->nBtns*SIZEOF(xkbActionWireDesc); - memcpy((char *)&acts[stuff->firstBtn],(char *)wire,sz); - wire+= sz; - ed.reason|= XkbXI_ButtonActionsMask; - ed.firstBtn= stuff->firstBtn; - ed.nBtns= stuff->nBtns; - - if (dev->key) kbd= dev; - else kbd= inputInfo.keyboard; - acts= &dev->button->xkb_acts[stuff->firstBtn]; - for (i=0;inBtns;i++,acts++) { - if (acts->type!=XkbSA_NoAction) - XkbSetActionKeyMods(kbd->key->xkbInfo->desc,acts,0); - } - } - if (stuff->change&XkbXI_IndicatorsMask) { - int status= Success; - wire= SetDeviceIndicators(wire,dev,stuff->change, - stuff->nDeviceLedFBs, &status,client,&ed); - if (status!=Success) - return status; - } - if ((stuff->change)&&(ed.reason)) - XkbSendExtensionDeviceNotify(dev,client,&ed); - return Success; -} - -int -ProcXkbSetDeviceInfo(ClientPtr client) -{ - DeviceIntPtr dev; - int rc; - - REQUEST(xkbSetDeviceInfoReq); - REQUEST_AT_LEAST_SIZE(xkbSetDeviceInfoReq); - - if (!(client->xkbClientFlags&_XkbClientInitialized)) - return BadAccess; - - CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); - CHK_MASK_LEGAL(0x01,stuff->change,XkbXI_AllFeaturesMask); - - rc = _XkbSetDeviceInfoCheck(client, dev, stuff); - - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd || stuff->deviceSpec == XkbUseCorePtr) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if (((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) && - ((stuff->deviceSpec == XkbUseCoreKbd && other->key) || - (stuff->deviceSpec == XkbUseCorePtr && other->button))) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - { - rc = _XkbSetDeviceInfoCheck(client, other, stuff); - if (rc != Success) - return rc; - } - } - } - } - - /* checks done, apply */ - rc = _XkbSetDeviceInfo(client, dev, stuff); - if (rc != Success) - return rc; - - if (stuff->deviceSpec == XkbUseCoreKbd || stuff->deviceSpec == XkbUseCorePtr) - { - DeviceIntPtr other; - for (other = inputInfo.devices; other; other = other->next) - { - if (((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) && - ((stuff->deviceSpec == XkbUseCoreKbd && other->key) || - (stuff->deviceSpec == XkbUseCorePtr && other->button))) - { - rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); - if (rc == Success) - { - rc = _XkbSetDeviceInfo(client, other, stuff); - if (rc != Success) - return rc; - } - } - } - } - - return Success; -} - -/***====================================================================***/ - -int -ProcXkbSetDebuggingFlags(ClientPtr client) -{ -CARD32 newFlags,newCtrls,extraLength; -xkbSetDebuggingFlagsReply rep; -int rc; - - REQUEST(xkbSetDebuggingFlagsReq); - REQUEST_AT_LEAST_SIZE(xkbSetDebuggingFlagsReq); - - rc = XaceHook(XACE_SERVER_ACCESS, client, DixDebugAccess); - if (rc != Success) - return rc; - - newFlags= xkbDebugFlags&(~stuff->affectFlags); - newFlags|= (stuff->flags&stuff->affectFlags); - newCtrls= xkbDebugCtrls&(~stuff->affectCtrls); - newCtrls|= (stuff->ctrls&stuff->affectCtrls); - if (xkbDebugFlags || newFlags || stuff->msgLength) { - ErrorF("[xkb] XkbDebug: Setting debug flags to 0x%lx\n",(long)newFlags); - if (newCtrls!=xkbDebugCtrls) - ErrorF("[xkb] XkbDebug: Setting debug controls to 0x%lx\n",(long)newCtrls); - } - extraLength= (stuff->length<<2)-sz_xkbSetDebuggingFlagsReq; - if (stuff->msgLength>0) { - char *msg; - if (extraLengthmsgLength)) { - ErrorF("[xkb] XkbDebug: msgLength= %d, length= %ld (should be %d)\n", - stuff->msgLength,(long)extraLength, - XkbPaddedSize(stuff->msgLength)); - return BadLength; - } - msg= (char *)&stuff[1]; - if (msg[stuff->msgLength-1]!='\0') { - ErrorF("[xkb] XkbDebug: message not null-terminated\n"); - return BadValue; - } - ErrorF("[xkb] XkbDebug: %s\n",msg); - } - xkbDebugFlags = newFlags; - xkbDebugCtrls = newCtrls; - - rep.type= X_Reply; - rep.length = 0; - rep.sequenceNumber = client->sequence; - rep.currentFlags = newFlags; - rep.currentCtrls = newCtrls; - rep.supportedFlags = ~0; - rep.supportedCtrls = ~0; - if ( client->swapped ) { - register int n; - swaps(&rep.sequenceNumber, n); - swapl(&rep.currentFlags, n); - swapl(&rep.currentCtrls, n); - swapl(&rep.supportedFlags, n); - swapl(&rep.supportedCtrls, n); - } - WriteToClient(client,SIZEOF(xkbSetDebuggingFlagsReply), (char *)&rep); - return Success; -} - -/***====================================================================***/ - -static int -ProcXkbDispatch (ClientPtr client) -{ - REQUEST(xReq); - switch (stuff->data) - { - case X_kbUseExtension: - return ProcXkbUseExtension(client); - case X_kbSelectEvents: - return ProcXkbSelectEvents(client); - case X_kbBell: - return ProcXkbBell(client); - case X_kbGetState: - return ProcXkbGetState(client); - case X_kbLatchLockState: - return ProcXkbLatchLockState(client); - case X_kbGetControls: - return ProcXkbGetControls(client); - case X_kbSetControls: - return ProcXkbSetControls(client); - case X_kbGetMap: - return ProcXkbGetMap(client); - case X_kbSetMap: - return ProcXkbSetMap(client); - case X_kbGetCompatMap: - return ProcXkbGetCompatMap(client); - case X_kbSetCompatMap: - return ProcXkbSetCompatMap(client); - case X_kbGetIndicatorState: - return ProcXkbGetIndicatorState(client); - case X_kbGetIndicatorMap: - return ProcXkbGetIndicatorMap(client); - case X_kbSetIndicatorMap: - return ProcXkbSetIndicatorMap(client); - case X_kbGetNamedIndicator: - return ProcXkbGetNamedIndicator(client); - case X_kbSetNamedIndicator: - return ProcXkbSetNamedIndicator(client); - case X_kbGetNames: - return ProcXkbGetNames(client); - case X_kbSetNames: - return ProcXkbSetNames(client); - case X_kbGetGeometry: - return ProcXkbGetGeometry(client); - case X_kbSetGeometry: - return ProcXkbSetGeometry(client); - case X_kbPerClientFlags: - return ProcXkbPerClientFlags(client); - case X_kbListComponents: - return ProcXkbListComponents(client); - case X_kbGetKbdByName: - return ProcXkbGetKbdByName(client); - case X_kbGetDeviceInfo: - return ProcXkbGetDeviceInfo(client); - case X_kbSetDeviceInfo: - return ProcXkbSetDeviceInfo(client); - case X_kbSetDebuggingFlags: - return ProcXkbSetDebuggingFlags(client); - default: - return BadRequest; - } -} - -static int -XkbClientGone(pointer data,XID id) -{ - DevicePtr pXDev = (DevicePtr)data; - - if (!XkbRemoveResourceClient(pXDev,id)) { - ErrorF("[xkb] Internal Error! bad RemoveResourceClient in XkbClientGone\n"); - } - return 1; -} - -void -XkbExtensionInit(void) -{ - ExtensionEntry *extEntry; - - RT_XKBCLIENT = CreateNewResourceType(XkbClientGone, "XkbClient"); - if (!RT_XKBCLIENT) - return; - - if (!XkbInitPrivates()) - return; - - if ((extEntry = AddExtension(XkbName, XkbNumberEvents, XkbNumberErrors, - ProcXkbDispatch, SProcXkbDispatch, - NULL, StandardMinorOpcode))) { - XkbReqCode = (unsigned char)extEntry->base; - XkbEventBase = (unsigned char)extEntry->eventBase; - XkbErrorBase = (unsigned char)extEntry->errorBase; - XkbKeyboardErrorCode = XkbErrorBase+XkbKeyboard; - } - return; -} - - +/************************************************************ +Copyright (c) 1993 by Silicon Graphics Computer Systems, Inc. + +Permission to use, copy, modify, and distribute this +software and its documentation for any purpose and without +fee is hereby granted, provided that the above copyright +notice appear in all copies and that both that copyright +notice and this permission notice appear in supporting +documentation, and that the name of Silicon Graphics not be +used in advertising or publicity pertaining to distribution +of the software without specific prior written permission. +Silicon Graphics makes no representation about the suitability +of this software for any purpose. It is provided "as is" +without any express or implied warranty. + +SILICON GRAPHICS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS +SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON +GRAPHICS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL +DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE +OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH +THE USE OR PERFORMANCE OF THIS SOFTWARE. + +********************************************************/ + +#ifdef HAVE_DIX_CONFIG_H +#include +#endif + +#include +#include +#include +#include "misc.h" +#include "inputstr.h" +#define XKBSRV_NEED_FILE_FUNCS +#include +#include "extnsionst.h" +#include "xace.h" +#include "xkb.h" +#include "protocol-versions.h" + +#include +#include + +int XkbEventBase; +static int XkbErrorBase; +int XkbReqCode; +int XkbKeyboardErrorCode; +CARD32 xkbDebugFlags = 0; +static CARD32 xkbDebugCtrls = 0; + +static RESTYPE RT_XKBCLIENT; + +/***====================================================================***/ + +#define CHK_DEVICE(dev, id, client, access_mode, lf) {\ + int why;\ + int rc = lf(&(dev), id, client, access_mode, &why);\ + if (rc != Success) {\ + client->errorValue = _XkbErrCode2(why, id);\ + return rc;\ + }\ +} + +#define CHK_KBD_DEVICE(dev, id, client, mode) \ + CHK_DEVICE(dev, id, client, mode, _XkbLookupKeyboard) +#define CHK_LED_DEVICE(dev, id, client, mode) \ + CHK_DEVICE(dev, id, client, mode, _XkbLookupLedDevice) +#define CHK_BELL_DEVICE(dev, id, client, mode) \ + CHK_DEVICE(dev, id, client, mode, _XkbLookupBellDevice) +#define CHK_ANY_DEVICE(dev, id, client, mode) \ + CHK_DEVICE(dev, id, client, mode, _XkbLookupAnyDevice) + +#define CHK_ATOM_ONLY2(a,ev,er) {\ + if (((a)==None)||(!ValidAtom((a)))) {\ + (ev)= (XID)(a);\ + return er;\ + }\ +} +#define CHK_ATOM_ONLY(a) \ + CHK_ATOM_ONLY2(a,client->errorValue,BadAtom) + +#define CHK_ATOM_OR_NONE3(a,ev,er,ret) {\ + if (((a)!=None)&&(!ValidAtom((a)))) {\ + (ev)= (XID)(a);\ + (er)= BadAtom;\ + return ret;\ + }\ +} +#define CHK_ATOM_OR_NONE2(a,ev,er) {\ + if (((a)!=None)&&(!ValidAtom((a)))) {\ + (ev)= (XID)(a);\ + return er;\ + }\ +} +#define CHK_ATOM_OR_NONE(a) \ + CHK_ATOM_OR_NONE2(a,client->errorValue,BadAtom) + +#define CHK_MASK_LEGAL3(err,mask,legal,ev,er,ret) {\ + if ((mask)&(~(legal))) { \ + (ev)= _XkbErrCode2((err),((mask)&(~(legal))));\ + (er)= BadValue;\ + return ret;\ + }\ +} +#define CHK_MASK_LEGAL2(err,mask,legal,ev,er) {\ + if ((mask)&(~(legal))) { \ + (ev)= _XkbErrCode2((err),((mask)&(~(legal))));\ + return er;\ + }\ +} +#define CHK_MASK_LEGAL(err,mask,legal) \ + CHK_MASK_LEGAL2(err,mask,legal,client->errorValue,BadValue) + +#define CHK_MASK_MATCH(err,affect,value) {\ + if ((value)&(~(affect))) { \ + client->errorValue= _XkbErrCode2((err),((value)&(~(affect))));\ + return BadMatch;\ + }\ +} +#define CHK_MASK_OVERLAP(err,m1,m2) {\ + if ((m1)&(m2)) { \ + client->errorValue= _XkbErrCode2((err),((m1)&(m2)));\ + return BadMatch;\ + }\ +} +#define CHK_KEY_RANGE2(err,first,num,x,ev,er) {\ + if (((unsigned)(first)+(num)-1)>(x)->max_key_code) {\ + (ev)=_XkbErrCode4(err,(first),(num),(x)->max_key_code);\ + return er;\ + }\ + else if ( (first)<(x)->min_key_code ) {\ + (ev)=_XkbErrCode3(err+1,(first),xkb->min_key_code);\ + return er;\ + }\ +} +#define CHK_KEY_RANGE(err,first,num,x) \ + CHK_KEY_RANGE2(err,first,num,x,client->errorValue,BadValue) + +#define CHK_REQ_KEY_RANGE2(err,first,num,r,ev,er) {\ + if (((unsigned)(first)+(num)-1)>(r)->maxKeyCode) {\ + (ev)=_XkbErrCode4(err,(first),(num),(r)->maxKeyCode);\ + return er;\ + }\ + else if ( (first)<(r)->minKeyCode ) {\ + (ev)=_XkbErrCode3(err+1,(first),(r)->minKeyCode);\ + return er;\ + }\ +} +#define CHK_REQ_KEY_RANGE(err,first,num,r) \ + CHK_REQ_KEY_RANGE2(err,first,num,r,client->errorValue,BadValue) + +/***====================================================================***/ + +int +ProcXkbUseExtension(ClientPtr client) +{ + REQUEST(xkbUseExtensionReq); + xkbUseExtensionReply rep; + register int n; + int supported; + + REQUEST_SIZE_MATCH(xkbUseExtensionReq); + if (stuff->wantedMajor != SERVER_XKB_MAJOR_VERSION) { + /* pre-release version 0.65 is compatible with 1.00 */ + supported= ((SERVER_XKB_MAJOR_VERSION==1)&& + (stuff->wantedMajor==0)&&(stuff->wantedMinor==65)); + } + else supported = 1; + + if ((supported) && (!(client->xkbClientFlags&_XkbClientInitialized))) { + client->xkbClientFlags= _XkbClientInitialized; + client->vMajor= stuff->wantedMajor; + client->vMinor= stuff->wantedMinor; + } + else if (xkbDebugFlags&0x1) { + ErrorF("[xkb] Rejecting client %d (0x%lx) (wants %d.%02d, have %d.%02d)\n", + client->index, + (long)client->clientAsMask, + stuff->wantedMajor,stuff->wantedMinor, + SERVER_XKB_MAJOR_VERSION,SERVER_XKB_MINOR_VERSION); + } + memset(&rep, 0, sizeof(xkbUseExtensionReply)); + rep.type = X_Reply; + rep.supported = supported; + rep.length = 0; + rep.sequenceNumber = client->sequence; + rep.serverMajor = SERVER_XKB_MAJOR_VERSION; + rep.serverMinor = SERVER_XKB_MINOR_VERSION; + if ( client->swapped ) { + swaps(&rep.sequenceNumber, n); + swaps(&rep.serverMajor, n); + swaps(&rep.serverMinor, n); + } + WriteToClient(client,SIZEOF(xkbUseExtensionReply), (char *)&rep); + return Success; +} + +/***====================================================================***/ + +int +ProcXkbSelectEvents(ClientPtr client) +{ + unsigned legal; + DeviceIntPtr dev; + XkbInterestPtr masks; + REQUEST(xkbSelectEventsReq); + + REQUEST_AT_LEAST_SIZE(xkbSelectEventsReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixUseAccess); + + if (((stuff->affectWhich&XkbMapNotifyMask)!=0)&&(stuff->affectMap)) { + client->mapNotifyMask&= ~stuff->affectMap; + client->mapNotifyMask|= (stuff->affectMap&stuff->map); + } + if ((stuff->affectWhich&(~XkbMapNotifyMask))==0) + return Success; + + masks = XkbFindClientResource((DevicePtr)dev,client); + if (!masks){ + XID id = FakeClientID(client->index); + if (!AddResource(id,RT_XKBCLIENT,dev)) + return BadAlloc; + masks= XkbAddClientResource((DevicePtr)dev,client,id); + } + if (masks) { + union { + CARD8 *c8; + CARD16 *c16; + CARD32 *c32; + } from,to; + register unsigned bit,ndx,maskLeft,dataLeft,size; + + from.c8= (CARD8 *)&stuff[1]; + dataLeft= (stuff->length*4)-SIZEOF(xkbSelectEventsReq); + maskLeft= (stuff->affectWhich&(~XkbMapNotifyMask)); + for (ndx=0,bit=1; (maskLeft!=0); ndx++, bit<<=1) { + if ((bit&maskLeft)==0) + continue; + maskLeft&= ~bit; + switch (ndx) { + case XkbNewKeyboardNotify: + to.c16= &client->newKeyboardNotifyMask; + legal= XkbAllNewKeyboardEventsMask; + size= 2; + break; + case XkbStateNotify: + to.c16= &masks->stateNotifyMask; + legal= XkbAllStateEventsMask; + size= 2; + break; + case XkbControlsNotify: + to.c32= &masks->ctrlsNotifyMask; + legal= XkbAllControlEventsMask; + size= 4; + break; + case XkbIndicatorStateNotify: + to.c32= &masks->iStateNotifyMask; + legal= XkbAllIndicatorEventsMask; + size= 4; + break; + case XkbIndicatorMapNotify: + to.c32= &masks->iMapNotifyMask; + legal= XkbAllIndicatorEventsMask; + size= 4; + break; + case XkbNamesNotify: + to.c16= &masks->namesNotifyMask; + legal= XkbAllNameEventsMask; + size= 2; + break; + case XkbCompatMapNotify: + to.c8= &masks->compatNotifyMask; + legal= XkbAllCompatMapEventsMask; + size= 1; + break; + case XkbBellNotify: + to.c8= &masks->bellNotifyMask; + legal= XkbAllBellEventsMask; + size= 1; + break; + case XkbActionMessage: + to.c8= &masks->actionMessageMask; + legal= XkbAllActionMessagesMask; + size= 1; + break; + case XkbAccessXNotify: + to.c16= &masks->accessXNotifyMask; + legal= XkbAllAccessXEventsMask; + size= 2; + break; + case XkbExtensionDeviceNotify: + to.c16= &masks->extDevNotifyMask; + legal= XkbAllExtensionDeviceEventsMask; + size= 2; + break; + default: + client->errorValue = _XkbErrCode2(33,bit); + return BadValue; + } + + if (stuff->clear&bit) { + if (size==2) to.c16[0]= 0; + else if (size==4) to.c32[0]= 0; + else to.c8[0]= 0; + } + else if (stuff->selectAll&bit) { + if (size==2) to.c16[0]= ~0; + else if (size==4) to.c32[0]= ~0; + else to.c8[0]= ~0; + } + else { + if (dataLeft<(size*2)) + return BadLength; + if (size==2) { + CHK_MASK_MATCH(ndx,from.c16[0],from.c16[1]); + CHK_MASK_LEGAL(ndx,from.c16[0],legal); + to.c16[0]&= ~from.c16[0]; + to.c16[0]|= (from.c16[0]&from.c16[1]); + } + else if (size==4) { + CHK_MASK_MATCH(ndx,from.c32[0],from.c32[1]); + CHK_MASK_LEGAL(ndx,from.c32[0],legal); + to.c32[0]&= ~from.c32[0]; + to.c32[0]|= (from.c32[0]&from.c32[1]); + } + else { + CHK_MASK_MATCH(ndx,from.c8[0],from.c8[1]); + CHK_MASK_LEGAL(ndx,from.c8[0],legal); + to.c8[0]&= ~from.c8[0]; + to.c8[0]|= (from.c8[0]&from.c8[1]); + size= 2; + } + from.c8+= (size*2); + dataLeft-= (size*2); + } + } + if (dataLeft>2) { + ErrorF("[xkb] Extra data (%d bytes) after SelectEvents\n",dataLeft); + return BadLength; + } + return Success; + } + return BadAlloc; +} + +/***====================================================================***/ +/** + * Ring a bell on the given device for the given client. + */ +static int +_XkbBell(ClientPtr client, DeviceIntPtr dev, WindowPtr pWin, + int bellClass, int bellID, int pitch, int duration, + int percent, int forceSound, int eventOnly, Atom name) +{ + int base; + pointer ctrl; + int oldPitch, oldDuration; + int newPercent; + + if (bellClass == KbdFeedbackClass) { + KbdFeedbackPtr k; + if (bellID==XkbDfltXIId) + k= dev->kbdfeed; + else { + for (k=dev->kbdfeed; k; k=k->next) { + if (k->ctrl.id == bellID) + break; + } + } + if (!k) { + client->errorValue = _XkbErrCode2(0x5,bellID); + return BadValue; + } + base = k->ctrl.bell; + ctrl = (pointer) &(k->ctrl); + oldPitch= k->ctrl.bell_pitch; + oldDuration= k->ctrl.bell_duration; + if (pitch!=0) { + if (pitch==-1) + k->ctrl.bell_pitch= defaultKeyboardControl.bell_pitch; + else k->ctrl.bell_pitch= pitch; + } + if (duration!=0) { + if (duration==-1) + k->ctrl.bell_duration= defaultKeyboardControl.bell_duration; + else k->ctrl.bell_duration= duration; + } + } + else if (bellClass == BellFeedbackClass) { + BellFeedbackPtr b; + if (bellID==XkbDfltXIId) + b= dev->bell; + else { + for (b=dev->bell; b; b=b->next) { + if (b->ctrl.id == bellID) + break; + } + } + if (!b) { + client->errorValue = _XkbErrCode2(0x6,bellID); + return BadValue; + } + base = b->ctrl.percent; + ctrl = (pointer) &(b->ctrl); + oldPitch= b->ctrl.pitch; + oldDuration= b->ctrl.duration; + if (pitch!=0) { + if (pitch==-1) + b->ctrl.pitch= defaultKeyboardControl.bell_pitch; + else b->ctrl.pitch= pitch; + } + if (duration!=0) { + if (duration==-1) + b->ctrl.duration= defaultKeyboardControl.bell_duration; + else b->ctrl.duration= duration; + } + } + else { + client->errorValue = _XkbErrCode2(0x7, bellClass); + return BadValue; + } + + newPercent = (base * percent)/100; + if (percent < 0) + newPercent = base + newPercent; + else newPercent = base - newPercent + percent; + + XkbHandleBell(forceSound, eventOnly, + dev, newPercent, ctrl, bellClass, + name, pWin, client); + if ((pitch!=0)||(duration!=0)) { + if (bellClass == KbdFeedbackClass) { + KbdFeedbackPtr k; + k= (KbdFeedbackPtr)ctrl; + if (pitch!=0) + k->ctrl.bell_pitch= oldPitch; + if (duration!=0) + k->ctrl.bell_duration= oldDuration; + } + else { + BellFeedbackPtr b; + b= (BellFeedbackPtr)ctrl; + if (pitch!=0) + b->ctrl.pitch= oldPitch; + if (duration!=0) + b->ctrl.duration= oldDuration; + } + } + + return Success; +} + +int +ProcXkbBell(ClientPtr client) +{ + REQUEST(xkbBellReq); + DeviceIntPtr dev; + WindowPtr pWin; + int rc; + + REQUEST_SIZE_MATCH(xkbBellReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_BELL_DEVICE(dev, stuff->deviceSpec, client, DixBellAccess); + CHK_ATOM_OR_NONE(stuff->name); + + /* device-independent checks request for sane values */ + if ((stuff->forceSound)&&(stuff->eventOnly)) { + client->errorValue=_XkbErrCode3(0x1,stuff->forceSound,stuff->eventOnly); + return BadMatch; + } + if (stuff->percent < -100 || stuff->percent > 100) { + client->errorValue = _XkbErrCode2(0x2,stuff->percent); + return BadValue; + } + if (stuff->duration<-1) { + client->errorValue = _XkbErrCode2(0x3,stuff->duration); + return BadValue; + } + if (stuff->pitch<-1) { + client->errorValue = _XkbErrCode2(0x4,stuff->pitch); + return BadValue; + } + + if (stuff->bellClass == XkbDfltXIClass) { + if (dev->kbdfeed!=NULL) + stuff->bellClass= KbdFeedbackClass; + else stuff->bellClass= BellFeedbackClass; + } + + if (stuff->window!=None) { + rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess); + if (rc != Success) { + client->errorValue= stuff->window; + return rc; + } + } + else pWin= NULL; + + /* Client wants to ring a bell on the core keyboard? + Ring the bell on the core keyboard (which does nothing, but if that + fails the client is screwed anyway), and then on all extension devices. + Fail if the core keyboard fails but not the extension devices. this + may cause some keyboards to ding and others to stay silent. Fix + your client to use explicit keyboards to avoid this. + + dev is the device the client requested. + */ + rc = _XkbBell(client, dev, pWin, stuff->bellClass, stuff->bellID, + stuff->pitch, stuff->duration, stuff->percent, + stuff->forceSound, stuff->eventOnly, stuff->name); + + if ((rc == Success) && ((stuff->deviceSpec == XkbUseCoreKbd) || + (stuff->deviceSpec == XkbUseCorePtr))) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixBellAccess); + if (rc == Success) + _XkbBell(client, other, pWin, stuff->bellClass, + stuff->bellID, stuff->pitch, stuff->duration, + stuff->percent, stuff->forceSound, + stuff->eventOnly, stuff->name); + } + } + rc = Success; /* reset to success, that's what we got for the VCK */ + } + + return rc; +} + +/***====================================================================***/ + +int +ProcXkbGetState(ClientPtr client) +{ + REQUEST(xkbGetStateReq); + DeviceIntPtr dev; + xkbGetStateReply rep; + XkbStateRec *xkb; + + REQUEST_SIZE_MATCH(xkbGetStateReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + + xkb= &dev->key->xkbInfo->state; + memset(&rep, 0, sizeof(xkbGetStateReply)); + rep.type= X_Reply; + rep.sequenceNumber= client->sequence; + rep.length = 0; + rep.deviceID = dev->id; + rep.mods = XkbStateFieldFromRec(xkb) & 0xff; + rep.baseMods = xkb->base_mods; + rep.lockedMods = xkb->locked_mods; + rep.latchedMods = xkb->latched_mods; + rep.group = xkb->group; + rep.baseGroup = xkb->base_group; + rep.latchedGroup = xkb->latched_group; + rep.lockedGroup = xkb->locked_group; + rep.compatState = xkb->compat_state; + rep.ptrBtnState = xkb->ptr_buttons; + if (client->swapped) { + register int n; + swaps(&rep.sequenceNumber,n); + swaps(&rep.ptrBtnState,n); + } + WriteToClient(client, SIZEOF(xkbGetStateReply), (char *)&rep); + return Success; +} + +/***====================================================================***/ + +int +ProcXkbLatchLockState(ClientPtr client) +{ + int status; + DeviceIntPtr dev, tmpd; + XkbStateRec oldState,*newState; + CARD16 changed; + xkbStateNotify sn; + XkbEventCauseRec cause; + + REQUEST(xkbLatchLockStateReq); + REQUEST_SIZE_MATCH(xkbLatchLockStateReq); + + if (!(client->xkbClientFlags & _XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixSetAttrAccess); + CHK_MASK_MATCH(0x01, stuff->affectModLocks, stuff->modLocks); + CHK_MASK_MATCH(0x01, stuff->affectModLatches, stuff->modLatches); + + status = Success; + + for (tmpd = inputInfo.devices; tmpd; tmpd = tmpd->next) { + if ((tmpd == dev) || (!IsMaster(tmpd) && GetMaster(tmpd, MASTER_KEYBOARD) == dev)) { + if (!tmpd->key || !tmpd->key->xkbInfo) + continue; + + oldState = tmpd->key->xkbInfo->state; + newState = &tmpd->key->xkbInfo->state; + if (stuff->affectModLocks) { + newState->locked_mods &= ~stuff->affectModLocks; + newState->locked_mods |= (stuff->affectModLocks & stuff->modLocks); + } + if (status == Success && stuff->lockGroup) + newState->locked_group = stuff->groupLock; + if (status == Success && stuff->affectModLatches) + status = XkbLatchModifiers(tmpd, stuff->affectModLatches, + stuff->modLatches); + if (status == Success && stuff->latchGroup) + status = XkbLatchGroup(tmpd, stuff->groupLatch); + + if (status != Success) + return status; + + XkbComputeDerivedState(tmpd->key->xkbInfo); + + changed = XkbStateChangedFlags(&oldState, newState); + if (changed) { + sn.keycode = 0; + sn.eventType = 0; + sn.requestMajor = XkbReqCode; + sn.requestMinor = X_kbLatchLockState; + sn.changed = changed; + XkbSendStateNotify(tmpd, &sn); + changed = XkbIndicatorsToUpdate(tmpd, changed, FALSE); + if (changed) { + XkbSetCauseXkbReq(&cause, X_kbLatchLockState, client); + XkbUpdateIndicators(tmpd, changed, TRUE, NULL, &cause); + } + } + } + } + + return Success; +} + +/***====================================================================***/ + +int +ProcXkbGetControls(ClientPtr client) +{ + xkbGetControlsReply rep; + XkbControlsPtr xkb; + DeviceIntPtr dev; + register int n; + + REQUEST(xkbGetControlsReq); + REQUEST_SIZE_MATCH(xkbGetControlsReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + + xkb = dev->key->xkbInfo->desc->ctrls; + rep.type = X_Reply; + rep.length = bytes_to_int32(SIZEOF(xkbGetControlsReply)- + SIZEOF(xGenericReply)); + rep.sequenceNumber = client->sequence; + rep.deviceID = ((DeviceIntPtr)dev)->id; + rep.numGroups = xkb->num_groups; + rep.groupsWrap = xkb->groups_wrap; + rep.internalMods = xkb->internal.mask; + rep.ignoreLockMods = xkb->ignore_lock.mask; + rep.internalRealMods = xkb->internal.real_mods; + rep.ignoreLockRealMods = xkb->ignore_lock.real_mods; + rep.internalVMods = xkb->internal.vmods; + rep.ignoreLockVMods = xkb->ignore_lock.vmods; + rep.enabledCtrls = xkb->enabled_ctrls; + rep.repeatDelay = xkb->repeat_delay; + rep.repeatInterval = xkb->repeat_interval; + rep.slowKeysDelay = xkb->slow_keys_delay; + rep.debounceDelay = xkb->debounce_delay; + rep.mkDelay = xkb->mk_delay; + rep.mkInterval = xkb->mk_interval; + rep.mkTimeToMax = xkb->mk_time_to_max; + rep.mkMaxSpeed = xkb->mk_max_speed; + rep.mkCurve = xkb->mk_curve; + rep.mkDfltBtn = xkb->mk_dflt_btn; + rep.axTimeout = xkb->ax_timeout; + rep.axtCtrlsMask = xkb->axt_ctrls_mask; + rep.axtCtrlsValues = xkb->axt_ctrls_values; + rep.axtOptsMask = xkb->axt_opts_mask; + rep.axtOptsValues = xkb->axt_opts_values; + rep.axOptions = xkb->ax_options; + memcpy(rep.perKeyRepeat,xkb->per_key_repeat,XkbPerKeyBitArraySize); + if (client->swapped) { + swaps(&rep.sequenceNumber, n); + swapl(&rep.length,n); + swaps(&rep.internalVMods, n); + swaps(&rep.ignoreLockVMods, n); + swapl(&rep.enabledCtrls, n); + swaps(&rep.repeatDelay, n); + swaps(&rep.repeatInterval, n); + swaps(&rep.slowKeysDelay, n); + swaps(&rep.debounceDelay, n); + swaps(&rep.mkDelay, n); + swaps(&rep.mkInterval, n); + swaps(&rep.mkTimeToMax, n); + swaps(&rep.mkMaxSpeed, n); + swaps(&rep.mkCurve, n); + swaps(&rep.axTimeout, n); + swapl(&rep.axtCtrlsMask, n); + swapl(&rep.axtCtrlsValues, n); + swaps(&rep.axtOptsMask, n); + swaps(&rep.axtOptsValues, n); + swaps(&rep.axOptions, n); + } + WriteToClient(client, SIZEOF(xkbGetControlsReply), (char *)&rep); + return Success; +} + +int +ProcXkbSetControls(ClientPtr client) +{ + DeviceIntPtr dev, tmpd; + XkbSrvInfoPtr xkbi; + XkbControlsPtr ctrl; + XkbControlsRec new,old; + xkbControlsNotify cn; + XkbEventCauseRec cause; + XkbSrvLedInfoPtr sli; + + REQUEST(xkbSetControlsReq); + REQUEST_SIZE_MATCH(xkbSetControlsReq); + + if (!(client->xkbClientFlags & _XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); + CHK_MASK_LEGAL(0x01, stuff->changeCtrls, XkbAllControlsMask); + + for (tmpd = inputInfo.devices; tmpd; tmpd = tmpd->next) { + if (!tmpd->key || !tmpd->key->xkbInfo) + continue; + if ((tmpd == dev) || (!IsMaster(tmpd) && GetMaster(tmpd, MASTER_KEYBOARD) == dev)) { + xkbi = tmpd->key->xkbInfo; + ctrl = xkbi->desc->ctrls; + new = *ctrl; + XkbSetCauseXkbReq(&cause, X_kbSetControls, client); + + if (stuff->changeCtrls & XkbInternalModsMask) { + CHK_MASK_MATCH(0x02, stuff->affectInternalMods, + stuff->internalMods); + CHK_MASK_MATCH(0x03, stuff->affectInternalVMods, + stuff->internalVMods); + + new.internal.real_mods &= ~(stuff->affectInternalMods); + new.internal.real_mods |= (stuff->affectInternalMods & + stuff->internalMods); + new.internal.vmods &= ~(stuff->affectInternalVMods); + new.internal.vmods |= (stuff->affectInternalVMods & + stuff->internalVMods); + new.internal.mask = new.internal.real_mods | + XkbMaskForVMask(xkbi->desc, + new.internal.vmods); + } + + if (stuff->changeCtrls & XkbIgnoreLockModsMask) { + CHK_MASK_MATCH(0x4, stuff->affectIgnoreLockMods, + stuff->ignoreLockMods); + CHK_MASK_MATCH(0x5, stuff->affectIgnoreLockVMods, + stuff->ignoreLockVMods); + + new.ignore_lock.real_mods &= ~(stuff->affectIgnoreLockMods); + new.ignore_lock.real_mods |= (stuff->affectIgnoreLockMods & + stuff->ignoreLockMods); + new.ignore_lock.vmods &= ~(stuff->affectIgnoreLockVMods); + new.ignore_lock.vmods |= (stuff->affectIgnoreLockVMods & + stuff->ignoreLockVMods); + new.ignore_lock.mask = new.ignore_lock.real_mods | + XkbMaskForVMask(xkbi->desc, + new.ignore_lock.vmods); + } + + CHK_MASK_MATCH(0x06, stuff->affectEnabledCtrls, + stuff->enabledCtrls); + if (stuff->affectEnabledCtrls) { + CHK_MASK_LEGAL(0x07, stuff->affectEnabledCtrls, + XkbAllBooleanCtrlsMask); + + new.enabled_ctrls &= ~(stuff->affectEnabledCtrls); + new.enabled_ctrls |= (stuff->affectEnabledCtrls & + stuff->enabledCtrls); + } + + if (stuff->changeCtrls & XkbRepeatKeysMask) { + if (stuff->repeatDelay < 1 || stuff->repeatInterval < 1) { + client->errorValue = _XkbErrCode3(0x08, stuff->repeatDelay, + stuff->repeatInterval); + return BadValue; + } + + new.repeat_delay = stuff->repeatDelay; + new.repeat_interval = stuff->repeatInterval; + } + + if (stuff->changeCtrls & XkbSlowKeysMask) { + if (stuff->slowKeysDelay < 1) { + client->errorValue = _XkbErrCode2(0x09, + stuff->slowKeysDelay); + return BadValue; + } + + new.slow_keys_delay = stuff->slowKeysDelay; + } + + if (stuff->changeCtrls & XkbBounceKeysMask) { + if (stuff->debounceDelay < 1) { + client->errorValue = _XkbErrCode2(0x0A, + stuff->debounceDelay); + return BadValue; + } + + new.debounce_delay = stuff->debounceDelay; + } + + if (stuff->changeCtrls & XkbMouseKeysMask) { + if (stuff->mkDfltBtn > XkbMaxMouseKeysBtn) { + client->errorValue = _XkbErrCode2(0x0B, stuff->mkDfltBtn); + return BadValue; + } + + new.mk_dflt_btn = stuff->mkDfltBtn; + } + + if (stuff->changeCtrls & XkbMouseKeysAccelMask) { + if (stuff->mkDelay < 1 || stuff->mkInterval < 1 || + stuff->mkTimeToMax < 1 || stuff->mkMaxSpeed < 1 || + stuff->mkCurve < -1000) { + client->errorValue = _XkbErrCode2(0x0C,0); + return BadValue; + } + + new.mk_delay = stuff->mkDelay; + new.mk_interval = stuff->mkInterval; + new.mk_time_to_max = stuff->mkTimeToMax; + new.mk_max_speed = stuff->mkMaxSpeed; + new.mk_curve = stuff->mkCurve; + AccessXComputeCurveFactor(xkbi, &new); + } + + if (stuff->changeCtrls & XkbGroupsWrapMask) { + unsigned act, num; + + act = XkbOutOfRangeGroupAction(stuff->groupsWrap); + switch (act) { + case XkbRedirectIntoRange: + num = XkbOutOfRangeGroupNumber(stuff->groupsWrap); + if (num >= new.num_groups) { + client->errorValue = _XkbErrCode3(0x0D, new.num_groups, + num); + return BadValue; + } + case XkbWrapIntoRange: + case XkbClampIntoRange: + break; + default: + client->errorValue = _XkbErrCode2(0x0E, act); + return BadValue; + } + + new.groups_wrap= stuff->groupsWrap; + } + + CHK_MASK_LEGAL(0x0F, stuff->axOptions, XkbAX_AllOptionsMask); + if (stuff->changeCtrls & XkbAccessXKeysMask) { + new.ax_options = stuff->axOptions & XkbAX_AllOptionsMask; + } + else { + if (stuff->changeCtrls & XkbStickyKeysMask) { + new.ax_options &= ~(XkbAX_SKOptionsMask); + new.ax_options |= (stuff->axOptions & XkbAX_SKOptionsMask); + } + + if (stuff->changeCtrls & XkbAccessXFeedbackMask) { + new.ax_options &= ~(XkbAX_FBOptionsMask); + new.ax_options |= (stuff->axOptions & XkbAX_FBOptionsMask); + } + } + + if (stuff->changeCtrls & XkbAccessXTimeoutMask) { + if (stuff->axTimeout < 1) { + client->errorValue = _XkbErrCode2(0x10, stuff->axTimeout); + return BadValue; + } + CHK_MASK_MATCH(0x11, stuff->axtCtrlsMask, + stuff->axtCtrlsValues); + CHK_MASK_LEGAL(0x12, stuff->axtCtrlsMask, + XkbAllBooleanCtrlsMask); + CHK_MASK_MATCH(0x13, stuff->axtOptsMask, stuff->axtOptsValues); + CHK_MASK_LEGAL(0x14, stuff->axtOptsMask, XkbAX_AllOptionsMask); + new.ax_timeout = stuff->axTimeout; + new.axt_ctrls_mask = stuff->axtCtrlsMask; + new.axt_ctrls_values = (stuff->axtCtrlsValues & + stuff->axtCtrlsMask); + new.axt_opts_mask = stuff->axtOptsMask; + new.axt_opts_values = (stuff->axtOptsValues & + stuff->axtOptsMask); + } + + if (stuff->changeCtrls & XkbPerKeyRepeatMask) { + memcpy(new.per_key_repeat, stuff->perKeyRepeat, + XkbPerKeyBitArraySize); + if (xkbi->repeatKey && + !BitIsOn(new.per_key_repeat, xkbi->repeatKey)) { + AccessXCancelRepeatKey(xkbi, xkbi->repeatKey); + } + } + + old= *ctrl; + *ctrl= new; + XkbDDXChangeControls(tmpd, &old, ctrl); + + if (XkbComputeControlsNotify(tmpd, &old, ctrl, &cn, FALSE)) { + cn.keycode = 0; + cn.eventType = 0; + cn.requestMajor = XkbReqCode; + cn.requestMinor = X_kbSetControls; + XkbSendControlsNotify(tmpd, &cn); + } + + sli = XkbFindSrvLedInfo(tmpd, XkbDfltXIClass, XkbDfltXIId, 0); + if (sli) + XkbUpdateIndicators(tmpd, sli->usesControls, TRUE, NULL, + &cause); + + /* If sticky keys were disabled, clear all locks and latches */ + if ((old.enabled_ctrls & XkbStickyKeysMask) && + !(ctrl->enabled_ctrls & XkbStickyKeysMask)) + XkbClearAllLatchesAndLocks(tmpd, xkbi, TRUE, &cause); + } + } + + return Success; +} + +/***====================================================================***/ + +static int +XkbSizeKeyTypes(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + XkbKeyTypeRec *type; + unsigned i,len; + + len= 0; + if (((rep->present&XkbKeyTypesMask)==0)||(rep->nTypes<1)|| + (!xkb)||(!xkb->map)||(!xkb->map->types)) { + rep->present&= ~XkbKeyTypesMask; + rep->firstType= rep->nTypes= 0; + return 0; + } + type= &xkb->map->types[rep->firstType]; + for (i=0;inTypes;i++,type++){ + len+= SIZEOF(xkbKeyTypeWireDesc); + if (type->map_count>0) { + len+= (type->map_count*SIZEOF(xkbKTMapEntryWireDesc)); + if (type->preserve) + len+= (type->map_count*SIZEOF(xkbModsWireDesc)); + } + } + return len; +} + +static char * +XkbWriteKeyTypes( XkbDescPtr xkb, + xkbGetMapReply * rep, + char * buf, + ClientPtr client) +{ + XkbKeyTypePtr type; + unsigned i; + xkbKeyTypeWireDesc *wire; + + type= &xkb->map->types[rep->firstType]; + for (i=0;inTypes;i++,type++) { + register unsigned n; + wire= (xkbKeyTypeWireDesc *)buf; + wire->mask = type->mods.mask; + wire->realMods = type->mods.real_mods; + wire->virtualMods = type->mods.vmods; + wire->numLevels = type->num_levels; + wire->nMapEntries = type->map_count; + wire->preserve = (type->preserve!=NULL); + if (client->swapped) { + register int n; + swaps(&wire->virtualMods,n); + } + + buf= (char *)&wire[1]; + if (wire->nMapEntries>0) { + xkbKTMapEntryWireDesc * wire; + XkbKTMapEntryPtr entry; + wire= (xkbKTMapEntryWireDesc *)buf; + entry= type->map; + for (n=0;nmap_count;n++,wire++,entry++) { + wire->active= entry->active; + wire->mask= entry->mods.mask; + wire->level= entry->level; + wire->realMods= entry->mods.real_mods; + wire->virtualMods= entry->mods.vmods; + if (client->swapped) { + register int n; + swaps(&wire->virtualMods,n); + } + } + buf= (char *)wire; + if (type->preserve!=NULL) { + xkbModsWireDesc * pwire; + XkbModsPtr preserve; + pwire= (xkbModsWireDesc *)buf; + preserve= type->preserve; + for (n=0;nmap_count;n++,pwire++,preserve++) { + pwire->mask= preserve->mask; + pwire->realMods= preserve->real_mods; + pwire->virtualMods= preserve->vmods; + if (client->swapped) { + register int n; + swaps(&pwire->virtualMods,n); + } + } + buf= (char *)pwire; + } + } + } + return buf; +} + +static int +XkbSizeKeySyms(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + XkbSymMapPtr symMap; + unsigned i,len; + unsigned nSyms,nSymsThisKey; + + if (((rep->present&XkbKeySymsMask)==0)||(rep->nKeySyms<1)|| + (!xkb)||(!xkb->map)||(!xkb->map->key_sym_map)) { + rep->present&= ~XkbKeySymsMask; + rep->firstKeySym= rep->nKeySyms= 0; + rep->totalSyms= 0; + return 0; + } + len= rep->nKeySyms*SIZEOF(xkbSymMapWireDesc); + symMap = &xkb->map->key_sym_map[rep->firstKeySym]; + for (i=nSyms=0;inKeySyms;i++,symMap++) { + if (symMap->offset!=0) { + nSymsThisKey= XkbNumGroups(symMap->group_info)*symMap->width; + nSyms+= nSymsThisKey; + } + } + len+= nSyms*4; + rep->totalSyms= nSyms; + return len; +} + +static int +XkbSizeVirtualMods(XkbDescPtr xkb,xkbGetMapReply *rep) +{ +register unsigned i,nMods,bit; + + if (((rep->present&XkbVirtualModsMask)==0)||(rep->virtualMods==0)|| + (!xkb)||(!xkb->server)) { + rep->present&= ~XkbVirtualModsMask; + rep->virtualMods= 0; + return 0; + } + for (i=nMods=0,bit=1;ivirtualMods&bit) + nMods++; + } + return XkbPaddedSize(nMods); +} + +static char * +XkbWriteKeySyms(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf,ClientPtr client) +{ +register KeySym * pSym; +XkbSymMapPtr symMap; +xkbSymMapWireDesc * outMap; +register unsigned i; + + symMap = &xkb->map->key_sym_map[rep->firstKeySym]; + for (i=0;inKeySyms;i++,symMap++) { + outMap = (xkbSymMapWireDesc *)buf; + outMap->ktIndex[0] = symMap->kt_index[0]; + outMap->ktIndex[1] = symMap->kt_index[1]; + outMap->ktIndex[2] = symMap->kt_index[2]; + outMap->ktIndex[3] = symMap->kt_index[3]; + outMap->groupInfo = symMap->group_info; + outMap->width= symMap->width; + outMap->nSyms = symMap->width*XkbNumGroups(symMap->group_info); + buf= (char *)&outMap[1]; + if (outMap->nSyms==0) + continue; + + pSym = &xkb->map->syms[symMap->offset]; + memcpy((char *)buf,(char *)pSym,outMap->nSyms*4); + if (client->swapped) { + register int n,nSyms= outMap->nSyms; + swaps(&outMap->nSyms,n); + while (nSyms-->0) { + swapl(buf,n); + buf+= 4; + } + } + else buf+= outMap->nSyms*4; + } + return buf; +} + +static int +XkbSizeKeyActions(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + unsigned i,len,nActs; + register KeyCode firstKey; + + if (((rep->present&XkbKeyActionsMask)==0)||(rep->nKeyActs<1)|| + (!xkb)||(!xkb->server)||(!xkb->server->key_acts)) { + rep->present&= ~XkbKeyActionsMask; + rep->firstKeyAct= rep->nKeyActs= 0; + rep->totalActs= 0; + return 0; + } + firstKey= rep->firstKeyAct; + for (nActs=i=0;inKeyActs;i++) { + if (xkb->server->key_acts[i+firstKey]!=0) + nActs+= XkbKeyNumActions(xkb,i+firstKey); + } + len= XkbPaddedSize(rep->nKeyActs)+(nActs*SIZEOF(xkbActionWireDesc)); + rep->totalActs= nActs; + return len; +} + +static char * +XkbWriteKeyActions(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, + ClientPtr client) +{ + unsigned i; + CARD8 * numDesc; + XkbAnyAction * actDesc; + + numDesc = (CARD8 *)buf; + for (i=0;inKeyActs;i++) { + if (xkb->server->key_acts[i+rep->firstKeyAct]==0) + numDesc[i] = 0; + else numDesc[i] = XkbKeyNumActions(xkb,(i+rep->firstKeyAct)); + } + buf+= XkbPaddedSize(rep->nKeyActs); + + actDesc = (XkbAnyAction *)buf; + for (i=0;inKeyActs;i++) { + if (xkb->server->key_acts[i+rep->firstKeyAct]!=0) { + unsigned int num; + num = XkbKeyNumActions(xkb,(i+rep->firstKeyAct)); + memcpy((char *)actDesc, + (char*)XkbKeyActionsPtr(xkb,(i+rep->firstKeyAct)), + num*SIZEOF(xkbActionWireDesc)); + actDesc+= num; + } + } + buf = (char *)actDesc; + return buf; +} + +static int +XkbSizeKeyBehaviors(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + unsigned i,len,nBhvr; + XkbBehavior * bhv; + + if (((rep->present&XkbKeyBehaviorsMask)==0)||(rep->nKeyBehaviors<1)|| + (!xkb)||(!xkb->server)||(!xkb->server->behaviors)) { + rep->present&= ~XkbKeyBehaviorsMask; + rep->firstKeyBehavior= rep->nKeyBehaviors= 0; + rep->totalKeyBehaviors= 0; + return 0; + } + bhv= &xkb->server->behaviors[rep->firstKeyBehavior]; + for (nBhvr=i=0;inKeyBehaviors;i++,bhv++) { + if (bhv->type!=XkbKB_Default) + nBhvr++; + } + len= nBhvr*SIZEOF(xkbBehaviorWireDesc); + rep->totalKeyBehaviors= nBhvr; + return len; +} + +static char * +XkbWriteKeyBehaviors(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, + ClientPtr client) +{ + unsigned i; + xkbBehaviorWireDesc *wire; + XkbBehavior *pBhvr; + + wire = (xkbBehaviorWireDesc *)buf; + pBhvr= &xkb->server->behaviors[rep->firstKeyBehavior]; + for (i=0;inKeyBehaviors;i++,pBhvr++) { + if (pBhvr->type!=XkbKB_Default) { + wire->key= i+rep->firstKeyBehavior; + wire->type= pBhvr->type; + wire->data= pBhvr->data; + wire++; + } + } + buf = (char *)wire; + return buf; +} + +static int +XkbSizeExplicit(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + unsigned i,len,nRtrn; + + if (((rep->present&XkbExplicitComponentsMask)==0)||(rep->nKeyExplicit<1)|| + (!xkb)||(!xkb->server)||(!xkb->server->explicit)) { + rep->present&= ~XkbExplicitComponentsMask; + rep->firstKeyExplicit= rep->nKeyExplicit= 0; + rep->totalKeyExplicit= 0; + return 0; + } + for (nRtrn=i=0;inKeyExplicit;i++) { + if (xkb->server->explicit[i+rep->firstKeyExplicit]!=0) + nRtrn++; + } + rep->totalKeyExplicit= nRtrn; + len= XkbPaddedSize(nRtrn*2); /* two bytes per non-zero explicit component */ + return len; +} + +static char * +XkbWriteExplicit(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf,ClientPtr client) +{ +unsigned i; +char * start; +unsigned char * pExp; + + start= buf; + pExp= &xkb->server->explicit[rep->firstKeyExplicit]; + for (i=0;inKeyExplicit;i++,pExp++) { + if (*pExp!=0) { + *buf++= i+rep->firstKeyExplicit; + *buf++= *pExp; + } + } + i= XkbPaddedSize(buf-start)-(buf-start); /* pad to word boundary */ + return buf+i; +} + +static int +XkbSizeModifierMap(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + unsigned i,len,nRtrn; + + if (((rep->present&XkbModifierMapMask)==0)||(rep->nModMapKeys<1)|| + (!xkb)||(!xkb->map)||(!xkb->map->modmap)) { + rep->present&= ~XkbModifierMapMask; + rep->firstModMapKey= rep->nModMapKeys= 0; + rep->totalModMapKeys= 0; + return 0; + } + for (nRtrn=i=0;inModMapKeys;i++) { + if (xkb->map->modmap[i+rep->firstModMapKey]!=0) + nRtrn++; + } + rep->totalModMapKeys= nRtrn; + len= XkbPaddedSize(nRtrn*2); /* two bytes per non-zero modmap component */ + return len; +} + +static char * +XkbWriteModifierMap(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, + ClientPtr client) +{ +unsigned i; +char * start; +unsigned char * pMap; + + start= buf; + pMap= &xkb->map->modmap[rep->firstModMapKey]; + for (i=0;inModMapKeys;i++,pMap++) { + if (*pMap!=0) { + *buf++= i+rep->firstModMapKey; + *buf++= *pMap; + } + } + i= XkbPaddedSize(buf-start)-(buf-start); /* pad to word boundary */ + return buf+i; +} + +static int +XkbSizeVirtualModMap(XkbDescPtr xkb,xkbGetMapReply *rep) +{ + unsigned i,len,nRtrn; + + if (((rep->present&XkbVirtualModMapMask)==0)||(rep->nVModMapKeys<1)|| + (!xkb)||(!xkb->server)||(!xkb->server->vmodmap)) { + rep->present&= ~XkbVirtualModMapMask; + rep->firstVModMapKey= rep->nVModMapKeys= 0; + rep->totalVModMapKeys= 0; + return 0; + } + for (nRtrn=i=0;inVModMapKeys;i++) { + if (xkb->server->vmodmap[i+rep->firstVModMapKey]!=0) + nRtrn++; + } + rep->totalVModMapKeys= nRtrn; + len= nRtrn*SIZEOF(xkbVModMapWireDesc); + return len; +} + +static char * +XkbWriteVirtualModMap(XkbDescPtr xkb,xkbGetMapReply *rep,char *buf, + ClientPtr client) +{ +unsigned i; +xkbVModMapWireDesc * wire; +unsigned short * pMap; + + wire= (xkbVModMapWireDesc *)buf; + pMap= &xkb->server->vmodmap[rep->firstVModMapKey]; + for (i=0;inVModMapKeys;i++,pMap++) { + if (*pMap!=0) { + wire->key= i+rep->firstVModMapKey; + wire->vmods= *pMap; + wire++; + } + } + return (char *)wire; +} + +static Status +XkbComputeGetMapReplySize(XkbDescPtr xkb,xkbGetMapReply *rep) +{ +int len; + + rep->minKeyCode= xkb->min_key_code; + rep->maxKeyCode= xkb->max_key_code; + len= XkbSizeKeyTypes(xkb,rep); + len+= XkbSizeKeySyms(xkb,rep); + len+= XkbSizeKeyActions(xkb,rep); + len+= XkbSizeKeyBehaviors(xkb,rep); + len+= XkbSizeVirtualMods(xkb,rep); + len+= XkbSizeExplicit(xkb,rep); + len+= XkbSizeModifierMap(xkb,rep); + len+= XkbSizeVirtualModMap(xkb,rep); + rep->length+= (len/4); + return Success; +} + +static int +XkbSendMap(ClientPtr client,XkbDescPtr xkb,xkbGetMapReply *rep) +{ +unsigned i,len; +char *desc,*start; + + len= (rep->length*4)-(SIZEOF(xkbGetMapReply)-SIZEOF(xGenericReply)); + start= desc= calloc(1, len); + if (!start) + return BadAlloc; + if ( rep->nTypes>0 ) + desc = XkbWriteKeyTypes(xkb,rep,desc,client); + if ( rep->nKeySyms>0 ) + desc = XkbWriteKeySyms(xkb,rep,desc,client); + if ( rep->nKeyActs>0 ) + desc = XkbWriteKeyActions(xkb,rep,desc,client); + if ( rep->totalKeyBehaviors>0 ) + desc = XkbWriteKeyBehaviors(xkb,rep,desc,client); + if ( rep->virtualMods ) { + register int sz,bit; + for (i=sz=0,bit=1;ivirtualMods&bit) { + desc[sz++]= xkb->server->vmods[i]; + } + } + desc+= XkbPaddedSize(sz); + } + if ( rep->totalKeyExplicit>0 ) + desc= XkbWriteExplicit(xkb,rep,desc,client); + if ( rep->totalModMapKeys>0 ) + desc= XkbWriteModifierMap(xkb,rep,desc,client); + if ( rep->totalVModMapKeys>0 ) + desc= XkbWriteVirtualModMap(xkb,rep,desc,client); + if ((desc-start)!=(len)) { + ErrorF("[xkb] BOGUS LENGTH in write keyboard desc, expected %d, got %ld\n", + len, (unsigned long)(desc-start)); + } + if (client->swapped) { + register int n; + swaps(&rep->sequenceNumber,n); + swapl(&rep->length,n); + swaps(&rep->present,n); + swaps(&rep->totalSyms,n); + swaps(&rep->totalActs,n); + } + WriteToClient(client, (i=SIZEOF(xkbGetMapReply)), (char *)rep); + WriteToClient(client, len, start); + free((char *)start); + return Success; +} + +int +ProcXkbGetMap(ClientPtr client) +{ + DeviceIntPtr dev; + xkbGetMapReply rep; + XkbDescRec *xkb; + int n,status; + + REQUEST(xkbGetMapReq); + REQUEST_SIZE_MATCH(xkbGetMapReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + CHK_MASK_OVERLAP(0x01,stuff->full,stuff->partial); + CHK_MASK_LEGAL(0x02,stuff->full,XkbAllMapComponentsMask); + CHK_MASK_LEGAL(0x03,stuff->partial,XkbAllMapComponentsMask); + + xkb= dev->key->xkbInfo->desc; + memset(&rep, 0, sizeof(xkbGetMapReply)); + rep.type= X_Reply; + rep.sequenceNumber= client->sequence; + rep.length = (SIZEOF(xkbGetMapReply)-SIZEOF(xGenericReply))>>2; + rep.deviceID = dev->id; + rep.present = stuff->partial|stuff->full; + rep.minKeyCode = xkb->min_key_code; + rep.maxKeyCode = xkb->max_key_code; + if ( stuff->full&XkbKeyTypesMask ) { + rep.firstType = 0; + rep.nTypes = xkb->map->num_types; + } + else if (stuff->partial&XkbKeyTypesMask) { + if (((unsigned)stuff->firstType+stuff->nTypes)>xkb->map->num_types) { + client->errorValue = _XkbErrCode4(0x04,xkb->map->num_types, + stuff->firstType,stuff->nTypes); + return BadValue; + } + rep.firstType = stuff->firstType; + rep.nTypes = stuff->nTypes; + } + else rep.nTypes = 0; + rep.totalTypes = xkb->map->num_types; + + n= XkbNumKeys(xkb); + if ( stuff->full&XkbKeySymsMask ) { + rep.firstKeySym = xkb->min_key_code; + rep.nKeySyms = n; + } + else if (stuff->partial&XkbKeySymsMask) { + CHK_KEY_RANGE(0x05,stuff->firstKeySym,stuff->nKeySyms,xkb); + rep.firstKeySym = stuff->firstKeySym; + rep.nKeySyms = stuff->nKeySyms; + } + else rep.nKeySyms = 0; + rep.totalSyms= 0; + + if ( stuff->full&XkbKeyActionsMask ) { + rep.firstKeyAct= xkb->min_key_code; + rep.nKeyActs= n; + } + else if (stuff->partial&XkbKeyActionsMask) { + CHK_KEY_RANGE(0x07,stuff->firstKeyAct,stuff->nKeyActs,xkb); + rep.firstKeyAct= stuff->firstKeyAct; + rep.nKeyActs= stuff->nKeyActs; + } + else rep.nKeyActs= 0; + rep.totalActs= 0; + + if ( stuff->full&XkbKeyBehaviorsMask ) { + rep.firstKeyBehavior = xkb->min_key_code; + rep.nKeyBehaviors = n; + } + else if (stuff->partial&XkbKeyBehaviorsMask) { + CHK_KEY_RANGE(0x09,stuff->firstKeyBehavior,stuff->nKeyBehaviors,xkb); + rep.firstKeyBehavior= stuff->firstKeyBehavior; + rep.nKeyBehaviors= stuff->nKeyBehaviors; + } + else rep.nKeyBehaviors = 0; + rep.totalKeyBehaviors= 0; + + if (stuff->full&XkbVirtualModsMask) + rep.virtualMods= ~0; + else if (stuff->partial&XkbVirtualModsMask) + rep.virtualMods= stuff->virtualMods; + + if (stuff->full&XkbExplicitComponentsMask) { + rep.firstKeyExplicit= xkb->min_key_code; + rep.nKeyExplicit= n; + } + else if (stuff->partial&XkbExplicitComponentsMask) { + CHK_KEY_RANGE(0x0B,stuff->firstKeyExplicit,stuff->nKeyExplicit,xkb); + rep.firstKeyExplicit= stuff->firstKeyExplicit; + rep.nKeyExplicit= stuff->nKeyExplicit; + } + else rep.nKeyExplicit = 0; + rep.totalKeyExplicit= 0; + + if (stuff->full&XkbModifierMapMask) { + rep.firstModMapKey= xkb->min_key_code; + rep.nModMapKeys= n; + } + else if (stuff->partial&XkbModifierMapMask) { + CHK_KEY_RANGE(0x0D,stuff->firstModMapKey,stuff->nModMapKeys,xkb); + rep.firstModMapKey= stuff->firstModMapKey; + rep.nModMapKeys= stuff->nModMapKeys; + } + else rep.nModMapKeys = 0; + rep.totalModMapKeys= 0; + + if (stuff->full&XkbVirtualModMapMask) { + rep.firstVModMapKey= xkb->min_key_code; + rep.nVModMapKeys= n; + } + else if (stuff->partial&XkbVirtualModMapMask) { + CHK_KEY_RANGE(0x0F,stuff->firstVModMapKey,stuff->nVModMapKeys,xkb); + rep.firstVModMapKey= stuff->firstVModMapKey; + rep.nVModMapKeys= stuff->nVModMapKeys; + } + else rep.nVModMapKeys = 0; + rep.totalVModMapKeys= 0; + + if ((status=XkbComputeGetMapReplySize(xkb,&rep))!=Success) + return status; + return XkbSendMap(client,xkb,&rep); +} + +/***====================================================================***/ + +static int +CheckKeyTypes( ClientPtr client, + XkbDescPtr xkb, + xkbSetMapReq * req, + xkbKeyTypeWireDesc **wireRtrn, + int * nMapsRtrn, + CARD8 * mapWidthRtrn) +{ +unsigned nMaps; +register unsigned i,n; +register CARD8 * map; +register xkbKeyTypeWireDesc *wire = *wireRtrn; + + if (req->firstType>((unsigned)xkb->map->num_types)) { + *nMapsRtrn = _XkbErrCode3(0x01,req->firstType,xkb->map->num_types); + return 0; + } + if (req->flags&XkbSetMapResizeTypes) { + nMaps = req->firstType+req->nTypes; + if (nMapsfirstType,req->nTypes,4); + return 0; + } + } + else if (req->present&XkbKeyTypesMask) { + nMaps = xkb->map->num_types; + if ((req->firstType+req->nTypes)>nMaps) { + *nMapsRtrn = req->firstType+req->nTypes; + return 0; + } + } + else { + *nMapsRtrn = xkb->map->num_types; + for (i=0;imap->num_types;i++) { + mapWidthRtrn[i] = xkb->map->types[i].num_levels; + } + return 1; + } + + for (i=0;ifirstType;i++) { + mapWidthRtrn[i] = xkb->map->types[i].num_levels; + } + for (i=0;inTypes;i++) { + unsigned width; + if (client->swapped) { + register int s; + swaps(&wire->virtualMods,s); + } + n= i+req->firstType; + width= wire->numLevels; + if (width<1) { + *nMapsRtrn= _XkbErrCode3(0x04,n,width); + return 0; + } + else if ((n==XkbOneLevelIndex)&&(width!=1)) { /* must be width 1 */ + *nMapsRtrn= _XkbErrCode3(0x05,n,width); + return 0; + } + else if ((width!=2)&& + ((n==XkbTwoLevelIndex)||(n==XkbKeypadIndex)|| + (n==XkbAlphabeticIndex))) { + /* TWO_LEVEL, ALPHABETIC and KEYPAD must be width 2 */ + *nMapsRtrn= _XkbErrCode3(0x05,n,width); + return 0; + } + if (wire->nMapEntries>0) { + xkbKTSetMapEntryWireDesc * mapWire; + xkbModsWireDesc * preWire; + mapWire= (xkbKTSetMapEntryWireDesc *)&wire[1]; + preWire= (xkbModsWireDesc *)&mapWire[wire->nMapEntries]; + for (n=0;nnMapEntries;n++) { + if (client->swapped) { + register int s; + swaps(&mapWire[n].virtualMods,s); + } + if (mapWire[n].realMods&(~wire->realMods)) { + *nMapsRtrn= _XkbErrCode4(0x06,n,mapWire[n].realMods, + wire->realMods); + return 0; + } + if (mapWire[n].virtualMods&(~wire->virtualMods)) { + *nMapsRtrn= _XkbErrCode3(0x07,n,mapWire[n].virtualMods); + return 0; + } + if (mapWire[n].level>=wire->numLevels) { + *nMapsRtrn= _XkbErrCode4(0x08,n,wire->numLevels, + mapWire[n].level); + return 0; + } + if (wire->preserve) { + if (client->swapped) { + register int s; + swaps(&preWire[n].virtualMods,s); + } + if (preWire[n].realMods&(~mapWire[n].realMods)) { + *nMapsRtrn= _XkbErrCode4(0x09,n,preWire[n].realMods, + mapWire[n].realMods); + return 0; + } + if (preWire[n].virtualMods&(~mapWire[n].virtualMods)) { + *nMapsRtrn=_XkbErrCode3(0x0a,n,preWire[n].virtualMods); + return 0; + } + } + } + if (wire->preserve) + map= (CARD8 *)&preWire[wire->nMapEntries]; + else map= (CARD8 *)&mapWire[wire->nMapEntries]; + } + else map= (CARD8 *)&wire[1]; + mapWidthRtrn[i+req->firstType] = wire->numLevels; + wire= (xkbKeyTypeWireDesc *)map; + } + for (i=req->firstType+req->nTypes;imap->types[i].num_levels; + } + *nMapsRtrn = nMaps; + *wireRtrn = wire; + return 1; +} + +static int +CheckKeySyms( ClientPtr client, + XkbDescPtr xkb, + xkbSetMapReq * req, + int nTypes, + CARD8 * mapWidths, + CARD16 * symsPerKey, + xkbSymMapWireDesc ** wireRtrn, + int * errorRtrn) +{ +register unsigned i; +XkbSymMapPtr map; +xkbSymMapWireDesc* wire = *wireRtrn; + + if (!(XkbKeySymsMask&req->present)) + return 1; + CHK_REQ_KEY_RANGE2(0x11,req->firstKeySym,req->nKeySyms,req,(*errorRtrn),0); + for (i=0;inKeySyms;i++) { + KeySym *pSyms; + register unsigned nG; + if (client->swapped) { + swaps(&wire->nSyms,nG); + } + nG = XkbNumGroups(wire->groupInfo); + if (nG>XkbNumKbdGroups) { + *errorRtrn = _XkbErrCode3(0x14,i+req->firstKeySym,nG); + return 0; + } + if (nG>0) { + register int g,w; + for (g=w=0;gktIndex[g]>=(unsigned)nTypes) { + *errorRtrn= _XkbErrCode4(0x15,i+req->firstKeySym,g, + wire->ktIndex[g]); + return 0; + } + if (mapWidths[wire->ktIndex[g]]>w) + w= mapWidths[wire->ktIndex[g]]; + } + if (wire->width!=w) { + *errorRtrn= _XkbErrCode3(0x16,i+req->firstKeySym,wire->width); + return 0; + } + w*= nG; + symsPerKey[i+req->firstKeySym] = w; + if (w!=wire->nSyms) { + *errorRtrn=_XkbErrCode4(0x16,i+req->firstKeySym,wire->nSyms,w); + return 0; + } + } + else if (wire->nSyms!=0) { + *errorRtrn = _XkbErrCode3(0x17,i+req->firstKeySym,wire->nSyms); + return 0; + } + pSyms = (KeySym *)&wire[1]; + wire = (xkbSymMapWireDesc *)&pSyms[wire->nSyms]; + } + + map = &xkb->map->key_sym_map[i]; + for (;i<=(unsigned)xkb->max_key_code;i++,map++) { + register int g,nG,w; + nG= XkbKeyNumGroups(xkb,i); + for (w=g=0;gkt_index[g]>=(unsigned)nTypes) { + *errorRtrn = _XkbErrCode4(0x18,i,g,map->kt_index[g]); + return 0; + } + if (mapWidths[map->kt_index[g]]>w) + w= mapWidths[map->kt_index[g]]; + } + symsPerKey[i] = w*nG; + } + *wireRtrn = wire; + return 1; +} + +static int +CheckKeyActions( XkbDescPtr xkb, + xkbSetMapReq * req, + int nTypes, + CARD8 * mapWidths, + CARD16 * symsPerKey, + CARD8 ** wireRtrn, + int * nActsRtrn) +{ +int nActs; +CARD8 * wire = *wireRtrn; +register unsigned i; + + if (!(XkbKeyActionsMask&req->present)) + return 1; + CHK_REQ_KEY_RANGE2(0x21,req->firstKeyAct,req->nKeyActs,req,(*nActsRtrn),0); + for (nActs=i=0;inKeyActs;i++) { + if (wire[0]!=0) { + if (wire[0]==symsPerKey[i+req->firstKeyAct]) + nActs+= wire[0]; + else { + *nActsRtrn= _XkbErrCode3(0x23,i+req->firstKeyAct,wire[0]); + return 0; + } + } + wire++; + } + if (req->nKeyActs%4) + wire+= 4-(req->nKeyActs%4); + *wireRtrn = (CARD8 *)(((XkbAnyAction *)wire)+nActs); + *nActsRtrn = nActs; + return 1; +} + +static int +CheckKeyBehaviors( XkbDescPtr xkb, + xkbSetMapReq * req, + xkbBehaviorWireDesc ** wireRtrn, + int * errorRtrn) +{ +register xkbBehaviorWireDesc * wire = *wireRtrn; +register XkbServerMapPtr server = xkb->server; +register unsigned i; +unsigned first,last; + + if (((req->present&XkbKeyBehaviorsMask)==0)||(req->nKeyBehaviors<1)) { + req->present&= ~XkbKeyBehaviorsMask; + req->nKeyBehaviors= 0; + return 1; + } + first= req->firstKeyBehavior; + last= req->firstKeyBehavior+req->nKeyBehaviors-1; + if (firstminKeyCode) { + *errorRtrn = _XkbErrCode3(0x31,first,req->minKeyCode); + return 0; + } + if (last>req->maxKeyCode) { + *errorRtrn = _XkbErrCode3(0x32,last,req->maxKeyCode); + return 0; + } + + for (i=0;itotalKeyBehaviors;i++,wire++) { + if ((wire->keykey>last)) { + *errorRtrn = _XkbErrCode4(0x33,first,last,wire->key); + return 0; + } + if ((wire->type&XkbKB_Permanent)&& + ((server->behaviors[wire->key].type!=wire->type)|| + (server->behaviors[wire->key].data!=wire->data))) { + *errorRtrn = _XkbErrCode3(0x33,wire->key,wire->type); + return 0; + } + if ((wire->type==XkbKB_RadioGroup)&& + ((wire->data&(~XkbKB_RGAllowNone))>XkbMaxRadioGroups)) { + *errorRtrn= _XkbErrCode4(0x34,wire->key,wire->data, + XkbMaxRadioGroups); + return 0; + } + if ((wire->type==XkbKB_Overlay1)||(wire->type==XkbKB_Overlay2)) { + CHK_KEY_RANGE2(0x35,wire->key,1,xkb,*errorRtrn,0); + } + } + *wireRtrn = wire; + return 1; +} + +static int +CheckVirtualMods( XkbDescRec * xkb, + xkbSetMapReq * req, + CARD8 ** wireRtrn, + int * errorRtrn) +{ +register CARD8 *wire = *wireRtrn; +register unsigned i,nMods,bit; + + if (((req->present&XkbVirtualModsMask)==0)||(req->virtualMods==0)) + return 1; + for (i=nMods=0,bit=1;ivirtualMods&bit) + nMods++; + } + *wireRtrn= (wire+XkbPaddedSize(nMods)); + return 1; +} + +static int +CheckKeyExplicit( XkbDescPtr xkb, + xkbSetMapReq * req, + CARD8 ** wireRtrn, + int * errorRtrn) +{ +register CARD8 * wire = *wireRtrn; +CARD8 * start; +register unsigned i; +int first,last; + + if (((req->present&XkbExplicitComponentsMask)==0)||(req->nKeyExplicit<1)) { + req->present&= ~XkbExplicitComponentsMask; + req->nKeyExplicit= 0; + return 1; + } + first= req->firstKeyExplicit; + last= first+req->nKeyExplicit-1; + if (firstminKeyCode) { + *errorRtrn = _XkbErrCode3(0x51,first,req->minKeyCode); + return 0; + } + if (last>req->maxKeyCode) { + *errorRtrn = _XkbErrCode3(0x52,last,req->maxKeyCode); + return 0; + } + start= wire; + for (i=0;itotalKeyExplicit;i++,wire+=2) { + if ((wire[0]last)) { + *errorRtrn = _XkbErrCode4(0x53,first,last,wire[0]); + return 0; + } + if (wire[1]&(~XkbAllExplicitMask)) { + *errorRtrn= _XkbErrCode3(0x52,~XkbAllExplicitMask,wire[1]); + return 0; + } + } + wire+= XkbPaddedSize(wire-start)-(wire-start); + *wireRtrn= wire; + return 1; +} + +static int +CheckModifierMap(XkbDescPtr xkb,xkbSetMapReq *req,CARD8 **wireRtrn,int *errRtrn) +{ +register CARD8 * wire = *wireRtrn; +CARD8 * start; +register unsigned i; +int first,last; + + if (((req->present&XkbModifierMapMask)==0)||(req->nModMapKeys<1)) { + req->present&= ~XkbModifierMapMask; + req->nModMapKeys= 0; + return 1; + } + first= req->firstModMapKey; + last= first+req->nModMapKeys-1; + if (firstminKeyCode) { + *errRtrn = _XkbErrCode3(0x61,first,req->minKeyCode); + return 0; + } + if (last>req->maxKeyCode) { + *errRtrn = _XkbErrCode3(0x62,last,req->maxKeyCode); + return 0; + } + start= wire; + for (i=0;itotalModMapKeys;i++,wire+=2) { + if ((wire[0]last)) { + *errRtrn = _XkbErrCode4(0x63,first,last,wire[0]); + return 0; + } + } + wire+= XkbPaddedSize(wire-start)-(wire-start); + *wireRtrn= wire; + return 1; +} + +static int +CheckVirtualModMap( XkbDescPtr xkb, + xkbSetMapReq *req, + xkbVModMapWireDesc **wireRtrn, + int *errRtrn) +{ +register xkbVModMapWireDesc * wire = *wireRtrn; +register unsigned i; +int first,last; + + if (((req->present&XkbVirtualModMapMask)==0)||(req->nVModMapKeys<1)) { + req->present&= ~XkbVirtualModMapMask; + req->nVModMapKeys= 0; + return 1; + } + first= req->firstVModMapKey; + last= first+req->nVModMapKeys-1; + if (firstminKeyCode) { + *errRtrn = _XkbErrCode3(0x71,first,req->minKeyCode); + return 0; + } + if (last>req->maxKeyCode) { + *errRtrn = _XkbErrCode3(0x72,last,req->maxKeyCode); + return 0; + } + for (i=0;itotalVModMapKeys;i++,wire++) { + if ((wire->keykey>last)) { + *errRtrn = _XkbErrCode4(0x73,first,last,wire->key); + return 0; + } + } + *wireRtrn= wire; + return 1; +} + +static char * +SetKeyTypes( XkbDescPtr xkb, + xkbSetMapReq * req, + xkbKeyTypeWireDesc * wire, + XkbChangesPtr changes) +{ +register unsigned i; +unsigned first,last; +CARD8 *map; + + if ((unsigned)(req->firstType+req->nTypes)>xkb->map->size_types) { + i= req->firstType+req->nTypes; + if (XkbAllocClientMap(xkb,XkbKeyTypesMask,i)!=Success) { + return NULL; + } + } + if ((unsigned)(req->firstType+req->nTypes)>xkb->map->num_types) + xkb->map->num_types= req->firstType+req->nTypes; + + for (i=0;inTypes;i++) { + XkbKeyTypePtr pOld; + register unsigned n; + + if (XkbResizeKeyType(xkb,i+req->firstType,wire->nMapEntries, + wire->preserve,wire->numLevels)!=Success) { + return NULL; + } + pOld = &xkb->map->types[i+req->firstType]; + map = (CARD8 *)&wire[1]; + + pOld->mods.real_mods = wire->realMods; + pOld->mods.vmods= wire->virtualMods; + pOld->num_levels = wire->numLevels; + pOld->map_count= wire->nMapEntries; + + pOld->mods.mask= pOld->mods.real_mods| + XkbMaskForVMask(xkb,pOld->mods.vmods); + + if (wire->nMapEntries) { + xkbKTSetMapEntryWireDesc *mapWire; + xkbModsWireDesc *preWire; + unsigned tmp; + mapWire= (xkbKTSetMapEntryWireDesc *)map; + preWire= (xkbModsWireDesc *)&mapWire[wire->nMapEntries]; + for (n=0;nnMapEntries;n++) { + pOld->map[n].active= 1; + pOld->map[n].mods.mask= mapWire[n].realMods; + pOld->map[n].mods.real_mods= mapWire[n].realMods; + pOld->map[n].mods.vmods= mapWire[n].virtualMods; + pOld->map[n].level= mapWire[n].level; + if (mapWire[n].virtualMods!=0) { + tmp= XkbMaskForVMask(xkb,mapWire[n].virtualMods); + pOld->map[n].active= (tmp!=0); + pOld->map[n].mods.mask|= tmp; + } + if (wire->preserve) { + pOld->preserve[n].real_mods= preWire[n].realMods; + pOld->preserve[n].vmods= preWire[n].virtualMods; + tmp= XkbMaskForVMask(xkb,preWire[n].virtualMods); + pOld->preserve[n].mask= preWire[n].realMods|tmp; + } + } + if (wire->preserve) + map= (CARD8 *)&preWire[wire->nMapEntries]; + else map= (CARD8 *)&mapWire[wire->nMapEntries]; + } + else map= (CARD8 *)&wire[1]; + wire = (xkbKeyTypeWireDesc *)map; + } + first= req->firstType; + last= first+req->nTypes-1; /* last changed type */ + if (changes->map.changed&XkbKeyTypesMask) { + int oldLast; + oldLast= changes->map.first_type+changes->map.num_types-1; + if (changes->map.first_typemap.first_type; + if (oldLast>last) + last= oldLast; + } + changes->map.changed|= XkbKeyTypesMask; + changes->map.first_type = first; + changes->map.num_types = (last-first)+1; + return (char *)wire; +} + +static char * +SetKeySyms( ClientPtr client, + XkbDescPtr xkb, + xkbSetMapReq * req, + xkbSymMapWireDesc * wire, + XkbChangesPtr changes, + DeviceIntPtr dev) +{ +register unsigned i,s; +XkbSymMapPtr oldMap; +KeySym * newSyms; +KeySym * pSyms; +unsigned first,last; + + oldMap = &xkb->map->key_sym_map[req->firstKeySym]; + for (i=0;inKeySyms;i++,oldMap++) { + pSyms = (KeySym *)&wire[1]; + if (wire->nSyms>0) { + newSyms = XkbResizeKeySyms(xkb,i+req->firstKeySym,wire->nSyms); + for (s=0;snSyms;s++) { + newSyms[s]= pSyms[s]; + } + if (client->swapped) { + int n; + for (s=0;snSyms;s++) { + swapl(&newSyms[s],n); + } + } + } + oldMap->kt_index[0] = wire->ktIndex[0]; + oldMap->kt_index[1] = wire->ktIndex[1]; + oldMap->kt_index[2] = wire->ktIndex[2]; + oldMap->kt_index[3] = wire->ktIndex[3]; + oldMap->group_info = wire->groupInfo; + oldMap->width = wire->width; + wire= (xkbSymMapWireDesc *)&pSyms[wire->nSyms]; + } + first= req->firstKeySym; + last= first+req->nKeySyms-1; + if (changes->map.changed&XkbKeySymsMask) { + int oldLast= (changes->map.first_key_sym+changes->map.num_key_syms-1); + if (changes->map.first_key_symmap.first_key_sym; + if (oldLast>last) + last= oldLast; + } + changes->map.changed|= XkbKeySymsMask; + changes->map.first_key_sym = first; + changes->map.num_key_syms = (last-first+1); + + s= 0; + for (i=xkb->min_key_code;i<=xkb->max_key_code;i++) { + if (XkbKeyNumGroups(xkb,i)>s) + s= XkbKeyNumGroups(xkb,i); + } + if (s!=xkb->ctrls->num_groups) { + xkbControlsNotify cn; + XkbControlsRec old; + cn.keycode= 0; + cn.eventType= 0; + cn.requestMajor= XkbReqCode; + cn.requestMinor= X_kbSetMap; + old= *xkb->ctrls; + xkb->ctrls->num_groups= s; + if (XkbComputeControlsNotify(dev,&old,xkb->ctrls,&cn,FALSE)) + XkbSendControlsNotify(dev,&cn); + } + return (char *)wire; +} + +static char * +SetKeyActions( XkbDescPtr xkb, + xkbSetMapReq * req, + CARD8 * wire, + XkbChangesPtr changes) +{ +register unsigned i,first,last; +CARD8 * nActs = wire; +XkbAction * newActs; + + wire+= XkbPaddedSize(req->nKeyActs); + for (i=0;inKeyActs;i++) { + if (nActs[i]==0) + xkb->server->key_acts[i+req->firstKeyAct]= 0; + else { + newActs= XkbResizeKeyActions(xkb,i+req->firstKeyAct,nActs[i]); + memcpy((char *)newActs,(char *)wire, + nActs[i]*SIZEOF(xkbActionWireDesc)); + wire+= nActs[i]*SIZEOF(xkbActionWireDesc); + } + } + first= req->firstKeyAct; + last= (first+req->nKeyActs-1); + if (changes->map.changed&XkbKeyActionsMask) { + int oldLast; + oldLast= changes->map.first_key_act+changes->map.num_key_acts-1; + if (changes->map.first_key_actmap.first_key_act; + if (oldLast>last) + last= oldLast; + } + changes->map.changed|= XkbKeyActionsMask; + changes->map.first_key_act= first; + changes->map.num_key_acts= (last-first+1); + return (char *)wire; +} + +static char * +SetKeyBehaviors( XkbSrvInfoPtr xkbi, + xkbSetMapReq *req, + xkbBehaviorWireDesc *wire, + XkbChangesPtr changes) +{ +register unsigned i; +int maxRG = -1; +XkbDescPtr xkb = xkbi->desc; +XkbServerMapPtr server = xkb->server; +unsigned first,last; + + first= req->firstKeyBehavior; + last= req->firstKeyBehavior+req->nKeyBehaviors-1; + memset(&server->behaviors[first], 0, req->nKeyBehaviors*sizeof(XkbBehavior)); + for (i=0;itotalKeyBehaviors;i++) { + if ((server->behaviors[wire->key].type&XkbKB_Permanent)==0) { + server->behaviors[wire->key].type= wire->type; + server->behaviors[wire->key].data= wire->data; + if ((wire->type==XkbKB_RadioGroup)&&(((int)wire->data)>maxRG)) + maxRG= wire->data + 1; + } + wire++; + } + + if (maxRG>(int)xkbi->nRadioGroups) { + int sz = maxRG*sizeof(XkbRadioGroupRec); + if (xkbi->radioGroups) + xkbi->radioGroups= realloc(xkbi->radioGroups,sz); + else xkbi->radioGroups= calloc(1, sz); + if (xkbi->radioGroups) { + if (xkbi->nRadioGroups) + memset(&xkbi->radioGroups[xkbi->nRadioGroups], 0, + (maxRG-xkbi->nRadioGroups)*sizeof(XkbRadioGroupRec)); + xkbi->nRadioGroups= maxRG; + } + else xkbi->nRadioGroups= 0; + /* should compute members here */ + } + if (changes->map.changed&XkbKeyBehaviorsMask) { + unsigned oldLast; + oldLast= changes->map.first_key_behavior+ + changes->map.num_key_behaviors-1; + if (changes->map.first_key_behaviorfirstKeyBehavior) + first= changes->map.first_key_behavior; + if (oldLast>last) + last= oldLast; + } + changes->map.changed|= XkbKeyBehaviorsMask; + changes->map.first_key_behavior = first; + changes->map.num_key_behaviors = (last-first+1); + return (char *)wire; +} + +static char * +SetVirtualMods(XkbSrvInfoPtr xkbi,xkbSetMapReq *req,CARD8 *wire, + XkbChangesPtr changes) +{ +register int i,bit,nMods; +XkbServerMapPtr srv = xkbi->desc->server; + + if (((req->present&XkbVirtualModsMask)==0)||(req->virtualMods==0)) + return (char *)wire; + for (i=nMods=0,bit=1;ivirtualMods&bit) { + if (srv->vmods[i]!=wire[nMods]) { + changes->map.changed|= XkbVirtualModsMask; + changes->map.vmods|= bit; + srv->vmods[i]= wire[nMods]; + } + nMods++; + } + } + return (char *)(wire+XkbPaddedSize(nMods)); +} + +static char * +SetKeyExplicit(XkbSrvInfoPtr xkbi,xkbSetMapReq *req,CARD8 *wire, + XkbChangesPtr changes) +{ +register unsigned i,first,last; +XkbServerMapPtr xkb = xkbi->desc->server; +CARD8 * start; + + start= wire; + first= req->firstKeyExplicit; + last= req->firstKeyExplicit+req->nKeyExplicit-1; + memset(&xkb->explicit[first], 0, req->nKeyExplicit); + for (i=0;itotalKeyExplicit;i++,wire+= 2) { + xkb->explicit[wire[0]]= wire[1]; + } + if (first>0) { + if (changes->map.changed&XkbExplicitComponentsMask) { + int oldLast; + oldLast= changes->map.first_key_explicit+ + changes->map.num_key_explicit-1; + if (changes->map.first_key_explicitmap.first_key_explicit; + if (oldLast>last) + last= oldLast; + } + changes->map.first_key_explicit= first; + changes->map.num_key_explicit= (last-first)+1; + } + wire+= XkbPaddedSize(wire-start)-(wire-start); + return (char *)wire; +} + +static char * +SetModifierMap( XkbSrvInfoPtr xkbi, + xkbSetMapReq * req, + CARD8 * wire, + XkbChangesPtr changes) +{ +register unsigned i,first,last; +XkbClientMapPtr xkb = xkbi->desc->map; +CARD8 * start; + + start= wire; + first= req->firstModMapKey; + last= req->firstModMapKey+req->nModMapKeys-1; + memset(&xkb->modmap[first], 0, req->nModMapKeys); + for (i=0;itotalModMapKeys;i++,wire+= 2) { + xkb->modmap[wire[0]]= wire[1]; + } + if (first>0) { + if (changes->map.changed&XkbModifierMapMask) { + int oldLast; + oldLast= changes->map.first_modmap_key+ + changes->map.num_modmap_keys-1; + if (changes->map.first_modmap_keymap.first_modmap_key; + if (oldLast>last) + last= oldLast; + } + changes->map.first_modmap_key= first; + changes->map.num_modmap_keys= (last-first)+1; + } + wire+= XkbPaddedSize(wire-start)-(wire-start); + return (char *)wire; +} + +static char * +SetVirtualModMap( XkbSrvInfoPtr xkbi, + xkbSetMapReq * req, + xkbVModMapWireDesc * wire, + XkbChangesPtr changes) +{ +register unsigned i,first,last; +XkbServerMapPtr srv = xkbi->desc->server; + + first= req->firstVModMapKey; + last= req->firstVModMapKey+req->nVModMapKeys-1; + memset(&srv->vmodmap[first], 0, req->nVModMapKeys*sizeof(unsigned short)); + for (i=0;itotalVModMapKeys;i++,wire++) { + srv->vmodmap[wire->key]= wire->vmods; + } + if (first>0) { + if (changes->map.changed&XkbVirtualModMapMask) { + int oldLast; + oldLast= changes->map.first_vmodmap_key+ + changes->map.num_vmodmap_keys-1; + if (changes->map.first_vmodmap_keymap.first_vmodmap_key; + if (oldLast>last) + last= oldLast; + } + changes->map.first_vmodmap_key= first; + changes->map.num_vmodmap_keys= (last-first)+1; + } + return (char *)wire; +} + +/** + * Check if the given request can be applied to the given device but don't + * actually do anything.. + */ +static int +_XkbSetMapChecks(ClientPtr client, DeviceIntPtr dev, xkbSetMapReq *req, char* values) +{ + XkbSrvInfoPtr xkbi; + XkbDescPtr xkb; + int error; + int nTypes = 0, nActions; + CARD8 mapWidths[XkbMaxLegalKeyCode + 1] = {0}; + CARD16 symsPerKey[XkbMaxLegalKeyCode + 1] = {0}; + XkbSymMapPtr map; + int i; + + xkbi= dev->key->xkbInfo; + xkb = xkbi->desc; + + if ((xkb->min_key_code != req->minKeyCode)|| + (xkb->max_key_code != req->maxKeyCode)) { + if (client->vMajor!=1) { /* pre 1.0 versions of Xlib have a bug */ + req->minKeyCode= xkb->min_key_code; + req->maxKeyCode= xkb->max_key_code; + } + else { + if (!XkbIsLegalKeycode(req->minKeyCode)) { + client->errorValue = _XkbErrCode3(2, req->minKeyCode, req->maxKeyCode); + return BadValue; + } + if (req->minKeyCode > req->maxKeyCode) { + client->errorValue = _XkbErrCode3(3, req->minKeyCode, req->maxKeyCode); + return BadMatch; + } + } + } + + if ((req->present & XkbKeyTypesMask) && + (!CheckKeyTypes(client,xkb,req,(xkbKeyTypeWireDesc **)&values, + &nTypes,mapWidths))) { + client->errorValue = nTypes; + return BadValue; + } + + /* symsPerKey/mapWidths must be filled regardless of client-side flags */ + map = &xkb->map->key_sym_map[xkb->min_key_code]; + for (i=xkb->min_key_code;imax_key_code;i++,map++) { + register int g,ng,w; + ng= XkbNumGroups(map->group_info); + for (w=g=0;gkt_index[g]>=(unsigned)nTypes) { + client->errorValue = _XkbErrCode4(0x13,i,g,map->kt_index[g]); + return 0; + } + if (mapWidths[map->kt_index[g]]>w) + w= mapWidths[map->kt_index[g]]; + } + symsPerKey[i] = w*ng; + } + + if ((req->present & XkbKeySymsMask) && + (!CheckKeySyms(client,xkb,req,nTypes,mapWidths,symsPerKey, + (xkbSymMapWireDesc **)&values,&error))) { + client->errorValue = error; + return BadValue; + } + + if ((req->present & XkbKeyActionsMask) && + (!CheckKeyActions(xkb,req,nTypes,mapWidths,symsPerKey, + (CARD8 **)&values,&nActions))) { + client->errorValue = nActions; + return BadValue; + } + + if ((req->present & XkbKeyBehaviorsMask) && + (!CheckKeyBehaviors(xkb,req,(xkbBehaviorWireDesc**)&values,&error))) { + client->errorValue = error; + return BadValue; + } + + if ((req->present & XkbVirtualModsMask) && + (!CheckVirtualMods(xkb,req,(CARD8 **)&values,&error))) { + client->errorValue= error; + return BadValue; + } + if ((req->present&XkbExplicitComponentsMask) && + (!CheckKeyExplicit(xkb,req,(CARD8 **)&values,&error))) { + client->errorValue= error; + return BadValue; + } + if ((req->present&XkbModifierMapMask) && + (!CheckModifierMap(xkb,req,(CARD8 **)&values,&error))) { + client->errorValue= error; + return BadValue; + } + if ((req->present&XkbVirtualModMapMask) && + (!CheckVirtualModMap(xkb,req,(xkbVModMapWireDesc **)&values,&error))) { + client->errorValue= error; + return BadValue; + } + + if (((values-((char *)req))/4)!= req->length) { + ErrorF("[xkb] Internal error! Bad length in XkbSetMap (after check)\n"); + client->errorValue = values-((char *)&req[1]); + return BadLength; + } + + return Success; +} + +/** + * Apply the given request on the given device. + */ +static int +_XkbSetMap(ClientPtr client, DeviceIntPtr dev, xkbSetMapReq *req, char *values) +{ + XkbEventCauseRec cause; + XkbChangesRec change; + Bool sentNKN; + XkbSrvInfoPtr xkbi; + XkbDescPtr xkb; + + xkbi= dev->key->xkbInfo; + xkb = xkbi->desc; + + XkbSetCauseXkbReq(&cause,X_kbSetMap,client); + memset(&change, 0, sizeof(change)); + sentNKN = FALSE; + if ((xkb->min_key_code!=req->minKeyCode)|| + (xkb->max_key_code!=req->maxKeyCode)) { + Status status; + xkbNewKeyboardNotify nkn; + nkn.deviceID = nkn.oldDeviceID = dev->id; + nkn.oldMinKeyCode = xkb->min_key_code; + nkn.oldMaxKeyCode = xkb->max_key_code; + status= XkbChangeKeycodeRange(xkb, req->minKeyCode, + req->maxKeyCode, &change); + if (status != Success) + return status; /* oh-oh. what about the other keyboards? */ + nkn.minKeyCode = xkb->min_key_code; + nkn.maxKeyCode = xkb->max_key_code; + nkn.requestMajor = XkbReqCode; + nkn.requestMinor = X_kbSetMap; + nkn.changed = XkbNKN_KeycodesMask; + XkbSendNewKeyboardNotify(dev,&nkn); + sentNKN = TRUE; + } + + if (req->present&XkbKeyTypesMask) { + values = SetKeyTypes(xkb,req,(xkbKeyTypeWireDesc *)values,&change); + if (!values) goto allocFailure; + } + if (req->present&XkbKeySymsMask) { + values = SetKeySyms(client,xkb,req,(xkbSymMapWireDesc *)values,&change,dev); + if (!values) goto allocFailure; + } + if (req->present&XkbKeyActionsMask) { + values = SetKeyActions(xkb,req,(CARD8 *)values,&change); + if (!values) goto allocFailure; + } + if (req->present&XkbKeyBehaviorsMask) { + values= SetKeyBehaviors(xkbi,req,(xkbBehaviorWireDesc *)values,&change); + if (!values) goto allocFailure; + } + if (req->present&XkbVirtualModsMask) + values= SetVirtualMods(xkbi,req,(CARD8 *)values,&change); + if (req->present&XkbExplicitComponentsMask) + values= SetKeyExplicit(xkbi,req,(CARD8 *)values,&change); + if (req->present&XkbModifierMapMask) + values= SetModifierMap(xkbi,req,(CARD8 *)values,&change); + if (req->present&XkbVirtualModMapMask) + values= SetVirtualModMap(xkbi,req,(xkbVModMapWireDesc *)values,&change); + if (((values-((char *)req))/4)!=req->length) { + ErrorF("[xkb] Internal error! Bad length in XkbSetMap (after set)\n"); + client->errorValue = values-((char *)&req[1]); + return BadLength; + } + if (req->flags&XkbSetMapRecomputeActions) { + KeyCode first,last,firstMM,lastMM; + if (change.map.num_key_syms>0) { + first= change.map.first_key_sym; + last= first+change.map.num_key_syms-1; + } + else first= last= 0; + if (change.map.num_modmap_keys>0) { + firstMM= change.map.first_modmap_key; + lastMM= first+change.map.num_modmap_keys-1; + } + else firstMM= lastMM= 0; + if ((last>0) && (lastMM>0)) { + if (firstMMlast) + last= lastMM; + } + else if (lastMM>0) { + first= firstMM; + last= lastMM; + } + if (last>0) { + unsigned check= 0; + XkbUpdateActions(dev,first,(last-first+1),&change,&check,&cause); + if (check) + XkbCheckSecondaryEffects(xkbi,check,&change,&cause); + } + } + if (!sentNKN) + XkbSendNotification(dev,&change,&cause); + + return Success; +allocFailure: + return BadAlloc; +} + + +int +ProcXkbSetMap(ClientPtr client) +{ + DeviceIntPtr dev; + char * tmp; + int rc; + + REQUEST(xkbSetMapReq); + REQUEST_AT_LEAST_SIZE(xkbSetMapReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); + CHK_MASK_LEGAL(0x01,stuff->present,XkbAllMapComponentsMask); + + tmp = (char *)&stuff[1]; + + /* Check if we can to the SetMap on the requested device. If this + succeeds, do the same thing for all extension devices (if needed). + If any of them fails, fail. */ + rc = _XkbSetMapChecks(client, dev, stuff, tmp); + + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + { + rc = _XkbSetMapChecks(client, other, stuff, tmp); + if (rc != Success) + return rc; + } + } + } + } + + /* We know now that we will succed with the SetMap. In theory anyway. */ + rc = _XkbSetMap(client, dev, stuff, tmp); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + _XkbSetMap(client, other, stuff, tmp); + /* ignore rc. if the SetMap failed although the check above + reported true there isn't much we can do. we still need to + set all other devices, hoping that at least they stay in + sync. */ + } + } + } + + return Success; +} + +/***====================================================================***/ + +static Status +XkbComputeGetCompatMapReplySize( XkbCompatMapPtr compat, + xkbGetCompatMapReply * rep) +{ +unsigned size,nGroups; + + nGroups= 0; + if (rep->groups!=0) { + register int i,bit; + for (i=0,bit=1;igroups&bit) + nGroups++; + } + } + size= nGroups*SIZEOF(xkbModsWireDesc); + size+= (rep->nSI*SIZEOF(xkbSymInterpretWireDesc)); + rep->length= size/4; + return Success; +} + +static int +XkbSendCompatMap( ClientPtr client, + XkbCompatMapPtr compat, + xkbGetCompatMapReply * rep) +{ +char * data; +int size; + + size= rep->length*4; + if (size>0) { + data = malloc(size); + if (data) { + register unsigned i,bit; + xkbModsWireDesc * grp; + XkbSymInterpretPtr sym= &compat->sym_interpret[rep->firstSI]; + xkbSymInterpretWireDesc *wire = (xkbSymInterpretWireDesc *)data; + for (i=0;inSI;i++,sym++,wire++) { + wire->sym= sym->sym; + wire->mods= sym->mods; + wire->match= sym->match; + wire->virtualMod= sym->virtual_mod; + wire->flags= sym->flags; + memcpy((char*)&wire->act,(char*)&sym->act,sz_xkbActionWireDesc); + if (client->swapped) { + register int n; + swapl(&wire->sym,n); + } + } + if (rep->groups) { + grp = (xkbModsWireDesc *)wire; + for (i=0,bit=1;igroups&bit) { + grp->mask= compat->groups[i].mask; + grp->realMods= compat->groups[i].real_mods; + grp->virtualMods= compat->groups[i].vmods; + if (client->swapped) { + register int n; + swaps(&grp->virtualMods,n); + } + grp++; + } + } + wire= (xkbSymInterpretWireDesc*)grp; + } + } + else return BadAlloc; + } + else data= NULL; + + if (client->swapped) { + register int n; + swaps(&rep->sequenceNumber,n); + swapl(&rep->length,n); + swaps(&rep->firstSI,n); + swaps(&rep->nSI,n); + swaps(&rep->nTotalSI,n); + } + + WriteToClient(client, SIZEOF(xkbGetCompatMapReply), (char *)rep); + if (data) { + WriteToClient(client, size, data); + free((char *)data); + } + return Success; +} + +int +ProcXkbGetCompatMap(ClientPtr client) +{ + xkbGetCompatMapReply rep; + DeviceIntPtr dev; + XkbDescPtr xkb; + XkbCompatMapPtr compat; + + REQUEST(xkbGetCompatMapReq); + REQUEST_SIZE_MATCH(xkbGetCompatMapReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + + xkb = dev->key->xkbInfo->desc; + compat= xkb->compat; + + rep.type = X_Reply; + rep.deviceID = dev->id; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.firstSI = stuff->firstSI; + rep.nSI = stuff->nSI; + if (stuff->getAllSI) { + rep.firstSI = 0; + rep.nSI = compat->num_si; + } + else if ((((unsigned)stuff->nSI)>0)&& + ((unsigned)(stuff->firstSI+stuff->nSI-1)>=compat->num_si)) { + client->errorValue = _XkbErrCode2(0x05,compat->num_si); + return BadValue; + } + rep.nTotalSI = compat->num_si; + rep.groups= stuff->groups; + XkbComputeGetCompatMapReplySize(compat,&rep); + return XkbSendCompatMap(client,compat,&rep); +} + +/** + * Apply the given request on the given device. + * If dryRun is TRUE, then value checks are performed, but the device isn't + * modified. + */ +static int +_XkbSetCompatMap(ClientPtr client, DeviceIntPtr dev, + xkbSetCompatMapReq *req, char* data, BOOL dryRun) +{ + XkbSrvInfoPtr xkbi; + XkbDescPtr xkb; + XkbCompatMapPtr compat; + int nGroups; + unsigned i,bit; + + xkbi = dev->key->xkbInfo; + xkb = xkbi->desc; + compat = xkb->compat; + + if ((req->nSI>0)||(req->truncateSI)) { + xkbSymInterpretWireDesc *wire; + if (req->firstSI>compat->num_si) { + client->errorValue = _XkbErrCode2(0x02,compat->num_si); + return BadValue; + } + wire= (xkbSymInterpretWireDesc *)data; + wire+= req->nSI; + data = (char *)wire; + } + + nGroups= 0; + if (req->groups!=0) { + for (i=0,bit=1;igroups&bit ) + nGroups++; + } + } + data+= nGroups*SIZEOF(xkbModsWireDesc); + if (((data-((char *)req))/4)!=req->length) { + return BadLength; + } + + /* Done all the checks we can do */ + if (dryRun) + return Success; + + data = (char *)&req[1]; + if (req->nSI>0) { + xkbSymInterpretWireDesc *wire = (xkbSymInterpretWireDesc *)data; + XkbSymInterpretPtr sym; + if ((unsigned)(req->firstSI+req->nSI)>compat->num_si) { + compat->num_si= req->firstSI+req->nSI; + compat->sym_interpret= realloc(compat->sym_interpret, + compat->num_si * sizeof(XkbSymInterpretRec)); + if (!compat->sym_interpret) { + compat->num_si= 0; + return BadAlloc; + } + } + else if (req->truncateSI) { + compat->num_si = req->firstSI+req->nSI; + } + sym = &compat->sym_interpret[req->firstSI]; + for (i=0;inSI;i++,wire++,sym++) { + if (client->swapped) { + int n; + swapl(&wire->sym,n); + } + sym->sym= wire->sym; + sym->mods= wire->mods; + sym->match= wire->match; + sym->flags= wire->flags; + sym->virtual_mod= wire->virtualMod; + memcpy((char *)&sym->act,(char *)&wire->act, + SIZEOF(xkbActionWireDesc)); + } + data = (char *)wire; + } + else if (req->truncateSI) { + compat->num_si = req->firstSI; + } + + if (req->groups!=0) { + unsigned i, bit; + xkbModsWireDesc *wire = (xkbModsWireDesc *)data; + for (i = 0, bit = 1; i < XkbNumKbdGroups; i++, bit <<= 1) { + if (req->groups & bit) { + if (client->swapped) { + int n; + swaps(&wire->virtualMods,n); + } + compat->groups[i].mask= wire->realMods; + compat->groups[i].real_mods= wire->realMods; + compat->groups[i].vmods= wire->virtualMods; + if (wire->virtualMods!=0) { + unsigned tmp; + tmp= XkbMaskForVMask(xkb,wire->virtualMods); + compat->groups[i].mask|= tmp; + } + data+= SIZEOF(xkbModsWireDesc); + wire= (xkbModsWireDesc *)data; + } + } + } + i= XkbPaddedSize((data-((char *)req))); + if ((i/4)!=req->length) { + ErrorF("[xkb] Internal length error on read in _XkbSetCompatMap\n"); + return BadLength; + } + + if (dev->xkb_interest) { + xkbCompatMapNotify ev; + ev.deviceID = dev->id; + ev.changedGroups = req->groups; + ev.firstSI = req->firstSI; + ev.nSI = req->nSI; + ev.nTotalSI = compat->num_si; + XkbSendCompatMapNotify(dev,&ev); + } + + if (req->recomputeActions) { + XkbChangesRec change; + unsigned check; + XkbEventCauseRec cause; + + XkbSetCauseXkbReq(&cause,X_kbSetCompatMap,client); + memset(&change, 0, sizeof(XkbChangesRec)); + XkbUpdateActions(dev,xkb->min_key_code,XkbNumKeys(xkb),&change,&check, + &cause); + if (check) + XkbCheckSecondaryEffects(xkbi,check,&change,&cause); + XkbSendNotification(dev,&change,&cause); + } + return Success; +} + +int +ProcXkbSetCompatMap(ClientPtr client) +{ + DeviceIntPtr dev; + char *data; + int rc; + + REQUEST(xkbSetCompatMapReq); + REQUEST_AT_LEAST_SIZE(xkbSetCompatMapReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); + + data = (char *)&stuff[1]; + + /* check first using a dry-run */ + rc = _XkbSetCompatMap(client, dev, stuff, data, TRUE); + if (rc != Success) + return rc; + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + { + /* dry-run */ + rc = _XkbSetCompatMap(client, other, stuff, data, TRUE); + if (rc != Success) + return rc; + } + } + } + } + + /* Yay, the dry-runs succeed. Let's apply */ + rc = _XkbSetCompatMap(client, dev, stuff, data, FALSE); + if (rc != Success) + return rc; + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + { + rc = _XkbSetCompatMap(client, other, stuff, data, FALSE); + if (rc != Success) + return rc; + } + } + } + } + + return Success; +} + +/***====================================================================***/ + +int +ProcXkbGetIndicatorState(ClientPtr client) +{ + xkbGetIndicatorStateReply rep; + XkbSrvLedInfoPtr sli; + DeviceIntPtr dev; + register int i; + + REQUEST(xkbGetIndicatorStateReq); + REQUEST_SIZE_MATCH(xkbGetIndicatorStateReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixReadAccess); + + sli= XkbFindSrvLedInfo(dev,XkbDfltXIClass,XkbDfltXIId, + XkbXI_IndicatorStateMask); + if (!sli) + return BadAlloc; + + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.deviceID = dev->id; + rep.state = sli->effectiveState; + + if (client->swapped) { + swaps(&rep.sequenceNumber,i); + swapl(&rep.state,i); + } + WriteToClient(client, SIZEOF(xkbGetIndicatorStateReply), (char *)&rep); + return Success; +} + +/***====================================================================***/ + +static Status +XkbComputeGetIndicatorMapReplySize( + XkbIndicatorPtr indicators, + xkbGetIndicatorMapReply *rep) +{ +register int i,bit; +int nIndicators; + + rep->realIndicators = indicators->phys_indicators; + for (i=nIndicators=0,bit=1;iwhich&bit) + nIndicators++; + } + rep->length = (nIndicators*SIZEOF(xkbIndicatorMapWireDesc))/4; + return Success; +} + +static int +XkbSendIndicatorMap( ClientPtr client, + XkbIndicatorPtr indicators, + xkbGetIndicatorMapReply * rep) +{ +int length; +CARD8 * map; +register int i; +register unsigned bit; + + length = rep->length*4; + if (length>0) { + CARD8 *to; + to= map= malloc(length); + if (map) { + xkbIndicatorMapWireDesc *wire = (xkbIndicatorMapWireDesc *)to; + for (i=0,bit=1;iwhich&bit) { + wire->flags= indicators->maps[i].flags; + wire->whichGroups= indicators->maps[i].which_groups; + wire->groups= indicators->maps[i].groups; + wire->whichMods= indicators->maps[i].which_mods; + wire->mods= indicators->maps[i].mods.mask; + wire->realMods= indicators->maps[i].mods.real_mods; + wire->virtualMods= indicators->maps[i].mods.vmods; + wire->ctrls= indicators->maps[i].ctrls; + if (client->swapped) { + register int n; + swaps(&wire->virtualMods,n); + swapl(&wire->ctrls,n); + } + wire++; + } + } + to = (CARD8 *)wire; + if ((to-map)!=length) { + client->errorValue = _XkbErrCode2(0xff,length); + free(map); + return BadLength; + } + } + else return BadAlloc; + } + else map = NULL; + if (client->swapped) { + swaps(&rep->sequenceNumber,i); + swapl(&rep->length,i); + swapl(&rep->which,i); + swapl(&rep->realIndicators,i); + } + WriteToClient(client, SIZEOF(xkbGetIndicatorMapReply), (char *)rep); + if (map) { + WriteToClient(client, length, (char *)map); + free((char *)map); + } + return Success; +} + +int +ProcXkbGetIndicatorMap(ClientPtr client) +{ +xkbGetIndicatorMapReply rep; +DeviceIntPtr dev; +XkbDescPtr xkb; +XkbIndicatorPtr leds; + + REQUEST(xkbGetIndicatorMapReq); + REQUEST_SIZE_MATCH(xkbGetIndicatorMapReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + + xkb= dev->key->xkbInfo->desc; + leds= xkb->indicators; + + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.deviceID = dev->id; + rep.which = stuff->which; + XkbComputeGetIndicatorMapReplySize(leds,&rep); + return XkbSendIndicatorMap(client,leds,&rep); +} + +/** + * Apply the given map to the given device. Which specifies which components + * to apply. + */ +static int +_XkbSetIndicatorMap(ClientPtr client, DeviceIntPtr dev, + int which, xkbIndicatorMapWireDesc *desc) +{ + XkbSrvInfoPtr xkbi; + XkbSrvLedInfoPtr sli; + XkbEventCauseRec cause; + int i, bit; + + xkbi = dev->key->xkbInfo; + + sli= XkbFindSrvLedInfo(dev, XkbDfltXIClass, XkbDfltXIId, + XkbXI_IndicatorMapsMask); + if (!sli) + return BadAlloc; + + for (i = 0, bit = 1; i < XkbNumIndicators; i++, bit <<= 1) { + if (which & bit) { + sli->maps[i].flags = desc->flags; + sli->maps[i].which_groups = desc->whichGroups; + sli->maps[i].groups = desc->groups; + sli->maps[i].which_mods = desc->whichMods; + sli->maps[i].mods.mask = desc->mods; + sli->maps[i].mods.real_mods = desc->mods; + sli->maps[i].mods.vmods= desc->virtualMods; + sli->maps[i].ctrls = desc->ctrls; + if (desc->virtualMods!=0) { + unsigned tmp; + tmp= XkbMaskForVMask(xkbi->desc,desc->virtualMods); + sli->maps[i].mods.mask= desc->mods|tmp; + } + desc++; + } + } + + XkbSetCauseXkbReq(&cause,X_kbSetIndicatorMap,client); + XkbApplyLedMapChanges(dev,sli,which,NULL,NULL,&cause); + + return Success; +} + +int +ProcXkbSetIndicatorMap(ClientPtr client) +{ + int i, bit; + int nIndicators; + DeviceIntPtr dev; + xkbIndicatorMapWireDesc *from; + int rc; + + REQUEST(xkbSetIndicatorMapReq); + REQUEST_AT_LEAST_SIZE(xkbSetIndicatorMapReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixSetAttrAccess); + + if (stuff->which==0) + return Success; + + for (nIndicators=i=0,bit=1;iwhich&bit) + nIndicators++; + } + if (stuff->length!=((SIZEOF(xkbSetIndicatorMapReq)+ + (nIndicators*SIZEOF(xkbIndicatorMapWireDesc)))/4)) { + return BadLength; + } + + from = (xkbIndicatorMapWireDesc *)&stuff[1]; + for (i=0,bit=1;iwhich&bit) { + if (client->swapped) { + int n; + swaps(&from->virtualMods,n); + swapl(&from->ctrls,n); + } + CHK_MASK_LEGAL(i,from->whichGroups,XkbIM_UseAnyGroup); + CHK_MASK_LEGAL(i,from->whichMods,XkbIM_UseAnyMods); + from++; + } + } + + from = (xkbIndicatorMapWireDesc *)&stuff[1]; + rc = _XkbSetIndicatorMap(client, dev, stuff->which, from); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixSetAttrAccess); + if (rc == Success) + _XkbSetIndicatorMap(client, other, stuff->which, from); + } + } + } + + return Success; +} + +/***====================================================================***/ + +int +ProcXkbGetNamedIndicator(ClientPtr client) +{ + DeviceIntPtr dev; + xkbGetNamedIndicatorReply rep; + register int i = 0; + XkbSrvLedInfoPtr sli; + XkbIndicatorMapPtr map = NULL; + + REQUEST(xkbGetNamedIndicatorReq); + REQUEST_SIZE_MATCH(xkbGetNamedIndicatorReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_LED_DEVICE(dev, stuff->deviceSpec, client, DixReadAccess); + CHK_ATOM_ONLY(stuff->indicator); + + sli= XkbFindSrvLedInfo(dev,stuff->ledClass,stuff->ledID,0); + if (!sli) + return BadAlloc; + + i= 0; + map= NULL; + if ((sli->names)&&(sli->maps)) { + for (i=0;iindicator==sli->names[i]) { + map= &sli->maps[i]; + break; + } + } + } + + rep.type= X_Reply; + rep.length = 0; + rep.sequenceNumber = client->sequence; + rep.deviceID = dev->id; + rep.indicator= stuff->indicator; + if (map!=NULL) { + rep.found= TRUE; + rep.on= ((sli->effectiveState&(1<physIndicators&(1<flags; + rep.whichGroups= map->which_groups; + rep.groups= map->groups; + rep.whichMods= map->which_mods; + rep.mods= map->mods.mask; + rep.realMods= map->mods.real_mods; + rep.virtualMods= map->mods.vmods; + rep.ctrls= map->ctrls; + rep.supported= TRUE; + } + else { + rep.found= FALSE; + rep.on= FALSE; + rep.realIndicator= FALSE; + rep.ndx= XkbNoIndicator; + rep.flags= 0; + rep.whichGroups= 0; + rep.groups= 0; + rep.whichMods= 0; + rep.mods= 0; + rep.realMods= 0; + rep.virtualMods= 0; + rep.ctrls= 0; + rep.supported= TRUE; + } + if ( client->swapped ) { + register int n; + swapl(&rep.length,n); + swaps(&rep.sequenceNumber,n); + swapl(&rep.indicator,n); + swaps(&rep.virtualMods,n); + swapl(&rep.ctrls,n); + } + + WriteToClient(client,SIZEOF(xkbGetNamedIndicatorReply), (char *)&rep); + return Success; +} + + +/** + * Find the IM on the device. + * Returns the map, or NULL if the map doesn't exist. + * If the return value is NULL, led_return is undefined. Otherwise, led_return + * is set to the led index of the map. + */ +static XkbIndicatorMapPtr +_XkbFindNamedIndicatorMap(XkbSrvLedInfoPtr sli, Atom indicator, + int *led_return) +{ + XkbIndicatorMapPtr map; + + /* search for the right indicator */ + map = NULL; + if (sli->names && sli->maps) { + int led; + + for (led = 0; (led < XkbNumIndicators) && (map == NULL); led++) { + if (sli->names[led] == indicator) { + map= &sli->maps[led]; + *led_return = led; + break; + } + } + } + + return map; +} + +/** + * Creates an indicator map on the device. If dryRun is TRUE, it only checks + * if creation is possible, but doesn't actually create it. + */ +static int +_XkbCreateIndicatorMap(DeviceIntPtr dev, Atom indicator, + int ledClass, int ledID, + XkbIndicatorMapPtr *map_return, int *led_return, + Bool dryRun) +{ + XkbSrvLedInfoPtr sli; + XkbIndicatorMapPtr map; + int led; + + sli = XkbFindSrvLedInfo(dev, ledClass, ledID, XkbXI_IndicatorsMask); + if (!sli) + return BadAlloc; + + map = _XkbFindNamedIndicatorMap(sli, indicator, &led); + + if (!map) + { + /* find first unused indicator maps and assign the name to it */ + for (led = 0, map = NULL; (led < XkbNumIndicators) && (map == NULL); led++) { + if ((sli->names) && (sli->maps) && (sli->names[led] == None) && + (!XkbIM_InUse(&sli->maps[led]))) + { + map = &sli->maps[led]; + if (!dryRun) + sli->names[led] = indicator; + break; + } + } + } + + if (!map) + return BadAlloc; + + *led_return = led; + *map_return = map; + return Success; +} + +static int +_XkbSetNamedIndicator(ClientPtr client, DeviceIntPtr dev, + xkbSetNamedIndicatorReq *stuff) +{ + unsigned int extDevReason; + unsigned int statec, namec, mapc; + XkbSrvLedInfoPtr sli; + int led = 0; + XkbIndicatorMapPtr map; + DeviceIntPtr kbd; + XkbEventCauseRec cause; + xkbExtensionDeviceNotify ed; + XkbChangesRec changes; + int rc; + + rc = _XkbCreateIndicatorMap(dev, stuff->indicator, stuff->ledClass, + stuff->ledID, &map, &led, FALSE); + if (rc != Success || !map) /* oh-oh */ + return rc; + + sli = XkbFindSrvLedInfo(dev, stuff->ledClass, stuff->ledID, + XkbXI_IndicatorsMask); + if (!sli) + return BadAlloc; + + namec = mapc = statec = 0; + extDevReason = 0; + + namec |= (1<namesPresent |= ((stuff->indicator != None) ? (1 << led) : 0); + extDevReason |= XkbXI_IndicatorNamesMask; + + if (stuff->setMap) { + map->flags = stuff->flags; + map->which_groups = stuff->whichGroups; + map->groups = stuff->groups; + map->which_mods = stuff->whichMods; + map->mods.mask = stuff->realMods; + map->mods.real_mods = stuff->realMods; + map->mods.vmods= stuff->virtualMods; + map->ctrls = stuff->ctrls; + mapc|= (1<setState) && ((map->flags & XkbIM_NoExplicit) == 0)) + { + if (stuff->on) sli->explicitState |= (1<explicitState &= ~(1<effectiveState ^ sli->explicitState) & (1 << led)); + } + + memset((char *)&ed, 0, sizeof(xkbExtensionDeviceNotify)); + memset((char *)&changes, 0, sizeof(XkbChangesRec)); + XkbSetCauseXkbReq(&cause,X_kbSetNamedIndicator,client); + if (namec) + XkbApplyLedNameChanges(dev,sli,namec,&ed,&changes,&cause); + if (mapc) + XkbApplyLedMapChanges(dev,sli,mapc,&ed,&changes,&cause); + if (statec) + XkbApplyLedStateChanges(dev,sli,statec,&ed,&changes,&cause); + + kbd = dev; + if ((sli->flags&XkbSLI_HasOwnState)==0) + kbd = inputInfo.keyboard; + XkbFlushLedEvents(dev, kbd, sli, &ed, &changes, &cause); + + return Success; +} + +int +ProcXkbSetNamedIndicator(ClientPtr client) +{ + int rc; + DeviceIntPtr dev; + int led = 0; + XkbIndicatorMapPtr map; + + REQUEST(xkbSetNamedIndicatorReq); + REQUEST_SIZE_MATCH(xkbSetNamedIndicatorReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_LED_DEVICE(dev, stuff->deviceSpec, client, DixSetAttrAccess); + CHK_ATOM_ONLY(stuff->indicator); + CHK_MASK_LEGAL(0x10,stuff->whichGroups,XkbIM_UseAnyGroup); + CHK_MASK_LEGAL(0x11,stuff->whichMods,XkbIM_UseAnyMods); + + /* Dry-run for checks */ + rc = _XkbCreateIndicatorMap(dev, stuff->indicator, + stuff->ledClass, stuff->ledID, + &map, &led, TRUE); + if (rc != Success || !map) /* couldn't be created or didn't exist */ + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd || + stuff->deviceSpec == XkbUseCorePtr) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev && + (other->kbdfeed || other->leds) && + (XaceHook(XACE_DEVICE_ACCESS, client, other, DixSetAttrAccess) == Success)) + { + rc = _XkbCreateIndicatorMap(other, stuff->indicator, + stuff->ledClass, stuff->ledID, + &map, &led, TRUE); + if (rc != Success || !map) + return rc; + } + } + } + + /* All checks passed, let's do it */ + rc = _XkbSetNamedIndicator(client, dev, stuff); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd || + stuff->deviceSpec == XkbUseCorePtr) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev && + (other->kbdfeed || other->leds) && + (XaceHook(XACE_DEVICE_ACCESS, client, other, DixSetAttrAccess) == Success)) + { + _XkbSetNamedIndicator(client, other, stuff); + } + } + } + + return Success; +} + +/***====================================================================***/ + +static CARD32 +_XkbCountAtoms(Atom *atoms,int maxAtoms,int *count) +{ +register unsigned int i,bit,nAtoms; +register CARD32 atomsPresent; + + for (i=nAtoms=atomsPresent=0,bit=1;iminKeyCode= xkb->min_key_code; + rep->maxKeyCode= xkb->max_key_code; + which= rep->which; + length= 0; + if (xkb->names!=NULL) { + if (which&XkbKeycodesNameMask) length++; + if (which&XkbGeometryNameMask) length++; + if (which&XkbSymbolsNameMask) length++; + if (which&XkbPhysSymbolsNameMask) length++; + if (which&XkbTypesNameMask) length++; + if (which&XkbCompatNameMask) length++; + } + else which&= ~XkbComponentNamesMask; + + if (xkb->map!=NULL) { + if (which&XkbKeyTypeNamesMask) + length+= xkb->map->num_types; + rep->nTypes= xkb->map->num_types; + if (which&XkbKTLevelNamesMask) { + XkbKeyTypePtr pType = xkb->map->types; + int nKTLevels = 0; + + length+= XkbPaddedSize(xkb->map->num_types)/4; + for (i=0;imap->num_types;i++,pType++) { + if (pType->level_names!=NULL) + nKTLevels+= pType->num_levels; + } + rep->nKTLevels= nKTLevels; + length+= nKTLevels; + } + } + else { + rep->nTypes= 0; + rep->nKTLevels= 0; + which&= ~(XkbKeyTypeNamesMask|XkbKTLevelNamesMask); + } + + rep->minKeyCode= xkb->min_key_code; + rep->maxKeyCode= xkb->max_key_code; + rep->indicators= 0; + rep->virtualMods= 0; + rep->groupNames= 0; + if (xkb->names!=NULL) { + if (which&XkbIndicatorNamesMask) { + int nLeds; + rep->indicators= + _XkbCountAtoms(xkb->names->indicators,XkbNumIndicators,&nLeds); + length+= nLeds; + if (nLeds==0) + which&= ~XkbIndicatorNamesMask; + } + + if (which&XkbVirtualModNamesMask) { + int nVMods; + rep->virtualMods= + _XkbCountAtoms(xkb->names->vmods,XkbNumVirtualMods,&nVMods); + length+= nVMods; + if (nVMods==0) + which&= ~XkbVirtualModNamesMask; + } + + if (which&XkbGroupNamesMask) { + int nGroups; + rep->groupNames= + _XkbCountAtoms(xkb->names->groups,XkbNumKbdGroups,&nGroups); + length+= nGroups; + if (nGroups==0) + which&= ~XkbGroupNamesMask; + } + + if ((which&XkbKeyNamesMask)&&(xkb->names->keys)) + length+= rep->nKeys; + else which&= ~XkbKeyNamesMask; + + if ((which&XkbKeyAliasesMask)&& + (xkb->names->key_aliases)&&(xkb->names->num_key_aliases>0)) { + rep->nKeyAliases= xkb->names->num_key_aliases; + length+= rep->nKeyAliases*2; + } + else { + which&= ~XkbKeyAliasesMask; + rep->nKeyAliases= 0; + } + + if ((which&XkbRGNamesMask)&&(xkb->names->num_rg>0)) + length+= xkb->names->num_rg; + else which&= ~XkbRGNamesMask; + } + else { + which&= ~(XkbIndicatorNamesMask|XkbVirtualModNamesMask); + which&= ~(XkbGroupNamesMask|XkbKeyNamesMask|XkbKeyAliasesMask); + which&= ~XkbRGNamesMask; + } + + rep->length= length; + rep->which= which; + return Success; +} + +static int +XkbSendNames(ClientPtr client,XkbDescPtr xkb,xkbGetNamesReply *rep) +{ +register unsigned i,length,which; +char * start; +char * desc; +register int n; + + length= rep->length*4; + which= rep->which; + if (client->swapped) { + swaps(&rep->sequenceNumber,n); + swapl(&rep->length,n); + swapl(&rep->which,n); + swaps(&rep->virtualMods,n); + swapl(&rep->indicators,n); + } + + start = desc = malloc(length); + if ( !start ) + return BadAlloc; + if (xkb->names) { + if (which&XkbKeycodesNameMask) { + *((CARD32 *)desc)= xkb->names->keycodes; + if (client->swapped) { + swapl(desc,n); + } + desc+= 4; + } + if (which&XkbGeometryNameMask) { + *((CARD32 *)desc)= xkb->names->geometry; + if (client->swapped) { + swapl(desc,n); + } + desc+= 4; + } + if (which&XkbSymbolsNameMask) { + *((CARD32 *)desc)= xkb->names->symbols; + if (client->swapped) { + swapl(desc,n); + } + desc+= 4; + } + if (which&XkbPhysSymbolsNameMask) { + register CARD32 *atm= (CARD32 *)desc; + atm[0]= (CARD32)xkb->names->phys_symbols; + if (client->swapped) { + swapl(&atm[0],n); + } + desc+= 4; + } + if (which&XkbTypesNameMask) { + *((CARD32 *)desc)= (CARD32)xkb->names->types; + if (client->swapped) { + swapl(desc,n); + } + desc+= 4; + } + if (which&XkbCompatNameMask) { + *((CARD32 *)desc)= (CARD32)xkb->names->compat; + if (client->swapped) { + swapl(desc,n); + } + desc+= 4; + } + if (which&XkbKeyTypeNamesMask) { + register CARD32 *atm= (CARD32 *)desc; + register XkbKeyTypePtr type= xkb->map->types; + + for (i=0;imap->num_types;i++,atm++,type++) { + *atm= (CARD32)type->name; + if (client->swapped) { + swapl(atm,n); + } + } + desc= (char *)atm; + } + if (which&XkbKTLevelNamesMask && xkb->map) { + XkbKeyTypePtr type = xkb->map->types; + register CARD32 *atm; + for (i=0;inTypes;i++,type++) { + *desc++ = type->num_levels; + } + desc+= XkbPaddedSize(rep->nTypes)-rep->nTypes; + + atm= (CARD32 *)desc; + type = xkb->map->types; + for (i=0;imap->num_types;i++,type++) { + register unsigned l; + if (type->level_names) { + for (l=0;lnum_levels;l++,atm++) { + *atm= type->level_names[l]; + if (client->swapped) { + swapl(atm,n); + } + } + desc+= type->num_levels*4; + } + } + } + if (which&XkbIndicatorNamesMask) { + desc= _XkbWriteAtoms(desc,xkb->names->indicators,XkbNumIndicators, + client->swapped); + } + if (which&XkbVirtualModNamesMask) { + desc= _XkbWriteAtoms(desc,xkb->names->vmods,XkbNumVirtualMods, + client->swapped); + } + if (which&XkbGroupNamesMask) { + desc= _XkbWriteAtoms(desc,xkb->names->groups,XkbNumKbdGroups, + client->swapped); + } + if (which&XkbKeyNamesMask) { + for (i=0;inKeys;i++,desc+= sizeof(XkbKeyNameRec)) { + *((XkbKeyNamePtr)desc)= xkb->names->keys[i+rep->firstKey]; + } + } + if (which&XkbKeyAliasesMask) { + XkbKeyAliasPtr pAl; + pAl= xkb->names->key_aliases; + for (i=0;inKeyAliases;i++,pAl++,desc+=2*XkbKeyNameLength) { + *((XkbKeyAliasPtr)desc)= *pAl; + } + } + if ((which&XkbRGNamesMask)&&(rep->nRadioGroups>0)) { + register CARD32 *atm= (CARD32 *)desc; + for (i=0;inRadioGroups;i++,atm++) { + *atm= (CARD32)xkb->names->radio_groups[i]; + if (client->swapped) { + swapl(atm,n); + } + } + desc+= rep->nRadioGroups*4; + } + } + + if ((desc-start)!=(length)) { + ErrorF("[xkb] BOGUS LENGTH in write names, expected %d, got %ld\n", + length, (unsigned long)(desc-start)); + } + WriteToClient(client, SIZEOF(xkbGetNamesReply), (char *)rep); + WriteToClient(client, length, start); + free((char *)start); + return Success; +} + +int +ProcXkbGetNames(ClientPtr client) +{ + DeviceIntPtr dev; + XkbDescPtr xkb; + xkbGetNamesReply rep; + + REQUEST(xkbGetNamesReq); + REQUEST_SIZE_MATCH(xkbGetNamesReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + CHK_MASK_LEGAL(0x01,stuff->which,XkbAllNamesMask); + + xkb = dev->key->xkbInfo->desc; + memset(&rep, 0, sizeof(xkbGetNamesReply)); + rep.type= X_Reply; + rep.sequenceNumber= client->sequence; + rep.length = 0; + rep.deviceID = dev->id; + rep.which = stuff->which; + rep.nTypes = xkb->map->num_types; + rep.firstKey = xkb->min_key_code; + rep.nKeys = XkbNumKeys(xkb); + if (xkb->names!=NULL) { + rep.nKeyAliases= xkb->names->num_key_aliases; + rep.nRadioGroups = xkb->names->num_rg; + } + else { + rep.nKeyAliases= rep.nRadioGroups= 0; + } + XkbComputeGetNamesReplySize(xkb,&rep); + return XkbSendNames(client,xkb,&rep); +} + +/***====================================================================***/ + +static CARD32 * +_XkbCheckAtoms(CARD32 *wire,int nAtoms,int swapped,Atom *pError) +{ +register int i; + + for (i=0;ikey->xkbInfo->desc; + names = xkb->names; + + + if (stuff->which & XkbKeyTypeNamesMask) { + int i; + CARD32 *old; + if ( stuff->nTypes<1 ) { + client->errorValue = _XkbErrCode2(0x02,stuff->nTypes); + return BadValue; + } + if ((unsigned)(stuff->firstType+stuff->nTypes-1)>=xkb->map->num_types) { + client->errorValue = _XkbErrCode4(0x03,stuff->firstType, + stuff->nTypes, + xkb->map->num_types); + return BadValue; + } + if (((unsigned)stuff->firstType)<=XkbLastRequiredType) { + client->errorValue = _XkbErrCode2(0x04,stuff->firstType); + return BadAccess; + } + old= tmp; + tmp= _XkbCheckAtoms(tmp,stuff->nTypes,client->swapped,&bad); + if (!tmp) { + client->errorValue= bad; + return BadAtom; + } + for (i=0;inTypes;i++,old++) { + if (!_XkbCheckTypeName((Atom)*old,stuff->firstType+i)) + client->errorValue= _XkbErrCode2(0x05,i); + } + } + if (stuff->which&XkbKTLevelNamesMask) { + unsigned i; + XkbKeyTypePtr type; + CARD8 * width; + if ( stuff->nKTLevels<1 ) { + client->errorValue = _XkbErrCode2(0x05,stuff->nKTLevels); + return BadValue; + } + if ((unsigned)(stuff->firstKTLevel+stuff->nKTLevels-1)>= + xkb->map->num_types) { + client->errorValue = _XkbErrCode4(0x06,stuff->firstKTLevel, + stuff->nKTLevels,xkb->map->num_types); + return BadValue; + } + width = (CARD8 *)tmp; + tmp= (CARD32 *)(((char *)tmp)+XkbPaddedSize(stuff->nKTLevels)); + type = &xkb->map->types[stuff->firstKTLevel]; + for (i=0;inKTLevels;i++,type++) { + if (width[i]==0) + continue; + else if (width[i]!=type->num_levels) { + client->errorValue= _XkbErrCode4(0x07,i+stuff->firstKTLevel, + type->num_levels,width[i]); + return BadMatch; + } + tmp= _XkbCheckAtoms(tmp,width[i],client->swapped,&bad); + if (!tmp) { + client->errorValue= bad; + return BadAtom; + } + } + } + if (stuff->which&XkbIndicatorNamesMask) { + if (stuff->indicators==0) { + client->errorValue= 0x08; + return BadMatch; + } + tmp= _XkbCheckMaskedAtoms(tmp,XkbNumIndicators,stuff->indicators, + client->swapped,&bad); + if (!tmp) { + client->errorValue= bad; + return BadAtom; + } + } + if (stuff->which&XkbVirtualModNamesMask) { + if (stuff->virtualMods==0) { + client->errorValue= 0x09; + return BadMatch; + } + tmp= _XkbCheckMaskedAtoms(tmp,XkbNumVirtualMods, + (CARD32)stuff->virtualMods, + client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + if (stuff->which&XkbGroupNamesMask) { + if (stuff->groupNames==0) { + client->errorValue= 0x0a; + return BadMatch; + } + tmp= _XkbCheckMaskedAtoms(tmp,XkbNumKbdGroups, + (CARD32)stuff->groupNames, + client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + if (stuff->which&XkbKeyNamesMask) { + if (stuff->firstKey<(unsigned)xkb->min_key_code) { + client->errorValue= _XkbErrCode3(0x0b,xkb->min_key_code, + stuff->firstKey); + return BadValue; + } + if (((unsigned)(stuff->firstKey+stuff->nKeys-1)>xkb->max_key_code)|| + (stuff->nKeys<1)) { + client->errorValue= _XkbErrCode4(0x0c,xkb->max_key_code, + stuff->firstKey,stuff->nKeys); + return BadValue; + } + tmp+= stuff->nKeys; + } + if ((stuff->which&XkbKeyAliasesMask)&&(stuff->nKeyAliases>0)) { + tmp+= stuff->nKeyAliases*2; + } + if (stuff->which&XkbRGNamesMask) { + if ( stuff->nRadioGroups<1 ) { + client->errorValue= _XkbErrCode2(0x0d,stuff->nRadioGroups); + return BadValue; + } + tmp= _XkbCheckAtoms(tmp,stuff->nRadioGroups,client->swapped,&bad); + if (!tmp) { + client->errorValue= bad; + return BadAtom; + } + } + if ((tmp-((CARD32 *)stuff))!=stuff->length) { + client->errorValue = stuff->length; + return BadLength; + } + + + + return Success; +} + +static int +_XkbSetNames(ClientPtr client, DeviceIntPtr dev, xkbSetNamesReq *stuff) +{ + XkbDescRec *xkb; + XkbNamesRec *names; + CARD32 *tmp; + xkbNamesNotify nn; + + tmp = (CARD32 *)&stuff[1]; + xkb = dev->key->xkbInfo->desc; + names = xkb->names; + + if (XkbAllocNames(xkb,stuff->which,stuff->nRadioGroups, + stuff->nKeyAliases)!=Success) { + return BadAlloc; + } + + memset(&nn, 0, sizeof(xkbNamesNotify)); + nn.changed= stuff->which; + tmp = (CARD32 *)&stuff[1]; + if (stuff->which&XkbKeycodesNameMask) + names->keycodes= *tmp++; + if (stuff->which&XkbGeometryNameMask) + names->geometry= *tmp++; + if (stuff->which&XkbSymbolsNameMask) + names->symbols= *tmp++; + if (stuff->which&XkbPhysSymbolsNameMask) + names->phys_symbols= *tmp++; + if (stuff->which&XkbTypesNameMask) + names->types= *tmp++; + if (stuff->which&XkbCompatNameMask) + names->compat= *tmp++; + if ((stuff->which&XkbKeyTypeNamesMask)&&(stuff->nTypes>0)) { + register unsigned i; + register XkbKeyTypePtr type; + + type= &xkb->map->types[stuff->firstType]; + for (i=0;inTypes;i++,type++) { + type->name= *tmp++; + } + nn.firstType= stuff->firstType; + nn.nTypes= stuff->nTypes; + } + if (stuff->which&XkbKTLevelNamesMask) { + register XkbKeyTypePtr type; + register unsigned i; + CARD8 *width; + + width = (CARD8 *)tmp; + tmp= (CARD32 *)(((char *)tmp)+XkbPaddedSize(stuff->nKTLevels)); + type= &xkb->map->types[stuff->firstKTLevel]; + for (i=0;inKTLevels;i++,type++) { + if (width[i]>0) { + if (type->level_names) { + register unsigned n; + for (n=0;nlevel_names[n]= tmp[n]; + } + } + tmp+= width[i]; + } + } + nn.firstLevelName= 0; + nn.nLevelNames= stuff->nTypes; + } + if (stuff->which&XkbIndicatorNamesMask) { + tmp= _XkbCopyMaskedAtoms(tmp,names->indicators,XkbNumIndicators, + stuff->indicators); + nn.changedIndicators= stuff->indicators; + } + if (stuff->which&XkbVirtualModNamesMask) { + tmp= _XkbCopyMaskedAtoms(tmp,names->vmods,XkbNumVirtualMods, + stuff->virtualMods); + nn.changedVirtualMods= stuff->virtualMods; + } + if (stuff->which&XkbGroupNamesMask) { + tmp= _XkbCopyMaskedAtoms(tmp,names->groups,XkbNumKbdGroups, + stuff->groupNames); + nn.changedVirtualMods= stuff->groupNames; + } + if (stuff->which&XkbKeyNamesMask) { + memcpy((char*)&names->keys[stuff->firstKey],(char *)tmp, + stuff->nKeys*XkbKeyNameLength); + tmp+= stuff->nKeys; + nn.firstKey= stuff->firstKey; + nn.nKeys= stuff->nKeys; + } + if (stuff->which&XkbKeyAliasesMask) { + if (stuff->nKeyAliases>0) { + register int na= stuff->nKeyAliases; + if (XkbAllocNames(xkb,XkbKeyAliasesMask,0,na)!=Success) + return BadAlloc; + memcpy((char *)names->key_aliases,(char *)tmp, + stuff->nKeyAliases*sizeof(XkbKeyAliasRec)); + tmp+= stuff->nKeyAliases*2; + } + else if (names->key_aliases!=NULL) { + free(names->key_aliases); + names->key_aliases= NULL; + names->num_key_aliases= 0; + } + nn.nAliases= names->num_key_aliases; + } + if (stuff->which&XkbRGNamesMask) { + if (stuff->nRadioGroups>0) { + register unsigned i,nrg; + nrg= stuff->nRadioGroups; + if (XkbAllocNames(xkb,XkbRGNamesMask,nrg,0)!=Success) + return BadAlloc; + + for (i=0;inRadioGroups;i++) { + names->radio_groups[i]= tmp[i]; + } + tmp+= stuff->nRadioGroups; + } + else if (names->radio_groups) { + free(names->radio_groups); + names->radio_groups= NULL; + names->num_rg= 0; + } + nn.nRadioGroups= names->num_rg; + } + if (nn.changed) { + Bool needExtEvent; + needExtEvent= (nn.changed&XkbIndicatorNamesMask)!=0; + XkbSendNamesNotify(dev,&nn); + if (needExtEvent) { + XkbSrvLedInfoPtr sli; + xkbExtensionDeviceNotify edev; + register int i; + register unsigned bit; + + sli= XkbFindSrvLedInfo(dev,XkbDfltXIClass,XkbDfltXIId, + XkbXI_IndicatorsMask); + sli->namesPresent= 0; + for (i=0,bit=1;iindicators[i]!=None) + sli->namesPresent|= bit; + } + memset(&edev, 0, sizeof(xkbExtensionDeviceNotify)); + edev.reason= XkbXI_IndicatorNamesMask; + edev.ledClass= KbdFeedbackClass; + edev.ledID= dev->kbdfeed->ctrl.id; + edev.ledsDefined= sli->namesPresent|sli->mapsPresent; + edev.ledState= sli->effectiveState; + edev.firstBtn= 0; + edev.nBtns= 0; + edev.supported= XkbXI_AllFeaturesMask; + edev.unsupported= 0; + XkbSendExtensionDeviceNotify(dev,client,&edev); + } + } + return Success; +} + +int +ProcXkbSetNames(ClientPtr client) +{ + DeviceIntPtr dev; + CARD32 *tmp; + Atom bad; + int rc; + + REQUEST(xkbSetNamesReq); + REQUEST_AT_LEAST_SIZE(xkbSetNamesReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); + CHK_MASK_LEGAL(0x01,stuff->which,XkbAllNamesMask); + + /* check device-independent stuff */ + tmp = (CARD32 *)&stuff[1]; + + if (stuff->which&XkbKeycodesNameMask) { + tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + if (stuff->which&XkbGeometryNameMask) { + tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + if (stuff->which&XkbSymbolsNameMask) { + tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + if (stuff->which&XkbPhysSymbolsNameMask) { + tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); + if (!tmp) { + client->errorValue= bad; + return BadAtom; + } + } + if (stuff->which&XkbTypesNameMask) { + tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + if (stuff->which&XkbCompatNameMask) { + tmp= _XkbCheckAtoms(tmp,1,client->swapped,&bad); + if (!tmp) { + client->errorValue = bad; + return BadAtom; + } + } + + /* start of device-dependent tests */ + rc = _XkbSetNamesCheck(client, dev, stuff, tmp); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + { + rc = _XkbSetNamesCheck(client, other, stuff, tmp); + if (rc != Success) + return rc; + } + } + } + } + + /* everything is okay -- update names */ + + rc = _XkbSetNames(client, dev, stuff); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + _XkbSetNames(client, other, stuff); + } + } + } + + /* everything is okay -- update names */ + + return Success; +} + +/***====================================================================***/ + +#include "xkbgeom.h" + +#define XkbSizeCountedString(s) ((s)?((((2+strlen(s))+3)/4)*4):4) + +static char * +XkbWriteCountedString(char *wire,char *str,Bool swap) +{ + CARD16 len,*pLen; + + if (!str) + return wire; + + len= strlen(str); + pLen= (CARD16 *)wire; + *pLen= len; + if (swap) { + register int n; + swaps(pLen,n); + } + memcpy(&wire[2],str,len); + wire+= ((2+len+3)/4)*4; + return wire; +} + +static int +XkbSizeGeomProperties(XkbGeometryPtr geom) +{ +register int i,size; +XkbPropertyPtr prop; + + for (size=i=0,prop=geom->properties;inum_properties;i++,prop++) { + size+= XkbSizeCountedString(prop->name); + size+= XkbSizeCountedString(prop->value); + } + return size; +} + +static char * +XkbWriteGeomProperties(char *wire,XkbGeometryPtr geom,Bool swap) +{ +register int i; +register XkbPropertyPtr prop; + + for (i=0,prop=geom->properties;inum_properties;i++,prop++) { + wire= XkbWriteCountedString(wire,prop->name,swap); + wire= XkbWriteCountedString(wire,prop->value,swap); + } + return wire; +} + +static int +XkbSizeGeomKeyAliases(XkbGeometryPtr geom) +{ + return geom->num_key_aliases*(2*XkbKeyNameLength); +} + +static char * +XkbWriteGeomKeyAliases(char *wire,XkbGeometryPtr geom,Bool swap) +{ +register int sz; + + sz= geom->num_key_aliases*(XkbKeyNameLength*2); + if (sz>0) { + memcpy(wire,(char *)geom->key_aliases,sz); + wire+= sz; + } + return wire; +} + +static int +XkbSizeGeomColors(XkbGeometryPtr geom) +{ +register int i,size; +register XkbColorPtr color; + + for (i=size=0,color=geom->colors;inum_colors;i++,color++) { + size+= XkbSizeCountedString(color->spec); + } + return size; +} + +static char * +XkbWriteGeomColors(char *wire,XkbGeometryPtr geom,Bool swap) +{ +register int i; +register XkbColorPtr color; + + for (i=0,color=geom->colors;inum_colors;i++,color++) { + wire= XkbWriteCountedString(wire,color->spec,swap); + } + return wire; +} + +static int +XkbSizeGeomShapes(XkbGeometryPtr geom) +{ +register int i,size; +register XkbShapePtr shape; + + for (i=size=0,shape=geom->shapes;inum_shapes;i++,shape++) { + register int n; + register XkbOutlinePtr ol; + size+= SIZEOF(xkbShapeWireDesc); + for (n=0,ol=shape->outlines;nnum_outlines;n++,ol++) { + size+= SIZEOF(xkbOutlineWireDesc); + size+= ol->num_points*SIZEOF(xkbPointWireDesc); + } + } + return size; +} + +static char * +XkbWriteGeomShapes(char *wire,XkbGeometryPtr geom,Bool swap) +{ +int i; +XkbShapePtr shape; +xkbShapeWireDesc * shapeWire; + + for (i=0,shape=geom->shapes;inum_shapes;i++,shape++) { + register int o; + XkbOutlinePtr ol; + xkbOutlineWireDesc * olWire; + shapeWire= (xkbShapeWireDesc *)wire; + shapeWire->name= shape->name; + shapeWire->nOutlines= shape->num_outlines; + if (shape->primary!=NULL) + shapeWire->primaryNdx= XkbOutlineIndex(shape,shape->primary); + else shapeWire->primaryNdx= XkbNoShape; + if (shape->approx!=NULL) + shapeWire->approxNdx= XkbOutlineIndex(shape,shape->approx); + else shapeWire->approxNdx= XkbNoShape; + if (swap) { + register int n; + swapl(&shapeWire->name,n); + } + wire= (char *)&shapeWire[1]; + for (o=0,ol=shape->outlines;onum_outlines;o++,ol++) { + register int p; + XkbPointPtr pt; + xkbPointWireDesc * ptWire; + olWire= (xkbOutlineWireDesc *)wire; + olWire->nPoints= ol->num_points; + olWire->cornerRadius= ol->corner_radius; + wire= (char *)&olWire[1]; + ptWire= (xkbPointWireDesc *)wire; + for (p=0,pt=ol->points;pnum_points;p++,pt++) { + ptWire[p].x= pt->x; + ptWire[p].y= pt->y; + if (swap) { + register int n; + swaps(&ptWire[p].x,n); + swaps(&ptWire[p].y,n); + } + } + wire= (char *)&ptWire[ol->num_points]; + } + } + return wire; +} + +static int +XkbSizeGeomDoodads(int num_doodads,XkbDoodadPtr doodad) +{ +register int i,size; + + for (i=size=0;iany.type==XkbTextDoodad) { + size+= XkbSizeCountedString(doodad->text.text); + size+= XkbSizeCountedString(doodad->text.font); + } + else if (doodad->any.type==XkbLogoDoodad) { + size+= XkbSizeCountedString(doodad->logo.logo_name); + } + } + return size; +} + +static char * +XkbWriteGeomDoodads(char *wire,int num_doodads,XkbDoodadPtr doodad,Bool swap) +{ +register int i; +xkbDoodadWireDesc * doodadWire; + + for (i=0;iany.name= doodad->any.name; + doodadWire->any.type= doodad->any.type; + doodadWire->any.priority= doodad->any.priority; + doodadWire->any.top= doodad->any.top; + doodadWire->any.left= doodad->any.left; + if (swap) { + register int n; + swapl(&doodadWire->any.name,n); + swaps(&doodadWire->any.top,n); + swaps(&doodadWire->any.left,n); + } + switch (doodad->any.type) { + case XkbOutlineDoodad: + case XkbSolidDoodad: + doodadWire->shape.angle= doodad->shape.angle; + doodadWire->shape.colorNdx= doodad->shape.color_ndx; + doodadWire->shape.shapeNdx= doodad->shape.shape_ndx; + if (swap) { + register int n; + swaps(&doodadWire->shape.angle,n); + } + break; + case XkbTextDoodad: + doodadWire->text.angle= doodad->text.angle; + doodadWire->text.width= doodad->text.width; + doodadWire->text.height= doodad->text.height; + doodadWire->text.colorNdx= doodad->text.color_ndx; + if (swap) { + register int n; + swaps(&doodadWire->text.angle,n); + swaps(&doodadWire->text.width,n); + swaps(&doodadWire->text.height,n); + } + wire= XkbWriteCountedString(wire,doodad->text.text,swap); + wire= XkbWriteCountedString(wire,doodad->text.font,swap); + break; + case XkbIndicatorDoodad: + doodadWire->indicator.shapeNdx= doodad->indicator.shape_ndx; + doodadWire->indicator.onColorNdx=doodad->indicator.on_color_ndx; + doodadWire->indicator.offColorNdx= + doodad->indicator.off_color_ndx; + break; + case XkbLogoDoodad: + doodadWire->logo.angle= doodad->logo.angle; + doodadWire->logo.colorNdx= doodad->logo.color_ndx; + doodadWire->logo.shapeNdx= doodad->logo.shape_ndx; + wire= XkbWriteCountedString(wire,doodad->logo.logo_name,swap); + break; + default: + ErrorF("[xkb] Unknown doodad type %d in XkbWriteGeomDoodads\n", + doodad->any.type); + ErrorF("[xkb] Ignored\n"); + break; + } + } + return wire; +} + +static char * +XkbWriteGeomOverlay(char *wire,XkbOverlayPtr ol,Bool swap) +{ +register int r; +XkbOverlayRowPtr row; +xkbOverlayWireDesc * olWire; + + olWire= (xkbOverlayWireDesc *)wire; + olWire->name= ol->name; + olWire->nRows= ol->num_rows; + if (swap) { + register int n; + swapl(&olWire->name,n); + } + wire= (char *)&olWire[1]; + for (r=0,row=ol->rows;rnum_rows;r++,row++) { + unsigned int k; + XkbOverlayKeyPtr key; + xkbOverlayRowWireDesc * rowWire; + rowWire= (xkbOverlayRowWireDesc *)wire; + rowWire->rowUnder= row->row_under; + rowWire->nKeys= row->num_keys; + wire= (char *)&rowWire[1]; + for (k=0,key=row->keys;knum_keys;k++,key++) { + xkbOverlayKeyWireDesc * keyWire; + keyWire= (xkbOverlayKeyWireDesc *)wire; + memcpy(keyWire->over,key->over.name,XkbKeyNameLength); + memcpy(keyWire->under,key->under.name,XkbKeyNameLength); + wire= (char *)&keyWire[1]; + } + } + return wire; +} + +static int +XkbSizeGeomSections(XkbGeometryPtr geom) +{ +register int i,size; +XkbSectionPtr section; + + for (i=size=0,section=geom->sections;inum_sections;i++,section++) { + size+= SIZEOF(xkbSectionWireDesc); + if (section->rows) { + int r; + XkbRowPtr row; + for (r=0,row=section->rows;rnum_rows;row++,r++) { + size+= SIZEOF(xkbRowWireDesc); + size+= row->num_keys*SIZEOF(xkbKeyWireDesc); + } + } + if (section->doodads) + size+= XkbSizeGeomDoodads(section->num_doodads,section->doodads); + if (section->overlays) { + int o; + XkbOverlayPtr ol; + for (o=0,ol=section->overlays;onum_overlays;o++,ol++) { + int r; + XkbOverlayRowPtr row; + size+= SIZEOF(xkbOverlayWireDesc); + for (r=0,row=ol->rows;rnum_rows;r++,row++) { + size+= SIZEOF(xkbOverlayRowWireDesc); + size+= row->num_keys*SIZEOF(xkbOverlayKeyWireDesc); + } + } + } + } + return size; +} + +static char * +XkbWriteGeomSections(char *wire,XkbGeometryPtr geom,Bool swap) +{ +register int i; +XkbSectionPtr section; +xkbSectionWireDesc * sectionWire; + + for (i=0,section=geom->sections;inum_sections;i++,section++) { + sectionWire= (xkbSectionWireDesc *)wire; + sectionWire->name= section->name; + sectionWire->top= section->top; + sectionWire->left= section->left; + sectionWire->width= section->width; + sectionWire->height= section->height; + sectionWire->angle= section->angle; + sectionWire->priority= section->priority; + sectionWire->nRows= section->num_rows; + sectionWire->nDoodads= section->num_doodads; + sectionWire->nOverlays= section->num_overlays; + sectionWire->pad= 0; + if (swap) { + register int n; + swapl(§ionWire->name,n); + swaps(§ionWire->top,n); + swaps(§ionWire->left,n); + swaps(§ionWire->width,n); + swaps(§ionWire->height,n); + swaps(§ionWire->angle,n); + } + wire= (char *)§ionWire[1]; + if (section->rows) { + int r; + XkbRowPtr row; + xkbRowWireDesc * rowWire; + for (r=0,row=section->rows;rnum_rows;r++,row++) { + rowWire= (xkbRowWireDesc *)wire; + rowWire->top= row->top; + rowWire->left= row->left; + rowWire->nKeys= row->num_keys; + rowWire->vertical= row->vertical; + rowWire->pad= 0; + if (swap) { + register int n; + swaps(&rowWire->top,n); + swaps(&rowWire->left,n); + } + wire= (char *)&rowWire[1]; + if (row->keys) { + int k; + XkbKeyPtr key; + xkbKeyWireDesc * keyWire; + keyWire= (xkbKeyWireDesc *)wire; + for (k=0,key=row->keys;knum_keys;k++,key++) { + memcpy(keyWire[k].name,key->name.name,XkbKeyNameLength); + keyWire[k].gap= key->gap; + keyWire[k].shapeNdx= key->shape_ndx; + keyWire[k].colorNdx= key->color_ndx; + if (swap) { + register int n; + swaps(&keyWire[k].gap,n); + } + } + wire= (char *)&keyWire[row->num_keys]; + } + } + } + if (section->doodads) { + wire= XkbWriteGeomDoodads(wire, + section->num_doodads,section->doodads, + swap); + } + if (section->overlays) { + register int o; + for (o=0;onum_overlays;o++) { + wire= XkbWriteGeomOverlay(wire,§ion->overlays[o],swap); + } + } + } + return wire; +} + +static Status +XkbComputeGetGeometryReplySize( XkbGeometryPtr geom, + xkbGetGeometryReply * rep, + Atom name) +{ +int len; + + if (geom!=NULL) { + len= XkbSizeCountedString(geom->label_font); + len+= XkbSizeGeomProperties(geom); + len+= XkbSizeGeomColors(geom); + len+= XkbSizeGeomShapes(geom); + len+= XkbSizeGeomSections(geom); + len+= XkbSizeGeomDoodads(geom->num_doodads,geom->doodads); + len+= XkbSizeGeomKeyAliases(geom); + rep->length= len/4; + rep->found= TRUE; + rep->name= geom->name; + rep->widthMM= geom->width_mm; + rep->heightMM= geom->height_mm; + rep->nProperties= geom->num_properties; + rep->nColors= geom->num_colors; + rep->nShapes= geom->num_shapes; + rep->nSections= geom->num_sections; + rep->nDoodads= geom->num_doodads; + rep->nKeyAliases= geom->num_key_aliases; + rep->baseColorNdx= XkbGeomColorIndex(geom,geom->base_color); + rep->labelColorNdx= XkbGeomColorIndex(geom,geom->label_color); + } + else { + rep->length= 0; + rep->found= FALSE; + rep->name= name; + rep->widthMM= rep->heightMM= 0; + rep->nProperties= rep->nColors= rep->nShapes= 0; + rep->nSections= rep->nDoodads= 0; + rep->nKeyAliases= 0; + rep->labelColorNdx= rep->baseColorNdx= 0; + } + return Success; +} + +static int +XkbSendGeometry( ClientPtr client, + XkbGeometryPtr geom, + xkbGetGeometryReply * rep, + Bool freeGeom) +{ + char *desc,*start; + int len; + + if (geom!=NULL) { + len= rep->length*4; + start= desc= malloc(len); + if (!start) + return BadAlloc; + desc= XkbWriteCountedString(desc,geom->label_font,client->swapped); + if ( rep->nProperties>0 ) + desc = XkbWriteGeomProperties(desc,geom,client->swapped); + if ( rep->nColors>0 ) + desc = XkbWriteGeomColors(desc,geom,client->swapped); + if ( rep->nShapes>0 ) + desc = XkbWriteGeomShapes(desc,geom,client->swapped); + if ( rep->nSections>0 ) + desc = XkbWriteGeomSections(desc,geom,client->swapped); + if ( rep->nDoodads>0 ) + desc = XkbWriteGeomDoodads(desc,geom->num_doodads,geom->doodads, + client->swapped); + if ( rep->nKeyAliases>0 ) + desc = XkbWriteGeomKeyAliases(desc,geom,client->swapped); + if ((desc-start)!=(len)) { + ErrorF("[xkb] BOGUS LENGTH in XkbSendGeometry, expected %d, got %ld\n", + len, (unsigned long)(desc-start)); + } + } + else { + len= 0; + start= NULL; + } + if (client->swapped) { + register int n; + swaps(&rep->sequenceNumber,n); + swapl(&rep->length,n); + swapl(&rep->name,n); + swaps(&rep->widthMM,n); + swaps(&rep->heightMM,n); + swaps(&rep->nProperties,n); + swaps(&rep->nColors,n); + swaps(&rep->nShapes,n); + swaps(&rep->nSections,n); + swaps(&rep->nDoodads,n); + swaps(&rep->nKeyAliases,n); + } + WriteToClient(client, SIZEOF(xkbGetGeometryReply), (char *)rep); + if (len>0) + WriteToClient(client, len, start); + if (start!=NULL) + free((char *)start); + if (freeGeom) + XkbFreeGeometry(geom,XkbGeomAllMask,TRUE); + return Success; +} + +int +ProcXkbGetGeometry(ClientPtr client) +{ + DeviceIntPtr dev; + xkbGetGeometryReply rep; + XkbGeometryPtr geom; + Bool shouldFree; + Status status; + + REQUEST(xkbGetGeometryReq); + REQUEST_SIZE_MATCH(xkbGetGeometryReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + CHK_ATOM_OR_NONE(stuff->name); + + geom= XkbLookupNamedGeometry(dev,stuff->name,&shouldFree); + rep.type= X_Reply; + rep.deviceID= dev->id; + rep.sequenceNumber= client->sequence; + rep.length= 0; + status= XkbComputeGetGeometryReplySize(geom,&rep,stuff->name); + if (status!=Success) + return status; + else return XkbSendGeometry(client,geom,&rep,shouldFree); +} + +/***====================================================================***/ + +static char * +_GetCountedString(char **wire_inout,Bool swap) +{ +char * wire,*str; +CARD16 len,*plen; + + wire= *wire_inout; + plen= (CARD16 *)wire; + if (swap) { + register int n; + swaps(plen,n); + } + len= *plen; + str= malloc(len+1); + if (str) { + memcpy(str,&wire[2],len); + str[len]= '\0'; + } + wire+= XkbPaddedSize(len+2); + *wire_inout= wire; + return str; +} + +static Status +_CheckSetDoodad( char ** wire_inout, + XkbGeometryPtr geom, + XkbSectionPtr section, + ClientPtr client) +{ +char * wire; +xkbDoodadWireDesc * dWire; +XkbDoodadPtr doodad; + + dWire= (xkbDoodadWireDesc *)(*wire_inout); + wire= (char *)&dWire[1]; + if (client->swapped) { + register int n; + swapl(&dWire->any.name,n); + swaps(&dWire->any.top,n); + swaps(&dWire->any.left,n); + swaps(&dWire->any.angle,n); + } + CHK_ATOM_ONLY(dWire->any.name); + doodad= XkbAddGeomDoodad(geom,section,dWire->any.name); + if (!doodad) + return BadAlloc; + doodad->any.type= dWire->any.type; + doodad->any.priority= dWire->any.priority; + doodad->any.top= dWire->any.top; + doodad->any.left= dWire->any.left; + doodad->any.angle= dWire->any.angle; + switch (doodad->any.type) { + case XkbOutlineDoodad: + case XkbSolidDoodad: + if (dWire->shape.colorNdx>=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x40,geom->num_colors, + dWire->shape.colorNdx); + return BadMatch; + } + if (dWire->shape.shapeNdx>=geom->num_shapes) { + client->errorValue= _XkbErrCode3(0x41,geom->num_shapes, + dWire->shape.shapeNdx); + return BadMatch; + } + doodad->shape.color_ndx= dWire->shape.colorNdx; + doodad->shape.shape_ndx= dWire->shape.shapeNdx; + break; + case XkbTextDoodad: + if (dWire->text.colorNdx>=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x42,geom->num_colors, + dWire->text.colorNdx); + return BadMatch; + } + if (client->swapped) { + register int n; + swaps(&dWire->text.width,n); + swaps(&dWire->text.height,n); + } + doodad->text.width= dWire->text.width; + doodad->text.height= dWire->text.height; + doodad->text.color_ndx= dWire->text.colorNdx; + doodad->text.text= _GetCountedString(&wire,client->swapped); + doodad->text.font= _GetCountedString(&wire,client->swapped); + break; + case XkbIndicatorDoodad: + if (dWire->indicator.onColorNdx>=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x43,geom->num_colors, + dWire->indicator.onColorNdx); + return BadMatch; + } + if (dWire->indicator.offColorNdx>=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x44,geom->num_colors, + dWire->indicator.offColorNdx); + return BadMatch; + } + if (dWire->indicator.shapeNdx>=geom->num_shapes) { + client->errorValue= _XkbErrCode3(0x45,geom->num_shapes, + dWire->indicator.shapeNdx); + return BadMatch; + } + doodad->indicator.shape_ndx= dWire->indicator.shapeNdx; + doodad->indicator.on_color_ndx= dWire->indicator.onColorNdx; + doodad->indicator.off_color_ndx= dWire->indicator.offColorNdx; + break; + case XkbLogoDoodad: + if (dWire->logo.colorNdx>=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x46,geom->num_colors, + dWire->logo.colorNdx); + return BadMatch; + } + if (dWire->logo.shapeNdx>=geom->num_shapes) { + client->errorValue= _XkbErrCode3(0x47,geom->num_shapes, + dWire->logo.shapeNdx); + return BadMatch; + } + doodad->logo.color_ndx= dWire->logo.colorNdx; + doodad->logo.shape_ndx= dWire->logo.shapeNdx; + doodad->logo.logo_name= _GetCountedString(&wire,client->swapped); + break; + default: + client->errorValue= _XkbErrCode2(0x4F,dWire->any.type); + return BadValue; + } + *wire_inout= wire; + return Success; +} + +static Status +_CheckSetOverlay( char ** wire_inout, + XkbGeometryPtr geom, + XkbSectionPtr section, + ClientPtr client) +{ +register int r; +char * wire; +XkbOverlayPtr ol; +xkbOverlayWireDesc * olWire; +xkbOverlayRowWireDesc * rWire; + + wire= *wire_inout; + olWire= (xkbOverlayWireDesc *)wire; + if (client->swapped) { + register int n; + swapl(&olWire->name,n); + } + CHK_ATOM_ONLY(olWire->name); + ol= XkbAddGeomOverlay(section,olWire->name,olWire->nRows); + rWire= (xkbOverlayRowWireDesc *)&olWire[1]; + for (r=0;rnRows;r++) { + register int k; + xkbOverlayKeyWireDesc * kWire; + XkbOverlayRowPtr row; + + if (rWire->rowUnder>section->num_rows) { + client->errorValue= _XkbErrCode4(0x20,r,section->num_rows, + rWire->rowUnder); + return BadMatch; + } + row= XkbAddGeomOverlayRow(ol,rWire->rowUnder,rWire->nKeys); + kWire= (xkbOverlayKeyWireDesc *)&rWire[1]; + for (k=0;knKeys;k++,kWire++) { + if (XkbAddGeomOverlayKey(ol,row, + (char *)kWire->over,(char *)kWire->under)==NULL) { + client->errorValue= _XkbErrCode3(0x21,r,k); + return BadMatch; + } + } + rWire= (xkbOverlayRowWireDesc *)kWire; + } + olWire= (xkbOverlayWireDesc *)rWire; + wire= (char *)olWire; + *wire_inout= wire; + return Success; +} + +static Status +_CheckSetSections( XkbGeometryPtr geom, + xkbSetGeometryReq * req, + char ** wire_inout, + ClientPtr client) +{ +Status status; +register int s; +char * wire; +xkbSectionWireDesc * sWire; +XkbSectionPtr section; + + wire= *wire_inout; + if (req->nSections<1) + return Success; + sWire= (xkbSectionWireDesc *)wire; + for (s=0;snSections;s++) { + register int r; + xkbRowWireDesc * rWire; + if (client->swapped) { + register int n; + swapl(&sWire->name,n); + swaps(&sWire->top,n); + swaps(&sWire->left,n); + swaps(&sWire->width,n); + swaps(&sWire->height,n); + swaps(&sWire->angle,n); + } + CHK_ATOM_ONLY(sWire->name); + section= XkbAddGeomSection(geom,sWire->name,sWire->nRows, + sWire->nDoodads,sWire->nOverlays); + if (!section) + return BadAlloc; + section->priority= sWire->priority; + section->top= sWire->top; + section->left= sWire->left; + section->width= sWire->width; + section->height= sWire->height; + section->angle= sWire->angle; + rWire= (xkbRowWireDesc *)&sWire[1]; + for (r=0;rnRows;r++) { + register int k; + XkbRowPtr row; + xkbKeyWireDesc * kWire; + if (client->swapped) { + register int n; + swaps(&rWire->top,n); + swaps(&rWire->left,n); + } + row= XkbAddGeomRow(section,rWire->nKeys); + if (!row) + return BadAlloc; + row->top= rWire->top; + row->left= rWire->left; + row->vertical= rWire->vertical; + kWire= (xkbKeyWireDesc *)&rWire[1]; + for (k=0;knKeys;k++) { + XkbKeyPtr key; + key= XkbAddGeomKey(row); + if (!key) + return BadAlloc; + memcpy(key->name.name,kWire[k].name,XkbKeyNameLength); + key->gap= kWire[k].gap; + key->shape_ndx= kWire[k].shapeNdx; + key->color_ndx= kWire[k].colorNdx; + if (key->shape_ndx>=geom->num_shapes) { + client->errorValue= _XkbErrCode3(0x10,key->shape_ndx, + geom->num_shapes); + return BadMatch; + } + if (key->color_ndx>=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x11,key->color_ndx, + geom->num_colors); + return BadMatch; + } + } + rWire= (xkbRowWireDesc *)&kWire[rWire->nKeys]; + } + wire= (char *)rWire; + if (sWire->nDoodads>0) { + register int d; + for (d=0;dnDoodads;d++) { + status=_CheckSetDoodad(&wire,geom,section,client); + if (status!=Success) + return status; + } + } + if (sWire->nOverlays>0) { + register int o; + for (o=0;onOverlays;o++) { + status= _CheckSetOverlay(&wire,geom,section,client); + if (status!=Success) + return status; + } + } + sWire= (xkbSectionWireDesc *)wire; + } + wire= (char *)sWire; + *wire_inout= wire; + return Success; +} + +static Status +_CheckSetShapes( XkbGeometryPtr geom, + xkbSetGeometryReq * req, + char ** wire_inout, + ClientPtr client) +{ +register int i; +char * wire; + + wire= *wire_inout; + if (req->nShapes<1) { + client->errorValue= _XkbErrCode2(0x06,req->nShapes); + return BadValue; + } + else { + xkbShapeWireDesc * shapeWire; + XkbShapePtr shape; + register int o; + shapeWire= (xkbShapeWireDesc *)wire; + for (i=0;inShapes;i++) { + xkbOutlineWireDesc * olWire; + XkbOutlinePtr ol; + shape= XkbAddGeomShape(geom,shapeWire->name,shapeWire->nOutlines); + if (!shape) + return BadAlloc; + olWire= (xkbOutlineWireDesc *)(&shapeWire[1]); + for (o=0;onOutlines;o++) { + register int p; + XkbPointPtr pt; + xkbPointWireDesc * ptWire; + + ol= XkbAddGeomOutline(shape,olWire->nPoints); + if (!ol) + return BadAlloc; + ol->corner_radius= olWire->cornerRadius; + ptWire= (xkbPointWireDesc *)&olWire[1]; + for (p=0,pt=ol->points;pnPoints;p++,pt++) { + pt->x= ptWire[p].x; + pt->y= ptWire[p].y; + if (client->swapped) { + register int n; + swaps(&pt->x,n); + swaps(&pt->y,n); + } + } + ol->num_points= olWire->nPoints; + olWire= (xkbOutlineWireDesc *)(&ptWire[olWire->nPoints]); + } + if (shapeWire->primaryNdx!=XkbNoShape) + shape->primary= &shape->outlines[shapeWire->primaryNdx]; + if (shapeWire->approxNdx!=XkbNoShape) + shape->approx= &shape->outlines[shapeWire->approxNdx]; + shapeWire= (xkbShapeWireDesc *)olWire; + } + wire= (char *)shapeWire; + } + if (geom->num_shapes!=req->nShapes) { + client->errorValue= _XkbErrCode3(0x07,geom->num_shapes,req->nShapes); + return BadMatch; + } + + *wire_inout= wire; + return Success; +} + +static Status +_CheckSetGeom( XkbGeometryPtr geom, + xkbSetGeometryReq * req, + ClientPtr client) +{ +register int i; +Status status; +char * wire; + + wire= (char *)&req[1]; + geom->label_font= _GetCountedString(&wire,client->swapped); + + for (i=0;inProperties;i++) { + char *name,*val; + name= _GetCountedString(&wire,client->swapped); + if (!name) + return BadAlloc; + val= _GetCountedString(&wire,client->swapped); + if (!val) { + free(name); + return BadAlloc; + } + if (XkbAddGeomProperty(geom,name,val)==NULL) { + free(name); + free(val); + return BadAlloc; + } + free(name); + free(val); + } + + if (req->nColors<2) { + client->errorValue= _XkbErrCode3(0x01,2,req->nColors); + return BadValue; + } + if (req->baseColorNdx>req->nColors) { + client->errorValue=_XkbErrCode3(0x03,req->nColors,req->baseColorNdx); + return BadMatch; + } + if (req->labelColorNdx>req->nColors) { + client->errorValue= _XkbErrCode3(0x03,req->nColors,req->labelColorNdx); + return BadMatch; + } + if (req->labelColorNdx==req->baseColorNdx) { + client->errorValue= _XkbErrCode3(0x04,req->baseColorNdx, + req->labelColorNdx); + return BadMatch; + } + + for (i=0;inColors;i++) { + char *name; + name= _GetCountedString(&wire,client->swapped); + if (!name) + return BadAlloc; + if (!XkbAddGeomColor(geom,name,geom->num_colors)) { + free(name); + return BadAlloc; + } + free(name); + } + if (req->nColors!=geom->num_colors) { + client->errorValue= _XkbErrCode3(0x05,req->nColors,geom->num_colors); + return BadMatch; + } + geom->label_color= &geom->colors[req->labelColorNdx]; + geom->base_color= &geom->colors[req->baseColorNdx]; + + if ((status=_CheckSetShapes(geom,req,&wire,client))!=Success) + return status; + + if ((status=_CheckSetSections(geom,req,&wire,client))!=Success) + return status; + + for (i=0;inDoodads;i++) { + status=_CheckSetDoodad(&wire,geom,NULL,client); + if (status!=Success) + return status; + } + + for (i=0;inKeyAliases;i++) { + if (XkbAddGeomKeyAlias(geom,&wire[XkbKeyNameLength],wire)==NULL) + return BadAlloc; + wire+= 2*XkbKeyNameLength; + } + return Success; +} + +static int +_XkbSetGeometry(ClientPtr client, DeviceIntPtr dev, xkbSetGeometryReq *stuff) +{ + XkbDescPtr xkb; + Bool new_name; + xkbNewKeyboardNotify nkn; + XkbGeometryPtr geom,old; + XkbGeometrySizesRec sizes; + Status status; + + xkb= dev->key->xkbInfo->desc; + old= xkb->geom; + xkb->geom= NULL; + + sizes.which= XkbGeomAllMask; + sizes.num_properties= stuff->nProperties; + sizes.num_colors= stuff->nColors; + sizes.num_shapes= stuff->nShapes; + sizes.num_sections= stuff->nSections; + sizes.num_doodads= stuff->nDoodads; + sizes.num_key_aliases= stuff->nKeyAliases; + if ((status= XkbAllocGeometry(xkb,&sizes))!=Success) { + xkb->geom= old; + return status; + } + geom= xkb->geom; + geom->name= stuff->name; + geom->width_mm= stuff->widthMM; + geom->height_mm= stuff->heightMM; + if ((status= _CheckSetGeom(geom,stuff,client))!=Success) { + XkbFreeGeometry(geom,XkbGeomAllMask,TRUE); + xkb->geom= old; + return status; + } + new_name= (xkb->names->geometry!=geom->name); + xkb->names->geometry= geom->name; + if (old) + XkbFreeGeometry(old,XkbGeomAllMask,TRUE); + if (new_name) { + xkbNamesNotify nn; + memset(&nn, 0, sizeof(xkbNamesNotify)); + nn.changed= XkbGeometryNameMask; + XkbSendNamesNotify(dev,&nn); + } + nkn.deviceID= nkn.oldDeviceID= dev->id; + nkn.minKeyCode= nkn.oldMinKeyCode= xkb->min_key_code; + nkn.maxKeyCode= nkn.oldMaxKeyCode= xkb->max_key_code; + nkn.requestMajor= XkbReqCode; + nkn.requestMinor= X_kbSetGeometry; + nkn.changed= XkbNKN_GeometryMask; + XkbSendNewKeyboardNotify(dev,&nkn); + return Success; +} + +int +ProcXkbSetGeometry(ClientPtr client) +{ + DeviceIntPtr dev; + int rc; + + REQUEST(xkbSetGeometryReq); + REQUEST_AT_LEAST_SIZE(xkbSetGeometryReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); + CHK_ATOM_OR_NONE(stuff->name); + + rc = _XkbSetGeometry(client, dev, stuff); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if ((other != dev) && other->key && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + _XkbSetGeometry(client, other, stuff); + } + } + } + + return Success; +} + +/***====================================================================***/ + +int +ProcXkbPerClientFlags(ClientPtr client) +{ + DeviceIntPtr dev; + xkbPerClientFlagsReply rep; + XkbInterestPtr interest; + Mask access_mode = DixGetAttrAccess | DixSetAttrAccess; + + REQUEST(xkbPerClientFlagsReq); + REQUEST_SIZE_MATCH(xkbPerClientFlagsReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, access_mode); + CHK_MASK_LEGAL(0x01,stuff->change,XkbPCF_AllFlagsMask); + CHK_MASK_MATCH(0x02,stuff->change,stuff->value); + + interest = XkbFindClientResource((DevicePtr)dev,client); + memset(&rep, 0, sizeof(xkbPerClientFlagsReply)); + rep.type= X_Reply; + rep.length = 0; + rep.sequenceNumber = client->sequence; + if (stuff->change) { + client->xkbClientFlags&= ~stuff->change; + client->xkbClientFlags|= stuff->value; + } + if (stuff->change&XkbPCF_AutoResetControlsMask) { + Bool want; + want= stuff->value&XkbPCF_AutoResetControlsMask; + if (interest && !want) { + interest->autoCtrls= interest->autoCtrlValues= 0; + } + else if (want && (!interest)) { + XID id = FakeClientID(client->index); + if (!AddResource(id,RT_XKBCLIENT,dev)) + return BadAlloc; + interest= XkbAddClientResource((DevicePtr)dev,client,id); + if (!interest) + return BadAlloc; + } + if (interest && want ) { + register unsigned affect; + affect= stuff->ctrlsToChange; + + CHK_MASK_LEGAL(0x03,affect,XkbAllBooleanCtrlsMask); + CHK_MASK_MATCH(0x04,affect,stuff->autoCtrls); + CHK_MASK_MATCH(0x05,stuff->autoCtrls,stuff->autoCtrlValues); + + interest->autoCtrls&= ~affect; + interest->autoCtrlValues&= ~affect; + interest->autoCtrls|= stuff->autoCtrls&affect; + interest->autoCtrlValues|= stuff->autoCtrlValues&affect; + } + } + rep.supported = XkbPCF_AllFlagsMask; + rep.value= client->xkbClientFlags&XkbPCF_AllFlagsMask; + if (interest) { + rep.autoCtrls= interest->autoCtrls; + rep.autoCtrlValues= interest->autoCtrlValues; + } + else { + rep.autoCtrls= rep.autoCtrlValues= 0; + } + if ( client->swapped ) { + register int n; + swaps(&rep.sequenceNumber, n); + swapl(&rep.supported,n); + swapl(&rep.value,n); + swapl(&rep.autoCtrls,n); + swapl(&rep.autoCtrlValues,n); + } + WriteToClient(client,SIZEOF(xkbPerClientFlagsReply), (char *)&rep); + return Success; +} + +/***====================================================================***/ + +/* all latin-1 alphanumerics, plus parens, minus, underscore, slash */ +/* and wildcards */ +static unsigned char componentSpecLegal[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0xa7, 0xff, 0x87, + 0xfe, 0xff, 0xff, 0x87, 0xfe, 0xff, 0xff, 0x07, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x7f, 0xff +}; + +/* same as above but accepts percent, plus and bar too */ +static unsigned char componentExprLegal[] = { + 0x00, 0x00, 0x00, 0x00, 0x20, 0xaf, 0xff, 0x87, + 0xfe, 0xff, 0xff, 0x87, 0xfe, 0xff, 0xff, 0x17, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x7f, 0xff +}; + +static char * +GetComponentSpec(unsigned char **pWire,Bool allowExpr,int *errRtrn) +{ +int len; +register int i; +unsigned char *wire,*str,*tmp,*legal; + + if (allowExpr) legal= &componentExprLegal[0]; + else legal= &componentSpecLegal[0]; + + wire= *pWire; + len= (*(unsigned char *)wire++); + if (len>0) { + str= calloc(1, len+1); + if (str) { + tmp= str; + for (i=0;ixkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + + status= Success; + str= (unsigned char *)&stuff[1]; + memset(&list, 0, sizeof(XkbSrvListInfoRec)); + list.maxRtrn= stuff->maxNames; + list.pattern[_XkbListKeycodes]= GetComponentSpec(&str,FALSE,&status); + list.pattern[_XkbListTypes]= GetComponentSpec(&str,FALSE,&status); + list.pattern[_XkbListCompat]= GetComponentSpec(&str,FALSE,&status); + list.pattern[_XkbListSymbols]= GetComponentSpec(&str,FALSE,&status); + list.pattern[_XkbListGeometry]= GetComponentSpec(&str,FALSE,&status); + if (status!=Success) + return status; + len= str-((unsigned char *)stuff); + if ((XkbPaddedSize(len)/4)!=stuff->length) + return BadLength; + if ((status=XkbDDXList(dev,&list,client))!=Success) { + free(list.pool); + list.pool = NULL; + return status; + } + memset(&rep, 0, sizeof(xkbListComponentsReply)); + rep.type= X_Reply; + rep.deviceID = dev->id; + rep.sequenceNumber = client->sequence; + rep.length = XkbPaddedSize(list.nPool)/4; + rep.nKeymaps = 0; + rep.nKeycodes = list.nFound[_XkbListKeycodes]; + rep.nTypes = list.nFound[_XkbListTypes]; + rep.nCompatMaps = list.nFound[_XkbListCompat]; + rep.nSymbols = list.nFound[_XkbListSymbols]; + rep.nGeometries = list.nFound[_XkbListGeometry]; + rep.extra= 0; + if (list.nTotal>list.maxRtrn) + rep.extra = (list.nTotal-list.maxRtrn); + if (client->swapped) { + register int n; + swaps(&rep.sequenceNumber,n); + swapl(&rep.length,n); + swaps(&rep.nKeymaps,n); + swaps(&rep.nKeycodes,n); + swaps(&rep.nTypes,n); + swaps(&rep.nCompatMaps,n); + swaps(&rep.nSymbols,n); + swaps(&rep.nGeometries,n); + swaps(&rep.extra,n); + } + WriteToClient(client,SIZEOF(xkbListComponentsReply),(char *)&rep); + if (list.nPool && list.pool) { + WriteToClient(client,XkbPaddedSize(list.nPool), (char *)list.pool); + free(list.pool); + list.pool= NULL; + } + return Success; +} + +/***====================================================================***/ + +int +ProcXkbGetKbdByName(ClientPtr client) +{ + DeviceIntPtr dev; + DeviceIntPtr tmpd; + xkbGetKbdByNameReply rep; + xkbGetMapReply mrep; + xkbGetCompatMapReply crep; + xkbGetIndicatorMapReply irep; + xkbGetNamesReply nrep; + xkbGetGeometryReply grep; + XkbComponentNamesRec names; + XkbDescPtr xkb, new; + unsigned char * str; + char mapFile[PATH_MAX]; + unsigned len; + unsigned fwant,fneed,reported; + int status; + Bool geom_changed; + XkbSrvLedInfoPtr old_sli; + XkbSrvLedInfoPtr sli; + Mask access_mode = DixGetAttrAccess | DixManageAccess; + + REQUEST(xkbGetKbdByNameReq); + REQUEST_AT_LEAST_SIZE(xkbGetKbdByNameReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_KBD_DEVICE(dev, stuff->deviceSpec, client, access_mode); + + xkb = dev->key->xkbInfo->desc; + status= Success; + str= (unsigned char *)&stuff[1]; + if (GetComponentSpec(&str,TRUE,&status)) /* keymap, unsupported */ + return BadMatch; + names.keycodes= GetComponentSpec(&str,TRUE,&status); + names.types= GetComponentSpec(&str,TRUE,&status); + names.compat= GetComponentSpec(&str,TRUE,&status); + names.symbols= GetComponentSpec(&str,TRUE,&status); + names.geometry= GetComponentSpec(&str,TRUE,&status); + if (status!=Success) + return status; + len= str-((unsigned char *)stuff); + if ((XkbPaddedSize(len)/4)!=stuff->length) + return BadLength; + + CHK_MASK_LEGAL(0x01,stuff->want,XkbGBN_AllComponentsMask); + CHK_MASK_LEGAL(0x02,stuff->need,XkbGBN_AllComponentsMask); + + if (stuff->load) + fwant= XkbGBN_AllComponentsMask; + else fwant= stuff->want|stuff->need; + if ((!names.compat)&& + (fwant&(XkbGBN_CompatMapMask|XkbGBN_IndicatorMapMask))) { + names.compat= _XkbDupString("%"); + } + if ((!names.types)&&(fwant&(XkbGBN_TypesMask))) { + names.types= _XkbDupString("%"); + } + if ((!names.symbols)&&(fwant&XkbGBN_SymbolsMask)) { + names.symbols= _XkbDupString("%"); + } + geom_changed= ((names.geometry!=NULL)&&(strcmp(names.geometry,"%")!=0)); + if ((!names.geometry)&&(fwant&XkbGBN_GeometryMask)) { + names.geometry= _XkbDupString("%"); + geom_changed= FALSE; + } + + memset(mapFile, 0, PATH_MAX); + rep.type= X_Reply; + rep.deviceID = dev->id; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.minKeyCode = xkb->min_key_code; + rep.maxKeyCode = xkb->max_key_code; + rep.loaded= FALSE; + fwant= XkbConvertGetByNameComponents(TRUE,stuff->want)|XkmVirtualModsMask; + fneed= XkbConvertGetByNameComponents(TRUE,stuff->need); + rep.reported= XkbConvertGetByNameComponents(FALSE,fwant|fneed); + if (stuff->load) { + fneed|= XkmKeymapRequired; + fwant|= XkmKeymapLegal; + } + if ((fwant|fneed)&XkmSymbolsMask) { + fneed|= XkmKeyNamesIndex|XkmTypesIndex; + fwant|= XkmIndicatorsIndex; + } + + /* We pass dev in here so we can get the old names out if needed. */ + rep.found = XkbDDXLoadKeymapByNames(dev,&names,fwant,fneed,&new, + mapFile,PATH_MAX); + rep.newKeyboard= FALSE; + rep.pad1= rep.pad2= rep.pad3= rep.pad4= 0; + + stuff->want|= stuff->need; + if (new==NULL) + rep.reported= 0; + else { + if (stuff->load) + rep.loaded= TRUE; + if (stuff->load || + ((rep.reported&XkbGBN_SymbolsMask) && (new->compat))) { + XkbChangesRec changes; + memset(&changes, 0, sizeof(changes)); + XkbUpdateDescActions(new, + new->min_key_code,XkbNumKeys(new), + &changes); + } + + if (new->map==NULL) + rep.reported&= ~(XkbGBN_SymbolsMask|XkbGBN_TypesMask); + else if (rep.reported&(XkbGBN_SymbolsMask|XkbGBN_TypesMask)) { + mrep.type= X_Reply; + mrep.deviceID = dev->id; + mrep.sequenceNumber= client->sequence; + mrep.length = ((SIZEOF(xkbGetMapReply)-SIZEOF(xGenericReply))>>2); + mrep.minKeyCode = new->min_key_code; + mrep.maxKeyCode = new->max_key_code; + mrep.present = 0; + mrep.totalSyms = mrep.totalActs = + mrep.totalKeyBehaviors= mrep.totalKeyExplicit= + mrep.totalModMapKeys= mrep.totalVModMapKeys= 0; + if (rep.reported&(XkbGBN_TypesMask|XkbGBN_ClientSymbolsMask)) { + mrep.present|= XkbKeyTypesMask; + mrep.firstType = 0; + mrep.nTypes = mrep.totalTypes= new->map->num_types; + } + else { + mrep.firstType = mrep.nTypes= 0; + mrep.totalTypes= 0; + } + if (rep.reported&XkbGBN_ClientSymbolsMask) { + mrep.present|= (XkbKeySymsMask|XkbModifierMapMask); + mrep.firstKeySym = mrep.firstModMapKey= new->min_key_code; + mrep.nKeySyms = mrep.nModMapKeys= XkbNumKeys(new); + } + else { + mrep.firstKeySym= mrep.firstModMapKey= 0; + mrep.nKeySyms= mrep.nModMapKeys= 0; + } + if (rep.reported&XkbGBN_ServerSymbolsMask) { + mrep.present|= XkbAllServerInfoMask; + mrep.virtualMods= ~0; + mrep.firstKeyAct = mrep.firstKeyBehavior = + mrep.firstKeyExplicit = new->min_key_code; + mrep.nKeyActs = mrep.nKeyBehaviors = + mrep.nKeyExplicit = XkbNumKeys(new); + mrep.firstVModMapKey= new->min_key_code; + mrep.nVModMapKeys= XkbNumKeys(new); + } + else { + mrep.virtualMods= 0; + mrep.firstKeyAct= mrep.firstKeyBehavior= + mrep.firstKeyExplicit = 0; + mrep.nKeyActs= mrep.nKeyBehaviors= mrep.nKeyExplicit= 0; + } + XkbComputeGetMapReplySize(new,&mrep); + rep.length+= SIZEOF(xGenericReply)/4+mrep.length; + } + if (new->compat==NULL) + rep.reported&= ~XkbGBN_CompatMapMask; + else if (rep.reported&XkbGBN_CompatMapMask) { + crep.type= X_Reply; + crep.deviceID= dev->id; + crep.sequenceNumber= client->sequence; + crep.length= 0; + crep.groups= XkbAllGroupsMask; + crep.firstSI= 0; + crep.nSI= crep.nTotalSI= new->compat->num_si; + XkbComputeGetCompatMapReplySize(new->compat,&crep); + rep.length+= SIZEOF(xGenericReply)/4+crep.length; + } + if (new->indicators==NULL) + rep.reported&= ~XkbGBN_IndicatorMapMask; + else if (rep.reported&XkbGBN_IndicatorMapMask) { + irep.type= X_Reply; + irep.deviceID= dev->id; + irep.sequenceNumber= client->sequence; + irep.length= 0; + irep.which= XkbAllIndicatorsMask; + XkbComputeGetIndicatorMapReplySize(new->indicators,&irep); + rep.length+= SIZEOF(xGenericReply)/4+irep.length; + } + if (new->names==NULL) + rep.reported&= ~(XkbGBN_OtherNamesMask|XkbGBN_KeyNamesMask); + else if (rep.reported&(XkbGBN_OtherNamesMask|XkbGBN_KeyNamesMask)) { + nrep.type= X_Reply; + nrep.deviceID= dev->id; + nrep.sequenceNumber= client->sequence; + nrep.length= 0; + nrep.minKeyCode= new->min_key_code; + nrep.maxKeyCode= new->max_key_code; + if (rep.reported&XkbGBN_OtherNamesMask) { + nrep.which= XkbAllNamesMask; + if (new->map!=NULL) + nrep.nTypes= new->map->num_types; + else nrep.nTypes= 0; + nrep.nKTLevels= 0; + nrep.groupNames= XkbAllGroupsMask; + nrep.virtualMods= XkbAllVirtualModsMask; + nrep.indicators= XkbAllIndicatorsMask; + nrep.nRadioGroups= new->names->num_rg; + } + else { + nrep.which= 0; + nrep.nTypes= 0; + nrep.nKTLevels= 0; + nrep.groupNames= 0; + nrep.virtualMods= 0; + nrep.indicators= 0; + nrep.nRadioGroups= 0; + } + if (rep.reported&XkbGBN_KeyNamesMask) { + nrep.which|= XkbKeyNamesMask; + nrep.firstKey= new->min_key_code; + nrep.nKeys= XkbNumKeys(new); + nrep.nKeyAliases= new->names->num_key_aliases; + if (nrep.nKeyAliases) + nrep.which|= XkbKeyAliasesMask; + } + else { + nrep.which&= ~(XkbKeyNamesMask|XkbKeyAliasesMask); + nrep.firstKey= nrep.nKeys= 0; + nrep.nKeyAliases= 0; + } + XkbComputeGetNamesReplySize(new,&nrep); + rep.length+= SIZEOF(xGenericReply)/4+nrep.length; + } + if (new->geom==NULL) + rep.reported&= ~XkbGBN_GeometryMask; + else if (rep.reported&XkbGBN_GeometryMask) { + grep.type= X_Reply; + grep.deviceID= dev->id; + grep.sequenceNumber= client->sequence; + grep.length= 0; + grep.found= TRUE; + grep.pad= 0; + grep.widthMM= grep.heightMM= 0; + grep.nProperties= grep.nColors= grep.nShapes= 0; + grep.nSections= grep.nDoodads= 0; + grep.baseColorNdx= grep.labelColorNdx= 0; + XkbComputeGetGeometryReplySize(new->geom,&grep,None); + rep.length+= SIZEOF(xGenericReply)/4+grep.length; + } + } + + reported= rep.reported; + if ( client->swapped ) { + register int n; + swaps(&rep.sequenceNumber,n); + swapl(&rep.length,n); + swaps(&rep.found,n); + swaps(&rep.reported,n); + } + WriteToClient(client,SIZEOF(xkbGetKbdByNameReply), (char *)&rep); + if (reported&(XkbGBN_SymbolsMask|XkbGBN_TypesMask)) + XkbSendMap(client,new,&mrep); + if (reported&XkbGBN_CompatMapMask) + XkbSendCompatMap(client,new->compat,&crep); + if (reported&XkbGBN_IndicatorMapMask) + XkbSendIndicatorMap(client,new->indicators,&irep); + if (reported&(XkbGBN_KeyNamesMask|XkbGBN_OtherNamesMask)) + XkbSendNames(client,new,&nrep); + if (reported&XkbGBN_GeometryMask) + XkbSendGeometry(client,new->geom,&grep,FALSE); + if (rep.loaded) { + XkbDescPtr old_xkb; + xkbNewKeyboardNotify nkn; + int i,nG,nTG; + old_xkb= xkb; + xkb= new; + dev->key->xkbInfo->desc= xkb; + new= old_xkb; /* so it'll get freed automatically */ + + *xkb->ctrls= *old_xkb->ctrls; + for (nG=nTG=0,i=xkb->min_key_code;i<=xkb->max_key_code;i++) { + nG= XkbKeyNumGroups(xkb,i); + if (nG>=XkbNumKbdGroups) { + nTG= XkbNumKbdGroups; + break; + } + if (nG>nTG) { + nTG= nG; + } + } + xkb->ctrls->num_groups= nTG; + + for (tmpd = inputInfo.devices; tmpd; tmpd = tmpd->next) { + if ((tmpd == dev) || (!IsMaster(tmpd) && GetMaster(tmpd, MASTER_KEYBOARD) == dev)) { + if (tmpd != dev) + XkbCopyDeviceKeymap(tmpd, dev); + + if (tmpd->kbdfeed && tmpd->kbdfeed->xkb_sli) { + old_sli = tmpd->kbdfeed->xkb_sli; + tmpd->kbdfeed->xkb_sli = NULL; + sli = XkbAllocSrvLedInfo(tmpd, tmpd->kbdfeed, NULL, 0); + if (sli) { + sli->explicitState = old_sli->explicitState; + sli->effectiveState = old_sli->effectiveState; + } + tmpd->kbdfeed->xkb_sli = sli; + XkbFreeSrvLedInfo(old_sli); + } + } + } + + nkn.deviceID= nkn.oldDeviceID= dev->id; + nkn.minKeyCode= new->min_key_code; + nkn.maxKeyCode= new->max_key_code; + nkn.oldMinKeyCode= xkb->min_key_code; + nkn.oldMaxKeyCode= xkb->max_key_code; + nkn.requestMajor= XkbReqCode; + nkn.requestMinor= X_kbGetKbdByName; + nkn.changed= XkbNKN_KeycodesMask; + if (geom_changed) + nkn.changed|= XkbNKN_GeometryMask; + XkbSendNewKeyboardNotify(dev,&nkn); + + if (!IsMaster(dev) && dev->u.master) + { + DeviceIntPtr master = dev->u.master; + if (master->u.lastSlave == dev) + { + XkbCopyDeviceKeymap(dev->u.master, dev); + XkbSendNewKeyboardNotify(dev,&nkn); + } + } + } + if ((new!=NULL)&&(new!=xkb)) { + XkbFreeKeyboard(new,XkbAllComponentsMask,TRUE); + new= NULL; + } + free(names.keycodes); + names.keycodes = NULL; + free(names.types); + names.types = NULL; + free(names.compat); + names.compat = NULL; + free(names.symbols); + names.symbols = NULL; + free(names.geometry); + names.geometry = NULL; + return Success; +} + +/***====================================================================***/ + +static int +ComputeDeviceLedInfoSize( DeviceIntPtr dev, + unsigned int what, + XkbSrvLedInfoPtr sli) +{ +int nNames,nMaps; +register unsigned n,bit; + + if (sli==NULL) + return 0; + nNames= nMaps= 0; + if ((what&XkbXI_IndicatorNamesMask)==0) + sli->namesPresent= 0; + if ((what&XkbXI_IndicatorMapsMask)==0) + sli->mapsPresent= 0; + + for (n=0,bit=1;nnames && sli->names[n]!=None) { + sli->namesPresent|= bit; + nNames++; + } + if (sli->maps && XkbIM_InUse(&sli->maps[n])) { + sli->mapsPresent|= bit; + nMaps++; + } + } + return (nNames*4)+(nMaps*SIZEOF(xkbIndicatorMapWireDesc)); +} + +static int +CheckDeviceLedFBs( DeviceIntPtr dev, + int class, + int id, + xkbGetDeviceInfoReply * rep, + ClientPtr client) +{ +int nFBs= 0; +int length= 0; +Bool classOk; + + if (class==XkbDfltXIClass) { + if (dev->kbdfeed) class= KbdFeedbackClass; + else if (dev->leds) class= LedFeedbackClass; + else { + client->errorValue= _XkbErrCode2(XkbErr_BadClass,class); + return XkbKeyboardErrorCode; + } + } + classOk= FALSE; + if ((dev->kbdfeed)&&((class==KbdFeedbackClass)||(class==XkbAllXIClasses))) { + KbdFeedbackPtr kf; + classOk= TRUE; + for (kf= dev->kbdfeed;(kf);kf=kf->next) { + if ((id!=XkbAllXIIds)&&(id!=XkbDfltXIId)&&(id!=kf->ctrl.id)) + continue; + nFBs++; + length+= SIZEOF(xkbDeviceLedsWireDesc); + if (!kf->xkb_sli) + kf->xkb_sli= XkbAllocSrvLedInfo(dev,kf,NULL,0); + length+= ComputeDeviceLedInfoSize(dev,rep->present,kf->xkb_sli); + if (id!=XkbAllXIIds) + break; + } + } + if ((dev->leds)&&((class==LedFeedbackClass)||(class==XkbAllXIClasses))) { + LedFeedbackPtr lf; + classOk= TRUE; + for (lf= dev->leds;(lf);lf=lf->next) { + if ((id!=XkbAllXIIds)&&(id!=XkbDfltXIId)&&(id!=lf->ctrl.id)) + continue; + nFBs++; + length+= SIZEOF(xkbDeviceLedsWireDesc); + if (!lf->xkb_sli) + lf->xkb_sli= XkbAllocSrvLedInfo(dev,NULL,lf,0); + length+= ComputeDeviceLedInfoSize(dev,rep->present,lf->xkb_sli); + if (id!=XkbAllXIIds) + break; + } + } + if (nFBs>0) { + rep->nDeviceLedFBs= nFBs; + rep->length+= (length/4); + return Success; + } + if (classOk) client->errorValue= _XkbErrCode2(XkbErr_BadId,id); + else client->errorValue= _XkbErrCode2(XkbErr_BadClass,class); + return XkbKeyboardErrorCode; +} + +static int +SendDeviceLedInfo( XkbSrvLedInfoPtr sli, + ClientPtr client) +{ +xkbDeviceLedsWireDesc wire; +int length; + + length= 0; + wire.ledClass= sli->class; + wire.ledID= sli->id; + wire.namesPresent= sli->namesPresent; + wire.mapsPresent= sli->mapsPresent; + wire.physIndicators= sli->physIndicators; + wire.state= sli->effectiveState; + if (client->swapped) { + register int n; + swaps(&wire.ledClass,n); + swaps(&wire.ledID,n); + swapl(&wire.namesPresent,n); + swapl(&wire.mapsPresent,n); + swapl(&wire.physIndicators,n); + swapl(&wire.state,n); + } + WriteToClient(client,SIZEOF(xkbDeviceLedsWireDesc),(char *)&wire); + length+= SIZEOF(xkbDeviceLedsWireDesc); + if (sli->namesPresent|sli->mapsPresent) { + register unsigned i,bit; + if (sli->namesPresent) { + CARD32 awire; + for (i=0,bit=1;inamesPresent&bit) { + awire= (CARD32)sli->names[i]; + if (client->swapped) { + register int n; + swapl(&awire,n); + } + WriteToClient(client,4,(char *)&awire); + length+= 4; + } + } + } + if (sli->mapsPresent) { + for (i=0,bit=1;imapsPresent&bit) { + iwire.flags= sli->maps[i].flags; + iwire.whichGroups= sli->maps[i].which_groups; + iwire.groups= sli->maps[i].groups; + iwire.whichMods= sli->maps[i].which_mods; + iwire.mods= sli->maps[i].mods.mask; + iwire.realMods= sli->maps[i].mods.real_mods; + iwire.virtualMods= sli->maps[i].mods.vmods; + iwire.ctrls= sli->maps[i].ctrls; + if (client->swapped) { + register int n; + swaps(&iwire.virtualMods,n); + swapl(&iwire.ctrls,n); + } + WriteToClient(client,SIZEOF(xkbIndicatorMapWireDesc), + (char *)&iwire); + length+= SIZEOF(xkbIndicatorMapWireDesc); + } + } + } + } + return length; +} + +static int +SendDeviceLedFBs( DeviceIntPtr dev, + int class, + int id, + unsigned wantLength, + ClientPtr client) +{ +int length= 0; + + if (class==XkbDfltXIClass) { + if (dev->kbdfeed) class= KbdFeedbackClass; + else if (dev->leds) class= LedFeedbackClass; + } + if ((dev->kbdfeed)&& + ((class==KbdFeedbackClass)||(class==XkbAllXIClasses))) { + KbdFeedbackPtr kf; + for (kf= dev->kbdfeed;(kf);kf=kf->next) { + if ((id==XkbAllXIIds)||(id==XkbDfltXIId)||(id==kf->ctrl.id)) { + length+= SendDeviceLedInfo(kf->xkb_sli,client); + if (id!=XkbAllXIIds) + break; + } + } + } + if ((dev->leds)&& + ((class==LedFeedbackClass)||(class==XkbAllXIClasses))) { + LedFeedbackPtr lf; + for (lf= dev->leds;(lf);lf=lf->next) { + if ((id==XkbAllXIIds)||(id==XkbDfltXIId)||(id==lf->ctrl.id)) { + length+= SendDeviceLedInfo(lf->xkb_sli,client); + if (id!=XkbAllXIIds) + break; + } + } + } + if (length==wantLength) + return Success; + else return BadLength; +} + +int +ProcXkbGetDeviceInfo(ClientPtr client) +{ +DeviceIntPtr dev; +xkbGetDeviceInfoReply rep; +int status,nDeviceLedFBs; +unsigned length,nameLen; +CARD16 ledClass,ledID; +unsigned wanted; +char * str; + + REQUEST(xkbGetDeviceInfoReq); + REQUEST_SIZE_MATCH(xkbGetDeviceInfoReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + wanted= stuff->wanted; + + CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixGetAttrAccess); + CHK_MASK_LEGAL(0x01,wanted,XkbXI_AllDeviceFeaturesMask); + + if ((!dev->button)||((stuff->nBtns<1)&&(!stuff->allBtns))) + wanted&= ~XkbXI_ButtonActionsMask; + if ((!dev->kbdfeed)&&(!dev->leds)) + wanted&= ~XkbXI_IndicatorsMask; + + nameLen= XkbSizeCountedString(dev->name); + memset((char *)&rep, 0, SIZEOF(xkbGetDeviceInfoReply)); + rep.type = X_Reply; + rep.deviceID= dev->id; + rep.sequenceNumber = client->sequence; + rep.length = nameLen/4; + rep.present = wanted; + rep.supported = XkbXI_AllDeviceFeaturesMask; + rep.unsupported = 0; + rep.firstBtnWanted = rep.nBtnsWanted = 0; + rep.firstBtnRtrn = rep.nBtnsRtrn = 0; + if (dev->button) + rep.totalBtns= dev->button->numButtons; + else rep.totalBtns= 0; + rep.devType= dev->xinput_type; + rep.hasOwnState= (dev->key && dev->key->xkbInfo); + rep.nDeviceLedFBs = 0; + if (dev->kbdfeed) rep.dfltKbdFB= dev->kbdfeed->ctrl.id; + else rep.dfltKbdFB= XkbXINone; + if (dev->leds) rep.dfltLedFB= dev->leds->ctrl.id; + else rep.dfltLedFB= XkbXINone; + + ledClass= stuff->ledClass; + ledID= stuff->ledID; + + rep.firstBtnWanted= rep.nBtnsWanted= 0; + rep.firstBtnRtrn= rep.nBtnsRtrn= 0; + if (wanted&XkbXI_ButtonActionsMask) { + if (stuff->allBtns) { + stuff->firstBtn= 0; + stuff->nBtns= dev->button->numButtons; + } + + if ((stuff->firstBtn+stuff->nBtns)>dev->button->numButtons) { + client->errorValue = _XkbErrCode4(0x02,dev->button->numButtons, + stuff->firstBtn, + stuff->nBtns); + return BadValue; + } + else { + rep.firstBtnWanted= stuff->firstBtn; + rep.nBtnsWanted= stuff->nBtns; + if (dev->button->xkb_acts!=NULL) { + XkbAction *act; + register int i; + + rep.firstBtnRtrn= stuff->firstBtn; + rep.nBtnsRtrn= stuff->nBtns; + act= &dev->button->xkb_acts[rep.firstBtnWanted]; + for (i=0;itype!=XkbSA_NoAction) + break; + } + rep.firstBtnRtrn+= i; + rep.nBtnsRtrn-= i; + act= &dev->button->xkb_acts[rep.firstBtnRtrn+rep.nBtnsRtrn-1]; + for (i=0;itype!=XkbSA_NoAction) + break; + } + rep.nBtnsRtrn-= i; + } + rep.length+= (rep.nBtnsRtrn*SIZEOF(xkbActionWireDesc))/4; + } + } + + if (wanted&XkbXI_IndicatorsMask) { + status= CheckDeviceLedFBs(dev,ledClass,ledID,&rep,client); + if (status!=Success) + return status; + } + length= rep.length*4; + nDeviceLedFBs = rep.nDeviceLedFBs; + if (client->swapped) { + register int n; + swaps(&rep.sequenceNumber,n); + swapl(&rep.length,n); + swaps(&rep.present,n); + swaps(&rep.supported,n); + swaps(&rep.unsupported,n); + swaps(&rep.nDeviceLedFBs,n); + swapl(&rep.type,n); + } + WriteToClient(client,SIZEOF(xkbGetDeviceInfoReply), (char *)&rep); + + str= malloc(nameLen); + if (!str) + return BadAlloc; + XkbWriteCountedString(str,dev->name,client->swapped); + WriteToClient(client,nameLen,str); + free(str); + length-= nameLen; + + if (rep.nBtnsRtrn>0) { + int sz; + xkbActionWireDesc * awire; + sz= rep.nBtnsRtrn*SIZEOF(xkbActionWireDesc); + awire= (xkbActionWireDesc *)&dev->button->xkb_acts[rep.firstBtnRtrn]; + WriteToClient(client,sz,(char *)awire); + length-= sz; + } + if (nDeviceLedFBs>0) { + status= SendDeviceLedFBs(dev,ledClass,ledID,length,client); + if (status!=Success) + return status; + } + else if (length!=0) { + ErrorF("[xkb] Internal Error! BadLength in ProcXkbGetDeviceInfo\n"); + ErrorF("[xkb] Wrote %d fewer bytes than expected\n",length); + return BadLength; + } + return Success; +} + +static char * +CheckSetDeviceIndicators( char * wire, + DeviceIntPtr dev, + int num, + int * status_rtrn, + ClientPtr client) +{ +xkbDeviceLedsWireDesc * ledWire; +int i; +XkbSrvLedInfoPtr sli; + + ledWire= (xkbDeviceLedsWireDesc *)wire; + for (i=0;iswapped) { + register int n; + swaps(&ledWire->ledClass,n); + swaps(&ledWire->ledID,n); + swapl(&ledWire->namesPresent,n); + swapl(&ledWire->mapsPresent,n); + swapl(&ledWire->physIndicators,n); + } + + sli= XkbFindSrvLedInfo(dev,ledWire->ledClass,ledWire->ledID, + XkbXI_IndicatorsMask); + if (sli!=NULL) { + register int n; + register unsigned bit; + int nMaps,nNames; + CARD32 *atomWire; + xkbIndicatorMapWireDesc *mapWire; + + nMaps= nNames= 0; + for (n=0,bit=1;nnamesPresent&bit) + nNames++; + if (ledWire->mapsPresent&bit) + nMaps++; + } + atomWire= (CARD32 *)&ledWire[1]; + if (nNames>0) { + for (n=0;nswapped) { + register int t; + swapl(atomWire,t); + } + CHK_ATOM_OR_NONE3(((Atom)(*atomWire)),client->errorValue, + *status_rtrn,NULL); + atomWire++; + } + } + mapWire= (xkbIndicatorMapWireDesc *)atomWire; + if (nMaps>0) { + for (n=0;nswapped) { + register int t; + swaps(&mapWire->virtualMods,t); + swapl(&mapWire->ctrls,t); + } + CHK_MASK_LEGAL3(0x21,mapWire->whichGroups, + XkbIM_UseAnyGroup, + client->errorValue, + *status_rtrn,NULL); + CHK_MASK_LEGAL3(0x22,mapWire->whichMods,XkbIM_UseAnyMods, + client->errorValue, + *status_rtrn,NULL); + mapWire++; + } + } + ledWire= (xkbDeviceLedsWireDesc *)mapWire; + } + else { + /* SHOULD NEVER HAPPEN */ + return (char *)ledWire; + } + } + return (char *)ledWire; +} + +static char * +SetDeviceIndicators( char * wire, + DeviceIntPtr dev, + unsigned changed, + int num, + int * status_rtrn, + ClientPtr client, + xkbExtensionDeviceNotify *ev) +{ +xkbDeviceLedsWireDesc * ledWire; +int i; +XkbEventCauseRec cause; +unsigned namec,mapc,statec; +xkbExtensionDeviceNotify ed; +XkbChangesRec changes; +DeviceIntPtr kbd; + + memset((char *)&ed, 0, sizeof(xkbExtensionDeviceNotify)); + memset((char *)&changes, 0, sizeof(XkbChangesRec)); + XkbSetCauseXkbReq(&cause,X_kbSetDeviceInfo,client); + ledWire= (xkbDeviceLedsWireDesc *)wire; + for (i=0;iledClass,ledWire->ledID, + XkbXI_IndicatorMapsMask); + if (!sli) { + /* SHOULD NEVER HAPPEN!! */ + return (char *)ledWire; + } + + atomWire= (CARD32 *)&ledWire[1]; + if (changed&XkbXI_IndicatorNamesMask) { + namec= sli->namesPresent|ledWire->namesPresent; + memset((char *)sli->names, 0, XkbNumIndicators*sizeof(Atom)); + } + if (ledWire->namesPresent) { + sli->namesPresent= ledWire->namesPresent; + memset((char *)sli->names, 0, XkbNumIndicators*sizeof(Atom)); + for (n=0,bit=1;nnamesPresent&bit) { + sli->names[n]= (Atom)*atomWire; + if (sli->names[n]==None) + ledWire->namesPresent&= ~bit; + atomWire++; + } + } + } + mapWire= (xkbIndicatorMapWireDesc *)atomWire; + if (changed&XkbXI_IndicatorMapsMask) { + mapc= sli->mapsPresent|ledWire->mapsPresent; + sli->mapsPresent= ledWire->mapsPresent; + memset((char*)sli->maps, 0, XkbNumIndicators*sizeof(XkbIndicatorMapRec)); + } + if (ledWire->mapsPresent) { + for (n=0,bit=1;nmapsPresent&bit) { + sli->maps[n].flags= mapWire->flags; + sli->maps[n].which_groups= mapWire->whichGroups; + sli->maps[n].groups= mapWire->groups; + sli->maps[n].which_mods= mapWire->whichMods; + sli->maps[n].mods.mask= mapWire->mods; + sli->maps[n].mods.real_mods=mapWire->realMods; + sli->maps[n].mods.vmods= mapWire->virtualMods; + sli->maps[n].ctrls= mapWire->ctrls; + mapWire++; + } + } + } + if (changed&XkbXI_IndicatorStateMask) { + statec= sli->effectiveState^ledWire->state; + sli->explicitState&= ~statec; + sli->explicitState|= (ledWire->state&statec); + } + if (namec) + XkbApplyLedNameChanges(dev,sli,namec,&ed,&changes,&cause); + if (mapc) + XkbApplyLedMapChanges(dev,sli,mapc,&ed,&changes,&cause); + if (statec) + XkbApplyLedStateChanges(dev,sli,statec,&ed,&changes,&cause); + + kbd= dev; + if ((sli->flags&XkbSLI_HasOwnState)==0) + kbd = inputInfo.keyboard; + + XkbFlushLedEvents(dev,kbd,sli,&ed,&changes,&cause); + ledWire= (xkbDeviceLedsWireDesc *)mapWire; + } + return (char *)ledWire; +} + + +static int +_XkbSetDeviceInfo(ClientPtr client, DeviceIntPtr dev, + xkbSetDeviceInfoReq *stuff) +{ + char *wire; + + wire= (char *)&stuff[1]; + if (stuff->change&XkbXI_ButtonActionsMask) { + if (!dev->button) { + client->errorValue = _XkbErrCode2(XkbErr_BadClass,ButtonClass); + return XkbKeyboardErrorCode; + } + if ((stuff->firstBtn+stuff->nBtns)>dev->button->numButtons) { + client->errorValue= _XkbErrCode4(0x02,stuff->firstBtn,stuff->nBtns, + dev->button->numButtons); + return BadMatch; + } + wire+= (stuff->nBtns*SIZEOF(xkbActionWireDesc)); + } + if (stuff->change&XkbXI_IndicatorsMask) { + int status= Success; + wire= CheckSetDeviceIndicators(wire,dev,stuff->nDeviceLedFBs, + &status,client); + if (status!=Success) + return status; + } + if (((wire-((char *)stuff))/4)!=stuff->length) + return BadLength; + + return Success; +} + +static int +_XkbSetDeviceInfoCheck(ClientPtr client, DeviceIntPtr dev, + xkbSetDeviceInfoReq *stuff) +{ + char *wire; + xkbExtensionDeviceNotify ed; + + memset((char *)&ed, 0, SIZEOF(xkbExtensionDeviceNotify)); + ed.deviceID= dev->id; + wire= (char *)&stuff[1]; + if (stuff->change&XkbXI_ButtonActionsMask) { + int nBtns,sz,i; + XkbAction * acts; + DeviceIntPtr kbd; + + nBtns= dev->button->numButtons; + acts= dev->button->xkb_acts; + if (acts==NULL) { + acts= calloc(nBtns, sizeof(XkbAction)); + if (!acts) + return BadAlloc; + dev->button->xkb_acts= acts; + } + sz= stuff->nBtns*SIZEOF(xkbActionWireDesc); + memcpy((char *)&acts[stuff->firstBtn],(char *)wire,sz); + wire+= sz; + ed.reason|= XkbXI_ButtonActionsMask; + ed.firstBtn= stuff->firstBtn; + ed.nBtns= stuff->nBtns; + + if (dev->key) kbd= dev; + else kbd= inputInfo.keyboard; + acts= &dev->button->xkb_acts[stuff->firstBtn]; + for (i=0;inBtns;i++,acts++) { + if (acts->type!=XkbSA_NoAction) + XkbSetActionKeyMods(kbd->key->xkbInfo->desc,acts,0); + } + } + if (stuff->change&XkbXI_IndicatorsMask) { + int status= Success; + wire= SetDeviceIndicators(wire,dev,stuff->change, + stuff->nDeviceLedFBs, &status,client,&ed); + if (status!=Success) + return status; + } + if ((stuff->change)&&(ed.reason)) + XkbSendExtensionDeviceNotify(dev,client,&ed); + return Success; +} + +int +ProcXkbSetDeviceInfo(ClientPtr client) +{ + DeviceIntPtr dev; + int rc; + + REQUEST(xkbSetDeviceInfoReq); + REQUEST_AT_LEAST_SIZE(xkbSetDeviceInfoReq); + + if (!(client->xkbClientFlags&_XkbClientInitialized)) + return BadAccess; + + CHK_ANY_DEVICE(dev, stuff->deviceSpec, client, DixManageAccess); + CHK_MASK_LEGAL(0x01,stuff->change,XkbXI_AllFeaturesMask); + + rc = _XkbSetDeviceInfoCheck(client, dev, stuff); + + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd || stuff->deviceSpec == XkbUseCorePtr) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if (((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) && + ((stuff->deviceSpec == XkbUseCoreKbd && other->key) || + (stuff->deviceSpec == XkbUseCorePtr && other->button))) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + { + rc = _XkbSetDeviceInfoCheck(client, other, stuff); + if (rc != Success) + return rc; + } + } + } + } + + /* checks done, apply */ + rc = _XkbSetDeviceInfo(client, dev, stuff); + if (rc != Success) + return rc; + + if (stuff->deviceSpec == XkbUseCoreKbd || stuff->deviceSpec == XkbUseCorePtr) + { + DeviceIntPtr other; + for (other = inputInfo.devices; other; other = other->next) + { + if (((other != dev) && !IsMaster(other) && GetMaster(other, MASTER_KEYBOARD) == dev) && + ((stuff->deviceSpec == XkbUseCoreKbd && other->key) || + (stuff->deviceSpec == XkbUseCorePtr && other->button))) + { + rc = XaceHook(XACE_DEVICE_ACCESS, client, other, DixManageAccess); + if (rc == Success) + { + rc = _XkbSetDeviceInfo(client, other, stuff); + if (rc != Success) + return rc; + } + } + } + } + + return Success; +} + +/***====================================================================***/ + +int +ProcXkbSetDebuggingFlags(ClientPtr client) +{ +CARD32 newFlags,newCtrls,extraLength; +xkbSetDebuggingFlagsReply rep; +int rc; + + REQUEST(xkbSetDebuggingFlagsReq); + REQUEST_AT_LEAST_SIZE(xkbSetDebuggingFlagsReq); + + rc = XaceHook(XACE_SERVER_ACCESS, client, DixDebugAccess); + if (rc != Success) + return rc; + + newFlags= xkbDebugFlags&(~stuff->affectFlags); + newFlags|= (stuff->flags&stuff->affectFlags); + newCtrls= xkbDebugCtrls&(~stuff->affectCtrls); + newCtrls|= (stuff->ctrls&stuff->affectCtrls); + if (xkbDebugFlags || newFlags || stuff->msgLength) { + ErrorF("[xkb] XkbDebug: Setting debug flags to 0x%lx\n",(long)newFlags); + if (newCtrls!=xkbDebugCtrls) + ErrorF("[xkb] XkbDebug: Setting debug controls to 0x%lx\n",(long)newCtrls); + } + extraLength= (stuff->length<<2)-sz_xkbSetDebuggingFlagsReq; + if (stuff->msgLength>0) { + char *msg; + if (extraLengthmsgLength)) { + ErrorF("[xkb] XkbDebug: msgLength= %d, length= %ld (should be %d)\n", + stuff->msgLength,(long)extraLength, + XkbPaddedSize(stuff->msgLength)); + return BadLength; + } + msg= (char *)&stuff[1]; + if (msg[stuff->msgLength-1]!='\0') { + ErrorF("[xkb] XkbDebug: message not null-terminated\n"); + return BadValue; + } + ErrorF("[xkb] XkbDebug: %s\n",msg); + } + xkbDebugFlags = newFlags; + xkbDebugCtrls = newCtrls; + + rep.type= X_Reply; + rep.length = 0; + rep.sequenceNumber = client->sequence; + rep.currentFlags = newFlags; + rep.currentCtrls = newCtrls; + rep.supportedFlags = ~0; + rep.supportedCtrls = ~0; + if ( client->swapped ) { + register int n; + swaps(&rep.sequenceNumber, n); + swapl(&rep.currentFlags, n); + swapl(&rep.currentCtrls, n); + swapl(&rep.supportedFlags, n); + swapl(&rep.supportedCtrls, n); + } + WriteToClient(client,SIZEOF(xkbSetDebuggingFlagsReply), (char *)&rep); + return Success; +} + +/***====================================================================***/ + +static int +ProcXkbDispatch (ClientPtr client) +{ + REQUEST(xReq); + switch (stuff->data) + { + case X_kbUseExtension: + return ProcXkbUseExtension(client); + case X_kbSelectEvents: + return ProcXkbSelectEvents(client); + case X_kbBell: + return ProcXkbBell(client); + case X_kbGetState: + return ProcXkbGetState(client); + case X_kbLatchLockState: + return ProcXkbLatchLockState(client); + case X_kbGetControls: + return ProcXkbGetControls(client); + case X_kbSetControls: + return ProcXkbSetControls(client); + case X_kbGetMap: + return ProcXkbGetMap(client); + case X_kbSetMap: + return ProcXkbSetMap(client); + case X_kbGetCompatMap: + return ProcXkbGetCompatMap(client); + case X_kbSetCompatMap: + return ProcXkbSetCompatMap(client); + case X_kbGetIndicatorState: + return ProcXkbGetIndicatorState(client); + case X_kbGetIndicatorMap: + return ProcXkbGetIndicatorMap(client); + case X_kbSetIndicatorMap: + return ProcXkbSetIndicatorMap(client); + case X_kbGetNamedIndicator: + return ProcXkbGetNamedIndicator(client); + case X_kbSetNamedIndicator: + return ProcXkbSetNamedIndicator(client); + case X_kbGetNames: + return ProcXkbGetNames(client); + case X_kbSetNames: + return ProcXkbSetNames(client); + case X_kbGetGeometry: + return ProcXkbGetGeometry(client); + case X_kbSetGeometry: + return ProcXkbSetGeometry(client); + case X_kbPerClientFlags: + return ProcXkbPerClientFlags(client); + case X_kbListComponents: + return ProcXkbListComponents(client); + case X_kbGetKbdByName: + return ProcXkbGetKbdByName(client); + case X_kbGetDeviceInfo: + return ProcXkbGetDeviceInfo(client); + case X_kbSetDeviceInfo: + return ProcXkbSetDeviceInfo(client); + case X_kbSetDebuggingFlags: + return ProcXkbSetDebuggingFlags(client); + default: + return BadRequest; + } +} + +static int +XkbClientGone(pointer data,XID id) +{ + DevicePtr pXDev = (DevicePtr)data; + + if (!XkbRemoveResourceClient(pXDev,id)) { + ErrorF("[xkb] Internal Error! bad RemoveResourceClient in XkbClientGone\n"); + } + return 1; +} + +void +XkbExtensionInit(void) +{ + ExtensionEntry *extEntry; + + RT_XKBCLIENT = CreateNewResourceType(XkbClientGone, "XkbClient"); + if (!RT_XKBCLIENT) + return; + + if (!XkbInitPrivates()) + return; + + if ((extEntry = AddExtension(XkbName, XkbNumberEvents, XkbNumberErrors, + ProcXkbDispatch, SProcXkbDispatch, + NULL, StandardMinorOpcode))) { + XkbReqCode = (unsigned char)extEntry->base; + XkbEventBase = (unsigned char)extEntry->eventBase; + XkbErrorBase = (unsigned char)extEntry->errorBase; + XkbKeyboardErrorCode = XkbErrorBase+XkbKeyboard; + } + return; +} + + -- cgit v1.2.3