TextArea not working correctly ?

calsmurf2904

04-12-2008 12:13:54

Hello,
I have setup a TextArea in my application for an scripting window.
It works perfectly but with some issues.
I can't press enter ? It doesn't go to the next line when I press enter.
The line thingee that indicates where you are writting isn't correctly aligned.
I am currently using the PlayPen GUI things.
Code to initialise Script Window :

QuickGUI::WindowDesc wd;
wd.name = "CompileWindow";
wd.dimensions.position = QuickGUI::Point((mWindow->getWidth()/2)-256,(mWindow->getHeight()/2)-256);
wd.dimensions.size = QuickGUI::Size(512,512);
wd.titleBarTextDesc.segments.push_back(QuickGUI::TextSegment("micross.12",Ogre::ColourValue::White,"Script Window"));
win = mGuiMgr->getActiveSheet()->createWindow(wd);
win->setTitleBarTextColor(Ogre::ColourValue::Blue);
QuickGUI::TextAreaDesc txd;
txd.name = "Script";
txd.defaultFontName = "micross.12";
txd.dimensions = QuickGUI::Rect(10,10,470,436);
mText = win->createTextArea(txd);
QuickGUI::ButtonDesc bd;
bd.dimensions = QuickGUI::Rect(10,448,100,16);
bd.textDesc.segments.push_back(QuickGUI::TextSegment("micross.12",Ogre::ColourValue::White,"Compile!"));
QuickGUI::Button* mCompileButton = win->createButton(bd);
mCompileButton->addWidgetEventHandler(QuickGUI::WIDGET_EVENT_MOUSE_BUTTON_UP,&OgrePython::compile,this);

kungfoomasta

04-12-2008 18:35:25

The TextArea widget needs to be updated, it was working at one point, but there were some issues with positioning the text cursor.

I am planning on making another release soon (within 2 weeks), I know a lot of people would like a working TextArea and Console widget.