高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】odfon
odfont
odfont
want to create a new odfont object, i want to get the available characters in a shx font.
code:
odfontptr pfont = odfont::createobject();
pfont->initialize(pstreambuf);
odarray<odchar> shxcharacters;
pfont->getavailablechars(shxcharacters);
but odfont::createobject() crashes. where is my mistake?
thanks for any help
woho
odfont is abstract interface class. so you cann't create this object.
you may use next code. text style must have interested font.
code:
odgitextstyle gitextstyle;
gifromdbtextstyle(textstyleid, gitextstyle);
odfontptr pfont = gitextstyle.getfont();
odarray<odchar> shxcharacters;
pfont->getavailablechars(shxcharacters);
best regards,
sergey z.
|