锘??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲先锋成人,狠狠狠色丁香婷婷综合激情,欧美激情中文字幕乱码免费http://www.shnenglu.com/eday/category/2953.htmlzh-cnSat, 24 May 2008 10:27:48 GMTSat, 24 May 2008 10:27:48 GMT60C++浠g爜浼樺寲http://www.shnenglu.com/eday/archive/2007/02/17/18844.html鏉?鏉?Sat, 17 Feb 2007 14:05:00 GMThttp://www.shnenglu.com/eday/archive/2007/02/17/18844.html1.紜畾嫻偣鍨嬪彉閲忓拰琛ㄨ揪寮忔槸 float 鍨?
聽聽聽 涓轟簡璁╃紪璇戝櫒浜х敓鏇村ソ鐨勪唬鐮?姣斿璇翠駭鐢?DNow! 鎴朣SE鎸囦護鐨勪唬鐮?錛屽繀欏葷‘瀹氭誕鐐瑰瀷鍙橀噺鍜岃〃杈懼紡鏄?float 鍨嬬殑銆傝鐗瑰埆娉ㄦ剰鐨勬槸錛屼互 "錛汧"錛?鎴?"錛沠"錛?涓哄悗緙錛堟瘮濡傦細3.14f錛夌殑嫻偣甯擱噺鎵嶆槸 float 鍨嬶紝鍚﹀垯榛樿鏄?double 鍨嬨備負浜嗛伩鍏?float 鍨嬪弬鏁拌嚜鍔ㄨ漿鍖栦負 double錛岃鍦ㄥ嚱鏁板0鏄庢椂浣跨敤 float銆?
2.浣跨敤32浣嶇殑鏁版嵁綾誨瀷
銆銆緙栬瘧鍣ㄦ湁寰堝縐嶏紝浣嗗畠浠兘鍖呭惈鐨勫吀鍨嬬殑32浣嶇被鍨嬫槸錛歩nt錛宻igned錛宻igned int錛寀nsigned錛寀nsigned int錛宭ong錛宻igned long錛宭ong int錛宻igned long int錛寀nsigned long錛寀nsigned long int銆傚敖閲忎嬌鐢?2浣嶇殑鏁版嵁綾誨瀷錛屽洜涓哄畠浠瘮16浣嶇殑鏁版嵁鐢氳嚦8浣嶇殑鏁版嵁鏇存湁鏁堢巼銆?
3.鏄庢櫤浣跨敤鏈夌鍙鋒暣鍨嬪彉閲?
銆銆鍦ㄥ緢澶氭儏鍐典笅錛屼綘闇瑕佽冭檻鏁村瀷鍙橀噺鏄湁絎﹀彿榪樻槸鏃犵鍙風被鍨嬬殑銆傛瘮濡傦紝淇濆瓨涓涓漢鐨勪綋閲嶆暟鎹椂涓嶅彲鑳藉嚭鐜拌礋鏁幫紝鎵浠ヤ笉闇瑕佷嬌鐢ㄦ湁絎﹀彿綾誨瀷銆備絾鏄紝濡傛灉鏄淇濆瓨娓╁害鏁版嵁錛屽氨蹇呴』浣跨敤鍒版湁絎﹀彿鐨勫彉閲忋?
銆銆鍦ㄨ澶氬湴鏂癸紝鑰冭檻鏄惁浣跨敤鏈夌鍙風殑鍙橀噺鏄繀瑕佺殑銆傚湪涓浜涙儏鍐典笅錛屾湁絎﹀彿鐨勮繍綆楁瘮杈冨揩錛涗絾鍦ㄤ竴浜涙儏鍐典笅鍗寸浉鍙嶃?
銆銆姣斿錛氭暣鍨嬪埌嫻偣杞寲鏃訛紝浣跨敤澶т簬16浣嶇殑鏈夌鍙鋒暣鍨嬫瘮杈冨揩銆傚洜涓簒86鏋勬灦涓彁渚涗簡浠庢湁絎﹀彿鏁村瀷杞寲鍒版誕鐐瑰瀷鐨勬寚浠わ紝浣嗘病鏈夋彁渚涗粠鏃犵鍙鋒暣鍨嬭漿鍖栧埌嫻偣鐨勬寚浠ゃ傜湅鐪嬬紪璇戝櫒浜х敓鐨勬眹緙栦唬鐮侊細
銆銆涓嶅ソ鐨勪唬鐮侊細
緙栬瘧鍓?聽聽聽聽聽緙栬瘧鍚?
double x錛浡犅犅犅爉ov [foo + 4], 0
unsigned int i錛浡犅犅爉ov eax, i
x = i錛浡犅犅犅犅爉ov [foo], eax
聽聽聽聽聽flid qword ptr [foo]
聽聽聽聽聽fstp qword ptr [x]
銆銆涓婇潰鐨勪唬鐮佹瘮杈冩參銆備笉浠呭洜涓烘寚浠ゆ暟鐩瘮杈冨錛岃屼笖鐢變簬鎸囦護涓嶈兘閰嶅閫犳垚鐨凢LID鎸囦護琚歡榪熸墽琛屻傛渶濂界敤浠ヤ笅浠g爜浠f浛錛?
聽聽聽 鎺ㄨ崘鐨勪唬鐮侊細
緙栬瘧鍓嵚犅犅犅犅犵紪璇戝悗
double x錛浡犅犅犅爁ild dword ptr
int i錛浡犅犅犅犅爁stp qword ptr [x]
x = i錛?
銆銆鍦ㄦ暣鏁拌繍綆椾腑璁$畻鍟嗗拰浣欐暟鏃訛紝浣跨敤鏃犵鍙風被鍨嬫瘮杈冨揩銆備互涓嬭繖孌靛吀鍨嬬殑浠g爜鏄紪璇戝櫒浜х敓鐨?2浣嶆暣鍨嬫暟闄や互4鐨勪唬鐮侊細
銆銆涓嶅ソ鐨勪唬鐮伮?
緙栬瘧鍓?聽聽聽聽聽緙栬瘧鍚?
int i錛浡犅犅犅犅爉ov eax, i
i = i / 4錛?聽聽聽聽cdq
聽聽聽聽聽and edx, 3
聽聽聽聽聽add eax, edx
聽聽聽聽聽sar eax, 2
聽聽聽聽聽mov i, eax
聽聽聽 鎺ㄨ崘鐨勪唬鐮?br />緙栬瘧鍓?聽聽聽聽聽緙栬瘧鍚?
unsigned int i錛?聽聽聽shr i, 2
i = i / 4錛?
銆鎬葷粨錛?br />銆鏃犵鍙風被鍨嬬敤浜庯細闄ゆ硶鍜屼綑鏁?寰幆璁℃暟,鏁扮粍涓嬫爣
聽 鏈夌鍙風被鍨嬬敤浜庯細鏁村瀷鍒版誕鐐圭殑杞寲
4.while VS. for
銆銆鍦ㄧ紪紼嬩腑錛屾垜浠父甯擱渶瑕佺敤鍒版棤闄愬驚鐜紝甯哥敤鐨勪袱縐嶆柟娉曟槸while (1) 鍜?for (錛涳紱)銆傝繖涓ょ鏂規硶鏁堟灉瀹屽叏涓鏍鳳紝浣嗛偅涓縐嶆洿濂藉憿錛熺劧鎴戜滑鐪嬬湅瀹冧滑緙栬瘧鍚庣殑浠g爜錛?
緙栬瘧鍓?聽聽聽聽聽緙栬瘧鍚?
while (1)錛?聽聽聽聽mov eax,1
聽聽聽聽聽test eax,eax
聽聽聽聽聽je foo+23h
聽聽聽聽聽jmp foo+18h
緙栬瘧鍓?聽聽聽聽聽緙栬瘧鍚幝?
for (錛涳紱)錛?聽聽聽聽jmp foo+23h
銆銆涓鐩簡鐒訛紝for (錛涳紱)鎸囦護灝戯紝涓嶅崰鐢ㄥ瘎瀛樺櫒錛岃屼笖娌℃湁鍒ゆ柇璺寵漿錛屾瘮while (1)濂姐?
5.浣跨敤鏁扮粍鍨嬩唬鏇挎寚閽堝瀷
銆銆浣跨敤鎸囬拡浼氫嬌緙栬瘧鍣ㄥ緢闅句紭鍖栧畠銆傚洜涓虹己涔忔湁鏁堢殑鎸囬拡浠g爜浼樺寲鐨勬柟娉曪紝緙栬瘧鍣ㄦ繪槸鍋囪鎸囬拡鍙互璁塊棶鍐呭瓨鐨勪換鎰忓湴鏂癸紝鍖呮嫭鍒嗛厤緇欏叾浠栧彉閲忕殑鍌ㄥ瓨絀洪棿銆傛墍浠ヤ負浜嗙紪璇戝櫒浜х敓浼樺寲寰楁洿濂界殑浠g爜錛岃閬垮厤鍦ㄤ笉蹇呰鐨勫湴鏂逛嬌鐢ㄦ寚閽堛備竴涓吀鍨嬬殑渚嬪瓙鏄闂瓨鏀懼湪鏁扮粍涓殑鏁版嵁銆侰++ 鍏佽浣跨敤鎿嶄綔絎?[] 鎴栨寚閽堟潵璁塊棶鏁扮粍錛屼嬌鐢ㄦ暟緇勫瀷浠g爜浼氳浼樺寲鍣ㄥ噺灝戜駭鐢熶笉瀹夊叏浠g爜鐨勫彲鑳芥с傛瘮濡傦紝x[0] 鍜寈[2] 涓嶅彲鑳芥槸鍚屼竴涓唴瀛樺湴鍧錛屼絾 *p 鍜?*q 鍙兘銆傚己鐑堝緩璁嬌鐢ㄦ暟緇勫瀷錛屽洜涓鴻繖鏍峰彲鑳戒細鏈夋剰鏂欎箣澶栫殑鎬ц兘鎻愬崌銆?
聽聽聽 涓嶅ソ鐨勪唬鐮?br />typedef struct
{
銆銆float x,y,z,w錛?br />} VERTEX錛?br />typedef struct

{
銆銆float m[4][4]錛?br />} MATRIX錛?br />void XForm(float* res, const float* v, const float* m, int nNumVerts)
{
銆銆float dp錛?br />銆銆int i錛?br />銆銆銆const VERTEX* vv = (VERTEX *)v錛?br />銆銆銆for (i = 0錛?i <錛?nNumVerts錛?i++)
銆銆{
銆銆銆銆dp = vv->錛泋 * *m ++錛?br />銆銆銆銆dp += vv->錛泍 * *m ++錛?br />銆銆銆銆dp += vv->錛泎 * *m ++錛?br />銆銆銆銆dp += vv->錛泈 * *m ++錛?br />銆銆銆銆*res ++ = dp錛涖銆銆銆銆銆// 鍐欏叆杞崲浜嗙殑 x
銆銆銆銆dp = vv->錛泋 * *m ++錛?br />銆銆銆銆dp += vv->錛泍 * *m ++錛?br />銆銆銆銆dp += vv->錛泎 * *m ++錛?br />銆銆銆銆dp += vv->錛泈 * *m ++錛?br />銆銆銆銆*res ++ = dp錛涖銆銆銆銆// 鍐欏叆杞崲浜嗙殑 y
銆銆銆銆dp = vv->錛泋 * *m ++錛?br />銆銆銆銆dp += vv->錛泍 * *m ++錛?br />銆銆銆銆dp += vv->錛泎 * *m ++錛?br />銆銆銆銆dp += vv->錛泈 * *m ++錛?br />銆銆銆銆*res ++ = dp錛涖銆銆銆// 鍐欏叆杞崲浜嗙殑 z
銆銆銆銆dp = vv->錛泋 * *m ++錛?br />銆銆銆銆dp += vv->錛泍 * *m ++錛?br />銆銆銆銆dp += vv->錛泎 * *m ++錛?br />銆銆銆銆dp += vv->錛泈 * *m ++錛?br />銆銆銆銆*res ++ = dp錛涖銆銆銆// 鍐欏叆杞崲浜嗙殑 w
銆銆銆銆vv ++錛涖銆銆銆銆銆銆 // 涓嬩竴涓煝閲?br />銆銆銆銆m -= 16錛?br />銆銆}
}
聽聽聽 鎺ㄨ崘鐨勪唬鐮?
typedef struct
{
銆銆float x,y,z,w錛?br />} VERTEX錛?br />typedef struct
{
銆銆float m[4][4]錛?br />} MATRIX錛?br />void XForm (float* res, const float* v, const float* m, int nNumVerts)
{
銆銆int i錛?br />銆銆const VERTEX* vv = (VERTEX*)v錛?br />銆銆const MATRIX* mm = (MATRIX*)m錛?br />銆銆VERTEX* rr = (VERTEX*)res錛?br />銆銆for (i = 0錛?i <錛?nNumVerts錛?i++)
銆銆{
銆銆銆銆rr->錛泋 = vv->錛泋 * mm->錛沵[0][0] + vv->錛泍 * mm->錛沵[0][1]
銆銆銆銆銆銆銆銆+ vv->錛泎 * mm->錛沵[0][2] + vv->錛泈 * mm->錛沵[0][3]錛?br />銆銆銆銆rr->錛泍 = vv->錛泋 * mm->錛沵[1][0] + vv->錛泍 * mm->錛沵[1][1]
銆銆銆銆銆銆銆銆+ vv->錛泎 * mm->錛沵[1][2] + vv->錛泈 * mm->錛沵[1][3]錛?br />銆銆銆銆rr->錛泎 = vv->錛泋 * mm->錛沵[2][0] + vv->錛泍 * mm->錛沵[2][1]
銆銆銆銆銆銆銆銆+ vv->錛泎 * mm->錛沵[2][2] + vv->錛泈 * mm->錛沵[2][3]錛?br />銆銆銆銆rr->錛泈 = vv->錛泋 * mm->錛沵[3][0] + vv->錛泍 * mm->錛沵[3][1]
銆銆銆銆銆銆銆銆+ vv->錛泎 * mm->錛沵[3][2] + vv->錛泈 * mm->錛沵[3][3]錛?br />銆銆}
}
銆銆娉ㄦ剰: 婧愪唬鐮佺殑杞寲鏄笌緙栬瘧鍣ㄧ殑浠g爜鍙戠敓鍣ㄧ浉緇撳悎鐨勩備粠婧愪唬鐮佸眰嬈″緢闅炬帶鍒朵駭鐢熺殑鏈哄櫒鐮併備緷闈犵紪璇戝櫒鍜岀壒孌婄殑婧愪唬鐮侊紝鏈夊彲鑳芥寚閽堝瀷浠g爜緙栬瘧鎴愮殑鏈哄櫒鐮佹瘮鍚岀瓑鏉′歡涓嬬殑鏁扮粍鍨嬩唬鐮佽繍琛岄熷害鏇村揩銆傛槑鏅虹殑鍋氭硶鏄湪婧愪唬鐮佽漿鍖栧悗媯鏌ユц兘鏄惁鐪熸鎻愰珮浜嗭紝鍐嶉夋嫨浣跨敤鎸囬拡鍨嬭繕鏄暟緇勫瀷銆?
6.鍏呭垎鍒嗚В灝忕殑寰幆
銆銆瑕佸厖鍒嗗埄鐢–PU鐨勬寚浠ょ紦瀛橈紝灝辮鍏呭垎鍒嗚В灝忕殑寰幆銆傜壒鍒槸褰撳驚鐜綋鏈韓寰堝皬鐨勬椂鍊欙紝鍒嗚В寰幆鍙互鎻愰珮鎬ц兘銆侭TW:寰堝緙栬瘧鍣ㄥ茍涓嶈兘鑷姩鍒嗚В寰幆銆?
涓嶅ソ鐨勪唬鐮?鎺ㄨ崘鐨勪唬鐮?
// 3D杞寲錛氭妸鐭㈤噺 V 鍜?4x4 鐭╅樀 M 鐩鎬箻
for (i = 0錛?i <錛?4錛?i ++)
{
銆銆r = 0錛?br />銆銆for (j = 0錛?j <錛?4錛?j ++)
銆銆{
銆銆銆銆r += M[j]*V[j]錛?br />銆銆}
}
r[0] = M[0][0]*V[0] + M[1][0]*V[1] + M[2][0]*V[2] + M[3][0]*V[3]錛?br />r[1] = M[0][1]*V[0] + M[1][1]*V[1] + M[2][1]*V[2] + M[3][1]*V[3]錛?br />r[2] = M[0][2]*V[0] + M[1][2]*V[1] + M[2][2]*V[2] + M[3][2]*V[3]錛?br />r[3] = M[0][3]*V[0] + M[1][3]*V[1] + M[2][3]*V[2] + M[3][3]*v[3]錛?
7.閬垮厤娌℃湁蹇呰鐨勮鍐欎緷璧?
銆銆褰撴暟鎹繚瀛樺埌鍐呭瓨鏃跺瓨鍦ㄨ鍐欎緷璧栵紝鍗蟲暟鎹繀欏誨湪姝g‘鍐欏叆鍚庢墠鑳藉啀嬈¤鍙栥傝櫧鐒禔MD Athlon絳塁PU鏈夊姞閫熻鍐欎緷璧栧歡榪熺殑紜歡錛屽厑璁稿湪瑕佷繚瀛樼殑鏁版嵁琚啓鍏ュ唴瀛樺墠璇誨彇鍑烘潵錛屼絾鏄紝濡傛灉閬垮厤浜嗚鍐欎緷璧栧茍鎶婃暟鎹繚瀛樺湪鍐呴儴瀵勫瓨鍣ㄤ腑錛岄熷害浼氭洿蹇傚湪涓孌靛緢闀跨殑鍙堜簰鐩鎬緷璧栫殑浠g爜閾句腑錛岄伩鍏嶈鍐欎緷璧栨樉寰楀挨鍏墮噸瑕併傚鏋滆鍐欎緷璧栧彂鐢熷湪鎿嶄綔鏁扮粍鏃訛紝璁稿緙栬瘧鍣ㄤ笉鑳借嚜鍔ㄤ紭鍖栦唬鐮佷互閬垮厤璇誨啓渚濊禆銆傛墍浠ユ帹鑽愮▼搴忓憳鎵嬪姩鍘繪秷闄よ鍐欎緷璧栵紝涓句緥鏉ヨ錛屽紩榪涗竴涓彲浠ヤ繚瀛樺湪瀵勫瓨鍣ㄤ腑鐨勪復鏃跺彉閲忋傝繖鏍峰彲浠ユ湁寰堝ぇ鐨勬ц兘鎻愬崌銆備笅闈竴孌典唬鐮佹槸涓涓緥瀛愶細
聽聽聽 涓嶅ソ鐨勪唬鐮?br />float x[VECLEN], y[VECLEN], z[VECLEN]錛?br />......
for (unsigned int k = 1錛?k <錛?VECLEN錛?k ++)
{
銆銆x[k] = x[k-1] + y[k]錛?br />}
for (k = 1錛?k <錛?VECLEN錛?k++)
{
銆銆x[k] = z[k] * (y[k] - x[k-1])錛?br />}
銆銆 鎺ㄨ崘鐨勪唬鐮?
float x[VECLEN], y[VECLEN], z[VECLEN]錛?br />......
float t(x[0])錛?br />for (unsigned int k = 1錛?k <錛?VECLEN錛?k ++)
{
銆銆t = t + y[k]錛?br />銆銆x[k] = t錛?br />}
t = x[0]錛?br />for (k = 1錛?k <錛?VECLEN錛?k ++)
{
銆銆t = z[k] * (y[k] - t)錛?br />銆銆x[k] = t錛?br />}
8.Switch 鐨勭敤娉?
銆銆Switch 鍙兘杞寲鎴愬縐嶄笉鍚岀畻娉曠殑浠g爜銆傚叾涓渶甯歌鐨勬槸璺寵漿琛ㄥ拰姣旇緝閾?鏍戙傛帹鑽愬case鐨勫間緷鐓у彂鐢熺殑鍙兘鎬ц繘琛屾帓搴忥紝鎶婃渶鏈夊彲鑳界殑鏀懼湪絎竴涓紝褰搒witch鐢ㄦ瘮杈冮摼鐨勬柟寮忚漿鍖栨椂錛岃繖鏍峰彲浠ユ彁楂樻ц兘銆傛澶栵紝鍦╟ase涓帹鑽愪嬌鐢ㄥ皬鐨勮繛緇殑鏁存暟錛屽洜涓哄湪榪欑鎯呭喌涓嬶紝鎵鏈夌殑緙栬瘧鍣ㄩ兘鍙互鎶妔witch 杞寲鎴愯煩杞〃銆?
聽聽聽 涓嶅ソ鐨勪唬鐮?br />int days_in_month, short_months, normal_months, long_months錛?br />......
switch (days_in_month)
{
銆銆case 28:
銆銆case 29:
銆銆銆銆short_months ++錛?br />銆銆銆銆break錛?br />銆銆case 30:
銆銆銆銆normal_months ++錛?br />銆銆銆銆break錛?br />銆銆case 31:
銆銆銆銆long_months ++錛?br />銆銆銆銆break錛?br />銆銆default:
銆銆銆銆cout <錛?lt;錛?"錛沵onth has fewer than 28 or more than 31 days"錛?<錛?lt;錛?endl錛?br />銆銆銆銆break錛?br />}
聽聽聽 鎺ㄨ崘鐨勪唬鐮?
int days_in_month, short_months, normal_months, long_months錛?br />......
switch (days_in_month)
{
銆銆case 31:
銆銆銆銆long_months ++錛?br />銆銆銆銆break錛?br />銆銆case 30:
銆銆銆銆normal_months ++錛?br />銆銆銆銆break錛?br />銆銆case 28:
銆銆case 29:
銆銆銆銆short_months ++錛?
銆銆銆銆break錛?br />銆銆default:
銆銆銆銆cout <錛?lt;錛?"錛沵onth has fewer than 28 or more than 31 days"錛?<錛?lt;錛?endl錛?br />銆銆銆銆break錛?br />}
9.鎵鏈夊嚱鏁伴兘搴旇鏈夊師鍨嬪畾涔?
銆銆涓鑸潵璇達紝鎵鏈夊嚱鏁伴兘搴旇鏈夊師鍨嬪畾涔夈傚師鍨嬪畾涔夊彲浠ヤ紶杈劇粰緙栬瘧鍣ㄦ洿澶氱殑鍙兘鐢ㄤ簬浼樺寲鐨勪俊鎭?
銆銆灝藉彲鑳戒嬌鐢ㄥ父閲?const)銆侰++ 鏍囧噯瑙勫畾錛屽鏋滀竴涓猚onst澹版槑鐨勫璞$殑鍦板潃涓嶈鑾峰彇錛屽厑璁哥紪璇戝櫒涓嶅瀹冨垎閰嶅偍瀛樼┖闂淬傝繖鏍峰彲浠ヤ嬌浠g爜鏇存湁鏁堢巼錛岃屼笖鍙互鐢熸垚鏇村ソ鐨勪唬鐮併?
10.鎻愬崌寰幆鐨勬ц兘
銆銆瑕佹彁鍗囧驚鐜殑鎬ц兘錛屽噺灝戝浣欑殑甯擱噺璁$畻闈炲父鏈夌敤錛堟瘮濡傦紝涓嶉殢寰幆鍙樺寲鐨勮綆楋級銆?
銆銆涓嶅ソ鐨勪唬鐮?鍦╢or()涓寘鍚笉鍙樼殑if()) 鎺ㄨ崘鐨勪唬鐮?
for( i ... )
{
銆銆if( CONSTANT0 )
銆銆{
銆銆銆銆DoWork0( i )錛?// 鍋囪榪欓噷涓嶆敼鍙楥ONSTANT0鐨勫?br />銆銆}
銆銆else
銆銆{
銆銆銆銆DoWork1( i )錛?// 鍋囪榪欓噷涓嶆敼鍙楥ONSTANT0鐨勫?br />銆銆}
}
if( CONSTANT0 )
{
銆銆for( i ... )
銆銆{
銆銆銆銆DoWork0( i )錛?br />銆銆}
}
else
{
銆銆for( i ... )
銆銆{
銆銆銆銆DoWork1( i )錛?br />銆銆}
}
銆銆濡傛灉宸茬粡鐭ラ亾if()鐨勫鹼紝榪欐牱鍙互閬垮厤閲嶅璁$畻銆傝櫧鐒朵笉濂界殑浠g爜涓殑鍒嗘敮鍙互綆鍗曞湴棰勬祴錛屼絾鏄敱浜庢帹鑽愮殑浠g爜鍦ㄨ繘鍏ュ驚鐜墠鍒嗘敮宸茬粡紜畾錛屽氨鍙互鍑忓皯瀵瑰垎鏀嫻嬬殑渚濊禆銆?銆銆鎶婃湰鍦板嚱鏁板0鏄庝負闈欐佺殑(static)
銆銆濡傛灉涓涓嚱鏁板湪瀹炵幇瀹冪殑鏂囦歡澶栨湭琚嬌鐢ㄧ殑璇濓紝鎶婂畠澹版槑涓洪潤鎬佺殑(static)浠ュ己鍒朵嬌鐢ㄥ唴閮ㄨ繛鎺ャ傚惁鍒欙紝榛樿鐨勬儏鍐典笅浼氭妸鍑芥暟瀹氫箟涓哄閮ㄨ繛鎺ャ傝繖鏍峰彲鑳戒細褰卞搷鏌愪簺緙栬瘧鍣ㄧ殑浼樺寲鈥斺旀瘮濡傦紝鑷姩鍐呰仈銆?
11.鑰冭檻鍔ㄦ佸唴瀛樺垎閰?
銆銆鍔ㄦ佸唴瀛樺垎閰嶏紙C++涓殑"錛沶ew"錛涳級鍙兘鎬繪槸涓洪暱鐨勫熀鏈被鍨嬶紙鍥涘瓧瀵歸綈錛夎繑鍥炰竴涓凡緇忓榻愮殑鎸囬拡銆備絾鏄鏋滀笉鑳戒繚璇佸榻愶紝浣跨敤浠ヤ笅浠g爜鏉ュ疄鐜板洓瀛楀榻愩傝繖孌典唬鐮佸亣璁炬寚閽堝彲浠ユ槧灝勫埌 long 鍨嬨?
銆銆渚嬪瓙
銆銆double* p = (double*)new BYTE[sizeof(double) * number_of_doubles+7L]錛?br />聽聽聽 double* np = (double*)((long(p) + 7L) &錛?鈥?L)錛?
銆銆鐜板湪錛屼綘鍙互浣跨敤 np 浠f浛 p 鏉ヨ闂暟鎹傛敞鎰忥細閲婃斁鍌ㄥ瓨絀洪棿鏃朵粛鐒跺簲璇ョ敤delete p銆?
12.浣跨敤鏄懼紡鐨勫茍琛屼唬鐮?
銆銆灝藉彲鑳芥妸闀跨殑鏈変緷璧栫殑浠g爜閾懼垎瑙f垚鍑犱釜鍙互鍦ㄦ祦姘寸嚎鎵ц鍗曞厓涓茍琛屾墽琛岀殑娌℃湁渚濊禆鐨勪唬鐮侀摼銆傚洜涓烘誕鐐規搷浣滄湁寰堥暱鐨勬綔浼忔湡錛屾墍浠ヤ笉綆″畠琚槧灝勬垚 x87 鎴?3DNow! 鎸囦護錛岃繖閮藉緢閲嶈銆傚緢澶氶珮綰ц璦錛屽寘鎷珻++錛屽茍涓嶅浜х敓鐨勬誕鐐硅〃杈懼紡閲嶆柊鎺掑簭錛屽洜涓洪偅鏄竴涓浉褰撳鏉傜殑榪囩▼銆傞渶瑕佹敞鎰忕殑鏄紝閲嶆帓搴忕殑浠g爜鍜屽師鏉ョ殑浠g爜鍦ㄤ唬鏁頒笂涓鑷村茍涓嶇瓑浠蜂簬璁$畻緇撴灉涓鑷達紝鍥犱負嫻偣鎿嶄綔緙轟箯綺劇‘搴︺傚湪涓浜涙儏鍐典笅錛岃繖浜涗紭鍖栧彲鑳藉鑷存剰鏂欎箣澶栫殑緇撴灉銆傚垢榪愮殑鏄紝鍦ㄥぇ閮ㄥ垎鎯呭喌涓嬶紝鏈鍚庣粨鏋滃彲鑳藉彧鏈夋渶涓嶉噸瑕佺殑浣嶏紙鍗蟲渶浣庝綅錛夋槸閿欒鐨勩?
銆銆涓嶅ソ鐨勪唬鐮?br />double a[100], sum錛?br />int i錛?br />sum = 0.0f錛?br />for (i=0錛?i<錛?00錛?i++)
銆銆sum += a錛?
聽聽聽 鎺ㄨ崘鐨勪唬鐮?
double a[100], sum1, sum2, sum3, sum4, sum錛?br />int i錛?br />sum1 = sum2 = sum3 = sum4 = 0.0錛?br />for (i = 0錛?i <錛?100錛?i += 4)
{
銆銆sum1 += a錛?br />銆銆sum2 += a[i+1]錛?br />銆銆sum3 += a[i+2]錛?br />銆銆sum4 += a[i+3]錛?br />}
sum = (sum4+sum3)+(sum1+sum2)錛?
銆銆瑕佹敞鎰忕殑鏄細浣跨敤4 璺垎瑙f槸鍥犱負榪欐牱浣跨敤浜?闃舵嫻佹按綰挎誕鐐瑰姞娉曪紝嫻偣鍔犳硶鐨勬瘡涓涓樁孌靛崰鐢ㄤ竴涓椂閽熷懆鏈燂紝淇濊瘉浜嗘渶澶х殑璧勬簮鍒╃敤鐜囥?
13.鎻愬嚭鍏叡瀛愯〃杈懼紡
銆銆鍦ㄦ煇浜涙儏鍐典笅錛孋++緙栬瘧鍣ㄤ笉鑳戒粠嫻偣琛ㄨ揪寮忎腑鎻愬嚭鍏叡鐨勫瓙琛ㄨ揪寮忥紝鍥犱負榪欐剰鍛崇潃鐩稿綋浜庡琛ㄨ揪寮忛噸鏂版帓搴忋傞渶瑕佺壒鍒寚鍑虹殑鏄紝緙栬瘧鍣ㄥ湪鎻愬彇鍏叡瀛愯〃杈懼紡鍓嶄笉鑳芥寜鐓т唬鏁扮殑絳変環鍏崇郴閲嶆柊瀹夋帓琛ㄨ揪寮忋傝繖鏃訛紝紼嬪簭鍛樿鎵嬪姩鍦版彁鍑哄叕鍏辯殑瀛愯〃杈懼紡錛堝湪VC.net閲屾湁涓欏光滃叏灞浼樺寲鈥濋夐」鍙互瀹屾垚姝ゅ伐浣滐紝浣嗘晥鏋滃氨涓嶅緱鑰岀煡浜嗭級銆?
鎺ㄨ崘鐨勪唬鐮?
float a, b, c, d, e, f錛?br />...
e = b * c / d錛?br />f = b / d * a錛?br />float a, b, c, d, e, f錛?br />...
const float t(b / d)錛?br />e = c * t錛?br />f = a * t錛?
鎺ㄨ崘鐨勪唬鐮?
float a, b, c, e, f錛?br />...
e = a / c錛?br />f = b / c錛?br />float a, b, c, e, f錛?br />...
const float t(1.0f / c)錛?br />e = a * t錛?br />f = b * t錛?
14.緇撴瀯浣撴垚鍛樼殑甯冨眬
銆銆寰堝緙栬瘧鍣ㄦ湁鈥滀嬌緇撴瀯浣撳瓧錛屽弻瀛楁垨鍥涘瓧瀵歸綈鈥濈殑閫夐」銆備絾鏄紝榪樻槸闇瑕佹敼鍠勭粨鏋勪綋鎴愬憳鐨勫榻愶紝鏈変簺緙栬瘧鍣ㄥ彲鑳藉垎閰嶇粰緇撴瀯浣撴垚鍛樼┖闂寸殑欏哄簭涓庝粬浠0鏄庣殑涓嶅悓銆備絾鏄紝鏈変簺緙栬瘧鍣ㄥ茍涓嶆彁渚涜繖浜涘姛鑳斤紝鎴栬呮晥鏋滀笉濂姐傛墍浠ワ紝瑕佸湪浠樺嚭鏈灝戜唬浠風殑鎯呭喌涓嬪疄鐜版渶濂界殑緇撴瀯浣撳拰緇撴瀯浣撴垚鍛樺榻愶紝寤鴻閲囧彇榪欎簺鏂規硶錛?
銆銆A鎸夌被鍨嬮暱搴︽帓搴?
銆銆鎶婄粨鏋勪綋鐨勬垚鍛樻寜鐓у畠浠殑綾誨瀷闀垮害鎺掑簭錛屽0鏄庢垚鍛樻椂鎶婇暱鐨勭被鍨嬫斁鍦ㄧ煭鐨勫墠闈€?
銆銆鎶婄粨鏋勪綋濉厖鎴愭渶闀跨被鍨嬮暱搴︾殑鏁村嶆暟
銆銆鎶婄粨鏋勪綋濉厖鎴愭渶闀跨被鍨嬮暱搴︾殑鏁村嶆暟銆傜収榪欐牱錛屽鏋滅粨鏋勪綋鐨勭涓涓垚鍛樺榻愪簡錛屾墍鏈夋暣涓粨鏋勪綋鑷劧涔熷氨瀵歸綈浜嗐備笅闈㈢殑渚嬪瓙婕旂ず浜嗗浣曞緇撴瀯浣撴垚鍛樿繘琛岄噸鏂版帓搴忥細
銆銆涓嶅ソ鐨勪唬鐮侊紝鏅氶『搴?鎺ㄨ崘鐨勪唬鐮侊紝鏂扮殑欏哄簭騫舵墜鍔ㄥ~鍏呬簡鍑犱釜瀛楄妭
struct
{
銆銆char a[5]錛?br />銆銆long k錛?br />銆銆double x錛?br />} baz錛?br />struct
{
銆銆double x錛?br />銆銆long k錛?br />銆銆char a[5]錛?br />char pad[7]錛?br />} baz錛?

銆銆榪欎釜瑙勫垯鍚屾牱閫傜敤浜庣被鐨勬垚鍛樼殑甯冨眬銆?
銆銆B鎸夋暟鎹被鍨嬬殑闀垮害鎺掑簭鏈湴鍙橀噺
銆銆褰撶紪璇戝櫒鍒嗛厤緇欐湰鍦板彉閲忕┖闂存椂錛屽畠浠殑欏哄簭鍜屽畠浠湪婧愪唬鐮佷腑澹版槑鐨勯『搴忎竴鏍鳳紝鍜屼笂涓鏉¤鍒欎竴鏍鳳紝搴旇鎶婇暱鐨勫彉閲忔斁鍦ㄧ煭鐨勫彉閲忓墠闈€傚鏋滅涓涓彉閲忓榻愪簡錛屽叾瀹冨彉閲忓氨浼氳繛緇殑瀛樻斁錛岃屼笖涓嶇敤濉厖瀛楄妭鑷劧灝變細瀵歸綈銆傛湁浜涚紪璇戝櫒鍦ㄥ垎閰嶅彉閲忔椂涓嶄細鑷姩鏀瑰彉鍙橀噺欏哄簭錛屾湁浜涚紪璇戝櫒涓嶈兘浜х敓4瀛楄妭瀵歸綈鐨勬爤錛屾墍浠?瀛楄妭鍙兘涓嶅榻愩備笅闈㈣繖涓緥瀛愭紨紺轟簡鏈湴鍙橀噺澹版槑鐨勯噸鏂版帓搴忥細
銆銆涓嶅ソ鐨勪唬鐮侊紝鏅氶『搴?鎺ㄨ崘鐨勪唬鐮侊紝鏀硅繘鐨勯『搴?
short ga, gu, gi錛?br />long foo, bar錛?br />double x, y, z[3]錛?br />char a, b錛?br />float baz錛?br />double z[3]錛?br />double x, y錛?br />long foo, bar錛?br />float baz錛?br />short ga, gu, gi錛?
14.閬垮厤涓嶅繀瑕佺殑鏁存暟闄ゆ硶
銆銆鏁存暟闄ゆ硶鏄暣鏁拌繍綆椾腑鏈鎱㈢殑錛屾墍浠ュ簲璇ュ敖鍙兘閬垮厤銆備竴縐嶅彲鑳藉噺灝戞暣鏁伴櫎娉曠殑鍦版柟鏄繛闄わ紝榪欓噷闄ゆ硶鍙互鐢變箻娉曚唬鏇褲傝繖涓浛鎹㈢殑鍓綔鐢ㄦ槸鏈夊彲鑳藉湪綆椾箻縐椂浼氭孩鍑猴紝鎵浠ュ彧鑳藉湪涓瀹氳寖鍥寸殑闄ゆ硶涓嬌鐢ㄣ?
銆銆涓嶅ソ鐨勪唬鐮?鎺ㄨ崘鐨勪唬鐮?
int i, j, k, m錛?br />m = i / j / k錛?br />int i, j, k, m錛?br />m = i / (j * k)錛?
15.鎶婇綣佷嬌鐢ㄧ殑鎸囬拡鍨嬪弬鏁版嫹璐濆埌鏈湴鍙橀噺
銆銆閬垮厤鍦ㄥ嚱鏁頒腑棰戠箒浣跨敤鎸囬拡鍨嬪弬鏁版寚鍚戠殑鍊箋傚洜涓虹紪璇戝櫒涓嶇煡閬撴寚閽堜箣闂存槸鍚﹀瓨鍦ㄥ啿紿侊紝鎵浠ユ寚閽堝瀷鍙傛暟寰寰涓嶈兘琚紪璇戝櫒浼樺寲銆傝繖鏍鋒槸鏁版嵁涓嶈兘琚瓨鏀懼湪瀵勫瓨鍣ㄤ腑錛岃屼笖鏄庢樉鍦板崰鐢ㄤ簡鍐呭瓨甯﹀銆傛敞鎰忥紝寰堝緙栬瘧鍣ㄦ湁鈥滃亣璁句笉鍐茬獊鈥濅紭鍖栧紑鍏籌紙鍦╒C閲屽繀欏繪墜鍔ㄦ坊鍔犵紪璇戝櫒鍛戒護琛?Oa鎴?Ow錛夛紝榪欏厑璁哥紪璇戝櫒鍋囪涓や釜涓嶅悓鐨勬寚閽堟繪槸鏈変笉鍚岀殑鍐呭錛岃繖鏍峰氨涓嶇敤鎶婃寚閽堝瀷鍙傛暟淇濆瓨鍒版湰鍦板彉閲忋傚惁鍒欙紝璇峰湪鍑芥暟涓寮濮嬫妸鎸囬拡鎸囧悜鐨勬暟鎹繚瀛樺埌鏈湴鍙橀噺銆傚鏋滈渶瑕佺殑璇濓紝鍦ㄥ嚱鏁扮粨鏉熷墠鎷瘋礉鍥炲幓銆?銆銆
聽聽聽 涓嶅ソ鐨勪唬鐮?
// 鍋囪 q != r
void isqrt(unsigned long a, unsigned long* q, unsigned long* r)
{
銆銆*q = a錛?br />銆銆if (a >錛?0)
銆銆{
銆銆銆銆while (*q >錛?(*r = a / *q))
銆銆銆銆{
銆銆銆銆銆銆*q = (*q + *r) >錛?gt;錛?1錛?br />銆銆銆銆}
銆銆}
銆銆*r = a - *q * *q錛?br />}
聽聽聽 鎺ㄨ崘鐨勪唬鐮?br />// 鍋囪 q != r
void isqrt(unsigned long a, unsigned long* q, unsigned long* r)
{
銆銆unsigned long qq, rr錛?br />銆銆qq = a錛?br />銆銆if (a >錛?0)
銆銆{
銆銆銆銆while (qq >錛?(rr = a / qq))
銆銆銆銆{
銆銆銆銆銆銆qq = (qq + rr) >錛?gt;錛?1錛?br />銆銆銆銆}
銆銆}
銆銆rr = a - qq * qq錛?br />銆銆*q = qq錛?br />銆銆*r = rr錛?br />}
16.璧嬪間笌鍒濆鍖?br />鍏堢湅鐪嬩互涓嬩唬鐮侊細
class CInt
{
銆銆int m_i錛?
public:
銆銆CInt(int a = 0):m_i(a) { cout <錛?lt;錛?"錛汣Int"錛?<錛?lt;錛?endl錛?}
銆銆~CInt() { cout <錛?lt;錛?"錛泘CInt"錛?<錛?lt;錛?endl錛?}
銆銆CInt operator + (const CInt&錛?a) { return CInt(m_i + a.GetInt())錛?}
銆銆void SetInt(const int i)銆銆{ m_i = i錛?}
銆銆int GetInt() const銆銆銆銆銆銆{ return m_i錛?}
}錛?br />聽聽聽 涓嶅ソ鐨勪唬鐮?
void main()
{
銆銆CInt a, b, c錛?br />銆銆a.SetInt(1)錛?br />銆銆b.SetInt(2)錛?br />銆銆c = a + b錛?br />}
聽聽聽 鎺ㄨ崘鐨勪唬鐮?br />void main()
{
銆銆CInt a(1), b(2)錛?br />銆銆CInt c(a + b)錛?br />}
銆銆榪欎袱孌典唬鐮佹墍浣滅殑浜嬮兘涓鏍鳳紝浣嗛偅涓涓洿濂藉憿錛熺湅鐪嬭緭鍑虹粨鏋滃氨浼氬彂鐜幫紝涓嶅ソ鐨勪唬鐮佽緭鍑轟簡鍥涗釜"錛汣Int"錛涘拰鍥涗釜"錛泘CInt"錛涳紝鑰屾帹鑽愮殑浠g爜鍙緭鍑轟笁涓備篃灝辨槸璇達紝絎簩涓緥瀛愭瘮絎竴涓緥瀛愬皯鐢熸垚涓嬈′復鏃跺璞°俉hy? 璇鋒敞鎰忥紝絎竴涓腑鐨刢鐢ㄧ殑鏄厛澹版槑鍐嶈祴鍊肩殑鏂規硶錛岀浜屼釜鐢ㄧ殑鏄垵濮嬪寲鐨勬柟娉曪紝瀹冧滑鏈夋湰璐ㄧ殑鍖哄埆銆傜涓涓緥瀛愮殑"錛沜 = a + b"錛涘厛鐢熸垚涓涓復鏃跺璞$敤鏉ヤ繚瀛榓 + b鐨勫鹼紝鍐嶆妸璇ヤ復鏃跺璞$敤浣嶆嫹璐濈殑鏂規硶緇檆璧嬪鹼紝鐒跺悗涓存椂瀵硅薄琚攢姣併傝繖涓復鏃跺璞″氨鏄偅涓鍑烘潵鐨勫璞°傜浜屼釜渚嬪瓙鐩存帴鐢ㄦ嫹璐濇瀯閫犲嚱鏁扮殑鏂規硶瀵筩鍒濆鍖栵紝涓嶄駭鐢熶復鏃跺璞°傛墍浠ワ紝灝介噺鍦ㄩ渶瑕佷嬌鐢ㄤ竴涓璞℃椂鎵嶅0鏄庯紝騫剁敤鍒濆鍖栫殑鏂規硶璧嬪垵鍊箋?
17.灝介噺浣跨敤鎴愬憳鍒濆鍖栧垪琛?
銆銆鍦ㄥ垵濮嬪寲綾葷殑鎴愬憳鏃訛紝灝介噺浣跨敤鎴愬憳鍒濆鍖栧垪琛ㄨ屼笉鏄紶緇熺殑璧嬪兼柟寮忋?
銆銆涓嶅ソ鐨勪唬鐮?
class CMyClass
{
銆銆string strName錛?
public:
銆銆CMyClass(const string&錛?str)錛?br />}錛?
CMyClass::CMyClass(const string&錛?str)
{
銆銆strName = str錛?br />}
聽聽聽 鎺ㄨ崘鐨勪唬鐮?br />class CMyClass
{
銆銆string strName錛?br />銆銆int i錛?br />public:
銆銆CMyClass(const string&錛?str)錛?br />}錛?
CMyClass::CMyClass(const string&錛泂tr)
聽聽 :strName(str)
{

}
銆銆涓嶅ソ鐨勪緥瀛愮敤鐨勬槸璧嬪肩殑鏂瑰紡銆傝繖鏍鳳紝strName浼氬厛琚緩绔嬶紙璋冪敤浜唖tring鐨勯粯璁ゆ瀯閫犲嚱鏁幫級錛屽啀鐢卞弬鏁皊tr璧嬪箋傝屾帹鑽愮殑渚嬪瓙鐢ㄧ殑鏄垚鍛樺垵濮嬪寲鍒楄〃錛宻trName鐩存帴鏋勯犱負str錛屽皯璋冪敤涓嬈¢粯璁ゆ瀯閫犲嚱鏁幫紝榪樺皯浜嗕竴浜涘畨鍏ㄩ殣鎮c?/p>

鏉? 2007-02-17 22:05 鍙戣〃璇勮
]]>
C浠g爜浼樺寲http://www.shnenglu.com/eday/archive/2007/02/17/18843.html鏉?鏉?Sat, 17 Feb 2007 14:04:00 GMThttp://www.shnenglu.com/eday/archive/2007/02/17/18843.html闃呰鍏ㄦ枃

