HOME

TheInfoList



OR:

In computer science and visualization, a canvas is a
container A container is any receptacle or enclosure for holding a product used in storage, packaging, and transportation, including shipping. Things kept inside of a container are protected on several sides by being inside of its structure. The term ...
that holds various drawing elements (lines, shapes, text, frames containing others elements, etc.). It takes its name from the
canvas Canvas is an extremely durable plain-woven fabric used for making sails, tents, marquees, backpacks, shelters, as a support for oil painting and for other items for which sturdiness is required, as well as in such fashion objects as handb ...
used in visual arts. It is sometimes called a
scene graph Scene (from Greek σκηνή ''skēnḗ'') may refer to: Arts, entertainment, and media Music *Scene (subculture), a youth subculture from the early 2000s characterized by a distinct music and style. Groups and performers * The Scene who recor ...
because it arranges the logical representation of a user interface or graphical scene. Some implementations also define the spatial representation and allow the user to interact with the elements via a
graphical user interface The GUI ( "UI" by itself is still usually pronounced . or ), graphical user interface, is a form of user interface that allows User (computing), users to Human–computer interaction, interact with electronic devices through graphical icon (comp ...
.


Library support

Various
free and open-source Free and open-source software (FOSS) is a term used to refer to groups of software consisting of both free software and open-source software where anyone is freely licensed to use, copy, study, and change the software in any way, and the source ...
canvas or scene-graph
libraries A library is a collection of materials, books or media that are accessible for use and not just for display purposes. A library provides physical (hard copies) or digital access (soft copies) materials, and may be a physical location or a vir ...
allow developers to construct a user interface and/or user-interface elements for their computer programs. Examples of free and open-source scene-graph canvas options include: * in C
Evas (in EFL)
from the Enlightenment project * in C,
Clutter Clutter and its derivations may refer to any of the following: Excessive physical disorder * Clutter, a confusing, or disorderly, state or collection, and possible symptom of compulsive hoarding * Clutter (marketing), numerous advertisements, ...
, associated with the GNOME project * in C, GTK Scene Graph Kit (GSK) * in C++ or optionally in Qt's own markup language QML:
Qt Quick Qt Quick is a free software Free software or libre software is computer software distributed under terms that allow users to run the software for any purpose as well as to study, change, and distribute it and any adapted versions. Free s ...
, provides
scenegraph
associated with the Qt project * in C++,
OpenSceneGraph OpenSceneGraph is an open-source 3D graphics application programming interface (library or framework), used by application developers in fields such as visual simulation, computer games, virtual reality, scientific visualization and modeling. ...
, a 3D graphics API using
OpenGL OpenGL (Open Graphics Library) is a cross-language, cross-platform application programming interface (API) for rendering 2D and 3D vector graphics. The API is typically used to interact with a graphics processing unit (GPU), to achieve ha ...
* in C++, the
OGRE An ogre ( feminine: ogress) is a legendary monster depicted as a large, hideous, man-like being that eats ordinary human beings, especially infants and children. Ogres frequently feature in mythology, folklore, and fiction throughout the wor ...
engine, based on a scene graph, supports multiple scene managers * in C++, OpenSG, a scene-graph system for real-time graphics, with clustering support and multi-thread safety * in C++, the FlightGear Flight Simulator uses a custom Canvas system ( LGPL'ed via SimGear) that is hardware-accelerated using
OpenSceneGraph OpenSceneGraph is an open-source 3D graphics application programming interface (library or framework), used by application developers in fields such as visual simulation, computer games, virtual reality, scientific visualization and modeling. ...
/
OpenGL OpenGL (Open Graphics Library) is a cross-language, cross-platform application programming interface (API) for rendering 2D and 3D vector graphics. The API is typically used to interact with a graphics processing unit (GPU), to achieve ha ...
, OpenVG/ShivaVG
The FlightGear Canvas system
* in
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
, the
Java FX JavaFX is a software platform for creating and delivering desktop applications, as well as rich web applications that can run across a wide variety of devices. JavaFX has support for desktop computers and web browsers on Microsoft Windows, L ...
scene graph with 2D and 3D functionality * in Tcl and other languages such as
Perl Perl is a family of two High-level programming language, high-level, General-purpose programming language, general-purpose, Interpreter (computing), interpreted, dynamic programming languages. "Perl" refers to Perl 5, but from 2000 to 2019 it ...
, Python ( Tkinter), and
Ruby A ruby is a pinkish red to blood-red colored gemstone, a variety of the mineral corundum (aluminium oxide). Ruby is one of the most popular traditional jewelry gems and is very durable. Other varieties of gem-quality corundum are called sapp ...
, the
Tk toolkit Tk is a free and open-source, cross-platform widget toolkit that provides a library of basic elements of GUI widgets for building a graphical user interface (GUI) in many programming languages. Tk provides a number of widgets commonly needed t ...
provides a canvas widget for 2D graphics * in Tcl and other languages such as
Perl Perl is a family of two High-level programming language, high-level, General-purpose programming language, general-purpose, Interpreter (computing), interpreted, dynamic programming languages. "Perl" refers to Perl 5, but from 2000 to 2019 it ...
and Python,TkZinc
is an extended replacement for the Tk canvas, which adds support for hierarchical grouping, clipping, affine transformations, anti-aliasing, and specific items for air traffic control. Some canvas modules within various libraries do not provide the power of a full scene-graph - they operate at a lower level which requires programmers to provide code such as mapping mouse-clicks to objects in the canvas. Examples of libraries which include such a canvas module include: * in C++,
KDE Plasma Workspaces KDE Plasma 5 is the fifth and current generation of the graphical workspaces environment created by KDE primarily for Linux systems. KDE Plasma 5 is the successor of KDE Plasma 4 and was first released on 15 July 2014. It includes a new defaul ...
br>Corona
canvas * the
Canvas element The canvas element is part of HTML5 and allows for dynamic, scriptable rendering of 2D shapes and bitmap images. It is a low level, procedural model that updates a bitmap. HTML5 Canvas also helps in making 2D games. While the HTML5 canvas ...
in
HTML5 HTML5 is a markup language used for structuring and presenting content on the World Wide Web. It is the fifth and final major HTML version that is a World Wide Web Consortium (W3C) recommendation. The current specification is known as the HT ...
* for
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
, the AWT librar
Canvas
* for
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
, the
Java FX JavaFX is a software platform for creating and delivering desktop applications, as well as rich web applications that can run across a wide variety of devices. JavaFX has support for desktop computers and web browsers on Microsoft Windows, L ...
librar
Canvas
* for
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
, the
Swing Swing or swinging may refer to: Apparatus * Swing (seat), a hanging seat that swings back and forth * Pendulum, an object that swings * Russian swing, a swing-like circus apparatus * Sex swing, a type of harness for sexual intercourse * Swing rid ...
librar
Canvas
* for
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
, the SWT librar
Canvas
associated with
Eclipse An eclipse is an astronomical event that occurs when an astronomical object or spacecraft is temporarily obscured, by passing into the shadow of another body or by having another body pass between it and the viewer. This alignment of three ce ...
* for
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
-like
JavaScript JavaScript (), often abbreviated as JS, is a programming language that is one of the core technologies of the World Wide Web, alongside HTML and CSS. As of 2022, 98% of Website, websites use JavaScript on the Client (computing), client side ...
, the GWT librar
Canvas
* in C++, th
papyrus Canvas library
which renders using the
Cairo (graphics) Cairo (stylized as cairo) is an open-source graphics library that provides a vector graphics-based, device-independent API for software developers. It provides primitives for two-dimensional drawing across a number of different back ends. C ...
library * in C
crcanvas
a
GTK GTK (formerly GIMP ToolKit and GTK+) is a free and open-source cross-platform widget toolkit for creating graphical user interfaces (GUIs). It is licensed under the terms of the GNU Lesser General Public License, allowing both free and prop ...
canvas widget which renders using the
Cairo (graphics) Cairo (stylized as cairo) is an open-source graphics library that provides a vector graphics-based, device-independent API for software developers. It provides primitives for two-dimensional drawing across a number of different back ends. C ...
library * in C
GooCanvas
a
GTK GTK (formerly GIMP ToolKit and GTK+) is a free and open-source cross-platform widget toolkit for creating graphical user interfaces (GUIs). It is licensed under the terms of the GNU Lesser General Public License, allowing both free and prop ...
canvas widget which renders using the
Cairo (graphics) Cairo (stylized as cairo) is an open-source graphics library that provides a vector graphics-based, device-independent API for software developers. It provides primitives for two-dimensional drawing across a number of different back ends. C ...
library Proprietary canvas libraries include, for example: * the Microsoft Windows
Win32 The Windows API, informally WinAPI, is Microsoft's core set of application programming interfaces (APIs) available in the Microsoft Windows operating systems. The name Windows API collectively refers to several different platform implementations ...
br>Canvas


References

{{Reflist Graphical user interface elements