> For the complete documentation index, see [llms.txt](https://kinematicsoup.gitbook.io/reactor/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kinematicsoup.gitbook.io/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kspathbox.md).

# Class ksPathBox

Namespace: [KS.Reactor.Client.Unity.Editor](/reactor/api-reference/ks.reactor.client.unity.editor.md)\
Assembly: KSUnity-Source.dll

A text box element with a button to open a file browser.

```csharp
public class ksPathBox : ksTextBox
```

#### Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) ← [ksTextBox](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kstextbox.md) ← [ksPathBox](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kspathbox.md)

#### Inherited Members

[ksTextBox.Label](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kstextbox.md#KS_Reactor_Client_Unity_Editor_ksTextBox_Label), [ksTextBox.Text](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kstextbox.md#KS_Reactor_Client_Unity_Editor_ksTextBox_Text), [ksTextBox.Focused](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kstextbox.md#KS_Reactor_Client_Unity_Editor_ksTextBox_Focused), [ksTextBox.Draw()](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kstextbox.md#KS_Reactor_Client_Unity_Editor_ksTextBox_Draw), [ksTextBox.Focus()](/reactor/api-reference/ks.reactor.client.unity.editor/ks.reactor.client.unity.editor.kstextbox.md#KS_Reactor_Client_Unity_Editor_ksTextBox_Focus), [object.Equals(object)](https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals\(system-object\)), [object.Equals(object, object)](https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals\(system-object-system-object\)), [object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode), [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype), [object.MemberwiseClone()](https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone), [object.ReferenceEquals(object, object)](https://learn.microsoft.com/dotnet/api/system.object.referenceequals), [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Constructors

### ksPathBox(EditorWindow, string, string, string, string) <a href="#ks_reactor_client_unity_editor_kspathbox__ctor_unityeditor_editorwindow_system_string_system_string" id="ks_reactor_client_unity_editor_kspathbox__ctor_unityeditor_editorwindow_system_string_system_string"></a>

Constructor

```csharp
public ksPathBox(EditorWindow window, string label = "", string title = "", string path = "", string extension = "")
```

#### Parameters

`window` EditorWindow

Window this element will be drawn in.

`label` [string](https://learn.microsoft.com/dotnet/api/system.string)

Label for the element.

`title` [string](https://learn.microsoft.com/dotnet/api/system.string)

Title for the file browser window.

`path` [string](https://learn.microsoft.com/dotnet/api/system.string)

Initial text in the text box.

`extension` [string](https://learn.microsoft.com/dotnet/api/system.string)

Extension allowed in the file browser. "/" for folders. "" for all files.

## Properties

### Extension <a href="#ks_reactor_client_unity_editor_kspathbox_extension" id="ks_reactor_client_unity_editor_kspathbox_extension"></a>

Extension filter to apply to files. If the extension is a "/" then a folder selection dialog will be used. All other extensions patterns will be used to filter file selection dialogs.

```csharp
public string Extension { get; set; }
```

#### Property Value

[string](https://learn.microsoft.com/dotnet/api/system.string)

### Title <a href="#ks_reactor_client_unity_editor_kspathbox_title" id="ks_reactor_client_unity_editor_kspathbox_title"></a>

Title of the file browser window.

```csharp
public string Title { get; set; }
```

#### Property Value

[string](https://learn.microsoft.com/dotnet/api/system.string)

## Methods

### Draw() <a href="#ks_reactor_client_unity_editor_kspathbox_draw" id="ks_reactor_client_unity_editor_kspathbox_draw"></a>

Draws the text box.

```csharp
public override bool Draw()
```

#### Returns

[bool](https://learn.microsoft.com/dotnet/api/system.boolean)

True if enter was pressed, if focus was lost and the text changed since focus was received, or if a path was selected in the file browser window.