鏉? 2007-02-17 22:04 鍙戣〃璇勮
]]>
C++璧勬簮涔嬩笉瀹屽叏瀵煎紩http://www.shnenglu.com/eday/archive/2007/02/05/18382.html鏉?鏉?Mon, 05 Feb 2007 02:07:00 GMThttp://www.shnenglu.com/eday/archive/2007/02/05/18382.html銆銆1錛屽墠璦

銆銆鏃犳暟嬈″惉鍒扳滄垜瑕佸紑濮嬪涔燙++!鈥濈殑鍛愬枈錛屾棤鏁版鍚埌鈥淐++澶鏉備簡錛屾垜鐪熺殑瀛︿笉浼氣濈殑鏃犲銆係tan Lippman鍏堢敓鏇懼湪銆奀++ Primer銆嬩竴涔︿腑鎸囧嚭鈥淐++鏄渶涓洪毦瀛︾殑楂樼駭紼嬪簭璁捐璇█涔嬩竴鈥濓紝浜轟滑甯稿皢鈥滀箣涓鈥濆幓鎺変互琛ㄨ揪鑷繁瀵笴++鐨勬暚鐣忋傝瘹鐒訛紝C++紼嬪簭璁捐璇█瀵逛簬瀛︿範鑰呯殑紜湁寰堝闅句互閫捐秺鐨勯縛娌燂紝浣撶郴緇撴瀯鐨勫簽澶э紝搴旀帴涓嶆殗騫朵笉鏂墿鍏呯殑鐗規р︹﹂櫎姝や箣澶栵紝鍙傝冭祫鏂欎箣澶氫笌鍐楁潅浣垮畠鐨勫涔犺呮湜鑰屽嵈姝ワ紝嬈叉眰娣卞叆鑰呰嫤涓嶅牚璦銆傚笇鏈涜繖涓浠戒笉瀹屽叏瀵煎紩鑳藉鎴愪負鎮–++瀛︿範涔嬭礬涓婄殑寮曡礬鐏?/p>

銆銆鎾板啓鏈枃鐨勫垵琛峰茍涓嶆墦綆楀甫棰嗗ぇ瀹朵綋楠屽彜鑰佺殑C++鍘嗗彶錛屽鏋滀綘鎯充簡瑙++鐨勫巻鍙蹭笌鍏跺墠鏈熷彂灞曚腑璇稿鎶鏈殑婕斿彉錛屼綘搴斿綋鍘誨弬鑰傿jarne鐨勩奣he Design and Evolution of C++銆嬨傚綋鐒朵篃涓嶆墦綆楃粰澶у涓涓棤鎵涓嶅寘鐨勫疂鍏革紙騫墮潪涓嶆兂錛氬叾涓鏄洜姘村鉤鏈夐檺錛屽叾浜屾棤濂圕++涔嬪崥澶х簿娣憋級錛屾墍緇欏嚭鐨勪粎浠呮槸涓浜涙垜浠涓哄浜庢兂瀛︿範C++鐨勫箍澶ц鑰呮潵璇存渶閲嶈騫朵笖瑙︽墜鍙強鐨勫紑鍙戜笌瀛︿範璧勬簮銆?/p>

銆銆鏈枃浠嬬粛騫跺垎鏋愪簡涓浜涚紪璇戝櫒錛屽紑鍙戠幆澧冿紝搴擄紝灝戦噺鐨勪功綾嶄互鍙婂弬鑰冪綉绔欙紝騫朵笖灝藉彲鑳藉皾璇曠潃緇欏嚭涓涓埄鐢ㄨ繖浜涜祫婧愮殑瀵煎紩錛屾湜瀵瑰鍚屾垜浠竴鏍風殑鍒濆鑰呰兘澶熸湁鎵瑁ㄧ泭銆?/p>

聽聽聽 銆2錛岀紪璇戝櫒

銆銆鍦–++涔嬪鐨勪換浣曡璦涓紝緙栬瘧鍣ㄩ兘浠庢潵娌℃湁鍙楀埌榪囧姝や箣閲嶈銆傚洜涓篊++鏄竴闂ㄧ浉褰撳鏉傜殑璇█錛屾墍浠ョ紪璇戝櫒涔熼毦浜庢瀯寤恒傜洿鍒版渶榪戞垜浠墠寮濮嬭兘澶熶嬌鐢ㄤ笂瀹屽叏絎﹀悎C++鏍囧噯鐨勭紪璇戝櫒錛堝摝錛屼綘鍙兘浼氳矗鎬偅浜涚紪璇戝櫒鍘傚晢涓嶈兘灝芥棭鐨勬彁渚涚鍚堟爣鍑嗙殑緙栬瘧鍣紝榪欏彧鑳芥粬浠悇鑷淮緋葷潃鑷韓鐨勪竴濂楀埆浜轟笉鎰挎帴鍙楃殑鏍囧噯錛夈備粈涔堬紵浣犺榪欐棤鍏崇揣瑕侊紵鍝︼紝涓嶏紝浣犳墍闇瑕佺殑鏄拰鏍囧噯鍖朇++楂樺害鍏煎鐨勭紪璇戠幆澧冦傞暱榪滄潵鐪?br />錛屽彧鏈夎繖鏍風殑緙栬瘧鍣ㄥC++寮鍙戜漢鍛樻潵璇存墠鏄渶鏈夋剰涔夌殑宸ュ叿錛屽挨鍏舵槸瀵逛簬紼嬪簭璁捐璇█鐨勫涔犺呫備竴鑷蟲ц浠g爜鍏峰鍙Щ妞嶆э紝騫惰涓闂ㄨ璦鍙婂叾搴撶殑搴旂敤鏇翠負騫挎硾銆傚棷錛屾槸鐨勶紝鎴戜滑榪欓噷鍙墦綆椾粙緇嶄竴浜涘叕璁ょ殑浼樼緙栬瘧鍣ㄣ?/p>

銆銆2.1 Borland C++

銆銆榪欎釜鏄疊orland C++ Builder鍜孊orland C++ Builder X榪欎袱縐嶅紑鍙戠幆澧冪殑鍚庡彴緙栬瘧鍣ㄣ傦紙鍝︼紝鎴戜箣鎵浠ュ皢涔嬪垎涓轟袱縐嶅紑鍙戠幆澧冧綘搴斿綋鑳芥槑鐧戒負浠涔堬紝姝eDelphi7鍒癉elphi8鐨勮漿鍙橈紝鏄潻鍛芥х殑涓や唬銆傦級Borland C++鐢辮佺墝寮鍙戝伐鍏峰巶鍟咮orland鍊懼姏鎵撻犮傝鍏徃鐨勭紪璇戝櫒绱犱互閫熷害蹇紝絀洪棿鏁堢巼楂樿憲縐幫紝Borland C++ 緋誨垪緙栬瘧鍣ㄧ鎵夸簡榪欎釜浼犵粺錛屽睘浜庨潪甯鎬紭璐ㄧ殑緙栬瘧鍣ㄣ傛爣鍑嗗寲鏂歸潰鏃╁湪5.5鐗堟湰鐨勭紪璇戝櫒涓鏍囧噯鍖朇++鐨勫吋瀹瑰氨杈懼埌浜?2.73%銆傜洰鍓嶆渶鏂扮増鏈槸Borland C++ Builder X涓殑6.0鐗堟湰錛屽畼鏂圭О100%絎﹀悎ANSI/ISO鐨凜++鏍囧噯浠ュ強C99鏍囧噯銆傚棷鈥﹁繖姝f槸鎴戝墠闈㈡墍鎸囩殑鈥滃畬鍏ㄧ鍚圕++鏍囧噯鐨勭紪璇戝櫒鈥濄?/p>

銆銆2.2 Visual C++

銆銆榪欎釜姝f槸鎴戜滑鐔熺煡鐨刅isual Studio 鍜?Visual Studio.net 2002, 2003浠ュ強2005 Whidbey涓甫鐨凜++緙栬瘧鍣ㄣ傜敱Microsoft鍏徃鐮斿埗銆傚湪Visual Studio 6.0涓紝鍥犱負緙栬瘧鍣ㄦ湁澶鍦版柟涓嶈兘涓庡悗鏉ュ嚭鐜扮殑C++鏍囧噯鐩稿惢鍚堣岄ケ鍙楁壒璇勶紙鎯蟲兂浣犲湪浣跨敤STL鐨勬椂鍊欑紪璇戞椂鎶ュ嚭鐨勯偅浜涗護浜哄帉鎭剁殑error鍜寃arning鍚э級銆俈C++6.0瀵規爣鍑嗗寲C+
+鐨勫吋瀹瑰彧鏈?3.43%銆備絾鏄殢鐫C++緙栬瘧鍣ㄨ璁″ぇ甯圫tanley Lippman浠ュ強璇稿C++紺劇兢杈句漢鐨勫姞鐩燂紝鍦╒isual Studio.NET 2003涓紝Visual C++緙栬瘧鍣ㄥ凡緇忔垚涓轟竴涓潪甯告垚鐔熷彲*鐨凜++緙栬瘧鍣ㄤ簡銆侱r.Dobb's Journal鐨勮瘎嫻嬫樉紺篤isual C++7.1瀵規爣鍑咰++鐨勫吋瀹規ч珮杈?8.22%錛屼竴搴︽垚涓篊BX涔嬪墠鍏煎鎬ф渶濂界殑緙栬瘧鍣ㄣ傜粨鍚堝己澶х殑Visual Studio.NET寮鍙戠幆澧冿紝鏄竴涓潪甯鎬笉閿欑殑閫夋嫨銆傝嚦浜嶹hidbey鏃朵唬鐨刅isual C++,浼間箮寰蔣鎵鏈鍏蟲敞鐨勬槸C++/CLI鈥︹︽垜浠笉鎯寵瘎璁哄井杞笅涓浠g殑C++緙栬瘧鍣ㄥ鏍囧噯鍖栧吋瀹瑰浣曪紝浣嗕粬紜疄瓚婃潵瓚婇傚悎.NET (鍏跺疄浣犲拰鎴戠殑鎰熻鍙兘鏄竴鏍風殑錛屽井杞笉搴斿綋鎶婃爣鍑咰++榪欏潡鑲ヨ倝涓㈢粰Borland,鐒惰屽井杞彲鑳藉茍涓嶈繖鏍瘋涓?銆?/p>

銆銆2.3 GNU C++

銆銆钁楀悕鐨勫紑婧怌++緙栬瘧鍣ㄣ傛槸綾籙nix鎿嶄綔緋葷粺涓嬬紪鍐機++紼嬪簭鐨勯閫夈傜壒鐐規槸鏈夐潪甯稿ソ鐨勭Щ妞嶆э紝浣犲彲浠ュ湪闈炲父騫挎硾鐨勫鉤鍙頒笂浣跨敤瀹冿紝鍚屾椂涔熸槸緙栧啓璺ㄥ鉤鍙幫紝宓屽叆寮忕▼搴忓緢濂界殑閫夋嫨銆傚彟澶栧湪絎﹀悎鏍囧噯榪欎釜鏂歸潰涓鐩撮兘闈炲父濂斤紝GCC3.3澶ф鑳藉杈懼埌96.15%銆備絾鏄敱浜庡叾璺ㄥ鉤鍙扮殑鐗規э紝鍦ㄤ唬鐮佸昂瀵擱熷害絳変紭鍖栦笂鐣ュ井宸竴鐐廣?/p>

銆銆鍩轟簬GNU C++鐨勭紪璇戝櫒鏈夊緢澶氾紝姣斿錛?/p>

銆銆(1) Mingw

銆銆http://www.mingw.org/

銆銆GCC鐨勪竴涓猈indows鐨勭Щ妞嶇増鏈紙Dev-C++鐨勫悗鍙幫級

銆銆(2) Cygwin

銆銆http://sources.redhat.com/cygwin/

銆銆GCC鐨勫彟澶栦竴涓猈indows縐繪鐗堟湰鏄疌ygwin鐨勪竴閮ㄥ垎錛孋ygwin鏄疻indows涓嬬殑涓涓猆nix浠跨湡鐜銆備弗鏍肩殑璇存槸妯℃嫙GNU鐨勭幆澧冿紝榪欎篃灝辨槸"Gnu's Not Unix"瑕佽〃杈劇殑鎰忔濓紝鍣紝鎵繙浜嗭紝榪欏茍涓嶆槸鎴戜滑鍦ㄨ繖閲屽叧蹇冪殑瀹炶川鍐呭銆?/p>

銆銆(3) Djgpp

銆銆http://www.delorie.com/djgpp/

銆銆榪欐槸GCC鐨凞OS縐繪鐗堟湰銆?/p>

銆銆(4) RSXNT

銆銆http://www.mathematik.uni-bielefeld.de/~rainer/

銆銆榪欐槸GCC鐨凞OS鍜學indows縐繪鐗堟湰銆?/p>

銆銆(5) Intel C++

銆銆钁楀悕CPU鍒墮犲巶鍟咺ntel鍑哄搧鐨勭紪璇戝櫒錛孲pecial Design for Intel x86錛佸浜嶪ntel x86緇撴瀯鐨凜PU緇忚繃鐗瑰埆鐨勪紭鍖栥傚湪鏈変簺搴旂敤鎯呭喌涓嬶紝鐗瑰埆鏄暟鍊艱綆楃瓑楂樻ц兘搴旂敤錛屼粎浠呴噰鐢↖ntel鐨勭紪璇戝櫒緙栬瘧灝辮兘澶у箙搴︾殑鎻愰珮鎬ц兘銆?/p>

銆銆(6) Digital Mars C++

銆銆緗戠粶涓婃彁渚涘厤璐逛笅杞斤紝Zortech/Symantec C++鐨勭戶鎵胯咃紝鍏跺墠韜湪褰撳勾鎯ㄧ儓鐨凜++鍥涘浗鎴樹腑涔熸槸涓昏涔嬩竴銆?/p>

銆銆3錛屽紑鍙戠幆澧?/p>

銆銆寮鍙戠幆澧冨浜庣▼搴忓憳鐨勪綔鐢ㄤ笉璦鑰屽柣銆傞夋嫨鑷繁鏈濆鐩稿鐨勭幆澧冧篃涓嶆槸瀹規槗鐨勪簨鎯咃紝鐗瑰埆鏄湪IDE濡傛涓板瘜鐨勬儏鍐典笅銆備笅闈㈠氨鏄垜浠帹鑽愮殑涓浜涘父瑙佺殑C++寮鍙戠幆澧冿紝騫舵病鏈夊寘鎷竴浜涘皬鍨嬬殑錛岀綍瑙佺殑IDE銆傚叾涓換浣曚竴嬈鵑兘鏄姛鑳戒赴瀵岋紝鍙互鐢ㄤ綔鏃ュ父寮鍙戜嬌鐢ㄧ殑銆傚浜庝笉鍚屽眰闈㈢殑寮鍙戣咃紝璇峰弬瑙佸唴鏂囧叧浜庨傜敤瀵硅薄鐨勬弿榪般?/p>

銆銆3.1 Visual Studio 6.0

銆銆榪欎釜铏界劧鏄疢icrosoft鍏徃鐨勮佺増鏈殑寮鍙戠幆澧冿紝浣嗘槸閴翠簬鍏跺悗緇х増鏈琕isualStudio.NET鐨勫簽澶ц韓韜紝浠ュ強鍒濆鑰呭茍涓嶉偅涔堥珮鐨勫姛鑳借姹傦紝鎵浠ユ帹鑽愯繖涓紑鍙戠幆澧冪粰C++鐨勫垵瀛﹁咃紝渚涘叾瀛︿範C++鐨勬渶鍩烘湰鐨勯儴鍒嗭紝姣斿C鐨勯偅閮ㄥ垎瀛愰泦錛屽綋鐒朵綘鍒寚鏈涗粬鑳藉鏀寔鏈鏂扮殑C99鏍囧噯銆傚湪鏃ュ父鐨勫紑鍙戜腑錛屼粛鐒舵湁寰堝鍏徃浣跨敤榪欎釜緇忓吀紼沖畾鐨勭幆澧冿紝姣斿絎旇呭氨鐪嬫浘浜茶鏈変簺鍏徃灝嗗叾緙栬瘧鍣ㄦ浛鎹負GCC鍋氭墜鏈哄紑鍙戜箣鐢ㄣ?/p>

銆銆3.2 Visual Studio.NET 2003

