From 4b024dd388aa3310fc63f947614468cf947b64c6 Mon Sep 17 00:00:00 2001 From: DreamSourceLab Date: Mon, 25 May 2015 16:47:33 +0800 Subject: [PATCH] add language support --- DSView/DSView.qrc | 15 +++++++++++ DSView/icons/file_cn.png | Bin 0 -> 1362 bytes DSView/icons/file_dis_cn.png | Bin 0 -> 1224 bytes DSView/icons/instant_cn.png | Bin 0 -> 1262 bytes DSView/icons/measure_cn.png | Bin 0 -> 1316 bytes DSView/icons/measure_dis_cn.png | Bin 0 -> 1414 bytes DSView/icons/params_cn.png | Bin 0 -> 1388 bytes DSView/icons/params_dis_cn.png | Bin 0 -> 1619 bytes DSView/icons/protocol_cn.png | Bin 0 -> 1243 bytes DSView/icons/protocol_dis_cn.png | Bin 0 -> 1454 bytes DSView/icons/search-bar_cn.png | Bin 0 -> 1580 bytes DSView/icons/search-bar_dis_cn.png | Bin 0 -> 1888 bytes DSView/icons/start_cn.png | Bin 0 -> 1401 bytes DSView/icons/stop_cn.png | Bin 0 -> 830 bytes DSView/icons/trigger_cn.png | Bin 0 -> 1141 bytes DSView/icons/trigger_dis_cn.png | Bin 0 -> 1453 bytes DSView/main.cpp | 19 +++++++++++--- DSView/pv/dialogs/deviceoptions.cpp | 8 +++--- DSView/pv/dialogs/search.cpp | 4 +-- DSView/pv/dialogs/streamoptions.cpp | 8 +++--- DSView/pv/dialogs/waitingdialog.cpp | 2 +- DSView/pv/dock/dsotriggerdock.cpp | 32 +++++++++++------------ DSView/pv/dock/measuredock.cpp | 38 ++++++++++++++-------------- DSView/pv/dock/protocoldock.cpp | 8 +++--- DSView/pv/dock/searchdock.cpp | 24 +++++++++--------- DSView/pv/dock/triggerdock.cpp | 22 ++++++++-------- DSView/pv/mainwindow.cpp | 8 +++--- DSView/pv/toolbars/filebar.cpp | 21 ++++++++++----- DSView/pv/toolbars/samplingbar.cpp | 26 +++++++++++++++---- DSView/pv/toolbars/trigbar.cpp | 33 ++++++++++++++++++++++++ DSView/pv/view/dsosignal.cpp | 14 +++++----- DSView/pv/view/viewport.cpp | 8 +++--- 32 files changed, 187 insertions(+), 103 deletions(-) create mode 100644 DSView/icons/file_cn.png create mode 100644 DSView/icons/file_dis_cn.png create mode 100644 DSView/icons/instant_cn.png create mode 100644 DSView/icons/measure_cn.png create mode 100644 DSView/icons/measure_dis_cn.png create mode 100644 DSView/icons/params_cn.png create mode 100644 DSView/icons/params_dis_cn.png create mode 100644 DSView/icons/protocol_cn.png create mode 100644 DSView/icons/protocol_dis_cn.png create mode 100644 DSView/icons/search-bar_cn.png create mode 100644 DSView/icons/search-bar_dis_cn.png create mode 100644 DSView/icons/start_cn.png create mode 100644 DSView/icons/stop_cn.png create mode 100644 DSView/icons/trigger_cn.png create mode 100644 DSView/icons/trigger_dis_cn.png diff --git a/DSView/DSView.qrc b/DSView/DSView.qrc index bf8d2d0c..00b550b7 100644 --- a/DSView/DSView.qrc +++ b/DSView/DSView.qrc @@ -36,5 +36,20 @@ icons/gear.png icons/wiki.png icons/wait.gif + icons/file_cn.png + icons/file_dis_cn.png + icons/instant_cn.png + icons/measure_cn.png + icons/measure_dis_cn.png + icons/params_cn.png + icons/params_dis_cn.png + icons/protocol_dis_cn.png + icons/search-bar_cn.png + icons/search-bar_dis_cn.png + icons/start_cn.png + icons/stop_cn.png + icons/trigger_cn.png + icons/trigger_dis_cn.png + icons/protocol_cn.png diff --git a/DSView/icons/file_cn.png b/DSView/icons/file_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..00096c509581fc2426e123cf58cdef3c27234a65 GIT binary patch literal 1362 zcmXw(2~g5m7{DK(sFWaOO5zok$7&mCZR+ZJ{Z+I9jhxk-B3%Qe5?I8{Rl#oTGIv2& zOHDVmY_&u37&WtOJR-F`YCYS5h&IJr$};y)O*8L%-^}m(ec#NRdGBR~(}ImL78n44 zaR>#X!Y@UG4<$$$D8|+|?(eVH-FO|=ZPY{5=adJ z!{)?;2Sku&{FC-8U_Oo0!Pt2*9E|w*_Wsofg3s9A<*+n&%Dx=vjq8 zeh~@BCZk#o5#tHMv8j1Q|97r$+RUuai|(0Dl*z2U%(kr`(sYI=I9YkgtcF@e0d9n7 zHJze1aa>=>Ss$$~(8E|OhbChr;;y?FlBJv9&fm96cM$zlZ2CbX$Cnyh{HST3(iFW} zUdULJWyoM&zh(qIruaT57*Q;4ka1g+Sn=_1gcW@aRS_Z^S#*{8Q`THsS%0>(vvY9C z9;~k;0$h5^+Uo5++Q?!#mia>7!!t885zUPKZq%AxHwT2Vs+C2pHY_hU*WF?=Dg4jm z%zU@Bv^1@Qg9G=+i>TpRSb`^Pk*~#z4aI8N@MJBGMza<)jv7BAAIZ(ji^JnRk=7D= z#{pMIvvUL@5tX@W7q7iMaTs33?iUqGeuE7bhfCS~BYP%9 ze)@qGRMB^gUEo1lnwX!T-^pSm)D4%ULX`*+Mjx-eD)GNLa9rVD$9tSYj|KIdh!Js|!+k$7_DhtYfXTo_^yh zsNpUp#+oc}r6RBmH2Gw9G=eeoGz6*kwx;}*9@#F{BhQs5fZIEv-Ox7un8=oj zK<0oq7es9;^~&^7tReSfT`A&soxighB{Y(2kG!Y3L1^$^Z~xgY^2o#T-hdZ>+$@+p z^kOmG?zSq(0H}V=J(w*PL&_X+6S(aQU6U-?ug(caiq$x+B4zKEJdkcn>H(iBsTsk< zFjPH)8e?hb{E7>3;)GC0gLvQFyii52tfp>0q!^ddcSz_yXOtG_$=kt|x^_R0iSEXC zgAc-%XU8)>JGqTFxz-sXL**mtzSQG-lJv#AYSasQ8zX*0X*&=mt(wghd)bxZPINFF zs++LjrT%o=q@@ia6P_>mEezry-k%d&RDq+xUk3;Yq(RmG HF~|Q0GjCVq literal 0 HcmV?d00001 diff --git a/DSView/icons/file_dis_cn.png b/DSView/icons/file_dis_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..b6e24584d2bed42577493c96ca1c70cc01f42a92 GIT binary patch literal 1224 zcmeAS@N?(olHy`uVBq!ia0vp^1|ZDA1|-9oezpTC&H|6fVg?4jBOuH;Rhv&5D9B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`>Hq)$ literal 0 HcmV?d00001 diff --git a/DSView/icons/instant_cn.png b/DSView/icons/instant_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..0e5860945bdcd8295e5349b56df5d1b62eb57f15 GIT binary patch literal 1262 zcmXxje>~H990%~vjAOJdg?dCxQ#zG-a4Y$7P0a19g-S*U$HopD^YuWkTGCzD4l|*h zN>`^Nl8b0vw7R0zI%~&6n#ZPV(H=Ew9ye*jeb+tikN4;O_&ndQ&*$;@{PFoAHu@{9 z{Th1!02ZP}>_xhtrR+XKR)*F5_ejI!(-I2-z}>eLs%{g`6+v4V+D*09*f`_2kvbiX zqo0VH0EZR9*<2oI?U2(DS_UH&!7R++vGZXzmjhN}Jc)?gTRfbbU&>==Wy7EyFAqW# z_epuobW4-~v-6mMJcq|16O3iDkIRCK(|JsglD}k$JAAsFU6_%ZjzoE&SK3{Tu$_e& z={ydblLe%%la?pg{&&8Jm%#-8EFFLIe=MAvm&fG5z$mZ3gV<-5SR5P9WrCJzr8fX* z2^0|)mwim1FqD(Le|4y4*Lk)~n6`}WQxheP-P7splQ`^=@G>ggB~j;9Lz7>;G%U-# z=-}*m%ny5lLJ%ZYI5}Py5?)`%9vJ=nBR;~q^6S_EdiGDxw+~V^6K?{cEOpsSFBq4s zmiKA;G}|=`>V^086;=Lc53RHle8)d@$@79byW_zHfk5DmI%}oS?$3*+)4xr1NEJG< zbu%;DL^C3Dr8f1T#6LJ#<#dAtk;N!90bFId%$8>!Jgf~g%uvE9eU1r~5O=PxlYN%I zn4TqEM5EE1pJPk5*3d%SPNSFa8`<1~&BJsEW{(dL$xB8(^4eh2RdHRXbXpDKXIZkbI zjO2sy({X-X8v=4{{M0H{lJscSixLK7vinsrqkephZs)+G2N4kMTfpaj)y-M#qnvMN!Ss`swK-y9`y;Zjf?GGiSodT-(~( zNRb6Dr?eC@nOsz_ExL1Zfx2R^il0kqo9Ed(t0C4Xzp z$B3rzov!47T3E*DCF-1^OX-1e>-m`j9^`-|D-a+MkBx{<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z&nl0o^nU?(TxmA| literal 0 HcmV?d00001 diff --git a/DSView/icons/params_dis_cn.png b/DSView/icons/params_dis_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..fcb8a6115a2f9bab5859f2a4023ee9e55595a4de GIT binary patch literal 1619 zcmXw(dpOg39LIk%Y;)V{7>!&ysx`Oiap#mfLoUg^FlMv4ZOzXm`rj@ zlT;IF;PR3)Najnvq#ziCkR$+5;YkBIXP}}ffiTeB%LVpI4vn-l#BI5r@DsTNgAU0c zmCgieIedZyDS;B?Oim&(X$+7?PXvBLY}1o)1u1u;GmbE6F;oy}K=N%QROKgSk|U+6 zE=Wrt1Lo^UgrtLzb`H=fU}_|j41_T@q`KnI;j|=De56EW0`1(^GZGA!;-E-oA}uin z;A+lFSAhM0Kbc7)1D`f>7k_C^^n?U*A_%PU&)=0Wd8y`41LMg+&C+8m0LW>(J3IJO zbKYN!h*u3z?fcWTWio8wsl1q2}dRSIx2i)9n4Qg1K%h4Ki$SB^Lrq28ZgO0iANyoj+eJUD(yj@_5l zKl{>pz0`E>_WJXrGl;T`8A#0DkyN)VDwpZSL?H z)UBXQMpbTf#` zE9Pqr7PigpIrMBJbmvLW+O{Rm(nJ?( z`XGQK2W4Aj6AeVeZ{5aQo*}xX9`ftd#x{Lg?SV`K3zNLpjwkGZYpgk$@r?e!>X4zD zc7=e&2<61`SNJNkYh}hYvX&oZh9i6K4<~ZsVlz&S`RKU|MXzxSNqf(;oeV^t27-DyB z+F-MH1~?3zgUQSPFjFF3Cx>XPkloxKEQf#X$wzKf((kF)j?m zSj3F53w!&AlMV8HVoZCT&f)yEhGXA~-2qGG?|oDE)pIVDK7H`vWR|bj?D2Pl(OdK8 z9oI#o$~`?n4{2eVVV4J$mhf@KExs>x%+gkF!KVAcAj50RfXQ^h1;5&0&tPo+runuR z$@1qqyUR=0PT35;1zT!^tK+6BjBQ$DEZP0_LoFdV&oGL*YVxKn!{}7p>Q1BP4@CAo z_=x{r3daIH$f2gSW;PxREWBBq{t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z+0Wx9U-Ls0RNy-!H5?Z>$D;|Ae?{3Lot|C)5r3T(4uZ0VW3Knv5TS3cq(Mtgn~?aU zOx#3C15uXWkcfjSI(f4)qE3oeq}`}n{5xDIOsU^fMHsU2T@Nsu_)OE-l)ARi$cfhC zw9;+&UnQITE(J3)c5Zge?@}Ht$2Ujc2($)ar&!L~9-u1d(1Jm~-|7}<#B<$~-*D~l zt@b&87`LW1O;0f(w>b#CKl5tZry?GX4|N zkWp00%DFh1ac5%8l5GRmpU;4Cv{qH(-892B98bL1ldsN}a4$%QNC8IZb$3vLPtpys z$1|9F?>v4OOYx~Pv#n`HWW`Xj?vi?9H2;sG z5+D)2z^^cuic!*|uLLN#ao2V|ZBcpC#%#D~CKVng6w!|iI61i3bC3Zy{{ty3 Bmcjr4 literal 0 HcmV?d00001 diff --git a/DSView/icons/search-bar_cn.png b/DSView/icons/search-bar_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..b8a249e4352d7a09d6742fc7489dac78701cd31b GIT binary patch literal 1580 zcmXxkc|6o<90%~9agO`eGFrzVw_fW=x-gSD9Jyj7M`JMM7-Os&jbo!!YM4;MI-*EB zNyb^tlw(+fWOBtKSJsh5BS+27w6Fc+`+Q%o_xJNWujl#axqiysMNV2%8UO$}Bm(9o z=vKm#k`SzZpzUjd1|}dd@c;)e*;TEO1kCFO{7oz|Eys^@8bU3+Xac`pduan7BX$$<% z8<$>9F6>fPb2FzrPkNPu+ixU@T<>g2h3Oj%$?;YvT7P1l2C4z65KUGuolYP1-wFbk zt7jJ$w(2@KIMh6Uz99$ni(ZsY1&8coJ?-u7JwC+c?(H}F9qkN@x?5CKWG*Ty>VgO| zymZDaWM8A};3k8?SfPfeICStpcY7EIRi!CT>sJl6^z2WpN6;pqd|mrT?C-}YJ0!<| zfPnS$;Mx_ZNAAVs?rB0(o|i{vmo{^fpMXZAWl~K6+wick7eyr{!SXEe5El%l;DdFq zDX{Z#`AF!9FGN=2IJM~}{{H0r>}=HY+gew1NWA6Iv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sWkPYF=SCAB!YD6^m>Ge3_(m{U<1 zD9!~Ecg`=UEXqvJC}CK`f5r+Z$_ExLN=*bQRVc~KO=U3s&d&*y;RMM9=ckpFCl;kL z#1{MqDdz?oo>`onlL%B=#IXIqmVTfx2S_+Pu_!MyFP-6l^fQnb*dh8$i;`0rzW#51 z4O8ZvpPQSSSHke^%(VSLF*cC0kj#>tRE8DrE~zsxFmZaiIEG|2zMZ+hE7(!w*#7ql zw_ZePXhcUvab!=-vKC}omk^hr8>8X7=|yBH<~+CekTTcK zD752#KlSu3mG9?bB$z%oXX?!~eqNr=XI$>&8Ii72%Cs@1@d^aRaJ;?o`m5QlyYFNf z#FdZzx0UO^&)s|yz#uU zOM>(PQ3hGj2{n8SD)H0K-}!st?)t40pBPDTig4O8f8abYZ^`0CvFVLVCN5EC_Z&lEqVFTKVdvYmbNlDDJvSicFB5`?VfVx zy}{LNXL9^LZC#SjpvPRXT6N7TM$g4XH)q~V^Z3-u!qD)9o8j{3Nh_2xMJD-hEL?t( zwP86!+|<(xx|XmuxVs9n-;cYl_^kTDjWcGA^zTuT-nwhGu_fL7pO}912 zJfd!{0(vNNfvfczk$3NI-q+LqV(j|=zFnaD_CJo3LBVN%^JPWptV2hufysoy)78&q Iol`;+00qcRwg3PC literal 0 HcmV?d00001 diff --git a/DSView/icons/trigger_cn.png b/DSView/icons/trigger_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..8f98b4dd629ef727038a2e1be09ec920c443df94 GIT binary patch literal 1141 zcmeAS@N?(olHy`uVBq!ia0vp^1|ZDA1|-9oezpTC&H|6fVg?4jBOuH;Rhv&5D9B#o z>FdgVpH-CKTz%iEx~E_v*N76w(vpn)B8HXg&UgTYcuIgmE~&-IMVSR9nfZAP!kmiA zKyfaRxO09%Wl?5&MhU|j{xeoUQ9iI}QEDPcsX|F+ZYqQ6cYaQw3@1n?I6tkVJh3R1 zA-3Q@NI5sy@XX@moJ63~B8Ke;w)6vqIY7eUiA8ytdFc!Xq@RJjzz)%0T9lm1@b!Q5 zYnU?U{M_8syb^|QXQu53im`!|g=CiGq%y2{cS)Urf!V>+#W5tK@$HQB-BUv)j@#ci zm*hOw#m2QWcaPv^BaM~YZths=R7}%eDW7S( z#QQ1HYcvWScj>Dy{x9O*TiE~Z(;xe)SZT;mVUp`oQFE)(4inwJUH6dh4W?x$(lv6#*h!%7YL7)K*%z{C;|NU*yWGXB+S5{6Dkz z^qutwTyG1{E|s5j+kV?D*OdZVySQz2rgZk{?q^=xup5pM+;8u0kUg-pV+K~!PY z1BRZPC#89Rvz&Dz`FDp<&V0Z7`{kRDYiYGz@NtRpdw9t^H!*~7iQVVsh0~7zI*@s7 z_0hG98caQR`thCN{k{DCT}DH7_WtWuOsk$9_`K~r^L?i3;^b+m`nTROz4v_Ob|m#d z?Slz#_cv}=jb*m$>&WzM7e46c;*%Qr&D~Y5JkXSVS>x;j?{_+0S`)tg<*Fq%_VbwI zrkC(p%t*cI|ML}dbwhe?z2ZyOgpH?8Zea^`)>uD>`Qe6T9IE?UJ7#>^n{~&3x5=B^ t-jCOCE;qX4Wvh9c{j9T#_JYhm>^zd^FK*cwWCF}x44$rjF6*2UngD((_3Z!v literal 0 HcmV?d00001 diff --git a/DSView/icons/trigger_dis_cn.png b/DSView/icons/trigger_dis_cn.png new file mode 100644 index 0000000000000000000000000000000000000000..e17bfce7150364663554979b53aaa7a5bc6b77d5 GIT binary patch literal 1453 zcmXw(dpOg39LK-AFveWgWg10WsdE-nlyZdlY0TM`lPE<2XT=EQ&%+Utobj#hIQPHYmF9TCX`)%tQf71jGexh#g- zYQ|$nv%q$xzP3uyRx3W7L%akAmj!}jm(_NiAH&)4%qWJ+$_2M&lCvtTrN;Xh+!%ID z1dtgk)KB;k&4%p3+!_J>&2ya|X`U!@@Fv3u2kw#x$0q`V zfPd?&sVpLq_`qdm8YE(G;0V*YhEil$hVU6o7nV2?w@V)kykl7wP-zGwO+i`%*`PPc za6!f&GUW#^!(?Uxj%(RKeLR$a6}3Ih*x3z@Vg-@>7E0Www=)Y(`EF%k6e&2XKbqV^ z1JODGoD-!=rE&=t3F@ISGJy+|h{Y#6y;A)l{EHY8>ZnE8BvM8uq%Wp6&ww3kAO3q_ z918d7mz)(w*8kKLg0ZopL%t@aruRIceF@eZ+f(V3TU3Hn>mA)R7 zNBkiR@U44VpXStfV0G|d4rJ3QcN7UHl}o#I!W3d*aa4WwcH-!J^PS_V4xy(Zf~CMf z(Cgn-;a&AT-Q{Js))(y4z4iL9L5POI8Y3g4g9-OmLFCGg5o;KpGitKZK&TmV=W+xdU@>AgET#p z4JW|oJV6wq1l6o9J8Oytl9@iWUV+mGl|9H}%;7(SG>WIQtT-2EBY~bti)U$4-Cp@am>WE$NY)tUgpcXH*ii#4O@QYkn&Cq2r6w~^$~h5_)mtR8 zgEUXl)cLmJ?d7J_&MM|g-D4Z;cV{?#<#zwIw)qb3G$nL^b2S3Zy6opLqTF0y9-vbe zwA=2bLYkM(--;gZnnm97=z-_JFga!;f%f@Ect;<1e{s-#|Guw7fd!(1ZK22k#C6;G z#r;>luM@SCQ8rt+m9u!nCNul<%rg?A%m-O_p?1_v&=7Lx(1kP{B6hT)@CD~`-;x8S z_Zi})snpQ;%9RPPq9NnlD%msAIibmyYp96s_knM#d44YQN1RpBG1liEZ>7{X)iP=< ztQ}|L%#N(l$z-@)4@x;zu4UqCpG1zQU>=6Z(uEJKvQzdvp{RZ(;OaddWidget(search_label, 0, 1); - search_layout->addWidget(new QLabel("Search Value: "), 1,0, Qt::AlignRight); + search_layout->addWidget(new QLabel(tr("Search Value: ")), 1,0, Qt::AlignRight); search_layout->addWidget(&search_lineEdit, 1, 1); search_layout->addWidget(new QLabel(" "), 2,0); - search_layout->addWidget(new QLabel("X: Don't care\n0: Low level\n1: High level\nR: Rising edge\nF: Falling edge\nC: Rising/Falling edge"), 3, 0); + search_layout->addWidget(new QLabel(tr("X: Don't care\n0: Low level\n1: High level\nR: Rising edge\nF: Falling edge\nC: Rising/Falling edge")), 3, 0); search_layout->addWidget(&search_buttonBox, 4, 2); //search_layout->addStretch(1); diff --git a/DSView/pv/dialogs/streamoptions.cpp b/DSView/pv/dialogs/streamoptions.cpp index a56d3b89..610c5beb 100644 --- a/DSView/pv/dialogs/streamoptions.cpp +++ b/DSView/pv/dialogs/streamoptions.cpp @@ -52,17 +52,17 @@ StreamOptions::StreamOptions(QWidget *parent, boost::shared_ptrsetText("Stream Mode Active!"); + _info->setText(tr("Stream Mode Active!")); else - _info->setText("Buffer Mode Active!"); + _info->setText(tr("Buffer Mode Active!")); _layout.addWidget(_info); if (_stream) { _op0 = new QRadioButton(this); _op1 = new QRadioButton(this); - _op0->setText("16 Channels, Max 10MHz sample rate"); - _op1->setText(" 8 Channels, Max 25MHz sample rate"); + _op0->setText(tr("16 Channels, Max 10MHz sample rate")); + _op1->setText(tr(" 8 Channels, Max 25MHz sample rate")); _layout.addWidget(_op0); _layout.addWidget(_op1); diff --git a/DSView/pv/dialogs/waitingdialog.cpp b/DSView/pv/dialogs/waitingdialog.cpp index eb3960c4..8e2b0e52 100644 --- a/DSView/pv/dialogs/waitingdialog.cpp +++ b/DSView/pv/dialogs/waitingdialog.cpp @@ -37,7 +37,7 @@ using namespace std; namespace pv { namespace dialogs { -const QString WaitingDialog::TIPS_INFO = "Waiting"; +const QString WaitingDialog::TIPS_INFO = tr("Waiting"); WaitingDialog::WaitingDialog(QWidget *parent, boost::shared_ptr dev_inst) : QDialog(parent), diff --git a/DSView/pv/dock/dsotriggerdock.cpp b/DSView/pv/dock/dsotriggerdock.cpp index d123691f..357b9d02 100644 --- a/DSView/pv/dock/dsotriggerdock.cpp +++ b/DSView/pv/dock/dsotriggerdock.cpp @@ -45,7 +45,7 @@ DsoTriggerDock::DsoTriggerDock(QWidget *parent, SigSession &session) : QWidget(parent), _session(session) { - QLabel *position_label = new QLabel("Trigger Position: ", this); + QLabel *position_label = new QLabel(tr("Trigger Position: "), this); position_spinBox = new QSpinBox(this); position_spinBox->setRange(0, 99); position_spinBox->setButtonSymbols(QAbstractSpinBox::NoButtons); @@ -55,23 +55,23 @@ DsoTriggerDock::DsoTriggerDock(QWidget *parent, SigSession &session) : connect(position_spinBox, SIGNAL(valueChanged(int)), position_slider, SLOT(setValue(int))); connect(position_slider, SIGNAL(valueChanged(int)), this, SLOT(pos_changed(int))); - QLabel *tSource_labe = new QLabel("Trigger Sources: ", this); - QRadioButton *auto_radioButton = new QRadioButton("Auto"); + QLabel *tSource_labe = new QLabel(tr("Trigger Sources: "), this); + QRadioButton *auto_radioButton = new QRadioButton(tr("Auto")); auto_radioButton->setChecked(true); - QRadioButton *ch0_radioButton = new QRadioButton("Channel 0"); - QRadioButton *ch1_radioButton = new QRadioButton("Channel 1"); - QRadioButton *ch0a1_radioButton = new QRadioButton("Channel 0 && Channel 1"); - QRadioButton *ch0o1_radioButton = new QRadioButton("Channel 0 | Channel 1"); + QRadioButton *ch0_radioButton = new QRadioButton(tr("Channel 0")); + QRadioButton *ch1_radioButton = new QRadioButton(tr("Channel 1")); + QRadioButton *ch0a1_radioButton = new QRadioButton(tr("Channel 0 && Channel 1")); + QRadioButton *ch0o1_radioButton = new QRadioButton(tr("Channel 0 | Channel 1")); connect(auto_radioButton, SIGNAL(clicked()), this, SLOT(source_changed())); connect(ch0_radioButton, SIGNAL(clicked()), this, SLOT(source_changed())); connect(ch1_radioButton, SIGNAL(clicked()), this, SLOT(source_changed())); connect(ch0a1_radioButton, SIGNAL(clicked()), this, SLOT(source_changed())); connect(ch0o1_radioButton, SIGNAL(clicked()), this, SLOT(source_changed())); - QLabel *tType_labe = new QLabel("Trigger Types: ", this); - QRadioButton *rising_radioButton = new QRadioButton("Rising Edge"); + QLabel *tType_labe = new QLabel(tr("Trigger Types: "), this); + QRadioButton *rising_radioButton = new QRadioButton(tr("Rising Edge")); rising_radioButton->setChecked(true); - QRadioButton *falling_radioButton = new QRadioButton("Falling Edge"); + QRadioButton *falling_radioButton = new QRadioButton(tr("Falling Edge")); connect(rising_radioButton, SIGNAL(clicked()), this, SLOT(type_changed())); connect(falling_radioButton, SIGNAL(clicked()), this, SLOT(type_changed())); @@ -141,8 +141,8 @@ void DsoTriggerDock::pos_changed(int pos) g_variant_new_uint16((uint16_t)pos)); if (!ret) { QMessageBox msg(this); - msg.setText("Trigger Setting Issue"); - msg.setInformativeText("Change horiz trigger position failed!"); + msg.setText(tr("Trigger Setting Issue")); + msg.setInformativeText(tr("Change horiz trigger position failed!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -163,8 +163,8 @@ void DsoTriggerDock::source_changed() g_variant_new_byte(id)); if (!ret) { QMessageBox msg(this); - msg.setText("Trigger Setting Issue"); - msg.setInformativeText("Change trigger source failed!"); + msg.setText(tr("Trigger Setting Issue")); + msg.setInformativeText(tr("Change trigger source failed!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -181,8 +181,8 @@ void DsoTriggerDock::type_changed() g_variant_new_byte(id)); if (!ret) { QMessageBox msg(this); - msg.setText("Trigger Setting Issue"); - msg.setInformativeText("Change trigger type failed!"); + msg.setText(tr("Trigger Setting Issue")); + msg.setInformativeText(tr("Change trigger type failed!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); diff --git a/DSView/pv/dock/measuredock.cpp b/DSView/pv/dock/measuredock.cpp index 211acdff..b37dd04a 100644 --- a/DSView/pv/dock/measuredock.cpp +++ b/DSView/pv/dock/measuredock.cpp @@ -52,8 +52,8 @@ MeasureDock::MeasureDock(QWidget *parent, View &view, SigSession &session) : _view(view) { - _mouse_groupBox = new QGroupBox("Mouse measurement", this); - _fen_checkBox = new QCheckBox("Enable floating measurement", this); + _mouse_groupBox = new QGroupBox(tr("Mouse measurement"), this); + _fen_checkBox = new QCheckBox(tr("Enable floating measurement"), this); _fen_checkBox->setChecked(true); _width_label = new QLabel("#####", this); _period_label = new QLabel("#####", this); @@ -62,13 +62,13 @@ MeasureDock::MeasureDock(QWidget *parent, View &view, SigSession &session) : _mouse_layout = new QGridLayout(); _mouse_layout->addWidget(_fen_checkBox, 0, 0, 1, 2); - _mouse_layout->addWidget(new QLabel("Width: ", this), 1, 0); + _mouse_layout->addWidget(new QLabel(tr("Width: "), this), 1, 0); _mouse_layout->addWidget(_width_label, 1, 1); - _mouse_layout->addWidget(new QLabel("Period: ", this), 2, 0); + _mouse_layout->addWidget(new QLabel(tr("Period: "), this), 2, 0); _mouse_layout->addWidget(_period_label, 2, 1); - _mouse_layout->addWidget(new QLabel("Frequency: ", this), 3, 0); + _mouse_layout->addWidget(new QLabel(tr("Frequency: "), this), 3, 0); _mouse_layout->addWidget(_freq_label, 3, 1); - _mouse_layout->addWidget(new QLabel("Duty Cycle: ", this), 4, 0); + _mouse_layout->addWidget(new QLabel(tr("Duty Cycle: "), this), 4, 0); _mouse_layout->addWidget(_duty_label, 4, 1); _mouse_layout->addWidget(new QLabel(this), 0, 2); _mouse_layout->addWidget(new QLabel(this), 1, 2); @@ -79,7 +79,7 @@ MeasureDock::MeasureDock(QWidget *parent, View &view, SigSession &session) : _mouse_groupBox->setLayout(_mouse_layout); - _cursor_groupBox = new QGroupBox("Cursor measurement", this); + _cursor_groupBox = new QGroupBox(tr("Cursor measurement"), this); _t1_comboBox = new QComboBox(this); _t2_comboBox = new QComboBox(this); _t3_comboBox = new QComboBox(this); @@ -94,30 +94,30 @@ MeasureDock::MeasureDock(QWidget *parent, View &view, SigSession &session) : _t3_last_index = 0; _cursor_layout = new QGridLayout(); - _cursor_layout->addWidget(new QLabel("T1: ", this), 0, 0); + _cursor_layout->addWidget(new QLabel(tr("T1: "), this), 0, 0); _cursor_layout->addWidget(_t1_comboBox, 0, 1); - _cursor_layout->addWidget(new QLabel("T2: ", this), 1, 0); + _cursor_layout->addWidget(new QLabel(tr("T2: "), this), 1, 0); _cursor_layout->addWidget(_t2_comboBox, 1, 1); - _cursor_layout->addWidget(new QLabel("T3: ", this), 2, 0); + _cursor_layout->addWidget(new QLabel(tr("T3: "), this), 2, 0); _cursor_layout->addWidget(_t3_comboBox, 2, 1); - _cursor_layout->addWidget(new QLabel("|T2 - T1|: ", this), 3, 0); + _cursor_layout->addWidget(new QLabel(tr("|T2 - T1|: "), this), 3, 0); _cursor_layout->addWidget(_delta_label_t1t2, 3, 1); - _cursor_layout->addWidget(new QLabel("Delta Samples: ", this), 3, 2); + _cursor_layout->addWidget(new QLabel(tr("Delta Samples: "), this), 3, 2); _cursor_layout->addWidget(_cnt_label_t1t2, 3, 3); - _cursor_layout->addWidget(new QLabel("|T3 - T2|: ", this), 4, 0); + _cursor_layout->addWidget(new QLabel(tr("|T3 - T2|: "), this), 4, 0); _cursor_layout->addWidget(_delta_label_t2t3, 4, 1); - _cursor_layout->addWidget(new QLabel("Delta Samples: ", this), 4, 2); + _cursor_layout->addWidget(new QLabel(tr("Delta Samples: "), this), 4, 2); _cursor_layout->addWidget(_cnt_label_t2t3, 4, 3); - _cursor_layout->addWidget(new QLabel("|T3 - T1|: ", this), 5, 0); + _cursor_layout->addWidget(new QLabel(tr("|T3 - T1|: "), this), 5, 0); _cursor_layout->addWidget(_delta_label_t1t3, 5, 1); - _cursor_layout->addWidget(new QLabel("Delta Samples: ", this), 5, 2); + _cursor_layout->addWidget(new QLabel(tr("Delta Samples: "), this), 5, 2); _cursor_layout->addWidget(_cnt_label_t1t3, 5, 3); - _cursor_layout->addWidget(new QLabel("Cursors", this), 6, 0); - _cursor_layout->addWidget(new QLabel("Time/Samples", this), 6, 1); + _cursor_layout->addWidget(new QLabel(tr("Cursors"), this), 6, 0); + _cursor_layout->addWidget(new QLabel(tr("Time/Samples"), this), 6, 1); _cursor_layout->addWidget(new QLabel(this), 0, 4); _cursor_layout->addWidget(new QLabel(this), 1, 4); @@ -185,7 +185,7 @@ void MeasureDock::cursor_update() for(std::list::iterator i = _view.get_cursorList().begin(); i != _view.get_cursorList().end(); i++) { - QString curCursor = "Cursor "+QString::number(index); + QString curCursor = tr("Cursor ")+QString::number(index); _t1_comboBox->addItem(curCursor); _t2_comboBox->addItem(curCursor); _t3_comboBox->addItem(curCursor); diff --git a/DSView/pv/dock/protocoldock.cpp b/DSView/pv/dock/protocoldock.cpp index 083f2568..5b6ea0bf 100644 --- a/DSView/pv/dock/protocoldock.cpp +++ b/DSView/pv/dock/protocoldock.cpp @@ -107,8 +107,8 @@ void ProtocolDock::add_protocol() { if (_session.get_device()->dev_inst()->mode != LOGIC) { QMessageBox msg(this); - msg.setText("Protocol Analyzer"); - msg.setInformativeText("Protocol Analyzer is only valid in Digital Mode!"); + msg.setText(tr("Protocol Analyzer")); + msg.setInformativeText(tr("Protocol Analyzer is only valid in Digital Mode!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -203,8 +203,8 @@ void ProtocolDock::del_protocol() _protocol_index_list.clear(); } else { QMessageBox msg(this); - msg.setText("Protocol Analyzer"); - msg.setInformativeText("No Protocol Analyzer to delete!"); + msg.setText(tr("Protocol Analyzer")); + msg.setInformativeText(tr("No Protocol Analyzer to delete!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); diff --git a/DSView/pv/dock/searchdock.cpp b/DSView/pv/dock/searchdock.cpp index 7fe6e768..3233b825 100644 --- a/DSView/pv/dock/searchdock.cpp +++ b/DSView/pv/dock/searchdock.cpp @@ -120,8 +120,8 @@ void SearchDock::on_previous() last_pos = _view.get_search_pos(); if (last_pos == 0) { QMessageBox msg(this); - msg.setText("Search"); - msg.setInformativeText("Search cursor at the start position!"); + msg.setText(tr("Search")); + msg.setInformativeText(tr("Search cursor at the start position!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -130,8 +130,8 @@ void SearchDock::on_previous() data = (uint8_t*)_session.get_buf(unit_size, length); if (data == NULL) { QMessageBox msg(this); - msg.setText("Search"); - msg.setInformativeText("No Sample data!"); + msg.setText(tr("Search")); + msg.setInformativeText(tr("No Sample data!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -140,8 +140,8 @@ void SearchDock::on_previous() const bool ret = search_value(data, unit_size, length, last_pos, 1, value); if (!ret) { QMessageBox msg(this); - msg.setText("Search"); - msg.setInformativeText("Pattern " + value + " not found!"); + msg.setText(tr("Search")); + msg.setInformativeText(tr("Pattern ") + value + tr(" not found!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -165,8 +165,8 @@ void SearchDock::on_next() last_pos = _view.get_search_pos(); if (last_pos == length - 1) { QMessageBox msg(this); - msg.setText("Search"); - msg.setInformativeText("Search cursor at the end position!"); + msg.setText(tr("Search")); + msg.setInformativeText(tr("Search cursor at the end position!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -174,8 +174,8 @@ void SearchDock::on_next() } else { if (data == NULL) { QMessageBox msg(this); - msg.setText("Search"); - msg.setInformativeText("No Sample data!"); + msg.setText(tr("Search")); + msg.setInformativeText(tr("No Sample data!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -184,8 +184,8 @@ void SearchDock::on_next() const int ret = search_value(data, unit_size, length, last_pos, 0, value); if (!ret) { QMessageBox msg(this); - msg.setText("Search"); - msg.setInformativeText("Pattern " + value + " not found!"); + msg.setText(tr("Search")); + msg.setInformativeText(tr("Pattern ") + value + tr(" not found!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); diff --git a/DSView/pv/dock/triggerdock.cpp b/DSView/pv/dock/triggerdock.cpp index 3f1a91f0..2cae1272 100644 --- a/DSView/pv/dock/triggerdock.cpp +++ b/DSView/pv/dock/triggerdock.cpp @@ -47,11 +47,11 @@ TriggerDock::TriggerDock(QWidget *parent, SigSession &session) : font.setStyleHint(QFont::Monospace); font.setFixedPitch(true); - simple_radioButton = new QRadioButton("Simple Trigger", this); + simple_radioButton = new QRadioButton(tr("Simple Trigger"), this); simple_radioButton->setChecked(true); - adv_radioButton = new QRadioButton("Advanced Trigger", this); + adv_radioButton = new QRadioButton(tr("Advanced Trigger"), this); - position_label = new QLabel("Trigger Position: ", this); + position_label = new QLabel(tr("Trigger Position: "), this); position_spinBox = new QSpinBox(this); position_spinBox->setRange(0, 99); position_spinBox->setButtonSymbols(QAbstractSpinBox::NoButtons); @@ -60,7 +60,7 @@ TriggerDock::TriggerDock(QWidget *parent, SigSession &session) : connect(position_slider, SIGNAL(valueChanged(int)), position_spinBox, SLOT(setValue(int))); connect(position_spinBox, SIGNAL(valueChanged(int)), position_slider, SLOT(setValue(int))); - stages_label = new QLabel("Total Trigger Stages: ", this); + stages_label = new QLabel(tr("Total Trigger Stages: "), this); stages_label->setDisabled(true); stages_comboBox = new QComboBox(this); for (i = 1; i <= TriggerStages; i++) @@ -131,11 +131,11 @@ TriggerDock::TriggerDock(QWidget *parent, SigSession &session) : stage_glayout->addWidget(_inv1_comboBox, 3, 1); stage_glayout->addWidget(_count1_spinBox, 3, 2); stage_layout->addLayout(stage_glayout); - stage_layout->addSpacing(100); - stage_layout->addWidget(new QLabel("X: Don't care\n0: Low level\n1: High level\nR: Rising edge\nF: Falling edge\nC: Rising/Falling edge")); + stage_layout->addSpacing(20); + stage_layout->addWidget(new QLabel(tr("X: Don't care\n0: Low level\n1: High level\nR: Rising edge\nF: Falling edge\nC: Rising/Falling edge"))); stage_layout->addStretch(1); - QGroupBox *_stage_groupBox = new QGroupBox("Stage"+QString::number(i), this); + QGroupBox *_stage_groupBox = new QGroupBox(tr("Stage")+QString::number(i), this); _stage_groupBox->setFlat(true); _stage_groupBox->setLayout(stage_layout); _stage_groupBox_list.push_back(_stage_groupBox); @@ -221,8 +221,8 @@ void TriggerDock::adv_trigger() } if (stream) { QMessageBox msg(this); - msg.setText("Trigger"); - msg.setInformativeText("Stram Mode Don't Support Advanced Trigger!"); + msg.setText(tr("Trigger")); + msg.setInformativeText(tr("Stram Mode Don't Support Advanced Trigger!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -234,8 +234,8 @@ void TriggerDock::adv_trigger() } } else { QMessageBox msg(this); - msg.setText("Trigger"); - msg.setInformativeText("Advanced Trigger need DSLogic Hardware Support!"); + msg.setText(tr("Trigger")); + msg.setInformativeText(tr("Advanced Trigger need DSLogic Hardware Support!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); diff --git a/DSView/pv/mainwindow.cpp b/DSView/pv/mainwindow.cpp index b37dc504..4a3ba30e 100644 --- a/DSView/pv/mainwindow.cpp +++ b/DSView/pv/mainwindow.cpp @@ -443,8 +443,8 @@ void MainWindow::test_data_error() #endif _session.stop_capture(); QMessageBox msg(this); - msg.setText("Data Error"); - msg.setInformativeText("the receive data are not consist with pre-defined test data"); + msg.setText(tr("Data Error")); + msg.setInformativeText(tr("the receive data are not consist with pre-defined test data")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -454,8 +454,8 @@ void MainWindow::malloc_error() { _session.stop_capture(); QMessageBox msg(this); - msg.setText("Malloc Error"); - msg.setInformativeText("Memory is not enough for this sample!\nPlease reduce the sample depth!"); + msg.setText(tr("Malloc Error")); + msg.setInformativeText(tr("Memory is not enough for this sample!\nPlease reduce the sample depth!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); diff --git a/DSView/pv/toolbars/filebar.cpp b/DSView/pv/toolbars/filebar.cpp index 9efc9cf7..12816b12 100644 --- a/DSView/pv/toolbars/filebar.cpp +++ b/DSView/pv/toolbars/filebar.cpp @@ -82,7 +82,11 @@ FileBar::FileBar(SigSession &session, QWidget *parent) : connect(_action_capture, SIGNAL(triggered()), this, SLOT(on_actionCapture_triggered())); _file_button.setPopupMode(QToolButton::InstantPopup); +#ifdef LANGUAGE_ZH_CN + _file_button.setIcon(QIcon(":/icons/file_cn.png")); +#else _file_button.setIcon(QIcon(":/icons/file.png")); +#endif addWidget(&_file_button); } @@ -122,8 +126,8 @@ void FileBar::on_actionExport_triggered(){ void* buf = _session.get_buf(unit_size, length); if (!buf) { QMessageBox msg(this); - msg.setText("Data Export"); - msg.setInformativeText("No Data to Save!"); + msg.setText(tr("Data Export")); + msg.setInformativeText(tr("No Data to Save!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -156,15 +160,15 @@ void FileBar::on_actionSave_triggered() void* buf = _session.get_buf(unit_size, length); if (!buf) { QMessageBox msg(this); - msg.setText("File Save"); - msg.setInformativeText("No Data to Save!"); + msg.setText(tr("File Save")); + msg.setInformativeText(tr("No Data to Save!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); } else if (_session.get_device()->dev_inst()->mode != LOGIC) { QMessageBox msg(this); - msg.setText("File Save"); - msg.setInformativeText("DSView currently only support saving logic data to file!"); + msg.setText(tr("File Save")); + msg.setInformativeText(tr("DSView currently only support saving logic data to file!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -189,8 +193,13 @@ void FileBar::on_actionCapture_triggered() void FileBar::enable_toggle(bool enable) { _file_button.setDisabled(!enable); +#ifdef LANGUAGE_ZH_CN + _file_button.setIcon(enable ? QIcon(":/icons/file_cn.png") : + QIcon(":/icons/file_dis_cn.png")); +#else _file_button.setIcon(enable ? QIcon(":/icons/file.png") : QIcon(":/icons/file_dis.png")); +#endif } } // namespace toolbars diff --git a/DSView/pv/toolbars/samplingbar.cpp b/DSView/pv/toolbars/samplingbar.cpp index 289fce77..4e4957de 100644 --- a/DSView/pv/toolbars/samplingbar.cpp +++ b/DSView/pv/toolbars/samplingbar.cpp @@ -88,9 +88,15 @@ SamplingBar::SamplingBar(SigSession &session, QWidget *parent) : _sample_rate(this), _updating_sample_rate(false), _updating_sample_count(false), + #ifdef LANGUAGE_ZH_CN + _icon_stop(":/icons/stop_cn.png"), + _icon_start(":/icons/start_cn.png"), + _icon_instant(":/icons/instant_cn.png"), + #else _icon_stop(":/icons/stop.png"), _icon_start(":/icons/start.png"), _icon_instant(":/icons/instant.png"), + #endif _run_stop_button(this), _instant_button(this), _instant(false) @@ -106,8 +112,13 @@ SamplingBar::SamplingBar(SigSession &session, QWidget *parent) : connect(&_instant_button, SIGNAL(clicked()), this, SLOT(on_instant_stop())); +#ifdef LANGUAGE_ZH_CN + _configure_button.setIcon(QIcon::fromTheme("configure", + QIcon(":/icons/params_cn.png"))); +#else _configure_button.setIcon(QIcon::fromTheme("configure", QIcon(":/icons/params.png"))); +#endif _run_stop_button.setIcon(_icon_start); _instant_button.setIcon(_icon_instant); @@ -313,8 +324,13 @@ void SamplingBar::set_sampling(bool sampling) } _configure_button.setEnabled(!sampling); +#ifdef LANGUAGE_ZH_CN + _configure_button.setIcon(sampling ? QIcon(":/icons/params_dis_cn.png") : + QIcon(":/icons/params_cn.png")); +#else _configure_button.setIcon(sampling ? QIcon(":/icons/params_dis.png") : QIcon(":/icons/params.png")); +#endif } void SamplingBar::set_sample_rate(uint64_t sample_rate) @@ -674,8 +690,8 @@ void SamplingBar::on_run_stop() g_variant_unref(gvar); if (zero) { QMessageBox msg(this); - msg.setText("Zero Adjustment"); - msg.setInformativeText("Please adjust zero skew and save the result!"); + msg.setText(tr("Zero Adjustment")); + msg.setInformativeText(tr("Please adjust zero skew and save the result!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); @@ -704,11 +720,11 @@ void SamplingBar::on_instant_stop() g_variant_unref(gvar); if (zero) { QMessageBox msg(this); - msg.setText("Zero Adjustment"); + msg.setText(tr("Zero Adjustment")); if(strcmp(dev_inst->dev_inst()->driver->name, "DSLogic") == 0) - msg.setInformativeText("Please adjust zero skew and save the result!\nPlease left both of channels unconnect for zero adjustment!"); + msg.setInformativeText(tr("Please adjust zero skew and save the result!\nPlease left both of channels unconnect for zero adjustment!")); else - msg.setInformativeText("Please adjust zero skew and save the result!"); + msg.setInformativeText(tr("Please adjust zero skew and save the result!")); msg.setStandardButtons(QMessageBox::Ok); msg.setIcon(QMessageBox::Warning); msg.exec(); diff --git a/DSView/pv/toolbars/trigbar.cpp b/DSView/pv/toolbars/trigbar.cpp index 9be5bf5e..143f9a30 100644 --- a/DSView/pv/toolbars/trigbar.cpp +++ b/DSView/pv/toolbars/trigbar.cpp @@ -45,6 +45,22 @@ TrigBar::TrigBar(QWidget *parent) : connect(&_search_button, SIGNAL(clicked()), this, SLOT(search_clicked())); +#ifdef LANGUAGE_ZH_CN + _trig_button.setIcon(QIcon::fromTheme("trig", + QIcon(":/icons/trigger_cn.png"))); + _trig_button.setCheckable(true); + _protocol_button.setIcon(QIcon::fromTheme("trig", + QIcon(":/icons/protocol_cn.png"))); +#ifdef ENABLE_DECODE + _protocol_button.setCheckable(true); +#endif + _measure_button.setIcon(QIcon::fromTheme("trig", + QIcon(":/icons/measure_cn.png"))); + _measure_button.setCheckable(true); + _search_button.setIcon(QIcon::fromTheme("trig", + QIcon(":/icons/search-bar_cn.png"))); + _search_button.setCheckable(true); +#else _trig_button.setIcon(QIcon::fromTheme("trig", QIcon(":/icons/trigger.png"))); _trig_button.setCheckable(true); @@ -59,6 +75,7 @@ TrigBar::TrigBar(QWidget *parent) : _search_button.setIcon(QIcon::fromTheme("trig", QIcon(":/icons/search-bar.png"))); _search_button.setCheckable(true); +#endif addWidget(&_trig_button); addWidget(&_protocol_button); @@ -93,6 +110,16 @@ void TrigBar::enable_toggle(bool enable) _measure_button.setDisabled(!enable); _search_button.setDisabled(!enable); +#ifdef LANGUAGE_ZH_CN + _trig_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/trigger_cn.png")) : + QIcon::fromTheme("trig", QIcon(":/icons/trigger_dis_cn.png"))); + _protocol_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/protocol_cn.png")) : + QIcon::fromTheme("trig", QIcon(":/icons/protocol_dis_cn.png"))); + _measure_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/measure_cn.png")) : + QIcon::fromTheme("trig", QIcon(":/icons/measure_dis_cn.png"))); + _search_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/search-bar_cn.png")) : + QIcon::fromTheme("trig", QIcon(":/icons/search-bar_dis_cn.png"))); +#else _trig_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/trigger.png")) : QIcon::fromTheme("trig", QIcon(":/icons/trigger_dis.png"))); _protocol_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/protocol.png")) : @@ -101,13 +128,19 @@ void TrigBar::enable_toggle(bool enable) QIcon::fromTheme("trig", QIcon(":/icons/measure_dis.png"))); _search_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/search-bar.png")) : QIcon::fromTheme("trig", QIcon(":/icons/search-bar_dis.png"))); +#endif } void TrigBar::enable_protocol(bool enable) { _protocol_button.setDisabled(!enable); +#ifdef LANGUAGE_ZH_CN + _protocol_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/protocol_cn.png")) : + QIcon::fromTheme("trig", QIcon(":/icons/protocol_dis_cn.png"))); +#else _protocol_button.setIcon(enable ? QIcon::fromTheme("trig", QIcon(":/icons/protocol.png")) : QIcon::fromTheme("trig", QIcon(":/icons/protocol_dis.png"))); +#endif } void TrigBar::close_all() diff --git a/DSView/pv/view/dsosignal.cpp b/DSView/pv/view/dsosignal.cpp index 62a22168..c099af80 100644 --- a/DSView/pv/view/dsosignal.cpp +++ b/DSView/pv/view/dsosignal.cpp @@ -844,14 +844,14 @@ void DsoSignal::paint_type_options(QPainter &p, int right, bool hover, int actio p.setBrush((hover && action == CHEN) ? _colour.darker() : _colour); p.drawRect(chEn_rect); p.setPen(Qt::white); - p.drawText(chEn_rect, Qt::AlignCenter | Qt::AlignVCenter, enabled() ? "EN" : "DIS"); + p.drawText(chEn_rect, Qt::AlignCenter | Qt::AlignVCenter, enabled() ? tr("EN") : tr("DIS")); p.setPen(Qt::transparent); p.setBrush(enabled() ? ((hover && action == ACDC) ? _colour.darker() : _colour) : dsDisable); p.drawRect(acdc_rect); p.setPen(Qt::white); - p.drawText(acdc_rect, Qt::AlignCenter | Qt::AlignVCenter, (_acCoupling == SR_GND_COUPLING) ? "GND" : - (_acCoupling == SR_DC_COUPLING) ? "DC" : "AC"); + p.drawText(acdc_rect, Qt::AlignCenter | Qt::AlignVCenter, (_acCoupling == SR_GND_COUPLING) ? tr("GND") : + (_acCoupling == SR_DC_COUPLING) ? tr("DC") : tr("AC")); // paint the probe factor selector GVariant* gvar; @@ -904,10 +904,10 @@ void DsoSignal::paint_measure(QPainter &p) QString freq_string = abs(_period) > 1000000 ? QString::number(1000000000/_period, 'f', 2) + "Hz" : abs(_period) > 1000 ? QString::number(1000000/_period, 'f', 2) + "kHz" : QString::number(1000/_period, 'f', 2) + "MHz"; p.setPen(_colour); - p.drawText(QRectF(0, 100*index + UpMargin, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, "Max: "+max_string+" "); - p.drawText(QRectF(0, 100*index + UpMargin + 20, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, "Min: "+min_string+" "); - p.drawText(QRectF(0, 100*index + UpMargin + 40, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, "Period: "+period_string+" "); - p.drawText(QRectF(0, 100*index + UpMargin + 60, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, "Frequency: "+freq_string+" "); + p.drawText(QRectF(0, 100*index + UpMargin, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, tr("Max: ")+max_string+" "); + p.drawText(QRectF(0, 100*index + UpMargin + 20, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, tr("Min: ")+min_string+" "); + p.drawText(QRectF(0, 100*index + UpMargin + 40, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, tr("Period: ")+period_string+" "); + p.drawText(QRectF(0, 100*index + UpMargin + 60, get_view_rect().width()*0.9, 20), Qt::AlignRight | Qt::AlignVCenter, tr("Frequency: ")+freq_string+" "); if (_autoV) { const uint8_t vscale = abs(_max - _min); diff --git a/DSView/pv/view/viewport.cpp b/DSView/pv/view/viewport.cpp index 87737fc2..251129a1 100644 --- a/DSView/pv/view/viewport.cpp +++ b/DSView/pv/view/viewport.cpp @@ -612,13 +612,13 @@ void Viewport::paintMeasure(QPainter &p) p.setPen(Qt::black); p.drawText(measure1_rect, Qt::AlignRight | Qt::AlignVCenter, - "Width: " + _mm_width); + tr("Width: ") + _mm_width); p.drawText(measure2_rect, Qt::AlignRight | Qt::AlignVCenter, - "Period: " + _mm_period); + tr("Period: ") + _mm_period); p.drawText(measure3_rect, Qt::AlignRight | Qt::AlignVCenter, - "Frequency: " + _mm_freq); + tr("Frequency: ") + _mm_freq); p.drawText(measure4_rect, Qt::AlignRight | Qt::AlignVCenter, - "Duty Cycle: " + _mm_duty); + tr("Duty Cycle: ") + _mm_duty); } } else if (_measure_type == DSO) { const vector< boost::shared_ptr > sigs(_view.session().get_signals());