World - control a display
#include <InterViews/world.h>
A world was an application's connection to a particular display. It is currently provided for backward compatibility.
World( const char* classname, int& argc, char** argv OptionDesc* = nil, PropertyData* = nil ) Construct the world object for a display. The world's instance name comes from the -name option if it was given; otherwise the instance name comes from the environment variable RESOURCE_NAME if it is nonnil. If the name has still not been defined, then argv[0] with all leading directories stripped is used. The following arguments are interpreted automatically and are removed from argv: -background next argument sets the background color -bg same as -background -display next argument specifies the target workstation display -foreground next argument sets the foreground color -fg same as -foreground -fn same as -font -font next argument sets the text font -geometry next argument sets the first top-level interactor's position and size -iconic starts up the first top-level interactor in iconic form -name next argument sets the instance name of all top-level interactors that don't have their own instance names -reverse swaps default foreground and background colors -rv same as -reverse -synchronous force synchronous operation with the window system -title next argument sets the first top-level interactor's title bar name -xrm next argument sets an ``attribute: value'' property The geometry specification has the form ``=WxH+XOFF+YOFF''. A negative XOFF (YOFF) specifies the offset of the interactor's right (bottom) edge from the right (bottom) side of the screen. The constructor sets argc to the number of uninterpreted arguments that remain. If non-nil, the OptionDesc* parameter is an array of option descriptors used to parse application-specific attributes. OptionDesc contains four fields: a name used on the command line, a path specifying the attribute, a style specifying where the value is, and a default value. Valid styles are OptionPropertyNext (use next argument as an attribute:value pair, not just the value), OptionValueNext (use next argument as value), OptionValueImplicit (use default value), OptionValueIsArg (use argument as value), and OptionValueAfter (use remainder of argument as value). If non-nil, the PropertyData* parameter is an array of structures that each contain three string fields: a path specifying the attribute, a value specifying the value, and a type specifying the type name. Attributes are entered in the following order: first any application defaults (specified by the PropertyData array), then application defaults from /usr/lib/X11/app- defaults/classname, then user defaults (usually in $HOME/.Xdefaults), and finally command-line arguments. Thus, command-line arguments override user defaults, and both override application defaults. const char* name() Return the instance name associated with the world. const char* classname() Return the class name associated with the world. int argc() Return the number of arguments passed to the world (not counting those that were interpreted by the constructor). char** argv() Return the argument vector passed to the world. Font* font() Return the default font associated with the display. If a value for ``font'' is defined at the top-level of the property sheet, then it is used. Otherwise, a system default is used. Color* foreground() Return the default foreground color associated with the display. If a value for ``foreground'' is defined at the top-level of the property sheet, then it is used. Otherwise, a system default is used. Color* background() Return the default background color associated with the display. If a value for ``background'' is defined at the top-level of the property sheet, then it is used. Otherwise, a system default is used. boolean shaped_windows() Return whether the display supports non-rectangular windows. boolean double_buffered() Return whether windows on the display should by default be double-buffered. virtual void flush() Repair all damaged windows on the display and then send any pending requests to the window system. virtual void sync() Repair all damaged windows on the display, send any pending requests to the window system, and wait for an acknowledgement from the window system. Coord width() Return the width in coordinates of the current screen associated with the display. Coord height() Return the height in coordinates of the current screen associated with the display. virtual void run() Read events from the display, handling them as they arrive, and stopping when quit is called. virtual void quit() Terminate the run loop. virtual boolean pending() Return whether any events are waiting to be read. virtual void read(Event&) Read the next event from the world associated with the event. virtual boolean read(long sec, long usec, Event&) Read the next event from the world associated with the event, but do not wait more than sec seconds and usec microseconds. Return whether an event was found in the given time. virtual void unread(Event&) Put the event back on the input queue for the world associated with the event. virtual void poll(Event&) Set the event to an artificial motion event based on the current pointer position and the state of the buttons and meta-keys. virtual void SetScreen(int s) Set the current screen to s. static World* current() Return the current world. The current world is set when a world is created or an event is received for the display associated with a world.
Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.
Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.
Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.
Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.
The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.
Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.
Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.
Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.