銆銆浣滀負Microsoft鍏徃瀹樻柟姝e紡鍙戝竷鐨勬渶鏂扮増鏈紑鍙戠幆澧冿紝鍏朵腑鏈夊お澶氭縺鍔ㄤ漢蹇冪殑鍔熻兘銆傜粨鍚堝叾鏈鏂扮殑C++緙栬瘧鍣ㄣ傚浜庢満鍣ㄩ厤緗瘮杈冨ソ鐨勫紑鍙戜漢鍛樻潵璇達紝浣跨敤榪欎釜寮鍙戠幆澧冨皢鑳芥弧瓚沖叾澶ч儴鍒嗙殑瑕佹眰銆傝繖閲屼笉鎵撶畻鍗曠嫭璇碫isual Studio Whidbey,铏界劧Visual Studio .NET 2005 - Whidbey紺懼尯棰勮鐗堝凡緇忔帹鍑猴紝浣嗘殏涓嶆槸寰堢ǔ瀹氾紝璇昏呭彲浠ヤ翰韜幓浣撻獙銆?/p>

銆銆3.3 Borland C++ Builder 6

銆銆榪欎釜騫朵笉鏄疊orland鐨凜++寮鍙戠幆澧冪殑鏈鏂扮増鏈傞夋嫨瀹冪殑鍘熷洜鏄畠涓嶆槸鐢↗ava鍐欑殑IDE錛岄熷害姣旇緝蹇傚畠鏈変竴涓緢瀹屽杽鐨凣UI紿椾綋璁捐鍣紝鍜孌elphi鍏辯敤涓涓猇CL銆傜敱浜庤繖浜涚壒鐐癸紝姣旇緝閫傚悎鍒濆鑰呬笂鎵嬨備絾鏄敱浜庡叾GUI鐨勪腑蹇冧綅緗紝鍙兘涓嶅埄浜庡浜嶤++璇█鐨勫涔犮傝屼笖鍏朵負浜嗘敮鎸乂CL榪欎釜Object Pascal鍐欑殑搴撲篃瀵笴++榪涜浜嗕竴浜涚鏈夌殑鎵╁厖銆備嬌寰椾漢浠湁涓涓笉寰椾笉鎺ュ彈鐨勪簨瀹烇細鈥淏orland C++ Builder 6鐨勯珮鎵?br />鍑犱箮閮芥槸Delphi楂樻墜鈥濄?/p>

銆銆3.4 Borland C++ Builder X

銆銆姝e鍓嶆枃鎵榪幫紝铏界劧鐗堟湰鍙蜂笂鍜屽墠闈㈤偅涓狪DE闈炲父鐩歌薄錛屼絾鏄叾瀹炲畠浠槸瀹屽叏涓嶅悓鐨勪袱涓泦鎴愬紑鍙戠幆澧冦侰++Builder鏇村鐨勬槸涓涓拰Delphi鍚屾鐨凜++鐗堟湰鐨勫紑鍙戠幆澧冿紝C++BuilderX鍒欐槸瀹屽叏浠嶤++鐨勮搴︽濊冨緱鍑虹殑涓涓姛鑳戒赴瀵岀殑IDE銆傚叾鏈澶х殑鐗圭偣鏄法騫沖彴錛岃法緙栬瘧鍣紝澶氱Framework鐨勯泦鎴愶紝騫朵笖鏈変竴涓猈xWindows涓哄熀紜鐨凣UI璁捐鍣ㄣ傚挨鍏舵槸閲囩敤浜嗙函C++鏉ラ噸鍐欎簡鏁翠釜Framework,鎽掑純浜嗕互鍓嶄護浜烘棤濂堢殑鐗堟湰銆傚浜嶤++鐨勫紑鍙戞潵璇達紝浠庣紪璇戝櫒錛屽埌搴擄紝鍒板姛鑳介泦鎴愰兘鏄潪甯哥悊鎯崇殑銆傚彲浠ラ瑙侊紝Borland C++ Builder X 2.0寰堝煎緱C++鐖卞ソ鑰呮湡寰呫傚敮涓浠や漢闅懼牚涔嬪鏄綔涓轟竴涓狢++鐨勫紑鍙戝伐鍏鳳紝鍏禝DE鏄敤Java鍐欑殑錛屽湪閰嶇疆涓嶅鐞嗘兂鐨勬満鍣ㄤ笂璇鋒厧閲嶈冭檻鍐嶅畨瑁呫?/p>

銆銆3.5 Emacs + GCC

銆銆鍓嶉潰璁茬殑澶ч儴鍒嗘槸Windows鐜涓嬬殑闆嗘垚寮鍙戠幆澧冦侺inux涓婄殑寮鍙戣呮洿鍊懼悜浜庝嬌鐢‥macs鏉ョ紪杈慍++鐨勬枃浠訛紝鐢∕akefile鏉ュ懡浠CC鍋氱紪璇戙傝櫧鐒剁湅涓婂幓姣旇緝鏉炬暎錛屼絾鏄繖浜涗笢瑗跨患鍚堣搗鏉ヨ繕鏄竴涓紑0鍙戠幆澧冦傚鏋滀綘鑳藉濞寸啛鐨勪嬌鐢ㄨ繖鏍風殑鐜鍐欑▼搴忥紝浣犵殑姘村鉤搴旇瓚沖鎸囧鎴戜滑鏉ュ啓榪欑瘒闄嬫枃浜嗐?/p>

銆銆3.6 Dev C++

銆銆GCC鏄竴涓緢濂界殑緙栬瘧鍣ㄣ傚湪Windows涓婄殑C++緙栬瘧鍣ㄤ竴鐩村拰鏍囧噯鏈夌潃涓孌佃窛紱葷殑鏃跺欙紝GCC灝辨槸涓涓Windows涓嬪紑鍙戣呮祦鍙f按鐨勭紪璇戝櫒銆侱ev-C++灝辨槸鑳藉璁〨CC璺戝湪Windows涓嬬殑宸ュ叿錛屼綔涓洪泦鎴愬紑鍙戠幆澧冿紝榪樻彁渚涗簡鍚屼笓涓欼DE鐩稿緹庣殑璇硶楂樹寒錛屼唬鐮佹彁紺猴紝璋冭瘯絳夊姛鑳姐傜敱浜庝嬌鐢―elphi寮鍙戯紝鍗犵敤鍐呭瓨灝戯紝閫熷害寰堝揩錛屾瘮杈冮傚悎杞婚噺綰х殑瀛︿範鍜屼嬌鐢ㄣ?/p>

銆銆3.7 Eclipse + CDT

銆銆Eclipse鍙槸榪戞潵澶у悕榧庨紟鐨勫紑鍙戝伐鍏楓傛渶鏂頒竴鏈熺殑Jolt澶у灝遍緇欎簡榪欎釜鏉板嚭鐨勭鐗┿傝鍏剁濂囨槸鍥犱負錛屽畠鏈韓鏄敤Java鍐欑殑錛屼絾鏄嫢鏈夋瘮涓鑸琂ava鍐欑殑紼嬪簭蹇緱澶氱殑閫熷害銆傝屼笖鍥犱負鍏跺熀浜庢彃浠剁粍瑁呬竴鍒囩殑鍘熷垯錛屼嬌寰楄兘澶熸湁CDT榪欐牱鐨勬彃浠舵妸Eclipse鍙樻垚涓涓狢/C++鐨勫紑鍙戠幆澧冦傚鏋滀綘涓鐩寸敤Eclipse鍐橨ava鐨勭▼搴忥紝涓嶅Θ鐢ㄥ畠浣撻獙涓涓婥++寮鍙戠殑涔愯叮銆?/p>

--------------------------------------------------------------------------------

銆銆4錛屽伐鍏?/p>

銆銆C++鐨勮緟鍔╁伐鍏風箒澶氾紝鎴戜滑鍒嗛棬鍒被鐨勪負澶у浣滀粙緇嶏細

銆銆4.1 鏂囨。綾?/p>

銆銆(1) Doxygen

銆銆鍙傝冪珯鐐癸細http://www.doxygen.org/

銆銆Doxygen鏄竴縐嶉傚悎C椋庢牸璇█錛堝C++銆丆銆両DL銆丣ava鐢氳嚦鍖呮嫭C#鍜孭HP錛夌殑銆佸紑鏀炬簮鐮佺殑銆佸熀浜庡懡浠よ鐨勬枃妗d駭鐢熷櫒銆?/p>

銆銆(2) C++2HTML

銆銆鍙傝冪珯鐐癸細http://www.bedaux.net/cpp2html/

銆銆鎶奀++浠g爜鍙樻垚璇硶楂樹寒鐨凥TML

銆銆(3) CodeColorizer

銆銆鍙傝冪珯鐐癸細http://www.chami.com/colorizer/

銆銆瀹冭兘鎶婂ソ鍑犵璇█鐨勬簮浠g爜鐫鑹蹭負HTML

銆銆(4) Doc-O-Matic

銆銆鍙傝冪珯鐐癸細http://www.doc-o-matic.com/

銆銆Doc-O_Matic涓轟綘鐨凜/C++錛孋++.net錛孌elphi/Pascal, VB.NET錛孋#鍜孞ava紼嬪簭鎴栬呯粍浠朵駭鐢熷噯紜殑鏂囨。銆侱oc-O-Matic浣跨敤婧愪唬鐮佷腑鐨勭鍙峰拰娉ㄩ噴浠ュ強澶栭儴鐨勬枃妗f枃浠跺垱寤轟笌嫻佽鐨勬枃妗f牱寮忎竴鑷寸殑鏂囨。銆?/p>

銆銆(5) DocVizor

銆銆鍙傝冪珯鐐癸細http://www.ucancode.net/Products/DocBuilder/Features.htm

銆銆DocVizor婊¤凍浜嗛潰鍚戝璞¤蔣浠跺紑鍙戣呯殑鍩烘湰瑕佹眰鈥斺斿畠璁╂垜浠兘澶熺湅鍒癈++宸ョ▼涓殑綾誨眰嬈$粨鏋勩侱ocVizor蹇熷湴浜х敓瀹屾暣鍙緵鎵撳嵃鐨勭被灞傛緇撴瀯鍥撅紝鍖呮嫭浠庣涓夋柟搴撲腑鏉ョ殑閭d簺綾伙紝闄ゆ涔嬪DocVizor榪樿兘浠庣被淇℃伅涓駭鐢烪TML鏂囦歡銆?/p>

銆銆(6) SourcePublisher C++

銆銆鍙傝冪珯鐐癸細http://www.scitools.com/sourcepublisher_c.html

銆銆緇欐簮浠g爜浜х敓鎻愪緵蹇熺洿瑙傜殑HTML鎶ヨ〃錛屽寘鎷唬鐮侊紝綾誨眰嬈$粨鏋勶紝璋冪敤鍜岃璋冪敤鏍戯紝鍖呭惈鍜岃鍖呭惈鏍戙傛敮鎸佸縐嶆搷浣滅郴緇熴?/p>

銆銆(7) Understand

銆銆鍙傝冪珯鐐癸細http://www.scitools.com/ucpp.html

銆銆鍒嗘瀽浠諱綍瑙勬ā鐨凜鎴栬匔++宸ョ▼錛屽府鍔╂垜浠洿濂界殑鐞嗚В浠ュ強緙栧啓鏂囨。銆?/p>

銆銆4.2 浠g爜綾?/p>

銆銆(1) CC-Rider

銆銆鍙傝冪珯鐐癸細http://www.cc-rider.com/

銆銆CC-Rider鏄敤浜嶤/C++紼嬪簭寮哄ぇ鐨勪唬鐮佸彲瑙嗗寲宸ュ叿錛岄氳繃浜や簰寮忔祻瑙堛佺紪杈戝強鑷姩鏂囦歡鏉ヤ績榪涚▼搴忕殑緇存寔鍜屽彂灞曘?/p>

銆銆(2) CodeInspect

銆銆鍙傝冪珯鐐癸細http://www.yokasoft.com/

銆銆涓縐嶆柊鐨凜/C++浠g爜鍒嗘瀽宸ュ叿銆傚畠媯鏌ユ垜浠殑婧愪唬鐮佹壘鍑洪潪鏍囧噯鐨勶紝鍙兘鐨勶紝浠ュ強鏅氱殑閿欒浠g爜銆?/p>

銆銆(3) CodeWizard

銆銆鍙傝冪珯鐐癸細http://www.parasoft.com/

銆銆鍏堣繘鐨凜/C++婧愪唬鐮佸垎鏋愬伐鍏鳳紝浣跨敤瓚呰繃500涓紪鐮佽鑼冭嚜鍔ㄥ寲鍦版爣鏄庡嵄闄╃殑錛屼絾鏄紪璇戝櫒涓嶈兘媯鏌ュ埌鐨勪唬鐮佺粨鏋勩?/p>

銆銆(4) C++ Validation Test Suites

銆銆鍙傝冪珯鐐癸細http://www.plumhall.com/suites.html

銆銆涓緇勭敤浜庢祴璇曠紪璇戝櫒鍜屽簱瀵逛簬鏍囧噯鍚誨悎紼嬪害鐨勪唬鐮佸簱銆?/p>

銆銆(5) CppRefactory

銆銆鍙傝冪珯鐐癸細http://cpptool.sourceforge.net/

銆銆CPPRefactory鏄竴涓嬌寰楀紑鍙戣呰兘澶熼噸鏋勪粬浠殑C++浠g爜鐨勭▼搴忋傜洰鐨勬槸浣垮緱C++浠g爜鐨勯噸鏋勮兘澶熷敖鍙兘鐨勬湁鏁堢巼鍜岀畝鍗曘?/p>

銆銆(6) Lzz

銆銆鍙傝冪珯鐐癸細http://www.lazycplusplus.com/

銆銆Lzz鏄竴涓嚜鍔ㄥ寲璁稿C++緙栫▼涓殑浣撳姏媧葷殑宸ュ叿銆傚畠鑳藉鑺傜渷鎴戜滑璁稿浜嬩歡騫朵笖浣垮緱緙栫爜鏇村姞鏈変箰瓚c傜粰鍑轟竴緋誨垪鐨勫0鏄庯紝Lzz浼氱粰鎴戜滑鍒涘緩澶存枃浠跺拰婧愭枃浠躲?/p>

銆銆(7) QA C++ Generation 2000

銆銆鍙傝冪珯鐐癸細http://www.programmingresearch.com/solutions/qacpp.htm

銆銆瀹冨叧娉ㄩ潰鍚戝璞$殑C++婧愪唬鐮侊紝瀵規湁鍏充簬璁捐錛屾晥鐜囷紝鍙?鎬э紝鍙淮鎶ゆх殑閮ㄥ垎鎻愬嚭璀﹀憡淇℃伅銆?/p>

銆銆(8) s-mail project - Java to C++DOL

銆銆鍙傝冪珯鐐癸細http://sadlocha.strefa.pl/s-mail/ja2dol.html

銆銆鎶奐ava婧愪唬鐮佺炕璇戜負鐩稿簲鐨凜++婧愪唬鐮佺殑鍛戒護琛屽伐鍏楓?/p>

銆銆(9) SNIP from Cleanscape Software International

銆銆鍙傝冪珯鐐癸細http://www.cleanscape.net/stdprod/snip/index.html

銆銆涓涓~騫崇紪鐮佸拰璁捐涔嬮棿娌熷鐨勬槗浜庝嬌鐢ㄧ殑C++寮鍙戝伐鍏鳳紝鑺傜渷澶ч噺緙栬緫鍜岃皟璇曠殑浜嬩歡錛屽畠榪樹嬌寰楀紑鍙戣呰兘澶熸寚瀹氳璁℃ā寮忎綔涓哄璞℃ā鍨嬶紝鑷姩浠庡璞℃ā鍨嬩腑浜х敓C++鐨勭被銆?/p>

銆銆(10) SourceStyler C++

銆銆鍙傝冪珯鐐癸細http://www.ochresoftware.com/

銆銆瀵笴/C++婧愪唬鐮佹彁渚涘畬鏁寸殑鏍煎紡鍖栧拰鎺掔増鎺у埗鐨勫伐鍏楓傛彁渚涘浜?5涓殑鏍煎紡鍖栭夐」浠ュ強瀹屽叏鏀寔ANSI C++銆?/p>

銆銆4.3 緙栬瘧綾?/p>

銆銆(1) Compilercache

銆銆鍙傝冪珯鐐癸細http://www.erikyyy.de/compilercache/

銆銆Compilercache鏄竴涓浣犵殑C鍜孋++緙栬瘧鍣ㄧ殑灝佽鑴氭湰銆傛瘡嬈℃垜浠繘琛岀紪璇戯紝灝佽鑴氭湰錛屾妸緙栬瘧鐨勭粨鏋滄斁鍏ョ紦瀛橈紝涓鏃︾紪璇戠浉鍚岀殑涓滆タ錛岀粨鏋滃皢浠庣紦瀛樹腑鍙栧嚭鑰屼笉鏄啀嬈$紪璇戙?/p>

銆銆(2) Ccache

銆銆鍙傝冪珯鐐癸細http://ccache.samba.org/

銆銆Ccache鏄竴涓紪璇戝櫒緙撳瓨銆傚畠浣跨敤璧鋒潵灝卞儚C/C++緙栬瘧鍣ㄧ殑緙撳瓨棰勫鐞嗗櫒錛岀紪璇戦熷害閫氬父鑳芥彁楂樻櫘閫氱紪璇戣繃紼嬬殑5~10鍊嶃?/p>

銆銆(3) Cmm (C++ with MultiMethods)

銆銆鍙傝冪珯鐐癸細http://www.op59.net/cmm/cmm-0.28/users.html

銆銆榪欐槸涓縐岰++璇█鐨勬墿灞曘傝鍏mm婧愪唬鐮佽緭鍑篊++鐨勬簮浠g爜錛屽姛鑳芥槸瀵笴++璇█娣誨姞浜嗗multimethod鐨勬敮鎸併?/p>

銆銆(4) The Frost Project

銆銆鍙傝冪珯鐐癸細http://frost.flewid.de/

銆銆Forst浣垮緱浣犺兘澶熷湪C++紼嬪簭涓儚鍘熺敓鐨凜++鐗規т竴鏍蜂嬌鐢╩ultimethod浠ュ強铏氬嚱鏁板弬鏁般傚畠鏄竴涓紪璇戝櫒鐨勫澹熾?/p>

銆銆4.4 嫻嬭瘯鍜岃皟璇曠被

銆銆(1) CPPUnit

銆銆CppUnit 鏄釜鍩轟簬 LGPL 鐨勫紑婧愰」鐩紝鏈鍒濈増鏈Щ妞嶈嚜 JUnit錛屾槸涓涓潪甯鎬紭縐鐨勫紑婧愭祴璇曟鏋躲侰ppUnit 鍜?JUnit 涓鏍蜂富瑕佹濇兂鏉ユ簮浜庢瀬闄愮紪紼嬨備富瑕佸姛鑳藉氨鏄鍗曞厓嫻嬭瘯榪涜綆$悊錛屽茍鍙繘琛岃嚜鍔ㄥ寲嫻嬭瘯銆?br />

銆銆(2) C++Test

銆銆鍙傝冪珯鐐癸細http://www.parasoft.com/

銆銆C++ Test鏄竴涓崟鍏冩祴璇曞伐鍏鳳紝瀹冭嚜鍔ㄥ寲浜咰鍜孋++綾伙紝鍑芥暟鎴栬呯粍浠剁殑嫻嬭瘯銆?/p>


銆銆(3) Cantata++

銆銆鍙傝冪珯鐐癸細http://www.iplbath.com/products/tools/pt400.shtml

銆銆璁捐鐨勭洰鐨勬槸涓轟簡婊¤凍鍦ㄥ悎鐞嗙殑緇忔祹寮閿涓嬩嬌鐢ㄨ繖涓伐鍏峰彲浠ヨ寮鍙戝伐紼嬪笀寮灞曞崟鍏冩祴璇曞拰闆嗘垚嫻嬭瘯鐨勯渶姹?

銆銆(4) Purify

銆銆鍙傝冪珯鐐癸細http://www-900.ibm.com/cn/software/rational/products/purif
yplus/index.shtml

銆銆IBM Rational PurifyPlus鏄竴濂楀畬鏁寸殑榪愯鏃跺垎鏋愬伐鍏鳳紝鏃ㄥ湪鎻愰珮搴旂敤紼嬪簭鐨勫彲*鎬у拰鎬ц兘銆侾urifyPlus灝嗗唴瀛橀敊璇拰娉勬紡媯嫻嬨佸簲鐢ㄧ▼搴忔ц兘鎻忚堪銆佷唬鐮佽鐩栧垎鏋愮瓑鍔熻兘緇勫悎鍦ㄤ竴涓崟涓銆佸畬鏁寸殑宸ュ叿鍖呬腑銆?/p>

銆銆(5) BoundsChecker

銆銆BoundsChecker鏄竴涓狢++榪愯鏃墮敊璇嫻嬪拰璋冭瘯宸ュ叿銆傚畠閫氳繃鍦╒isual Studio鍐呰嚜鍔ㄥ寲璋冭瘯榪囩▼鍔犻熷紑鍙戝茍涓旂緝鐭笂甯傜殑鍛ㄦ湡銆侭oundsChecker鎻愪緵娓呮錛岃緇嗙殑紼嬪簭閿欒鍒嗘瀽錛岃澶氭槸瀵笴++鐙湁鐨勫茍涓斿湪static錛宻tack鍜宧eap鍐呭瓨涓嫻嬪拰璇婃柇閿欒錛屼互鍙婂彂鐜板唴瀛樺拰璧勬簮鐨勬硠婕忋傘銆

銆銆(6) Insure++

銆銆鍙傝冪珯鐐癸細http://www.parasoft.com/

銆銆涓涓嚜鍔ㄥ寲鐨勮繍琛屾椂紼嬪簭嫻嬭瘯宸ュ叿錛屾鏌ラ毦浠ュ療瑙夌殑閿欒,濡傚唴瀛樿鐩栵紝鍐呭瓨娉勬紡錛屽唴瀛樺垎閰嶉敊璇紝鍙橀噺鍒濆鍖栭敊璇紝鍙橀噺瀹氫箟鍐茬獊錛屾寚閽堥敊璇紝搴撻敊璇紝閫昏緫閿欒鍜岀畻娉曢敊璇瓑銆?/p>

銆銆(7) GlowCode

銆銆鍙傝冪珯鐐癸細http://www.glowcode.com/

銆銆GlowCode鍖呮嫭鍐呭瓨娉勬紡媯鏌ワ紝code profiler錛屽嚱鏁拌皟鐢ㄨ窡韙瓑鍔熻兘銆傜粰C++寮鍙戣呮彁渚涘畬鏁寸殑閿欒璇婃柇錛屽拰榪愯鏃舵ц兘鍒嗘瀽宸ュ叿鍖呫?/p>

銆銆(8) Stack Spy

銆銆鍙傝冪珯鐐癸細http://www.imperioustech.com/

銆銆瀹冭兘鎹曟崏stack corruption, stack over run, stack overflow絳夋湁鍏蟲爤鐨勯敊璇?/p>

------------------------------------------------------------------------
銆5錛屽簱

銆銆鍦–++涓紝搴撶殑鍦頒綅鏄潪甯擱珮鐨勩侰++涔嬬埗 Bjarne Stroustrup鍏堢敓澶氭琛ㄧず浜嗚璁″簱鏉ユ墿鍏呭姛鑳借濂借繃璁捐鏇村鐨勮娉曠殑璦璁恒傜幇瀹炰腑錛孋++鐨勫簱闂ㄧ被綣佸錛岃В鍐崇殑闂涔熸槸鏋佸叾騫挎硾錛屽簱浠庤交閲忕駭鍒伴噸閲忕駭鐨勯兘鏈夈備笉灝戦兘鏄浜虹溂鐣屽ぇ寮錛屼害鎴栨槸鏈涜岀敓鍙圭殑鎬濈淮鏉頒綔銆傜敱浜庡簱鐨勬暟閲忛潪甯稿簽澶э紝鑰屼笖闄愪簬絎旇呮按騫籌紝鍏朵腑寰堝騫朵笉浜嗚В銆傛墍浠ユ枃涓墍鎻愮殑涓浜涘簱閮芥槸姣旇緝钁楀悕鐨勫ぇ鍨嬪簱銆?/p>

銆銆5.1 鏍囧噯搴?/p>

銆銆鏍囧噯搴撲腑鎻愪緵浜咰++紼嬪簭鐨勫熀鏈鏂姐傝櫧鐒禖++鏍囧噯搴撻殢鐫C++鏍囧噯鎶樿吘浜嗚澶氬勾錛岀洿鍒版爣鍑嗙殑鍑哄彴鎵嶆寮忓畾鍨嬶紝浣嗘槸鍦ㄦ爣鍑嗗簱鐨勫疄鐜頒笂鍗村緢浠や漢嬈f叞寰楃湅鍒板縐嶅疄鐜幫紝騫朵笖宸茶瀹炶返璇佹槑涓烘湁宸ヤ笟綰у埆寮哄害鐨勪匠浣溿?/p>

銆銆(1) Dinkumware C++ Library

銆銆鍙傝冪珯鐐癸細http://www.dinkumware.com/

銆銆P.J. Plauger緙栧啓鐨勯珮鍝佽川鐨勬爣鍑嗗簱銆侾.J. Plauger鍗氬+鏄疍r. Dobb's紼嬪簭璁捐鏉板嚭濂栫殑鑾峰緱鑰呫傚叾緙栧啓鐨勫簱闀挎湡琚玀icrosoft閲囩敤錛屽茍涓旀渶榪態orland涔熷彇寰椾簡鍏禣EM鐨刲icense錛屽湪鍏禖/C++鐨勪駭鍝佷腑閲囩敤Dinkumware鐨勫簱銆?/p>

銆銆(2) RogueWave Standard C++ Library

銆銆鍙傝冪珯鐐癸細http://www.roguewave.com/

銆銆榪欎釜搴撳湪Borland C++ Builder鐨勬棭鏈熺増鏈腑鏇劇粡琚噰鐢紝鍚庢潵琚叾浠栫殑搴撶粰鏇挎崲浜嗐傜瑪鑰呬笉鎺ㄨ崘浣跨敤銆?/p>

銆銆(3) SGI STL

銆銆鍙傝冪珯鐐癸細http://www.roguewave.com/

銆銆SGI鍏徃鐨凜++鏍囧噯妯$増搴撱?/p>

銆銆(4) STLport

銆銆鍙傝冪珯鐐癸細http://www.stlport.org/

銆銆SGI STL搴撶殑璺ㄥ鉤鍙板彲縐繪鐗堟湰銆?/p>

銆銆5.2 鈥滃噯鈥濇爣鍑嗗簱 - Boost

銆銆鍙傝冪珯鐐癸細http://www.boost.org/

銆銆鍥藉唴闀滃儚錛?a >http://www.c-view.org/tech/lib/boost/index.htm

銆銆Boost搴撴槸涓涓粡榪囧崈閿ょ櫨鐐箋佸彲縐繪銆佹彁渚涙簮浠g爜鐨凜++搴擄紝浣滀負鏍囧噯搴撶殑鍚庡錛屾槸C++鏍囧噯鍖栬繘紼嬬殑鍙戝姩鏈轟箣涓銆?Boost搴撶敱C++鏍囧噯濮斿憳浼氬簱宸ヤ綔緇勬垚鍛樺彂璧鳳紝鍦–++紺懼尯涓獎鍝嶇敋澶э紝鍏舵垚鍛樺凡榪?000浜恒?Boost搴撲負鎴戜滑甯︽潵浜嗘渶鏂般佹渶閰楓佹渶瀹炵敤鐨勬妧鏈紝鏄笉鎶樹笉鎵g殑鈥滃噯鈥濇爣鍑嗗簱銆?/p>

銆銆Boost涓瘮杈冩湁鍚嶆皵鐨勬湁榪欎箞鍑犱釜搴擄細

銆銆Regex

銆銆姝e垯琛ㄨ揪寮忓簱

銆銆Spirit

銆銆LL parser framework錛岀敤C++浠g爜鐩存帴琛ㄨ揪EBNF

銆銆Graph

銆銆鍥劇粍浠跺拰綆楁硶

銆銆Lambda

銆銆鍦ㄨ皟鐢ㄧ殑鍦版柟瀹氫箟鐭皬鍖垮悕鐨勫嚱鏁板璞★紝寰堝疄鐢ㄧ殑functional鍔熻兘

銆銆concept check

銆銆媯鏌ユ硾鍨嬬紪紼嬩腑鐨刢oncept

銆銆Mpl

銆銆鐢ㄦā鏉垮疄鐜扮殑鍏冪紪紼嬫鏋?/p>

銆銆Thread

銆銆鍙Щ妞嶇殑C++澶氱嚎紼嬪簱

銆銆Python

銆銆鎶奀++綾誨拰鍑芥暟鏄犲皠鍒癙ython涔嬩腑

銆銆Pool

銆銆鍐呭瓨姹犵鐞?/p>

銆銆smart_ptr

銆銆5涓櫤鑳芥寚閽堬紝瀛︿範鏅鴻兘鎸囬拡蹇呰錛屼竴浠戒笉閿欑殑鍙傝冩槸鏉ヨ嚜CUJ鐨勬枃绔狅細

銆銆Smart Pointers in Boost錛屽摝錛岃繖綃囨枃绔犲彲浠ユ煡鍒幫紝CUJ鏄彁渚涘湪綰挎祻瑙堢殑銆備腑鏂囩増瑙佺瑪鑰呭湪銆奃r. Dobb's Journal杞歡鐮斿彂鏉傚織銆嬬7杈戜笂鐨勮瘧鏂囥?/p>

銆銆Boost鎬諱綋鏉ヨ鏄疄鐢ㄤ環鍊煎緢楂橈紝璐ㄩ噺寰堥珮鐨勫簱銆傚茍涓旂敱浜庡叾瀵硅法騫沖彴鐨勫己璋冿紝瀵規爣鍑咰++鐨勫己璋冿紝鏄紪鍐欏鉤鍙版棤鍏籌紝鐜頒唬C++鐨勫紑鍙戣呭繀澶囩殑宸ュ叿銆備絾鏄疊oost涓篃鏈夊緢澶氭槸瀹為獙鎬ц川鐨勪笢瑗匡紝鍦ㄥ疄闄呯殑寮鍙戜腑瀹炵敤闇瑕佽皚鎱庛傚茍涓斿緢澶欱oost涓殑搴撳姛鑳藉牚縐板璇█鍔熻兘鐨勬墿灞曪紝鍏舵瀯閫犵敤灝界簿宸х殑鎵嬫硶錛屼笉瑕佽錘鐒剁殑鑺辮垂鏃墮棿鐮旇銆侭oost鍙﹀涓闈紝姣斿Graph榪欐牱鐨勫簱鍒欐槸鍏鋒湁宸ヤ笟寮哄害錛岀粨鏋勮壇濂斤紝闈炲父鍊煎緱鐮旇鐨勭簿鍝佷唬鐮侊紝騫朵笖涔熷彲浠ユ斁蹇冪殑鍦ㄤ駭鍝佷唬鐮佷腑澶氬鍒╃敤銆?/p>

銆銆5.3 GUI

