Hi, I'm not ask the same question and I think I should place it in the Beginners Help.
I want to insert into the ItemListbox some Items, which are combined windows, such as StaticImage、StaticText、StaticImage.and I now know that I should insert ItemEntry based class object into ItemListbox.
In order to achive this, I write a class Named NewItemEntry: public ItemEntry.
and In it's constructor, I add four new child window(StaticImage、StaticText、StaticImage、StaticImage) to this NewItemEntry, and the next step I create a new object NewItemEntry *pMyItem = new NewItemEntry(...)
ItemListbox::addItem(pMyItem), it gives me an exception ("ItemEntry::getItemPixelSize must be implementd...")
I don't know how to solve this .
I'm waiting for your suggestion!Thank you !
About ItemListbox && ItemEntry
Moderators: CEGUI MVP, CEGUI Team
- CrazyEddie
- CEGUI Project Lead
- Posts: 6760
- Joined: Wed Jan 12, 2005 12:06
- Location: England
- Contact:
Re: About ItemListbox && ItemEntry
I know from the other thread that you fixed this, but for completeness, the reason this fails is because you're trying to create your new window type directly which is not allowed in CEGUI. New window types must be registered with the system, you then need a falagard mapping that can assign an appropriate WindowRenderer in order that the new window type can draw imagery specified in a WidgetLook XML definition. The type specified by this mapping is then created via the WindowManager.
For info about registering a window type with CEGUI, this post: viewtopic.php?p=14730#p14730 covers the way to do that, though we have vastly simplified this in the upcoming 0.7.0 release.
CE.
For info about registering a window type with CEGUI, this post: viewtopic.php?p=14730#p14730 covers the way to do that, though we have vastly simplified this in the upcoming 0.7.0 release.
CE.
Useful Links: Forum Guidelines | Documentation | Tutorials | HOWTO | Videos | Donate to CEGUI | CEGUI Twitter
Re: About ItemListbox && ItemEntry
OK, Thank you so much!
Who is online
Users browsing this forum: No registered users and 20 guests