NSWindow
The NSWindow class defines objects (known as windows) that manage and coordinate the windows an application displays on the screen.
NSWindow類通常用來定義一個窗口對象,控制并與應(yīng)用內(nèi)的窗口對象協(xié)作處理顯示屏幕上的視圖患整。
Overview
A single NSWindow object corresponds to at most one onscreen window. The two principal functions of a window are to provide an area in which views can be placed and to accept and distribute, to the appropriate views, events the user instigates through actions with the mouse and keyboard.
一個NSWindow對象最多對應(yīng)屏幕上的一個窗口。窗口的兩個基本功能,其一是為各種視圖層提供了空間隘截,便于將視圖放在窗口里,其二是響應(yīng)并分配用戶通過使用鼠標(biāo)和鍵盤在適當(dāng)?shù)囊晥D層上激發(fā)的交互事件。
Note
Although the NSWindow class inherits the NSCoding protocol from NSResponder? the class does not support coding. Legacy support for archivers exists but its use is deprecated and may not work. Any attempt to archive or unarchive an NSWindow object using a keyed coding object raises an invalidArgumentException exception.
雖然NSWindow類繼承自NSResponder筐钟,并遵守NSCoding協(xié)議,但是這個類并不支持編碼赋朦。之前存在支持歸檔的情況篓冲,但是這種用法已經(jīng)過時李破,可能已經(jīng)沒效了。任何嘗試使用關(guān)鍵coding對象來歸檔或解檔一個NSWindow對象都會拋出? NSInvalidArgumentException 異常纹因。
上班之余喷屋,翻譯技術(shù)文檔之余,吃飯睡覺拉shi之余瞭恰,我翻譯的《明日此時》屯曹,出自美國大作家 @ 魯伯特·考利之筆,另推薦他的另一本暢銷作《火車上的女人》