Looking for Text Tips
by David Helmer · in iTorque 2D · 05/29/2012 (6:17 pm) · 4 replies
Hey guys,
I've been reading a lot of forum posts about using Text in iTorque2D and I'm considering 2 angles I guess.
If anyone has best practices or ideas for how I should proceed with text in my UI, let me know.
I've been reading a lot of forum posts about using Text in iTorque2D and I'm considering 2 angles I guess.
- Use GUI to display text: since the GUI elements are not mentioned in the latest documentation, I don't know how well it is supported. I'm going to use the 2 scenegraph approach to build my GUI for the most part and only need GUI for text since as I understand it, TextObjects just don't cut it for text.
- Use UIKit to display text: I read the tutorial for interacting with UI kit and then I thought for a moment I could build a bunch of UI using UIKit. I guess my concern is that my artist doesn't have a mac so my review builds for him will cease to work without some kind of work around. I also anticipate that I'll have issues with managing input to the scene graph if I'm displaying UI Kit above it.
If anyone has best practices or ideas for how I should proceed with text in my UI, let me know.
About the author
A C# developer by day and a TorqueScript developer by night...
#2
And should there be anything I should look out for at the beginning for Universal support.
Thanks!
05/29/2012 (8:15 pm)
Great, should I just check out the T2D documentation for GUI instructions or is there some other resource I should use.And should there be anything I should look out for at the beginning for Universal support.
Thanks!
#3
So you could roll your own solution. Maybe write your own gui class that uses scenes and bitmap fonts.
If you do decide to use GUI. Look at the reference doc.
http://docs.garagegames.com/tgb/official/index.html?content/documentation/Interface%20Tutorials/Feature/Static%20Sprites.html
You want to start with GUIControl, GuiMLTextCtrl, GuiTextCtrl. Then find sample codes somewhere of an app that uses GUI. Look in TDN: http://tdn.garagegames.com/wiki/TDN_Home&needLogin=1
05/29/2012 (8:25 pm)
Okay didn't realize you were going to do universal. I can't completely recommend using it2d GUI then because the GUI doesn't scale properly. For Coloring 4 Kids, I had to have two different GUIs for the two resolutions. So you could roll your own solution. Maybe write your own gui class that uses scenes and bitmap fonts.
If you do decide to use GUI. Look at the reference doc.
http://docs.garagegames.com/tgb/official/index.html?content/documentation/Interface%20Tutorials/Feature/Static%20Sprites.html
You want to start with GUIControl, GuiMLTextCtrl, GuiTextCtrl. Then find sample codes somewhere of an app that uses GUI. Look in TDN: http://tdn.garagegames.com/wiki/TDN_Home&needLogin=1
#4
Thanks for the tips. If the only issue with Universal is sizing of the gui and swapping based off of platform, i'll just be mindful of that going for.
As it stands Universal is a nice to have in my book.
05/29/2012 (8:40 pm)
Ok cool, I've used regular t2d GUI before so I'll check out my old code.Thanks for the tips. If the only issue with Universal is sizing of the gui and swapping based off of platform, i'll just be mindful of that going for.
As it stands Universal is a nice to have in my book.
Torque Owner Johnny Vo
Here's my suggestion use what is most easiest...that will be the built in GUI system. After you use that and you find that it doesn't have the capabilities you need and you can't work around it then look into another solution.