Acompositing manager, orcompositor, is software that provides applications with an off-screenbuffer for each window, thencomposites these window buffers into an image representing the screen and writes the result into the display memory. Acompositing window manager is awindow manager that is also a compositing manager.[1][2]
Compositing managers may perform additional processing on buffered windows, applying2D and3D animated effects such asblending,fading,scaling,rotation,duplication, bending and contortion, shuffling,blurring, redirecting applications, andtranslating windows into one of a number ofdisplays andvirtual desktops. Computer graphics technology allows for visual effects to be rendered in real time such asdrop shadows, live previews, and complex animation.[3][4]Since the screen isdouble buffered, it does notflicker during updates.
The most commonly used compositing managers and compositing window managers include:
Thewindow manager sends each window amessage to repaint itself when needed. Windows may overlap. When a window in front is moved, it can reveal an area of a window behind that was previously concealed. Window managers are broadly categorised by their strategy for causing that newly revealed area to be displayed to the user. In the "stacking" strategy, the window manager tells the back window to repaint itself. In the "compositing" strategy, the window manager maintains an off-screen memory buffer containing the full appearance of each window, including the back window.
With a stacking manager, the repainting process can become corrupted when a program that is slow, unresponsive orbuggy does not respond to messages in a timely manner.[5][6] A malicious program can cause the system to appear unstable by simply neglecting to repaint its window. Then, one or more of the following conditions may result:
With a compositing manager, if a window stops repainting itself when requested by the window manager, its last repaint will remain displayed and the window might be dimmed. Often, the title changes to reflect the status of the window as unresponsive. A program may prevent its window from being moved or unmapped, but generally will not cause repainting problems.
One of the first systems with a compositing windowing system was the CommodoreAmiga, released in 1985. Applications could first request a region of memory outside the current display region for use as bitmap. The Amiga windowing system would then use a series ofbit blits using the system's hardwareblitter to build a composite of these applications' bitmaps - along with buttons and sliders - in display memory, without requiring these applications to redraw any of their bitmaps.[9]
On March 24, 2001,Mac OS X v10.0 became the first mainstreamoperating system to feature software-based 3D compositing and effects, provided by itsQuartz component. With the release ofMac OS X v10.2 andQuartz Extreme, the job of compositing could move to dedicatedgraphics hardware.[2][10]
In 2003Sun Microsystems demonstrated an ambitious 3D graphics system calledProject Looking Glass to layer on top of itsSwing toolkit. It was first shown at the 2003LinuxWorld Expo. Although Apple threatened to sue Sun for breach ofintellectual-property rights, other window managers have implemented some of the functionality in Looking Glass. By 2006 development was discontinued by Sun, whose primary business was transitioning from graphically orientedUnix workstations to sellingenterprise mainframes.[11]
Microsoft first presented the Desktop Window Manager inProject Longhorn to the 2003Windows Hardware Engineering Conference, demonstratingwobbly windows.[12]Severe delays in the development of Longhorn causedMicrosoft not to debut its 3D-compositing window-manager until the release ofWindows Vista in January 2007.[13]
Implementing compositing under theX Window System required some redesign, which took place incrementally.[14]Metacity 2.8.4 was released in August 2004.[15] However, the first widely publicized compositing window manager forX wasXfwm, released in January 2005.[16] On 26 January 2005Compiz was released, introducing fully accelerated 3D-compositing to the Linux platform.[17]KDE'sKWin also supports compositing.
In compositing, 3D effects could be applied on windows to provide 3D desktop effects. Modern compositing window managers use 3D hardware acceleration. Compositing window manager software communicates with graphics hardware viaprogramming interfaces such asOpenGL orDirect3D.
The earliest widespread implementations using this technique were released for the Mac in Mac OS X 10.2, and for Linux in aLuminocity prototype. Currently, window managers using OpenGL include Compiz, KWin, and the Quartz Compositor, while Desktop Window Manager currently uses DirectX 9. OpenGL is still not fully supported in hardware, so performance of OpenGL-based compositing should continue to improve as hardware improves[citation needed].
Stacking window managers running on theX Window System (X11) required achroma keying or green screeningextension.[citation needed] Compositing was introduced by way of theComposite Extension. Compositing managers use hardware acceleration through this extension, if available.
Under X11, the ability to do full 3D-accelerated compositing required fundamental changes to the window system protocol in order to use hardware acceleration. Originally, a number of modified X11 implementations designed aroundOpenGL began to appear, includingXgl. The introduction ofAIGLX would eliminate the need to use Xgl, and allow window managers to do 3D accelerated compositing on a standard X server, while still allowing fordirect rendering. Currently,NVIDIA,Intel, andATI cards support AIGLX.
Compiz introduced a cube effect, which allows the user to see up to 6 virtual desktops at once. Each desktop is converted into a surface texture of the cube, which can be rotated at will. Compiz displays a wide array of 2D and 3D effects and has relatively low hardware requirements.[18] In 2012, Compiz was included inUbuntu Linux, and was enabled automatically when supported hardware and drivers were available and the user had not selected 2D Mode.[19]
Mutter (Metacity +Clutter) has replaced Metacity as the default window manager forGNOME. It is featured in theGNOME Shell component of GNOME 3.0. It uses the display engine Clutter, which has been ported to all major operating systems,netbooks andsmartphones.
Since version 4, KDE's window managerKWin has compositing capabilities. KWin features much of the same functionality also present inCompiz.
With theWayland protocol, a compositing window manager is also adisplay server; there is no display server separate from the window manager. The combined window manager/display server is called aWayland compositor.Weston is a reference implementation of a Wayland compositor; KWin and Mutter are also Wayland compositors as well as being X11 compositing window managers.
Project Looking Glass was a window manager combining 3D rendering and the cross-platformJava programming language. It is now inactive and released under theGNU General Public License. TheGranular Linuxlive CD distribution includes Looking Glass as an optional window manager.
In the aftermath of it being discontinued, some of its features, such as cover switching and thumbnail live previews, have found their way onto other window managers. Its more original features included window tilting, two-sided window frames andparallax scrolling backgrounds.
While they are able to run on 3D-capable hardware, AmigaOS 4 and MorphOS are designed to run on oldlegacy Amiga computers, starting with theAmiga 1200. As such, their window managers have mostly planar rendering capabilities that include composite layering, alpha blending, gradients, high resolution and multiple desktops ("screens") that can partially clip one another.
While the window manager in Windows 2000 does perform compositing, it does not perform transformations such as a per-pixel alpha. Few commercial applications took advantage of alpha blending;freeware programs were among the first to experiment with it, albeit through optional settings.[20][21] Compositing was introduced withDesktop Window Manager inWindows Vista.[1]
Windows Vista and Windows 7 allow the user to disable Desktop Window Manager by selecting the Windows Basic appearance settings. In addition, it is automatically disabled by Windows in order to performhardware overlay through theOverlay Mixer Filter.
The compositing approach makes it easier to implement a number of features that make the user interface more accessible, simpler to use or witheye candy elements.
Vector graphics, such asTrueType fonts and 3D-accelerated elements, can be expanded without degradation (usually due toaliasing). Ascreen magnifier enlarges an area of the screen, making portions of text easier to read – whether to preventeye strain, for thevisually impaired, or simply at a distance.Zoom effects such as thefish eye magnifier and zoom desktop effects provide this functionality.
A preview of a window can be displayed in a pop-upthumbnail when the userhovers its associatedtaskbar button. This allows the user to identify and manage several concurrently running programs.
Windows with similar names and icons tend to cause confusion, especially when their title bars overlap; the position of every such window on the taskbar has to be memorized. When there are many open windows in this manner, the user often has to resort to trial and error—clicking each taskbar button one-by-one—before proceeding. Window switching allows one to quickly preview several windows at once by temporarily rearranging them against a decorative background. After a selection is made, the windows are then restored to their original arrangement.
Selection begins when the user either enters ahotkey combination, moves the mouse pointer to ahotspot on the screen, or, in some situations, uses the mouse'sscroll wheel. Items are navigated using the keyboard or mouse. An item is selected by either releasing the hotkey, hitting the Enter key or clicking on it with the mouse.
The flip switcher is an enhancement to theAlt-Tab switching feature. Running windows are arranged into a stack – similar to a flip-style selector in a 1950sjukebox, or aRolodex. In some systems, the user can press Alt-Shift-Tab to navigate backwards. Visual transitions are applied to each item while navigating.
Common implementations of flip switching includeFlip 3D in Windows andShift Switcher in Compiz.
Cover switching is like flip switching with a few, mostly visual, differences. Instead of one stack with the selection at the top, two symmetrical stacks are shown with the current selection front and center (similar to the window tilting feature in Looking Glass).
Cover Flow is an implementation of cover switching in macOS. More recent versions use blurring to de-emphasize non-selected items. Cover Flow has also been implemented in other software published byApple such asiTunes.
This is also referred to as "flick-book view."
Ring switching is like flip switching, except the windows move in a circle, with the current selection in front, usually at the bottom. Most compositing window managers include this featureout of the box, andthird-party applications, such as3d-desktop, are also available.
The user can group windows together, such that only one window at a time is visible in each group. In Compiz, the window frame is flipped to indicate when the active window in its group has been changed.
macOS displays a preview of every window on the screen by tiling them. Other systems with similar functionality (Microsoft Windows, Compiz, KWin, third-party applications) are referred to as Exposé clones. The hotkey to activate Exposé is not Alt-Tab, but rather F3.
Mac OS X 10.7 combines several other compositing features developed by Apple—such as Exposé,Dashboard, andSpaces—into a larger program calledMission Control.
On macOS, "widgets" (single-purposeapplets) such as a clock, note pad, and calculator can appear by pressing ahotkey. Widget engines speed work by keeping commonly used widgets accessible while unobtrusive. They are handled by the Dashboard program in macOS.
Compiz starts with a blank Widget Layer, allowing the user to add applications by clicking on them. A variety of widgets are supported, includingScreenlets,gDesklets andSuperKaramba.[22]
Windows Vista providesgadgets that the user can place on theWindows Sidebar (Sidebar gadgets), aWindows Livestart page (Web gadgets), or an external display, such as the user's mobile phone (SideShow gadgets). The Windows Sidebar was a visible partition in Windows Vista, and was eliminated in Windows 7, along with Sidebar gadgets which were changed toDesktop Gadgets.
Before compositing window managers were developed, windows would instantly jump in and out of view, which is incongruent with the interface metaphor (and with a physicaloffice setting). Some systems like theClassic Mac OS avoided this issue withZoomRects, animating the windows outline "zooming" toward its final position.[23] But on most systems, the sudden appearance and disappearance ofGUI elements may seem confusing or even chaotic to inexperienced users.[citation needed] Visual transitions provide context and help distinguish the causal relationships of GUI elements. Instead of just disappearing, a window may fade away, or visibly shrink to the taskbar. A pull-down menu that has been clicked may smoothly radiate outward from the menu bar, making it easier to determine its origin and purpose.
Gradual and natural transitions may be[original research?] especially helpful for elderly or visually impaired users who notice changes to the screen more slowly and with less clarity. For example, an inexperienced user may impulsively click on a menu that was activated by accident, causing him or her to lose work. The short delay necessary to display a visual transition may give the user enough time to make a conscious decision, and avoid such mistakes.
Metisse implements user interface façades, a system that provides users with simple ways to adapt, reconfigure, and recombine existing graphical interfaces, through the use ofdirect manipulation techniques.[24]