home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / std_unix / volume.31 / text0024.txt < prev    next >
Encoding:
Text File  |  1993-07-15  |  9.9 KB  |  241 lines

  1. Submitted-by: preece@urbana.mcd.mot.com (Scott E. Preece)
  2.  
  3.          Towards a Uniform API for GUI Programming
  4.  
  5. Four years ago the IEEE began an effort to produce a
  6. standard GUI API based on X.  After about 30 months of
  7. debate over whether the result should be OPEN LOOK or
  8. OSF/Motif, working group P1201.1 changed course, its new
  9. mission to write a standard for a multi-GUI API, an API that
  10. would be implementable on top of a wide range of GUI bases.
  11. The API must be independent of the look and feel of the
  12. delivered interface, yet must support a wide range of
  13. interface functionality.
  14.  
  15. P1201.1 has gotten technical input from the authors of a
  16. wide range of multi-GUI toolkits and UIMS systems.  The
  17. group has focused its work on developing a programming
  18. language independent model of GUI programming, on which
  19. language specific bindings will be based.  The model
  20. abstracts core elements of the computational model of
  21. several existing multi-GUI toolkits, including XVT, Galaxy,
  22. and THINGS, expressed in an object-based computational model
  23. similar to the programming style of the Xview toolkit.
  24. Interface components are modeled by objects manipulated by
  25. simple object management services (create, destroy, get-
  26. attribute, set-attribute).  The user interface is event-
  27. driven; events are directed to event handlers associated
  28. with each object.
  29.  
  30. P1201.1 has recently released Draft 7 of its document in
  31. progress.  This draft is the first to present the bones of
  32. the entire model (though some areas have only a little flesh
  33. covering the bones).  At the next IEEE POSIX meeting (19-23
  34. April in Irvine, CA) the group will review the entire
  35. document and work on the details of several key areas and
  36. will also begin serious consideration of the C language
  37. binding.
  38.  
  39. At this point the group is looking for an expanded core of
  40. interested parties to validate our model and to contribute
  41. to the completion of the standard.  IEEE standards are
  42. supposed to represent a consensus of opinion of a reasonable
  43. slice of the industry; the current working group is diverse,
  44. but small.  We invite the participation of new members; this
  45. meeting would be an especially useful time to join in, as we
  46. will be reviewing the whole document to figure out writing
  47. assignments for completing the language-independent
  48. specification and will be making decisions about the form of
  49. the C API.
  50.  
  51. We would especially appreciate participation of vendors,
  52. implementors, and users of multi-GUI toolkits, who could
  53. apply their experience to identifying problems or gaps in
  54. our model.
  55.  
  56. The meeting is 19-23 April 1993 and will be held at the
  57. Irvine Marriott Hotel, in Irvine, CA.  The room rate for
  58. this meeting is $88, single occupancy, if reserved before 26
  59. March (the hotel telephone number is 714-553-0100, specify
  60. the IEEE P1003 meeting).
  61.  
  62. Although IEEE TCOS meetings are open to all, they are not
  63. free.  The IEEE charges $200 ($230 with four days lunches
  64. included) to attend TCOS meetings.  To get a registration
  65. form, call Brenda Williams at the IEEE Computer Society
  66. (telephone 202-371-0101); she can also provide forms for
  67. subscribing to the mailing service that distributes work
  68. group documents.
  69.  
  70. I am the Chair of P1201.1.  I would be happy to try to
  71. answer questions about the meetings and to provide copies of
  72. the current draft to those who plan to participate or who
  73. would like to review it and comment electronically.
  74.  
  75. If you do decide to come to the meeting, please let me know
  76. (preferably by e-mail), so I can track copying and space
  77. requirements.
  78.  
  79.            Scott Preece
  80.            Motorola Computer Group
  81.            1101 E. University Avenue,
  82.            Urbana, IL   61801
  83.  
  84.            Internet e-mail:  preece@urbana.mcd.mot.com
  85.            Telephone:        217-384-8589
  86.            Fax:              217-384-8550
  87.  
  88.  
  89. The remainder of this posting is a low-resolution overview
  90. of our computational model.
  91.  
  92. ===========================================================
  93.  
  94.     The P1201.1 Uniform API for GUI Programming
  95.  
  96. The Uniform API (UAPI) defines a set of services for defining
  97. an application's user interface.  An interface programmed to
  98. the UAPI sufficiently abstract that it can be mapped into any
  99. of a wide range of native window systems.
  100.  
  101. The UAPI remains abstract by limiting the application's
  102. ability to specify low-level visual details and by allowing
  103. the application to use opaque representations of primitives
  104. obtained, by the implementation, from the native window
  105. system.
  106.  
  107. This model defers many decisions about placement, visual
  108. representation, and other aspects of the user interface to
  109. the implementation, which must support the UAPI primitives
  110. in a way appropriate to the native window system.  In
  111. principle, the application uses the UAPI primitives to say
  112. what interactions are possible between the user and the
  113. application, without saying very much about how those
  114. interactions are implemented or what they look like to the
  115. user.
  116.  
  117. Application Model > The UAPI presents an event-driven model
  118. of interaction between the application code and the user
  119. interface.
  120.  
  121. The UAPI toolkit reacts to user actions by calling
  122. application-provided event handler routines corresponding to
  123. the individual actions each visual object supports.  Each
  124. user action represented in the UAPI model has a
  125. corresponding event.
  126.  
  127. When the application instantiates a window or control, it
  128. can provide handlers for any events that object supports.
  129.  
  130. The UAPI implementation provides an event loop, to which the
  131. application hands control after constructing the needed
  132. objects and handlers and setting up any required initial
  133. state.  The event loop waits for user actions (or
  134. notifications from time or data driven application
  135. components) and dispatches them to the appropriate event
  136. handlers.
  137.  
  138. Objects and Attributes > An application defines its interface
  139. in terms of objects that appear on the user's display.  Each
  140. object belongs to an object class that defines what the
  141. behavior of the object is and what internal state it
  142. contains.
  143.  
  144. Most interaction between objects in the UAPI or between the
  145. application and the objects defining its user interface
  146. occurs through the manipulation of attributes of the object.
  147. All objects of a given class contain the same attributes.
  148. The toolkit provides operations to get or set the value of
  149. each attribute.
  150.  
  151.      Some attributes represent the object's stored data;
  152.      setting such an attribute determines the value which
  153.      will be retrieved by subsequently getting the value of
  154.      the same attribute.
  155.  
  156.      Some attributes represent structural information about
  157.      the object, provided by the toolkit; setting the value
  158.      of such an attribute may not be allowed or may have
  159.      side effects beyond changing the value.
  160.  
  161.      Some attributes are handles through which the
  162.      application can determine the behavior of the object;
  163.      setting such an attribute has side effects which may
  164.      not be directly reflected in the value retrieved by
  165.      getting the value of the attribute.
  166.  
  167. An enclosure object corresponds to an screen area displayed
  168. to the user in which the application may place other visual
  169. objects.
  170.  
  171. A control is an object corresponding to a visual element
  172. with which the user may interact.
  173.  
  174. Non-visual objects provide supporting functionality for the
  175. application to use, such as lists and timers, but do not
  176. directly correspond to anything visible on screen.
  177.  
  178. Events >            Each class of object recognizes a
  179. defined set of user actions as indicating events which
  180. should be transmitted to the application.  The application
  181. may associate one or more event handler routines with each
  182. event the object can generate.  When a user action occurs,
  183. the toolkit calls all the event handlers for the
  184. corresponding event, providing each with a piece of data
  185. supplied by the application and with information describing
  186. the exact nature of the event.
  187.  
  188. The application can also send events to objects and objects
  189. may send events to other objects.
  190.  
  191. Fonts >             A font is an object designating a
  192. particular style of text display.  The UAPI provides
  193. services for obtaining a native font object by attribute
  194. matching or by user interaction.  A UAPI implementation is
  195. required to provide font objects with certain common names,
  196. so that a portable application may request certain common
  197. text style distinctions.
  198.  
  199. Color >             A color is an object designating a
  200. particular style of visual presentation of an area of a
  201. screen.  The UAPI provides services for obtaining a native
  202. color object by attribute matching or by user interaction.
  203. A UAPI implementation is required to provide color objects
  204. with certain common names, so that a portable application
  205. may request certain common visual distinctions.
  206.  
  207. Help System >       The UAPI will include interfaces for
  208. registering and providing help services; this area is still
  209. under discussion.  The goal is to support delivery using (a)
  210. a native help system, (b) an enterprise help system, or (c)
  211. a toolkit-provided help system.
  212.  
  213. Resources >         Resources are object definitions defined
  214. and stored external to the application and used to provide
  215. attribute values when objects are instantiated.
  216.  
  217. A UAPI toolkit must provide a tool which reads resource
  218. definitions in a standard format and sets the stored
  219. resources for an application appropriately.
  220.  
  221. Selections >        A selection is a named piece of data
  222. made available to the application.  A selection may be made
  223. available by the application or by the UAPI implementation;
  224. the toolkit may provide a selection either as a result of an
  225. interaction with the user designating a value as a selection
  226. or as a result of external events, including actions of
  227. other applications.
  228.  
  229. An implementation provides one or more selection lists, each
  230. containing one or more named selections, each of which is
  231. available in one or more named formats.
  232.  
  233. Selections also provide a protocol for exchanging data
  234. dynamically, using a sequence of events passed back and
  235. forth between the provider of the selection and the
  236. application.  This dynamic exchange also provides drag-and-
  237. drop capabilities.
  238.  
  239. Volume-Number: Volume 31, Number 27
  240.  
  241.