Some QuickGUI content becomes invisible past border...

chunky

11-12-2007 23:41:38

Ok, It's pretty hard to describe what's happening here. I'll post a video, but in case you can't see that [it's quicktime, freely downloadable from apple's site :-)], I'll take some screenshots too.

The code that generates this is:
QuickGUI::SkinSetManager::getSingleton().loadSkin("qgui",QuickGUI::SkinSet::IMAGE_TYPE_PNG);

mGUIManager = new QuickGUI::GUIManager(mViewport);
mGUIManager->setSceneManager(mScnMgr);

mSheet = mGUIManager->getDefaultSheet();
mSheet->setFont("TuxWars");

mChatWindow = mSheet->createWindow("Chat Window");
mChatWindow->setDimensions(QuickGUI::Rect(10,500,350,250));

mChatInputTB = mChatWindow->createTextBox();
mChatInputTB->setDimensions(QuickGUI::Rect(0,220,350,30));


Movie: http://chunkyks.com/quickguiproblems/hidingui.mov
Screenshots:
http://chunkyks.com/quickguiproblems/hiding1.png
http://chunkyks.com/quickguiproblems/hiding2.png
http://chunkyks.com/quickguiproblems/hiding3.png
http://chunkyks.com/quickguiproblems/hiding4.png
http://chunkyks.com/quickguiproblems/hiding5.png
http://chunkyks.com/quickguiproblems/hiding6.png

It seems like there's some sort of border area where the background of the window isn't rendered. The main application window is at 1024x768, for reference. Strangely, the window border is still rendered.

Then, looking at just the textbox, the border, background, and text are all rendered even going past the area where main window stops being rendered.

Wibble?

Thank-you very much,
Gary (-;

EDIT: Fix busted urls

kungfoomasta

12-12-2007 00:15:44

Cool app! So I thought about it some, and was really puzzled at first, but I'm leaning towards this thought: it looks like your window starts off at a certain resolution, and then is changed later on. The sheet is supposed to be full viewport size at all times, but there is no way to determine when viewport dimensions have changed. So when you resize your window, you should call:

GUIManager::_notifyViewportDimensionsChanged();

The borders aren't clipping correctly, which is why they're shown outside the Sheet bounds. As for the TextBox still showing up... not sure on that either, lol. Let me know if calling the above fixes the problem.

chunky

12-12-2007 01:15:22

Well, that appears to have fixed it. Fairly odd, since I just create the window once, and it's not even resizable. Ah, well.

Thank-you so much for the quick [and useful!] responses in the last couple days :-)

Gary (-;