Panda3d can't display Tradiontal Chinese Charater ?

I had used code and modify it from this link-

import direct.directbase.DirectStart
from direct.showbase.DirectObject import DirectObject
from direct.gui.DirectGui import *
from pandac.PandaModules import *
from direct.gui.OnscreenText import OnscreenText
import codecs

class World(DirectObject):
def init(self):
font = loader.loadFont(‘kaiu.ttf’) # my window2000 Chinese font
text = TextNode(‘node name’)
ustr = u’\ua4e5’ # one Traditional Chinese character
textNodePath = aspect2d.attachNewNode(text)

w = World()


but I got this error
:text(warning): No definition in DFKai-SB Regular for Character 42213
And Panda3d didn’t display correct “Chinese character”.

If panda3d-1.3.2 doesn’t support “Traditional Chinese” range ?

Panda supports all international characters, including Chinese characters.

The error message indicates that your font does not contain a definition for the character u’\ua4e5’ (which has unicode number 42213). Are you sure you are using the correct font?


Thanks your reply for this topic !!! :slight_smile:

Today, I tried it out !!!
In Taiwan with Windows2000 pc,
I had used below code to display Tradiontal Chinese.
And py-script the 1st line must add this:


-- coding: cp950 -- <—### é€™è¡Œå¿…é ˆç”¨, æ‰