GUI Box Coordinates Help

Okay, so I just started reading this: Unity - Manual: IMGUI Basics. But I can’t seem to understand what it’s talking about. (:

I need to make my box bigger and wider. So. Yes. All I need is someone to kind of tell me or explain to me how their coordinate, transform, whatever system works. (:

Here is the code I’m working with. (: Thanks!

void DrawJournalEntries()
	{
		GUI.BeginGroup (new Rect (Screen.width / 2 - 50, Screen.height / 2 - 50, 100, 100));
		// All rectangles are now adjusted to the group. (0,0) is the topleft corner of the group.

		// We'll make a box so you can see where the group is on-screen.
		GUI.Box (new Rect (0,0,100,100), "Group is here");
		GUI.Button (new Rect (10,40,80,30), "Click me");

		// End the group we started above. This is very important to remember!
		GUI.EndGroup ();
	}

If you need to make the box bigger, I’m going to assume it’s the GUI.Box()
So this is how you should do it.

GUI.Box(new Rect(20, 20, 100, 100), "Group is here")
//You have to put some numbers where you put the zeros. That's how you make the box visible.

You just need to know about Rect(). It has 4 parameters to pass.

  1. x coordinate of Starting point of GUI item
  2. y coordinate of Starting point of GUI item
  3. Width of the GUI Item
  4. Height of GUI Item.

so if you are creating a box which should be wide and big, you need to set higher width and height for it in Rect().

For e.g. GUI.Box(new Rect(20, 20, 500, 300), "Group is here");
This will create a box whose starting point is at (20,20) from left top corner of the screen. And if it is inside group then (20,20) from the group’s starting position. Width is 500 px and Height is 300 px. By increasing these value you can have bigger and wider box as much as you want.
This code will give you the bigger and wider box.

void OnGUI () {
		GUI.BeginGroup (new Rect (Screen.width / 2 - 150, Screen.height / 2 - 150, 300, 300));
		// All rectangles are now adjusted to the group. (0,0) is the topleft corner of the group.
		
		// We'll make a box so you can see where the group is on-screen.
		GUI.Box (new Rect (10,10,280,280), "Group is here");
		GUI.Button (new Rect (10,40,80,30), "Click me");
		
		// End the group we started above. This is very important to remember!
		GUI.EndGroup ();
	}