銆銆鍦ㄤ紬澶欳++鐨勫簱涓紝GUI閮ㄥ垎鐨勫簱綆楁槸姣旇緝綣佽崳錛屼篃姣旇緝寮曚漢娉ㄧ洰鐨勩傚湪瀹為檯寮鍙戜腑錛孏UI搴撶殑閫夋嫨涔熸槸闈炲父閲嶈鐨勪竴浠朵簨鎯咃紝涓嬮潰鎴戜滑緇艱堪涓涓嬪彲閫夋嫨鐨凣UI搴擄紝鍚勮嚜鐨勭壒鐐逛互鍙婄浉鍏沖伐鍏風殑鏀寔銆?/p>

銆銆(1) MFC

銆銆澶у悕榧庨紟鐨勫井杞熀紜綾誨簱錛圡icrosoft Foundation Class錛夈傚ぇ鍑″榪嘨C++鐨勪漢閮藉簲璇ョ煡閬撹繖涓簱銆傝櫧鐒朵粠鎶鏈搴﹁錛孧FC鏄笉澶ф紓浜殑錛屼絾鏄畠鏋勫緩浜嶹indows API 涔嬩笂錛岃兘澶熶嬌紼嬪簭鍛樼殑宸ヤ綔鏇村鏄?緙栫▼鏁堢巼楂橈紝鍑忓皯浜嗗ぇ閲忓湪寤虹珛 Windows 紼嬪簭鏃跺繀欏葷紪鍐欑殑浠g爜錛屽悓鏃跺畠榪樻彁渚涗簡鎵鏈変竴鑸?C++ 緙栫▼鐨勪紭鐐癸紝渚嬪緇ф壙鍜屽皝瑁呫侻FC 緙栧啓鐨勭▼搴忓湪鍚勪釜鐗堟湰鐨刉indows鎿嶄綔緋葷粺涓婃槸鍙Щ妞嶇殑錛屼緥濡傦紝鍦╓indows 3.1涓嬬紪鍐欑殑浠g爜鍙互寰堝鏄撳湴縐繪鍒?Windows NT 鎴?Windows 95 涓娿備絾鏄湪鏈榪戝彂灞曚互鍙婂畼鏂規敮鎸佷笂鏃ユ笎鍔垮井銆?/p>

銆銆(2) QT

銆銆鍙傝冪綉绔欙細http://www.trolltech.com/

銆銆Qt鏄疶rolltech鍏徃鐨勪竴涓騫沖彴鐨凜++鍥懼艦鐢ㄦ埛鐣岄潰搴旂敤紼嬪簭妗嗘灦銆傚畠鎻愪緵緇欏簲鐢ㄧ▼搴忓紑鍙戣呭緩绔嬭壓鏈駭鐨勫浘褰㈢敤鎴風晫闈㈡墍闇鐨勬墍鐢ㄥ姛鑳姐俀t鏄畬鍏ㄩ潰鍚戝璞$殑寰堝鏄撴墿灞曪紝騫朵笖鍏佽鐪熸鍦扮粍浠剁紪紼嬨傝嚜浠?996騫存棭浜涙椂鍊欙紝Qt榪涘叆鍟嗕笟棰嗗煙錛屽畠宸茬粡鎴愪負鍏ㄤ笘鐣岃寖鍥村唴鏁板崈縐嶆垚鍔熺殑搴旂敤紼嬪簭鐨勫熀紜銆俀t涔熸槸嫻佽鐨凩inux妗岄潰鐜KDE 鐨勫熀紜錛屽悓鏃跺畠榪樻敮鎸乄indows銆丮acintosh銆乁nix/X11絳夊縐嶅鉤鍙般?/p>

銆銆(3) WxWindows

銆銆鍙傝冪綉绔欙細http://www.wxwindows.org/

銆銆璺ㄥ鉤鍙扮殑GUI搴撱傚洜涓哄叾綾誨眰嬈℃瀬鍍廙FC錛屾墍浠ユ湁鏂囩珷浠嬬粛浠嶮FC鍒癢xWindows鐨勪唬鐮佺Щ妞嶄互瀹炵幇璺ㄥ鉤鍙扮殑鍔熻兘銆傞氳繃澶氬勾鐨勫紑鍙戜篃鏄竴涓棩瓚嬪畬鍠勭殑GUI搴擄紝鏀寔鍚屾牱涓嶅急浜庡墠闈袱涓簱銆傚茍涓旀槸瀹屽叏寮鏀炬簮浠g爜鐨勩傛柊榪戠殑C++ Builder X鐨凣UI璁捐鍣ㄥ氨鏄熀浜庤繖涓簱鐨勩?/p>

銆銆(4) Fox

銆銆鍙傝冪綉绔欙細http://www.fox-toolkit.org/

銆銆寮鏀炬簮浠g爜鐨凣UI搴撱備綔鑰呬粠鑷繁浜茶韓鐨勫紑鍙戠粡楠屼腑寰楀嚭浜嗕竴涓悊鎯崇殑GUI搴撳簲璇ユ槸浠涔堟牱瀛愮殑鎰熷彈鍑哄彂錛屼粠鑰屽紑濮嬩簡瀵硅繖涓簱鐨勫紑鍙戙傛湁鍏磋叮鐨勫彲浠ュ皾璇曚竴涓嬨?/p>


銆銆(5) WTL

銆銆鍩轟簬ATL鐨勪竴涓簱銆傚洜涓轟嬌鐢ㄤ簡澶ч噺ATL鐨勮交閲忕駭鎵嬫硶錛屾ā鏉跨瓑鎶鏈紝鍦ㄤ唬鐮佸昂瀵革紝浠ュ強閫熷害浼樺寲鏂歸潰鍋氬緱闈炲父鍒頒綅銆備富瑕侀潰鍚戠殑浣跨敤緹や綋鏄紑鍙慍OM杞婚噺綰т緵緗戠粶涓嬭澆鐨勫彲瑙嗗寲鎺т歡鐨勫紑鍙戣呫?/p>

銆銆(6) GTK

銆銆鍙傝冪綉绔欙細http://gtkmm.sourceforge.net/

銆銆GTK鏄竴涓ぇ鍚嶉紟榧庣殑C鐨勫紑婧怗UI搴撱傚湪Linux涓栫晫涓湁Gnome榪欐牱鐨勬潃鎵嬪簲鐢ㄣ傝孏TK灝辨槸榪欎釜搴撶殑C++灝佽鐗堟湰銆?/p>

銆銆5.4 緗戠粶閫氫俊

銆銆(1) ACE

銆銆鍙傝冪綉绔欙細http://www.cs.wustl.edu/~schmidt/ACE.html

銆銆C++搴撶殑浠h〃錛岃秴閲嶉噺綰х殑緗戠粶閫氫俊寮鍙戞鏋躲侫CE鑷傞厤閫氫俊鐜錛圓daptiveCommunication Environment錛夋槸鍙互鑷敱浣跨敤銆佸紑鏀炬簮浠g爜鐨勯潰鍚戝璞℃鏋訛紝鍦ㄥ叾涓疄鐜頒簡璁稿鐢ㄤ簬騫跺彂閫氫俊杞歡鐨勬牳蹇冩ā寮忋侫CE鎻愪緵浜嗕竴緇勪赴瀵岀殑鍙鐢–++鍖呰澶栬錛圵rapper Facade錛夊拰妗嗘灦緇勪歡錛屽彲璺ㄨ秺澶氱騫沖彴瀹屾垚閫氱敤鐨勯氫俊杞歡浠誨姟錛屽叾涓寘鎷細浜嬩歡澶氳礬鍒嗙鍜屼簨浠跺鐞嗗櫒鍒嗘淳銆佷俊鍙峰鐞嗐佹湇鍔″垵濮嬪寲銆佽繘紼嬮棿閫?br />淇°佸叡浜唴瀛樼鐞嗐佹秷鎭礬鐢便佸垎甯冨紡鏈嶅姟鍔ㄦ侊紙閲嶏級閰嶇疆銆佸茍鍙戞墽琛屽拰鍚屾錛岀瓑絳夈?/p>

銆銆(2) StreamModule

銆銆鍙傝冪綉绔欙細http://www.omnifarious.org/StrMod/

銆銆璁捐鐢ㄤ簬綆鍖栫紪鍐欏垎甯冨紡紼嬪簭鐨勫簱銆傚皾璇曠潃浣垮緱緙栧啓澶勭悊寮傛琛屼負鐨勭▼搴忔洿瀹規槗錛岃屼笉鏄敤鍚屾鐨勫澹沖寘璧峰紓姝ョ殑鏈川銆?/p>

銆銆(3) SimpleSocket

銆銆鍙傝冪綉绔欙細http://home.hetnet.nl/~lcbokkers/simsock.htm

銆銆榪欎釜綾誨簱璁╃紪鍐欏熀浜巗ocket鐨勫鎴?鏈嶅姟鍣ㄧ▼搴忔洿鍔犲鏄撱?/p>

銆銆(4) A Stream Socket API for C++

銆銆鍙傝冪綉绔欙細http://www.pcs.cnu.edu/~dgame/sockets/socketsC++/sockets.h
tml

銆銆鍙堜竴涓Socket鐨勫皝瑁呭簱銆?/p>

銆銆5.5 XML

銆銆(1) Xerces

銆銆鍙傝冪綉绔欙細http://xml.apache.org/xerces-c/

銆銆Xerces-C++ 鏄竴涓潪甯稿仴澹殑XML瑙f瀽鍣紝瀹冩彁渚涗簡楠岃瘉錛屼互鍙奡AX鍜孌OM API銆俋ML楠岃瘉鍦ㄦ枃妗g被鍨嬪畾涔?Document Type Definition錛孌TD)鏂歸潰鏈夊緢濂界殑鏀寔錛屽茍涓斿湪2001騫?2鏈堝鍔犱簡鏀寔W3C XML Schema 鐨勫熀鏈畬鏁寸殑寮鏀炬爣鍑嗐?/p>

銆銆(2) XMLBooster

銆銆鍙傝冪綉绔欙細http://www.xmlbooster.com/

銆銆榪欎釜搴撻氳繃浜х敓鐗瑰埗鐨刾arser鐨勫姙娉曟瀬澶х殑鎻愰珮浜哫ML瑙f瀽鐨勯熷害錛屽茍涓旇兘澶熶駭鐢熺浉搴旂殑GUI紼嬪簭鏉ヤ慨鏀硅繖涓猵arser銆傚湪DOM鍜孲AX涓ゅぇ涓繪祦XML瑙f瀽鍔炴硶涔嬪鎻愪緵浜嗗彟澶栦竴涓彲琛岀殑瑙e喅鏂規銆?/p>

銆銆(3) Pull Parser

銆銆鍙傝冪綉绔欙細http://www.extreme.indiana.edu/xgws/xsoap/xpp/

銆銆榪欎釜搴撻噰鐢╬ull鏂規硶鐨刾arser銆傚湪姣忎釜SAX鐨刾arser搴曞眰閮芥湁涓涓猵ull鐨刾arser錛岃繖涓獂pp鎶婅繖灞傛毚闇插嚭鏉ョ洿鎺ョ粰澶у浣跨敤銆傚湪瑕佸厖鍒嗚冭檻閫熷害鐨勬椂鍊欏煎緱灝濊瘯銆?br />
銆銆(4) Xalan

銆銆鍙傝冪綉绔欙細http://xml.apache.org/xalan-c/

銆銆Xalan鏄竴涓敤浜庢妸XML鏂囨。杞崲涓篐TML錛岀函鏂囨湰鎴栬呭叾浠朮ML綾誨瀷鏂囨。鐨刋SLT澶勭悊鍣ㄣ?/p>

銆銆(5) CMarkup

銆銆鍙傝冪綉绔欙細http://www.firstobject.com/xml.htm

銆銆榪欐槸涓縐嶄嬌鐢‥DOM鐨刋ML瑙f瀽鍣ㄣ傚湪寰堝鎬濊礬涓婇潰闈炲父鐏墊椿瀹炵敤銆傚煎緱澶у鍦―OM鍜孲AX涔嬪瀵繪眰涓鐐圭伒鎰熴?/p>

銆銆(6) libxml++

銆銆http://libxmlplusplus.sourceforge.net/

銆銆libxml++鏄钁楀悕鐨刲ibxml XML瑙f瀽鍣ㄧ殑C++灝佽鐗堟湰

銆銆5.6 縐戝璁$畻

銆銆(1) Blitz++

銆銆鍙傝冪綉绔欙細http://www.oonumerics.org/blitz/

銆銆Blitz++ 鏄竴涓珮鏁堢巼鐨勬暟鍊艱綆楀嚱鏁板簱錛屽畠鐨勮璁$洰鐨勬槸甯屾湜寤虹珛涓濂楁棦鍏峰儚C++ 涓鏍鋒柟渚匡紝鍚屾椂鍙堟瘮Fortran閫熷害鏇村揩鐨勬暟鍊艱綆楃幆澧冦傞氬父錛岀敤C++鎵鍐欏嚭鐨勬暟鍊肩▼搴忥紝姣?Fortran鎱?0%宸﹀彸錛屽洜姝litz++姝f槸瑕佹敼鎺夎繖涓己鐐廣傛柟娉曟槸鍒╃敤C++鐨則emplate鎶鏈紝紼嬪簭鎵ц鐢氳嚦鍙互姣擣ortran鏇村揩銆侭litz++鐩墠浠嶅湪鍙戝睍涓紝瀵逛簬甯歌鐨凷VD錛孎FTs錛孮MRES絳夊父瑙佺殑綰挎т唬鏁版柟娉曞茍涓嶆彁渚涳紝涓嶈繃浣跨敤鑰呭彲浠ュ緢瀹規槗鍦板埄鐢˙litz++鎵鎻愪緵鐨勫嚱鏁版潵鏋勫緩銆?/p>

銆銆(2) POOMA

銆銆鍙傝冪綉绔欙細http://www.codesourcery.com/pooma/pooma

銆銆POOMA鏄竴涓厤璐圭殑楂樻ц兘鐨凜++搴擄紝鐢ㄤ簬澶勭悊騫惰寮忕瀛﹁綆椼侾OOMA鐨勯潰鍚戝璞¤璁℃柟渚夸簡蹇熺殑紼嬪簭寮鍙戯紝瀵瑰茍琛屾満鍣ㄨ繘琛屼簡浼樺寲浠ヨ揪鍒版渶楂樼殑鏁堢巼錛屾柟渚垮湪宸ヤ笟鍜岀爺絀剁幆澧冧腑浣跨敤銆?/p>

銆銆(3) MTL

銆銆鍙傝冪綉绔欙細http://www.osl.iu.edu/research/mtl/

銆銆Matrix Template Library(MTL)鏄竴涓珮鎬ц兘鐨勬硾鍨嬬粍浠跺簱錛屾彁渚涗簡鍚勭鏍煎紡鐭╅樀鐨勫ぇ閲忕嚎鎬т唬鏁版柟闈㈢殑鍔熻兘銆傚湪鏌愪簺搴旂敤浣跨敤楂樻ц兘緙栬瘧鍣ㄧ殑鎯呭喌涓嬶紝姣斿Intel鐨勭紪璇戝櫒錛屼粠浜х敓鐨勬眹緙栦唬鐮佸彲浠ョ湅鍑哄叾涓庢墜鍐欏嚑涔庢病鏈変袱鏍風殑鏁堣兘銆?/p>

銆銆(4) CGAL

銆銆鍙傝冪綉绔欙細http://www.cgal.org/

銆銆Computational Geometry Algorithms Library鐨勭洰鐨勬槸鎶婂湪璁$畻鍑犱綍鏂歸潰鐨勫ぇ閮ㄥ垎閲嶈鐨勮В鍐蟲柟妗堝拰鏂規硶浠++搴撶殑褰㈠紡鎻愪緵緇欏伐涓氬拰瀛︽湳鐣岀殑鐢ㄦ埛銆?/p>

銆銆5.7 娓告垙寮鍙?/p>

銆銆(1) Audio/Video 3D C++ Programming Library

銆銆鍙傝冪綉绔欙細http://www.galacticasoftware.com/products/av/

銆銆AV3D鏄竴涓法騫沖彴錛岄珮鎬ц兘鐨凜++搴撱備富瑕佺殑鐗規ф槸鎻愪緵3D鍥懼艦錛屽0鏁堟敮鎸侊紙SB,浠ュ強S3M錛夛紝鎺у埗鎺ュ彛錛堥敭鐩橈紝榧犳爣鍜岄仴鎰燂級錛孹MS銆?/p>

銆銆(2) KlayGE

銆銆鍙傝冪綉绔欙細http://home.g365.net/enginedev/

銆銆鍥藉唴娓告垙寮鍙戦珮鎵嬭嚜宸辯敤C++寮鍙戠殑娓告垙寮曟搸銆侹layGE鏄竴涓紑鏀炬簮浠g爜銆佽法騫沖彴鐨勬父鎴忓紩鎿庯紝騫朵嬌鐢≒ython浣滆剼鏈璦銆侹layGE鍦↙GPL鍗忚涓嬪彂琛屻傛劅璋㈤練鏁忔晱鍏堢敓涓轟腑鍥芥父鎴忓紑鍙戜簨涓氭墍鍋氬嚭鐨勮礎鐚?/p>

銆銆(3) OGRE

銆銆鍙傝冪綉绔欙細http://www.ogre3d.org/

銆銆OGRE錛堥潰鍚戝璞$殑鍥懼艦娓叉煋寮曟搸錛夋槸鐢–++寮鍙戠殑錛屼嬌鐢ㄧ伒媧葷殑闈㈠悜瀵硅薄3D寮曟搸銆傚畠鐨勭洰鐨勬槸璁╁紑鍙戣呰兘鏇存柟渚垮拰鐩存帴鍦板紑鍙戝熀浜?D紜歡璁懼鐨勫簲鐢ㄧ▼搴忔垨娓告垙銆傚紩鎿庝腑鐨勭被搴撳鏇村簳灞傜殑緋葷粺搴擄紙濡傦細Direct3D鍜孫penGL錛夌殑鍏ㄩ儴浣跨敤緇嗚妭榪涜浜嗘娊璞★紝騫舵彁渚涗簡鍩轟簬鐜板疄涓栫晫瀵硅薄鐨勬帴鍙e拰鍏跺畠綾匯?/p>

銆銆5.8 綰跨▼

銆銆(1) C++ Threads

銆銆鍙傝冪綉绔欙細http://threads.sourceforge.net/

銆銆榪欎釜搴撶殑鐩爣鏄粰紼嬪簭鍛樻彁渚涙槗浜庝嬌鐢ㄧ殑綾伙紝榪欎簺綾昏緇ф壙浠ユ彁渚涘湪Linux鐜涓緢闅劇湅鍒扮殑澶ч噺鐨勭嚎紼嬫柟闈㈢殑鍔熻兘銆?/p>

銆銆(2) ZThreads

銆銆鍙傝冪綉绔欙細http://zthread.sourceforge.net/

銆銆涓涓厛榪涚殑闈㈠悜瀵硅薄錛岃法騫沖彴鐨凜++綰跨▼鍜屽悓姝ュ簱銆?br />

銆銆5.9 搴忓垪鍖?/p>

銆銆(1) s11n

銆銆鍙傝冪綉绔欙細http://s11n.net/

銆銆涓涓熀浜嶴TL鐨凜++搴擄紝鐢ㄤ簬搴忓垪鍖朠OD錛孲TL瀹瑰櫒浠ュ強鐢ㄦ埛瀹氫箟鐨勭被鍨嬨?/p>

銆銆(2) Simple XML Persistence Library

銆銆鍙傝冪綉绔欙細http://sxp.sourceforge.net/

銆銆榪欐槸涓涓妸瀵硅薄搴忓垪鍖栦負XML鐨勮交閲忕駭鐨凜++搴撱?/p>

銆銆5.10 瀛楃涓?/p>

銆銆(1) C++ Str Library

銆銆鍙傝冪綉绔欙細http://www.utilitycode.com/str/

銆銆鎿嶄綔瀛楃涓插拰瀛楃鐨勫簱錛屾敮鎸乄indows鍜屾敮鎸乬cc鐨勫縐嶅鉤鍙般傛彁渚涢珮搴︿紭鍖栫殑浠g爜錛屽茍涓旀敮鎸佸綰跨▼鐜鍜孶nicode錛屽悓鏃惰繕鏈夋鍒欒〃杈懼紡鐨勬敮鎸併?/p>

銆銆(2) Common Text Transformation Library

銆銆鍙傝冪綉绔欙細http://cttl.sourceforge.net/

銆銆榪欐槸涓涓В鏋愬拰淇敼STL瀛楃涓茬殑搴撱侰TTL substring綾誨彲浠ョ敤鏉ユ瘮杈冿紝鎻掑叆錛屾浛鎹互鍙婄敤EBNF鐨勮娉曡繘琛岃В鏋愩?/p>

銆銆(3) GRETA

銆銆鍙傝冪綉绔欙細http://research.microsoft.com/projects/greta/

銆銆榪欐槸鐢卞井杞爺絀墮櫌鐨勭爺絀朵漢鍛樺紑鍙戠殑澶勭悊姝e垯琛ㄨ揪寮忕殑搴撱傚湪灝忓瀷鍖歸厤鐨勬儏鍐典笅鏈夐潪甯鎬紭縐鐨勮〃鐜般?/p>

銆銆5.11 緇煎悎

銆銆(1) P::Classes

銆銆鍙傝冪綉绔欙細http://pclasses.com/

銆銆涓涓珮搴﹀彲縐繪鐨凜++搴旂敤紼嬪簭妗嗘灦銆傚綋鍓嶅叧娉ㄧ被鍨嬪拰綰跨▼瀹夊叏鐨剆ignal/slot鏈哄埗錛宨/o緋葷粺鍖呮嫭鍩轟簬鎻掍歡鐨勭綉緇滃崗璁忔槑鐨刬/o鏋舵瀯錛屽熀浜庢彃浠剁殑搴旂敤紼嬪簭娑堟伅鏃ュ織妗嗘灦錛岃闂畇ql鏁版嵁搴撶殑綾葷瓑絳夈?/p>

銆銆(2) ACDK - Artefaktur Component Development Kit

銆銆鍙傝冪綉绔欙細http://acdk.sourceforge.net/

銆銆榪欐槸涓涓鉤鍙版棤鍏崇殑C++緇勪歡妗嗘灦錛岀被浼間簬Java鎴栬?NET涓殑妗嗘灦錛堝弽灝勬満鍒訛紝綰跨▼錛孶nicode錛屽簾鏂欐敹闆嗭紝I/O錛岀綉緇滐紝瀹炵敤宸ュ叿錛孹ML錛岀瓑絳夛級錛屼互鍙婂Java, Perl, Python, TCL, Lisp, COM 鍜?CORBA鐨勯泦鎴愩?/p>

銆銆(3) dlib C++ library

銆銆鍙傝冪綉绔欙細http://www.cis.ohio-state.edu/~kingd/dlib/

銆銆鍚勭鍚勬牱鐨勭被鐨勪竴涓患鍚堛傚ぇ鏁存暟錛孲ocket錛岀嚎紼嬶紝GUI錛屽鍣ㄧ被,浠ュ強嫻忚鐩綍鐨凙PI絳夌瓑銆?/p>

銆銆(4) Chilkat C++ Libraries

銆銆鍙傝冪綉绔欙細http://www.chilkatsoft.com/cpp_libraries.asp

銆銆榪欐槸鎻愪緵zip錛宔-mail錛岀紪鐮侊紝S/MIME錛孹ML絳夋柟闈㈢殑搴撱?/p>

銆銆(5) C++ Portable Types Library (PTypes)

銆銆鍙傝冪綉绔欙細http://www.melikyan.com/ptypes/

銆銆榪欐槸STL鐨勬瘮杈冪畝鍗曠殑鏇夸唬鍝侊紝浠ュ強鍙Щ妞嶇殑澶氱嚎紼嬪拰緗戠粶搴撱?/p>

銆銆(6) LFC

銆銆鍙傝冪綉绔欙細http://lfc.sourceforge.net/

銆銆鍝︼紝榪欏張鏄竴涓皾璇曟彁渚涗竴鍒囩殑C++搴?/p>

銆銆5.12 鍏朵粬搴?/p>

銆銆(1) Loki

銆銆鍙傝冪綉绔欙細http://www.moderncppdesign.com/

銆銆鍝︼紝浣犲彲鑳芥姳鎬ㄦ垜鏃╄鍜孊oost涓璧蜂粙緇嶅畠錛屼竴涓疄楠屾ц川鐨勫簱銆備綔鑰呭湪loki涓妸C++妯℃澘鐨勫姛鑳藉彂鎸ュ埌浜嗘瀬鑷淬傚茍涓斿皾璇曟妸綾諱技璁捐妯″紡榪欐牱鎬濇兂灞傞潰鐨勪笢瑗塊氳繃搴撴潵鎻愪緵銆傚悓鏃惰繕鎻愪緵浜嗘櫤鑳芥寚閽堣繖鏍鋒瘮杈冨疄鐢ㄧ殑鍔熻兘銆?/p>

銆銆(2) ATL

銆銆ATL(Active Template Library)

銆銆鏄竴緇勫皬宸с侀珮鏁堛佺伒媧葷殑綾伙紝榪欎簺綾諱負鍒涘緩鍙簰鎿嶄綔鐨凜OM緇勪歡鎻愪緵浜嗗熀鏈殑璁炬柦銆?/p>

銆銆(3) FC++: The Functional C++ Library

銆銆榪欎釜搴撴彁渚涗簡涓浜涘嚱鏁板紡璇█涓墠鏈夌殑瑕佺礌銆傚睘浜庣敤搴撴潵鎵╁厖璇█鐨勪竴涓唬琛ㄤ綔銆傚鏋滄兂瑕佸湪OOP涔嬪瀵繪壘鍙︿竴鍒嗙殑涔愯叮錛屽彲浠ュ幓鐪嬬湅鍑芥暟寮忕▼搴忚璁$殑涓栫晫銆傚ぇ甯圥eter Norvig鍦?鈥淭each Yourself rogramming in Ten Years鈥濅竴鏂囦腑灝卞皢鍑芥暟寮忚璦鍒椾負鑷沖皯搴斿綋瀛︿範鐨?綾葷紪紼嬭璦涔嬩竴銆?/p>

銆銆(4) FACT!

銆銆鍙傝冪綉绔欙細http://www.kfa-juelich.de/zam/FACT/start/index.html

銆銆鍙﹀涓涓疄鐜板嚱鏁板紡璇█鐗規х殑搴?/p>

銆銆(5) Crypto++

銆銆鎻愪緵澶勭悊瀵嗙爜錛屾秷鎭獙璇侊紝鍗曞悜hash錛屽叕鍖欏姞瀵嗙郴緇熺瓑鍔熻兘鐨勫厤璐瑰簱銆?/p>

銆銆榪樻湁寰堝闈炲父嬋鍔ㄤ漢蹇冩垨鑰呮槸鏋佸叾瀹炵敤鐨凜++搴擄紝闄愪簬鎴戜滑鐨勬按騫充互鍙婃枃绔犵殑綃囧箙涓嶈兘鍖呮嫭榪涙潵銆傚湪瀵逛簬榪欎簺宸茬粡鍖呭惈榪戞潵鐨勫簱鐨勪粙緇嶄腑錛岀敱浜庡茍涓嶆槸姣忎竴涓垜浠兘浣跨敤榪囷紝鎵浠ラ毦鍏嶆湁鍋忛涔嬪錛岃璇昏呰璋呫?/p>

--------------------------------------------------------------------------------

銆銆6錛屼功綾?/p>

銆銆浠ュ墠鐔婅妭鍏堢敓鏇炬挵鏂囪瘎璁虹浉瀵逛簬Java紼嬪簭璁捐璇█錛孋++鐨勫ソ涔﹀濡傜墰姣涖傝崳鑰鍏堢敓鍦ㄣ婄▼搴忓憳銆嬫潅蹇椾笂鎾版枃銆奀++紼嬪簭璁捐涔嬪洓涔︿簲緇忋嬩篃灝嗘湰棰嗗煙鍐呭嚑涔庢墍鏈夌殑緇忓吀涔︾睄浣滀簡鍏ㄩ潰鐨勪粙緇?浠諱綍鍏充簬涔︾殑璇勮姝ゆ椂鐪嬫潵渚挎槸寰堝浣欑殑浜嗐備釜浜烘祬瑙侊紝闄ら潪浣犳墦綆椾互C++浣滀負鍞竴鍏磋叮鎴栬呯敓瀛樹箣鏈紝涓鑸鑰呯‘瀹炴病鏈夎凍澶熺殑鏃墮棿鍜屽繀瑕佸皢20浣欐湰涔︾睄鍏ㄩ儴闃呰銆傛洿鏈夊弬鑰冧環鍊肩殑鏄崳鑰鍏堢敓鐨勫彟涓綃囨枃绔狅細銆婅嚦灝戝簲璇ラ槄
璇葷殑涔濇湰C++钁椾綔銆嬶紝鍙互浠庝笅闈㈢殑鍦板潃嫻忚鍒版鏂囷細

銆銆http://www.royaloo.com/articles/articles_2003/9CppBooks.htm

銆銆涓嬮潰鍑犳湰涔﹀浜庤蛋鍦–++鍒濆涔嬭礬涓婄殑璇昏呮槸鎴戜滑鏈鎰挎剰鎺ㄨ崘緇欏ぇ瀹剁殑錛?/p>

銆銆(1) 銆奀++ Primer銆?/p>

銆銆鍝︼紝涔熻浣犱細鎶辨ㄦ垜浠負浠涔堜笉鍏堜粙緇峊CPL,浣嗗浜庤蛋鍦ㄥ涔犱箣璺笂鐨勫叆闂ㄨ咃紝鏈功鍐呭鏇翠負鍏ㄩ潰錛屾洿涓鴻緇嗘槗鎳傦紝鎴戜滑縐板畠涓衡淐++鐨勮秴綰у疂鍏糕濆茍涓嶈繃鍒嗐傞厤鏈変竴鏈笉閿欑殑涔犻瑙g瓟銆奀++ Primer Answer Book銆嬪彲浠ヨ緟鍔╀綘鐨勫涔犱箣璺?/p>

銆銆(2) 銆奅ssential C++銆?/p>

銆銆濡傛灉璇淬奀++ Primer銆嬫槸C++棰嗗煙鐨勮秴綰у疂鍏革紝閭d箞姝や功浣滀負鎺屾彙C++鐨勫ぇ灞瑙傚綋涔嬫棤鎰с傛濡傘?NET澶у眬瑙傘嬩竴涔﹁兘澶熻璇昏呭叏鎻?NET錛屾湰涔﹁榪頒簡C++涓渶鏍稿績鐨勫叏閮ㄤ富棰樸備功铏戒笉鍘氾紝鍐呭綺劇偧錛屼笉澶變負銆奀++ Primer銆嬭鑰呰尪浣欓キ鍚庣殑涓婚鍥為【涔嬩綔銆?/p>

銆銆(3) 銆奣he C++ Programming Language銆?/p>

