fatcoder
Member
|
GUI Questions
1. Is it possible to create a list control in the GUI editor, then add data to it in code. The list tutorial only shows how to create a list in code.
2. How do you align text to the left or right in the text control. The text is always centred within the control and I cannot find any option to align it to the left/right within the control.
3. How do I anchor GUI controls to the top/right/bottom/left side of the screen? Is this possible? i.e. anchor a control to the bottom, left corner and the control stays there regardless of the screen size. Do I have to do this manually by positioning the controls in code based on the screen size?
|
|
05-18-2010 12:48 PM |
|
NxShape
Member
|
RE: GUI Questions
2.TextDS tds;//This is parameters of text draw
tds.reset();
tds.align = Vec2(1, 0);//This is align the text for left align
//Vec2(-1, 0) for right align
//Vec2(0, 0) for center
//Vec2(0, 1) for down align
//Vec2(0, -1) for up align
...
Gui += text.create(Rect_LU(0.03, -0.03, 2.45, 0.1), "Text!", &tds);
Sorry for my english))
|
|
05-18-2010 02:31 PM |
|
Esenthel
Administrator
|
RE: GUI Questions
1. no but you can add the List in the codes
3. you need to manually move them when screen size changes (please use D.screenChanged or something like that)
|
|
05-18-2010 04:56 PM |
|