AppKit

Last updated
Calendar, a macOS application using AppKit. MacOS Calendar.png
Calendar, a macOS application using AppKit.

AppKit (formally Application Kit) [1] is a graphical user interface toolkit. It initially served as the UI framework for NeXTSTEP. [2] Along with Foundation and Display PostScript, it became one of the core parts of the OpenStep specification of APIs. Later, AppKit and Foundation became part of Cocoa, the Objective-C API framework of macOS. GNUstep, GNU's implementation of the OpenStep/Cocoa API, also contains an implementation of the AppKit API.

Contents

AppKit comprises a collection of Objective-C classes and protocols that can be used to build an application in OpenStep/Cocoa. These classes can also be used in Swift through its Objective-C bridge. Xcode has built-in functionality for developing a Cocoa application using AppKit, including the ability to visually design user interfaces with Interface Builder. It relies heavily on patterns like reference types, delegation, notifications, target–action, and model–view–controller. A sign of the NeXTSTEP heritage, AppKit's classes and protocols still use the "NS" prefix.

Most of the applications bundled with macOS—for example, the Finder, TextEdit, Calendar, and Preview—use AppKit to provide their user interface.

macOS, iOS, iPadOS, and tvOS also support other UI frameworks, including UIKit, which is derived from AppKit and uses many similar structures, and SwiftUI, a Swift-only declarative UI framework.

Prior to macOS Catalina, macOS also supported Carbon, a UI framework derived from the Macintosh Toolbox.

Classes

Of the more than 170 classes included in the Application Kit, the following classes form the core: [3]

See also

Related Research Articles

<span class="mw-page-title-main">NeXTSTEP</span> Operating system from NeXT Computer

NeXTSTEP is a discontinued object-oriented, multitasking operating system based on the Mach kernel and the UNIX-derived BSD. It was developed by NeXT Computer in the late 1980s and early 1990s and was initially used for its range of proprietary workstation computers such as the NeXTcube. It was later ported to several other computer architectures.

OpenStep is a defunct object-oriented application programming interface (API) specification for a legacy object-oriented operating system, with the basic goal of offering a NeXTSTEP-like environment on non-NeXTSTEP operating systems. OpenStep was principally developed by NeXT with Sun Microsystems, to allow advanced application development on Sun's operating systems, specifically Solaris. NeXT produced a version of OpenStep for its own Mach-based Unix, stylized as OPENSTEP, as well as a version for Windows NT. The software libraries that shipped with OPENSTEP are a superset of the original OpenStep specification, including many features from the original NeXTSTEP.

Cocoa is Apple's native object-oriented application programming interface (API) for its desktop operating system macOS.

<span class="mw-page-title-main">GNUstep</span> Open source widget toolkit and application development tools

GNUstep is a free software implementation of the Cocoa Objective-C frameworks, widget toolkit, and application development tools for Unix-like operating systems and Microsoft Windows. It is part of the GNU Project.

Carbon was one of two primary C-based application programming interfaces (APIs) developed by Apple for the macOS operating system. Carbon provided a good degree of backward compatibility for programs that ran on Mac OS 8 and 9. Developers could use the Carbon APIs to port (“carbonize”) their “classic” Mac applications and software to the Mac OS X platform with little effort, compared to porting the app to the entirely different Cocoa system, which originated in OPENSTEP. With the release of macOS 10.15 Catalina, the Carbon API was officially discontinued and removed, leaving Cocoa as the sole primary API for developing macOS applications.

The Enterprise Objects Framework, or simply EOF, was introduced by NeXT in 1994 as a pioneering object-relational mapping product for its NeXTSTEP and OpenStep development platforms. EOF abstracts the process of interacting with a relational database by mapping database rows to Java or Objective-C objects. This largely relieves developers from writing low-level SQL code.

<span class="mw-page-title-main">OmniWeb</span> Web browser

OmniWeb is a discontinued web browser that was developed and marketed by The Omni Group exclusively for Apple's macOS operating system. Though a stable version is no longer maintained, it is still available as a free download and unstable versions are still being released.

The Foundation Kit, or just Foundation for short, is an Objective-C framework in the OpenStep specification. It provides basic classes such as wrapper classes and data structure classes. This framework uses the prefix NS. It is also part of Cocoa and of the Swift standard library.