銆銆Bjarne涓轟綘甯︽潵鐨凜++鏁欑▼錛岀湡姝h兘澶熷憡璇変綘鎬庝箞鐢ㄦ墠鍙湡姝g殑C++鐨勫敮涓涓鏈功銆傝櫧鐒跺鍚屸滄煇鏌愮▼搴忚璁¤璦鈥濊繖鏍風殑涔︾睄浼氱粰澶у涓涓唴瀹瑰叏鎻斤紝鍏ラ棬鍒扮簿閫氱殑鎰熻錛屼絾鏈功紜疄涓嶅お閫傚悎鍒濆鑰呴槄璇匯傚鏋滀綘鑷涓烘槸涓鍚嶅緢鏈夌粡楠岀殑C++紼嬪簭鍛橈紝閭h嚦灝戜篃瑕佸弽澶嶅拃鍤糂jarne鍏堢敓鎵寮鴻皟鐨勮嫢騫插唴瀹廣?/p>

銆銆(4) 銆奅ffective C++銆嬶紝銆奙ore Effective C++銆?/p>

銆銆鏄殑錛屾濡備竴浜汣++鐖卞ソ鑰呯粡甯鎬互璇昏繃涓庢病鏈夎榪囦笂榪頒袱鏈綔鍝佹潵鍖哄垎浣犳槸鍚︽槸C++楂樻墜銆傛垜浠篃鏋佸姏鎺ㄥ磭榪欎袱鏈憲浣溿傚湪鍚勭浠嬬粛C++涓撳緇忛獙鐨勪功綾嶉噷闈紝榪欎袱鏈槸鏈璐磋繎璇█鏈川錛岀湅鍚庢渶鑳藉鏈夎劚鑳庢崲楠ㄦ劅瑙夌殑涔︼紝璇繪涔︿綘闇姣忔棩涓夌渷姹濊韓銆?/p>

銆銆鎶鏈功綾嶄粊鑰呰浠侊紝榪囧鐨勮瘎璁哄弽鏃犲お澶氭剰涔夛紝鐢辮鑰呭枩濂介夋嫨鏈閫傚悎鑷繁鐨勪功鏂逛負涓婄瓥銆?/p>

--------------------------------------------------------------------------------

銆銆7錛岃祫婧愮綉绔?/p>

銆銆姝e鎴戜滑鍙互閫氳繃璁$畻鏈哄巻鍙蹭笂鐨勯噸瑕佷漢鐗╀簡瑙h綆楁満鍙茬殑鍙戝睍錛孋++鐩稿叧浜虹墿鐨勭綉绔欎篃鍙互浣挎垜浠緱鍒版渶鏈変環鍊肩殑鍙傝冧笌鍊熼壌錛屼笅闈㈢殑浜虹墿鎴戜滑璁や負娌℃湁浠嬬粛鐨勫繀瑕侊紝鍙洜涓嬮潰鐨勪漢鐗╁湪C++棰嗗煙鐨勫湴浣嶄紬鎵鍛ㄧ煡錛屾垜浠彧灝嗙浉鍏崇殑璧勬簮榪涜緗楀垪浠ヤ緵璇昏呭涔狅紝浠栦滑鏈夌殑宸ヤ綔浜庤礉灝斿疄楠屽錛屾湁鐨勫伐浣滀簬鐭ュ悕緙栬瘧鍣ㄥ巶鍟嗭紝鏈夌殑鍦ㄤ笉鏂帹榪涜璦鐨勬爣鍑嗗寲錛屾湁鐨勪負璇昏呮挵鍐欎簡澶氶儴鍗冨彜濂囦綔鈥︹?br />銆銆(1) Bjarne Stroustrup
銆銆http://www.research.att.com/~bs/

銆銆(2) Stanley B. Lippman
銆銆http://blogs.msdn.com/slippman/
銆銆涓枃鐗?http://www.zengyihome.net/slippman/index.htm

銆銆(3) Scott Meyers
銆銆http://www.aristeia.com/

銆銆(4) David Musser
銆銆http://www.cs.rpi.edu/~musser/

銆銆(5) Bruce Eckel
銆銆http://www.bruceeckel.com/

銆銆(6) Nicolai M. Josuttis
銆銆http://www.josuttis.com/

銆銆(7) Herb Sutter
銆銆http://www.gotw.ca/

銆銆(8) Andrei Alexandrescu
銆銆http://www.coderncppdesign.com/

銆銆(9) 渚嵎鍏堢敓
銆銆http://www.jjhou.com/

銆銆(10) 瀛熷博鍏堢敓
銆銆鍏堢敓綣佸繖浜庡伐浣滐紝鐥磋糠浜庢妧鏈紝鏆傛棤涓漢涓婚〉錛屽叧浜庡厛鐢熺殑浣滃搧鍙互閫氳繃CSDN鐨勪笓鏍忓拰渚厛鐢熺殑涓婚〉璁塊棶鍒般?/p>

銆銆(11) 鑽h鍏堢敓
銆銆http://www.royaloo.com/

銆銆(12) 娼樼埍姘戝厛鐢?br />銆銆http://www.icst.pku.edu.cn/panaimin/pam_homepage.htm

銆銆闄や簡涓婅堪澶у笀鐨勪富欏靛錛屼互涓嬬殑緇煎悎綾籆++瀛︿範鍙傝冪珯鐐規槸鎴戜滑闈炲父鎰挎剰鍚戝ぇ瀹舵帹鑽愮殑錛?/p>

銆銆(1) CodeProject
銆銆http://www.codeproject.com/

銆銆(2) CodeGuru
銆銆http://www.codeguru.com/

銆銆(3) Dr. Dobb's Journal
銆銆http://www.ddj.com/

銆銆(4) C/C++ Users Journal
銆銆http://www.cuj.com/

銆銆(5) C緇磋鐐?br />銆銆http://www.c-view.org/

銆銆(6) allaboutprogram
銆銆http://www.allaboutprogram.com/
銆銆鍏朵粬璧勬枡

銆銆(1) ISO IEC JTC1/SC22/WG21 - C++錛氭爣鍑咰++鐨勬潈濞佸弬鑰?br />銆銆http://anubis.dkuug.dk/jtc1/sc22/wg21/

銆銆(2) C++ FAQ LITE 鈥?Frequently Asked Questions: 鏈涓哄叏闈㈢殑C++FAQ
銆銆http://www.sunistudio.com/cppfaq/index.html
銆銆C/C++ 鏂伴椈緇勶細
銆銆浣犱笉濡ㄥ皾璇曚粠榪欓噷鎻愰棶鍜屽洖絳旈棶棰橈紝寰堝涓嶉敊鐨凲&A璧勬簮......

銆銆(1) .alt.comp.lang.learn.c-c++
銆銆榪欎釜綆鍗曚簺錛屽鏋滀綘鍜屾垜涓鏍鋒槸涓彍楦?/p>

銆銆(2) .comp.lang.c++.moderated
聽 鍡紝榪欎釜鏄劇劧姘村鉤楂樹竴浜?/p>

銆銆(3) .comp.std.c++
銆銆濡傛灉浣犻渶瑕佽璁烘爣鍑咰++鐩稿叧璇濋鐨勮瘽

--------------------------------------------------------------------------------

銆銆8錛屼笉寰椾笉鍐欑殑緇撴潫璇?/p>

銆銆緇撴潫鐨勬椂鍊欎篃鏄葷粨鐜扮姸錛屽睍鏈涙湭鏉ョ殑鏃跺欍傝櫧鐒禖++浠庤劚鑳庝簬C寮濮嬶紝涓璺壈闅懼潕鍧風殑璧拌繃鏉ワ紝浣嗘槸鏃犺濡備綍C++宸茬粡鍙栧緱浜嗗伐涓氬熀紜鐨勫湴浣嶃傛枃绔犲垪涓劇殑澶ч噺鐩稿叧璧勬簮灝辨槸鏈濂界殑璇佹槑錛岃屼笟鐣岀殑澶ч噺鐢–++鍐欐垚鐨勪駭鍝佷唬鐮佷互鍙婂ぇ閲忕殑C++鑱屼笟宸ョ▼甯堝垯鏄渶鐩存帴鐨勮瘉鏄庛傚悓鏃訛紝鎴戜滑鍙互鐪嬪埌鍚勪釜楂樻牎鐨勮綆楁満涓撲笟閮藉紑璁炬湁C++榪欓棬璇劇▼錛岀綉緇滀笂瀵逛簬C++鐨勫涔犺璁轟篃浠庢潵閮芥病鏈夊仠榪囥備絾鏄紝鍦↗ava鍜?NET涓ゅぇ浼佷笟寮鍙戝鉤鍙扮殑鍥存敾涓嬶紝緇欎漢鐨勬劅瑙夋槸C++瓚婃潵瓚娾滀笉琛屸濅簡銆?/p>

銆銆C++鍦ㄩ潰鍚戜紒涓氱殑杞歡寮鍙戜腑錛屽湪寮鍙戜究鎹鋒х瓑鏂歸潰鐨勭‘瑕佹瘮Java鍜孋#宸緢澶氾紝鍏朵腑涓涓棶棰樻槸C++璇█鏈韓姣旇緝澶嶆潅錛屽涔犳洸綰挎瘮杈冮櫋宄紝鍙﹀涓涓棶棰樻槸C++鏍囧噯鍖栫殑鏃墮棿澶暱錛屼撫澶變簡寰堝鐨勫.澶ф満浼氾紝鑰楄垂浜嗗緢澶氱簿鍔涘湪鍘傚晢鐨勪箣闂寸殑鏂椾簤涓婏紝鑰孋++鐨勬爣鍑嗗簱紱諱竴涓畬鍠勭殑紼嬪簭寮鍙戞鏋惰繕緙哄皯澶澶鐨勫唴瀹癸紝鍚勪釜絎笁鏂圭殑綾誨簱鍜屾鏋跺張鍦ㄤ竴鑷存у拰瀹屾暣鎬т笂娌℃硶鍜岄殢騫沖彴鎻愪緵鐨勬鏋剁浉鎻愬茍璁恒傞毦閬揅++鐪熺殑瑕侀鍑哄巻鍙茶垶鍙頒簡錛?/p>

銆銆浠嶤++鐩墠鐨勬椿璺冪▼搴︼紝浠ュ強搴旂敤鐜扮姸鏉ヨ鏄畬鍏ㄨ兘澶熻偗瀹欳++浠嶇劧鏄蔣浠跺伐涓氱殑鍩虹錛屼篃涓嶄細閫鍑哄巻鍙茶垶鍙扮殑銆傚彟澶栦粠Boost錛孡oki榪欎簺搴撲腑鎴戜滑涔熻兘澶熺湅鍒癈++鐨勫彂灞曢潪甯告椿璺冿紝瀵逛簬鏂版妧鏈柊鎬濈淮闈炲父嬋榪涳紝C++浠嶇劧騫挎硾鍙楀埌鍏蟲敞銆備粠ACE鍦ㄩ珮鎬ц兘閫氫俊棰嗗煙鐨勫簲鐢紝浠ュ強MTL榪欐牱鐨勫簱鍦ㄦ暟鍊艱綆楅鍩熺殑鍑鴻壊琛ㄧ幇錛屾垜浠彲浠ョ湅鍒癈++鍦ㄩ珮鎬ц兘搴旂敤鍦哄悎涓嬬殑涓嶅彲鏇夸唬鐨勪綔鐢紝鑰屽祵鍏ュ紡緋葷粺榪欐牱鐨勫唴瀛樺彈闄愬紑鍙戝鉤鍙?br />錛屾瘮濡係ymbian OS涓婏紝C++宸茬粡鍙戞尌鐫騫朵笖灝嗗彂鎸ユ洿澶х殑浣滅敤銆傚彲浠ラ瑙佺殑鏄互鍚庣殑杞歡鏃犺涓婂眰鐨勫簲鐢ㄦ庝箞鍙橈紝瀹冪殑搴曞眰鏍稿績閮戒細鏄敱C/C++榪欐牱鐨勭郴緇熺駭杞歡緙栧啓鐨勶紝姣斿Java铏氭嫙鏈猴紝.NET Framwork銆傚洜涓哄彧鏈夎繖鏍風殑緋葷粺綰ц蔣浠舵墠鑳藉畬鍏ㄥ交搴曠殑鍙戞尌鏈哄櫒鐨勫姛鑳姐?/p>

銆銆闇瑕佺湅鍒扮殑鏄袱涓秼鍔匡紝涓涓秼鍔挎槸C++鍙樺緱鏇村姞澶嶆潅錛屾洿鍔犲闄㈡淳錛岄氳繃妯℃澘絳夋湁娼滃姏鐨勮娉曞洜绱犳瀯閫犺秺鏉ヨ秺綺懼閥鐨勫簱鎴愪負浜嗙幇浠++鐨勭儹鐐癸紝铏界劧鍦ㄥ埄鐢ㄥ簱瀹炵幇鏂扮殑緙栫▼鑼冨紡錛屼箖鑷寵璁℃ā寮忕瓑鏂歸潰寰堟湁寮鍒涙剰涔夛紝涔熺‘瀹炰駭鐢熶簡涓浜涜兘澶熶究鎹峰紑鍙戠殑宸ュ叿錛屼絾鏄洿澶氱殑鏄妸C++鍙樺緱鏇村姞寮哄ぇ錛屾洿鍔犲鏉傦紝涔熸洿鍔犻毦鎳傦紝浼間箮涔熸洿鍔犲闄㈡淳錛屼笉寰椾笉璇村畠姝e湪鍚戣竟緙樺寲閬撹礬鍙戝睍銆傚彟涓涓秼鍔挎槸C++鍦ㄤ富嫻佺殑浼佷笟搴旂敤寮
鍙戜腑宸茬粡閫愭笎閫鍑轟簡錛孍RP榪欐牱鐨勪紒涓氳蔣浠跺紑鍙戜腑鍩烘湰涓婁笉浼氳冭檻C++錛岄櫎闈為渶瑕佽冭檻鎬ц兘鎴栬呭拰閬楃暀浠g爜鐨勯泦鎴愯繖浜涘洜绱犮侰++閫瀹堝埌緋葷粺綰у埆璇█錛屾垚涓鴻蔣浠跺伐涓氱殑鍩虹鏄ぇ鍔挎墍瓚嬨傜劧鑰屽弽鎬濅竴涓嬶紝鐪熺殑鏄瀹堜箞錛熻嚜浠嶴TL鍑虹幇錛屾棤鏁扮殑浜洪璧蜂簯娑岀殑寮濮嬫敮鎸丆++,浠栦滑鐙傚懠鈥滄垜鐪嬪埌娣卞娑堝け浜嗭紝鐩爣杞歡宸ョ▼鐨勫嚭鐜般傛垜鐪嬪埌浜嗗彲緇存姢鐨勪唬鐮併傗濇槸鐨勶紝STL鍦ㄥ彲緇存姢鎬т笅鍋氬緱濡傛鍑鴻壊銆備絾鏄張鎬庢牱鍛紵STL涓篊++閾哄鉤浜嗙幇浠h蔣浠跺伐紼嬬殑閬撹礬錛岃屽湪涓婂眰搴旂敤紼嬪簭杞歡寮鍙戦鍩熻繖鍧楀満鍦版棭涓嶅崟鐙睘浜嶤++,寰堝紼嬪簭璁捐璇█閮藉仛寰楀緢鍑鴻壊錛岀柉鐙傜殑鏀寔鑰呬細姣笉鐘硅鮑鍦拌鎴戜滑搴斿綋鏀寔C++,鍥犱負瀹冩槸涓栫晫涓婃渶媯掔殑璇█銆傝屽潶鐜囧湴璇達紝浣犵殑鑵版潌鐪熺殑閭d箞紜箞錛熶篃璁稿彧鏄湪閫冮伩涓浜涗簨瀹炪侰++鏄紭縐鐨勶紝榪欎笉鍙惁璁わ紝STL鐨勫嚭鐜拌C++涓搴﹁蛋涓婁簡鏈杈夌厡鐨勬椂鍒伙紝鐒惰岀幇鍦ㄧ湅鏉モ︹︽垜鐨勪竴浣嶆仼甯堟浘璦錛氱湡姝h兘澶熷皢STL搴旂敤寰楁穻婕撳敖鑷寸殑浜哄緢
淇濆畧鍦拌鍥藉唴涔熶笉瓚呰繃200浜猴紝鎴栬涓嶅姞鍏TL鑳藉浣緾++鍚戠潃瀹冨簲褰撳彂灞曠殑鏂瑰悜鍙戝睍鐨勬洿濂斤紝鑰岀幇鍦ㄧ湅鏉ワ紝C++涔熷簲褰撳洖棣栧埌鐪熸灞炰簬浠栫殑閭d竴鐗囧湥鍦頒笂鈥︹?/p>

鏉? 2007-02-05 10:07 鍙戣〃璇勮
]]>
C++ 綾誨簱http://www.shnenglu.com/eday/archive/2007/01/20/17805.html鏉?鏉?Fri, 19 Jan 2007 18:58:00 GMThttp://www.shnenglu.com/eday/archive/2007/01/20/17805.html鍐嶆浣撶幇浜咰++淇濇寔鏍稿績璇█鐨勬晥鐜囧悓鏃跺ぇ鍔涘彂灞曞簲鐢ㄥ簱鐨勫彂灞曡秼鍔?!鍦–++涓紝搴撶殑鍦頒綅鏄潪甯擱珮鐨勩侰++涔嬬埗聽Bjarne聽Stroustrup鍏堢敓澶氭琛ㄧず浜嗚璁″簱鏉ユ墿鍏呭姛鑳借濂借繃璁捐鏇村鐨勮娉曠殑璦璁恒傜幇瀹炰腑錛孋++鐨勫簱闂ㄧ被綣佸錛岃В鍐崇殑闂涔熸槸鏋佸叾騫挎硾錛屽簱浠庤交閲忕駭鍒伴噸閲忕駭鐨勯兘鏈夈備笉灝戦兘鏄浜虹溂鐣屽ぇ寮錛屼害鎴栨槸鏈涜岀敓鍙圭殑鎬濈淮鏉頒綔銆傜敱浜庡簱鐨勬暟閲忛潪甯稿簽澶э紝鑰屼笖闄愪簬絎旇呮按騫籌紝鍏朵腑寰堝騫朵笉浜嗚В銆傛墍浠ユ枃涓墍鎻愮殑涓浜涘簱閮芥槸姣旇緝钁楀悕鐨勫ぇ鍨嬪簱銆偮?br />
鏍囧噯搴撀?br />
鏍囧噯搴撲腑鎻愪緵浜咰++紼嬪簭鐨勫熀鏈鏂姐傝櫧鐒禖++鏍囧噯搴撻殢鐫C++鏍囧噯鎶樿吘浜嗚澶氬勾錛岀洿鍒版爣鍑嗙殑鍑哄彴鎵嶆寮忓畾鍨嬶紝浣嗘槸鍦ㄦ爣鍑嗗簱鐨勫疄鐜頒笂鍗村緢浠や漢嬈f叞寰楃湅鍒板縐嶅疄鐜幫紝騫朵笖宸茶瀹炶返璇佹槑涓烘湁宸ヤ笟綰у埆寮哄害鐨勪匠浣溿偮?br />
1銆伮燚inkumware聽C++聽Library聽

鍙傝冪珯鐐癸細http://www.dinkumware.com/'>http://www.dinkumware.com/

P.J.聽Plauger緙栧啓鐨勯珮鍝佽川鐨勬爣鍑嗗簱銆侾.J.聽Plauger鍗氬+鏄疍r.聽Dobb's紼嬪簭璁捐鏉板嚭濂栫殑鑾峰緱鑰呫傚叾緙栧啓鐨勫簱闀挎湡琚玀icrosoft閲囩敤錛屽茍涓旀渶榪態orland涔熷彇寰椾簡鍏禣EM鐨刲icense錛屽湪鍏禖/C+聽+鐨勪駭鍝佷腑閲囩敤Dinkumware鐨勫簱銆偮?br />
2銆伮燫ogueWave聽Standard聽C++聽Library聽

鍙傝冪珯鐐癸細http://www.roguewave.com/'>http://www.roguewave.com/'>http://www.roguewave.com/'>http://www.roguewave.com/

榪欎釜搴撳湪Borland聽C++聽Builder鐨勬棭鏈熺増鏈腑鏇劇粡琚噰鐢紝鍚庢潵琚叾浠栫殑搴撶粰鏇挎崲浜嗐傜瑪鑰呬笉鎺ㄨ崘浣跨敤銆偮?br />
3銆丼GI聽STL聽

鍙傝冪珯鐐癸細http://www.roguewave.com/'>http://www.roguewave.com/'>http://www.roguewave.com/'>http://www.roguewave.com/

SGI鍏徃鐨凜++鏍囧噯妯$増搴撱偮?br />
4銆丼TLport聽

鍙傝冪珯鐐癸細http://www.stlport.org/'>http://www.stlport.org/

SGI聽STL搴撶殑璺ㄥ鉤鍙板彲縐繪鐗堟湰銆偮?br />


鍑嗘爣鍑嗗簱鈥斺擝oost聽

Boost聽搴撴槸涓涓粡榪囧崈閿ょ櫨鐐箋佸彲縐繪銆佹彁渚涙簮浠g爜鐨凜++搴擄紝浣滀負鏍囧噯搴撶殑鍚庡錛屾槸C++鏍囧噯鍖栬繘紼嬬殑鍙戝姩鏈轟箣涓銆偮燘oost搴撶敱C++鏍囧噯濮斿憳浼氬簱宸ヤ綔緇勬垚鍛樺彂璧鳳紝鍦–++紺懼尯涓獎鍝嶇敋澶э紝鍏舵垚鍛樺凡榪?000浜恒偮燘oost搴撲負鎴戜滑甯︽潵浜嗘渶鏂般佹渶閰楓佹渶瀹炵敤鐨勬妧鏈紝鏄笉鎶樹笉鎵g殑"鍑?鏍囧噯搴撱偮?br />
Boost涓瘮杈冩湁鍚嶆皵鐨勬湁榪欎箞鍑犱釜搴擄細聽

Regex聽
姝e垯琛ㄨ揪寮忓簱聽

Spirit聽
LL聽parser聽framework錛岀敤C++浠g爜鐩存帴琛ㄨ揪EBNF聽

Graph聽
鍥劇粍浠跺拰綆楁硶聽

Lambda聽
鍦ㄨ皟鐢ㄧ殑鍦版柟瀹氫箟鐭皬鍖垮悕鐨勫嚱鏁板璞★紝寰堝疄鐢ㄧ殑functional鍔熻兘聽

concept聽check聽
媯鏌ユ硾鍨嬬紪紼嬩腑鐨刢oncept聽

Mpl聽
鐢ㄦā鏉垮疄鐜扮殑鍏冪紪紼嬫鏋堵?br />
Thread聽
鍙Щ妞嶇殑C++澶氱嚎紼嬪簱聽

Python聽
鎶奀++綾誨拰鍑芥暟鏄犲皠鍒癙ython涔嬩腑聽

Pool聽
鍐呭瓨姹犵鐞喡?br />
smart_ptr聽
5涓櫤鑳芥寚閽堬紝瀛︿範鏅鴻兘鎸囬拡蹇呰錛屼竴浠戒笉閿欑殑鍙傝冩槸鏉ヨ嚜CUJ鐨勬枃绔狅細聽

Smart聽Pointers聽in聽Boost,鍝︼紝榪欑瘒鏂囩珷鍙互鏌ュ埌錛孋UJ鏄彁渚涘湪綰挎祻瑙堢殑銆備腑鏂囩増瑙佺瑪鑰呭湪銆奃r.聽Dobb's聽Journal杞歡鐮斿彂鏉傚織銆嬬7杈戜笂鐨勮瘧鏂囥偮?br />

Boost聽鎬諱綋鏉ヨ鏄疄鐢ㄤ環鍊煎緢楂橈紝璐ㄩ噺寰堥珮鐨勫簱銆傚茍涓旂敱浜庡叾瀵硅法騫沖彴鐨勫己璋冿紝瀵規爣鍑咰++鐨勫己璋冿紝鏄紪鍐欏鉤鍙版棤鍏籌紝鐜頒唬C++鐨勫紑鍙戣呭繀澶囩殑宸ュ叿銆備絾鏄疊oost聽涓篃鏈夊緢澶氭槸瀹為獙鎬ц川鐨勪笢瑗匡紝鍦ㄥ疄闄呯殑寮鍙戜腑瀹炵敤闇瑕佽皚鎱庛傚茍涓斿緢澶欱oost涓殑搴撳姛鑳藉牚縐板璇█鍔熻兘鐨勬墿灞曪紝鍏舵瀯閫犵敤灝界簿宸х殑鎵嬫硶錛屼笉瑕佽錘鐒剁殑鑺辮垂鏃墮棿鐮旇銆侭oost鍙﹀涓闈紝姣斿Graph榪欐牱鐨勫簱鍒欐槸鍏鋒湁宸ヤ笟寮哄害錛岀粨鏋勮壇濂斤紝闈炲父鍊煎緱鐮旇鐨勭簿鍝佷唬鐮侊紝騫朵笖涔熷彲浠ユ斁蹇冪殑鍦ㄤ駭鍝佷唬鐮佷腑澶氬鍒╃敤銆偮?br />
鍙傝冪珯鐐癸細http://www.boost.org'>http://www.boost.org錛堝浗鍐呴暅鍍忥細http://www.c'>聽http://www.c'>http://www.c'>http://www.c-view.org/tech/lib/boost/index.htm錛壜?br />
GUI聽

鍦ㄤ紬澶欳++鐨勫簱涓紝GUI閮ㄥ垎鐨勫簱綆楁槸姣旇緝綣佽崳錛屼篃姣旇緝寮曚漢娉ㄧ洰鐨勩傚湪瀹為檯寮鍙戜腑錛孏UI搴撶殑閫夋嫨涔熸槸闈炲父閲嶈鐨勪竴浠朵簨鎯咃紝涓嬮潰鎴戜滑緇艱堪涓涓嬪彲閫夋嫨鐨凣UI搴擄紝鍚勮嚜鐨勭壒鐐逛互鍙婄浉鍏沖伐鍏風殑鏀寔銆偮?br />
1銆伮燤FC聽

澶у悕榧庨紟鐨勫井杞熀紜綾誨簱錛圡icrosoft聽Foundation聽Class錛夈傚ぇ鍑″榪嘨C++鐨勪漢閮藉簲璇ョ煡閬撹繖涓簱銆傝櫧鐒朵粠鎶鏈搴﹁錛孧FC鏄笉澶ф紓浜殑錛屼絾鏄畠鏋勫緩浜嶹indows聽API聽涔嬩笂錛岃兘澶熶嬌紼嬪簭鍛樼殑宸ヤ綔鏇村鏄?緙栫▼鏁堢巼楂橈紝鍑忓皯浜嗗ぇ閲忓湪寤虹珛聽Windows聽紼嬪簭鏃跺繀欏葷紪鍐欑殑浠g爜錛屽悓鏃跺畠榪樻彁渚涗簡鎵鏈変竴鑸燙++聽緙栫▼鐨勪紭鐐癸紝渚嬪緇ф壙鍜屽皝瑁呫侻FC聽緙栧啓鐨勭▼搴忓湪鍚勪釜鐗堟湰鐨刉indows鎿嶄綔緋葷粺涓婃槸鍙Щ妞嶇殑錛屼緥濡傦紝鍦燱indows聽3.1涓嬬紪鍐欑殑浠g爜鍙互寰堝鏄撳湴縐繪鍒奧燱indows聽NT聽鎴柭燱indows聽95聽涓娿備絾鏄湪鏈榪戝彂灞曚互鍙婂畼鏂規敮鎸佷笂鏃ユ笎鍔垮井銆偮?br />


2銆伮燪T聽

鍙傝冪綉绔欙細http://www.trolltech.com/'>http://www.trolltech.com/

Qt聽鏄疶rolltech鍏徃鐨勪竴涓騫沖彴鐨凜++鍥懼艦鐢ㄦ埛鐣岄潰搴旂敤紼嬪簭妗嗘灦銆傚畠鎻愪緵緇欏簲鐢ㄧ▼搴忓紑鍙戣呭緩绔嬭壓鏈駭鐨勫浘褰㈢敤鎴風晫闈㈡墍闇鐨勬墍鐢ㄥ姛鑳姐俀t鏄畬鍏ㄩ潰鍚戝璞$殑寰堝鏄撴墿灞曪紝騫朵笖鍏佽鐪熸鍦扮粍浠剁紪紼嬨傝嚜浠?996騫存棭浜涙椂鍊欙紝Qt榪涘叆鍟嗕笟棰嗗煙錛屽畠宸茬粡鎴愪負鍏ㄤ笘鐣岃寖鍥村唴鏁板崈縐嶆垚鍔熺殑搴旂敤紼嬪簭鐨勫熀紜銆俀t涔熸槸嫻佽鐨凩inux妗岄潰鐜KDE聽鐨勫熀紜錛屽悓鏃跺畠榪樻敮鎸乄indows銆丮acintosh銆乁nix/X11絳夊縐嶅鉤鍙般偮?br />


3銆乄xWindows聽

鍙傝冪綉绔欙細http://www.wxwindows.org/'>http://www.wxwindows.org/

璺ㄥ鉤鍙扮殑GUI搴撱傚洜涓哄叾綾誨眰嬈℃瀬鍍廙FC錛屾墍浠ユ湁鏂囩珷浠嬬粛浠嶮FC鍒癢xWindows鐨勪唬鐮佺Щ妞嶄互瀹炵幇璺ㄥ鉤鍙扮殑鍔熻兘銆傞氳繃澶氬勾鐨勫紑鍙戜篃鏄竴涓棩瓚嬪畬鍠勭殑聽GUI搴擄紝鏀寔鍚屾牱涓嶅急浜庡墠闈袱涓簱銆傚茍涓旀槸瀹屽叏寮鏀炬簮浠g爜鐨勩傛柊榪戠殑C++聽Builder聽X鐨凣UI璁捐鍣ㄥ氨鏄熀浜庤繖涓簱鐨勩偮?br />
4銆丗ox聽

寮鏀炬簮浠g爜鐨凣UI搴撱備綔鑰呬粠鑷繁浜茶韓鐨勫紑鍙戠粡楠屼腑寰楀嚭浜嗕竴涓悊鎯崇殑GUI搴撳簲璇ユ槸浠涔堟牱瀛愮殑鎰熷彈鍑哄彂錛屼粠鑰屽紑濮嬩簡瀵硅繖涓簱鐨勫紑鍙戙傛湁鍏磋叮鐨勫彲浠ュ皾璇曚竴涓嬨偮?br />
鍙傝冪綉绔欙細http://www.fox'>http://www.fox-toolkit.org/

5銆伮燱TL聽

