---
title: "init(string:)"
framework: appkit
role: symbol
role_heading: Initializer
path: "appkit/nstextfield/init(string:)"
---

# init(string:)

Initializes a single-line editable text field for user input using the system default font and standard visual appearance.

## Declaration

```swift
convenience init(string stringValue: String)
```

## Parameters

- `stringValue`: A string to use as the initial content of the editable text field.

## Return Value

Return Value A single-line editable text field that displays the specified string.

## See Also

### Creating Text Fields

- [init(labelWithAttributedString:)](appkit/nstextfield/init(labelwithattributedstring:).md)
- [init(labelWithString:)](appkit/nstextfield/init(labelwithstring:).md)
- [init(wrappingLabelWithString:)](appkit/nstextfield/init(wrappinglabelwithstring:).md)