The Dock is a prominent feature of the graphical user interface of macOS. It is used to launch applications and to switch between running applications. The Dock is also a prominent feature of macOS's predecessor NeXTSTEP and OPENSTEP operating systems. The earliest known implementations of a dock are found in operating systems such as RISC OS and NeXTSTEP. iOS has its own version of the Dock for the iPhone and iPod Touch, as does iPadOS for the iPad.

<span class="mw-page-title-main">WebObjects</span> Java web application server and framework originally developed by NeXT Software

WebObjects was a Java web application server and a server-based web application framework originally developed by NeXT Software, Inc.

<span class="mw-page-title-main">Rhapsody (operating system)</span> Apple operating system

Rhapsody is the development series of Apple Computer's next-generation operating system. Targeting only developers for a transition period, its releases came between Apple's purchase of NeXT in late 1996 and the announcement of Mac OS X in 1998. Rhapsody represented a new and exploratory strategy for Apple, more than an operating system, and runs on x86-based PCs and on Power Macintosh. Its OPENSTEP based Yellow Box API frameworks were ported to Windows NT for creating cross-platform applications. Eventually, the non-Apple platforms were discontinued, and later versions consist primarily of the OPENSTEP operating system ported to Power Macintosh, merging the Copland-originated GUI of Mac OS 8 with that of OPENSTEP. Several existing classic Mac OS frameworks were ported, including QuickTime and AppleSearch. Rhapsody can run Mac OS 8 and its applications in a paravirtualization layer called Blue Box for backward compatibility during migration to Mac OS X.

<span class="mw-page-title-main">Interface Builder</span> Developer Application for MacOS

Interface Builder is a software development application for Apple's macOS operating system. It is part of Xcode, the Apple Developer developer's toolset. Interface Builder allows Cocoa and Carbon developers to create interfaces for applications using a graphical user interface. The resulting interface is stored as a .nib file, short for NeXT Interface Builder, or more recently, as an XML-based .xib file.

Core Data is an object graph and persistence framework provided by Apple in the macOS and iOS operating systems. It was introduced in Mac OS X 10.4 Tiger and iOS with iPhone SDK 3.0. It allows data organized by the relational entity–attribute model to be serialized into XML, binary, or SQLite stores. The data can be manipulated using higher level objects representing entities and their relationships. Core Data manages the serialized version, providing object lifecycle and object graph management, including persistence. Core Data interfaces directly with SQLite, insulating the developer from the underlying SQL.

In the macOS, iOS, NeXTSTEP, and GNUstep programming frameworks, property list files are files that store serialized objects. Property list files use the filename extension .plist, and thus are often referred to as p-list files.

<span class="mw-page-title-main">Architecture of macOS</span> Layers of the operating system

The architecture of macOS describes the layers of the operating system that is the culmination of Apple Inc.'s decade-long research and development process to replace the classic Mac OS.

Cocoa Touch is the application development environment for building software programs to run on iOS for the iPhone and iPod Touch, iPadOS for the iPad, watchOS for the Apple Watch, and tvOS for the Apple TV, from Apple Inc.

Objective-C is a high-level general-purpose, object-oriented programming language that adds Smalltalk-style messaging to the C programming language. Originally developed by Brad Cox and Tom Love in the early 1980s, it was selected by NeXT for its NeXTSTEP operating system. Due to Apple macOS’s direct lineage from NeXTSTEP, Objective-C was the standard programming language used, supported, and promoted by Apple for developing macOS and iOS applications until the introduction of the Swift programming language in 2014.

Swift is a high-level general-purpose, multi-paradigm, compiled programming language developed by Apple Inc. and the open-source community. First released in 2014, Swift was developed as a replacement for Apple's earlier programming language Objective-C, as Objective-C had been largely unchanged since the early 1980s and lacked modern language features. Swift works with Apple's Cocoa and Cocoa Touch frameworks, and a key aspect of Swift's design was the ability to interoperate with the huge body of existing Objective-C code developed for Apple products over the previous decades. It was built with the open source LLVM compiler framework and has been included in Xcode since version 6, released in 2014. On Apple platforms, it uses the Objective-C runtime library, which allows C, Objective-C, C++ and Swift code to run within one program.

The Cocoa text system is the linked network of classes, protocols, interfaces and objects that provide typography and text field editing capabilities and to Cocoa applications on Apple's macOS, where it is the primary text-handling system. Although "extremely complex", the standard text-handling abilities of the Cocoa text system have been widely praised as without peer. It is possible to implement a fully featured rich text editor in only a few lines of code.

References