鍩轟簬ATL鐨勪竴涓簱銆傚洜涓轟嬌鐢ㄤ簡澶ч噺ATL鐨勮交閲忕駭鎵嬫硶錛屾ā鏉跨瓑鎶鏈紝鍦ㄤ唬鐮佸昂瀵革紝浠ュ強閫熷害浼樺寲鏂歸潰鍋氬緱闈炲父鍒頒綅銆備富瑕侀潰鍚戠殑浣跨敤緹や綋鏄紑鍙慍OM杞婚噺綰т緵緗戠粶涓嬭澆鐨勫彲瑙嗗寲鎺т歡鐨勫紑鍙戣呫偮?br />
6銆伮燝TK聽

鍙傝冪綉绔欙細http://gtkmm.sourceforge.net/

GTK鏄竴涓ぇ鍚嶉紟榧庣殑C鐨勫紑婧怗UI搴撱傚湪Linux涓栫晫涓湁Gnome榪欐牱鐨勬潃鎵嬪簲鐢ㄣ傝孏TK灝辨槸榪欎釜搴撶殑C++灝佽鐗堟湰銆偮?br />
?聽

搴撀?br />

緗戠粶閫氫俊聽

ACE聽

鍙傝冪綉绔欙細http://www.c'>http://www.c'>http://www.c'>http://www.cs.wustl.edu/~schmidt/ACE.html

C+聽+搴撶殑浠h〃錛岃秴閲嶉噺綰х殑緗戠粶閫氫俊寮鍙戞鏋躲侫CE鑷傞厤閫氫俊鐜錛圓daptive聽Communication聽Environment錛夋槸鍙互鑷敱浣跨敤銆佸紑鏀炬簮浠g爜鐨勯潰鍚戝璞℃鏋訛紝鍦ㄥ叾涓疄鐜頒簡璁稿鐢ㄤ簬騫跺彂閫氫俊杞歡鐨勬牳蹇冩ā寮忋侫CE鎻愪緵浜嗕竴緇勪赴瀵岀殑鍙鐢–++聽鍖呰澶栬錛圵rapper聽Facade錛夊拰妗嗘灦緇勪歡錛屽彲璺ㄨ秺澶氱騫沖彴瀹屾垚閫氱敤鐨勯氫俊杞歡浠誨姟錛屽叾涓寘鎷細浜嬩歡澶氳礬鍒嗙鍜屼簨浠跺鐞嗗櫒鍒嗘淳銆佷俊鍙峰鐞嗐佹湇鍔″垵濮嬪寲銆佽繘紼嬮棿閫氫俊銆佸叡浜唴瀛樼鐞嗐佹秷鎭礬鐢便佸垎甯冨紡鏈嶅姟鍔ㄦ侊紙閲嶏級閰嶇疆銆佸茍鍙戞墽琛屽拰鍚屾錛岀瓑絳夈偮?br />
StreamModule聽

鍙傝冪綉绔欙細http://www.omnifarious.org/StrMod/'>http://www.omnifarious.org/StrMod/

璁捐鐢ㄤ簬綆鍖栫紪鍐欏垎甯冨紡紼嬪簭鐨勫簱銆傚皾璇曠潃浣垮緱緙栧啓澶勭悊寮傛琛屼負鐨勭▼搴忔洿瀹規槗錛岃屼笉鏄敤鍚屾鐨勫澹沖寘璧峰紓姝ョ殑鏈川銆偮?br />
SimpleSocket聽

鍙傝冪綉绔欙細http://home.hetnet.nl/~lcbokkers/simsock.htm

榪欎釜綾誨簱璁╃紪鍐欏熀浜巗ocket鐨勫鎴?鏈嶅姟鍣ㄧ▼搴忔洿鍔犲鏄撱偮?br />
A聽Stream聽Socket聽API聽for聽C++聽

鍙傝冪綉绔欙細http://www.pcs.cnu.edu/'>http://www.pcs.cnu.edu/~dgame/sockets/socketsC++/sockets.html

鍙堜竴涓Socket鐨勫皝瑁呭簱銆偮?br />
XML聽

Xerces聽

鍙傝冪綉绔欙細http://xml.apache.org/xerces-c/

Xerces-C++聽鏄竴涓潪甯稿仴澹殑XML瑙f瀽鍣紝瀹冩彁渚涗簡楠岃瘉錛屼互鍙奡AX鍜孌OM聽API銆俋ML楠岃瘉鍦ㄦ枃妗g被鍨嬪畾涔?Document聽Type聽Definition錛孌TD)鏂歸潰鏈夊緢濂界殑鏀寔錛屽茍涓斿湪2001騫?2鏈堝鍔犱簡鏀寔W3C聽XML聽Schema聽鐨勫熀鏈畬鏁寸殑寮鏀炬爣鍑嗐偮?br />
XMLBooster聽

鍙傝冪綉绔欙細http://www.xmlbooster.com/'>http://www.xmlbooster.com/

榪欎釜搴撻氳繃浜х敓鐗瑰埗鐨刾arser鐨勫姙娉曟瀬澶х殑鎻愰珮浜哫ML瑙f瀽鐨勯熷害錛屽茍涓旇兘澶熶駭鐢熺浉搴旂殑GUI紼嬪簭鏉ヤ慨鏀硅繖涓猵arser銆傚湪DOM鍜孲AX涓ゅぇ涓繪祦XML瑙f瀽鍔炴硶涔嬪鎻愪緵浜嗗彟澶栦竴涓彲琛岀殑瑙e喅鏂規銆偮?br />
Pull聽Parser聽

鍙傝冪綉绔欙細http://www.extreme.indiana.edu/xgws/xsoap/xpp/'>http://www.extreme.indiana.edu/xgws/xsoap/xpp/

榪欎釜搴撻噰鐢╬ull鏂規硶鐨刾arser銆傚湪姣忎釜SAX鐨刾arser搴曞眰閮芥湁涓涓猵ull鐨刾arser錛岃繖涓獂pp鎶婅繖灞傛毚闇插嚭鏉ョ洿鎺ョ粰澶у浣跨敤銆傚湪瑕佸厖鍒嗚冭檻閫熷害鐨勬椂鍊欏煎緱灝濊瘯銆偮?br />
Xalan聽

鍙傝冪綉绔欙細http://xml.apache.org/xalan-c/

Xalan鏄竴涓敤浜庢妸XML鏂囨。杞崲涓篐TML錛岀函鏂囨湰鎴栬呭叾浠朮ML綾誨瀷鏂囨。鐨刋SLT澶勭悊鍣ㄣ偮?br />
CMarkup聽

鍙傝冪綉绔欙細http://www.firstobject.com/xml.htm'>http://www.firstobject.com/xml.htm

榪欐槸涓縐嶄嬌鐢‥DOM鐨刋ML瑙f瀽鍣ㄣ傚湪寰堝鎬濊礬涓婇潰闈炲父鐏墊椿瀹炵敤銆傚煎緱澶у鍦―OM鍜孲AX涔嬪瀵繪眰涓鐐圭伒鎰熴偮?br />
libxml++聽

http://libxmlplusplus.sourceforge.net/

libxml++鏄钁楀悕鐨刲ibxml聽XML瑙f瀽鍣ㄧ殑C++灝佽鐗堟湰聽



縐戝璁$畻聽

Blitz++聽

鍙傝冪綉绔欙細http://www.oonumerics.org/blitz/'>http://www.oonumerics.org/blitz/

Blitz++聽鏄竴涓珮鏁堢巼鐨勬暟鍊艱綆楀嚱鏁板簱錛屽畠鐨勮璁$洰鐨勬槸甯屾湜寤虹珛涓濂楁棦鍏峰儚C++聽涓鏍鋒柟渚匡紝鍚屾椂鍙堟瘮Fortran閫熷害鏇村揩鐨勬暟鍊艱綆楃幆澧冦傞氬父錛岀敤C++鎵鍐欏嚭鐨勬暟鍊肩▼搴忥紝姣斅燜ortran鎱?0%宸﹀彸錛屽洜姝litz++姝f槸瑕佹敼鎺夎繖涓己鐐廣傛柟娉曟槸鍒╃敤C++鐨則emplate鎶鏈紝紼嬪簭鎵ц鐢氳嚦鍙互姣擣ortran鏇村揩銆偮燘litz++鐩墠浠嶅湪鍙戝睍涓紝瀵逛簬甯歌鐨凷VD錛孎FTs錛孮MRES絳夊父瑙佺殑綰挎т唬鏁版柟娉曞茍涓嶆彁渚涳紝涓嶈繃浣跨敤鑰呭彲浠ュ緢瀹規槗鍦板埄鐢˙litz++鎵鎻愪緵鐨勫嚱鏁版潵鏋勫緩銆偮?br />
POOMA聽

鍙傝冪綉绔欙細http://www.c'>http://www.c'>http://www.c'>http://www.codesourcery.com/pooma/pooma

POOMA鏄竴涓厤璐圭殑楂樻ц兘鐨凜++搴擄紝鐢ㄤ簬澶勭悊騫惰寮忕瀛﹁綆椼侾OOMA鐨勯潰鍚戝璞¤璁℃柟渚夸簡蹇熺殑紼嬪簭寮鍙戯紝瀵瑰茍琛屾満鍣ㄨ繘琛屼簡浼樺寲浠ヨ揪鍒版渶楂樼殑鏁堢巼錛屾柟渚垮湪宸ヤ笟鍜岀爺絀剁幆澧冧腑浣跨敤銆偮?br />
MTL聽

鍙傝冪綉绔欙細http://www.osl.iu.edu/research/mtl/'>http://www.osl.iu.edu/research/mtl/

Matrix聽Template聽Library(MTL)鏄竴涓珮鎬ц兘鐨勬硾鍨嬬粍浠跺簱錛屾彁渚涗簡鍚勭鏍煎紡鐭╅樀鐨勫ぇ閲忕嚎鎬т唬鏁版柟闈㈢殑鍔熻兘銆傚湪鏌愪簺搴旂敤浣跨敤楂樻ц兘緙栬瘧鍣ㄧ殑鎯呭喌涓嬶紝姣斿Intel鐨勭紪璇戝櫒錛屼粠浜х敓鐨勬眹緙栦唬鐮佸彲浠ョ湅鍑哄叾涓庢墜鍐欏嚑涔庢病鏈変袱鏍風殑鏁堣兘銆偮?br />
CGAL聽

鍙傝冪綉绔欙細www.cgal.org

Computational聽Geometry聽Algorithms聽Library鐨勭洰鐨勬槸鎶婂湪璁$畻鍑犱綍鏂歸潰鐨勫ぇ閮ㄥ垎閲嶈鐨勮В鍐蟲柟妗堝拰鏂規硶浠++搴撶殑褰㈠紡鎻愪緵緇欏伐涓氬拰瀛︽湳鐣岀殑鐢ㄦ埛銆偮?br />


娓告垙寮鍙懧?br />
Audio/Video聽3D聽C++聽Programming聽Library聽

鍙傝冪綉绔欙細http://www.galacticasoftware.com/products/av/'>http://www.galacticasoftware.com/products/av/

AV3D鏄竴涓法騫沖彴錛岄珮鎬ц兘鐨凜++搴撱備富瑕佺殑鐗規ф槸鎻愪緵3D鍥懼艦錛屽0鏁堟敮鎸侊紙SB,浠ュ強S3M錛夛紝鎺у埗鎺ュ彛錛堥敭鐩橈紝榧犳爣鍜岄仴鎰燂級錛孹MS銆偮?br />
KlayGE聽

鍙傝冪綉绔欙細http://home.g365.net/enginedev/

鍥藉唴娓告垙寮鍙戦珮鎵嬭嚜宸辯敤C++寮鍙戠殑娓告垙寮曟搸銆侹layGE鏄竴涓紑鏀炬簮浠g爜銆佽法騫沖彴鐨勬父鎴忓紩鎿庯紝騫朵嬌鐢≒ython浣滆剼鏈璦銆侹layGE鍦↙GPL鍗忚涓嬪彂琛屻傛劅璋㈤練鏁忔晱鍏堢敓涓轟腑鍥芥父鎴忓紑鍙戜簨涓氭墍鍋氬嚭鐨勮礎鐚偮?br />
OGRE聽

鍙傝冪綉绔欙細http://www.ogre3d.org'>http://www.ogre3d.org

OGRE聽錛堥潰鍚戝璞$殑鍥懼艦娓叉煋寮曟搸錛夋槸鐢–++寮鍙戠殑錛屼嬌鐢ㄧ伒媧葷殑闈㈠悜瀵硅薄3D寮曟搸銆傚畠鐨勭洰鐨勬槸璁╁紑鍙戣呰兘鏇存柟渚垮拰鐩存帴鍦板紑鍙戝熀浜?D紜歡璁懼鐨勫簲鐢ㄧ▼搴忔垨娓告垙銆傚紩鎿庝腑鐨勭被搴撳鏇村簳灞傜殑緋葷粺搴擄紙濡傦細Direct3D鍜孫penGL錛夌殑鍏ㄩ儴浣跨敤緇嗚妭榪涜浜嗘娊璞★紝騫舵彁渚涗簡鍩轟簬鐜板疄涓栫晫瀵硅薄鐨勬帴鍙e拰鍏跺畠綾匯偮?br />


綰跨▼聽

C++聽Threads聽

鍙傝冪綉绔欙細http://threads.sourceforge.net/

榪欎釜搴撶殑鐩爣鏄粰紼嬪簭鍛樻彁渚涙槗浜庝嬌鐢ㄧ殑綾伙紝榪欎簺綾昏緇ф壙浠ユ彁渚涘湪Linux鐜涓緢闅劇湅鍒扮殑澶ч噺鐨勭嚎紼嬫柟闈㈢殑鍔熻兘銆偮?br />
ZThreads聽

鍙傝冪綉绔欙細http://zthread.sourceforge.net/

涓涓厛榪涚殑闈㈠悜瀵硅薄錛岃法騫沖彴鐨凜++綰跨▼鍜屽悓姝ュ簱銆偮?br />


搴忓垪鍖柭?br />
s11n聽

鍙傝冪綉绔欙細http://s11n.net/

涓涓熀浜嶴TL鐨凜++搴擄紝鐢ㄤ簬搴忓垪鍖朠OD錛孲TL瀹瑰櫒浠ュ強鐢ㄦ埛瀹氫箟鐨勭被鍨嬨偮?br />
Simple聽XML聽Persistence聽Library聽

鍙傝冪綉绔欙細http://sxp.sourceforge.net/

榪欐槸涓涓妸瀵硅薄搴忓垪鍖栦負XML鐨勮交閲忕駭鐨凜++搴撱偮?br />


瀛楃涓猜?br />
C++聽Str聽Library聽

鍙傝冪綉绔欙細http://www.utilitycode.com/str/'>http://www.utilitycode.com/str/

鎿嶄綔瀛楃涓插拰瀛楃鐨勫簱錛屾敮鎸乄indows鍜屾敮鎸乬cc鐨勫縐嶅鉤鍙般傛彁渚涢珮搴︿紭鍖栫殑浠g爜錛屽茍涓旀敮鎸佸綰跨▼鐜鍜孶nicode錛屽悓鏃惰繕鏈夋鍒欒〃杈懼紡鐨勬敮鎸併偮?br />
Common聽Text聽Transformation聽Library聽

鍙傝冪綉绔欙細http://cttl.sourceforge.net/

榪欐槸涓涓В鏋愬拰淇敼STL瀛楃涓茬殑搴撱侰TTL聽substring綾誨彲浠ョ敤鏉ユ瘮杈冿紝鎻掑叆錛屾浛鎹互鍙婄敤EBNF鐨勮娉曡繘琛岃В鏋愩偮?br />
GRETA聽

鍙傝冪綉绔欙細http://research.microsoft.com/projects/greta/

榪欐槸鐢卞井杞爺絀墮櫌鐨勭爺絀朵漢鍛樺紑鍙戠殑澶勭悊姝e垯琛ㄨ揪寮忕殑搴撱傚湪灝忓瀷鍖歸厤鐨勬儏鍐典笅鏈夐潪甯鎬紭縐鐨勮〃鐜般偮?br />
緇煎悎聽

P::Classes聽

鍙傝冪綉绔欙細http://pclasses.com/

涓涓珮搴﹀彲縐繪鐨凜++搴旂敤紼嬪簭妗嗘灦銆傚綋鍓嶅叧娉ㄧ被鍨嬪拰綰跨▼瀹夊叏鐨剆ignal/slot鏈哄埗錛宨/o緋葷粺鍖呮嫭鍩轟簬鎻掍歡鐨勭綉緇滃崗璁忔槑鐨刬/o鏋舵瀯錛屽熀浜庢彃浠剁殑搴旂敤紼嬪簭娑堟伅鏃ュ織妗嗘灦錛岃闂畇ql鏁版嵁搴撶殑綾葷瓑絳夈偮?br />
ACDK聽-聽Artefaktur聽Component聽Development聽Kit聽

鍙傝冪綉绔欙細http://acdk.sourceforge.net/

榪欐槸涓涓鉤鍙版棤鍏崇殑C++緇勪歡妗嗘灦錛岀被浼間簬Java鎴栬?NET涓殑妗嗘灦錛堝弽灝勬満鍒訛紝綰跨▼錛孶nicode錛屽簾鏂欐敹闆嗭紝I/O錛岀綉緇滐紝瀹炵敤宸ュ叿錛孹ML錛岀瓑絳夛級錛屼互鍙婂Java,聽Perl,聽Python,聽TCL,聽Lisp,聽COM聽鍜屄燙ORBA鐨勯泦鎴愩偮?br />
dlib聽C++聽library聽

鍙傝冪綉绔欙細http://www.c'>http://www.c'>http://www.c'>http://www.cis.ohio-state.edu/~kingd/dlib/

鍚勭鍚勬牱鐨勭被鐨勪竴涓患鍚堛傚ぇ鏁存暟錛孲ocket錛岀嚎紼嬶紝GUI錛屽鍣ㄧ被,浠ュ強嫻忚鐩綍鐨凙PI絳夌瓑銆偮?br />
Chilkat聽C++聽Libraries聽

鍙傝冪綉绔欙細http://www.c'>http://www.c'>http://www.c'>http://www.chilkatsoft.com/cpp_libraries.asp

榪欐槸鎻愪緵zip錛宔-mail錛岀紪鐮侊紝S/MIME錛孹ML絳夋柟闈㈢殑搴撱偮?br />
C++聽Portable聽Types聽Library聽(PTypes)聽

鍙傝冪綉绔欙細http://www.melikyan.com/ptypes/'>http://www.melikyan.com/ptypes/

榪欐槸STL鐨勬瘮杈冪畝鍗曠殑鏇夸唬鍝侊紝浠ュ強鍙Щ妞嶇殑澶氱嚎紼嬪拰緗戠粶搴撱偮?br />
LFC聽

鍙傝冪綉绔欙細http://lfc.sourceforge.net/

鍝︼紝榪欏張鏄竴涓皾璇曟彁渚涗竴鍒囩殑C++搴撀?br />


鍏朵粬搴撀?br />
Loki聽

鍙傝冪綉绔欙細http://www.moderncppdesign.com/'>http:聽//www.moderncppdesign.com/'>http://www.moderncppdesign.com/'>http://www.moderncppdesign.com/

鍝︼紝浣犲彲鑳芥姳鎬ㄦ垜鏃╄鍜孊oost涓璧蜂粙緇嶅畠錛屼竴涓疄楠屾ц川鐨勫簱銆備綔鑰呭湪loki涓妸C++妯℃澘鐨勫姛鑳藉彂鎸ュ埌浜嗘瀬鑷淬傚茍涓斿皾璇曟妸綾諱技璁捐妯″紡榪欐牱鎬濇兂灞傞潰鐨勪笢瑗塊氳繃搴撴潵鎻愪緵銆傚悓鏃惰繕鎻愪緵浜嗘櫤鑳芥寚閽堣繖鏍鋒瘮杈冨疄鐢ㄧ殑鍔熻兘銆偮?br />
ATL聽

ATL(Active聽Template聽Library)鏄竴緇勫皬宸с侀珮鏁堛佺伒媧葷殑綾伙紝榪欎簺綾諱負鍒涘緩鍙簰鎿嶄綔鐨凜OM緇勪歡鎻愪緵浜嗗熀鏈殑璁炬柦銆偮?br />
FC++:聽The聽Functional聽C++聽Library聽

榪欎釜搴撴彁渚涗簡涓浜涘嚱鏁板紡璇█涓墠鏈夌殑瑕佺礌銆傚睘浜庣敤搴撴潵鎵╁厖璇█鐨勪竴涓唬琛ㄤ綔銆傚鏋滄兂瑕佸湪OOP涔嬪瀵繪壘鍙︿竴鍒嗙殑涔愯叮錛屽彲浠ュ幓鐪嬬湅鍑芥暟寮忕▼搴忚璁$殑涓栫晫銆傚ぇ甯埪燩eter聽Norvig鍦?Teach聽Yourself聽Programming聽in聽Ten聽Years"涓鏂囦腑灝卞皢鍑芥暟寮忚璦鍒椾負鑷沖皯搴斿綋瀛︿範鐨?綾葷紪紼嬭璦涔嬩竴銆偮?br />
FACT!聽

鍙傝冪綉绔欙細http://www.kfa'>http://www.kfa-juelich.de/zam/FACT/start/index.html

鍙﹀涓涓疄鐜板嚱鏁板紡璇█鐗規х殑搴撀?br />
Crypto++聽

鎻愪緵澶勭悊瀵嗙爜錛屾秷鎭獙璇侊紝鍗曞悜hash錛屽叕鍖欏姞瀵嗙郴緇熺瓑鍔熻兘鐨勫厤璐瑰簱銆偮?br />
榪樻湁寰堝闈炲父嬋鍔ㄤ漢蹇冩垨鑰呮槸鏋佸叾瀹炵敤鐨凜++搴擄紝闄愪簬鎴戜滑鐨勬按騫充互鍙婃枃绔犵殑綃囧箙涓嶈兘鍖呮嫭榪涙潵銆傚湪瀵逛簬榪欎簺宸茬粡鍖呭惈榪戞潵鐨勫簱鐨勪粙緇嶄腑錛岀敱浜庡茍涓嶆槸姣忎竴涓垜浠兘浣跨敤榪囷紝鎵浠ラ毦鍏嶆湁鍋忛涔嬪錛岃璇昏呰璋呫偮?br />


璧勬簮緗戠珯聽

姝e鎴戜滑鍙互閫氳繃璁$畻鏈哄巻鍙蹭笂鐨勯噸瑕佷漢鐗╀簡瑙h綆楁満鍙茬殑鍙戝睍錛孋++鐩稿叧浜虹墿鐨勭綉绔欎篃鍙互浣挎垜浠緱鍒版渶鏈変環鍊肩殑鍙傝冧笌鍊熼壌錛屼笅闈㈢殑浜虹墿鎴戜滑璁や負娌℃湁浠嬬粛鐨勫繀瑕侊紝鍙洜涓嬮潰鐨勪漢鐗╁湪C++棰嗗煙鐨勫湴浣嶄紬鎵鍛ㄧ煡錛屾垜浠彧灝嗙浉鍏崇殑璧勬簮榪涜緗楀垪浠ヤ緵璇昏呭涔狅紝浠栦滑鏈夌殑宸ヤ綔浜庤礉灝斿疄楠屽錛屾湁鐨勫伐浣滀簬鐭ュ悕緙栬瘧鍣ㄥ巶鍟嗭紝鏈夌殑鍦ㄤ笉鏂帹榪涜璦鐨勬爣鍑嗗寲錛屾湁鐨勪負璇昏呮挵鍐欎簡澶氶儴鍗冨彜濂囦綔......聽

Bjarne聽Stroustrup聽http://www.research.att.com/'>http://www.research.att.com/~bs/

Stanley聽B.聽Lippman聽

http:聽//blogs.msdn.com/slippman/(涓枃鐗?a target="_blank">http://www.zengyihome.net'>http:聽//www.zengyihome.net/slippman/index.htm'>http://www.zengyihome.net'>http://www.zengyihome.net/slippman/index.htm)聽

Scott聽Meyers聽http://www.aristeia.com/'>http://www.aristeia.com/

David聽Musser聽http://www.c'>http://www.c'>http://www.c'>http://www.cs.rpi.edu/~musser/

Bruce聽Eckel聽http://www.bruceeckel.com'>http://www.bruceeckel.com

Nicolai聽M.聽Josuttis聽http://www.josuttis.com/'>http://www.josuttis.com/

Herb聽Sutter聽http://www.gotw.ca/'>http://www.gotw.ca/

Andrei聽Alexandrescu聽http://www.moderncppdesign.com/'>http://www.moderncppdesign.com/'>http://www.moderncppdesign.com/'>http://www.moderncppdesign.com/

鏉? 2007-01-20 02:58 鍙戣〃璇勮
]]>
WTL鍑虹幇GUID閿欒 Did you forget to pass the LIBID to CComModule::Init?http://www.shnenglu.com/eday/archive/2007/01/18/17754.html鏉?鏉?Thu, 18 Jan 2007 08:23:00 GMThttp://www.shnenglu.com/eday/archive/2007/01/18/17754.html聽聽聽 When using WTL 7.0 with ActiveX controls under ATL 7.1, the framework will ASSERT inside atlcom.h on the following line:
聽聽聽 ATLASSERT(!InlineIsEqualGUID(*m_plibid,GUID_NULL) && "Did you forget to pass the LIBID to CComModule::Init?");

聽聽聽 This can be solved one of two ways:
聽聽聽 1) Change your "Use of ATL" setting to "Dynamic Link to ATL" in your project properties.
聽聽聽 2) Change your "Use of ATL" setting to "Static Link to ATL" and instead of using
聽聽聽 聽聽
hRes = _Module.Init(NULL, hInstance);
聽聽聽 聽聽 line in your _tWinMain, use this instead:
聽聽聽聽 GUID guid;
聽聽聽 聽聽 hRes = _Module.Init(NULL, hInstance, &guid);

聽聽聽 The ATLASSERT is apparently a bug in ATL 7.0/7.1 because everything works right if you pass a non-null GUID to _Module.Init(). Note that some people prefer to pass the actual LIBID instead of a garbage GUID, but this has no effect on whether the framework works correctly or not.



聽聽聽 I was unsure whether to post this under GDI or WTL, but WTL won out since I was using CScrollImpl when I encountered this problem. On one of the views in my WTL program, I was creating controls dynamically on the output screen. This worked fine until the controls I was creating extended beyond the range of the viewport. When I kept using the same RECT coordinates for the created controls in the scrolled view, I started having all sorts of positioning and resizing problems.

聽聽聽 Turns out that Create assumes that the RECT coordinates you specify in the call are from the top of the viewport, not the top of the window. This was not at all intuitive to me. Consequently, if you want to keep a common coordinate system when creating controls on a scrolling view, you must either 1) factor in the scroll bar offset yourself, or 2) scroll back to the top left of the window (without updating), place your controls and then scroll back to the proper position.

聽聽聽 By default, the COM Server code that the WTL AppWizard adds does not have the _Module.RegisterServer function set to TRUE by default. As a result, the type library information never showed up in the registry. A message in the ATL Archives relayed the answer to this problem.

聽聽聽 After trying to use extended combo boxes within a WTL app and not getting them to load, I knew I must be doing something wrong. I was initializing them with ::InitCommonControlsEx() in OnInitDialog(), which was a little too late. I moved them to DllMain, and that solved the problem. (The Microsoft ATL mailing list archives saved the day ...)

聽聽聽 I was trying to modify a WTL frame window by using ModifyStyle in OnCreate(). WTL doesn't like this very well. Instead I discovered that I got the results I was looking for by modifying CFrameWindowImpl to take a customized version of CWinTraits by adding it to the template definition. By the way, this also works for CWindowImpl, which is where I found this trick in the MSDN docs and ATL Internals. Also, this link shows another tricky portion of the whole process.

聽聽聽 Steps to use CDialogResize (from WTL 3.1):
聽聽聽 1) #include <atlframe.h> in your view/dialog class
聽聽聽 2) derive your view/dialog from CDialogResize:
聽聽聽聽聽聽聽 class CMyClass: public CDialogImpl<CMyClass>, ....
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽 public CDialogResize<CMyClass>
聽聽聽 3) Add a DLGRESIZE_MAP to your view as follows:
聽聽聽聽聽聽聽聽 BEGIN_DLGRESIZE_MAP(CMyClass)
聽聽聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDOK, DLSZ_MOVE_X | DLSZ_SIZE_Y)
聽聽聽聽聽聽聽 END_DLGRESIZE_MAP()
聽聽聽聽聽聽聽 The first parameter in the DLGRESIZE_CONTROL macro is the resource ID of your control. The second parameter(s) is the way that you want that control to be resized; valid values are DLSZ_MOVE_X, DLSZ_MOVE_Y, DLSZ_SIZE_X, DLSZ_SIZE_Y. (Note that you can OR these together with a |). You can also resize controls as a group by enclosing a number of DLGRESIZE_CONTROL macros with BEGIN_DLGRESIZE_GROUP() and END_DLGRESIZE_GROUP(). More on grouping in the next tip.
聽聽聽 4) Chain your message map to CDialogResize, i.e.
聽聽聽聽聽聽聽聽聽聽聽 BEGIN_MSG_MAP(CMyClass)
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽 ....
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽 CHAIN_MSG_MAP(CDialogResize<CMyClass>)
聽聽聽聽聽聽聽聽聽聽聽 END_MSG_MAP()
聽聽聽 5) Initialize the resizing for your view with DlgResize_Init(false, true, WS_CLIPCHILDREN) in OnInitDialog. Normally (for standard dialogs) you would just use DlgResize_Init() and accept the default parameters, but for a view you have to supply the extra settings since the view doesn't need a gripper or a frame like a dialog would.

Some things I've noticed about grouping controls with CDialogResize:
聽聽 1) You can group controls in one direction and leave them ungrouped in another direction to achieve good effects.
聽聽聽聽聽聽聽 For instance, if you had Save, Print and Close buttons running along the bottom of your dialog, centered and spaced evenly apart, you'd probably want to do this grouping:
聽聽聽聽聽聽 BEGIN_DLGRESIZE_MAP(CMyClass)
聽聽聽聽聽聽聽聽聽聽聽 BEGIN_DLGRESIZE_GROUP()
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDC_BTN_SAVE, DLSZ_MOVE_X )
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDC_BTN_PRINT, DLSZ_MOVE_X )
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDC_BTN_CLOSE, DLSZ_MOVE_X)
聽聽聽聽聽聽聽聽聽聽聽 END_DLGRESIZE_GROUP()
聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDC_BTN_SAVE, DLSZ_MOVE_Y)
聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDC_BTN_PRINT, DLSZ_MOVE_Y)
聽聽聽聽聽聽聽聽聽聽聽 DLGRESIZE_CONTROL(IDC_BTN_CLOSE, DLSZ_MOVE_Y)
聽聽聽聽聽聽 END_DLGRESIZE_MAP()

聽聽聽聽聽聽 This would keep all of them centered and spaced evenly as you moved them, while also moving them up and down independently.

