Ted C. Posted February 4, 2012 at 09:04 AM Report Share Posted February 4, 2012 at 09:04 AM Hey Imron, there was some talk upthread about the need to use an English locale to get the correct fonts in Word. Did you consider making the input locale "English (Singapore)"? It's an available locale in Windows, and it might make more sense than English (Australia) or English (Canada), since Chinese is an official language of Singapore (though I don't think they have an official romanisation). By the way, you deserve an award just for the name "pinyinput". How did anyone not come up with that before? Quote Link to comment Share on other sites More sharing options...
imron Posted February 4, 2012 at 09:21 AM Author Report Share Posted February 4, 2012 at 09:21 AM The English locale is required to make Word and a couple of other Microsoft programs (e.g. Wordpad) not automatically change to a Chinese font for characters outside the standard ASCII range (e.g. any character with a tone mark over it), which these programs will do if the input locale is Chinese. So I made the installation choice for input locale to be one of Chinese (Simplified PRC), Chinese (Traditional Taiwan), English (Australia), or the default locale of your computer - which in your case appears to be English (Canada) So, any user who has English (Singapore) as their default locale will be able to choose that if they wish. I didn't want to force a random locale on anyone as it may have created other problems and also complicates things for non-technical users, and I figured the above options made the most amount of sense with the possible exception of English (Australia) which I put to provide an English option for users whose default locale wasn't English, and chose over more common varieties such as English (UK) or English (US) more to fly the flag than anything else By the way, you deserve an award just for the name "pinyinput". How did anyone not come up with that before? My one tiny regret was not registering the domain name - which was free both at the time and for about a year after Pinyinput's release. Oh well, only myself to blame for that. Quote Link to comment Share on other sites More sharing options...
Ted C. Posted February 4, 2012 at 09:40 AM Report Share Posted February 4, 2012 at 09:40 AM Ah, I see. Yeah, that makes sense. Quote Link to comment Share on other sites More sharing options...
imron Posted February 4, 2012 at 09:59 AM Author Report Share Posted February 4, 2012 at 09:59 AM I just wish MS had put a bit more thought into their automatic font changing logic in Word and made it change fonts for any Chinese character rather than just any non-ASCII character. It would have saved a whole lot of trouble as it took a good amount of poking around and trickery to get dynamic locale selection working. Not sure what it's like with the TSF, but the old IME API wants IMEs to set a single locale at compile time and be done with it. In the end I had to overwrite the VS_VERSION_INFO stucture of the IME dll manually before installing it. Quote Link to comment Share on other sites More sharing options...
Shelley Posted February 4, 2012 at 10:17 PM Report Share Posted February 4, 2012 at 10:17 PM Just got it working on my pc. Wonderful Thanks for your efforts. it works very well on my setup. I agree with Ted C. Brilliant name for it. Keep up the good work. Shelley Quote Link to comment Share on other sites More sharing options...
ausgang Posted February 10, 2012 at 11:13 PM Report Share Posted February 10, 2012 at 11:13 PM Hi imron, I have problems installing pinyinput on Win7 Ultimate 64bit. I run the .exe as admin but get the error message: "Error loading pinyinput as a text service". Do you have a clue what to do? Thanks in advance, Juergen Quote Link to comment Share on other sites More sharing options...
imron Posted February 11, 2012 at 02:46 AM Author Report Share Posted February 11, 2012 at 02:46 AM What locale are you trying to install it under, and what is the default locale of your machine? Quote Link to comment Share on other sites More sharing options...
ausgang Posted February 11, 2012 at 09:50 AM Report Share Posted February 11, 2012 at 09:50 AM Thanks for the quick answer. My systems default is german, but I also tried to install it under other languages such as simplified chinese, traditional chinese and english. It always produces the same error message. Quote Link to comment Share on other sites More sharing options...
imron Posted February 11, 2012 at 11:26 AM Author Report Share Posted February 11, 2012 at 11:26 AM There are 4 different places in installer that will produce that error message, but from the error message alone it's difficult to know which one caused it exactly. If I supplied you with a debug version of the installer would you be happy to try running that so that I can get some logging information to find out which of them is causing the problem? Quote Link to comment Share on other sites More sharing options...
ausgang Posted February 11, 2012 at 05:10 PM Report Share Posted February 11, 2012 at 05:10 PM Of course I would try this. Does this produce a log file or something like that? Quote Link to comment Share on other sites More sharing options...
imron Posted February 11, 2012 at 08:25 PM Author Report Share Posted February 11, 2012 at 08:25 PM Yeah, it will produce a log file telling me which place failed and why. I'll send the file via email sometime later today. Quote Link to comment Share on other sites More sharing options...
ausgang Posted February 16, 2012 at 05:30 PM Report Share Posted February 16, 2012 at 05:30 PM Hi imron, have you alreadey tried to send the debug installer to me? Thanks in advance Quote Link to comment Share on other sites More sharing options...
imron Posted February 16, 2012 at 08:13 PM Author Report Share Posted February 16, 2012 at 08:13 PM Yep. I sent it on the 12th to the email address you registered at the forums with. PM me if you would like me to send it to a different email address. Quote Link to comment Share on other sites More sharing options...
Manuel Posted March 9, 2012 at 07:40 AM Report Share Posted March 9, 2012 at 07:40 AM Not to piss on anybody's strawberries but this can be accomplished with Autohotkey_L in just a few minutes, totally bug-free, no need to install anything (assuming you already use Autohotkey_L) and best of all no need to switch input methods or worry about locales, etc, as you can type simultaneously not just pinyin but also several other languages if you so wish. The following code is what I use for entring pinyin. It works with all upper, lower and mixed case and works similar to imron's Pinyinput. You can of course add code to input French, German and Spanish characters, as well as other commonly used characters such as €£¥°© on the fly without having to mess around e.g. on my system I type © I just type out hscopy (hs stands for hotstring). Anyway here's the code for pinyin.: #If (PinyinEnabled & !WinExist("ahk_class SoPY_Status")) :*?:ai1::āi :*?:ai2::ái :*?:ai3::ǎi :*?:ai4::ài :*?:ei1::ēi :*?:ei2::éi :*?:ei3::ěi :*?:ei4::èi :*?:i1::ī :*?:i2::í :*?:i3::ǐ :*?:i4::ì :*?:ao1::āo :*?:ao2::áo :*?:ao3::ǎo :*?:ao4::ào :*?:o1::ō :*?:o2::ó :*?:o3::ǒ :*?:o4::ò :*?:ou1::ōu :*?:ou2::óu :*?:ou3::ǒu :*?:ou4::òu :*?:u1::ū :*?:u2::ú :*?:u3::ǔ :*?:u4::ù :*?:a1::ā :*?:a2::á :*?:a3::ǎ :*?:a4::à :*?:e1::ē :*?:e2::é :*?:e3::ě :*?:e4::è :*?:v1::ǖ :*?:v2::ǘ :*?:v3::ǚ :*?:v4::ǜ :*?:an1::ān :*?:an2::án :*?:an3::ǎn :*?:an4::àn :*?:en1::ēn :*?:en2::én :*?:en3::ěn :*?:en4::èn :*?:in1::īn :*?:in2::ín :*?:in3::ǐn :*?:in4::ìn :*?:un1::ūn :*?:un2::ún :*?:un3::ǔn :*?:un4::ùn :*?:vn1::ǖn :*?:vn2::ǘn :*?:vn3::ǚn :*?:vn4::ǜn :*?:ang1::āng :*?:ang2::áng :*?:ang3::ǎng :*?:ang4::àng :*?:eng1::ēng :*?:eng2::éng :*?:eng3::ěng :*?:eng4::èng :*?:ing1::īng :*?:ing2::íng :*?:ing3::ǐng :*?:ing4::ìng :*?:ong1::ōng :*?:ong2::óng :*?:ong3::ǒng :*?:ong4::òng :*?:er1::ēr :*?:er2::ér :*?:er3::ěr :*?:er4::èr #If Then what you do is assign a hotstring or hotkey to toggle the PinyinEnabled flag if you need to disable pinyin input i.e. if you want to type ni3 hao3 instead of nǐ hǎo. The above code also checks to see if Sogou input method is active, in which case it has no effect. On my system I switch between Chinese and English input methods using the hotstring "SDF" and toggle pinyin input on and off using the hotstring "FDS", by means of the following code. ;Toggle Sogou Chinese input language :*?:sdf:: SetCapsLockState, Off ;Turn off CapsLock, so you can type Chinese straightaway SendInput {Alt Down}{Shift Down}{Shift Up}{Alt Up} Return :*?:fds::PinyinEnabled := !PinyinEnabled I highly recommend Autohotkey_L to everybody! It's the best thing that happened to Windows and the reason why I don't use a Mac. Edit: I humbly apologise if this post looked like I was trying to say that my app was better than Imron's. Imron's Pinyinput was created way before Authotkey_L existed, so kudos to Imron for his slefless coding effort. If Autohotkey_L didn't exist I'd be using Pinyinput no doubt. Quote Link to comment Share on other sites More sharing options...
imron Posted March 9, 2012 at 07:49 AM Author Report Share Posted March 9, 2012 at 07:49 AM no need to install anything You mean besides Autohotkey Quote Link to comment Share on other sites More sharing options...
Manuel Posted March 9, 2012 at 08:37 AM Report Share Posted March 9, 2012 at 08:37 AM I have moved QuickPinyin to a thread of its own to increase visibility: QuickPinyin - Faster pinyin with tone marks Quote Link to comment Share on other sites More sharing options...
imron Posted March 9, 2012 at 08:52 AM Author Report Share Posted March 9, 2012 at 08:52 AM totally bug-free P.S. what happens if you type in rang4bu4? (not trying to be mean, actually I think this looks like a pretty neat tool, and would probably even try it myself if I wasn't a Mac convert - well, that and I'm not really a fan of running random files downloaded from the Internet that my antivirus software flags as malware ). Quote Link to comment Share on other sites More sharing options...
Manuel Posted March 9, 2012 at 09:17 AM Report Share Posted March 9, 2012 at 09:17 AM Thanks Imron! Well spotted, that was actually a typo in my code, sorry... If you type rang4bu4 you get ràngbù. I accidentally typed an s after ang when I hit Ctrl-S to save. Fixed. I have still called it v1.02 rather naughtily though, as I don't think many people will have downloaded it. Quote Link to comment Share on other sites More sharing options...
imron Posted March 9, 2012 at 09:21 AM Author Report Share Posted March 9, 2012 at 09:21 AM You should probably edit your original post too, as ang4 is still listed as àngs in the script. Quote Link to comment Share on other sites More sharing options...
Manuel Posted March 9, 2012 at 09:24 AM Report Share Posted March 9, 2012 at 09:24 AM Thanks! Original post amended. BTW did your antivirus flag it as malware? If you are not sure you can always run it in Sandboxie, which is what I do as standard for everything I download. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and select your username and password later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.