ftlio is right, but another reason is Taiwan. Someone can correct me if things have changed - a lot of Taiwanese businnesses have strong links to the mainland in the form of manufacturing facilities, and so on. China encourages these links with one big stipulation: these Taiwanese businesses cannot transfer their funds out of China. Why? China considers Taiwan to be a renegade province that it would like back just like Macau and HK. It will do almost anything to make that a reality i.e. influencing elections, tempting and pressuring the business sector, etc... It's such an emotional issue that I feel even a costly invasion would be on the table if there was enough provocation from pro-independence factions in Taiwan
My understanding was that between debt purchasing and exchange controls, China can keep the yuan cheap and demand for their exports high. I say 'was' because it's been a while since I tried to grok China's economy.