home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / cl-lib07.zip / news.txt < prev    next >
Text File  |  1995-06-27  |  32KB  |  903 lines

  1. ===============================================================================
  2. Changes in PM library from version 0.6 to 0.7
  3. ===============================================================================
  4.  
  5. This file provides necessary information for users of the PM class library.
  6. The main documentation was not changed since the last version was released.
  7. If you already printed the manual before, just read this information!
  8.  
  9. The main difference between the last version of the class library and the
  10. current one is the addition of archiving methods (read:, write:, awake and
  11. createInPMWindow:) to the window classes. So whole dialog windows can be
  12. saved in Typed streams and reloaded afterwards. Theoretically, you could create
  13. Objects with a program on one machine and transfer them via typed streams to
  14. another machine on the local network...
  15.  
  16. Additionally some new classes were introduced, simplifying the handling of
  17. Presentation Manager Help Windows and Printing.
  18.  
  19. In this reference, the archiving methods are not described. You can assume
  20. "read:" to read an object from a typed stream, "write:" to archive the object
  21. to the specified stream and "awake" and "createInPMWindow:" to prepare the
  22. object after unarchiving. You should never call any of those methods in one
  23. of your programs. In addition to the size and position, the font and size
  24. selected for the window objects are saved. For container classes, also the
  25. data is stored on a stream, so don't forget to implement read:, write: and
  26. awake: methods for the data stored in your container, if you plan to archive
  27. container classes containing data.
  28.  
  29. Methods not described here are used internally by the library and should never
  30. be modified or used by your own applications.
  31.  
  32.  
  33. 1. New classes:
  34. ===============
  35.  
  36. The classes newly introduced with this version of the library are:
  37.  
  38.     * DelegateWindow
  39.     * FactoryWindow
  40.     * Help
  41.     * InterfaceFile
  42.     * PresentationSpace and
  43.     * Printer
  44.  
  45.  
  46. 1.1. DelegateWindow:
  47. --------------------
  48.     "DelegateWindow" is derived directly from "Window". It is the super-
  49.     class of "FactoryWindow", the class most other window classes are 
  50.     derived from.
  51.  
  52.     From this version of the library on, most window classes can interact
  53.     with delegate objects. This class provides the basic functionality to
  54.     handle the connection of an object with it's delegate.
  55.  
  56.  
  57.  Instance Variables:
  58.  
  59.  *    id delegate
  60.     This instance variable stores a pointer to the delegate object.
  61.  
  62.  
  63.  Methods:
  64.  
  65.  *    init
  66.     "init" initializes the object and sets "delegate" to nil.
  67.  
  68.  *    setDelegate: anObject
  69.     Using this method, you can set the window's delegate-object to
  70.     "anObject".
  71.  
  72.  *    delegate
  73.     "delegate" returns a pointer to the current delegate object.
  74.  
  75.  
  76. 1.2. FactoryWindow:
  77. -------------------
  78.     Most PM windows can send notification messages to their owner windows.
  79.     Using this class as a superclass of most other window classes enables
  80.     them to directly react to those notification messages. So you can now
  81.     easily and directly bind commands sent by buttons to some method in
  82.     another object. See the description of "Button" for more information.
  83.  
  84.  
  85.  Instance Variables:
  86.  
  87.  *    HWND owner
  88.     The new owner window handle of all window objects.
  89.  
  90.  
  91.  Methods:
  92.  
  93.  *    initIn: (Window *) aParent
  94.     Initializes the object and creates a new owner window.
  95.  
  96.  *    associate: (HWND) hwnd
  97.     Used to bind an already existing PM window object to an Objective C
  98.     object. Either this method or one of the "init*" methods must be
  99.     used after allocating memory for the object using [... alloc] and
  100.     before using the object itself.
  101.  
  102.  *    destroy
  103.     Destroy the owner window and it's associated children.
  104.  
  105.  
  106. 1.3. Help:
  107. ----------
  108.     This class is used to enable your applications to use the PM online
  109.     Help feature. Just create a help file using e.g. ipfc.exe and add an
  110.     instance of "Help" to your application.
  111.  
  112.     Follow these steps to add help to your application:
  113.  
  114.     1. add a help menu to your main window or help buttons to your dialog
  115.        windows.
  116.  
  117.     2. allocate a help object and inialize it.
  118.  
  119.     3. associate the help object with your main window.
  120.  
  121.     4. create command bindings for your menu items/buttons
  122.  
  123.     Before closing your app, free the help object.
  124.  
  125.     The object can display help for the standard topics:
  126.  
  127.         "Help for Help" (How to use the online help feature)
  128.         "Extended Help" (show the first help page)
  129.         "Help index" (show the help index)
  130.  
  131.     Additionally the object can display a specified help page.
  132.  
  133.  
  134.  Instance Variables:
  135.  
  136.  *    BOOL helpEnabled
  137.     flag showing, if the help object was initialized correctly and the
  138.     online help feature can be used.
  139.  
  140.  *    HWND helpInstance
  141.     window handle of the help window.
  142.  
  143.  
  144.  Methods:
  145.  
  146.  *    initForApp: (StdApp *) anApp helpFile: (char *) fileName
  147.     calls "initForApp: anApp helpFile: fileName withTitle: "Help"
  148.             helpTable: 1000".
  149.  
  150.  *    initForApp: (StdApp *) anApp helpFile: (char *) fileName
  151.      withTitle: (char *) helpTitle
  152.     calls "initForApp: anApp helpFile: fileName withTitle: helpTitle
  153.             helpTable: 1000".
  154.  
  155.  *    initForApp: (StdApp *) anApp helpFile: (char *) fileName
  156.      withTitle: (char *) helpTitle helpTable: (ULONG) helpTableID
  157.     initializes the help object. "fileName" is the name of the help file.
  158.     "helpTitle" is the title of the help window, "helpTableID" is the
  159.     ID of the help table in the resource file.
  160.  
  161.     "anApp" must be a pointer to an initialized instance of "StdApp".
  162.  
  163.  *    free
  164.     frees the object and all resources allocated.
  165.  
  166.  *    associateWith: aWindow
  167.     Before using a help object with your main window, you must associate
  168.     the help object with it. This is accomplished using this method.
  169.  
  170.  *    helpForHelp: sender
  171.     Display information on how to use the help system. This method can
  172.     be bound directly to a menu item.
  173.  
  174.  *    helpExtended: sender
  175.     Display the first help page according to the help table specified.
  176.     This method can be bound directly to a menu item.
  177.  
  178.  *    helpIndex: sender
  179.     This method displays the help index, if available. It can be bound
  180.     directly to a menu item.
  181.  
  182.  *    helpFor: sender
  183.     This method is used to display a special help topic. The topic is
  184.     specified by the sending object. The number of the topic (which is
  185.     the number also specified in the .ipf source file) is specified
  186.     by [sender tag]. Can be bound directly to a menu item or button.
  187.     If this method is bound to a button or a menu item via "bindCommand:
  188.     withObject: selector:", the sending object is the window, in which the
  189.     control resides. If bound to a button using the button's "bindWith:
  190.     selector:" method, the sending object is the button itself.
  191.  
  192.  *    helpForTopic: (int) topic
  193.     Display help page specified by "topic".
  194.  
  195.  
  196. 1.4. InterfaceFile:
  197. -------------------
  198.     As most of the classes in the library now provide support for
  199.     archiving, a class is provided to group many dialog objects (and also
  200.     command bindings etc.) into one object to simplify archiving and
  201.     unarchiving.
  202.  
  203.     This class is used as the root class for archiving by all files created
  204.     by the "Interface Builder" program.
  205.  
  206.     Instances of this class can store objects, command bindings, bindings
  207.     of instance variables of type "id" to other objects also stored and
  208.     objects not archived but created at run-time.
  209.  
  210.     Only standard objects are supported now.
  211.  
  212.     The objects are stored with a unique string key associated. The objects
  213.     can be queried either by index or by key. Querying by key is
  214.     recommended because the index can change after archiving/unarchiving.
  215.  
  216.  
  217.  Methods:
  218.  
  219.  *    init
  220.     Initialize the object
  221.  
  222.  *    free
  223.     free the memory allocated by this object
  224.  
  225.  *    freeObjects
  226.     free this object and all objects stored
  227.  
  228.  *    freeAll
  229.     free this object, all objects stored and all command/outlet bindings.
  230.  
  231.  *    (char *) keyFor: (int) index
  232.     return the key for the object stored at index "index".
  233.  
  234.  *    objectFor: (int) index
  235.     return the object stored at index "index".
  236.  
  237.  *    (int) objectCount
  238.     return the number of objects already stored. Index range is from
  239.     0 to objectCount - 1.
  240.  
  241.  *    addObject: anObject withKey: (char *) aKey
  242.     add the object "anObject" with the key "aKey" to the interface file.
  243.     "aKey" must be a unique, NULL-terminated string. On failure, nil
  244.     is returned, otherwise self.
  245.  
  246.  *    objectForKey: (char *) aKey
  247.     returns the object stored with key "aKey". If none could found, nil
  248.     is returned.
  249.  
  250.  *    deleteObjectWithKey: (char *) aKey
  251.     delete the object specified by "aKey" from the interface file.
  252.  
  253.  *    (int) indexForKey: (char *) aKey
  254.     return the index of the object stored with "aKey"
  255.  
  256.  *    (int) indexForObject: anObject
  257.     return the index of the object pointed to by "anObject"
  258.  
  259.  
  260. 1.5. PresentationSpace:
  261. -----------------------
  262.     PM uses presentation spaces whenever drawing shall take place. This
  263.     class provides an encapsulation of *some few* access methods to
  264.     presentation spaces, mainly those for drawing text and selecting
  265.     fonts. More methods for drawing etc. will follow.
  266.  
  267.     You should not use an instance of this object directly. Only instances
  268.     of "Printer", a subclass of "PresentationSpace" were tested.
  269.  
  270.  
  271.  Methods:
  272.  
  273.  *    (LONG) witdhInPels
  274.     return the width of the presentation space (or the printer form)
  275.     in pixels.
  276.  
  277.  *    (LONG) witdhInMm
  278.     return the width of the presentation space (or the printer form)
  279.     in mm.
  280.  
  281.  *    (LONG) heightInPels
  282.     return the height of the presentation space (or the printer form)
  283.     in pixels.
  284.  
  285.  *    (LONG) heightInMm
  286.     return the height of the presentation space (or the printer form)
  287.     in mm.
  288.  
  289.  *    (LONG) xResolution
  290.     returns the horizontal *font* resolution in dpi.
  291.  
  292.  *    (LONG) yResolution
  293.     returns the vertical *font* resoultion in dpi.
  294.  
  295.  *    (LONG) textHeight
  296.     returns the height of the currently selected font in pixels.
  297.  
  298.  *    setSpacing: (float) ratio
  299.     When printing text boxes, the lines are separated by (ratio - 1) *
  300.     "textHeight" pixels. For normal text you should use a spacing ratio
  301.     of 1.2.
  302.  
  303.  *    (float) spacing
  304.     returns the current spacing ratio for text boxes.
  305.  
  306.  *    setFont: (char *) fontName
  307.     This method selects a font by name. The point size currently selected
  308.     is not changed.
  309.  
  310.     Example:     [printer setFont: "Helvetica"]; // select Helvetica font
  311.  
  312.  *    setFont: (char *) fontName at: (LONG) pointSize
  313.     set the font to "fontName" and the size to "pointSize".
  314.  
  315.     Example:     [printer setFont: "Courier" at: 12]; // select Courier at
  316.                               // 12 pt.
  317.  
  318.  *    setFontSize: (LONG) pointSize
  319.     set the size of the current font in printer points.
  320.  
  321.  *    (LONG) stringWidth: (char *) aString
  322.     returns the width of the "aString" in pixels.
  323.  
  324.  *    (LONG) stringBoxWidth: (char *) stringBox
  325.     A string box is a string including newline characters. The lines are
  326.     drawn left-aligned separated by the spacing ratio.
  327.  
  328.     This method returns the width of a string box. The width of a string
  329.     box is the width of the longest line in the box.
  330.  
  331.  *    (LONG) stringBoxHeight: (char *) stringBox
  332.     Returns the height of the string box in pixels.
  333.  
  334.  *    string: (char *) aString
  335.     Draw "aString" at the current position with the current font and
  336.     pointsize.
  337.  
  338.  *    string: (char *) aString at: (LONG) x : (LONG) y
  339.     Draw "aString" at position (x/y) with the current font and size.
  340.     "x" and "y" are measured in pixels.
  341.  
  342.  *    stringBox: (char *) stringBox
  343.     Draw the string box at the current position with the current font and
  344.     pointsize. The line spacing ratio can be set using "setSpacing:".
  345.  
  346.  *    stringBox: (char *) stringBox at: (LONG) x : (LONG) y
  347.     Draw the string box at (x/y) with the current font and pointsize.
  348.  
  349.  *    lineTo: (LONG) x : (LONG) y
  350.     Draw a line from the current position to (x/y). "x" and "y" are
  351.     measured in pixels.
  352.  
  353.  *    lineFrom: (LONG) x0 : (LONG) y0 to: (LONG) x : (LONG) y
  354.     Draw a line from (x0/y0) to (x/y).
  355.  
  356.  
  357. 1.6. Printer:
  358. -------------
  359.     To simplify printing from your applications, this class is provided.
  360.     The "Printer" class can be used to initialize the printer object and
  361.     select the current printer/printer job properties.
  362.  
  363.     To control spooling, use the methods "beginSpool: appTitle:",
  364.     "endSpool" and "newPage".
  365.  
  366.  
  367.  Methods:
  368.  
  369.  *    initForApp: (StdApp *) anApp
  370.     initializes the printer object. "anApp" must be a pointer to your
  371.     application object.
  372.  
  373.  *    free
  374.     free all memory associated with this object and perform a clean-up.
  375.  
  376.  *    beginSpool: (char *) spoolTitle appTitle: (char *) appTitle
  377.     Start a print job on the currently selected printer. This must
  378.     be ended using "endSpool". Terminating a print job is not supported
  379.     at the moment.
  380.  
  381.     While spooling, you *must not* call either "beginSpool: appTitle:",
  382.     "printerSetup:", "setDefault" or "jobProperties:".
  383.  
  384.     "spoolTitle" is shown in the settings notebook of a print job,
  385.     "appTitle" is shown in the icon view of any printer object.
  386.  
  387.  *    endSpool
  388.     end the current print job and eject the page.
  389.  
  390.  *    newPage
  391.     eject the current page and start a new one.
  392.  
  393.  *    printerSetup: sender
  394.     This method displays the setup dialog specified by "setSetupDialog:".
  395.     This method can be bound directly to a menu item.
  396.  
  397.  *    setSetupDialog: aSetupDialog
  398.     The setup dialog *must* contain a listbox with PM id 1000 and a
  399.     job properties push button with id 1001. The list is automatically
  400.     initialized when calling "printerSetup:"
  401.  
  402.  *    setupDialog
  403.     returns a pointer to the current setup dialog.
  404.  
  405.  *    jobProperties: sender
  406.     display the job properties dialog. This method should not be called
  407.     directly by your application.
  408.  
  409.  
  410. 2. Changes to old classes:
  411. ==========================
  412.  
  413. This section describes the changes made to already existing classes in the
  414. library. The addition of archiving methods is not stated explicitly for every
  415. class. All window classes are now derived from "DelegateWindow", supporting
  416. "setDelegate:" and "delegate" methods now.
  417.  
  418. 2.1. Button:
  419. ------------
  420.     "Button" is now a subclass of "FactoryWindow".
  421.  
  422.     New methods to directly bind a command to a button (also a checkbox,
  423.     a radiobutton, etc.) were introduced. These are:
  424.  
  425.  *    setTarget: aTarget
  426.     Set the target object for a command. This *must* be specified after
  427.     setting the action.
  428.  
  429.  *    setAction: (SEL) anAction
  430.     Set the method to be called when the button is clicked.
  431.  
  432.  *    bindWith: anObject selector: (SEL) aSel
  433.     Bind the button with "anObject" and selector "aSel".
  434.  
  435.     Example:    [button bindWith: help selector: @selector(helpFor:)];
  436.  
  437.     is equivalent to:
  438.  
  439.             [button setAction: @selector(helpFor:)];
  440.             [button setTarget: help];
  441.  
  442.     If possible, you should use the methods of Button to bind the commands,
  443.     instead of the bindCommand: with: selector: method of the dialog or
  444.     main window, the button is in. Those should only be used to bind
  445.     menu items to methods!
  446.  
  447.  
  448. 2.2. Container:
  449. ---------------
  450.     Container now supports notifying the delegate when some special user
  451.     interactions occured. Note, that the following methods are not methods
  452.     implemented by the "Container" class, but can be implemented by a
  453.     delegate object.
  454.  
  455.  *    stringChanged: (CNREDITDATA *) editData
  456.     This method is called, whenever the user changes a string value in
  457.     the container by direct editing.
  458.  
  459.  *    changeString: (CNREDITDATA *) editData
  460.     If the user edits a string, normally a new memory block must be
  461.     allocated to store it. When this delegate method returns a non-nil
  462.     value, the new string is copied into the buffer specified in
  463.     "editData". If nil is returned, the string is not copied.
  464.  
  465.  *    enterPressed: (NOTIFYRECORDENTER *) recordEnter
  466.     When the user double-clicks in the container or presses Enter, the
  467.     container sends this message to the delegate. So the delegate can
  468.     respond to this action by performing some application-specific
  469.     functionality.
  470.  
  471.  *    showContextMenu: (PRECORDCORE) recordCore
  472.     When the user tries to bring up the contextmenu, in the container
  473.     object, the delegate object is notified. If the mouse pointer is over
  474.     a container item, recordCore is a pointer to the RECORDCORE structure
  475.     of this item.
  476.  
  477.     Normally, the delegate method should use WinPopupMenu to display a
  478.     context menu.
  479.  
  480.  
  481. 2.3. EntryField:
  482. ----------------
  483.     New methods to set or query the contents of the entry field were
  484.     added, conforming to the "Value" protocol
  485.  
  486.  *    (char *) stringValue
  487.     retrieve the contents of the entry field as a string. The string must
  488.     be freed afterwards using free ().
  489.  
  490.  *    (int) intValue
  491.     retrieve the contents of the entry field as an integer.
  492.  
  493.  *    (long) longValue
  494.     retrieve the contents of the entry field as a long integer.
  495.  
  496.  *    (float) floatValue
  497.     retrieve the contents of the entry field as a floating point value.
  498.  
  499.  *    setStringValue: (char *) aValue
  500.     set the contents of the entry field as a string.
  501.  
  502.  *    setIntValue: (int) aValue
  503.     set the contents of the entry field as an integer.
  504.  
  505.  *    setLongValue: (long) aValue
  506.     set the contents of the entry field as a long integer.
  507.  
  508.  *    setFloatValue: (float) aValue
  509.     set the contents of the entry field as a floating point value.
  510.  
  511.  
  512. 2.4. FileDlg:
  513. -------------
  514.  *    runModalFor: sender
  515.     This method returns self if the dialog could be run modal and nil
  516.     otherwise. The result of the dialog processing can be retrieved via
  517.     "result".
  518.  
  519.  *    (ULONG) result
  520.     returns the result of the last dialog execution.
  521.  
  522.  
  523. 2.5. Notebook:
  524. --------------
  525.     Notebook is now derived from "FactoryWindow". Basic support for
  526.     creating and deleting pages is provided.
  527.  
  528.  *    (ULONG) createTopPageWithStatusText: (BOOL) stFlag
  529.     Calling this method creates a new FIRST page (top page) for the
  530.     notebook window.
  531.  
  532.     If "stFlag" is YES, an area for status text is reserved. The status
  533.     text can be set using [notebook setStatusLineTextFor: to:].
  534.  
  535.     This method returns a handle (ULONG) to the page created. It must be
  536.     used when setting the status text, inserting a page before or after
  537.     a special one, or deleting a page.
  538.  
  539.  *    (ULONG) createMajorTopPageWithStatusText: (BOOL) stFlag
  540.     Calling this method creates a new FIRST page (top page) for the
  541.     notebook window. The page has a MAJOR tab attribute.
  542.  
  543.     If "stFlag" is YES, an area for status text is reserved. The status
  544.     text can be set using [notebook setStatusLineTextFor: to:].
  545.  
  546.     This method returns a handle (ULONG) to the page created. It must be
  547.     used when setting the status text, inserting a page before or after
  548.     a special one, or deleting a page.
  549.  
  550.  *    (ULONG) createMinorTopPageWithStatusText: (BOOL) stFlag
  551.     Calling this method creates a new FIRST page (top page) for the
  552.     notebook window. The page has a MINOR tab attribute.
  553.  
  554.     If "stFlag" is YES, an area for status text is reserved. The status
  555.     text can be set using [notebook setStatusLineTextFor: to:].
  556.  
  557.     This method returns a handle (ULONG) to the page created. It must be
  558.     used when setting the status text, inserting a page before or after
  559.     a special one, or deleting a page.
  560.  
  561.  *    (ULONG) createLastPageWithStatusText: (BOOL) stFlag
  562.     Calling this method creates a new LAST page for the notebook window.
  563.  
  564.     If "stFlag" is YES, an area for status text is reserved. The status
  565.     text can be set using [notebook setStatusLineTextFor: to:].
  566.  
  567.     This method returns a handle (ULONG) to the page created. It must be
  568.     used when setting the status text, inserting a page before or after
  569.     a special one, or deleting a page.
  570.  
  571.  *    (ULONG) createMajorLastPageWithStatusText: (BOOL) stFlag
  572.     Calling this method creates a new LAST page for the notebook window.
  573.     The page has a MAJOR tab attribute.
  574.  
  575.     If "stFlag" is YES, an area for status text is reserved. The status
  576.     text can be set using [notebook setStatusLineTextFor: to:].
  577.  
  578.     This method returns a handle (ULONG) to the page created. It must be
  579.     used when setting the status text, inserting a page before or after
  580.     a special one, or deleting a page.
  581.  
  582.  *    (ULONG) createMinorLastPageWithStatusText: (BOOL) stFlag
  583.     Calling this method creates a new LAST page for the notebook window.
  584.     The page has a MINOR tab attribute.
  585.  
  586.     If "stFlag" is YES, an area for status text is reserved. The status
  587.     text can be set using [notebook setStatusLineTextFor: to:].
  588.  
  589.     This method returns a handle (ULONG) to the page created. It must be
  590.     used when setting the status text, inserting a page before or after
  591.     a special one, or deleting a page.
  592.  
  593.  *    (ULONG) createPageBefore: (ULONG) pageID withStatusText: (BOOL) stFlag
  594.     Calling this method creates a new page for the notebook window. The
  595.     page is inserted BEFORE the page specified by "pageID".
  596.  
  597.     If "stFlag" is YES, an area for status text is reserved. The status
  598.     text can be set using [notebook setStatusLineTextFor: to:].
  599.  
  600.     This method returns a handle (ULONG) to the page created. It must be
  601.     used when setting the status text, inserting a page before or after
  602.     a special one, or deleting a page.
  603.  
  604.  *    (ULONG) createMajorPageBefore: (ULONG) pageID 
  605.                        withStatusText: (BOOL) stFlag
  606.     Calling this method creates a new page for the notebook window. The
  607.     page is inserted BEFORE the page specified by "pageID". MAJOR tab.
  608.  
  609.     If "stFlag" is YES, an area for status text is reserved. The status
  610.     text can be set using [notebook setStatusLineTextFor: to:].
  611.  
  612.     This method returns a handle (ULONG) to the page created. It must be
  613.     used when setting the status text, inserting a page before or after
  614.     a special one, or deleting a page.
  615.  
  616.  *    (ULONG) createMinorPageBefore: (ULONG) pageID 
  617.                        withStatusText: (BOOL) stFlag
  618.     Calling this method creates a new page for the notebook window. The
  619.     page is inserted BEFORE the page specified by "pageID". MINOR tab.
  620.  
  621.     If "stFlag" is YES, an area for status text is reserved. The status
  622.     text can be set using [notebook setStatusLineTextFor: to:].
  623.  
  624.     This method returns a handle (ULONG) to the page created. It must be
  625.     used when setting the status text, inserting a page before or after
  626.     a special one, or deleting a page.
  627.  
  628.  *    (ULONG) createPageAfter: (ULONG) pageID
  629.                 withStatusText: (BOOL) statusFlag
  630.     Calling this method creates a new page for the notebook window. The
  631.     page is inserted AFTER the page specified by "pageID".
  632.  
  633.     If "stFlag" is YES, an area for status text is reserved. The status
  634.     text can be set using [notebook setStatusLineTextFor: to:].
  635.  
  636.     This method returns a handle (ULONG) to the page created. It must be
  637.     used when setting the status text, inserting a page before or after
  638.     a special one, or deleting a page.
  639.  
  640.  *    (ULONG) createMajorPageAfter: (ULONG) pageID 
  641.                       withStatusText: (BOOL) stFlag
  642.     Calling this method creates a new page for the notebook window. The
  643.     page is inserted AFTER the page specified by "pageID". MAJOR tab.
  644.  
  645.     If "stFlag" is YES, an area for status text is reserved. The status
  646.     text can be set using [notebook setStatusLineTextFor: to:].
  647.  
  648.     This method returns a handle (ULONG) to the page created. It must be
  649.     used when setting the status text, inserting a page before or after
  650.     a special one, or deleting a page.
  651.  
  652.  *    (ULONG) createMinorPageAfter: (ULONG) pageID 
  653.                       withStatusText: (BOOL) stFlag
  654.     Calling this method creates a new page for the notebook window. The
  655.     page is inserted AFTER the page specified by "pageID". MINOR tab.
  656.  
  657.     If "stFlag" is YES, an area for status text is reserved. The status
  658.     text can be set using [notebook setStatusLineTextFor: to:].
  659.  
  660.     This method returns a handle (ULONG) to the page created. It must be
  661.     used when setting the status text, inserting a page before or after
  662.     a special one, or deleting a page.
  663.  
  664.  *    deletePage: (ULONG) pageID
  665.     This method deletes the page specified by "pageID".
  666.  
  667.  *    deleteAllPages
  668.     This method deletes all pages currently in the notebook.
  669.  
  670.  *    setStatusLineTextFor: (ULONG) pageID to: (char *) aString
  671.     Set the status line text for notebook page "pageID" to "aString".
  672.  
  673.  *    setTabTextFor: (ULONG) pageID to: (char *) aString
  674.     Set the tab text for page "pageID" to "aString".
  675.  
  676.  *    setMajorTabDimensions: (USHORT) width : (USHORT) height
  677.     Set the major tab dimensions to ("width"/"height") Pels.
  678.  
  679.  *    setMinorTabDimensions: (USHORT) width : (USHORT) height
  680.     Set the minor tab dimensions to ("width"/"height") Pels.
  681.  
  682.  *    setPageButtonDimensions: (USHORT) width : (USHORT) height
  683.     Set the page button dimensions to ("width"/"height") Pels.
  684.  
  685.  *    setPage: (ULONG) pageID to: (Window *) aWindow
  686.     Display "aWindow" on page "pageID", when this page is shown. The
  687.     window object is NOT freed automatically, when the page is deleted.
  688.  
  689.  
  690. 2.6. StdApp:
  691. ------------
  692.  
  693.  *    loadIBFile: (char *) fileName
  694.     This method loads an interface file from disk. The name of the file
  695.     is specified via "fileName". The file is searched for first in the
  696.     current working directory, if it could not be found there, the
  697.     directory the executable file was started from, is checked.
  698.  
  699.     While loading, all objects stored in the interface file are allocated
  700.     and initialized.
  701.  
  702.     A pointer to the InterfaceFile object is returned. This object is
  703.     NOT freed automatically, when freeing the application object.
  704.  
  705.     You can load more than one interface file for a single application.
  706.     It is recommended, to put related objects into a single file. The
  707.     files should be loaded on demand, when the objects stored there are
  708.     needed.
  709.  
  710.     The objects stored in the interface file can be accessed using the
  711.     appropriate methods of InterfaceFile.
  712.  
  713.  
  714. 2.7. StdDialog:
  715. ---------------
  716.  
  717.  *    initWithId: (ULONG) anId andFlags: (ULONG) flags
  718.     While initWithId: is used to load dialog windows from a resource file,
  719.     this method creates an empty dialog window from scratch. "flags"
  720.     can be used to control the look and feel of the newly created dialog
  721.     window, just like the border type (FCF_DLGBORDER,FCF_SIZEBORDER,...).
  722.  
  723.  *    (ULONG) createFlags
  724.     This method returns the flags specified at creation time with
  725.     initWithId: andFlags: or those set via setCreateFlags:
  726.  
  727.  *    setCreateFlags: (ULONG) flags
  728.     Set the frame creation flags for the dialog window. The modifications
  729.     are not displayed immediately!
  730.  
  731.  *    updateFrame
  732.     Send a WM_UPDATEFRAME message to the dialog window.
  733.  
  734.  *    setTitle: (char *) aTitle
  735.     Set the title of the dialog window. This is equivalent to setText:
  736.  
  737.  *    (BOOL) running
  738.     This method returns YES, if the dialog window is executed using
  739.     runModalFor:.
  740.  
  741.  *    centerOnScreen: sender
  742.     Centers the dialog window on the screen. This method can be bound
  743.     directly to a button or menu item!
  744.  
  745.  
  746. 2.8. StdWindow:
  747. ---------------
  748.  *    (ULONG) windowStyle
  749.     returns the window style specified at creation time.
  750.  
  751.  *    setWindowStyle: (ULONG) styleFlags
  752.     modify the window style. These changes are normally not displayed
  753.     immediately.
  754.  
  755.  *    (ULONG) pmId
  756.     returns the PM identifier of the window.
  757.  
  758.  *    setPmId: (ULONG) anId
  759.     sets the PM identifier of the window
  760.  
  761.  *    performClose: sender
  762.     This causes the window to be closed.
  763.  
  764.  *    performQuit: sender
  765.     The window is closed and the application is terminated.
  766.  
  767.  *    centerOnScreen: sender
  768.     Centers the dialog window on the screen. This method can be bound
  769.     directly to a button or menu item!
  770.  
  771.  
  772. 2.9. Window:
  773. ------------
  774.  *    (ULONG) windowStyle
  775.     returns the window style of the window.
  776.  
  777.  *    setWindowStyle: (ULONG) styleFlags
  778.     set the window style of the window. Depending on the particular window,
  779.     calling invalidate may cause the changes to be displayed immediately.
  780.  
  781.  *    enable
  782.     enables the window, it can be selected and all window-specific actions,
  783.     like entering text can be performed.
  784.  
  785.  *    disable
  786.     disables the window. No window-specific actions can be performed.
  787.  
  788.  *    invalidate
  789.     invalidates the window area. This causes changes to be redisplayed,
  790.     if any were made (e.g. with setWindowStyle:)
  791.  
  792.  *    show
  793.     displays the window on the screen
  794.  
  795.  *    hide
  796.     hides the window.
  797.  
  798.  
  799. 3. Using the Interface Builder:
  800. ===============================
  801.  
  802. Starting with this version of the library, some sort of dialog editor is
  803. included, to let you easily create dialog windows for your application. At
  804. the moment, this is just a simple program, letting you create dialog windows
  805. and insert, move and change the appearance of some of the most-used window
  806. classes. Support for all OS/2 supported window classes will be added soon.
  807.  
  808. In addition to simple creation and editing of dialog windows, most of the
  809. dynamic binding now accomplished using the bindCommand: with: selector:,
  810. bindWith: selector: and setDelegate: methods will be supported in future
  811. releases by simple drag & drop.
  812.  
  813. The Interface Builder program does not create OS/2 resource files. All objects
  814. in an interface file are standard Objective C objects. These are created as
  815. soon as you load a file.
  816.  
  817. Just try it. There's no more documentation at the moment.
  818.  
  819. Some hints:    Reordering of the items in a dialog window is not possible
  820.         now!
  821.  
  822.         All changes to objects created can be made using the
  823.         Preferences dialog. This dialog is not modal! It can be
  824.         open all time you edit an interface file. As soon a new object
  825.         is selected, the preferences are updated!
  826.  
  827.         When deleting a dialog window, or closing an interface file,
  828.         the preferences dialog is not updated automatically. Just
  829.         select another dialog window to refresh the display.
  830.  
  831.         Using the interface files is really simple! Load the files
  832.         using the appropriate method of StdApp (see above) and access
  833.         the objects stored with their keys.
  834.  
  835.         Selection of a window is performed using the first mouse
  836.         button. The selected object can be resized - at the moment
  837.         only diagonally.
  838.  
  839.         Moving an object is performed by clicking and holding the
  840.         second mouse button on any object and dragging!
  841.  
  842.         You can change the font and size of the objects by dragging
  843.         a font template from the font palette and dropping it on the
  844.         item (e.g. a button). This font and size change is saved!
  845.  
  846. If you are using interface files in one of your programs, call the function
  847. registerClasses() somewhere in your main file. This function really does
  848. nothing. But, if you are using Objective C objects unarchived from a stream,
  849. which are referenced by class nowhere else in your program, the code for these
  850. classes will not be linked to your app. Calling this function prevents the
  851. linker to be too optimizing! You can expect your application to produce
  852. core dumps as soon as you try to load an interface file if you forget to call
  853. this function!
  854.  
  855. Example:
  856. ========
  857.  
  858.     main ()
  859.     {
  860.         .
  861.         .
  862.         .
  863.  
  864.         registerClasses ();
  865.  
  866.         .
  867.         .
  868.         .
  869.     }
  870.  
  871.  
  872. Using a resolution of at least 1024x768 is recommended for the interface
  873. builder!
  874.  
  875. More features, bug-fixes and much better documentation following soon.
  876.  
  877.  
  878. The shareware version of the Interface Builder is limited to only two open
  879. files at once and only two dialog windows per interface file.
  880.  
  881.  
  882. 4. Additions to the printed manuals
  883. ===================================
  884. To use rc correctly, don't forget to set the environment variable
  885. INCLUDE to a directory, where the file os2.h can be found.
  886.  
  887. e.g.
  888.  
  889. SET INCLUDE=c:\emx\include
  890.  
  891.  
  892. If you have any questions, feel free to contact me. E-Mail is preferred.
  893. If sending any questions via E-Mail in July 1995, be patient, I won't have
  894. access to my Mailbox until the first week of August.
  895.  
  896. ===============================================================================
  897. Thomas Baier
  898. Ufergasse 68
  899. A-3500 Krems
  900. Austria
  901.  
  902. <baier@ci.tuwien.ac.at>
  903.