Property named 'Image'

For help with general CEGUI usage:
- Questions about the usage of CEGUI and its features, if not explained in the documentation.
- Problems with the CMAKE configuration or problems occuring during the build process/compilation.
- Errors or unexpected behaviour.

Moderators: CEGUI MVP, CEGUI Team

Irene
Just popping in
Just popping in
Posts: 2
Joined: Sun Nov 25, 2012 21:48

Property named 'Image'

Postby Irene » Sun Nov 25, 2012 21:55

I'm trying to use some images in my cegui code, but receive a following error:

26/11/2012 01:22:09 (Std) Started creation of Font from XML specification:
26/11/2012 01:22:09 (Std) ---- CEGUI font name: DejaVuSans-10
26/11/2012 01:22:09 (Std) ---- Font type: FreeType
26/11/2012 01:22:09 (Std) ---- Source file: DejaVuSans.ttf in resource group: (Default)
26/11/2012 01:22:09 (Std) ---- Real point size: 10
26/11/2012 01:22:09 (Std) ---- Returning existing instance of Font named 'DejaVuSans-10'.
26/11/2012 01:22:09 (Std) Attempting to create Imageset 'gui_menu' using image file 'rifle.jpg'.
26/11/2012 01:22:09 (Error) CEGUI::UnknownObjectException in file c:\projects\myProject\cegui-0.7.7\cegui\src\ceguipropertyset.cpp(125) : There is no Property named 'Image' available in the set.


Here's the code:

Code: Select all

Window* window= wmgr.createWindow( "DefaultWindow", "root" );
...
CEGUI::Imageset &menu_imageset = CEGUI::ImagesetManager::getSingleton().createFromImageFile("gui_menu","rifle.jpg");
menu_imageset.defineImage("gui_menu_base",CEGUI::Point(8.0f, 341.0f),CEGUI::Size(200.0f, 200.0f),CEGUI::Point(0.0f, 0.0f));   
window->setProperty("Image","set:gui_menu image:gui_menu_base");


How do I fix this?

User avatar
Kulik
CEGUI Team
Posts: 1382
Joined: Mon Jul 26, 2010 18:47
Location: Czech Republic
Contact:

Re: Property named 'Image'

Postby Kulik » Mon Nov 26, 2012 09:08

Use TaharezLook/StaticImage, not DefaultWindow. There are property reference pages on the wiki.


Return to “Help”

Who is online

Users browsing this forum: No registered users and 9 guests