### Property

# Gtk Viewport:scroll-to-focus

since: 4.0

#### Declaration

    property scroll-to-focus: gboolean [ read, write ]

#### Description [src]

Whether to scroll when the focus changes.

Before 4.6.2, this property was mistakenly defaulting to FALSE, so if your code needs to work with older versions, consider setting it explicitly to TRUE.

Type: | `gboolean`
Available since: | 4.0

Default value | TRUE
Getter method | `gtk_viewport_get_scroll_to_focus()`
Setter method | `gtk_viewport_set_scroll_to_focus()`

#### Flags

Readable | yes
Writable | yes
Construct | no
Construct only | no