# OnPreviewGUI(Rect, GUIStyle)

> Draws the default Terrain Layer preview GUI.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor](/engine/7000.0/script-reference/unityeditor.md)
* **Assembly:** UnityEditor

```csharp
public override void OnPreviewGUI(Rect r, GUIStyle background)
```

### Parameters

**** (\[Rect]\(/engine/7000.0/script-reference/unityengine/rect)): The rectangle in which to draw the preview.**** (\[GUIStyle]\(/engine/7000.0/script-reference/unityengine/guistyle)): Background image.

### Remarks

Additional Resources: [Editor.OnPreviewGUI](/engine/7000.0/script-reference/unityeditor/editor/onpreviewgui.md).