聽聽聽 2) As soon as you noticed this little trick, however, you might start to take notice that your buttons don't exactly line up with the other controls on screen. You'd see this as the dialog was sized larger and larger. What's happening is that the leftmost button in the resource (this doesn't mean the top one in the DLGRESIZE_GROUP -- it's unrelated) is acting as an anchor for all the other buttons in the group. So when you resize the dialog, the leftmost button isn't moving ... it's just staying in place.
聽聽聽 There may be better ways to solve this problem, but what I did is insert a new invisible button on the resource in the leftmost position to act as the anchor. I then included the button in the DLGRESIZE_GROUP with a DLSZ_MOVE_X command as well so it would make all the other three buttons move together correctly. Like I said -- it works. If you stumble on something better



鏉? 2007-01-18 16:23 鍙戣〃璇勮
]]>
WTL浣撶郴緇撴瀯http://www.shnenglu.com/eday/archive/2007/01/18/17742.html鏉?鏉?Thu, 18 Jan 2007 01:49:00 GMThttp://www.shnenglu.com/eday/archive/2007/01/18/17742.html 緇

聽聽聽聽 WTL 鏈緇堟潵浜?/span> , 鑰屼笖 鎻愪緵浜嗘垜鎵甯屾湜鐨勫姛鑳?/span> . 鎴戝湪 WTL Bytesize (璇戞枃)鐨勬枃绔犲垪鍑?/span> WTL 涓昏鐗瑰緛 . 鍦ㄦ湰鏂囦腑 , 鎴戝皢鎻忚堪涓涓?/span> WTL 鐨勪綋緋葷粨鏋?/span> , 鍚屾椂鎴戜細緇欏嚭涓浜涚畝鍗曠殑渚嬪瓙鏉ユ紨紺哄浣曚嬌鐢ㄥ畠鐨勯偅浜涚壒寰?/span> . 甯屾湜鑳藉瀵規偍鏈?span lang="zh-cn">鎵甯姪 .

WTL 搴旂敤紼嬪簭鐨勭被鍨?/font>

聽聽聽聽 WTL 鏈夊ソ鍑犵搴旂敤紼嬪簭綾誨瀷 , 渚涙偍鍦?/span> AppWizard 閫夊彇 .



聽聽聽
涓嬭〃瀵硅繖浜涘簲鐢ㄧ▼搴忚繘琛屼簡鎻忚堪
. 榪欑寮規ф瀯鎴愪簡 WTL 浣撶郴緇撴瀯鐨勪竴閮ㄥ垎 .

搴旂敤紼嬪簭綾誨瀷 鎻忚堪
SDI Application 鍗曟枃鏈晫闈?/span> 鈥? 鍙湁涓涓獥鍙?/span>
Multiple Threads SDI 鍗曚釜榪涚▼鎷ユ湁涓涓垨澶氫釜紿楀彛
MDI Application 澶氭枃鏈晫闈?/span> 鈥? 鍦ㄦ鏋跺唴 , 鎮ㄥ彲浠ユ湁闆朵釜鎴栧涓瓙紿楀彛
Dialog Based 鍩轟簬瀵硅瘽妗嗘ā鐗?/span>

聽聽聽 浣犲彲鑳借繕鏄嬈″惉璇村綰跨▼SDI搴旂敤紼嬪簭,浣嗘槸涓嶇敤鎷呭績,瀹冪殑姒傚康寰堝鏄撶悊瑙?涓涓綰跨▼SDI紼嬪簭鍚姩鍚庡畠浼氭湁涓涓獥鍙? 紿楀彛鏄劇ず浜嗕竴涓枃妗? 褰撲綘鎯寵紼嬪簭瑕佸啀鍒涘緩涓涓枃妗f椂,闂灝卞嚭鐜頒簡--SDI紼嬪簭鍙兘鏄劇ず涓涓枃妗?涓轟簡瑙e喅榪欎釜闂,澶氱嚎紼婼DI鍒涘緩浜嗗彟涓涓猄DI紿楀彛.鐪嬭搗鏉ユ槸涓涓柊鐨勫疄渚嬪湪榪愯,瀹為檯涓婂畠涓嶈繃鏄師鏉ョ殑榪涚▼鍒涘緩浜嗕竴涓柊鐨勭獥鍙?騫舵妸瀹冧緷闄勫埌榪涚▼鐨勪竴涓柊綰跨▼. IE鐨勬柊寤虹獥鍙e氨鏄繖鏍峰仛鐨?

聽聽聽 闄や簡澶氱嚎紼?span lang="EN-US">SDI,鎵鏈夎繖浜涘簲鐢ㄧ▼搴忛兘鍙互浣滀負COM鏈嶅姟鍣? 騫朵笖搴旂敤紼嬪簭鍚戝(AppWizard)涓烘鎻愪緵浜嗕竴涓夐」.鍙﹀搴旂敤紼嬪簭鍚戝榪樺彲浠ヨ浣犳寚瀹氳紼嬪簭鏄惁涓繪寔ActiveX鎺т歡.浠や漢璐硅В鐨勬槸,涓嶅悓鐨勭▼搴忕被鍨?閫夊彇"Host ActiveX Controls"鐨勫湴鏂逛笉鍚?闄ゅ璇濇搴旂敤紼嬪簭澶栫殑鍏朵粬綾誨瀷鍦ㄧ涓欏典笂閫夊彇,鑰屽璇濇綾誨瀷鍗存斁鍒扮浜岄〉.

聽聽聽 絎簩欏電殑鍏朵粬閫夐」,瀵瑰璇濇紼嬪簭浠ュ鐨勭被鍨嬮兘鏄彲鐢ㄧ殑.瀹冧滑璁╀綘鎸囧畾紼嬪簭鏄惁闇瑕佸伐鍏鋒潯(toolbar),鐘舵佹潯(status bar)鍜岃紿楀彛(View Window).



聽聽聽 濡傛灉閫夊彇浜?Toolbar"閫夐」,浣犲彲浠ラ氳繃"Rebar"閫夋嫨鏄惁灝嗗伐鍏鋒潯鏀懼叆IE Rebar鎺т歡涓? 濡傛灉浣犻夊彇浜哛ebar, 浣犲氨鍙互閫氳繃妗嗘灦紿楀彛(frame window)鐨勬垚鍛榤_hWndToolBar(鍚庤竟浼氭湁璇︾粏鐨勬弿榪?鏉ヨ闂畠.浣犲彲浠ユ寜鐓т綘鐨勬剰鎰?鍦ㄩ噷杈瑰姞鍏ュ叾浠栫殑宸ュ叿鏉? 閫夊彇浜?Rebar"鍚? 浣犲彲浠ュ喅瀹氭槸鍚﹂夊彇"Command Bar".
Command bar寰堝儚CE鐨刢ommand bar鎺т歡.鍙槸WTL鏄敤涓涓被鏉ュ疄鐜?鑰屽湪CE, command bar鏄竴涓郴緇熺獥鍙g被(system window class). Command bar闈炲父鏈夌敤,瀹冭兘澶熸妸紿楀彛涔熷姞鍏ュ埌宸ュ叿鏉′腑鍘? 濡傛灉浣犻夊彇浜嗚繖涓夐」, 宸ュ叿鏉″拰鑿滃崟閮藉皢琚綋鍋歵oolbar鏉ュ疄鐜?榪欎嬌鑿滃崟欏逛篃鍙互鏈夊叧鑱旂殑鍥炬爣,騫朵笖褰撲綘縐誨姩榧犳爣鍒頒竴涓彍鍗曢」涓婃椂,璇ヨ彍鍗曢」浼氳緗垚楂樹寒.浠嶰ffice 97浠ユ潵, Office杞歡鐨勮彍鍗曢兘鍏鋒湁涓婅堪鐗瑰緛.

聽聽聽 絎簩欏佃繕鏈夋寚瀹氱▼搴忔槸鍚︿嬌鐢ㄨ鐨勯夐」(澶氬崐浣犳兂瑕佷嬌鐢?, 鍚屾椂浣犲彲浠ュ喅瀹氳繖浜涜濡備綍瀹炵幇. 涓嬭〃鍒楀嚭浜嗘墍鏈夊彲閫夌殑瑙?

瑙?/span> 鎻忚堪
Generic Window 涓涓畝鍗曠殑紿楀彛 . 姝ょ被紿楀彛鍏佽紼嬪簭鍛樼紪鍐?/span> WM_PAINT 娑堟伅鐨勫鐞嗗嚱鏁?/span> . 閫傜敤浜庨渶瑕佺洿鎺ヨ繘琛?/span> paint 鐨勬枃妗?/span> .
Form 榪欑被瑙嗗叿鏈変竴涓璇濇妯$増 . 閫傜敤浜庡甫 ActiveX 鎺т歡鐨勭獥鍙?/span> . 搴旂敤紼嬪簭鏉ユ搷浣滆繖浜涙帶浠?/span> .
List Box 榪欎釜瑙嗘槸涓?/span> list box. 瀹冩渶綆鍗曠殑褰㈠紡鎰忓懗鐫鍙互閫氳繃璋冪敤 AddString() 鏂規硶鏉ユ坊鍔犲瓧絎︿覆 .
Edit 榪欎釜瑙嗘槸涓?/span> edit control. 鏈川涓?/span> , 瀹冩彁渚涗簡涓涓儚 Notepad 涓鏍風殑紼嬪簭 .
List View 榪欎釜瑙嗘槸涓?/span> list view 閫氱敤鎺т歡 . 鐢ㄨ繖涓帶浠舵潵鏄劇ず鐩稿叧鐨勯」 ( 姣斿 , 鎺у埗闈㈡澘鏄竴涓?/span> Explorer 涓繪寔鐨?/span> List View, 鎵鏈夌殑欏歸兘鏄帶鍒墮潰鏉?/span> applet).
Tree View 榪欎釜瑙嗘槸涓?/span> tree view 閫氱敤鎺т歡 . 榪欎釜閫傜敤浜庡叿鏈夊眰嬈″叧緋葷殑鏁版嵁 , 姣斿 , 鍙互鐢ㄥ畠鏉ユ樉紺烘暟鎹簱鐨?/span> schema. 欏跺眰鍒嗘敮涓鴻〃鍜屽瓨鍌ㄨ繃紼?/span> , 嬈$駭鐨勫垎鏀負琛ㄤ腑鐨勫瓧孌?/span> .
Rich Edit 榪欎釜瑙嗘槸涓?/span> rich edit 鎺т歡 , 鍍?/span> WordPad.
HTML Page 榪欎釜瑙嗕富鎸佷簡涓涓?/span> IE Web Browser 鎺т歡 . 瀹冩妸涓繪寔鐨勪竴涓?/span> web page 褰撴垚涓涓 .

聽聽聽 鏈枃鐨勪緥瀛愰渶瑕佷竴涓璇濇妯$増 , 鍚屾椂榪橀渶瑕佽彍鍗?/span> , 鍥犳 Form view 鏄釜鐞嗘兂鐨勯夋嫨 .

紼嬪簭綰跨▼

聽聽聽 璺烝TL涓鏍?WTL紼嬪簭涔熼渶瑕佷竴涓?font face="Courier New">_Module鍏ㄥ眬鍙橀噺鏉ヤ繚瀛樺叏灞鏁版嵁,鏂逛究搴旂敤綰т唬鐮佽闂?鍦╓TL涓?榪欎釜鍙橀噺鏄?font face="Courier New">CAppModule鎴?font face="Courier New">CServerAppModule鐨勫疄渚?鍚庤呭湪紼嬪簭鍚屾椂浣滀負涓涓狢OM鏈嶅姟鍣ㄦ椂鐢ㄥ埌.姣忎釜搴旂敤紼嬪簭鍏鋒湁涓涓垨鑰呭涓猆I綰跨▼.WTL浣跨敤涓ょ鏂瑰紡鏉ョ鐞嗚繖浜涚嚎紼?

聽聽聽 濡傛灉搴旂敤紼嬪簭鍙湁涓涓猆I綰跨▼(闄や簡澶氱嚎紼婼DI浠ュ,鍏朵粬紼嬪簭綾誨瀷榛樿鍙湁涓涓猆I綰跨▼),綰跨▼璋冪敤鍏ㄥ眬鍑芥暟run():

int Run(LPTSTR /*lpstrCmdLine*/ = NULL, int nCmdShow = SW_SHOWDEFAULT)
{
聽聽聽 CMessageLoop theLoop;
聽聽聽 _Module.AddMessageLoop(&theLoop);
聽聽聽 CMainFrame wndMain;
聽聽聽 if (wndMain.CreateEx() == NULL)
聽聽聽 {
聽聽聽聽聽聽聽 ATLTRACE(_T("Main window creation failed!\n"));
聽聽聽聽聽聽聽 return 0;
聽聽聽 }
聽聽聽 wndMain.ShowWindow(nCmdShow);
聽聽聽 int nRet = theLoop.Run();
聽聽聽 _Module.RemoveMessageLoop();
聽聽聽 return nRet;
}

聽聽聽 綰跨▼鐨勬秷鎭驚鐜寘鍚湪CMessageLoop鍐呴儴.鍑芥暟鍒涘緩浜嗕竴涓?b>CMessageLoop瀹炰緥, 鎶婂畠鏀懼叆鍏ㄥ眬鐨勬秷鎭驚鐜槧灝?message loop map)鏁扮粍. 浠ョ嚎紼婭D涓虹儲寮?綰跨▼涓繍琛岀殑鍏朵粬鐨勪唬鐮佸彲浠ヨ闂埌榪欎釜瀹炰緥. 娑堟伅寰幆瀵硅薄鍖呭惈浜唌essage filter鍜宨dle handler. 榪愯鍦ㄨ繖涓猆I綰跨▼鐨刄I鍏冧歡(UI element)鍙互鏈夊畠鑷繁鐨刬dle handler,鍦ㄧ嚎紼嬬殑娑堟伅闃熷垪涓虹┖鏃惰繍琛?font face="瀹嬩綋">銆?/font>璇戞敞:閫氳繃CMessageLoop::AddIdleHandler()鎶婅繖涓猆I鍏冧歡鍔犲叆鍒?b>CMessageLoop鐨刬dle handler 鏁扮粍涓?font face="瀹嬩綋">銆?/font>. CMessageLoop::Run()鍖呭惈浜哢I綰跨▼鐨勪富娑堟伅鏄犲皠(main message map).涓嬭竟鏄畠鐨勪吉浠g爜:

MSG m_msg;
int CMessageLoop::Run()
{
聽聽聽 for (;;)
聽聽聽 {
聽聽聽聽聽聽聽 while (!::PeekMessage(&m_msg, NULL, 0, 0, PM_NOREMOVE))
聽聽聽聽聽聽聽聽聽聽聽 DoIdleHandlers();
聽聽聽聽聽聽聽 bRet = ::GetMessage(&m_msg, NULL, 0, 0);
聽聽聽聽聽聽聽 if(bRet == -1)
聽聽聽聽聽聽聽聽聽聽聽 continue;
聽聽聽聽聽聽聽 else if(!bRet)
聽聽聽聽聽聽聽聽聽聽聽 break;
聽聽聽聽聽聽聽 if (!DoMessageFilters(&m_msg))
聽聽聽聽聽聽聽 {
聽聽聽聽聽聽聽聽聽聽聽 ::TranslateMessage(&m_msg);
聽聽聽聽聽聽聽聽聽聽聽 ::DispatchMessage(&m_msg);
聽聽聽聽聽聽聽 }
聽聽聽 }
聽聽聽 return (int)m_msg.wParam;
}


聽聽聽 鍙互鐪嬪埌,榪欎釜鍑芥暟鎺ㄥ姩鐫娑堟伅闃熷垪. 娌℃湁娑堟伅鏃? 榪愯娉ㄥ唽鍒扮嚎紼嬬殑idle hander. 濡傛灉鍦ㄩ槦鍒椾腑媯嫻嬪埌娑堟伅,鎶婂畠鍙栧嚭鏉?浼犵粰姣忎釜message filter. 濡傛灉娑堟伅娌℃湁琚繖浜涘嚱鏁板鐞?瀹冨皢鎸夌収閫氬父鐨勬柟寮?鍙戦佸埌鐩爣紿楀彛.

聽聽聽 濡傛灉紼嬪簭鏈夎秴榪囦竴涓殑UI綰跨▼,鍙互鐢╓TL鐨勭嚎紼嬬鐞嗗櫒,澶氱嚎紼婼DI灝辨槸榪欐牱鍋氱殑. 涓葷嚎紼嬩綔涓轟竴涓鐞嗚呯嚎紼?瀹冧細涓烘瘡涓柊紿楀彛鍒涘緩涓涓柊鐨?span lang="zh-cn">鏂?/span>綰跨▼. 涓昏嫻佺▼濡備笅:

int nRet = m_dwCount;
DWORD dwRet;
while(m_dwCount > 0)
{
聽聽聽 dwRet = ::MsgWaitForMultipleObjects(m_dwCount, m_arrThreadHandles,
聽聽聽聽聽聽聽 FALSE, INFINITE, QS_ALLINPUT);
聽聽聽 if(dwRet >= WAIT_OBJECT_0 && dwRet <= (WAIT_OBJECT_0 + m_dwCount - 1))
聽聽聽聽聽聽聽 RemoveThread(dwRet - WAIT_OBJECT_0);
聽聽聽 else if(dwRet == (WAIT_OBJECT_0 + m_dwCount))
聽聽聽 {
聽聽聽聽聽聽聽 ::GetMessage(&msg, NULL, 0, 0);
聽聽聽聽聽聽聽 if(msg.message == WM_USER)
聽聽聽聽聽聽聽聽聽聽聽 AddThread(_T(""), SW_SHOWNORMAL);
聽聽聽 }
}


閭d簺綰跨▼鍙ユ焺鏀懼湪涓涓暟緇勪腑. 綰跨▼閫氳繃AddThread()鍔犲叆鍒版暟緇?鍚屾椂鍚姩綰跨▼), RemoveThread()浠庢暟緇勭Щ璧? wait璇彞鍦ㄤ袱縐嶆儏鍐典笅浼氳鎵撴柇: 綰跨▼姝諱骸(灝嗙嚎紼嬩粠鏁扮粍涓Щ鍑? 鎴栫嚎紼嬫敹鍒頒簡WM_USER娑堟伅(涓涓嚎紼嬪湪涓涓柊綰跨▼閲屾柊寤轟簡涓涓獥鍙?. 綰跨▼綆$悊鑰呬負紼嬪簭涓殑涓涓被,鍥犳鍙互鍦ㄥ驚鐜腑鍔犲叆鑷繁鐨刴essage handler, 姣斿,褰撶▼搴忔湁涓嶆涓縐嶇獥鍙g被鍨嬫椂. 鍒涘緩涓涓柊鐨勭獥鍙i潪甯哥畝鍗?鍙渶鍦ㄤ換鎰忎竴涓獥鍙d腑璋冪敤:

::PostThreadMessage(_Module.m_dwMainThreadID, WM_USER, 0, 0L);

榪欎釜寰幆浼氫竴鐩磋繍琛屼笅鍘?鐩村埌鎵鏈夌殑UI綰跨▼閮藉叧闂簡. UI綰跨▼鍏鋒湁涓涓猼hread procedure,瀹冭窡鍗昒I綰跨▼鐨凴un()鏂規硶涓鏍?涓嶈繃,鐢變簬綰跨▼綆$悊鑰呬嬌鐢ㄤ簡MsgWaitForMultipleObjects(), 榪欐剰鍛寵呮渶澶氬彧鑳芥湁MAXIMUM_WAIT_OBJECTS-1涓猆I綰跨▼,榪欎篃鎰忓懗鐫鏈澶氬彧鑳藉垱寤?3涓獥鍙?

妗嗘灦

聽聽聽 WTL瀹為檯涓婃槸涓ょ被紿楀彛: 妗嗘灦紿楀彛鍜岃鍥劇獥鍙? 姝e鍚嶅瓧鎵鏆楃ず鐨勯偅鏍? 妗嗘灦紿楀彛涓虹獥鍙f彁渚涙爣棰樻爮(caption bar)鍜岃竟妗?浣犵殑浠g爜鐢ㄥ畠鏉ュ鐞嗗伐鍏鋒潯(tool bar)鍜岃彍鍗曢」鍛戒護.浣犵湅鍒扮殑紼嬪簭紿楀彛瀹為檯涓婃槸瑙嗗浘紿楀彛, 瑙嗗浘瑕嗙洊浜嗘鏋剁獥鍙g殑瀹㈡埛鍖?瀹㈡埛鍖烘槸鎸囨鏋剁獥鍙f病鏈夎璇稿鐘舵佹潯,宸ュ叿鏉′箣綾葷殑淇グ閮ㄤ歡鎵閬尅鐨勯儴鍒?

聽聽聽 綰跨▼浼氬垱寤轟富妗嗘灦紿楀彛鐨勪竴涓疄渚?鍒涘緩瑙嗗浘鐨勫伐浣滅敱涓繪鏋剁獥鍙g殑WM_CREATE娑堟伅澶勭悊鍑芥暟瀹屾垚. 瀵逛簬SDI紼嬪簭鏉ヨ,榪欎釜榪囩▼寰堢畝鍗? 鎶婅鍥劇被鐨勪竴涓疄渚嬩綔涓轟富妗嗘灦綾葷殑涓涓垚鍛?璋冪敤瑙嗗浘綾葷殑Create()鏂規硶鍗沖彲.MDI紼嬪簭紼嶅井鏈変簺涓嶅悓, MDI涓繪鏋剁獥鍙i氳繃CMDIFrameWindowImpl<>::CreateMDIClient()寤虹珛涓涓悕涓?b>MDICLIENT鐨勭獥鍙? 榪欎釜瀹㈡埛紿楀彛灝?font face="Courier New">CMDIChildWindowImpl<>紿楀彛褰撳仛瀹冪殑瀛愮獥鍙?瀛愮獥鍙f湁涓涓鍥?榪欎篃鍙嶆槧浜嗚繖涔堜竴涓簨瀹?MDI紼嬪簭鍙互鍏鋒湁闆朵釜鎴栬呭涓瓙紿楀彛,姣忎釜閮芥湁杈規鍜屾爣棰樻爮.

妗嗘灦紿楀彛鐨凮nCreate()寰堟湁鎰忔?璁╂垜鐪嬬湅:

LRESULT OnCreate(UINT, WPARAM, LPARAM, BOOL&)
{
聽聽聽 // create command bar window
聽聽聽 HWND hWndCmdBar = m_CmdBar.Create(m_hWnd, rcDefault,
聽聽聽聽聽聽聽 NULL, ATL_SIMPLE_CMDBAR_PANE_STYLE);
聽聽聽 // attach menu
聽聽聽 m_CmdBar.AttachMenu(GetMenu());
聽聽聽 // load command bar images
聽聽聽 m_CmdBar.LoadImages(IDR_MAINFRAME);
聽聽聽 // remove old menu
聽聽聽 SetMenu(NULL);
聽聽聽 HWND hWndToolBar = CreateSimpleToolBarCtrl(m_hWnd, IDR_MAINFRAME,
聽聽聽聽聽聽聽 FALSE, ATL_SIMPLE_TOOLBAR_PANE_STYLE);
聽聽聽 CreateSimpleReBar(ATL_SIMPLE_REBAR_NOBORDER_STYLE);
聽聽聽 AddSimpleReBarBand(hWndCmdBar);
聽聽聽 AddSimpleReBarBand(hWndToolBar, NULL, TRUE);
聽聽聽 CreateSimpleStatusBar();
聽聽聽 m_hWndClient = m_view.Create(m_hWnd, rcDefault, NULL,
聽聽聽聽聽聽聽 WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | WS_CLIPCHILDREN,
聽聽聽聽聽聽聽 WS_EX_CLIENTEDGE);
聽聽聽 UIAddToolBar(hWndToolBar);
聽聽聽 UISetCheck(ID_VIEW_TOOLBAR, 1);
聽聽聽 UISetCheck(ID_VIEW_STATUS_BAR, 1);
聽聽聽 CMessageLoop* pLoop = _Module.GetMessageLoop();
聽聽聽 pLoop->AddMessageFilter(this);
聽聽聽 pLoop->AddIdleHandler(this);
聽聽聽 return 0;
}

聽聽聽 榪欐槸浠庝竴涓猄DI紼嬪簭鎷挎潵鐨勪竴孌典唬鐮?璇ョ▼搴忔湁涓涓熀浜巆ommand bar鐨勫伐鍏鋒潯鍜屼竴涓姸鎬佹潯. 鍑芥暟鐨勭涓琛屽垱寤轟簡涓涓猚ommand bar瀹炰緥,鐒跺悗瀵瑰畠榪涜鍒濆鍖?鍦ㄥ叾涓姞鍏ユ鏋剁獥鍙g殑鑿滃崟鍜屽伐鍏鋒潯浣嶅浘. 榪欐浠g爜鍏堝皢鑿滃崟鍙栧嚭,鎶婃墍鏈夌殑涓嬫媺鑿滃崟杞崲涓哄伐鍏鋒潯鎸夐挳,騫跺皢鑿滃崟淇濆瓨鍦ㄤ竴涓彉閲忎腑,浠ュ鍚庣敤. 緇欎漢鐨勬劅瑙夋槸鑿滃崟鏄敱宸ュ叿鏉″疄鐜扮殑-閭f垜浠氨鎶婂畠鍙仛宸ュ叿鏉¤彍鍗?menu toolbar)鍚? 鐒跺悗Command Bar灝嗙▼搴忓伐鍏鋒潯鐨勫浘鏍囪鍏mage list 騫跺皢瀹冧滑鐨処D淇濆瓨鍦ㄦ暟緇勪腑. 褰撶偣鍑誨伐鍏鋒潯鑿滃崟鐨勬寜閽椂,commandbar浼氭壘鍒板搴旂殑瀛愯彍鍗?鍒涘緩涓涓脊鍑鴻彍鍗? Command bar灝嗗瓙鑿滃崟欏圭殑ID鍜屽畠淇濆瓨鐨処D榪涜姣旇緝,榪欎簺ID璺焛mage list涓殑宸ュ叿鏉℃寜閽浘鏍囨槸鐩稿叧鑱旂殑. 濡傛灉姣旇緝鎴愬姛, 鍒欏皢鍏寵仈鐨勫浘鏍囧姞鍒拌彍鍗曢」涓婂幓. 榪欐剰鍛崇潃鐩稿悓ID鐨勮彍鍗曢」鍜屽伐鍏鋒潯鎸夐挳鍏鋒湁鐩稿悓鐨勫浘鏍?

鎺ヤ笅鏉? 鍒涘緩宸ュ叿鏉″茍鎶婂畠鍏寵仈鍒癱ommandbar, 鐒跺悗鍒涘緩鐘舵佹潯鍜岃鍥?鍙互鐪嬪埌瑙嗗浘鐨?b>HWND瀛樻斁鍦ㄦ鏋剁獥鍙g殑m_hWndClient鍙橀噺涓? 榪欎釜紿楀彛鍙ユ焺鍦ㄦ鏋剁獥鍙g殑WM_SIZE handler涓細鐢ㄥ埌.褰撴鏋剁獥鍙f敼鍙樺ぇ灝忔椂,瀹冨憡鐭ヨ鍥炬敼鍙樿嚜韜?浜庢鍚屾椂涔熻鑰冭檻鐘舵佹潯鍜宑ommand bar.

鍦ㄤ笅鏉ョ殑涓夎(浠庤皟鐢?b>UIAddToolBar()寮濮? 鐢ㄦ潵鏄劇ず鍦ㄨ繍琛屾椂浼氭敼鍙樼姸鎬佺殑UI欏?UI item).鏂囩珷鍚庨潰榪樹細閲嶆彁榪欎釜璇濋. 鏈鍚?璁塊棶娑堟伅寰幆(message loop), 浣犲簲璇ヨ繕璁板緱璇ユ秷鎭驚鐜瓨鏀懼湪涓鍏ㄥ眬鏁扮粍涓?GetMessageLoop() 鍙栧緱褰撳墠綰跨▼鐨勬秷鎭驚鐜?鍔犲叆妗嗘灦紿楀彛鐨刴essage filter鍜宨dle handler, 鍒嗗埆榛樿鏄?b>PreTranslateMessage()鍜?b>OnIdle().

妗嗘灦紿楀彛緇ф壙浜庝互涓嬬被:

class CMainFrame :
聽聽聽 public CFrameWindowImpl<CMainFrame>,
聽聽聽 public CUpdateUI<CMainFrame>,
聽聽聽 public CMessageFilter,
聽聽聽 public CIdleHandler


鍚庝袱涓娊璞$被瀹gО浜嗘鏋剁獥鍙g被瀹炵幇浜?b>PreTranslateMessage()鍜?b>OnIdle(). 浠?b>CUpdateUI<>緇ф壙琛ㄧず妗嗘灦綾繪敮鎸乁I update map.

瑙嗗浘

瑙嗗浘紿楀彛鐪嬭搗鏉?/span>鏄懼緱寰堢畝鍗?

class CMyView : public CWindowImpl<CMyView>
{
public:
聽聽聽 DECLARE_WND_CLASS(NULL)
聽聽聽 BOOL PreTranslateMessage(MSG* pMsg)
聽聽聽 {
聽聽聽 聽聽聽 pMsg;
聽聽聽聽聽聽聽 return FALSE;
聽聽聽 }
聽聽聽 BEGIN_MSG_MAP(CMyView)
聽聽聽聽聽聽聽 MESSAGE_HANDLER(WM_PAINT, OnPaint)
聽聽聽 END_MSG_MAP()
聽聽聽 LRESULT OnPaint(UINT, WPARAM, LPARAM, BOOL&)
聽聽聽 {
聽聽聽聽聽聽聽 CPaintDC dc(m_hWnd);
聽聽聽聽聽聽聽 //TODO: Add your drawing code here
聽聽聽聽聽聽聽 return 0;
聽聽聽 }
};


涓婇潰鏄?/span>涓涓猄DI紼嬪簭鐨勮鍥劇被. 澶氱嚎紼婼DI鍜孧DI鐨勮鍥劇被鍦ㄦ湰璐ㄤ笂涔?span lang="zh-cn">璺熻繖涓?/span>涓鏍?浣嗕粬浠病鏈?b>PreTranslateMessage()鏂規硶. SDI紼嬪簭灝辨槸浣跨敤榪欎釜鍑芥暟,璧跺湪妗嗘灦綾?span lang="zh-cn">澶勭悊娑堟伅涔嬪墠鎶婃秷鎭?/span>鎶撲綇. PreTranslateMessage()鍦⊿DI鐨勬鏋剁被涓殑瀹炵幇鏄?span lang="zh-cn">錛?/span>鐩存帴灝?/span>娑堟伅杞彂緇欒鍥劇被.

榪欓噷鏄劇ず鐨勮鍥懼疄闄呬笂娌℃湁鍋氫粈涔堝伐浣?浣犲簲璇?span lang="zh-cn">鑷繁
鍦?b>OnPaint()鍑芥暟涓姞鍏ョ敾鍑烘枃妗?span lang="zh-cn">鍐呭
鐨勪唬鐮?濡傛灉瑕佹敮鎸佽緭鍏?濡傞紶鏍囩殑鐐瑰嚮鍜岄敭鐩樼殑鎸夐敭,浣犲簲璇ュ姞鍏?span lang="zh-cn">鐩稿簲娑堟伅澶勭悊鍑芥暟鍒扮被鍜屾槧灝勪腑. 鍙互鐪?span lang="zh-cn">鍒?/span>榪欎釜紿楀彛鏄粠CWindowImpl<>緇ф壙涓嬫潵鐨?濡傛灉浣犳兂璁╁畠鍩轟簬涓涓猈in32鎺т歡鐨勮瘽,灝卞簲璇ヤ粠瀹氫箟鍦ˋtlCtrls.h鏂囦歡涓?span lang="zh-cn">鏌愪釜WTL綾葷戶鎵?

濡傛灉鎯沖湪鍩轟簬CWindowImpl<>鐨勭被閲屽姞涓婃粴鍔ㄦ潯,閭d箞浣犲簲璇ユ妸鍩虹被鎹㈡垚CScrollWindowImpl<>,鍚屾椂鎶婃秷鎭摼緇欏畠:

class CMyView : public CScrollWindowImpl<CMyView>
{
public:
聽聽聽 typedef CScrollWindowImpl<CMyView> parent;
聽聽聽 BEGIN_MSG_MAP(CMyView)
聽聽聽聽聽聽聽 CHAIN_MSG_MAP(parent)
聽聽聽 END_MSG_MAP()
聽聽聽 void DoPaint(CDCHandle dc)
聽聽聽 {
聽聽聽 }
}錛?/span>

鍩虹被淇濊瘉紿楀彛鍏?span lang="zh-cn">澶?/span>婊氬姩鏉?騫舵彁渚涙粴鍔ㄦ潯娑堟伅鐨勯粯璁ゅ鐞?瑙嗗浘綾諱笉鍐嶆湁WM_PAINT鐨勫鐞嗗嚱鏁?鍥犱負瀹?span lang="zh-cn">宸?/span>琚?b>CScrollWindowImpl<>澶勭悊.鏍規嵁婊氬姩鏉$殑浣嶇疆,CScrollWindowImpl<>鐢誨嚭瑙嗗浘鐩稿搴旂殑閮ㄥ垎. 鍙栬屼唬涔?span lang="zh-cn">鐨?/span>鏄?span lang="zh-cn">錛?/span>鍦ㄤ綘鐨勭被閲屽疄鐜?b>DoPaint(),鍦ㄨ繖閲屼綘闇瑕佺敾鍑?span lang="zh-cn">鏁?/span>涓鍥?濡傛灉浣?span lang="zh-cn">鎯?/span>鎸囧畾婊氬姩鐨勮寖鍥?澶у皬鎴栬搗鐐?浣犻渶瑕佸姞涓婂鐞?b>WM_CREATE娑堟伅鐨勫嚱鏁?span lang="zh-cn">錛屾妸榪欎簺鍒濆鍖?/span>浠g爜鏀懼埌閲岃竟.

姝e鎴戝厛鍓?span lang="zh-cn">鎵鎻愬埌鐨?妗嗘灦紿楀彛浼氭敼鍙樿鍥劇獥鍙g殑澶у皬,浠ヤ嬌瀹冨鎴峰尯鏈鐘舵佹潯鍜屽伐鍏鋒潯瑕嗙洊鐨勯儴鍒嗕負瑙嗗浘鎵濉厖. 鍦ㄥぇ澶氭暟鎯呭喌涓?榪欐牱灝卞浜?/span>.浣嗘槸褰撲綘鎯寵涓涓叿鏈塛indows Explorer鏍峰瓙鐨勭▼搴忔椂,璇ユ庝箞鍔炲憿? Windows Explorer鐨勭獥鍙e寘鍚簡涓涓猼ree view 鍜屼竴涓猯ist view,榪樻湁涓よ呬箣闂寸殑鍒嗗壊鏉? WTL鐨勮В鍐蟲柟妗堝緢綆鍗?浣跨敤splitter紿楀彛!

涓烘浣犻渶瑕佹敼鍙樹竴涓嬫鏋剁獥鍙?璁╁畠鍒涘緩splitter紿楀彛鐨勪竴涓疄渚嬩綔涓哄畠鐨勮鍥? 渚嬪, 鍦ㄤ綘鐨?span lang="zh-cn">妗嗘灦
綾婚噷鏈夊涓嬬殑鏁版嵁鎴愬憳:

CSplitterWindow m_view;
CTreeViewCtrl m_tree;
CListViewCtrl m_list;


浣犲彲浠ュ湪OnCreate()鍒涘緩涓涓猻plitter紿楀彛:

// get the frame client rect, so that we set the splitter initial size
// and we can get the splitter bar in the centre

RECT rect;
GetClientRect(&rect);
m_hWndClient = m_view.Create(m_hWnd, rect,
聽聽聽 NULL, WS_CHILD | WS_VISIBLE);
m_tree.Create(m_view, rcDefault, NULL,
聽聽聽 WS_CHILD | WS_VISIBLE | TVS_HASBUTTONS | TVS_HASLINES | TVS_LINESATROOT,
聽聽聽 WS_EX_CLIENTEDGE);
m_list.Create(m_view, rcDefault,
聽聽聽 NULL, WS_CHILD | WS_VISIBLE | LVS_REPORT, WS_EX_CLIENTEDGE);
m_view.SetSplitterPanes(m_tree, m_list);
m_view.SetSplitterPos();


Splitter紿楀彛濡傚悓涓涓鍥?灝嗘鏋剁獥鍙d綔涓哄畠鐨勭埗紿楀彛. 鍦ㄨ繖孌典唬鐮侀噷,鎴戝皢妗嗘灦紿楀彛瀹㈡埛鍖虹殑瀹為檯澶у皬浼犵粰浜?/span>splitter紿楀彛. 鎴?span lang="zh-cn">涔?/span>鍙互鍦ㄨ繖閲屼嬌鐢?rcDefault,鍥犱負涓鏃︽鏋剁獥鍙?span lang="zh-cn">鍒涘緩瀹屾垚,妗嗘灦紿楀彛灝?/span>浼氳漿鍙?b>WM_SIZE娑堟伅緇檚plitter. 榪欐牱splitter鍙互椹笂鏀瑰彉鑷韓鐨勫ぇ灝忔潵濉厖妗嗘灦. 鐒惰?褰撴垜鍑嗗浣跨敤涓?span lang="zh-cn">甯?/span>鍙傛暟鐨?b>SetSplitterPos(),鎶婂垎鍓叉潯璁劇疆浜庣獥鍙d腑綰挎椂,鍑虹幇浜嗛棶棰?Splitter紿楀彛浣跨敤瀹冪殑澶у皬鏉ュ喅瀹氫腑綰跨殑浣嶇疆,鐢變簬rcDefault鍛婅瘔紿楀彛瀹冪殑澶у皬鏄?(鍥犳涓嚎鐨勪綅緗篃鏄?),浠庤屾剰鍛崇潃鍒嗗壊鏉″皢鍑虹幇鍦?span lang="zh-cn">z鏈宸﹁竟,灝?/span>宸︾獥鍙i殣钘忎簡璧鋒潵.

鍒涘緩浜唖plitter紿楀彛鍚?浣犻渶瑕佸垱寤洪偅浜涗綘鎯寵鍒嗗壊鐨勭獥鍙?span lang="zh-cn">浜?/span>.瀹冧滑灝嗕綔涓簊plitter紿楀彛鐨?span lang="zh-cn">瀛?/span>紿楀彛琚垱寤?鏈鍚庝綘灝嗚繖浜涘瓙紿楀彛閫氳繃SetSplitterPanes()鍔犲埌splitter紿楀彛涓幓,騫剁‘瀹氬垎鍓叉潯鐨勪綅緗墍鍦?

UI Update

鑿滃崟欏瑰彲浠ヨ璁劇疆涓烘湁鏁堟垨鏃犳晥,鍙互甯?/span>check璁板彿鎴栫潃鍍弐adio鎸夐挳涓鏍?鍦?/span>涓緇?span lang="zh-cn">鑿滃崟欏逛腑鍚屾椂鏈変笖鍙湁涓涓?span lang="zh-cn">鑳借check.姝ゅ,鑿滃崟欏硅繕鍙互甯﹀浘鏍囧拰鏂囧瓧. 鎵鏈夌殑榪欎簺鐘舵侀兘鍙互鍦ㄨ繍琛屾椂鏍規嵁紼嬪簭涓殑鏌愪釜鍊艱繘琛屾敼鍙?宸ュ叿鏉″湪鏌愮紼嬪害涓婂彲浠ョ湅鍋氭槸鑿滃崟鐨勬槗瑙佸艦鎬?鍥犱負瀹冧滑鐨勬寜閽彲浠ヤ釜鍒湴,鎴栬呬綔涓轟竴緇勭殑涓閮?span lang="zh-cn">鍒?/span>琚疆鎴愭湁鏁堟垨鏃犳晥,鎺ㄥ叆鎺ㄥ嚭. UI update鏈哄埗鍏佽浣犳寚瀹氬摢浜沀I鍏冧歡(UI element)鐨勭姸鎬佸彲浠ュ湪榪愯鏃舵敼鍙? WTL浣跨敤濡備笅鐨刄I update鏄犲皠鏉ュ疄鐜拌繖涓鍔熻兘:


BEGIN_UPDATE_UI_MAP(CMainFrame)
聽聽聽 UPDATE_ELEMENT(ID_FILE_SAVERESULTS, UPDUI_MENUPOPUP | UPDUI_TOOLBAR)
聽聽聽 UPDATE_ELEMENT(ID_VIEW_TOOLBAR, UPDUI_MENUPOPUP)
聽聽聽 UPDATE_ELEMENT(ID_VIEW_STATUS_BAR, UPDUI_MENUPOPUP)
END_UPDATE_UI_MAP()

榪欎釜渚嬪瓙鎸囧嚭涓変釜鑿滃崟欏瑰湪榪愯鏃舵湁涓涓姸鎬侀渶瑕佹樉紺?鍏朵腑鐨勪竴涓? ID_FILE_SAVERESULTS,榪?/span>鏈変竴涓伐鍏鋒潯鎸夐挳璺熷畠鐩稿叧鑱? WTL閫氳繃寤虹珛涓涓暟緇勬潵淇濆瓨榪欎簺淇℃伅.涓烘浣犻渶瑕?span lang="zh-cn">瀹屾垚涓ゆ柟闈㈢殑宸ヤ綔:

棣栧厛鏄疷I鍏冧歡鐨勭姸鎬? 濡傛灉鏄彍鍗曢」, 浣犲彲浠ヤ嬌鐢?b>UIEnable()浣胯兘璇ヨ彍鍗曢」, UISetCheck()璁劇疆check璁板彿, UISetText()鏀瑰彉鑿滃崟鐨勬枃瀛?濡傛灉鏄伐鍏鋒潯鎸夐挳,閭d箞浣犱嬌鐢?b>UIEnable()浣胯兘璇ユ寜閽? UISetCheck()鎴栬?font face="Courier New">UISetRadio()鍐沖畾鎸夐挳鏄帹鍏ヨ繕鏄帹鍑?涓嬭竟鐨勪唬鐮佹牴鎹槸鍚︽湁鏂囨湰琚変腑,鏉ヤ嬌鑳紺ut鑿滃崟欏瑰拰宸ュ叿鏉℃寜閽?

BOOL bSelected = GetSelected();
UIEnable(ID_EDIT_CUT, bSelected);


浣犲彲浠ユ妸榪欐牱鐨勪唬鐮佹斁鍏?span lang="zh-cn">鐩稿簲澶勭悊鍑芥暟涓?濡備竴涓彍鍗曢」鐨勭姸鎬?/span>渚濊禆浜庡彟涓涓彍鍗曢」鐨勫姩浣?span lang="zh-cn">,灝嗗畠鏀懼叆鍚庤呯殑澶勭悊鍑芥暟涓?/span>),鎴栬呮斁鍏?font face="Courier New">OnIdle()鏂規硶,閫氳繃媯鏌ユ煇涓被鍙橀噺鏉ュ喅瀹氬厓浠剁殑鐘舵?

