I’ve been at this for two hours now… Something that is supposed to be easy to implement has gotten the best of me…
I’m trying to implement a scrollview into my window…
Here’s what I have in my window:
Vector2 scrollPosition = Vector2.zero; //Global vector2...
void DoMyWindow(int windowID) {
scrollPosition = GUI.BeginScrollView(new Rect(10,50,480,100),
scrollPosition,
new Rect(0,0,400,400));
//GUI.skin.box.wordWrap = true;
GUI.TextArea(new Rect(0,0,400,400),displayText);
GUI.EndScrollView();
GUI.Label(new Rect(10, 20, 100, 100), "Version: " + Version.x.ToString("F0") + "." + Version.y.ToString("F0") + "." + Version.z.ToString("F0") + "." + Version.z.ToString("F0"));
if (GUI.Button(new Rect(10, 300, 480, 35), "Send Mail"))
{
SendMail();
}
// GUILayout.BeginArea(new Rect(10, 45, 480, 100));
// GUILayout.EndArea();
userComments = GUI.TextArea(new Rect(10,150,480,150), userComments, 1000);
Debug.Log(scrollPosition.ToString());
GUI.DragWindow(new Rect(0, 0, 10000, 10000));
}
I can literally SEE my scrollPosition change in the Debug.Log… But the GUI isn’t changing for some reason…
WHAT IS THE PROBLEM???
For some reason it just will not work… I have to click the very bottom of the scrollbar and drag UP for it to scroll down… Why is this happening?
I mean, I saw some posts from 2009 that said Unity knew about this bug… I figured it would be fixed in 2014!