亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bidiutil.java

?? 源碼為Eclipse開源開發平臺桌面開發工具SWT的源代碼,
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
	}	if ((fontLanguageInfo & GCP_GLYPHSHAPE) == GCP_GLYPHSHAPE) {		dwFlags |= GCP_GLYPHSHAPE;	}	if ((flags & CLASSIN) == CLASSIN) {		// set classification values for the substring, classification values		// can be specified on input		dwFlags |= GCP_CLASSIN;		OS.MoveMemory(result.lpClass, classBuffer, classBuffer.length);	}	int glyphCount = 0;	for (int i=0; i<offsets.length-1; i++) {		int offset = offsets [i];		int length = offsets [i+1] - offsets [i];		// The number of glyphs expected is <= length (segment length);		// the actual number returned may be less in case of Arabic ligatures.		result.nGlyphs = length;		TCHAR textBuffer2 = new TCHAR(lpCs[1], text.substring(offset, offset + length), false);		OS.GetCharacterPlacement(gc.handle, textBuffer2, textBuffer2.length(), 0, result, dwFlags);		if (order != null) {			int [] order2 = new int [length];			OS.MoveMemory(order2, result.lpOrder, order2.length * 4);			translateOrder(order2, glyphCount, isRightOriented);			System.arraycopy (order2, 0, order, offset, length);		}		if (classBuffer != null) {			byte [] classBuffer2 = new byte [length];			OS.MoveMemory(classBuffer2, result.lpClass, classBuffer2.length);			System.arraycopy (classBuffer2, 0, classBuffer, offset, length);		}		glyphCount += result.nGlyphs;		// We concatenate successive results of calls to GCP.		// For Arabic, it is the only good method since the number of output		// glyphs might be less than the number of input characters.		// This assumes that the whole line is built by successive adjacent		// segments without overlapping.		result.lpOrder += length * 4;		result.lpClass += length;	}	/* Free the memory that was allocated. */	OS.HeapFree(hHeap, 0, lpClass);	OS.HeapFree(hHeap, 0, lpOrder);}/** * Return bidi attribute information for the font in the specified gc.   * <p> * * @param gc the gc to query * @return bitwise OR of the REORDER, LIGATE and GLYPHSHAPE flags * 	defined by this class. */public static int getFontBidiAttributes(GC gc) {	int fontStyle = 0;	int fontLanguageInfo = OS.GetFontLanguageInfo(gc.handle);	if (((fontLanguageInfo & GCP_REORDER) != 0)) {		fontStyle |= REORDER;	}	if (((fontLanguageInfo & GCP_LIGATE) != 0)) {		fontStyle |= LIGATE;	}	if (((fontLanguageInfo & GCP_GLYPHSHAPE) != 0)) {		fontStyle |= GLYPHSHAPE;	}	return fontStyle;	}/** * Return the active keyboard language type.   * <p> * * @return an integer representing the active keyboard language (KEYBOARD_BIDI, *  KEYBOARD_NON_BIDI) */public static int getKeyboardLanguage() {	int layout = OS.GetKeyboardLayout(0);	// only interested in low 2 bytes, which is the primary	// language identifier	layout = layout & 0x000000FF;	if (layout == LANG_HEBREW) return KEYBOARD_BIDI;	if (layout == LANG_ARABIC) return KEYBOARD_BIDI;	// return non-bidi for all other languages	return KEYBOARD_NON_BIDI;}/** * Return the languages that are installed for the keyboard.   * <p> * * @return integer array with an entry for each installed language */static int[] getKeyboardLanguageList() {	int maxSize = 10;	int[] tempList = new int[maxSize];	int size = OS.GetKeyboardLayoutList(maxSize, tempList);	int[] list = new int[size];	System.arraycopy(tempList, 0, list, 0, size);	return list;}/** * Return whether or not the platform supports a bidi language.  Determine this * by looking at the languages that are installed.   * <p> * * @return true if bidi is supported, false otherwise. Always  * 	false on Windows CE. */public static boolean isBidiPlatform() {	if (OS.IsWinCE) return false;	if (isBidiPlatform != -1) return isBidiPlatform == 1; // already set	isBidiPlatform = 0;		// The following test is a workaround for bug report 27629. On WinXP,	// both bidi and complex script (e.g., Thai) languages must be installed	// at the same time.  Since the bidi platform calls do not support	// double byte characters, there is no way to run Eclipse using the	// complex script languages on XP, so constrain this test to answer true	// only if a bidi input language is defined.  Doing so will allow complex	// script languages to work (e.g., one can install bidi and complex script 	// languages, but only install the Thai keyboard).	if (!isKeyboardBidi()) return false;		Callback callback = null;	try {		callback = new Callback (Class.forName (CLASS_NAME), "EnumSystemLanguageGroupsProc", 5);		int lpEnumSystemLanguageGroupsProc = callback.getAddress ();			if (lpEnumSystemLanguageGroupsProc == 0) SWT.error(SWT.ERROR_NO_MORE_CALLBACKS);		OS.EnumSystemLanguageGroups(lpEnumSystemLanguageGroupsProc, OS.LGRPID_INSTALLED, 0);		callback.dispose ();	} catch (ClassNotFoundException e) {		if (callback != null) callback.dispose();	}	if (isBidiPlatform == 1) return true;	// need to look at system code page for NT & 98 platforms since EnumSystemLanguageGroups is	// not supported for these platforms	String codePage = String.valueOf(OS.GetACP());	if (CD_PG_ARABIC.equals(codePage) || CD_PG_HEBREW.equals(codePage)) {		isBidiPlatform = 1;	}	return isBidiPlatform == 1;}/** * Return whether or not the keyboard supports input of a bidi language.  Determine this * by looking at the languages that are installed for the keyboard.   * <p> * * @return true if bidi is supported, false otherwise. */public static boolean isKeyboardBidi() {	int[] list = getKeyboardLanguageList();	for (int i=0; i<list.length; i++) {		int id = list[i] & 0x000000FF;		if ((id == LANG_ARABIC) || (id == LANG_HEBREW)) {			return true;		}	}	return false;}/** * Removes the specified language listener. * <p> * * @param hwnd the handle of the Control that is listening for keyboard language changes */public static void removeLanguageListener (int hwnd) {	languageMap.remove(new Integer(hwnd));	unsubclass(hwnd);}		/** * Switch the keyboard language to the specified language type.  We do * not distinguish between mulitple bidi or multiple non-bidi languages, so * set the keyboard to the first language of the given type. * <p> * * @param language integer representing language. One of  * 	KEYBOARD_BIDI, KEYBOARD_NON_BIDI. */public static void setKeyboardLanguage(int language) {	// don't switch the keyboard if it doesn't need to be	if (language == getKeyboardLanguage()) return;		if (language == KEYBOARD_BIDI) {		// get the list of active languages		int[] list = getKeyboardLanguageList();		// set to first bidi language		for (int i=0; i<list.length; i++) {			int id = list[i] & 0x000000FF;			if ((id == LANG_ARABIC) || (id == LANG_HEBREW)) {				OS.ActivateKeyboardLayout(list[i], 0);				return;			}		}	} else {		// get the list of active languages		int[] list = getKeyboardLanguageList();		// set to the first non-bidi language (anything not		// hebrew or arabic)		for (int i=0; i<list.length; i++) {			int id = list[i] & 0x000000FF;			if ((id != LANG_HEBREW) && (id != LANG_ARABIC)) {				OS.ActivateKeyboardLayout(list[i], 0);				return;			}		}	}}/** * Sets the orientation (writing order) of the specified control. Text will  * be right aligned for right to left writing order. * <p> *  * @param hwnd the handle of the Control to change the orientation of * @param orientation one of SWT.RIGHT_TO_LEFT or SWT.LEFT_TO_RIGHT * @return true if the orientation was changed, false if the orientation  * 	could not be changed */public static boolean setOrientation (int hwnd, int orientation) {	if ((OS.WIN32_MAJOR << 16 | OS.WIN32_MINOR) < (4 << 16 | 10)) return false;	int bits = OS.GetWindowLong (hwnd, OS.GWL_EXSTYLE);	if ((orientation & SWT.RIGHT_TO_LEFT) != 0) {		bits |= OS.WS_EX_LAYOUTRTL; 	} else {		bits &= ~OS.WS_EX_LAYOUTRTL;	} 	OS.SetWindowLong (hwnd, OS.GWL_EXSTYLE, bits);	return true;}/** * Override the window proc. *  * @param hwnd control to override the window proc of */static void subclass(int hwnd) {	Integer key = new Integer(hwnd);	if (oldProcMap.get(key) == null) {		int oldProc = OS.GetWindowLong(hwnd, OS.GWL_WNDPROC);		oldProcMap.put(key, new Integer(oldProc));		OS.SetWindowLong(hwnd, OS.GWL_WNDPROC, callback.getAddress());	}}/** *  Reverse the character array.  Used for right orientation. *  * @param charArray character array to reverse */static void reverse(char[] charArray) {	int length = charArray.length;	for (int i = 0; i <= (length  - 1) / 2; i++) {		char tmp = charArray[i];		charArray[i] = charArray[length - 1 - i];		charArray[length - 1 - i] = tmp;	}}	/** *  Reverse the integer array.  Used for right orientation. *  * @param intArray integer array to reverse */static void reverse(int[] intArray) {	int length = intArray.length;	for (int i = 0; i <= (length  - 1) / 2; i++) {		int tmp = intArray[i];		intArray[i] = intArray[length - 1 - i];		intArray[length - 1 - i] = tmp;	}}	/** * Adjust the order array so that it is relative to the start of the line.  Also reverse the order array if the orientation * is to the right. *  * @param orderArray  integer array of order values to translate * @param glyphCount  number of glyphs that have been processed for the current line * @param isRightOriented  flag indicating whether or not current orientation is to the right*/static void translateOrder(int[] orderArray, int glyphCount, boolean isRightOriented) {	int maxOrder = 0;	int length = orderArray.length;	if (isRightOriented) {  		for (int i=0; i<length; i++) {			maxOrder = Math.max(maxOrder, orderArray[i]);		}		} 	for (int i=0; i<length; i++) {		if (isRightOriented) orderArray[i] = maxOrder - orderArray[i]; 		orderArray [i] += glyphCount;	}}/** * Remove the overridden the window proc. *  * @param hwnd control to remove the window proc override for */static void unsubclass(int hwnd) {	Integer key = new Integer(hwnd);	if (languageMap.get(key) == null && keyMap.get(key) == null) {		Integer proc = (Integer) oldProcMap.remove(key);		if (proc == null) return;		OS.SetWindowLong(hwnd, OS.GWL_WNDPROC, proc.intValue());	}	}/** * Window proc to intercept keyboard language switch event (WS_INPUTLANGCHANGE) * and widget orientation changes. * Run the Control's registered runnable when the keyboard language is switched. *  * @param hwnd handle of the control that is listening for the keyboard language *  change event * @param msg window message */static int windowProc (int hwnd, int msg, int wParam, int lParam) {	Integer key = new Integer (hwnd);	switch (msg) {		case 0x51 /*OS.WM_INPUTLANGCHANGE*/:			Runnable runnable = (Runnable) languageMap.get (key);			if (runnable != null) runnable.run ();			break;		}	Integer oldProc = (Integer)oldProcMap.get(key);	return OS.CallWindowProc (oldProc.intValue(), hwnd, msg, wParam, lParam);}}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
中文字幕av资源一区| 欧美成人国产一区二区| 成人午夜激情在线| 国产久卡久卡久卡久卡视频精品| 香蕉影视欧美成人| 日本三级韩国三级欧美三级| 日本视频在线一区| 黄色日韩三级电影| 国产精品一区一区三区| 国产电影一区二区三区| 成人免费视频国产在线观看| 成人app下载| 色综合一区二区| 欧美日韩国产成人在线91| 欧美日韩国产高清一区二区三区| 777xxx欧美| 久久久国际精品| 国产精品福利一区| 亚洲综合一区二区| 久久av老司机精品网站导航| 狠狠狠色丁香婷婷综合久久五月| 成人网在线免费视频| 色综合中文字幕国产 | 亚洲成av人片在线观看无码| 日本一区二区高清| 夜夜夜精品看看| 麻豆91精品91久久久的内涵| 国产精选一区二区三区| 91在线小视频| 精品欧美一区二区久久| 国产精品人成在线观看免费| 亚洲国产视频在线| 国产一区二区在线免费观看| 色狠狠色狠狠综合| 欧美大肚乱孕交hd孕妇| 中文字幕一区二区三区在线播放| 亚洲一区二区欧美| 国产91精品免费| 欧美老肥妇做.爰bbww| 国产欧美综合在线观看第十页| 一区二区三区精品视频在线| 狠狠色狠狠色综合日日91app| 91在线视频免费观看| 欧美男人的天堂一二区| 欧美国产一区视频在线观看| 亚洲国产成人porn| 99久久精品一区| 日韩你懂的在线观看| 亚洲欧洲综合另类| 国产成人久久精品77777最新版本| 欧美性猛片aaaaaaa做受| 国产三级欧美三级日产三级99 | 免费的成人av| 欧美午夜影院一区| 国产精品第一页第二页第三页| 日韩黄色一级片| 欧美在线观看视频在线| 国产精品久久久久天堂| 精品一区二区免费| 欧美人xxxx| 亚洲午夜在线视频| 99国产麻豆精品| 国产精品视频免费看| 欧美bbbbb| 欧美一区二区福利视频| 亚洲成人免费在线| 欧美天堂亚洲电影院在线播放| 中文字幕一区视频| 成人一区二区三区在线观看| 国产欧美久久久精品影院| 精品在线免费观看| 日韩视频中午一区| 蜜桃视频一区二区| 欧美一区二区三区爱爱| 日日摸夜夜添夜夜添国产精品| 日本高清不卡视频| 亚洲福利视频导航| 91精品国产综合久久久蜜臀图片| 亚洲综合色自拍一区| 色94色欧美sute亚洲13| 亚洲一二三四在线| 欧美性xxxxx极品少妇| 亚洲成av人片一区二区| 欧美日韩高清影院| 蜜桃视频在线观看一区二区| 欧美大片在线观看| 国产91精品精华液一区二区三区| 视频一区二区三区入口| 日韩一区二区在线播放| 狠狠色丁香婷综合久久| 欧美国产欧美综合| 日本高清不卡一区| 日本中文一区二区三区| 久久亚洲欧美国产精品乐播| 国产传媒日韩欧美成人| 亚洲欧美精品午睡沙发| 欧美欧美午夜aⅴ在线观看| 日韩电影一区二区三区| 久久精品亚洲国产奇米99 | 国产精品国产自产拍高清av| 99亚偷拍自图区亚洲| 亚洲在线一区二区三区| 欧美一卡2卡三卡4卡5免费| 六月丁香综合在线视频| 国产精品天干天干在观线| 色噜噜狠狠成人网p站| 三级亚洲高清视频| 国产精品视频线看| 欧美精品九九99久久| 国产馆精品极品| 香港成人在线视频| 久久精品人人做| 欧美三级电影精品| 成人午夜av在线| 成人a级免费电影| 日日夜夜精品视频天天综合网| 国产欧美日本一区二区三区| 欧美日本在线观看| 成人精品免费视频| 美国一区二区三区在线播放| 亚洲欧美激情插| 久久影院午夜论| 欧美人与性动xxxx| www.色精品| 国产一区不卡在线| 视频在线在亚洲| 亚洲欧美国产77777| 欧美电视剧在线观看完整版| 91视频com| 国产精品18久久久久久vr| 亚洲午夜免费视频| 亚洲私人黄色宅男| 国产午夜精品理论片a级大结局| 在线播放日韩导航| 欧美伊人久久大香线蕉综合69 | 一本色道久久综合狠狠躁的推荐| 麻豆精品在线播放| 亚洲123区在线观看| 一区在线观看视频| 国产精品久久久久影院| 欧美精品一区二区三区在线播放| 欧美日韩国产高清一区二区三区 | 国产喷白浆一区二区三区| 精品久久久久久久久久久久久久久 | 成人动漫视频在线| 韩国三级在线一区| 日精品一区二区| 五月天一区二区三区| 亚洲综合丝袜美腿| 亚洲欧洲性图库| 国产欧美精品在线观看| 久久久不卡网国产精品二区| 日韩女优毛片在线| 精品裸体舞一区二区三区| 日韩一级二级三级精品视频| 91精品一区二区三区久久久久久 | 欧美羞羞免费网站| 欧洲亚洲精品在线| 欧美系列亚洲系列| 欧美人动与zoxxxx乱| 51精品国自产在线| 日韩一级大片在线| 精品国产一二三| 国产欧美日韩在线| 亚洲欧美一区二区在线观看| 亚洲欧洲日产国产综合网| 一区二区三区四区五区视频在线观看| 国产精品国模大尺度视频| 亚洲精品日韩综合观看成人91| 一区二区三区日本| 日韩国产在线观看一区| 久久99久久99小草精品免视看| 国产乱码字幕精品高清av| 国产成人午夜片在线观看高清观看| 成人午夜精品一区二区三区| 97久久精品人人爽人人爽蜜臀| 欧美视频在线一区| 精品久久国产老人久久综合| 国产精品电影院| 日韩激情在线观看| 成人激情校园春色| 欧美性生活影院| 精品粉嫩超白一线天av| 国产精品久99| 蜜桃久久久久久久| 91视频免费看| 欧美电视剧免费全集观看| 国产情人综合久久777777| 亚洲一区二区三区免费视频| 狠狠色2019综合网| 在线免费精品视频| 国产亚洲婷婷免费| 五月天激情综合| 99久久精品国产观看| 欧美高清你懂得| 中文字幕综合网| 韩国精品在线观看| 欧美三区免费完整视频在线观看| 亚洲精品一区二区三区在线观看| 亚洲综合色视频|