Unity UI Extensions

UIWindowBase

A draggable window for RectTransforms with bounds checking to keep it within the canvas


Contents

1 Overview

2 Properties

3 Methods

4 Usage

5 Video Demo

6 See also

7 Credits and Donation

8 External links


Overview

A draggable window implementation for RectTransforms that includes bounds checking to ensure the window stays within the canvas area.


Properties

The properties of the UI Window Base control are as follows:

Property Description
Keep Window In Canvas Number of pixels of the window that must stay inside the canvas view
Root Transform The transform that is moved when dragging, can be left empty in which case its own transform is used

Additional properties available in code

Property Return Type Description
ResetCoords bool (static) Set to true to reset the window to its original position

Methods

This component does not expose public methods beyond inherited behaviour.


Usage

Add the UI Window Base component to a RectTransform using:

“Add Component -> UI -> Extensions -> UI Window Base”

Or alternatively, add it via the GameObject menu:

“GameObject -> UI -> Extensions -> Controls -> UI Window Base”


Video Demo

N/A


See also

N/A


Credits and Donation

GXMark, alexzzzz, CaoMengde777, TroyDavis


Sourced from