鍏舵鏄‘瀹氬悇涓猆I鍏冧歡鏄惁閮借鏇存柊浜?涓烘浣犻渶瑕佽皟鐢?font face="Courier New">CUpdateUI<>鐨勬煇涓?/span>鏂規硶灝?/span>UI鍏冧歡鍔犲叆鍒板垪琛ㄤ腑.涓昏彍鍗曞凡琚?/span>鑷姩鍔犲叆,浣嗘槸鍏朵粬鐨勪換浣曡彍鍗曞拰鎵鏈夌殑宸ュ叿鏉″繀欏誨垎鍒氳繃璋冪敤UIAddMenuBar()鍜?b>UIAddToolBar()鎵嬪姩鍔犲叆.

鍏朵粬榪樻湁涓鍫嗕簨鎯呰娉ㄦ剰. 棣栧厛,璁劇疆浜嗗伐鍏鋒潯鐨勭姸鎬佸悗,浣跨敤UIUpdateToolBar()浠ヤ嬌宸ュ叿鏉$姸鎬佹洿鏂? 瀵逛簬鑿滃崟,浣犱笉闇濡傛,鍥犱負瀛愯彍鍗曟槸鍔ㄦ佺敓鎴愮殑.UIUpdateMenuBar()榪欎釜鏂規硶涔熷瓨鍦?浣嗘槸瀹?span lang="zh-cn">鐨勪綔鐢?/span>鏄妸鑿滃崟鎭㈠鍒板垵濮嬬姸鎬?濡傛灉浣犳敼鍙樿繃鏌愪簺欏圭殑鏂囧瓧,璋冪敤UIUpdateMenuBar()鐨勭粨鏋滃彲鑳戒笉鏄綘鎵鏈熸湜鐨?鍥犱負鑿滃崟欏圭殑鏂囧瓧浼氬彉鎴?span lang="zh-cn">鑰?/span>鐨?.

灝界榪樻湁涓涓柟娉?b>UISetRadio(),浣嗘槸榪?/span>娌℃湁涓涓妸鍑犱釜鑿滃崟欏規垨鑰呭伐鍏鋒潯鎸夐挳褰撳仛radio鎸夐挳緇?涔熷氨鏄,鏈変竴涓屼笖鍙湁涓涓閫変腑)鐨勬満鍒?濡傛灉浣犲笇鏈涘緱鍒拌繖鏍?span lang="zh-cn">鏁堟灉,浣犲繀欏昏嚜宸辯紪鐮?涓嶈繃瀹冨茍涓嶉毦.

瀵硅瘽妗?/font>

ATL鐨勫璇濇鏀寔涓鍚戝緢濂?瀵規WTL鏂板浜嗛氱敤瀵硅瘽妗嗙殑灝佽. 鏈川涓婃槸涓哄璇濇鍔犲叆浜嗚緭鍏ラ獙璇佸拰鍥炶皟鍑芥暟. 姣斿, 浣犳兂鍦?/span>鐢ㄦ埛鏀瑰彉騫碠pen瀵硅瘽妗嗕腑鐨勬枃浠跺す鏃舵湁鎵鍔ㄤ綔,閭d箞浣犲簲璇ヤ粠CFileDialogImpl<>緇ф壙涓涓被,瀹炵幇OnFolderChange():

class CMyFileDialog : public CFileDialogImpl<CMyFileDialog>
{
public:
聽聽聽 CMyFileDialog(BOOL b)
聽聽聽聽聽聽聽 : CFileDialogImpl<CMyFileDialog>(b) { }
聽聽聽 void OnFolderChange(LPOFNOTIFY lpon)
聽聽聽 {
聽聽聽聽聽聽聽 char strFolder[MAX_PATH];
聽聽聽聽聽聽聽 if (GetFolderPath(strFolder, sizeof(strFolder)) > 0)
聽聽聽聽聽聽聽 {
聽聽聽聽聽聽聽聽聽聽聽 MessageBox(strFolder);
聽聽聽聽聽聽聽 }
聽聽聽 }
};

褰撴枃浠跺す鐨勮礬寰勬敼鍙樻椂,CFileDialogImpl<>璋冪敤OnFolderChange().璇ュ嚱鏁頒嬌鐢ㄥ熀綾葷殑GetFolderPath(),鏉ュ彇寰楁柊璺緞.

鎺т歡

WTL涓烘墍鏈夌殑Win32鍜岄氱敤鎺т歡鎻愪緵浜嗗皝瑁呯被,鍖呮嫭Windows 2000鏂板姞鍏ョ殑. 铏界劧鍙槸綆鍗曠殑鍖呰錛屼絾鏄畠浠嬌榪欎簺鎺т歡鏇村姞瀹規槗璁塊棶.璀錛屼綘鑳借娓呮浠嶭ist View璇誨嚭褰撳墠閫夊畾欏圭殑鏂囧瓧鐨勬秷鎭拰闇瑕佷紶鐨勫弬鏁板悧錛?瀹為檯涓? 浣犻渶瑕佸彂閫佷袱涓秷鎭? 涓涓槸寰楀埌閫夊畾欏圭殑绱㈠紩錛屽彟涓涓槸璇誨嚭瀹冪殑鏂囧瓧.) WTL鐨勪綔鑰?span lang="zh-cn">涓轟綘瀹屾垚浜嗚繖浜涚儲浜虹殑宸ヤ綔, 鎻愪緵浜嗕竴涓畝鍗曠殑灝佽鍑芥暟渚涗綘浣跨敤.

浣跨敤榪欎簺鎺т歡綾繪湁涓ょ鏂規硶. 濡傛灉浣犵殑瀵硅瘽妗嗛噷鏈変竴涓帶浠? 浣犲彲浠ュ皢鎺т歡鐨?font face="Courier New">HWND
渚濋檮鍒頒竴涓皝瑁呭璞?浣跨敤灝佽綾葷殑鏂規硶鏉ヨ闂帶浠?span lang="zh-cn">.榪欑鏂規硶綆鍖栦簡浣犺鍐欐帶浠舵暟鎹拰澶勭悊notification娑堟伅鐨勪唬鐮?

鍙﹀鐨勭敤娉曟槸鎶婅繖浜涚被鍔犲埌浣犵殑瑙嗗浘綾葷殑緇ф壙灞傛涓幓:

class CMyView : public CWindowImpl<CMyView, CListBox>

榪欒〃紺?font face="Courier New">CWindowImpl<>鏄?font face="瀹嬩綋">浠?/span>CListBox緇ф壙鑰屾潵,鍥犳鍒涘緩鐨勭獥鍙e皢鏄竴涓猯ist box (鍥犱負紿楀彛綾葷殑鍚嶅瓧鏄氳繃璋冪敤
CListBox::GetWndClassName()寰楀埌鐨?/span>). 鍙﹀, ATL鐨勭獥鍙f満鍒朵細瀛愮被鍖栬繖涓獥鍙?灝嗗彂緇欏畠鐨勬秷鎭礬鐢卞埌浣犵殑娑堟伅鏄犲皠涓幓. 瀹冧繚鐣欎簡鑰佺殑紿楀彛鍑芥暟,榪欐牱,浣犳病鏈夊鐞嗙殑娑堟伅灝嗙敱鑰佺殑紿楀彛鍑芥暟鏉ュ鐞?褰撲綘鐨勮鍥劇被浠庢帶浠剁被緇ф壙鏃?WTL灝變細浣跨敤榪欎竴鎶鏈?

鍦╪otification娑堟伅鍜屽瓙綾誨寲榪欎釜涓婚涓?鏈変竴鐐瑰緢鍊煎緱鎸囧嚭,閭e氨鏄綋鏌?/span>浜嬩歡鍙戠敓鏃?緇濆ぇ澶氭暟紿楀彛鎺т歡閮戒細鍙戦乶otification娑堟伅緇欏畠浠殑鐖剁獥鍙?璁╀綘紿楀彛鏉ュ鐞嗚繖浜?font face="Courier New">notification娑堟伅瑕佹瘮瀛愮被鍖栦竴涓凡瀛樺湪鎺т歡紿楀彛(鎴栧瓙綾誨寲涓涓凡瀛樺湪鐨勭被,鐒跺悗寤虹珛涓涓疄渚?,浠庤屽湪鎺т歡涔嬪墠鍙栧緱娑堟伅濂藉緱澶? 璀, 浣犳兂澶勭悊鎸夐挳鐨刢lick浜嬩歡,浣犳墍闇瑕佸仛鐨勫彧鏄鐞?font face="Courier New">BN_CLICKEDnotification.瀹冨皢鐢辨寜閽彂閫佺粰浣犵殑紿楀彛綾?鍙﹀鐨勪竴縐嶆柟娉曟槸浠?b>CContainedWindow<>瀛愮被鍖朆UTTON紿楀彛鏉ュ鐞?b>click娑堟伅.

鎴?span lang="zh-cn">涔嬫墍浠?/span>璇磋繖涓槸鍥犱負涓涓煡鍚嶇殑ATL榧撳惞鑰呯粰鎴戜竴浠戒唬鐮侀噷灝辨槸榪欎箞鍋氱殑.浠栫殑浠g爜鍙栧緱涓涓畝鍗曠殑鎸夐挳click浜嬩歡鎵鑺辯殑鏃墮棿鏄埆浜虹殑3鍒?鍊?鍥犱負浠栧瓙綾誨寲浜嗘寜閽帶浠?鑰屼笉鏄畝鍗曠殑澶勭悊BN_CLICKEDnotification.

WTL榪樻彁渚涗簡涓浜涙柊鐨勬帶浠?鍦╳in32涓病鏈夊絳夎? 浣犲凡緇忕湅鍒拌繃涓涓?span lang="zh-cn"> --
command bar, 瀹為檯涓婅繕鏈夊叾浠栦竴浜涢潪甯告湁鐢ㄧ被:

綾?/span> 聽聽 鎻忚堪
CBitmapButton 榪欐槸涓涓敤浣嶅浘鏇夸唬鏍囬鐨勬寜閽?浣犲彲浠ユ彁渚涗竴涓?/span>image list,閲岃竟鍖呭惈鎸夐挳鍦ㄦ甯哥姸鎬?澶辨晥, 鎺ㄥ叆鍜岄紶鏍囪惤鍦ㄦ寜閽笂鐨勫浘琛?/span>.
CHyperLink 璁╀綘寤虹珛涓涓猻tatic鎺т歡,瀹冧唬琛ㄤ竴涓?/span>hyperlink,榪欐牱褰撶敤鎴風偣鍑誨畠鏃?榛樿鐨剋eb嫻忚鍣ㄦ墦寮璇ラ摼鎺?/span>.
CWaitCursor 榪欎笉榪囨槸鍦ㄥ畠鐨勬瀯閫犲嚱鏁頒腑鎶婇紶鏍囧浘鏍囨敼鎴愮瓑寰呯姸鎬?鑰屽湪鏋愭瀯鍑芥暟涓繕鍘?/span>.
CCheckListViewCtrl 鍦ㄦ瘡涓欏硅竟涓婇兘鏈変竴涓猚heck box鐨?/span>list box.
CMultiPaneStatusBarCtrl 鍏鋒湁澶氫釜pane鐨勭姸鎬佹潯



鏉? 2007-01-18 09:49 鍙戣〃璇勮
]]>
鍦╒C8.0涓嬪畨瑁卋oost鍑洪敊http://www.shnenglu.com/eday/archive/2006/11/07/14764.html鏉?鏉?Mon, 06 Nov 2006 17:25:00 GMThttp://www.shnenglu.com/eday/archive/2006/11/07/14764.htmlMakDir1 bin
spawn: no such file or directory

鍦ㄧ綉涓婃壘浜嗗緢澶氳祫鏂欙紝鍐呭鍒版槸鎸哄錛屼絾榪樻槸娌¤兘瑙e喅璇ラ棶棰橈紝閮侀椃浜嗕竴澶╋紝娌″姙娉曞啀鎵撅紝緇堜簬鍦ㄥ浗澶栫殑涓涓綉绔欙紙http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl?InstallingBoost%20?錛変笂鎵懼埌浜嗙瓟妗堬紝鑰屼笖鏂規硶寰堢畝鍗曪細
涓嶇敤璁劇疆鍦ㄧ幆澧冨彉閲忛噷娣誨姞 bjam 鐨勮礬寰勶紝鐩存帴鎶婄紪璇戝ソ鐨?bjam.exe 鎷瘋礉鍒?\boost_1_33_1 鐩綍涓嬶紝鐒跺悗鍦ㄦ帶鍒跺彴鎵ц:
   bjam.exe "-sVC80_ROOT=C:\Program Files\Microsoft Visual Studio 8\VC" -sTOOLS=vc-8_0 install

瀹夎鎴愬姛!

鑷充簬涔嬪墠涓轟粈涔堜細澶辮觸錛屾垜涔熸噿寰楀幓鐮旂┒浜嗐?

鏉? 2006-11-07 01:25 鍙戣〃璇勮
]]>
青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            欧美日韩亚洲一区二区三区四区| 欧美日韩蜜桃| 国产精品一区二区久久精品| 一本一本久久a久久精品综合妖精| 欧美成人伊人久久综合网| 久久九九久精品国产免费直播 | 麻豆freexxxx性91精品| 亚洲欧美在线看| 国产麻豆综合| 久久久精品网| 久久综合狠狠综合久久综青草| 韩日午夜在线资源一区二区| 巨乳诱惑日韩免费av| 麻豆久久久9性大片| 亚洲区在线播放| 99国产精品久久| 国产精品毛片a∨一区二区三区|国| 亚洲欧美日韩高清| 午夜伦欧美伦电影理论片| 激情久久久久久久| 亚洲成人在线视频播放| 亚洲国产精品123| 亚洲第一天堂无码专区| 欧美a一区二区| 亚洲一区在线直播| 欧美一区日韩一区| 亚洲精品免费一二三区| 99精品国产在热久久| 国产区精品在线观看| 免费看亚洲片| 欧美日韩国产精品一区| 久久高清国产| 欧美.www| 久久xxxx| 欧美精品国产| 久久福利视频导航| 欧美日韩1区2区| 久久精品国产免费观看| 欧美精品自拍| 久久久国产一区二区三区| 欧美激情一区二区三区在线视频观看| 亚洲午夜电影| 毛片精品免费在线观看| 久久www成人_看片免费不卡| 欧美精品1区2区| 久久久五月婷婷| 国产精品高清在线观看| 亚洲第一在线综合在线| 国产亚洲毛片在线| 亚洲视频在线一区| 一区二区高清在线| 久久久中精品2020中文| 午夜视频一区| 欧美午夜精彩| 亚洲人人精品| 亚洲激情在线观看视频免费| 欧美在线1区| 久久成人18免费网站| 欧美日韩亚洲一区二区三区在线 | 亚洲一区中文字幕在线观看| 美女国产一区| 久久综合伊人77777蜜臀| 国产精品久久影院| 99热免费精品在线观看| 夜夜夜久久久| 欧美刺激午夜性久久久久久久| 老司机一区二区三区| 国产毛片一区| 欧美一区二区成人| 欧美一区二区黄| 国产精品一级二级三级| 在线亚洲欧美视频| 一本色道久久综合| 欧美日韩国产成人高清视频| 亚洲国产精品精华液2区45| 亚洲全部视频| 欧美顶级大胆免费视频| 欧美韩日一区二区三区| 狠狠操狠狠色综合网| 久久国产66| 久久最新视频| 亚洲国内高清视频| 模特精品裸拍一区| 亚洲精品综合在线| 亚洲伊人一本大道中文字幕| 国产精品久久久久久久7电影| 宅男精品视频| 久久国产黑丝| 亚洲二区在线观看| 欧美国产精品一区| 亚洲免费高清视频| 亚洲欧美日韩天堂| 国产丝袜一区二区三区| 久久国产高清| 欧美激情 亚洲a∨综合| 99国产欧美久久久精品| 国产精品久久久久影院亚瑟| 西瓜成人精品人成网站| 美女成人午夜| 亚洲午夜国产成人av电影男同| 国产精品第一页第二页第三页| 小处雏高清一区二区三区| 榴莲视频成人在线观看| 99re6热只有精品免费观看 | 男人的天堂亚洲在线| 日韩一区二区电影网| 久久av一区二区三区| 亚洲国产你懂的| 国产精品拍天天在线| 久久先锋资源| 亚洲一区在线播放| 欧美+日本+国产+在线a∨观看| 一区二区免费在线播放| 国内精品亚洲| 欧美日韩xxxxx| 久久成人国产| 在线亚洲精品福利网址导航| 免费美女久久99| 午夜激情综合网| 91久久国产综合久久91精品网站| 欧美午夜精品久久久| 欧美gay视频| 欧美尤物巨大精品爽| 99re热精品| 欧美a级在线| 久久本道综合色狠狠五月| 亚洲看片一区| 亚洲国产精品黑人久久久| 国产精品一区二区久久久| 欧美日本韩国一区| 久久综合久色欧美综合狠狠| 亚洲欧美日韩综合aⅴ视频| 99视频一区| 亚洲经典自拍| 欧美电影美腿模特1979在线看| 欧美制服第一页| 亚洲资源av| 日韩一二三在线视频播| 亚洲国产经典视频| 影音先锋欧美精品| 国产一区亚洲| 国产色产综合产在线视频| 国产精品久久国产精麻豆99网站| 免费在线看成人av| 久久亚洲精品一区二区| 久久久久久婷| 久久久综合网站| 久久久久久久999| 欧美一区二区视频97| 欧美亚洲综合另类| 亚洲欧美日韩精品综合在线观看| 亚洲精品一区在线观看香蕉| 亚洲人成77777在线观看网| 欧美大片国产精品| 欧美激情性爽国产精品17p| 免费成人小视频| 蜜桃av综合| 亚洲大胆在线| 91久久精品一区二区三区| 最新中文字幕亚洲| 亚洲精品日日夜夜| 99视频精品免费观看| 亚洲视频欧洲视频| 午夜日本精品| 久久精品一区二区| 牛牛影视久久网| 欧美日韩精品欧美日韩精品| 欧美午夜视频一区二区| 国产亚洲精品aa| 一色屋精品亚洲香蕉网站| 亚洲人成在线播放网站岛国| 日韩小视频在线观看| 在线视频日韩| 久久成人精品一区二区三区| 久久久久久一区二区三区| 欧美成人午夜激情在线| 亚洲精品在线观看免费| 亚洲一区二区少妇| 久久久亚洲综合| 欧美日韩亚洲天堂| 国产婷婷色一区二区三区| 亚洲国产成人在线视频| 国产精品99久久久久久人| 久久国产欧美精品| 亚洲电影在线播放| 亚洲一区二区三区高清| 久久理论片午夜琪琪电影网| 欧美精品在线视频观看| 国产精品日韩精品欧美在线 | 欧美伦理一区二区| 国产精品私拍pans大尺度在线| 激情六月婷婷综合| 一本一本久久| 久久久久综合网| 亚洲精品美女在线观看| 性久久久久久久久| 欧美精品一区二区三区很污很色的| 国产精品亚洲一区二区三区在线| 亚洲国产日韩欧美在线动漫| 亚洲伊人网站|