---
title: synchronizeWindowTitleWithDocumentName()
framework: appkit
role: symbol
role_heading: Instance Method
path: appkit/nswindowcontroller/synchronizewindowtitlewithdocumentname()
---

# synchronizeWindowTitleWithDocumentName()

Synchronizes the displayed window title and the represented filename with the information in the associated document.

## Declaration

```swift
func synchronizeWindowTitleWithDocumentName()
```

## Discussion

Discussion Does nothing if the window controller has no associated document or loaded window. This method queries the window controller’s document to get the document’s display name and full filename path, then calls windowTitle(forDocumentDisplayName:) to get the display name to show in the window title.

## See Also

### Accessing Window Attributes and Content

- [shouldCascadeWindows](appkit/nswindowcontroller/shouldcascadewindows.md)
- [windowFrameAutosaveName](appkit/nswindowcontroller/windowframeautosavename.md)
- [windowTitle(forDocumentDisplayName:)](appkit/nswindowcontroller/windowtitle(fordocumentdisplayname:).md)
- [contentViewController](appkit/nswindowcontroller/contentviewcontroller.md)
- [dismissController(_:)](appkit/nswindowcontroller/dismisscontroller(_:).md)
