home *** CD-ROM | disk | FTP | other *** search
/ The Fred Fish Collection 1.5 / ffcollection-1-5-1992-11.iso / ff_disks / 300-399 / ff308.lzh / ScreenShare / readme < prev    next >
Text File  |  1990-01-18  |  4KB  |  69 lines

  1.  
  2.     screenshare.library
  3.     ===================
  4.  
  5.     This is a proposed scheme to allow applications ("symbionts") to open up
  6. windows on other applications' ("hosts") custom screens.
  7.     There are many reasons for wanting to do this. For example, it is nice
  8. to be able to have AmigaREXX open up a file requester on your application's
  9. screen from outside of your application, and it is useful to be able to open
  10. up your editor on your terminal emulator's screen so you can write your messages
  11. while being able to see the contents of the terminal's screen. Sofar, this has
  12. only been possible by opening all applications on the Workbench. This causes
  13. excessive clutter, and limits you to the Workbench's number of colors and
  14. resolution mode.
  15.     The scheme proposed here consists of an exec library to which prospective
  16. hosts can post their screen pointers and provide them with a unique name.
  17. Symbionts can query the same library and find, given the name, the pointer to 
  18. the host's screen. The method is very simple, does not require SetFunction()ing
  19. any Amiga functions, does not take up very much room, is trivially easy to
  20. implement, and is, above all, safe if both hosts and symbionts obey the rules.
  21. This implies, however, that the method cannot be used transparently with existing
  22. applications not set up properly. This is just as well, because any scheme that
  23. tries to retrofit screen sharing to older applications requires trickery and is
  24. dangerous.
  25.     There are six accessible functions in the screenshare.library, one of
  26. which is mainly a debugging tool and should not normally be called in an
  27. application. A typical host would call the functions: PublicScreen() to declare
  28. a screen public, PubScrLocked() to inquire whether there are any symbionts
  29. currently accessing the screen, and PrivateScreen() to revert a named public
  30. screen to private status. A typical symbiont would call the functions:
  31. LockPubScreen() to obtain a pointer to the Screen structure of a named public
  32. screen, and UnlockPubScreen() to signal to the library that all windows on a
  33. named public screen have been closed by the symbiont. All calls have a single
  34. argument, the name of the public screen (a null-terminated ascii string), with 
  35. the exception of PublicScreen(), which has a pointer to the Screen structure
  36. as the second argument.
  37.     It is possible for a program to be both a host and a symbiont, e.g. 
  38. when the first instance of a program opens a screen, and subsequent instances
  39. want to open on that same screen.
  40.     Further documentation can be found in the file pubscr.c, the main
  41. part of the screenshare.library.
  42.     The functions can be accessed by linking the glue routines contained
  43. in liblink.asm to your host or symbiont.
  44.  
  45.     In this archive, you will find also three utilities: showscr, addscr, 
  46. and addsym. Thes are intended for debugging purposes only, and should typically
  47. not be distributed with your software. Showscr shows the current list of 
  48. shared screens. Addscr can fake a shared screen by adding one to the list. It
  49. can also remove shared screens from the list. Addsym can fake a symbiont 
  50. opening up on a shared screen. It can also remove symbionts.
  51.  
  52.     These files are not in the public domain. They may, however, be
  53. distributed freely, and used freely, in any software, PD or commercial.
  54.  
  55.     Willy Langeveld            11 may 1988
  56.  
  57.  
  58.  
  59.     For this release: the documentation did not state previously that
  60. int return codes from functions are 16 bit values and should more properly
  61. be called short. Also, a minor bug was fixed.
  62.  
  63.     Willy Langeveld            7 september 1989
  64.  
  65.  
  66.     For this release: a bug showed up during 1.4 testing. Now fixed.
  67.  
  68.     Willy Langeveld            9 january 1990
  69.