═══ 1. How to Use this Book ═══ This reference is a detailed technical guide and reference for application programmers. It gives reference information and code examples to enable you to write source code using Workplace classes and methods. Before you begin to use this information, it would be helpful to understand how you can:  Expand the Contents to see all available topics  Obtain additional information for a highlighted word or phrase  Use action bar choices  Use the programming information. How to Use the Contents When the Contents window first appears, some topics have a plus (+) sign beside them. The plus sign indicates that additional topics are available. To expand the Contents if you are using a mouse, click on the plus sign. If you are using the keyboard, use the Up or Down Arrow key to highlight the topic, and press the plus (+) key. For example, Code Pages has a plus sign beside it. To see additional topics for that heading, click on the plus sign or highlight that topic and press the plus (+) key. To view a topic, double-click on the topic (or press the Up or Down Arrow key to highlight the topic, and then press the Enter key). How to Obtain Additional Information After you select a topic, the information for that topic appears in a window. Highlighted words or phrases indicate that additional information is available. You will notice that certain words and phrases are highlighted in green letters, or in white letters on a black background. These are called hypertext terms. If you are using a mouse, double-click on the highlighted word. If you are using a keyboard, press the Tab key to move to the highlighted word, and then press the Enter key. Additional information then appears in a window. How to Use Action Bar Choices Several choices are available for managing information presented in the Workplace Shell Programming Reference. There are three pull-down menus on the action bar: the Services menu, the Options menu, and the Help menu. The actions that are selectable from the Services menu operate on the active window currently displayed on the screen. These actions include the following: Bookmark Allows you to set a placeholder so you can retrieve information of interest to you. When you place a bookmark on a topic, it is added to a list of bookmarks you have previously set. You can view the list, and you can remove one or all bookmarks from the list. If you have not set any bookmarks, the list is empty. To set a bookmark, do the following: 1. Select a topic from the Contents. 2. When that topic appears, choose the Bookmark option from the Services pull-down. 3. If you want to change the name used for the bookmark, type the new name in the field. 4. Click on the Place radio button (or press the Up or Down Arrow key to select it). 5. Click on OK (or select it and press Enter). The bookmark is then added to the bookmark list. Search Allows you to find occurrences of a word or phrase in the current topic, selected topics, or all topics. You can specify a word or phrase to be searched. You can also limit the search to a set of topics by first marking the topics in the Contents list. To search for a word or phrase in all topics, do the following: 1. Choose the Search option from the Services pull-down. 2. Type the word or words for which to search. 3. Click on All sections (or press the Up or Down Arrow keys to select it). 4. Click on Search (or select it and press Enter) to begin the search. 5. The list of topics where the word or phrase appears is displayed. Print Allows you to print one or more topics. You can also print a set of topics by first marking the topics in the Contents list. To print the document Contents list, do the following: 1. Choose Print from the Services pull-down. 2. Click on Contents (or press the Up or Down Arrow key to select it). 3. Click on Print (or select it and press Enter). 4. The Contents list is printed on your printer. Copy Allows you to copy a topic that you are viewing to the System Clipboard or to a file that you can edit. You will find this particularly useful for copying syntax definitions and program samples into the application that you are developing. You can copy a topic that you are viewing in two ways:  Copy copies the topic that you are viewing into the System Clipboard. If you are using a Presentation Manager* editor (for example, the System Editor) that copies or cuts (or both) to the System Clipboard, and pastes to the System Clipboard, you can easily add the copied information to your program source module.  Copy to file copies the topic that you are viewing into a temporary file named TEXT.TMP. You can later edit that file by using any editor. You will find TEXT.TMP in the directory where your viewable document resides. To copy a topic, do the following: 1. Expand the Contents list and select a topic. 2. When the topic appears, choose Copy to file from the Services pull-down. 3. The system puts the text pertaining to that topic into the temporary file named TEXT.TMP. For information on one of the other choices in the Services pull-down, highlight the choice and press the F1 key. The actions that are selectable from the Options menu allow you to change the way your Contents list is displayed. To expand the Contents and show all levels for all topics, choose Expand all from the Options pull-down. You can also press the Ctrl and * keys together. For information on one of the other choices in the Options pull-down, highlight the choice and press the F1 key. The actions that are selectable from the Help menu allow you to select different types of help information. You can also press the F1 key for help information about the Information Presentation Facility (IPF). How to Use the Programming Information This document consists of guide and reference information that provides a detailed description of each function, message, constant, and data type. It provides language-dependent information about the functions which enable the user to generate call statements in the C Language. Workplace Shell programming information is presented by component, such as Workplace Classes, Instance Methods, and Class Methods, for example: ┌─────────────────────────────────────────┐ │ Contents │ ├─────────────────────────────────────────┤ │ │ │ + Workplace Classes │ │ + Instance Methods │ │ + Class Methods │ │ │ └─────────────────────────────────────────┘ By clicking on the plus sign beside "Instance Methods", you see an alphabetic list of the Workplace Shell instance methods. Selecting an instance method takes you directly into the reference information for that method. Units of reference information are presented in selectable multiple windows or viewports. A viewport is a Presentation Manager window that can be sized, moved, minimized, maximized, or closed. By selecting a unit (in this case, an entry on the Contents list), you will see two windows displayed: ┌────────────────────┬──────────────────────────┐ │ Unit Title │ Selection Title │ ├────────────────────┼──────────────────────────┤ │ Select an item │ │ │ │ │ │ Syntax │ │ │ Returns │ │ │ Notes │ │ │ Related Methods │ │ │ Override │ │ │ Glossary │ │ │ │ │ └────────────────────┴──────────────────────────┘ The window on the left is the primary window. It contains a list of items that are always available to you. The window on the right is the secondary window. It contains a "snapshot" of the unit information. For reference units (that is, function descriptions), this window contains the Function Syntax. All of the information needed to understand a reference unit (or topic) is readily available to you through the primary window. The information is divided into discrete information groups, and only the appropriate information group appears for the topic that you are viewing. The information groups for a reference unit (that is, a function description) can include all or some of the following:  Syntax  Parameters  Returns  Notes  Related Methods  Usage  Override  Glossary This list may vary. Some topics may be omitted when they do not apply. Information groups are displayed in separate viewports that are stacked in a third window location that overlaps the secondary window. By selecting an item (information group) in the primary window, the item is displayed in the third window location, as follows: ┌────────────────┬─────────────┬──────────────────┐ │ Unit Title │ Selection │ Glossary │ ├────────────────┼─────────────┼──────────────────┤ │ Select an item │ │ Select a starting│ │ │ │ letter of │ │ . │ │ glossary terms │ │ . │ │ │ │ . │ │ A N │ │ . │ │ B O │ │ . │ │ C P │ │ Glossary │ │ . . │ │ │ │ . . │ │ │ │ . . │ │ │ │ M Z │ └────────────────┴─────────────┴──────────────────┘ By selecting successive items from the primary window, additional windows are displayed on top of the previous windows displayed in the third window location. For example, in a function description, Parameters and Return Values are items listed in the primary window. When selected, they appear one on top of the other in the third window location. Because of this, you may move the first selected (topmost) window to the left before selecting the next item. This allows simultaneous display of two related pieces of information from the "stack" of windows in the third window location, as follows: ┌────────────────┬──────────────┬─────────────────┐ │ Unit Title │ Parameters │ Return Values │ ├────────────────┼──────────────┼─────────────────┤ │ Select an item │ │ │ │ . │ │ │ │ . │ │ │ │ . │ │ │ │ Returns │ │ │ │ Errors │ │ │ │ . │ │ │ │ . │ │ │ │ . │ │ │ │ │ │ │ └────────────────┴──────────────┴─────────────────┘ Each window can be individually closed from its system menu. All windows are closed when you close the primary window. Some secondary windows may have the appearance of a split screen. For example, an illustration may appear in the left half of the window, and scrollable, explanatory information may appear in the right half of the window. Because illustrations may not necessarily fit into the small window size on your screen, you may maximize the secondary window for better readability. ═══ 1.1. Conventions Used in this Reference ═══ The purpose of this reference is to give information about classes, methods, constants, and data types. It provides information about the methods which enables the user to call functions in the C programming language. The following information is provided:  The syntax and parameters for each method.  The syntax of each data type and structure. ═══ 1.2. Notation Conventions ═══ The following notation conventions are used in this reference: NULL The term NULL applied to a parameter is used to indicate the presence of the pointer parameter, but with no value. NULLHANDLE The term NULLHANDLE applied to a parameter is used to indicate the presence of the handle parameter, but with no value. Implicit Pointer If no entry for a data type "Pxxxxxxx" is found in Data Types, then it is implicitly a pointer to the data type "xxxxxxx". See Implicit Pointer Data Types for more information about implicit pointers. CONSTANT NAMES All constants are written in uppercase to match the header files. Where applicable, constant names have a prefix derived from the name of a function, message, or idea associated with the constant. For example: WM_CREATE Window message SV_CXICON System value CF_TEXT Clipboard format. In this book, references to a complete set of constants with a given prefix is written as shown in the following examples: Window message WM_* System value SV_* Parameters and Fields Function parameters and data structure fields are shown in italics. ═══ 1.3. Conventions Used in Method Descriptions ═══ The documentation of each function contains these sections: Syntax The method syntax describes the C-language calling syntax of the function and gives a brief description. Programming Note The methods in this book are spelled in mixed-case for readability but are known to the system as uppercase character strings. For example, the function "WinCreateObject" is actually the external name "WINCREATEOBJECT". If you are using a compiler that generates a mixed-case external name, you should code the functions in uppercase. Parameters Each parameter is listed with its C-language data type, parameter type, and a brief description.  All data types are written in uppercase to match the header files. A data type of "Pxxxxxxx" implicitly defines a pointer to the data type "xxxxxxx". The term NULL applied to a parameter indicates the presence of the parameter, with no value. Refer to Data Types for a complete list of all data types and their descriptions.  There are three parameter types: Input Specified by the programmer. Output Returned by the method. Input/Output Specified by the programmer and modified by the method.  A brief description is provided with each parameter. Where appropriate, restrictions are also included. In some cases, the parameter points to a structure. Returns A list of possible return codes is included in this section. Remarks This section contains additional information about the method, when required. Related Methods This list shows the methods (if any) that are related to the method being described. Usage This section describes any restrictions for using the method. Override This section describes when the method can be overridden. ═══ 1.4. Error Severities ═══ Each of the error conditions given in the list of errors for each function falls into one of these areas: Warning The function detected a problem, but took some remedial action that enabled the function to complete successfully. The return code in this case indicates that the function completed successfully. Error The function detected a problem for which it could not take any sensible remedial action. The system has recovered from the problem, and the state of the system, with respect to the application, remains the same as at the time when the function was requested. The system has not even partially executed the function (other than reporting the error). Severe Error The function detected a problem from which the system could not reestablish its state, with respect to the application, at the time when that function was requested; that is, the system partially executed the function. This, therefore, necessitates the application performing some corrective activity to restore the system to some known state. Unrecoverable Error The function detected some problem from which the system could not reestablish its state, with respect to the application, at the time when that call was issued. It is possible that the application cannot perform some corrective action to restore the system to some known state. ═══ 1.5. Header Files ═══ All functions require an "#include" statement for the system header file OS2.H: #include Most functions also require a "#define" statement to select an appropriate (conditional) section of the header file, and hence, the required prototype. Where this is necessary, it is shown at the head of the function definition in the form: #define INCL_name Note: These "#define" statements must precede the "#include " statement. ═══ 1.6. Addressing Elements in Arrays ═══ Constants defining array elements are given values that are zero-based in C; that is, the numbering of the array elements starts at zero, not one. For example, in the DevQueryCaps function, the sixth element of the alArray parameter is CAPS_HEIGHT, which is equated to 5. Count parameters related to such arrays always mean the actual number of elements available; therefore, again using the DevQueryCaps function as an example, if all elements up to and including CAPS_HEIGHT are provided for, lCount could be set to (CAPS_HEIGHT+1). In functions for which the starting array element can be specified, this is always zero-based, and so the C element number constants can be used directly. For example, to start with the CAPS_HEIGHT element, the lStart parameter can be set to CAPS_HEIGHT. ═══ 1.7. Implicit Pointer Data Types ═══ A data type name beginning with "P" (for example, PERRORCODE) is likely to be a pointer to another data type (in this instance, ERRORCODE). In the data type summary, Data Types, no explicit "typedefs" are shown for pointers; therefore, if no data type definition can be found in the summary for a data type name "Pxxxxxx", it represents a pointer to the data type "xxxxxx", for which a definition should be found in the reference. The implicit type definition needed for such a pointer "Pxxxxxx" is: typedef xxxxxx *Pxxxxxx; Such definitions are provided in the header files. ═══ 1.8. Storage Mapping of Data Types ═══ The storage mapping of the data types is dependent on the machine architecture. To be portable, applications must access the data types using the definitions supplied for the environment in which they will execute. ═══ 1.9. Double-Byte Character Set (DBCS) ═══ Throughout this publication, you will see references to specific value for character strings. The values are for single-byte character set (SBCS). If you use the double-byte character set (DBCS), note that one DBCS character equals two SBCS characters. ═══ 1.10. Message Queues ═══ Usually when an application thread uses a PM function, a message queue must be available for that thread. This means that before calling the function, WinCreateMsgQueue must be called by the same thread. It is recommended that you create a message queue for every thread that calls any method, since a PM function might be used by the methods you are calling. ═══ 1.11. Programming Considerations ═══ This section provides information you need to consider before you begin programming with Workplace Shell methods. ═══ 1.11.1. Method Considerations ═══ When including the "OBJECTID=<...>" keyname/value pair in a setup string, it must be specified as the last entry in the string. ═══ 1.11.2. Stack Size ═══ Existing 16-bit applications (small and tiny models) must have a 4KB stack available when they enter system calls; otherwise, the stack can overflow into the data area. ═══ 1.11.3. C++ Considerations ═══ This section contains several topics you should take into consideration if you are using C++ **. ═══ 1.11.3.1. C++ Header Files ═══ OS/2 functions that used to take a PSZ as a parameter, and that do not modify the contents of the passed string, have been updated in the C++ header files to take a PCSZ data type parameter. The use of PCSZ allows for better optimization by the compiler and is more semantically compatible with C++. Existing code that calls functions that use PSZ will continue to work correctly. Several of the typedefs have been changed in the C++ header files. For example, many items that are unsigned char in the C header files are char in the C++ header files. For instance, typedef unsigned char BYTE; has changed to typedef char BYTE; The existing samples that are included in the IBM Developer's Toolkit for OS/2 Warp, Version 3 can be used with either set of the header files. ═══ 1.11.3.2. PCSZ Data Type ═══ Note: The PCSZ data type is defined in the C++ header files included with this product. The use of the "const" keyword is not necessarily specific to C++. Certain C compilers support it as well. If a function takes as a parameter a string that is not changed by the function, the string parameter can be declared as a "const" string, or a PCSZ. PCSZ is defined in the C++ header files as a "const" pointer to a NULL-delimited string. The "const" means that the function will not change the contents of the string. Declaring the parameter as PCSZ informs the C++ compiler that the function will not change the string. Therefore, the compiler simply passes a pointer to the string in the function parameter list. If the parameter is declared as a normal PSZ (not "const"), the compiler assumes that the function might change the string. Under these circumstances the compiler will add code to make a copy of the string then pass a pointer to the copy, rather than pass a pointer to the original string. A smaller, faster executable is often produced if the data item passed in a parameter list is declared as "const". If the data item is declared as "const" then it must not be changed by the function. ═══ 1.11.3.3. LINK386 ═══ The C++ compiler will provide a dynamic link library which is be used by LINK386 when generating error messages. This DLL will convert a compiler generated mangled name into the function prototype. If the DLL is not present, an error message will be displayed and LINK386 will display the compiler-generated mangled name in error messages. ═══ 2. Workplace Object Classes ═══ This chapter contains an alphabetic listing of the Workplace object classes. These sections contain technical reference information. See the Workplace Shell Programming Guide for Workplace guide information. For information on the System Object Model (SOM), see the System Object Model Guide and Reference. Workplace objects are icons representative of physical objects which users deal with in the Workplace. A Workplace object is implemented as an instance of a Workplace object class. Workplace object classes are System Object Model (SOM) object classes which are descendants of the predefined Workplace object class, WPObject. For more information about SOM object classes, see System Object Model Guide and Reference. All Workplace objects are descendants of a Workplace object storage class. Workplace storage object classes are responsible primarily for storing and retrieving object class data for instances of objects which are descendants (subclasses) of that storage class. The three predefined Workplace object storage classes are: WPAbstract Storage class for objects stored in the user profile (OS2.INI) WPFileSystem Storage class for objects stored as files in the file system WPTransient Storage class for non-persistent objects. ═══ 2.1. Workplace Object Class Hierarchy ═══ The following figure lists the predefined Workplace object classes in a hierarchical order. Each branch in the tree represents an immediate descendant (subclass) of a Workplace object class. The predefined SOM object class, SOMObject, is the root class for all SOM object classes, including all Workplace object classes. CLASS NAME CLASS DEFINITION FILE SOMObject somobj.idl ├── SOMClass somcls.idl ├── SOMClassMgr somcm.idl └── WPObject wpobject.idl ├── WPAbstract wpabs.idl │ ├── WPClock wpclock.idl │ ├── WPCountry wpctry.idl │ ├── WPDisk wpdisk.idl │ ├── WPLaunchPad wplnchpd.idl │ ├── WPKeyboard wpkeybd.idl │ ├── WPMouse wpmouse.idl │ ├── WPPalette wppalet.idl │ │ ├── WPColorPalette wpclrpal.idl │ │ ├── WPFontPalette wpfntpal.idl │ │ └── WPSchemePalette wpscheme.idl │ ├── WPPower wppower.idl │ ├── WPPrinter wpprint.idl │ │ └── WPRPrinter wprprint.idl │ ├── WPProgram wppgm.idl │ ├── WPShadow wpshadow.idl │ │ └── WPNetLink wpnetlnk.idl │ ├── WPShredder wpshred.idl │ ├── WPSound wpsound.idl │ ├── WPSpecialNeeds wpspneed.idl │ ├── WPSpool wpspool.idl │ ├── WPSystem wpsystem.idl │ └── WPWinConfig wincfg.idl ├── WPFileSystem wpfsys.idl │ ├── WPDataFile wpdataf.idl │ │ ├── WPBitmap wpbitmap.idl │ │ ├── WPIcon wpicon.idl │ │ ├── WPMet wpmet.idl │ │ ├── WPPif wppif.idl │ │ ├── WPPointer wpptr.idl │ │ └── WPProgramFile wppgmf.idl │ │ └── WPCommandFile wpcmdf.idl │ ├── WPFolder wpfolder.idl │ │ ├── WPDesktop wpdesk.idl │ │ ├── WPDrives wpdrives.idl │ │ ├── WPMinWinViewer wpmwv.idl │ │ ├── WPNetgrp wpnetgrp.idl │ │ ├── WPNetwork wpnetwrk.idl │ │ ├── WPRootFolder wprootf.idl │ │ ├── WPServer wpserver.idl │ │ ├── WPSharedDir wpshdir.idl │ │ ├── WPStartup wpstart.idl │ │ └── WPTemplates wptemps.idl └── WPTransient wptrans.idl ├── WPJob wpjob.idl ├── WPPort wpport.idl ├── WPPdr wppdr.idl └── WPQdr wpqdr.idl Instances of some Workplace object classes cannot be created as a Workplace object. These classes are provided as base classes which provide support for descendant classes that can have instances created. Other classes are SOM classes and are described in better detail in the System Object Model Guide and Reference. These classes include: SOMObject This is the SOM root class. All SOM classes must be descended from SOMObject. A Workplace object of this class cannot be created. SOMClass This is the SOM metaclass, that is, the instances of this class are class objects. A Workplace object of this class cannot be created. SOMClassMgr This is the SOM class manager class. A Workplace object of this class cannot be created. ═══ 2.2. WPAbstract ═══ Class definition file: wpabs.idl Class hierarchy SOMObject WPObject WPAbstract Description This is the abstract object storage class. The storage medium for objects that are descendants of the WPAbstract class is the INI file. In other words, any object class derived from WPAbstract will have persistent storage for its instance variables in the INI file. Note that an abstract object does not have a file name, just a numeric handle that can be used to identify it. It can optionally be assigned an object id to uniquely identify it. An instance of this class can be created as a Workplace object. No instances of this class are initially created by the system. Instance methods There are currently no methods defined for the WPAbstract Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPAbstract class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpCopyObject  wpDragOver  wpMoveObject  wpQueryHandle  wpQueryIcon  wpQueryIconData  wpQueryNameClashOptions  wpRestoreState  wpSaveImmediate  wpSaveState  wpSetIconData  wpSetTitle Class methods There following list shows the WPAbstract class methods.  wpclsQuerySetting  wpclsSetSetting WPObject class methods. The following shows the class methods overridden by the WPAbstract class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryTitle ═══ 2.3. WPBitmap ═══ Class definition file: wpbitmap.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPBitmap Description This is the WPBitmap object class. All bit maps are of this class. These bit map files are templatable. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each bit map in the system. Instance methods There are currently no methods defined for the WPBitmap Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPBitmap class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetupOnce Class methods There are currently no class methods defined for the WPBitmap Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPBitmap class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryTitle WPFileSystem class methods. The following list shows all the class methods overridden by the WPBitmap class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryInstanceFilter  wpclsQueryInstanceType ═══ 2.4. WPClock ═══ Class definition file: wpclock.idl Class hierarchy SOMObject WPObject WPAbstract WPClock Description This is the system clock object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "System Clock" and resides in the "System Setup" folder. Instance methods The following list shows all the WPClock instance methods:  wpAddClockAlarmPage  wpAddClockDateTimePage  wpAddClockView1Page  wpAddClockView2Page WPObject instance methods The following list shows all the methods overridden by the WPClock class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState Class methods There are currently no class methods defined for the WPClock Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPClock class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.5. WPColorPalette ═══ Class definition file: wpclrpal.idl Class hierarchy SOMObject WPObject WPAbstract WPPalette WPColorPalette Description This is the color palette object class. An instance of this class can be created as a Workplace object. Two instances of this class are created initially by the system, with the titles "Mixed Color Palette" and "Solid Color Palette", both residing in the "System Setup" folder. Instance methods There are currently no methods defined for the WPColorPalette Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPColorPalette class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpInitData  wpMenuItemHelpSelected  wpSetup wpSetup override by WPColorPalette The following table shows the keyname-value pairs added by the WPColorPalette class. ┌──────────┬──────────┬────────────────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├──────────┼──────────┼────────────────────────────────────────┤ │COLORS │RGB values│These are the initial color values of │ │ │ │each cell in the color palette. The │ │ │ │values for each cell are separated by │ │ │ │commas. This is equivalent to calling │ │ │ │the wpSetupCell method. The RGB value │ │ │ │must be presented as a 6-digit hex value│ │ │ │in the format 0xRRGGBB where RR, GG, and│ │ │ │BB are the red, green, and blue, values │ │ │ │ranging between 0x00 and 0xFF (0-255). │ ├──────────┼──────────┼────────────────────────────────────────┤ │XCELLCOUNT│columns │Number of X cells as decimal digits. │ │ │ │For Solid Color Palette, AUTOSETUP=LORES│ │ │ │must be specified, and the default value│ │ │ │is 8. │ │ │ │For Mixed Color Palette, AUTOSETUP=HIRES│ │ │ │must be specified, and the default value│ │ │ │is 16. │ ├──────────┼──────────┼────────────────────────────────────────┤ │YCELLCOUNT│rows │Number of Y cells as decimal digits. │ │ │ │For Solid Color Palette, AUTOSETUP=LORES│ │ │ │must be specified, and the default value│ │ │ │is 2. │ │ │ │For Mixed Color Palette, AUTOSETUP=HIRES│ │ │ │must be specified, and the default value│ │ │ │is 16. │ └──────────┴──────────┴────────────────────────────────────────┘ Example pszSetupString="COLORS=0x000000," "0xFFFFFF," "0xFF23B4," "0x505050," "0x00FFFF," "0xA0A0A0"; WPPalette methods The following list shows all the methods overridden by the WPColorPalette class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpDragCell  wpEditCell  wpPaintCell  wpQueryPaletteHelp Class methods There are currently no class methods defined for the WPColorPalette Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPColorPalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsCreateDefaultTemplates  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle WPPalette class methods. The following list shows all the class methods overridden by the WPColorPalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryEditString ═══ 2.6. WPCommandFile ═══ Class definition file: wpcmdf.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPProgramFile WPCommandFile Description This is the command file object class. All DOS and OS/2 command/batch files are of this class. These program files are templatable. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each command file in the system. Each instance has a title corresponding to the file name of the command file it represents and resides in a folder corresponding to the physical directory in which the program file resides. Instance methods There are currently no methods defined for the WPCommandFile Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPCommandFile class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpPrintObject Class methods There are currently no class methods defined for the WPCommandFile Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPCommandFile class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryStyle  wpclsQueryTitle WPFileSystem class methods. The following list shows all the class methods overridden by the WPCommandFile class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryInstanceFilter  wpclsQueryInstanceType ═══ 2.7. WPCountry ═══ Class definition file: wpctry.idl Class hierarchy SOMObject WPObject WPAbstract WPCountry Description This is the country object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title, "Country" and resides in the "System Setup" folder. Instance methods The following list shows all the WPCountry instance methods:  wpAddCountryDatePage  wpAddCountryNumbersPage  wpAddCountryPage  wpAddCountryTimePage WPObject instance methods The following list shows all the methods overridden by the WPCountry class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu  wpInitData Class methods There are currently no class methods defined for the WPCountry Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPCountry class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.8. WPDataFile ═══ Class definition file: wpdataf.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile Description This is the data file object class. An instance of this class can be created as a Workplace object and is created initially by the system in its template form. The template form of this class has the title "Data file" and resides in the "Templates" folder. Instance methods The following list shows all the WPDataFile methods:  wpAddFileTypePage  wpPrintMetaFile  wpPrintPifFile  wpPrintPrinterSpecificFile  wpPrintUnknownFile  wpQueryAssociatedFileIcon  wpQueryAssociatedProgram  wpSetAssociatedFileIcon WPObject instance methods The following list shows all the methods overridden by the WPDataFile class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpDragOver  wpFormatDragItem  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpPrintObject  wpQueryDefaultHelp  wpQueryIcon  wpRestoreState  wpSetDefaultView  wpSetRealName WPFileSystem instance methods The following list shows all the methods overridden by the WPDataFile class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetType Class methods There are currently no class methods defined for the WPDataFile Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPDataFile class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.9. WPDesktop ═══ Class definition file: wpdesk.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPDesktop Description This is the Workplace desktop object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Desktop" and initially resides in the root directory of the drive containing the user profile. Instance methods The following list shows all the WPDesktop methods:  wpAddDesktopArcRest1Page  wpAddDesktopDefDT1Page  wpAddDesktopLockup1Page  wpAddDesktopLockup2Page  wpAddDesktopLockup3Page  wpIsCurrentDesktop WPObject instance methods The following list shows all the methods overridden by the WPDesktop class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpFilterPopupMenu  wpInitData  wpMenuItemSelected  wpModifyPopupMenu  wpRestoreState  wpSaveState Class methods The following list shows the WPDesktop class methods.  wpclsQueryActiveDesktop  wpclsQueryActiveDesktopHWND  wpclsQueryObjectFromFrame WPObject class methods. The following list shows all the class methods overridden by the WPDesktop class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.10. WPDisk ═══ Class definition file: wpdisk.idl Class hierarchy SOMObject WPObject WPAbstract WPDisk Description This is the file-system device object class. It is used to represent all types of file-system devices including:  CD ROM drives  Fixed disk drives  Floppy diskette drives  Magnetic tape drives  Network drives  PCMCIA** devices  Ram drives An instance of this class can be created as a Workplace object. Shadow instances of this class are created initially by the system for each file-system device available. Each instance has a title corresponding to a file-system device and resides in the Drives folder. If a primary, local, removable, media file-system device such as a floppy drive exists, an instance of this class will also be created on the desktop, and will represent this drive. These instances actually appear as WPShadow objects which are shadows of WPDisk objects. Instance methods The following list shows the WPDisk methods:  wpAddDiskDetailsPage  wpEjectDisk  wpLockDrive  wpQueryDriveLockStatus  wpQueryLogicalDrive  wpQueryRootFolder  wpSetCorrectDiskIcon WPObject instance methods The following list shows all the methods overridden by the WPDisk class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpDragOver  wpDrop  wpFilterPopupMenu  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryDefaultHelp  wpQueryIconData  wpRestoreState  wpSaveState  wpSetIconData  wpSetTitle  wpSetup  wpUnInitData  wpViewObject The following list shows all the methods overridden by the WPDisk class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpFilterPopupMenu  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu wpSetup override by WPDisk The following table shows the keyname-value pairs added by the WPDisk class. ┌──────────┬───────────────┬───────────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├──────────┼───────────────┼───────────────────────────────────┤ │DRIVENUM │DRIVENUM=dd │Logical drive number (1-26). │ └──────────┴───────────────┴───────────────────────────────────┘ Class methods There are currently no class methods defined for the WPDisk Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPDisk class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.11. WPDrives ═══ Class definition file: wpdrives.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPDrives Description This is the file-system device folder object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Drives" and resides in the "OS/2 System" folder. Instance methods There are currently no methods defined for the WPDrives Workplace object class. WPObject methods The following list shows all the methods overridden by the WPDrives class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpFilterPopupMenu  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu WPFolder methods The following list shows all the methods overridden by the WPDrives class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpPopulate Class methods There are currently no class methods defined for the WPDrives Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPDrives class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.12. WPFileSystem ═══ Class definition file: wpfsys.idl Class hierarchy SOMObject WPObject WPFileSystem Description This is the file-system object storage class. WPFileSystem is the storage class that represents all file-system objects including directory (folder), data file, executable file, and root directory (drive) objects. This class also provides persistent storage of instance variables for all classes derived from it. Persistent data for instances of WPFileSystem subclasses are stored in the Extended Attributes (EAs) of the file or directory. This is a base storage class; it is not intended for instances of this class to be created. Instance methods The following list shows all the WPFileSystem class methods:  wpAddFileMenuPage  wpAddFile1Page  wpAddFile2Page  wpAddFile3Page  wpConfirmKeepAssoc  wpConfirmRenameFileWithExt  wpIsDiskSwapped  wpPrintPlainTextFile  wpQueryAttr  wpQueryCreation  wpQueryDateInfo  wpQueryDisk  wpQueryEASize  wpQueryFilename  wpQueryFileSize  wpQueryLastAccess  wpQueryLastWrite  wpQueryRealName  wpQueryType  wpRefresh  wpSetAttr  wpSetDateInfo  wpSetFileSizeInfo  wpSetRealName  wpSetTitleAndRenameFile  wpSetType  wpVerifyUpdateAccess WPObject instance methods The following list shows all the methods overridden by the WPFileSystem class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpCopyObject  wpCreateFromTemplate  wpDoesObjectMatch  wpDraggedOverObject  wpDroppedOnObject  wpFilterPopupMenu  wpFormatDragItem  wpMenuItemSelected  wpModifyPopupMenu  wpMoveObject  wpOpen  wpQueryDetailsData  wpQueryHandle  wpQueryIcon  wpQueryIconData  wpQueryNameClashOptions  wpQueryStyle  wpRestoreState  wpSaveImmediate  wpSaveState  wpSetIconData  wpSetStyle  wpSetTitle  wpSwitchTo  wpUnInitData  wpViewObject Class methods The following list shows the WPFileSystem class methods:  wpclsFileSysExists  wpclsQueryAwakeObject  wpclsQueryInstanceFilter  wpclsQueryInstanceType  wpclsQueryObjectFromPath WPObject class methods. The following list shows all the class methods overridden by the WPFileSystem class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDetailsInfo  wpclsQueryExtendedCriteria  wpclsNew  wpclsQuerySearchInfo  wpclsQueryTitle ═══ 2.13. WPFolder ═══ Class definition file: wpfolder.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder Description This is the folder object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system in its template form. It has the title "Folder" and resides in the "Templates" folder. Every directory in the system is represented by a WPFolder object. Instance methods The following list shows how all the WPFolder methods are related within functional areas: Settings notebook methods  wpAddFolderBackgroundPage  wpAddFolderIncludePage  wpAddFolderSelfClosePage  wpAddFolderSortPage  wpAddFolderView1Page  wpAddFolderView2Page  wpAddFolderView3Page Object position methods  wpQueryIconViewPos  wpQueryNextIconPos  wpSetNextIconPos Folder attributes methods  wpIsDetailsColumnVisible  wpIsSortAttribAvailable  wpModifyFldrFlags  wpQueryFldrAttr  wpQueryFldrDetailsClass  wpQueryFldrFlags  wpQueryFldrFont  wpQueryFldrSort  wpQueryFldrSortClass  wpSetDetailsColumnVisibility  wpSetFldrAttr  wpSetFldrDetailsClass  wpSetFldrFlags  wpSetFldrFont  wpSetFldrSort  wpSetFldrSortClass  wpSetSortAttribAvailable Folder state methods  wpHideFldrRunObjs Folder content methods  wpAddFirstChild  wpAddToContent  wpContainsFolders  wpDeleteContents  wpDeleteFromContent  wpPopulate  wpQueryContent WPObject instance methods The following list shows all the methods overridden by the WPFolder class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpConfirmDelete  wpDelete  wpDragOver  wpDrop  wpFilterPopupMenu  wpFormatDragItem  wpFree  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpMoveObject  wpObjectReady  wpOpen  wpQueryDefaultHelp  wpQueryDefaultView  wpRender  wpRenderComplete  wpRestoreState  wpSaveState  wpSetIconData  wpSetup  wpUnInitData WPFileSystem instance methods The following list shows all the methods overridden by the WPFolder class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFile2Page  wpAddFile3Page wpSetup override by WPFolder The following table shows the keyname-value pairs supported by the WPFolder class. ┌────────────────┬──────────────────┬──────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ALWAYSSORT │YES │Sort order is always │ │ │ │maintained. Opening and adding│ │ │ │an object to a folder may take│ │ │ │longer if the sort order is │ │ │ │being maintained. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NO │Sort order is not maintained. │ │ │ │This is the default value. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │BACKGROUND │N,M,S,B,C │This sets the folder │ │ │ │background, where: │ │ │ │N = Image file name. This │ │ │ │ name must be the fully- │ │ │ │ qualified path of the │ │ │ │ image file. "?:\" is │ │ │ │ permitted to indicate the │ │ │ │ boot drive. │ │ │ │ │ │ │ │M = Image mode. This mode can │ │ │ │ be one of the following: │ │ │ │ N = Normal image │ │ │ │ T = Titled image │ │ │ │ S = Scaled image │ │ │ │ │ │ │ │S = Scaling factor. │ │ │ │ │ │ │ │B = Background type. This can │ │ │ │ be one of the following: │ │ │ │ I = Image │ │ │ │ C = Color only │ │ │ │ │ │ │ │C = Background color. This │ │ │ │ color can be 3 numbers re-│ │ │ │ presenting RGB values or │ │ │ │ the default, in the │ │ │ │ following format: │ │ │ │ │ │ │ │ {R-value G-value B-value} │ │ │ │ │ │ │ │For example: │ │ │ │"BACKGROUND= │ │ │ │C:\OS2\BITMAP\OS2LOGO.BMP,S, │ │ │ │3,I" │ │ │ │or │ │ │ │"BACKGROUND= │ │ │ │(none),,,C,0 128 128" │ ├────────────────┼──────────────────┼──────────────────────────────┤ │DEFAULTVIEW │ICON │This sets the default open │ │ │ │view to the ICON (or CONTENTS)│ │ │ │view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │TREE │This sets the default open │ │ │ │view to the TREE view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │DETAILS │This sets the default open │ │ │ │view to the DETAILS view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │ │The default view of the │ │ │ │containing folder. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │DETAILSCLASS │classname │This sets the object class for│ │ │ │which the details are │ │ │ │displayed in details view. │ │ │ │The default object class is │ │ │ │WPFileSystem. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │DETAILSFONT │font name.size │Setup string used to change │ │ │string │the font used for a details │ │ │ │view. For example: 10.Helv │ │ │ │The default value is 8.Helv. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │DETAILSVIEW │s1[,s2,...sn] │This set details view to the │ │ │ │specified styles. Possible │ │ │ │values are: │ │ │ │MINI small icon; this is │ │ │ │ the default. │ │ │ │NORMAL normal-size icon. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ICONFONT │font size.facename│Setup string used to change │ │ │ │the font used for an icon │ │ │ │view. For example: 10.Helv │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ICONNFILE │index,filename │This sets the file name of the│ │ │ │animation (open folder) icon. │ │ │ │The "index" value must be set │ │ │ │to 1. The specified file │ │ │ │contains the folder's open │ │ │ │folder icon. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ICONNRESOURCE │index,id,modname │This sets the resource of the │ │ │ │animation (open folder) icon. │ │ │ │The "index" value must be set │ │ │ │to 1. The "id" is the identity│ │ │ │of an icon resource in the │ │ │ │"module" dynamic link library │ │ │ │(DLL). The specified resource │ │ │ │is the folder's open folder │ │ │ │icon. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ICONVIEW │s1[,s2,...sn] │This sets icon view to the │ │ │ │specified styles. Possible │ │ │ │values are: │ │ │ │FLOWED NOGRID │ │ │ │INVISIBLE NONFLOWED │ │ │ │MINI NORMAL │ │ │ │ │ │ │ │The default value is │ │ │ │NOGRID,NORMAL │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ICONVIEWPOS │x,y,cx,cy │This sets the initial icon │ │ │ │view position and size of the │ │ │ │folder on the screen. These │ │ │ │values are percentages (0-100)│ │ │ │of the screen size. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │OPEN │ICON │This opens the icon view when │ │ │ │object is created or when │ │ │ │WinSetObjectData is called. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │TREE │This opens the tree view when │ │ │ │object is created or when │ │ │ │WinSetObjectData is called. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │DETAILS │This opens the details view │ │ │ │when object is created or when│ │ │ │WinSetObjectData is called. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │ │The default is to not │ │ │ │automatically open a view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │REMOVEFONTS │YES │This removes all instance │ │ │ │fonts from the folder. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NO │This does not remove instance │ │ │ │fonts from the folder. │ │ │ │This is the default value. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │SORTCLASS │classname │This sets the class object to │ │ │ │sort by. │ │ │ │The default class object is │ │ │ │WPFileSystem. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │TREEFONT │font size.facename│This changes the font used for│ │ │ │a tree view. For example: │ │ │ │10.System Proportional │ ├────────────────┼──────────────────┼──────────────────────────────┤ │TREEVIEW │s1[,s2,...sn] │This sets the tree view to the│ │ │ │specified styles. Possible │ │ │ │values are: │ │ │ │INVISIBLE LINES │ │ │ │MINI NOLINES │ │ │ │NORMAL │ │ │ │ │ │ │ │The default value is LINES, │ │ │ │NORMAL. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │view styles │FLOWED │Flowed list items. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NONFLOWED │Non-flowed list items. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NONGRID │Non-gridded icon view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NORMAL │Normal size icons. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │MINI │Small icons. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │INVISIBLE │No icons. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │LINES │Lines in tree view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NOLINES │No lines in tree view. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │WORKAREA │YES │This sets the folder so it is │ │ │ │a workarea. │ ├────────────────┼──────────────────┼──────────────────────────────┤ │ │NO │This sets the folder so it is │ │ │ │not a workarea. This is the │ │ │ │default value. │ └────────────────┴──────────────────┴──────────────────────────────┘ WPFileSystem instance methods The following list shows all the methods overridden by the WPFolder class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpRefresh Class methods The following list shows all the WPFolder class methods:  wpclsQueryIconDataN  wpclsQueryIconN  wpclsQueryOpenFolders WPObject class methods. The following list shows all the class methods overridden by the WPFolder class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.14. WPFontPalette ═══ Class definition file: wpfntpal.idl Class hierarchy SOMObject WPObject WPAbstract WPPalette WPFontPalette Description This is the font palette object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Font Palette" and resides in the "System Setup" folder. Instance methods The following list shows all the WPFontPalette instance methods.  wpGetFattrsFromPsz WPObject instance methods The following list shows all the methods overridden by the WPFontPalette class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpMenuItemHelpSelected  wpSetup wpSetup override by WPFontPalette The following table shows the keyname-value pairs supported by the WPFontPalette class. ┌──────────┬──────────┬────────────────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├──────────┼──────────┼────────────────────────────────────────┤ │FONTS │fonttype │These are the initial fonts for each │ │ │ │cell in the font palette. The values │ │ │ │for each cell are separated by commas. │ │ │ │This is equivalent to calling the │ │ │ │wpSetupCell method. The fonttype value │ │ │ │is presented as the point size followed │ │ │ │by a period which is then followed by │ │ │ │the face name. │ ├──────────┼──────────┼────────────────────────────────────────┤ │XCELLCOUNT│columns │Number of X cells as decimal digits. If│ │ │ │not specified, defaults to 2. │ ├──────────┼──────────┼────────────────────────────────────────┤ │YCELLCOUNT│rows │Number of Y cells as decimal digits. If│ │ │ │not specified, defaults to 4. │ └──────────┴──────────┴────────────────────────────────────────┘ Example pszSetupString="FONTS=10.Helvetica," "8.Helvetica," "10.Courier," "12.Courier," "24.Courier," "10.System"; WPPalette instance methods The following list shows all the methods overridden by the WPFontPalette class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpDragCell  wpEditCell  wpPaintCell  wpQueryPaletteHelp  wpSetupCell Class methods There are currently no class methods defined for the WPFontPalette Workplace object class. WPObject class methods. The following list shows all the class methods overridden by the WPFontPalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle WPPalette class methods. The following list shows all the class methods overridden by the WPFontPalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryEditString ═══ 2.15. WPIcon ═══ Class definition file: wpicon.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPIcon Description This is the WPIcon object class. All icons are of this class. These icon files are templatable. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each icon in the system. Instance methods There are currently no methods defined for the WPIcon Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPIcon class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetupOnce Class methods There are currently no class methods defined for the WPIcon Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPIcon class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryTitle WPFileSystem class methods. The following list shows all the class methods overridden by the WPIcon class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryInstanceFilter  wpclsQueryInstanceType ═══ 2.16. WPJob ═══ Class definition file: wpjob.idl Class hierarchy SOMObject WPObject WPTransient WPJob Description This is the job object class. An instance of this class is created by the printer object in its icon or detail view. Instance methods The following list shows all the WPJob methods:  wpDeleteJob  wpHoldJob  wpPrintJobNext  wpQueryJobFile  wpQueryJobId  wpQueryJobType  wpQueryPrintObject  wpReleaseJob  wpStartJobAgain WPObject instance methods The following list shows all the methods overridden by the WPJob class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectGeneralPage  wpAddSettingsPages  wpDragOver  wpDrop  wpFilterPopupMenu  wpFree  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryDetailsData  wpQueryIcon  wpQueryTitle  wpSetTitle  wpUnInitData Class methods WPObject class methods. There are currently no class methods defined for the WPJob Workplace class object. The following list shows all the class methods overridden by the WPJob class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryDetailsInfo  wpclsQueryIcon  wpclsQueryStyle  wpclsQueryTitle ═══ 2.17. WPKeyboard ═══ Class definition file: wpkeybd.idl Class hierarchy SOMObject WPObject WPAbstract WPKeyboard Description This is the keyboard object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Keyboard" and resides in the "System Setup" folder. Instance methods The following list shows all the WPKeyboard methods:  wpAddKeyboardMappingsPage  wpAddKeyboardSpecialNeedsPage  wpAddKeyboardTimingPage WPObject instance methods The following list shows all the methods overridden by the WPKeyboard class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu Class methods There are currently no class methods defined for the WPKeyboard Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPKeyboard class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle WPAbstract class methods. The following list shows all the class methods overridden by the WPKeyboard class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQuerySetting  wpclsSetSetting wpclsSetSettings override by wpKeyboard The defaults can be specified on a wpclsSetSetting invocation to request that the setting be set to its default value. wpclsQuerySetting, however, never returns an xxxx_DEFAULT value. ┌─────────────────┬─────────────────────┬────────────────────────────┐ │Setting │Value │Description │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │CursorBlinkRate │rate │Sets the rate at which the │ │ │ │cursor blinks. │ │ │ │This value must be in the │ │ │ │range CURSORBLINK_MIN to │ │ │ │CURSORBLINK_MAX. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │CURSORBLINK_DEFAULT │Sets the default rate at │ │ │ │which the cursor blinks. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │EditTitleTextKey │AF_VIRTUALKEY │High word. Sets the key used│ │ │AF_KBDCOMMAND │with another key to edit │ │ │ │button text. │ │ │ │Both of these values are │ │ │ │required if the default is │ │ │ │not set. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │AF_ALT │High word. Sets the key used│ │ │AF_SHIFT │with another key to edit │ │ │AF_CONTROL │button text. │ │ │ │These are optional values. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │VK_F1 through VK_F12 │Low word. Sets the key used │ │ │VK_PAGEUP │to edit button text. │ │ │VK_PAGEDOWN │One of these values is │ │ │VK_HOME │required if the default is │ │ │VK_END │not set. │ │ │VK_INSERT │ │ │ │VK_TAB │ │ │ │VK_ENTER │ │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │TEXTEDITKEY_DEFAULT │Sets the default text edit │ │ │ │key. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │KeyRepeatDelay │rate │Sets the time before the key│ │ │ │starts repeating. This value│ │ │ │must be in the range │ │ │ │REPEATDELAY_MIN to │ │ │ │REPEATDELAY_MAX. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │REPEATDELAY_DEFAULT │Sets the default time before│ │ │ │the key starts repeating. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │KeyRepeatRate │rate │Sets the rate at which a key│ │ │ │repeats. This value must be │ │ │ │in the range REPEATRATE_MIN │ │ │ │to REPEATRATE_MAX. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │REPEATRATE_DEFAULT │Sets the default rate at │ │ │ │which a key repeats. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │PopupMenuKey │AF_VIRTUALKEY │High word. Sets the key used│ │ │AF_KBDCOMMAND │with another key to display │ │ │ │the pop-up menu. │ │ │ │Both of these values are │ │ │ │required if the default is │ │ │ │not set. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │AF_ALT │High word. Sets the key used│ │ │AF_SHIFT │with another key to display │ │ │AF_CONTROL │the pop-up menu. │ │ │ │These are optional values. │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │VK_F1 through VK_F12 │Low word. Sets the key used │ │ │VK_PAGEUP │to display the pop-up menu. │ │ │VK_PAGEDOWN │One of these values is │ │ │VK_HOME │required if the default is │ │ │VK_END │not set. │ │ │VK_INSERT │ │ │ │VK_TAB │ │ │ │VK_ENTER │ │ ├─────────────────┼─────────────────────┼────────────────────────────┤ │ │POPUPKEY_DEFAULT │Sets the default popup menu │ │ │ │key. │ └─────────────────┴─────────────────────┴────────────────────────────┘ ═══ 2.18. WPLaunchPad ═══ Class definition file: wplnchpd.idl Class hierarchy SOMObject WPObject WPAbstract WPLaunchPad Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the front panel object class. The Toolbar is a convenience for users that provides fast access to frequently used objects and Desktop actions. Objects may be placed on the Toolbar or in drawers, which are represented by a small button above objects on the Toolbar. There is no limit to the number of Toolbars that may exist in the system. The system Toolbar is defined as the one with an OBJECTID of . An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title, "Toolbar" and resides in the "System Startup" folder. Instance methods The following list shows all the WPLaunchPad methods.  wpAddLaunchPadPage1  wpAddLaunchPadPage2  wpQueryActionButtons  wpQueryActionButtonStyle  wpQueryCloseDrawer  wpQueryDisplaySmallIcons  wpQueryDisplayText  wpQueryDisplayTextInDrawers  wpQueryDisplayVertical  wpQueryDrawerHWND  wpQueryFloatOnTop  wpQueryHideLaunchPadFrameCtls  wpQueryObjectList  wpRefreshDrawer  wpSetActionButtonStyle  wpSetCloseDrawer  wpSetDisplaySmallIcons  wpSetDisplayText  wpSetDisplayTextInDrawers  wpSetDisplayVertical  wpSetDrawerHWND  wpSetFloatOnTop  wpSetHideLaunchPadFrameCtls  wpSetObjectListFromHObjects  wpSetObjectListFromObjects  wpSetObjectListFromStrings WPObject instance methods The following list shows all the methods overridden by the WPLaunchPad class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryConcurrentView  wpRestoreState  wpSaveState  wpSetup  wpUnInitData wpSetup override by WPLaunchPad Following are keyname-value pairs added by the WPLaunchPad class. The following table contains setup strings that can be used with WinCreateObject and WinSetObjectData to customize Toolbars: ┌───────────────┬───────────────┬──────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├───────────────┼───────────────┼──────────────────────────────┤ │FPOBJECTS │object IDs or │Adds objects to the end of the│ │ │path and file │Toolbar. If multiple objects │ │ │names │exist, the objects are │ │ │ │separated by a comma. For │ │ │ │example: │ │ │ │, │ ├───────────────┼───────────────┼──────────────────────────────┤ │DRAWEROBJECTS │drawer number, │Adds the objects to the end of│ │ │object IDs or │the numbered Toolbar drawer. │ │ │path and file │The drawer number is followed │ │ │names │by a comma-delimited set of │ │ │ │object IDs or path and file │ │ │ │names. The drawer number and │ │ │ │first object must be separated│ │ │ │by a comma. Examples of drawer│ │ │ │numbers : 0=Toolbar, │ │ │ │1=Left-most drawer, etc. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPCLOSEDRAWER │YES │The Toolbar drawers will close│ │ │ │after an object in the drawer │ │ │ │is opened. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │The Toolbar drawers will stay │ │ │ │open after an object in the │ │ │ │drawer is opened. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPACTIONSTYLE │TEXT │Display the action buttons as │ │ │ │text (the default). │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │OFF │Turns off the display of │ │ │ │action buttons. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │MINI │Displays the action buttons as│ │ │ │mini-icons. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NORMAL │Displays the action buttons as│ │ │ │normal (large) icons. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPVERTICAL │YES │The Toolbar will be displayed │ │ │ │vertically. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │The Toolbar will be displayed │ │ │ │horizontally (the default). │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPTEXT │YES │The object titles will appear │ │ │ │on the Toolbar. This has no │ │ │ │effect on the objects in the │ │ │ │drawers. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │The object titles will be │ │ │ │hidden. This has no effect on│ │ │ │the objects in the drawers. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPDRAWERTEXT │YES │The object titles will appear │ │ │ │on the objects in the drawers.│ │ │ │This has no effect on the │ │ │ │objects on the Toolbar. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │.The object titles will be │ │ │ │hidden. This has no effect on│ │ │ │the objects on the Toolbar. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPSMALLICONS │YES │Objects are displayed using │ │ │ │small icons. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │Objects are displayed using │ │ │ │large (normal) icons. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPHIDECTLS │YES │The frame controls (title bar │ │ │ │and system menu) are hidden │ │ │ │(the default). │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │The frame controls are │ │ │ │displayed. │ ├───────────────┼───────────────┼──────────────────────────────┤ │LPFLOAT │YES │The Toolbar will float on top │ │ │ │of all other windows. │ ├───────────────┼───────────────┼──────────────────────────────┤ │ │NO │The Toolbar will not float on │ │ │ │top of all other windows. │ └───────────────┴───────────────┴──────────────────────────────┘ Class methods There are currently no class methods defined for the WPLaunchPad Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPLaunchPad class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.19. WPMet ═══ Class definition file: wpmet.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPMet Description This is the metafile class object. All MET files are of this class. These MET files are templatable. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each MET file in the system. Instance methods There are currently no methods defined for the WPMet Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPMet class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetupOnce Class methods There are currently no class methods defined for the WPMet Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPMet class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryTitle WPFileSystem class methods. The following list shows all the class methods overridden by the WPMet class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryInstanceFilter  wpclsQueryInstanceType ═══ 2.20. WPMinWinViewer ═══ Class definition file: wpmwv.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPMinWinViewer Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the minimized window viewer object class. This is a special folder that contains only minimized window objects. An instance of this class can be created as a Workplace object. An instance of this class is created by the system during initialization. Instance methods The following list shows all the WPMinWinViewer methods.  wpFindMinWindow WPFileSystem instance methods The following list shows all the methods overridden by the WPMinWinViewer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFileMenuPage WPFolder instance methods The following list shows all the methods overridden by the WPMinWinViewer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFolderIncludePage  wpAddFolderView2Page  wpAddFolderView3Page WPObject instance methods The following list shows all the methods overridden by the WPMinWinViewer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpDragOver  wpFilterPopupMenu  wpMenuItemSelected  wpModifyPopupMenu  wpOpen Class methods There are currently no class methods defined for the WPMinWinViewer Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPMinWinViewer class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.21. WPMouse ═══ Class definition file: wpmouse.idl Class hierarchy SOMObject WPObject WPAbstract WPMouse Description This is the mouse object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Mouse" and resides in the "System Setup" folder. Instance methods The following list shows all the WPMouse methods:  wpAddMouseCometPage  wpAddMouseMappingsPage  wpAddMousePtrPage  wpAddMouseTimingPage  wpAddMouseTypePage WPObject instance methods The following list shows all the methods overridden by the WPMouse class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu Class methods There are currently no class methods defined for the WPMouse Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPMouse class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle WPAbstract class methods. The following list shows all the class methods overridden by the WPMouse class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQuerySetting  wpclsSetSetting wpclsSetSettings override by wpMouse The defaults can be specified on a wpclsSetSetting invocation to request that the setting be set to its default value. wpclsQuerySetting, however, never returns an xxxx_DEFAULT value. ┌────────────────────────┬─────────────────────────┬────────────────┐ │Setting │Value │Description │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ButtonSetup │BUTTONS_LEFTHANDED │Sets the mouse │ │ │ │buttons for a │ │ │ │left-handed │ │ │ │person. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │BUTTONS_RIGHTHANDED │Sets the mouse │ │ │ │buttons for a │ │ │ │right-handed │ │ │ │person. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │BUTTONS_DEFAULT │Sets the default│ │ │ │setup for the │ │ │ │mouse buttons. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │DisplayWindowListButton │INP_NONE │High word. │ │ │ │This value is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │WM_BUTTON2CLICK │Low word. Sets │ │ │WM_CHORD │the button which│ │ │ │displays the │ │ │ │window list. │ │ │ │One of these │ │ │ │values is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │WINDOWLISTBUTTON_DEFAULT │Sets the default│ │ │ │button which │ │ │ │displays the │ │ │ │window list. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │DoubleClickTime │time │Sets the time │ │ │ │between mouse │ │ │ │clicks. Higher │ │ │ │values allow │ │ │ │more time │ │ │ │between mouse │ │ │ │clicks, where as│ │ │ │lower values │ │ │ │allow less time │ │ │ │between mouse │ │ │ │clicks. │ │ │ │This value must │ │ │ │be in the range │ │ │ │170 to 1 060. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │DOUBLECLICK_DEFAULT │Sets the default│ │ │ │time between │ │ │ │mouse clicks. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │DragObjectButton │INP_NONE │High word. │ │ │ │This value is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │WM_BUTTON1MOTIONSTART │Low word. Sets │ │ │WM_BUTTON2MOTIONSTART │the button which│ │ │ │drags objects. │ │ │ │One of these │ │ │ │values is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │DRAGBUTTON_DEFAULT │Sets the button │ │ │ │which drags │ │ │ │objects to the │ │ │ │default. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │EditTitleTextButton │INP_ALT │High word. Sets │ │ │INP_CTRL │the key used │ │ │INP_NONE │with a mouse │ │ │INP_SHIFT │button to edit │ │ │ │button text. │ │ │ │One of these │ │ │ │values is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │WM_BUTTON1CLICK │Low word. Sets │ │ │WM_BUTTON2CLICK │the mouse button│ │ │WM_BUTTON1DBLCLK │used to edit │ │ │WM_BUTTON2DBLCKL │button text. │ │ │ │One of these │ │ │ │values is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │TEXTEDITBUTTON_DEFAULT │Sets the text │ │ │ │edit button to │ │ │ │the default. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │PopupMenuButton │INP_ALT │High word. Sets │ │ │INP_CTRL │the key used │ │ │INP_NONE │with a mouse │ │ │INP_SHIFT │button to │ │ │ │display pop-up │ │ │ │menus. │ │ │ │One of these │ │ │ │values is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │WM_BUTTON1CLICK │Low word. Sets │ │ │WM_BUTTON2CLICK │the mouse button│ │ │WM_BUTTON1DBLCLK │used to display │ │ │WM_BUTTON2DBLCKL │pop-up menus. │ │ │WM_CHORD │One of these │ │ │ │values is │ │ │ │required if the │ │ │ │default is not │ │ │ │set. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │POPUPBUTTON_DEFAULT │Sets the default│ │ │ │key and mouse │ │ │ │button used to │ │ │ │display pop-up │ │ │ │menus. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │TrackingSpeed │speed │Sets the mouse │ │ │ │tracking speed. │ │ │ │This value must │ │ │ │be in the range │ │ │ │1 to 7, where 1 │ │ │ │is the fastest │ │ │ │value. │ ├────────────────────────┼─────────────────────────┼────────────────┤ │ │TRACKING_DEFAULT │Sets the default│ │ │ │mouse tracking │ │ │ │speed. │ └────────────────────────┴─────────────────────────┴────────────────┘ ═══ 2.22. WPNetgrp ═══ Class definition file: wpnetgrp.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPNetgrp Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the network group object class. An instances of this class can be created as a Workplace object. Instances of this class are created for every LAN system in a WPNetwork, for example LAN server and Novell**). Instance methods The following list shows all the WPNetgrp methods.  wpAddNetworkPage  wpQueryNetIdentity  wpSetNetIdentity WPFileSystem instance methods The following list shows all the methods overridden by the WPNetgrp class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFile1Page  wpAddFile2Page  wpAddFile3Page WPFolder instance methods The following list shows all the methods overridden by the WPNetgrp class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFolderIncludePage  wpDeleteContents  wpPopulate WPObject instance methods The following list shows all the methods overridden by the WPNetgrp class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectGeneralPage  wpAddSettingsPages  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState  wpSetup  wpUnInitData Class methods There are currently no class methods defined for the WPNetgrp Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPNetgrp class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.23. WPNetLink ═══ Class definition file: wpnetlnk.idl Class hierarchy SOMObject WPObject WPAbstract WPShadow WPNetLink Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the network link object class. This object handles all saving and restoring of data for the shared directory object by providing a persistent link or reference to that shared directory. The purpose of this link is to locally store all the instance data of the shared directory that this object is linked to and then reroute all requests for help, context menus, open views, and so forth, to this object. An instance of this class can be created as a Workplace object. Instance methods The following list shows all the WPNetLink methods.  wpQueryObjectNetId  wpSetObjectNetId WPObject instance methods The following list shows all the methods overridden by the WPNetLink class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpCreateShadowObject  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpModifyPopupMenu  wpQueryStyle  wpRestoreState  wpSaveState  wpUnInitData Class methods There are currently no class methods defined for the WPNetLink Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPNetLink class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryStyle  wpclsQueryTitle ═══ 2.24. WPNetwork ═══ Class definition file: wpnetwrk.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPNetwork Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the network object class. An instances of this class can be created as a Workplace object. This object is the "network" folder that is created by the system on the Desktop. It is visible only if the LAN is attached to the machine being used. Instance methods There are currently no methods defined for the WPNetwork Workplace object class. WPFileSystem instance methods The following list shows all the methods overridden by the WPNetwork class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFile1Page  wpAddFile2Page  wpAddFile3Page WPFolder instance methods The following list shows all the methods overridden by the WPNetwork class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFolderIncludePage  wpPopulate WPObject instance methods The following list shows all the methods overridden by the WPNetwork class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSetup Class methods There are currently no class methods defined for the WPNetwork Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPNetwork class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.25. WPObject ═══ Class definition file: wpobject.idl Class hierarchy SOMObject WPObject Description This is the root Workplace object class. This is the fundamental class from which all Workplace objects are derived, regardless of where they are actually stored. Immediate descendant classes of WPObject are called storage classes, since they take responsibility for storing the object information, typically in a persistent form. Predefined Workplace object storage classes are the following:  WPAbstract  WPFileSystem  WPTransient A Workplace object of this class cannot be created. MenuID list The following list shows the WPMENUIDs: WPMENUID_ACCESSNEW WPMENUID_ARRANGE WPMENUID_ASSIGN WPMENUID_CLOSE WPMENUID_CHKDSK WPMENUID_CREATEANOTHER WPMENUID_COPY WPMENUID_COPYDSK WPMENUID_CREATESHADOW WPMENUID_DELETE WPMENUID_DESELALL WPMENUID_DETAILS WPMENUID_EJECTDISK WPMENUID_EXTENDEDHELP WPMENUID_FIND WPMENUID_FIXDSK WPMENUID_FORMAT WPMENUID_HELP WPMENUID_HELPINDEX WPMENUID_HELPKEYS WPMENUID_HELP_FOR_HELP WPMENUID_HOWTOGETHELP WPMENUID_ICON WPMENUID_LOCKDISK WPMENUID_LOCKUP WPMENUID_LOGIN WPMENUID_LOGOUT WPMENUID_MOVE WPMENUID_OPEN WPMENUID_PALETTE WPMENUID_PICKUP WPMENUID_PRIMARY WPMENUID_PRINT WPMENUID_PROGRAM WPMENUID_PROPERTIES WPMENUID_PUTDOWN WPMENUID_PUTDOWN_CANCEL WPMENUID_PUTDOWN_COPY WPMENUID_PUTDOWN_CREATE WPMENUID_PUTDOWN_LINK WPMENUID_PUTDOWN_MOVE WPMENUID_REFRESH WPMENUID_RESERVED1 WPMENUID_RESERVED2 WPMENUID_SELALL WPMENUID_SELECT WPMENUID_SHUTDOWN WPMENUID_SORT WPMENUID_SYSTEMSETUP WPMENUID_TREE WPMENUID_UNASSIGN WPMENUID_UNLOCKDISK WPMENUID_USER wpSetup override by WPObject The following table shows the keyname-value pairs added by the WPObject class. ┌─────────────┬────────────────────┬───────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├─────────────┼────────────────────┼───────────────────────────┤ │CCVIEW │DEFAULT │The default value of the │ │ │ │concurrent view setting of │ │ │ │the system is used when the│ │ │ │user selects open. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │YES │This sets the object's │ │ │ │multiple concurrent view │ │ │ │behavior, so that new views│ │ │ │of this object are created │ │ │ │every time the user selects│ │ │ │open. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │Opened view of this object │ │ │ │resurfaces when the user │ │ │ │selects open. │ ├─────────────┼────────────────────┼───────────────────────────┤ │DEFAULTVIEW │SETTINGS │This sets the default open │ │ │ │view to Settings view. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │id │This sets the default open │ │ │ │view to the id of a │ │ │ │user-added view (0-9). │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │DEFAULT │This sets the default open │ │ │ │view to the object's class │ │ │ │default view, as returned │ │ │ │by wpclsQueryDefaultView. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │HELPLIBRARY │filename │This sets the help library.│ ├─────────────┼────────────────────┼───────────────────────────┤ │HELPPANEL │id │This sets the object's │ │ │ │default help panel for │ │ │ │object-specific help. This │ │ │ │is equivalent to calling │ │ │ │wpSetDefaultHelp. │ ├─────────────┼────────────────────┼───────────────────────────┤ │HIDEBUTTON │YES │Views of this object have a│ │ │ │hide button as opposed to a│ │ │ │minimize button. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │Views of this object have a│ │ │ │minimize button as opposed │ │ │ │to a hide button. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │ │The default is the current │ │ │ │system Button appearance │ │ │ │for windows setting. This │ │ │ │cannot be specified here. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ICONFILE │filename │This sets the object's │ │ │ │icon. This is equivalent to│ │ │ │calling wpSetIconData. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ICONPOS │x,y │This sets the object's │ │ │ │initial icon position in a │ │ │ │folder. The x and y values │ │ │ │represent the position in │ │ │ │the object's folder in │ │ │ │percentage coordinates. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ICONRESOURCE │id,module │This sets the object's │ │ │ │icon. This is equivalent to│ │ │ │calling wpSetIconData. The │ │ │ │"id" is the icon resource │ │ │ │ID in the dynamic link │ │ │ │library (DLL) "module". │ ├─────────────┼────────────────────┼───────────────────────────┤ │MINWIN │HIDE │Views of this object hide │ │ │ │when their minimize button │ │ │ │is selected. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │VIEWER │Views of this object │ │ │ │minimize to the minimized │ │ │ │window viewer when their │ │ │ │minimize button is │ │ │ │selected. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │DESKTOP │Views of this object │ │ │ │minimize to the desktop │ │ │ │when their minimize button │ │ │ │is selected. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │ │The default is the current │ │ │ │Minimize button setting. │ │ │ │This cannot be specified │ │ │ │here. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOCOPY │YES │This sets the object's no │ │ │ │copy property, so that the │ │ │ │object cannot be copied. │ │ │ │This is equivalent to │ │ │ │calling wpSetStyle with a │ │ │ │style of OBJSTYLE_NOCOPY. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │copy property, so that the │ │ │ │object can be copied. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NODELETE │YES │This sets the object's no │ │ │ │delete property, so that │ │ │ │the object cannot be │ │ │ │deleted. This is equivalent│ │ │ │to calling wpSetStyle with │ │ │ │a style of │ │ │ │OBJSTYLE_NODELETE. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │delete property, so that │ │ │ │the object can be deleted. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NODRAG │YES │This sets the object's no │ │ │ │drag property, so that the │ │ │ │object cannot be dragged. │ │ │ │This is equivalent to │ │ │ │calling wpSetStyle with a │ │ │ │style of OBJSTYLE_NODRAG. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │drag property, so that the │ │ │ │object can be dragged. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NODROP │YES │This sets the object's no │ │ │ │drop property, so that no │ │ │ │other object can be dropped│ │ │ │on it. This is equivalent │ │ │ │to calling wpSetStyle with │ │ │ │a style of │ │ │ │OBJSTYLE_NODROPON. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │drop property, so that │ │ │ │another object can be │ │ │ │dropped on it. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOLINK │YES │This sets the object's no │ │ │ │link property, so that the │ │ │ │object cannot be linked. │ │ │ │This is equivalent to │ │ │ │calling wpSetStyle with a │ │ │ │style of OBJSTYLE_NOLINK. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │link property, so that the │ │ │ │object can be linked. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOMOVE │YES │This sets the object's no │ │ │ │move property, so that the │ │ │ │object cannot be moved. │ │ │ │This is equivalent to │ │ │ │calling wpSetStyle with a │ │ │ │style of OBJSTYLE_NOMOVE. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │move property, so that the │ │ │ │object can be moved. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOPRINT │YES │This sets the object's no │ │ │ │print property, so that the│ │ │ │object cannot be printed. │ │ │ │This is equivalent to │ │ │ │calling wpSetStyle with a │ │ │ │style of OBJSTYLE_NOPRINT. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │print property, so that the│ │ │ │object can be printed. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NORENAME │YES │This sets the object's no │ │ │ │rename property, so that │ │ │ │the object cannot be │ │ │ │renamed. This is equivalent│ │ │ │to calling wpSetStyle with │ │ │ │a style of │ │ │ │OBJSTYLE_NORENAME. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │rename property, so that │ │ │ │the object can be renamed. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOSETTINGS │YES │This sets the object's no │ │ │ │settings property, so that │ │ │ │the object' settings cannot│ │ │ │be opened. This is │ │ │ │equivalent to calling │ │ │ │wpSetStyle with a style of │ │ │ │OBJSTYLE_NOSETTINGS. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │settings property, so that │ │ │ │the object's settings can │ │ │ │be opened. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOSHADOW │YES │This sets the object's no │ │ │ │link property, so that the │ │ │ │object cannot be linked. │ │ │ │This is equivalent to │ │ │ │calling wpSetStyle with a │ │ │ │style of OBJSTYLE_NOLINK. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's no│ │ │ │link property, so that the │ │ │ │object can be linked. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │NOTVISIBLE │YES │This sets the object's not │ │ │ │visible property, so that │ │ │ │the object cannot be made │ │ │ │visible. This is equivalent│ │ │ │to calling wpSetStyle with │ │ │ │a style of │ │ │ │OBJSTYLE_NOTVISIBLE. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's │ │ │ │not visible property, so │ │ │ │that the object can be made│ │ │ │visible. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │OBJECTID │ │This sets a persistent ID │ │ │ │for the object. The │ │ │ │OBJECTID stays with the │ │ │ │object even if it is moved │ │ │ │or renamed. The object │ │ │ │pointer or handle can be │ │ │ │retrieved via │ │ │ │wpclsQueryObject or │ │ │ │WinQueryObject , │ │ │ │respectively. An OBJECTID │ │ │ │is any unique string │ │ │ │preceded with a "<" and │ │ │ │terminated with a ">". │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │ │The default is to not have │ │ │ │an ID. │ ├─────────────┼────────────────────┼───────────────────────────┤ │OPEN │SETTINGS │This opens the Settings │ │ │ │view when an object is │ │ │ │created or when │ │ │ │WinSetObjectData is called.│ ├─────────────┼────────────────────┼───────────────────────────┤ │ │DEFAULT │This opens the default view│ │ │ │when an object is created │ │ │ │or when WinSetObjectData is│ │ │ │called. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │ │The default is to not open │ │ │ │a view. │ ├─────────────┼────────────────────┼───────────────────────────┤ │TEMPLATE │YES │This sets the object's │ │ │ │template property. This is │ │ │ │equivalent to calling │ │ │ │wpSetStyle with a style of │ │ │ │OBJSTYLE_TEMPLATE. │ ├─────────────┼────────────────────┼───────────────────────────┤ │ │NO │This resets the object's │ │ │ │template property. │ │ │ │This is the default value. │ ├─────────────┼────────────────────┼───────────────────────────┤ │TITLE │Title │This sets the object's │ │ │ │title. This is equivalent │ │ │ │to calling wpSetTitle. │ └─────────────┴────────────────────┴───────────────────────────┘ Example pszSetupString="TITLE=MYObject;" "ICONFILE=myobj.ico;" "HELPPANEL=132;" "TEMPLATE=YES;" "NODELETE=NO"; Instance methods The following lists show how all the WPObject instance methods are related within functional areas: Settings notebook methods  wpAddObjectGeneralPage  wpAddObjectGeneralPage2  wpAddObjectWindowPage  wpAddSettingsPages  wpInsertSettingsPage Save/restore state methods  wpRestoreData  wpRestoreLong  wpRestoreState  wpRestoreString  wpSaveData  wpSaveDeferred  wpSaveImmediate  wpSaveLong  wpSaveState  wpSaveString Object usage methods  wpAddToObjUseList  wpCnrDeleteUseItem  wpDeleteFromObjUseList  wpFindUseItem  wpIsLocked  wpLockObject  wpUnlockObject Popup menu methods  wpClose  wpCopyObject  wpCreateAnother  wpCreateFromTemplate  wpCreateShadowObject  wpCreateShadowObjectExt  wpDelete  wpDisplayHelp  wpDisplayMenu  wpFilterPopupMenu  wpHide  wpInsertPopupMenuItems  wpIsObjectInitialized  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpMoveObject  wpObjectReady  wpOpen  wpPrintObject  wpRestore Query and Set object information methods  wpModifyStyle  wpQueryButtonAppearance  wpQueryConcurrentView  wpQueryConfirmations  wpQueryContainerFlagPtr  wpQueryCoreRecord  wpQueryDefaultHelp  wpQueryDefaultIconPos  wpQueryDefaultView  wpQueryDetailsData  wpQueryFolder  wpQueryHandle  wpQueryIcon  wpQueryIconData  wpQueryMinWindow  wpQueryNameClashOptions  wpQueryObjectID  wpQueryScreenGroupID  wpQueryStyle  wpQueryTitle  wpSetButtonAppearance  wpSetConcurrentView  wpSetDefaultHelp  wpSetDefaultIconPos  wpSetDefaultView  wpSetIcon  wpSetIconData  wpSetIconHandle  wpSetMinWindow  wpSetObjectID  wpSetStyle  wpSetTitle  wpViewObject Error handling methods  wpQueryError  wpSetError Memory management methods  wpAllocMem  wpFreeMem Setup/cleanup methods  wpFree  wpInitData  wpScanSetupString  wpSetup  wpSetupOnce  wpUnInitData Direct manipulation methods  wpDraggedOverObject  wpDragOver  wpDrop  wpDroppedOnObject  wpEndConversation  wpFormatDragItem  wpRender  wpRenderComplete Miscellaneous methods  wpCnrInsertObject  wpCnrRefreshDetails  wpCnrRemoveObject  wpCnrSetEmphasis  wpConfirmDelete  wpConfirmObjectTitle  wpCopiedFromTemplate  wpDoesObjectMatch  wpFindViewItem  wpIsDeleteable  wpRegisterView  wpSwitchTo  wpWaitForClose SOMObject methods The following list shows all the instance methods overridden by the WPObject class. These instance methods are overridden in order to modify the behavior defined by an ancestor class.  somDefaultInit  somInit  somUninit Class Methods The following list shows all the WPObject class methods:  wpclsCreateDefaultTemplates  wpclsDecUsage  wpclsFindObjectEnd  wpclsFindObjectFirst  wpclsFindObjectNext  wpclsFindOneObject  wpclsIncUsage  wpclsInitData  wpclsInsertMultipleObjects  wpclsMakeAwake  wpclsNew  wpclsObjectFromHandle  wpclsQueryButtonAppearance  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryDetails  wpclsQueryDetailsInfo  wpclsQueryError  wpclsQueryExtendedCriteria  wpclsQueryFolder  wpclsQueryIcon  wpclsQueryIconData  wpclsQueryObject  wpclsQuerySearchInfo  wpclsQuerySettingsPageSize  wpclsQueryStyle  wpclsQueryTitle  wpclsRemoveObjects  wpclsSetError  wpclsSetIconData  wpclsSetIcon  wpclsSetSettingsPageSize  wpclsUnInitData SOMClass methods The following list shows all the class methods overridden by the the WPObject class. These methods are overridden to modify the behavior defined by an ancestor class.  somClassReady  somNew  somRenew ═══ 2.26. WPPalette ═══ Class definition file: wppalet.idl Class hierarchy SOMObject WPObject WPAbstract WPPalette Description This is the palette object class. There are no instances of this class initially created by the system. Instance methods The following list shows all the WPPalette instance methods:  wpDragCell  wpEditCell  wpInitCellStructs  wpPaintCell  wpPaintPalette  wpQueryPaletteHelp  wpQueryPaletteInfo  wpRedrawCell  wpRestoreCellData  wpSaveCellData  wpSelectCell  wpSetPaletteInfo  wpSetupCell  wpShowPalettePointer WPObject instance methods The following list shows all the methods overridden by the WPPalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState  wpSetup  wpUnInitData wpSetup override by WPPalette The following table shows the keyname-value pairs added by the WPPalette class. ┌───────────────┬───────────────┬──────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├───────────────┼───────────────┼──────────────────────────────┤ │XCELLCOUNT │columns │Number of columns of cells. │ │ │ │If not specified, defaults to │ │ │ │13. │ ├───────────────┼───────────────┼──────────────────────────────┤ │YCELLCOUNT │rows │Number of rows of cells. If │ │ │ │not specified, defaults to 9. │ ├───────────────┼───────────────┼──────────────────────────────┤ │XCELLWIDTH │width │Width in dialog units of each │ │ │ │cell. │ ├───────────────┼───────────────┼──────────────────────────────┤ │YCELLHEIGHT │height │Height in dialog units of each│ │ │ │cell. │ ├───────────────┼───────────────┼──────────────────────────────┤ │XCELLGAP │gap │X separation in dialog units │ │ │ │between each cell. │ ├───────────────┼───────────────┼──────────────────────────────┤ │YCELLGAP │gap │Y separation in dialog units │ │ │ │between each cell. │ └───────────────┴───────────────┴──────────────────────────────┘ Example pszSetupString="XCELLCOUNT=3," "YCELLCOUNT=4"; Class methods The following list shows all the WPPalette class methods:  wpclsQueryEditString WPObject class methods. The following list shows all the class methods overridden by the WPPalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryStyle  wpclsQueryTitle ═══ 2.27. WPPdr ═══ Class definition file: wppdr.idl Class hierarchy SOMObject WPObject WPTransient WPPdr Description This is the printer driver object class. An instance of this class is created by the print object in its Settings view. Instance methods There are currently no methods defined for the WPPdr Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPPdr class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpDragOver  wpDrop  wpFilterPopupMenu  wpFree  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryIcon  wpQueryTitle  wpUnInitData Class methods There are currently no class methods defined for the WPPdr Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPPdr class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIcon  wpclsQueryStyle  wpclsQueryTitle ═══ 2.28. WPPif ═══ Class definition file: wppif.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPPif Description This is the Picture Interchange Format (PIF) class object. All PIF files are of this class. These PIF files are templatable. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each PIF file in the system. Instance methods There are currently no methods defined for the WPPif Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPPif class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetupOnce Class methods There are currently no class methods defined for the WPPif Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPPif class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryTitle WPFileSystem class methods. The following list shows all the class methods overridden by the WPPif class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryInstanceFilter  wpclsQueryInstanceType ═══ 2.29. WPPointer ═══ Class definition file: wpptr.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPPointer Description This is the WPPointer class. All pointers are of this class. These pointer files are templatable. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each pointer in the system. Instance methods There are currently no methods defined for the WPPointer Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPPointer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetupOnce Class methods There are currently no class methods defined for the WPPointer Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPPointer class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryTitle WPFileSystem class methods. The following list shows all the class methods overridden by the WPPointer class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryInstanceFilter  wpclsQueryInstanceType ═══ 2.30. WPPort ═══ Class definition file: wpport.idl Class hierarchy SOMObject WPObject WPTransient WPPort Description This is the port object class. An instance of this class is created by the print object in its Settings view. Instance methods There are currently no methods defined for the WPPort Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPPort class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpCnrSetEmphasis  wpDragOver  wpDrop  wpFilterPopupMenu  wpFree  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryIcon  wpQueryTitle  wpUnInitData Class methods There are currently no class methods defined for the WPPort Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPPort class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIcon  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.31. WPPower ═══ Class definition file: wppower.idl Class hierarchy SOMObject WPObject WPAbstract WPPower Description This class is specific to version 2.1, or higher, of the OS/2 operating system. This is the power object class that represents the power management support. An instance of this class can be created as a Workplace object. An instance of this class is created initially by systems that support power management. It cannot be deleted. It has the title "Power" and resides in the "System Setup" folder. Instance methods The following list shows all the WPPower methods:  wpAddPowerPage  wpAddPowerViewPage  wpChangePowerState  wpQueryAutoRefresh  wpQueryDefStatusView  wpQueryPowerConfirmation  wpQueryPowerManagement  wpQueryRefreshRate  wpSetAutoRefresh  wpSetDefStatusView  wpSetPowerConfirmation  wpSetPowerManagement  wpSetRefreshRate WPObject instance methods The following list shows all the methods overridden by the WPPower class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState Class methods There are currently no class methods defined for the WPPower Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPPower class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.32. WPPrinter ═══ Class definition file: wpprint.idl Class hierarchy SOMObject WPObject WPAbstract WPPrinter Description This is the printer object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system in its template form. It has the title "Printer" and resides in the "Templates" folder. Instances of this class are also created initially by the system for each print configured. Each instance will have a title corresponding to the description of the configured queue and printer and will reside on the desktop. Instance methods The following list shows all the WPPrinter methods:  wpDeleteAllJobs  wpHoldPrinter  wpJobAdded  wpJobChanged  wpJobDeleted  wpQueryComputerName  wpQueryPrinterName  wpQueryQueueOptions  wpQueryRemoteOptions  wpReleasePrinter  wpSetComputerName  wpSetDefaultPrinter  wpSetPrinterName  wpSetQueueOptions  wpSetRemoteOptions WPObject instance methods The following list shows all the methods overridden by the WPPrinter class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpCopiedFromTemplate  wpCopyObject  wpCreateAnother  wpCreateFromTemplate  wpCreateShadowObject  wpDragOver  wpDrop  wpFilterPopupMenu  wpFree  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpMoveObject  wpOpen  wpQueryDefaultHelp  wpQueryDefaultView  wpQueryIcon  wpQueryIconData  wpQueryStyle  wpQueryTitle  wpRestoreState  wpSaveState  wpSetDefaultView  wpSetIcon  wpSetIconData  wpSetTitle  wpSetup  wpUnInitData wpSetup override by WPPrint The following table shows the keyname-value pairs added by the WPPrint class. ┌─────────────────────────┬─────────────┬───────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │APPDEFAULT │YES │This printer object is to │ │ │ │become the application's │ │ │ │default printer object for │ │ │ │printing. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │ │NO │This printer object is not │ │ │ │to become the application's│ │ │ │default printer object for │ │ │ │printing. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │DEFAULTVIEW │DETAILS │Default open view for this │ │ │ │printer object is in │ │ │ │details view. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │ │ICON │Default open view for this │ │ │ │printer object is in icon │ │ │ │view. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │JOBDIALOGBEFOREPRINT │YES │The job properties dialog │ │ │ │is displayed before │ │ │ │printing. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │ │NO │The job properties dialog │ │ │ │is not displayed before │ │ │ │printing. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │JOBPROPERTIES │filename │The complete path to a │ │ │ │binary file containing the │ │ │ │default job properties for │ │ │ │this printer object. This │ │ │ │file can be created by │ │ │ │saving the │ │ │ │PRQINFO3->pDriverData data │ │ │ │to a file; this data can be│ │ │ │obtained by using the │ │ │ │SplQueryQueue API of the │ │ │ │spooler. │ │ │ │For more information about │ │ │ │spooler functions, see the │ │ │ │Presentation Manager │ │ │ │Programming Reference. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │OUTPUTTOFILE │YES │The output of this printer │ │ │ │object goes to a file. The │ │ │ │user will be prompted for a│ │ │ │filename each time a print │ │ │ │job is submitted to this │ │ │ │printer object. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │ │NO │The output of this printer │ │ │ │object does not go to a │ │ │ │file. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │PORTNAME │portname │The names of already │ │ │ │installed ports to which │ │ │ │this printer object is to │ │ │ │be attached. In the case of│ │ │ │more than one port, specify│ │ │ │a comma-separated list. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │PRINTDRIVER │driver.device│The complete name of the │ │ │ │print-driver that this │ │ │ │printer object is to use. │ │ │ │For example: 'IBM42XX.IBM │ │ │ │420 Proprinter III' │ │ │ │In the case of more than │ │ │ │one print driver, specify a│ │ │ │comma-separated list. │ │ │ │These printer drivers must │ │ │ │already be installed. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │PRINTERSPECIFICFORMAT │YES │The printer object spools │ │ │ │print jobs in PM_Q_RAW │ │ │ │format. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │ │NO │The printer object spools │ │ │ │print jobs in PM_Q_STANDARD│ │ │ │format. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │PRINTWHILESPOOLING │YES │The printing is enabled │ │ │ │while the job is spooling. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │ │NO │The printing is disabled │ │ │ │while the job is spooling. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │QSTARTTIME │time │The time when the printer │ │ │ │object starts printing. The│ │ │ │time format is HH:MM, and │ │ │ │the base is a 24-hour │ │ │ │clock. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │QSTOPTIME │time │The time when the printer │ │ │ │object is to stop printing.│ │ │ │The time format is HH:MM, │ │ │ │and the base is a 24-hour │ │ │ │clock. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │QUEUENAME │name │The local queue name for │ │ │ │the printer object. If a │ │ │ │queue name is not │ │ │ │specified, one is created │ │ │ │by the printer object. │ │ │ │The QUEUENAME key will be │ │ │ │ignored if this object has │ │ │ │already been assigned a │ │ │ │queue. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │QUEUEDRIVER │qdrvname │The queue driver name. The │ │ │ │queue driver must already │ │ │ │be installed. │ ├─────────────────────────┼─────────────┼───────────────────────────┤ │SEPARATORFILE │filename │A separator file that │ │ │ │prints before each print │ │ │ │job. │ └─────────────────────────┴─────────────┴───────────────────────────┘ Class methods There are currently no class methods defined for the WPPrinter Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPPrinter class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIcon  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.33. WPProgram ═══ Class definition file: wppgm.idl Class hierarchy SOMObject WPObject WPAbstract WPProgram Description This is the program object class. This class provides an object that points to executable programs and allows the user to run that program by simply double-clicking on the program object. The program can also contain a variety of useful additional parameters, such as the environment for the program and the parameters that are passed to it. An instance of this class can be created as a Workplace object and is created initially by the system in its template form. It has the title "Program" and resides in the "Templates" folder. Other instances of this class initially created by the system include:  "DOS Full Screen" in the "Command Prompts" folder  "DOS Window" in the "Command Prompts" folder  "OS/2 Full Screen" in the "Command Prompts" folder  "OS/2 Window" in the "Command Prompts" folder  Every object in the "Games" folder  Some objects in the "Information" folder  Every object in the "Productivity" folder Instance methods The following list shows all the WPProgram methods:  wpAddProgramAssociationPage  wpAddProgramPage  wpAddProgramSessionPage  wpQueryAssociationFilter  wpQueryAssociationType  wpQueryProgDetails  wpQueryProgramAssociations  wpSetAssociationFilter  wpSetAssociationType  wpSetProgDetails  wpSetProgramAssociations  wpSetProgIcon WPObject instance methods The following list shows all the methods overridden by the WPProgram class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpCopyObject  wpCreateAnother  wpCreateFromTemplate  wpDragOver  wpDrop  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpMoveObject  wpOpen  wpQueryDefaultHelp  wpQueryIcon  wpQueryIconData  wpRestoreState  wpSaveState  wpSetIconData  wpSetTitle  wpSetup  wpUnInitData wpSetup override by WPProgram The following table shows the keyname-value pairs added by the WPProgram class. ┌───────────────┬─────────────────────────┬──────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ASSOCFILTER │filters │Sets the filename filter for │ │ │ │files associated with this │ │ │ │program. Multiple filters are │ │ │ │separated by commas. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ASSOCTYPE │type │Sets the type of files │ │ │ │associated with this program. │ │ │ │Multiple types are separated │ │ │ │by commas. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │EXENAME │filename │Sets the name of the program. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │MAXIMIZED │YES │The program window is │ │ │ │maximized upon startup. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │NO │The program window is restored│ │ │ │to normal upon startup. │ │ │ │This is the default setting. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │MINIMIZED │YES │The program window is │ │ │ │minimized upon startup. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │NO │The program window is restored│ │ │ │to normal upon startup. │ │ │ │This is the default setting. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │PROGTYPE │FULLSCREEN │Sets the session type to OS/2 │ │ │ │full-screen mode. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PM │Sets the session type to PM. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_30_STD │Sets the session type to │ │ │ │standard compatibility full │ │ │ │screen mode. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_31_ENH │Sets the session type to │ │ │ │enhanced compatibility full │ │ │ │screen mode. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_31_ENHSEAMLESSCOMMON│Sets the session type to │ │ │ │WIN-OS/2* window in the │ │ │ │WIN-OS/2 enhanced │ │ │ │compatibility common session. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_31_ENHSEAMLESSVDM │Sets the session type to │ │ │ │WIN-OS/2 window in a separate │ │ │ │session enhanced compatibility│ │ │ │mode. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_31_STD │Sets the session type to │ │ │ │standard compatibility full │ │ │ │screen mode. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_31_STDSEAMLESSCOMMON│Sets the session type to │ │ │ │WIN-OS/2 window in the │ │ │ │WIN-OS/2 standard │ │ │ │compatibility common session. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │PROG_31_STDSEAMLESSVDM │Sets the session type to │ │ │ │WIN-OS/2 window in a separate │ │ │ │session standard compatibility│ │ │ │mode. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │SEPARATEWIN │Sets the session type to │ │ │ │WIN-OS/2 window running in a │ │ │ │separate VDM. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │VDM │Sets the session type to DOS │ │ │ │full-screen. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │WIN │Sets the session type to │ │ │ │WIN-OS/2 full screen. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │WINDOWABLEVIO │Sets the session type to OS/2 │ │ │ │windowed. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │WINDOWEDVDM │Sets the session type to DOS │ │ │ │windowed. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │WINDOWEDWIN │Sets the session type to │ │ │ │WIN-OS/2 window. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │NOAUTOCLOSE │YES │Leaves the window open when │ │ │ │the program terminates. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │ │NO │Closes the window when the │ │ │ │program terminates. │ │ │ │This is the default setting. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │PARAMETERS │params │Sets the parameters list, │ │ │ │which may include substitution│ │ │ │characters. │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │SET │XXX=VVV │XXX is an environment │ │ │ │variable. VVV sets the value │ │ │ │of the environment variable. │ │ │ │This is also used to specify │ │ │ │DOS settings on DOS and │ │ │ │Windows** programs. │ │ │ │Each variable/value pair must │ │ │ │be separated by a NULL (\0), │ │ │ │and the entire string must be │ │ │ │terminated by two NULLS │ │ │ │(\0\0). For exmple: DOS │ │ │ │DEVICE=value\0env=value\0\0 │ ├───────────────┼─────────────────────────┼──────────────────────────────┤ │STARTUPDIR │pathname │Sets the working directory. │ └───────────────┴─────────────────────────┴──────────────────────────────┘ Example pszSetupString="PROGTYPE=VDM;" "EXENAME=C=\EDIT.EXE;" "ASSOCFILTER=*.DOC,*.TXT;" "ASSOCTYPE=Plain Text;" "SET DOS_DEVICE=1.SYS,2.SYS;" "SET PATH=C:\FRED"; Class methods There are currently no class methods defined for the WPProgram Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPProgram class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.34. WPProgramFile ═══ Class definition file: wppgmf.idl Class hierarchy SOMObject WPObject WPFileSystem WPDataFile WPProgramFile Description This is the program file object class. All executable files are of this class. From the Settings notebook pages for objects of this class, it is possible to set up associations to various data file types (files with .TYPE EAs or file extensions). It is also possible to set up a default working directory and specify parameters to the executable program to be used when it is opened from the shell. An instance of this class can be created as a Workplace object. Instances of this class are created initially by the system for each program file in the system. Each instance has a title corresponding to the file name of the program file it represents and resides in a folder corresponding to the physical directory in which the program file resides. Instance methods The following list shows all the WPProgramFile methods:  wpAddProgramAssociationPage  wpAddProgramPage  wpAddProgramSessionPage  wpQueryAssociationFilter  wpQueryAssociationType  wpQueryProgDetails  wpQueryProgramAssociations  wpSetAssociationFilter  wpSetAssociationType  wpSetProgDetails  wpSetProgramAssociations  wpSetProgIcon WPObject instance methods The following list shows all the methods overridden by the WPProgramFile class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpCopyObject  wpCreateAnother  wpDragOver  wpDrop  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpMoveObject  wpOpen  wpQueryNameClashOptions  wpRestoreState  wpSaveState  wpSetup wpSetup override by WPProgramFile The following table shows the keyname-value pairs added by the WPProgramFile class. ┌───────────────┬─────────────────────────┬────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├───────────────┼─────────────────────────┼────────────────────┤ │ASSOCFILTER │filters │Sets the filename │ │ │ │filter for files │ │ │ │associated with this│ │ │ │program. Multiple │ │ │ │filters are │ │ │ │separated by commas.│ ├───────────────┼─────────────────────────┼────────────────────┤ │ASSOCTYPE │type │Sets the type of │ │ │ │files associated │ │ │ │with this program. │ │ │ │Multiple types are │ │ │ │separated by commas.│ └───────────────┴─────────────────────────┴────────────────────┘ Example pszSetupString="PROGTYPE=VDM;" "EXENAME=C=\EDIT.EXE;" "ASSOCFILTER=*.DOC,*.TXT;" "ASSOCTYPE=Plain Text"; WPDataFile instance methods The following list shows all the methods overridden by the WPProgramFile class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetAssociatedFileIcon Class methods There are currently no class methods defined for the WPProgramFile Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPProgramFile class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.35. WPQdr ═══ Class definition file: wpqdr.idl Class hierarchy SOMObject WPObject WPTransient WPQdr Description This is the queue driver object class. An instance of this class is created by the print object in its Settings view. Instance methods There are currently no methods defined for the WPQdr Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPQdr class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpDragOver  wpDrop  wpFilterPopupMenu  wpFree  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryIcon  wpQueryTitle  wpUnInitData Class methods There are currently no class methods defined for the WPQdr Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPQdr class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIcon  wpclsQueryStyle  wpclsQueryTitle ═══ 2.36. WPRootFolder ═══ Class definition file: wprootf.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPRootFolder Description The WPRootFolder class represents the root folder (or directory) of a file-system device. Instances of this class exist for every file-system device available. Each instance is paired with a WPDisk object, which represents a particular device. An instance of this class can be created as a Workplace object. Instance methods There are no methods defined in the WPRootFolder Workplace object class. WPFileSystem instance methods The following list shows the instance methods overridden by the WPRootFolder class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFile1Page  wpAddFile2Page  wpAddFile3Page WPObject instance methods The following list shows the instance methods overridden by the WPRootFolder class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpFilterPopupMenu  wpOpen  wpRefresh  wpRestoreState  wpSaveState  wpSetDefaultView  wpSetTitle Class methods There are currently no class methods defined for the WPRootFolder Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPRootFolder class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsInitData  wpclsQueryDefaultView  wpclsQueryStyle  wpclsUnInitData ═══ 2.37. WPRPrinter ═══ Class definition file: wprprint.idl Class hierarchy SOMObject WPObject WPAbstract WPPrinter WPRPrinter Description This is the remote (network) printer object class. An instance of this class represents a print resource on another computer or server. For proper behavior, a network must be installed. Each instance has a title corresponding to the remote resource and resides on the desktop. Instance methods The following list shows all the WPRPrinter methods:  wpAddNetworkPage  wpQueryLocalAlias  wpQueryNetworkId WPObject instance methods The following list shows all the methods overridden by the WPRPrinter class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpCopiedFromTemplate  wpCopyObject  wpCreateFromTemplate  wpDragOver  wpDrop  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState  wpSetup  wpUnInitData wpSetup override by WPRPrinter The following table shows the keyname-value pairs added by the WPRPrinter class. ┌─────────────────┬─────────────────┬──────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├─────────────────┼─────────────────┼──────────────────────────┤ │ICON │filename │The name of the .ICO file │ │ │ │to be used as the icon for│ │ │ │this object. │ ├─────────────────┼─────────────────┼──────────────────────────┤ │NETID │ │The full name of the │ │ │ │printer resource as it is │ │ │ │known to the network. For │ │ │ │example: │ │ │ │LS:\\DEPTSERV\DEPTPRNT │ │ │ │The NETID key will be │ │ │ │ignored and FALSE will be │ │ │ │returned if this object │ │ │ │has already been assigned │ │ │ │a NetId. │ ├─────────────────┼─────────────────┼──────────────────────────┤ │REFRESHINTERVAL │value │Time interval, in seconds,│ │ │ │when the printer object is│ │ │ │refreshed. │ ├─────────────────┼─────────────────┼──────────────────────────┤ │SHOWJOBS │ALL │All jobs are displayed in │ │ │ │the printer object. │ ├─────────────────┼─────────────────┼──────────────────────────┤ │ │OWN │Only the current user's │ │ │ │jobs are displayed in the │ │ │ │printer object. │ └─────────────────┴─────────────────┴──────────────────────────┘ Class methods There are currently no class methods defined for the WPRPrinter Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPRPrinter class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryIcon  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.38. WPSchemePalette ═══ Class definition file: wpscheme.idl Class hierarchy SOMObject WPObject WPAbstract WPPalette WPSchemePalette Description This is the scheme palette object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Scheme Palette" and resides in the "System Setup" folder. Instance methods There are currently no methods defined for the WPSchemePalette Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPSchemePalette class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpMenuItemHelpSelected  wpSetup wpSetup override by WPSchemePalette The following are the keyname-value pairs added by the WPSchemePalette class. ┌──────────┬────────────┬──────────────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├──────────┼────────────┼──────────────────────────────────────┤ │AUTOSETUP │YES │This automatically sets the palette │ │ │ │values to the original system palette │ │ │ │settings. │ │ │ │This is the default setting. │ ├──────────┼────────────┼──────────────────────────────────────┤ │ │NO │This does not set palette values to │ │ │ │the original system palette settings. │ ├──────────┼────────────┼──────────────────────────────────────┤ │SCHEMES │Schemetype │These are the initial schemes for each│ │ │ │cell in the scheme palette. The values│ │ │ │for each cell are separated by commas.│ │ │ │This is equivalent to calling the │ │ │ │wpSetupCell instance method. The │ │ │ │schemetype value is presented as the │ │ │ │scheme name followed by a colon, │ │ │ │followed by an application name in the│ │ │ │INI file. │ ├──────────┼────────────┼──────────────────────────────────────┤ │XCELLCOUNT│columns │Number of X cells as decimal digits. │ │ │ │If not specified, defaults to 4. │ ├──────────┼────────────┼──────────────────────────────────────┤ │YCELLCOUNT│rows │Number of Y cells as decimal digits. │ │ │ │If not specified, defaults to 7. │ └──────────┴────────────┴──────────────────────────────────────┘ Example pszSetupString="SCHEMES=Marble:PM_Marble_Colors," "Southwest:PM_Southwest_Colors," "Khaki:PM_Khaki_Colors"; WPPalette methods The following list shows all the methods overridden by the WPSchemePalette class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpDragCell  wpEditCell  wpPaintCell  wpQueryPaletteHelp  wpSetupCell Class methods There are currently no class methods defined for the WPSchemePalette Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPSchemePalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle WPPalette class methods The following list shows all the class methods overridden by the WPSchemePalette class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryEditString ═══ 2.39. WPServer ═══ Class definition file: wpserver.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPServer Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the server object class. An instances of this class can be created as a Workplace object. Instances of this class are created for every server in a WPNetgrp folder that is accessible to the user. Instance methods The following list shows all the WPServer methods.  wpAddServerPage  wpQuerySrvrIdentity WPFileSystem instance methods The following list shows all the methods overridden by the WPServer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFile1Page  wpAddFile2Page  wpAddFile3Page WPFolder instance methods The following list shows all the methods overridden by the WPServer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFolderIncludePage  wpDeleteContents  wpPopulate WPObject instance methods The following list shows all the methods overridden by the WPServer class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectGeneralPage  wpAddSettingsPages  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState  wpSetup  wpUnInitData wpSetup override by WPServer The following table shows the keyname-value pairs added by the WPServer class. ┌────────────┬───────────────┬─────────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├────────────┼───────────────┼─────────────────────────────────┤ │SRVCOMMENT │comment string │This sets the object's title to │ │ │ │the specified comment string. │ │ │ │This is equivalent to calling │ │ │ │wpSetTitle. │ │ │ │Note: │ │ │ │The value specified for the TITLE│ │ │ │keyword will override this │ │ │ │comment. │ └────────────┴───────────────┴─────────────────────────────────┘ Class methods There are currently no class methods defined for the WPServer Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPServer class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryIconDataN  wpclsQueryStyle  wpclsQueryTitle ═══ 2.40. WPShadow ═══ Class definition file: wpshadow.idl Class hierarchy SOMObject WPObject WPAbstract WPShadow Description This is the shadow object class, instances of which provide a persistent link or reference to any other object. This is achieved by storing away the location and identity of the object to which it is linked and then rerouting all requests for help, context menus, and open views to the object to which it is linked. Instance methods The following list shows all the WPShadow methods:  wpQueryShadowedObject  wpSetLinkToObject  wpSetShadowTitle WPObject instance methods The following list shows all the methods overridden by the WPShadow class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpConfirmDelete  wpConfirmObjectTitle  wpCreateFromTemplate  wpCreateShadowObject  wpDraggedOverObject  wpDragOver  wpDrop  wpDroppedOnObject  wpFilterPopupMenu  wpFormatDragItem  wpInitData  wpInsertPopupMenuItems  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpPrintObject  wpQueryDefaultHelp  wpQueryNameClashOptions  wpQueryStyle  wpQueryTitle  wpRestoreState  wpSaveState  wpSetTitle  wpSetup  wpUnInitData  wpViewObject wpSetup override by WPShadow The following table shows the keyname-value pairs added by the WPShadow class. ┌───────────────┬───────────────┬──────────────────────────────┐ │KEYNAME │VALUE │DESCRIPTION │ ├───────────────┼───────────────┼──────────────────────────────┤ │SHADOWID │ or file │This specifies the object for │ │ │name │which this object is a shadow.│ │ │ │The value for this keyname is │ │ │ │an object's id (OBJECTID) or a│ │ │ │fully qualified pathname of a │ │ │ │directory, program file, or │ │ │ │data file. │ └───────────────┴───────────────┴──────────────────────────────┘ Class methods WPObject class methods There are currently no class methods defined for the WPShadow Workplace class object. The following list shows all the class methods overridden by the WPShadow class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.41. WPSharedDir ═══ Class definition file: wpshdir.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPSharedDir Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the shared directory object class. An instances of this class can be created as a Workplace object. Instances of this class are created for every shared directory in a WPServer folder that is accessible to the user. Instance methods The following list shows all the WPSharedDir methods.  wpAddResourcePage WPFileSystem instance methods The following list shows all the methods overridden by the WPSharedDir class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFile1Page  wpAddFile2Page  wpAddFile3Page WPFolder instance methods The following list shows all the methods overridden by the WPSharedDir class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddFolderIncludePage  wpPopulate WPObject instance methods The following list shows all the methods overridden by the WPSharedDir class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectGeneralPage  wpAddSettingsPages  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpRestoreState  wpSaveState Class methods There are currently no class methods defined for the WPSharedDir Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPSharedDir class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.42. WPShredder ═══ Class definition file: wpshred.idl Class hierarchy SOMObject WPObject WPAbstract WPShredder Description This is the shredder device object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "shredder" and resides on the desktop. Instance methods There are currently no methods defined for the WPShadow Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPShredder class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpDragOver  wpDrop  wpFilterPopupMenu Class methods There are currently no class methods defined for the WPShredder Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPShredder class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.43. WPSound ═══ Class definition file: wpsound.idl Class hierarchy SOMObject WPObject WPAbstract WPSound Description This is the sound object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system. It has the title "Sound" and resides in the "System Setup" folder. Instance methods The following list shows all the WPSound methods:  wpAddSoundWarningBeepPage WPObject instance methods The following list shows all the methods overridden by the WPSound class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu Class methods There are currently no class methods defined for the WPSound Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPSound class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.44. WPSpecialNeeds ═══ Class definition file: wpspneed.idl Class hierarchy SOMObject WPObject WPAbstract WPSpecialNeeds Description This is the special needs object class. An instance of this class can be created as a Workplace object. An instance of this class is created initially by the system when the keyboard special needs mode is activated via the keyboard object settings. It has the title "Special Needs" and resides on the desktop. Instance methods There are currently no methods defined for the WPSpecialNeeds Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPSpecialNeeds class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpFilterPopupMenu Class methods There are currently no class methods defined for the WPSpecialNeeds Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPSpecialNeeds class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryTitle ═══ 2.45. WPSpool ═══ Class definition file: wpspool.idl Class hierarchy SOMObject WPObject WPAbstract WPSpool Description This is the spooler object class. An instance of this class is created initially by the system. It has the title "Spooler" and resides in the "System Setup" folder.  wpAddSetPathPage  wpAddSetPriorityPage Instance methods There are currently no class methods defined for the WPSpool Workplace class object. WPObject instance methods The following list shows all the methods overridden by the WPSpool class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddSettingsPages  wpCopyObject  wpDragOver  wpDrop  wpFilterPopupMenu  wpInitData  wpMenuItemHelpSelected  wpMenuItemSelected  wpModifyPopupMenu  wpOpen  wpQueryIcon  wpQueryTitle  wpRestoreState  wpSaveState  wpUnInitData Class methods There are currently no class methods defined for the WPSpool Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPSpool class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIcon  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.46. WPStartup ═══ Class definition file: wpstart.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPStartup Description This is the startup folder object class. Any object in the startup folder will be automatically opened every time the system is restarted. Any object in the system that is open at shutdown time will be automatically reopened when the system is restarted. The startup folder is used to automatically open (start) objects that are not necessarily open (running) when the system is shut down. This usually includes things such as a batch file that initializes the network and then terminates. An instance of this class can be created as a Workplace object and is created initially by the system. It has the title "Startup" and resides in the "OS/2 System" folder. Instance methods There are currently no methods defined for the WPStartup Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPStartup class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpFree  wpRestoreState  wpSetupOnce Class methods There are currently no class methods defined for the WPStartup Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPStartup class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.47. WPSystem ═══ Class definition file: wpsystem.idl Class hierarchy SOMObject WPObject WPAbstract WPSystem Description This is the system object class. An instance of this class can be created as a Workplace object and is created initially by the system. It has the title "System" and resides in the "System Setup" folder. Instance methods The following list shows all the WPSystem class methods:  wpAddDMQSDisplayTypePage  wpAddSysFdrSelfClosePage  wpAddSysFdrDefViewPage  wpAddSystemConfirmationPage  wpAddSystemInputPage  wpAddSystemLogoPage  wpAddSystemPrintScreenPage  wpAddSystemScreenPage  wpAddSystemWindowPage  wpAddTitleConfirmationPage WPObject instance methods The following list shows all the methods overridden by the WPSystem class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectWindowPage  wpAddSettingsPages  wpFilterPopupMenu  wpRestoreState  wpSaveState Class methods There are currently no class methods defined for the WPSystem Workplace class object. WPAbstract class methods. The following list shows all the class methods overridden by the WPSystem class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQuerySetting  wpclsSetSetting WPObject class methods. The following list shows all the class methods overridden by the WPSystem class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle wpclsSetSettings override by wpSystem The defaults can be specified on a wpclsSetSetting invocation to request that the setting be set to its default value. wpclsQuerySetting, however, never returns an xxxx_DEFAULT value. ┌───────────────────────────┬───────────────────────┬────────────────────┐ │Setting │Value │Description │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │Animation │ANIMATION_ON │Enables animation │ │ │ │when a window is │ │ │ │created or │ │ │ │maximized. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │ANIMATION_OFF │Disables animation │ │ │ │when a window is │ │ │ │created or │ │ │ │maximized. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │ANIMATION_DEFAULT │Sets the default │ │ │ │window animation │ │ │ │setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ConfirmCopyMoveCreateShadow│CONFIRM_ON │Displays a │ │ │ │confirmation when a │ │ │ │copy, move, or │ │ │ │create shadow │ │ │ │operation occurs. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_OFF │Does not display a │ │ │ │confirmation when a │ │ │ │copy, move, or │ │ │ │create shadow │ │ │ │operation occurs. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_DEFAULT │Sets the default │ │ │ │confirmation display│ │ │ │setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ConfirmFolderDelete │CONFIRM_ON │Displays a │ │ │ │confirmation when a │ │ │ │folder is deleted. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_OFF │Does not display a │ │ │ │confirmation when a │ │ │ │folder is deleted. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_DEFAULT │Sets the default │ │ │ │confirmation display│ │ │ │setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ConfirmObjectDelete │CONFIRM_ON │Displays a │ │ │ │confirmation when an│ │ │ │object is deleted. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_OFF │Does not display a │ │ │ │confirmation when an│ │ │ │object is deleted. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_DEFAULT │Sets the default │ │ │ │confirmation display│ │ │ │setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ConfirmRenameFileExtension │CONFIRM_ON │Displays a │ │ │ │confirmation when a │ │ │ │file or extension is│ │ │ │renamed. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_OFF │Does not display a │ │ │ │confirmation when a │ │ │ │file or extension is│ │ │ │renamed. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CONFIRM_DEFAULT │Sets the default │ │ │ │confirmation display│ │ │ │setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │CurrentView │CCVIEW_ON │Turns concurrent │ │ │ │view mode on. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CCVIEW_OFF │Turns concurrent │ │ │ │view mode off. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │CCVIEW_DEFAULT │Sets the concurrent │ │ │ │view mode to the │ │ │ │default. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │DisplayProgressIndicator │DISPLAY_ON │Displays a progress │ │ │ │indicator. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │DISPLAY_OFF │Does not display │ │ │ │progress indicator. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │DISPLAY_DEFAULT │Sets the default │ │ │ │progress indicator │ │ │ │display setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │LogoDisplayTime │LOGO_INDEFINITE │Displays the logo │ │ │ │indefinitely. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │LOGO_NONE │Does not display the│ │ │ │logo. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │time │Displays the logo │ │ │ │for a given period │ │ │ │of time. This value │ │ │ │must be in the range│ │ │ │0 to 32767 │ │ │ │milliseconds. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │LOGO_DEFAULT │Sets the default │ │ │ │logo display time. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │MinButtonAppearance │BUTTON_HIDE │Sets views of this │ │ │ │object to have a │ │ │ │hide button as │ │ │ │opposed to a │ │ │ │minimize button. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │BUTTON_MINIMIZE │Sets views of this │ │ │ │object to have a │ │ │ │minimize button as │ │ │ │opposed to a hide │ │ │ │button. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │BUTTON_DEFAULT │Sets the default │ │ │ │minimize button │ │ │ │appearance setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │MinButtonBehavior │MINWIN_HIDE │Hides the view of an│ │ │ │object when its │ │ │ │minimize button is │ │ │ │selected. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │MINWIN_VIEWER │Minimizes the view │ │ │ │of an object to the │ │ │ │minimized window │ │ │ │viewer when its │ │ │ │minimize button is │ │ │ │selected. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │MINWIN_DESKTOP │Minimizes the view │ │ │ │of an object to the │ │ │ │Desktop when its │ │ │ │minimize button is │ │ │ │selected. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │MINWIN_DEFAULT │Sets the default │ │ │ │minimize button │ │ │ │behavior setting. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │NameClash │NAMECLASH_PROMPT │Displays a dialog │ │ │ │when an object is │ │ │ │created, copied or │ │ │ │moved to a folder │ │ │ │which contains │ │ │ │another object with │ │ │ │the same name. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │NAMECLASH_RENAME │Renames an object │ │ │ │when it is created, │ │ │ │copied or moved to a│ │ │ │folder which │ │ │ │contains another │ │ │ │object with the same│ │ │ │name. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │NAMECLASH_REPLACE │Replaces the │ │ │ │existing object with│ │ │ │the new object when │ │ │ │an object is │ │ │ │created, copied or │ │ │ │moved to a folder │ │ │ │which contains │ │ │ │another object with │ │ │ │the same name. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │NAMECLASH_DEFAULT │Sets the default │ │ │ │setting for handling│ │ │ │name clashes. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │PrintScreen │PRINTSCREEN_ON │Enables printing │ │ │ │when the print │ │ │ │screen key is │ │ │ │pressed. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │PRINTSCREEN_OFF │Disables printing │ │ │ │when the print │ │ │ │screen key is │ │ │ │pressed. │ ├───────────────────────────┼───────────────────────┼────────────────────┤ │ │PRINTSCREEN_DEFAULT │Sets the default │ │ │ │setting when the │ │ │ │print screen key is │ │ │ │pressed. │ └───────────────────────────┴───────────────────────┴────────────────────┘ ═══ 2.48. WPTemplates ═══ Class definition file: wptemps.idl Class hierarchy SOMObject WPObject WPFileSystem WPFolder WPTemplates Description This is the template folder object class. This class of folder always contains a template instance of every class of object that the user can create that supports the "Create another" action. A WPTemplates object is a normal folder in all respects other than the following:  It always contains a template for every class that supports them.  The last template for each object class cannot be deleted from the folder. An instance of this class can be created as a Workplace object and is created initially by the system. It has the title, "Templates" and resides on the desktop. A template instance is also created for each data type defined in an application's ASSOCTABLE resource. Instance methods There are currently no methods defined for the WPTemplates Workplace object class. WPFolder instance methods The following list shows all the methods overridden by the WPTemplates class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpPopulate WPObject instance methods The following list shows all the methods overridden by the WPTemplates class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpSetup Class methods There are currently no class methods defined for the WPTemplates Workplace class object. WPObject class methods. The following list shows all the class methods overridden by the WPTemplates class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 2.49. WPTransient ═══ Class definition file: wptrans.idl Class hierarchy SOMObject WPObject WPTransient Description This is the non-persistent object storage class. The WPTransient class is a storage class with no storage medium. This means that instances of object classes derived from WPTransient do not persist across reboots. This class is available for applications which need to utilize a large amount of workplace functionality (such as context menus and Settings notebooks) in their object class without having to be a file, directory, or a record in the INI file. An instance of this class can be created as a Workplace object. No instances of this class are initially created by the system. Instance methods There are currently no methods defined for the WPTransient Workplace object class. WPObject instance methods The following list shows all the methods overridden by the WPTransient class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpCopyObject  wpQueryHandle  wpSaveDeferred Class methods There are currently no class methods defined for the WPTransient Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPTransient class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryStyle  wpclsQueryTitle ═══ 2.50. WPWinConfig ═══ Class definition file: wincfg.idl Class hierarchy SOMObject WPObject WPAbstract WPWinConfig Description This class is specific to version 3, or higher, of the OS/2 operating system. This is the WIN-OS/2* configuration object class. This object stores and allows the user to modify the default settings for WIN-OS/2 applications. It initially resides in the system setup folder. An instance of this class can be created as a Workplace object. Instance methods The following list shows all the WPWinConfig methods.  wpAddDDEPage  wpAddSessionPage  wpAddSession31Page WPObject instance methods The following list shows all the methods overridden by the WPWinConfig class. These methods are overridden in order to modify the behavior defined by an ancestor class.  wpAddObjectGeneralPage  wpAddSettingsPages  wpFilterPopupMenu Class methods There are currently no class methods defined for the WPWinConfig Workplace class object. WPObject class methods The following list shows all the class methods overridden by the WPWinConfig class. These methods are overridden to modify the behavior defined by an ancestor class.  wpclsQueryDefaultHelp  wpclsQueryDefaultView  wpclsQueryIconData  wpclsQueryStyle  wpclsQueryTitle ═══ 3. Workplace Class Methods ═══ This chapter contains an alphabetic listing of the Workplace class methods. Class methods act on class data common to all instances of the class. Metaclasses define all the class methods for a class. Metaclasses are, therefore, the mechanisms for defining class properties as opposed to instance properties. Workplace class methods are prefixed by wpcls. See the Workplace Shell Programming Guide for guidance information on this subject. ═══ 3.1. wpclsCreateDefaultTemplates ═══ ═══ wpclsCreateDefaultTemplates - Syntax ═══ This method is called to allow the specified class to create default template instances of its class. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ WPFolder *Folder; /* Pointer to the folder in which to create the templates. */ BOOL rc; /* Flag indicating whether the class creates the templates. */ rc = _wpclsCreateDefaultTemplates(somSelf, Folder); ═══ wpclsCreateDefaultTemplates Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsCreateDefaultTemplates Parameter - Folder ═══ Folder (WPFolder *) - input Pointer to the folder in which to create the templates. Points to an object of class WPFolder. ═══ wpclsCreateDefaultTemplates Return Value - rc ═══ rc (BOOL) - returns Flag indicating whether the class creates the templates. Possible values are described in the following list: TRUE The class creates its own templates. FALSE The Templates folder creates the templates for the class. ═══ wpclsCreateDefaultTemplates - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. Folder (WPFolder *) - input Pointer to the folder in which to create the templates. Points to an object of class WPFolder. rc (BOOL) - returns Flag indicating whether the class creates the templates. Possible values are described in the following list: TRUE The class creates its own templates. FALSE The Templates folder creates the templates for the class. ═══ wpclsCreateDefaultTemplates - Usage ═══ This method is generally called only by the system when the class is registered. A class is registered by a call to the WinRegisterObjectClass function. When the system calls this method, "Folder" is a pointer to the Templates folder. ═══ wpclsCreateDefaultTemplates - How to Override ═══ This method should be overridden by classes that need to create default template instances of their class. ═══ wpclsCreateDefaultTemplates - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Glossary ═══ 3.2. wpclsDecUsage ═══ ═══ wpclsDecUsage - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method is called to decrement the class usage count. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ wpclsDecUsage(somSelf); ═══ wpclsDecUsage Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsDecUsage - Return Value ═══ There is no return value for this method. ═══ wpclsDecUsage - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. There is no return value for this method. ═══ wpclsDecUsage - Remarks ═══ The class usage count is used by the system to dynamically load and unload DLLs containing classes. ═══ wpclsDecUsage - How to Override ═══ This method is generally not overridden. ═══ wpclsDecUsage - Related Methods ═══  wpclsIncUsage ═══ wpclsDecUsage - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Related Methods Glossary ═══ 3.3. wpclsFileSysExists ═══ ═══ wpclsFileSysExists - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method returns the object if the specified file or directory already exists in the given folder. #define INCL_WINWORKPLACE #include M_WPFileSystem *somSelf; /* Pointer to the WPFileSystem class object. */ SOMAny *Folder; /* Pointer to folder in which to search for file or directory. */ PSZ pszFilename; /* Name of file or directory on which search is to be performed. */ ULONG attrFile; /* Flag specifying whether name to be searched is a file or directory. */ WPObject Object *; /* Pointer to the object found. */ Object * = _wpclsFileSysExists(somSelf, Folder, pszFilename, attrFile); ═══ wpclsFileSysExists Parameter - somSelf ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. ═══ wpclsFileSysExists Parameter - Folder ═══ Folder (SOMAny *) - input Pointer to folder in which to search for file or directory. ═══ wpclsFileSysExists Parameter - pszFilename ═══ pszFilename (PSZ) - input Name of file or directory on which search is to be performed. ═══ wpclsFileSysExists Parameter - attrFile ═══ attrFile (ULONG) - input Flag specifying whether name to be searched is a file or directory. ═══ wpclsFileSysExists Return Value - Object * ═══ Object * (WPObject) - returns Pointer to the object found. A return value of NULL indicates that the object was not found. ═══ wpclsFileSysExists - Parameters ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. Folder (SOMAny *) - input Pointer to folder in which to search for file or directory. pszFilename (PSZ) - input Name of file or directory on which search is to be performed. attrFile (ULONG) - input Flag specifying whether name to be searched is a file or directory. Object * (WPObject) - returns Pointer to the object found. A return value of NULL indicates that the object was not found. ═══ wpclsFileSysExists - Usage ═══ This method can be called at any time. ═══ wpclsFileSysExists - How to Override ═══ This method is generally not overridden. ═══ wpclsFileSysExists - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Glossary ═══ 3.4. wpclsFindObjectEnd ═══ ═══ wpclsFindObjectEnd - Syntax ═══ This method is called to end the find operation started by a call to the wpclsFindObjectFirst method. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HFIND hfind; /* Handle associated with a previous wpclsFindObjectFirst or wpclsFindObjectNext method call. */ BOOL rc; /* Success indicator. */ rc = _wpclsFindObjectEnd(somSelf, hfind); ═══ wpclsFindObjectEnd Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsFindObjectEnd Parameter - hfind ═══ hfind (HFIND) - input Handle associated with a previous wpclsFindObjectFirst or wpclsFindObjectNext method call. ═══ wpclsFindObjectEnd Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsFindObjectEnd - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hfind (HFIND) - input Handle associated with a previous wpclsFindObjectFirst or wpclsFindObjectNext method call. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsFindObjectEnd - Usage ═══ This method should be called to terminate a find operation that was started by a previous call to the wpclsFindObjectFirst method. ═══ wpclsFindObjectEnd - How to Override ═══ This method is generally not overridden. ═══ wpclsFindObjectEnd - Related Methods ═══  wpclsFindObjectEnd  wpclsFindObjectFirst  wpclsFindObjectNext ═══ wpclsFindObjectEnd - Example Code ═══ This example finds all occurrences of an object type in a folder. VOID clsFindEverybody(SOMAny *self) { BOOL rc; /* Return from methods */ HFIND hFind = 0; /* Handle for repeated finds */ CLASS Class[2]; /* List of classes to look for */ OBJECT Object[10]; /* Objects returned from search */ ULONG ulCount = 10; /* Count of objects to find / or found */ WPFolder *folder = 0; /* Pointer to folder for search */ ULONG errorid = 0; /* Error returned from previous search */ CHAR sz[CCHMAXPATH]; /* Title string to look for */ PSZ title = sz; Class[0] = _WPFolder; Class[1] = NULL; /* Get the pointer to the desktop (since that is where we are looking) */ folder = _wpclsQueryFolder( _WPFolder, "", TRUE ); _wpclsSetError( _WPObject, 0 ); /* Reset the error indicators */ rc = 0; /* Attempt to find the first 10 objects matching our criteria */ ulCount = 10; rc =_wpclsFindObjectFirst(_WPObject, /* Class self pointer */ Class, /* Pointer to array of class objects */ &hFind, /* Handle for wpclsFindObjectNext */ NULL, /* Find EVERYTHING */ folder, /* Pointer to folder of interest */ TRUE, /* Search all folders in tree */ NULL, /* No extended criteria */ Object, /* Array of object pointers */ &ulCount ); /* Number requested and number found */ errorid = _wpclsQueryError( _WPObject); /* Get errorid (may still be OK) */ if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf(" _wpclsFindObjectFirst failed, errorid=%u\n", errorid ); return; } /* endif */ do { _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Look for next 10 objects */ rc =_wpclsFindObjectNext(_WPObject, /* Self */ hFind, /* Handle from previous Find */ Object, /* Objects found */ &ulCount ); /* Number to look for. On return, number found */ errorid = _wpclsQueryError( _WPObject ); if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf("_wpclsFindObjectNext failed, errorid=%u\n", errorid); return; } /* endif */ } while ( errorid == WPERR_BUFFER_OVERFLOW ); /* enddo */ _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Indicate find complete */ rc =_wpclsFindObjectEnd( _WPObject, hFind ); if (!rc) { errorid = _wpclsQueryError( _WPObject ); somPrintf( "_wpclsFindObjectEnd failed, errorid=%u\n", errorid ); return; } return; } ═══ wpclsFindObjectEnd - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Example Code Related Methods Glossary ═══ 3.5. wpclsFindObjectFirst ═══ ═══ wpclsFindObjectFirst - Syntax ═══ This method is called to find workplace objects. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PCLASS pClasslist; /* Pointer to an array of class objects. */ PHFIND phFind; /* Address of the handle returned by this method. */ PSZ pszTitle; /* Pointer to the title specification for objects to be searched. */ WPFolder *Folder; /* Pointer to the folder in which to find objects. */ BOOL fSubfolders; /* Scope indicator. */ PVOID pExtendedCriteria; /* Pointer to extended search criteria. */ POBJECT pBuffer; /* Pointer to a buffer that contains an array of object pointers. */ PULONG pCount; /* Address of the number of matching entries requested in pBuffer. */ BOOL rc; /* Success indicator. */ rc = _wpclsFindObjectFirst(somSelf, pClasslist, phFind, pszTitle, Folder, fSubfolders, pExtendedCriteria, pBuffer, pCount); ═══ wpclsFindObjectFirst Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsFindObjectFirst Parameter - pClasslist ═══ pClasslist (PCLASS) - output Pointer to an array of class objects. The final element of the array must be NULL. If this parameter is specified, only objects that are descended from the specified object classes are returned. ═══ wpclsFindObjectFirst Parameter - phFind ═══ phFind (PHFIND) - output Address of the handle returned by this method. This handle is used with subsequent calls to wpclsFindObjectNext and wpclsFindObjectEnd. ═══ wpclsFindObjectFirst Parameter - pszTitle ═══ pszTitle (PSZ) - input Pointer to the title specification for objects to be searched. This title may include the wildcard characters * and ?. If this parameter is specified, only objects whose titles match the title specification are returned. ═══ wpclsFindObjectFirst Parameter - Folder ═══ Folder (WPFolder *) - input Pointer to the folder in which to find objects. This pointer can be determined by issuing a call to the wpclsQueryFolder method. ═══ wpclsFindObjectFirst Parameter - fSubfolders ═══ fSubfolders (BOOL) - input Scope indicator. TRUE Search Folder and all folders in its tree. FALSE Search only the folder specified by Folder. ═══ wpclsFindObjectFirst Parameter - pExtendedCriteria ═══ pExtendedCriteria (PVOID) - input Pointer to the extended search criteria. Points to a buffer that contains the class-specific extended search criteria. If this parameter is specified, only the objects that match the specified extended search criteria are returned. If this parameter is NULL, objects of all classes are returned. ═══ wpclsFindObjectFirst Parameter - pBuffer ═══ pBuffer (POBJECT) - output Pointer to a buffer that contains an array of object pointers. The size of this buffer must be large enough to hold the number of requested entries specified by pCount. ═══ wpclsFindObjectFirst Parameter - pCount ═══ pCount (PULONG) - in/out Address of the number of matching entries requested in pBuffer. On return, this field contains the number of entries placed into pBuffer. ═══ wpclsFindObjectFirst Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. If wpclsFindObjectFirst returns FALSE, the wpQueryError method can be called to retrieve the error code. Error codes include the following: WPERR_BUFFER_OVERFLOW The pBuffer was not large enough to fit all objects matching the specified criteria. The wpclsFindObjectNext method should be called to retrieve the rest of the objects matching the specified criteria. WPERR_OBJECT_NOT_FOUND No objects matching the specified criteria were found. ═══ wpclsFindObjectFirst - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pClasslist (PCLASS) - output Pointer to an array of class objects. The final element of the array must be NULL. If this parameter is specified, only objects that are descended from the specified object classes are returned. phFind (PHFIND) - output Address of the handle returned by this method. This handle is used with subsequent calls to wpclsFindObjectNext and wpclsFindObjectEnd. pszTitle (PSZ) - input Pointer to the title specification for objects to be searched. This title may include the wildcard characters * and ?. If this parameter is specified, only objects whose titles match the title specification are returned. Folder (WPFolder *) - input Pointer to the folder in which to find objects. This pointer can be determined by issuing a call to the wpclsQueryFolder method. fSubfolders (BOOL) - input Scope indicator. TRUE Search Folder and all folders in its tree. FALSE Search only the folder specified by Folder. pExtendedCriteria (PVOID) - input Pointer to the extended search criteria. Points to a buffer that contains the class-specific extended search criteria. If this parameter is specified, only the objects that match the specified extended search criteria are returned. If this parameter is NULL, objects of all classes are returned. pBuffer (POBJECT) - output Pointer to a buffer that contains an array of object pointers. The size of this buffer must be large enough to hold the number of requested entries specified by pCount. pCount (PULONG) - in/out Address of the number of matching entries requested in pBuffer. On return, this field contains the number of entries placed into pBuffer. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. If wpclsFindObjectFirst returns FALSE, the wpQueryError method can be called to retrieve the error code. Error codes include the following: WPERR_BUFFER_OVERFLOW The pBuffer was not large enough to fit all objects matching the specified criteria. The wpclsFindObjectNext method should be called to retrieve the rest of the objects matching the specified criteria. WPERR_OBJECT_NOT_FOUND No objects matching the specified criteria were found. ═══ wpclsFindObjectFirst - Remarks ═══ This method returns object pointers (up to the number requested in pCount) for as many objects that match the specifications and that fit in pBuffer. On output, pCount contains the actual number of object pointers returned. The returned objects are all locked. The wpUnlockObject method for each object must be called when finished using the object. The wpclsFindObjectNext method uses the find object handle returned by wpclsFindObjectFirst to continue the search started by the wpclsFindObjectFirst request. The wpclsFindObjectEnd method should be called to terminate the find operation. ═══ wpclsFindObjectFirst - Usage ═══ This method can be called at any time in order to find objects. ═══ wpclsFindObjectFirst - How to Override ═══ This method is generally not overridden. ═══ wpclsFindObjectFirst - Related Methods ═══  wpclsFindObjectEnd  wpclsFindObjectNext ═══ wpclsFindObjectFirst - Example Code ═══ This example code finds all folders contained in the Desktop subtree. VOID clsFindEverybody(SOMAny *self) { BOOL rc; /* Return from methods */ HFIND hFind = 0; /* Handle for repeated finds */ CLASS Class[2]; /* List of classes to look for */ OBJECT Object[10]; /* Objects returned from search */ ULONG ulCount = 10; /* Count of objects to find or found */ WPFolder *folder = 0; /* Pointer to folder for search */ ULONG errorid = 0; /* Error returned from previous search */ CHAR sz[CCHMAXPATH]; /* Title string to look for */ PSZ title = sz; Class[0] = _WPFolder; Class[1] = NULL; /* Get the pointer to the Desktop */ folder = _wpclsQueryFolder(_WPFolder, "", TRUE); /* Reset the error indicators */ _wpclsSetError(_WPObject, 0); rc = 0; /* Attempt to find the first 10 objects matching the criteria */ ulCount = 10; rc = _wpclsFindObjectFirst(_WPObject, /* Class self pointer */ Class, /* Pointer to array of class objects */ &hFind, /* Handle for wpclsFindObjectNext */ NULL, /* Find EVERYTHING */ folder, /* Pointer to folder of interest */ TRUE, /* Search all folders in tree */ NULL, /* No extended criteria */ Object, /* Array of object pointers */ &ulCount); /* Number requested and number found */ /* Get the errorid */ errorid = _wpclsQueryError(_WPObject); if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /* Process the objects found here */ } else { somPrintf(" _wpclsFindObjectFirst failed, errorid=%u\n", errorid); return; } /* endif */ do { /* Reset error indicators */ _wpclsSetError(_WPObject, 0); rc = 0; /* Look for the next 10 objects */ ulCount = 10; rc = _wpclsFindObjectNext(_WPObject, /* Self */ hFind, /* Handle from previous Find */ Object, /* Objects found */ &ulCount ); /* Number to look for. */ /* On return, number found */ errorid = _wpclsQueryError(_WPObject); if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /* Process all objects found here */ } else { somPrintf("_wpclsFindObjectNext failed, errorid=%u\n", errorid); return; } /* endif */ } while (errorid == WPERR_BUFFER_OVERFLOW); /* Reset the error indicators */ _wpclsSetError(_WPObject, 0); rc = 0; /* Indicate find complete */ rc =_wpclsFindObjectEnd(_WPObject, hFind); if (!rc) { errorid = _wpclsQueryError(_WPObject); somPrintf("_wpclsFindObjectEnd failed, errorid=%u\n", errorid); return; } return; } ═══ wpclsFindObjectFirst - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.6. wpclsFindObjectNext ═══ ═══ wpclsFindObjectNext - Syntax ═══ This method is called to find the next set of matching objects. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HFIND hfind; /* Handle associated with a previous wpclsFindObjectFirst or wpclsFindObjectNext method call. */ POBJECT pBuffer; /* Pointer to a buffer that contains an array of object pointers. */ PULONG pCount; /* Address of the number of matching entries requested in pBuffer. */ BOOL rc; /* Success indicator. */ rc = _wpclsFindObjectNext(somSelf, hfind, pBuffer, pCount); ═══ wpclsFindObjectNext Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsFindObjectNext Parameter - hfind ═══ hfind (HFIND) - input Handle associated with a previous wpclsFindObjectFirst or wpclsFindObjectNext method call. ═══ wpclsFindObjectNext Parameter - pBuffer ═══ pBuffer (POBJECT) - output Pointer to a buffer that contains an array of object pointers. The size of this buffer must be large enough to hold the number of requested entries specified by pulCount. ═══ wpclsFindObjectNext Parameter - pCount ═══ pCount (PULONG) - in/out Address of the number of matching entries requested in pBuffer. On return, this field contains the number of entries placed into pBuffer. ═══ wpclsFindObjectNext Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. FALSE can indicate: WPERR_OBJECT_NOT_FOUND WPERR_BUFFER_OVERFLOW ═══ wpclsFindObjectNext - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hfind (HFIND) - input Handle associated with a previous wpclsFindObjectFirst or wpclsFindObjectNext method call. pBuffer (POBJECT) - output Pointer to a buffer that contains an array of object pointers. The size of this buffer must be large enough to hold the number of requested entries specified by pulCount. pCount (PULONG) - in/out Address of the number of matching entries requested in pBuffer. On return, this field contains the number of entries placed into pBuffer. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. FALSE can indicate: WPERR_OBJECT_NOT_FOUND WPERR_BUFFER_OVERFLOW ═══ wpclsFindObjectNext - Remarks ═══ wpclsFindObjectNext returns object pointers (up to the number requested in pulCount) for as many objects that match the specifications and that fit in pBuffer. On output, pulCount contains the actual number of object pointers returned. wpclsFindObjectNext uses the find object handle associated with wpclsFindObjectFirst to continue the search started by the wpclsFindObjectFirst request. If wpclsFindObjectNext returns FALSE, the wpQueryError method can be called to retrieve the error code. Error codes include: WPERR_OBJECT_NOT_FOUND No objects matching the specified criteria were found. WPERR_BUFFER_OVERFLOW The pBuffer buffer was not large enough to fit all objects matching the specified criteria. The wpclsFindObjectNext method should be called to retrieve the rest of the objects matching the specified criteria. The wpclsFindObjectEnd method should be called to terminate the find operation. ═══ wpclsFindObjectNext - Usage ═══ This method can be called at any time in order to find the next set of matching objects. This method should be called only after a previous call to the wpclsFindObjectFirst method returned an error of WPERR_BUFFER_OVERFLOW. ═══ wpclsFindObjectNext - How to Override ═══ This method is generally not overridden. ═══ wpclsFindObjectNext - Related Methods ═══  wpclsFindObjectEnd  wpclsFindObjectFirst  wpclsFindObjectNext ═══ wpclsFindObjectNext - Example Code ═══ This example finds all occurrences of an object type in a folder. VOID clsFindEverybody(SOMAny *self) { BOOL rc; /* Return from methods */ HFIND hFind = 0; /* Handle for repeated finds */ CLASS Class[2]; /* List of classes to look for */ OBJECT Object[10]; /* Objects returned from search */ ULONG ulCount = 10; /* Count of objects to find / or found */ WPFolder *folder = 0; /* Pointer to folder for search */ ULONG errorid = 0; /* Error returned from previous search */ CHAR sz[CCHMAXPATH]; /* Title string to look for */ PSZ title = sz; Class[0] = _WPFolder; Class[1] = NULL; /* Get the pointer to the desktop (since that is where we are looking) */ folder = _wpclsQueryFolder( _WPFolder, "", TRUE ); _wpclsSetError( _WPObject, 0 ); /* Reset the error indicators */ rc = 0; /* Attempt to find the first 10 objects matching our criteria */ ulCount = 10; rc =_wpclsFindObjectFirst(_WPObject, /* Class self pointer */ Class, /* Pointer to array of class objects */ &hFind, /* Handle for wpclsFindObjectNext */ NULL, /* Find EVERYTHING */ folder, /* Pointer to folder of interest */ TRUE, /* Search all folders in tree */ NULL, /* No extended criteria */ Object, /* Array of object pointers */ &ulCount ); /* Number requested and number found */ errorid = _wpclsQueryError( _WPObject); /* Get errorid (may still be OK) */ if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf(" _wpclsFindObjectFirst failed, errorid=%u\n", errorid ); return; } /* endif */ do { _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Look for next 10 objects */ rc =_wpclsFindObjectNext(_WPObject, /* Self */ hFind, /* Handle from previous Find */ Object, /* Objects found */ &ulCount ); /* Number to look for. On return, number found */ errorid = _wpclsQueryError( _WPObject ); if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf("_wpclsFindObjectNext failed, errorid=%u\n", errorid); return; } /* endif */ } while ( errorid == WPERR_BUFFER_OVERFLOW ); /* enddo */ _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Indicate find complete */ rc =_wpclsFindObjectEnd( _WPObject, hFind ); if (!rc) { errorid = _wpclsQueryError( _WPObject ); somPrintf( "_wpclsFindObjectEnd failed, errorid=%u\n", errorid ); return; } return; } ═══ wpclsFindObjectNext - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.7. wpclsFindOneObject ═══ ═══ wpclsFindOneObject - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method is used by find pushbuttons to find an object matching a predefined set of properties. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HWND hwndOwner; /* Handle of the owner window for the dialogs. */ PSZ pszFindParams; /* Setup string which defines the properties of an object. */ WPObject *Object; /* Pointer to the found object. */ Object = _wpclsFindOneObject(somSelf, hwndOwner, pszFindParams); ═══ wpclsFindOneObject Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsFindOneObject Parameter - hwndOwner ═══ hwndOwner (HWND) - input Handle of the owner window for the dialogs. ═══ wpclsFindOneObject Parameter - pszFindParams ═══ pszFindParams (PSZ) - input Setup string which defines the properties of an object. ═══ wpclsFindOneObject Return Value - Object ═══ Object (WPObject *) - returns Pointer to the found object. ═══ wpclsFindOneObject - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hwndOwner (HWND) - input Handle of the owner window for the dialogs. pszFindParams (PSZ) - input Setup string which defines the properties of an object. Object (WPObject *) - returns Pointer to the found object. ═══ wpclsFindOneObject - Usage ═══ This method can be called at any time. ═══ wpclsFindOneObject - How to Override ═══ This method is generally not overridden. ═══ wpclsFindOneObject - Related Methods ═══  wpclsFindObjectEnd  wpclsFindObjectFirst  wpclsFindObjectNext ═══ wpclsFindOneObject - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Related Methods Glossary ═══ 3.8. wpclsIncUsage ═══ ═══ wpclsIncUsage - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method is called to increment the class usage count. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ wpclsIncUsage(somSelf); ═══ wpclsIncUsage Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsIncUsage - Return Value ═══ There is no return value for this method. ═══ wpclsIncUsage - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. There is no return value for this method. ═══ wpclsIncUsage - Remarks ═══ The class usage count is used by the system to dynamically load and unload DLLs containing classes. ═══ wpclsIncUsage - How to Override ═══ This method should not be overridden. ═══ wpclsIncUsage - Related Methods ═══  wpclsDecUsage ═══ wpclsIncUsage - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Related Methods Glossary ═══ 3.9. wpclsInitData ═══ ═══ wpclsInitData - Syntax ═══ This method is called to allow the class object to initialize its instance data. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ wpclsInitData(somSelf); ═══ wpclsInitData Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsInitData - Return Value ═══ There is no return value for this method. ═══ wpclsInitData - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. There is no return value for this method. ═══ wpclsInitData - Remarks ═══ This method is called immediately after the class object is first awakened. When the class object is made dormant, the wpclsUnInitData method is called to give the class object the opportunity to deallocate resources allocated during the processing of wpclsInitData. ═══ wpclsInitData - Usage ═══ This method is generally called only by the system when the class object is awakened. The class object is awakened when the first instance of this class is either awakened or newly created. It is made dormant again when the last instance of this class is made dormant. ═══ wpclsInitData - How to Override ═══ Any class that has metaclass instance variables should override this method so that those variables are all initially in a known state. It is essential to pass this method onto the parent class object before performing any override processing. ═══ wpclsInitData - Related Methods ═══  wpclsUnInitData ═══ wpclsInitData - Example Code ═══ This coding example uses wpclsInitData to initialize class data associated with MyDataBase. SOM_Scope void SOMLINK MyDataBaseM_wpclsInitData(M_MyDataBase *somSelf) { /* M_MyDataBaseData *somThis = M_MyDataBaseGetData(somSelf); */ M_MyDataBaseMethodDebug("M_MyDataBase","MyDataBaseM_wpclsInitData"); hModule = _clsQueryModuleHandle( somSelf ); _hIcon = WinLoadPointer ( HWND_DESKTOP, hModule, ID_WINDOW ); parent_wpclsInitData(somSelf); } ═══ wpclsInitData - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.10. wpclsInsertMultipleObjects ═══ ═══ wpclsInsertMultipleObjects - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method inserts multiple objects into a container at one time. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HWND hwndCnr; /* Handle to the container window in which objects are to be inserted. */ PPOINTL pptlIcon; /* Pointer to the initial icon position of the first icon inserted. */ PVOID *pObjectArray; /* Pointer to an array of object pointers. */ PVOID pRecordParent; /* Pointer to the parent record. */ ULONG NumRecords; /* Number of records in pObjectArray to be inserted. */ BOOL rc; /* Success indicator. */ rc = _wpclsInsertMultipleObjects(somSelf, hwndCnr, pptlIcon, pObjectArray, pRecordParent, NumRecords); ═══ wpclsInsertMultipleObjects Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsInsertMultipleObjects Parameter - hwndCnr ═══ hwndCnr (HWND) - input Handle to the container window in which objects are to be inserted. ═══ wpclsInsertMultipleObjects Parameter - pptlIcon ═══ pptlIcon (PPOINTL) - input Pointer to the initial icon position of the first icon inserted. ═══ wpclsInsertMultipleObjects Parameter - pObjectArray ═══ pObjectArray (PVOID *) - input Pointer to an array of object pointers. The objects in this array are to be inserted into the container. ═══ wpclsInsertMultipleObjects Parameter - pRecordParent ═══ pRecordParent (PVOID) - input Pointer to the parent record. This parameter should be set to NULL if the records being inserted will not have a parent or tree view is not supported. ═══ wpclsInsertMultipleObjects Parameter - NumRecords ═══ NumRecords (ULONG) - input Number of records in pObjectArray to be inserted. This parameter must be greater than 0. ═══ wpclsInsertMultipleObjects Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Errors occurred. ═══ wpclsInsertMultipleObjects - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hwndCnr (HWND) - input Handle to the container window in which objects are to be inserted. pptlIcon (PPOINTL) - input Pointer to the initial icon position of the first icon inserted. pObjectArray (PVOID *) - input Pointer to an array of object pointers. The objects in this array are to be inserted into the container. pRecordParent (PVOID) - input Pointer to the parent record. This parameter should be set to NULL if the records being inserted will not have a parent or tree view is not supported. NumRecords (ULONG) - input Number of records in pObjectArray to be inserted. This parameter must be greater than 0. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Errors occurred. ═══ wpclsInsertMultipleObjects - Remarks ═══ This method provides rapid insertion of multiple objects into a container at once. wpCnrInsertObject performs the same function as this method, but operates only on one object at a time. This method adds each object to the in-use list. ═══ wpclsInsertMultipleObjects - Usage ═══ This method can be called at any time to add multiple objects to a container. ═══ wpclsInsertMultipleObjects - How to Override ═══ This method is generally not overridden. ═══ wpclsInsertMultipleObjects - Related Methods ═══  wpCnrRemoveObject  wpCnrInsertObject  wpclsRemoveObjects ═══ wpclsInsertMultipleObjects - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.11. wpclsMakeAwake ═══ ═══ wpclsMakeAwake - Syntax ═══ This method is called to allow the specified class to awaken an object. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSZ pTitle; /* Pointer to the object title. */ ULONG ulStyle; /* Object style flags to set on the object. */ HPOINTER hptrIcon; /* Icon to set on the object. */ POBJDATA pObjData; /* Pointer to the object data. */ WPFolder *Folder; /* Pointer to a Folder object. */ ULONG ulUser; /* Base class-defined value. */ WPObject *Success; /* Success indicator. */ Success = _wpclsMakeAwake(somSelf, pTitle, ulStyle, hptrIcon, pObjData, Folder, ulUser); ═══ wpclsMakeAwake Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsMakeAwake Parameter - pTitle ═══ pTitle (PSZ) - input Pointer to the object title. A pointer to a string containing a title to set on the object. If this value is NULL, the class default value is used. ═══ wpclsMakeAwake Parameter - ulStyle ═══ ulStyle (ULONG) - input Object style flags to set on the object. If this value is NULL, the current or default value is used. Predefined object style bits are as follows: OBJSTYLE_CUSTOMICON Destroy the icon when the object goes to sleep. OBJSTYLE_NOCOPY Do not allow copy on the object. OBJSTYLE_NODELETE Do not allow delete on the object. OBJSTYLE_NODDRAG Do not allow drag of this object. OBJSTYLE_NODDROPON Do not allow dropping on this object. OBJSTYLE_NOLINK Do not allow linking on the object. OBJSTYLE_NOMOVE Do not allow moving on the object. OBJSTYLE_NOPRINT Do not allow printting of this object. OBJSTYLE_NORENAME Do not allow renaming of the object. OBJSTYLE_NOTVISIBLE Make this object hidden. OBJSTYLE_NODSETTINGS Do not allow setting of this object. OBJSTYLE_TEMPLATE This object is a template. ═══ wpclsMakeAwake Parameter - hptrIcon ═══ hptrIcon (HPOINTER) - input Icon to set on the object. If this value is NULL, the class default value is used. ═══ wpclsMakeAwake Parameter - pObjData ═══ pObjData (POBJDATA) - input Pointer to the object data. If this value is NULL, the class default value is used. ═══ wpclsMakeAwake Parameter - Folder ═══ Folder (WPFolder *) - input Pointer to a Folder object. A pointer to a Folder object that contains the new object. This pointer can be determined by issuing a call to the wpclsQueryFolder method. ═══ wpclsMakeAwake Parameter - ulUser ═══ ulUser (ULONG) - input Base class-defined value. This value is defined by the user and used by the base storage class. ═══ wpclsMakeAwake Return Value - Success ═══ Success (WPObject *) - returns Success indicator. NULL Error occurred Other Pointer to the awakened object. ═══ wpclsMakeAwake - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pTitle (PSZ) - input Pointer to the object title. A pointer to a string containing a title to set on the object. If this value is NULL, the class default value is used. ulStyle (ULONG) - input Object style flags to set on the object. If this value is NULL, the current or default value is used. Predefined object style bits are as follows: OBJSTYLE_CUSTOMICON Destroy the icon when the object goes to sleep. OBJSTYLE_NOCOPY Do not allow copy on the object. OBJSTYLE_NODELETE Do not allow delete on the object. OBJSTYLE_NODDRAG Do not allow drag of this object. OBJSTYLE_NODDROPON Do not allow dropping on this object. OBJSTYLE_NOLINK Do not allow linking on the object. OBJSTYLE_NOMOVE Do not allow moving on the object. OBJSTYLE_NOPRINT Do not allow printting of this object. OBJSTYLE_NORENAME Do not allow renaming of the object. OBJSTYLE_NOTVISIBLE Make this object hidden. OBJSTYLE_NODSETTINGS Do not allow setting of this object. OBJSTYLE_TEMPLATE This object is a template. hptrIcon (HPOINTER) - input Icon to set on the object. If this value is NULL, the class default value is used. pObjData (POBJDATA) - input Pointer to the object data. If this value is NULL, the class default value is used. Folder (WPFolder *) - input Pointer to a Folder object. A pointer to a Folder object that contains the new object. This pointer can be determined by issuing a call to the wpclsQueryFolder method. ulUser (ULONG) - input Base class-defined value. This value is defined by the user and used by the base storage class. Success (WPObject *) - returns Success indicator. NULL Error occurred Other Pointer to the awakened object. ═══ wpclsMakeAwake - Remarks ═══ An object is made awake when it is created in an open folder or when a folder containing the object is opened. An object awakened by the wpclsMakeAwake class method is automatically locked. The wpUnlockObject method can be called to allow the object to return to its dormant state. ═══ wpclsMakeAwake - Usage ═══ This method is generally called only by base storage classes in order to awaken an object from the dormant state. ═══ wpclsMakeAwake - How to Override ═══ This method is generally not overridden. ═══ wpclsMakeAwake - Related Methods ═══  wpclsNew  wpInitData  wpUnlockObject ═══ wpclsMakeAwake - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.12. wpclsNew ═══ ═══ wpclsNew - Syntax ═══ This method creates a new instance of a given class of object. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSZ pszTitle; /* Pointer to the object title. */ PSZ pszSetupEnv; /* Environment setup string. */ WPFolder *Folder; /* Pointer to the folder object in which to place the new object. */ BOOL fLock; /* Lock object flag. */ WPObject *wpclsNew; /* Pointer to the new object. */ wpclsNew = _wpclsNew(somSelf, pszTitle, pszSetupEnv, Folder, fLock); ═══ wpclsNew Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsNew Parameter - pszTitle ═══ pszTitle (PSZ) - input Pointer to the object title. A pointer to a null-terminated string which contains the initial title of the object as it is to appear when displayed on the user interface underneath an icon or on the title bar of an open object. ═══ wpclsNew Parameter - pszSetupEnv ═══ pszSetupEnv (PSZ) - input Environment setup string. A pointer to a zero-terminated string which contains the environment setup string of the new object. The pszSetupEnv string is extracted when the wpSetup method is called. Refer to wpSetup for the description of this field for the class of the object being created. ═══ wpclsNew Parameter - Folder ═══ Folder (WPFolder *) - input Pointer to the folder object in which to place the new object. This pointer can be determined by issuing a call to the wpclsQueryFolder method. ═══ wpclsNew Parameter - fLock ═══ fLock (BOOL) - input Lock object flag. Possible values are described in the following list: TRUE The new flag remains awake until the caller issues the wpUnlockObject method on it. FALSE The newly created object is made dormant whenever the object and the folder containing the object are closed. ═══ wpclsNew Return Value - wpclsNew ═══ wpclsNew (WPObject *) - returns Pointer to the new object. A return value of NULL indicates that an error occurred. ═══ wpclsNew - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pszTitle (PSZ) - input Pointer to the object title. A pointer to a null-terminated string which contains the initial title of the object as it is to appear when displayed on the user interface underneath an icon or on the title bar of an open object. pszSetupEnv (PSZ) - input Environment setup string. A pointer to a zero-terminated string which contains the environment setup string of the new object. The pszSetupEnv string is extracted when the wpSetup method is called. Refer to wpSetup for the description of this field for the class of the object being created. Folder (WPFolder *) - input Pointer to the folder object in which to place the new object. This pointer can be determined by issuing a call to the wpclsQueryFolder method. fLock (BOOL) - input Lock object flag. Possible values are described in the following list: TRUE The new flag remains awake until the caller issues the wpUnlockObject method on it. FALSE The newly created object is made dormant whenever the object and the folder containing the object are closed. wpclsNew (WPObject *) - returns Pointer to the new object. A return value of NULL indicates that an error occurred. ═══ wpclsNew - Remarks ═══ This method is a modified version of somNew that takes arguments. These arguments provide a way to create a new object with a defined state. ═══ wpclsNew - Usage ═══ This method can be called at any time to create a new workplace object. The created object is a persistent instance of the class specified by WPClass. ═══ wpclsNew - How to Override ═══ This method can be overridden only in a metaclass. ═══ wpclsNew - Related Methods ═══  wpFree  wpSetup  wpUnlockObject  wpclsQueryFolder ═══ wpclsNew - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.13. wpclsObjectFromHandle ═══ ═══ wpclsObjectFromHandle - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method extracts the object pointer for an instance represented by the given handle. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HOBJECT hObject; /* Persistent object handle. */ WPObject *pObject; /* Pointer to the object instance. */ pObject = _wpclsObjectFromHandle(somSelf, hObject); ═══ wpclsObjectFromHandle Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsObjectFromHandle Parameter - hObject ═══ hObject (HOBJECT) - input Persistent object handle. ═══ wpclsObjectFromHandle Return Value - pObject ═══ pObject (WPObject *) - returns Pointer to the object instance. ═══ wpclsObjectFromHandle - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hObject (HOBJECT) - input Persistent object handle. pObject (WPObject *) - returns Pointer to the object instance. ═══ wpclsObjectFromHandle - Remarks ═══ Each base class must store the relationship between the object handles and the folders they reside in. Using HOBJECT for .INI files or files in which an application uses a rename/save/delete sequence is not supported. ═══ wpclsObjectFromHandle - Usage ═══ This method can be called at any time to find the object pointer from a given handle. ═══ wpclsObjectFromHandle - How to Override ═══ This method is generally not overridden. ═══ wpclsObjectFromHandle - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Glossary ═══ 3.14. wpclsQueryActiveDesktop ═══ ═══ wpclsQueryActiveDesktop - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method returns a pointer to the active WPDesktop object. #define INCL_WINWORKPLACE #include M_WPDesktop *somSelf; /* Pointer to the WPDesktop class object. */ WPDesktop *WPDesktop; /* Pointer to the active desktop object. */ WPDesktop = _wpclsQueryActiveDesktop(somSelf); ═══ wpclsQueryActiveDesktop Parameter - somSelf ═══ somSelf (M_WPDesktop *) - input Pointer to the WPDesktop class object. ═══ wpclsQueryActiveDesktop Return Value - WPDesktop ═══ WPDesktop (WPDesktop *) - returns Pointer to the active desktop object. ═══ wpclsQueryActiveDesktop - Parameters ═══ somSelf (M_WPDesktop *) - input Pointer to the WPDesktop class object. WPDesktop (WPDesktop *) - returns Pointer to the active desktop object. ═══ wpclsQueryActiveDesktop - Remarks ═══ Multiple desktop objects can be awake, but only one can be active at a time. ═══ wpclsQueryActiveDesktop - Usage ═══ This method can be called at any time. ═══ wpclsQueryActiveDesktop - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryActiveDesktop - Related Methods ═══  wpclsQueryActiveDesktopHWND ═══ wpclsQueryActiveDesktop - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.15. wpclsQueryActiveDesktopHWND ═══ ═══ wpclsQueryActiveDesktopHWND - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method returns the handle of the active WPDesktop object. #define INCL_WINWORKPLACE #include M_WPDesktop *somSelf; /* Pointer to the WPDesktop class object. */ HWND hwndDesktop; /* Handle of the active desktop object' frame window. */ hwndDesktop = _wpclsQueryActiveDesktopHWND( somSelf); ═══ wpclsQueryActiveDesktopHWND Parameter - somSelf ═══ somSelf (M_WPDesktop *) - input Pointer to the WPDesktop class object. ═══ wpclsQueryActiveDesktopHWND Return Value - hwndDesktop ═══ hwndDesktop (HWND) - returns Handle of the active desktop object' frame window. ═══ wpclsQueryActiveDesktopHWND - Parameters ═══ somSelf (M_WPDesktop *) - input Pointer to the WPDesktop class object. hwndDesktop (HWND) - returns Handle of the active desktop object' frame window. ═══ wpclsQueryActiveDesktopHWND - Usage ═══ This method can be called at any time. ═══ wpclsQueryActiveDesktopHWND - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryActiveDesktopHWND - Related Methods ═══  wpclsQueryActiveDesktop ═══ wpclsQueryActiveDesktopHWND - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Related Methods Glossary ═══ 3.16. wpclsQueryAwakeObject ═══ ═══ wpclsQueryAwakeObject - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method determines if the given object is already awake. #define INCL_WINWORKPLACE #include M_WPFileSystem *somSelf; /* Pointer to the WPFileSystem class object. */ PSZ pszInputPath; /* Fully-qualified input path. */ WPObject Object; /* The awake object. */ Object = _wpclsQueryAwakeObject(somSelf, pszInputPath); ═══ wpclsQueryAwakeObject Parameter - somSelf ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. ═══ wpclsQueryAwakeObject Parameter - pszInputPath ═══ pszInputPath (PSZ) - input Fully-qualified input path. Note: This parameter must be a valid path. The system does not call the file system to check whether the file exists. ═══ wpclsQueryAwakeObject Return Value - Object ═══ Object (WPObject) - returns The awake object. A return value of NULL indicates that the object is not already awake. ═══ wpclsQueryAwakeObject - Parameters ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. pszInputPath (PSZ) - input Fully-qualified input path. Note: This parameter must be a valid path. The system does not call the file system to check whether the file exists. Object (WPObject) - returns The awake object. A return value of NULL indicates that the object is not already awake. ═══ wpclsQueryAwakeObject - Remarks ═══ This methods requires that for an object to be awake, all path coomponents prior to the object are also awake. If any path component is not found awake, then the routine assumes that the object for that passed file cannot be awake either. ═══ wpclsQueryAwakeObject - Usage ═══ This method can be called at any time. ═══ wpclsQueryAwakeObject - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryAwakeObject - Related Methods ═══  wpclsMakeAwake ═══ wpclsQueryAwakeObject - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.17. wpclsQueryButtonAppearance ═══ ═══ wpclsQueryButtonAppearance - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method returns the system button appearance. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ ULONG ulButtonType; /* Flag indicating the system default button appearance. */ ulButtonType = _wpclsQueryButtonAppearance( somSelf); ═══ wpclsQueryButtonAppearance Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryButtonAppearance Return Value - ulButtonType ═══ ulButtonType (ULONG) - returns Flag indicating the system default button appearance. Possible values are described in the following list: HIDEBUTTON MINBUTTON ═══ wpclsQueryButtonAppearance - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ulButtonType (ULONG) - returns Flag indicating the system default button appearance. Possible values are described in the following list: HIDEBUTTON MINBUTTON ═══ wpclsQueryButtonAppearance - Usage ═══ This method can be called at any time to query the default button appearance. ═══ wpclsQueryButtonAppearance - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryButtonAppearance - Related Methods ═══  wpQueryButtonAppearance  wpSetButtonAppearance ═══ wpclsQueryButtonAppearance - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Related Methods Glossary ═══ 3.18. wpclsQueryDefaultHelp ═══ ═══ wpclsQueryDefaultHelp - Syntax ═══ This method is called to allow the class object to specify its default help panel for its instances. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PULONG HelpPanelId; /* Pointer to the help panel which provides help for this class. */ PSZ HelpLibrary; /* Pointer to the buffer in which to place the name of the Help library. */ ULONG rc; /* Success indicator. */ rc = _wpclsQueryDefaultHelp(somSelf, HelpPanelId, HelpLibrary); ═══ wpclsQueryDefaultHelp Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryDefaultHelp Parameter - HelpPanelId ═══ HelpPanelId (PULONG) - output Pointer to the help panel which provides help for this class. ═══ wpclsQueryDefaultHelp Parameter - HelpLibrary ═══ HelpLibrary (PSZ) - output Pointer to the buffer in which to place the name of the Help library. This buffer should be at least the length of CCHMAXPATH bytes. ═══ wpclsQueryDefaultHelp Return Value - rc ═══ rc (ULONG) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsQueryDefaultHelp - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. HelpPanelId (PULONG) - output Pointer to the help panel which provides help for this class. HelpLibrary (PSZ) - output Pointer to the buffer in which to place the name of the Help library. This buffer should be at least the length of CCHMAXPATH bytes. rc (ULONG) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsQueryDefaultHelp - Remarks ═══ This class method is called during the default processing of wpQueryDefaultHelp. ═══ wpclsQueryDefaultHelp - Usage ═══ This method can be called at any time in order to determine the default help panel for this object class. ═══ wpclsQueryDefaultHelp - How to Override ═══ The default WPObject class does not process this method other than returning FALSE. ═══ wpclsQueryDefaultHelp - Related Methods ═══  wpDisplayHelp  wpMenuItemHelpSelected  wpQueryDefaultHelp  wpSetDefaultHelp  wpclsQueryDefaultHelp ═══ wpclsQueryDefaultHelp - Example Code ═══ This example provides general help for the Spread (sheet) instance. SOM_Scope BOOL SOMLINK SpreadM_wpclsQueryDefaultHelp(M_Spread *somSelf, PULONG pHelpPanelId, PSZ pszHelpLibrary) { /* M_SpreadData *somThis = M_SpreadGetData(somSelf); */ M_SpreadMethodDebug("M_Spread","SpreadM_wpclsQueryDefaultHelp"); if (pHelpPanelId) /* set default help panel id */ *pHelpPanelId = PANEL_MAIN; if (pszHelpLibrary) /* copy help filename */ strcpy( pszHelpLibrary, "spdsheet.hlp"); return( TRUE ); /* Help exists */ } ═══ wpclsQueryDefaultHelp - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.19. wpclsQueryDefaultView ═══ ═══ wpclsQueryDefaultView - Syntax ═══ This method is called to allow the class object to specify the default open view for its instance. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ ULONG ulView; /* Default open view. */ ulView = wpclsQueryDefaultView(somSelf); ═══ wpclsQueryDefaultView Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryDefaultView Return Value - ulView ═══ ulView (ULONG) - returns Default open view. OPEN_CONTENTS Open contents view. OPEN_DEFAULT Open default view (same as double-click). OPEN_DETAILS Open details view. OPEN_HELP Display HelpPanel. OPEN_RUNNING Execute object. OPEN_SETTINGS Open Settings notebook. OPEN_TREE Open tree view. OPEN_UNKNOWN Unknown view. OPEN_USER Class-specific views have a greater value than this. ═══ wpclsQueryDefaultView - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ulView (ULONG) - returns Default open view. OPEN_CONTENTS Open contents view. OPEN_DEFAULT Open default view (same as double-click). OPEN_DETAILS Open details view. OPEN_HELP Display HelpPanel. OPEN_RUNNING Execute object. OPEN_SETTINGS Open Settings notebook. OPEN_TREE Open tree view. OPEN_UNKNOWN Unknown view. OPEN_USER Class-specific views have a greater value than this. ═══ wpclsQueryDefaultView - Usage ═══ This method can be called at any time in order to query the default open view for instances of this class. ═══ wpclsQueryDefaultView - How to Override ═══ All classes should override this method, so that new objects in their class will always have a sensible default view (device objects typically have a default view of OPEN_SETTINGS). The default view is used for both the conditional Open cascade menu and double-clicking on the object. ═══ wpclsQueryDefaultView - Related Methods ═══  wpQueryDefaultView  wpclsQueryDefaultView  wpSetDefaultView ═══ wpclsQueryDefaultView - Example Code ═══ This example demonstrates how to change the default open view of the instances of this class by overriding this method. SOM_Scope ULONG SOMLINK MyObjectM_wpclsQueryDefaultView(M_MyObject *somSelf) { /* M_MyObjectData *somThis = M_MyObjectGetData(somSelf); */ M_MyObjectMethodDebug("M_MyObject","MtObjectM_wpclsQueryDefaultView"); /* Make the default open view the ICON view */ return ( OPEN_ICON ); } ═══ wpclsQueryDefaultView - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Example Code Related Methods Glossary ═══ 3.20. wpclsQueryDetails ═══ ═══ wpclsQueryDetails - Syntax ═══ This method is called to allow the class object to specify the default details view items for its instances. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PCLASSDETAILS pReturn; /* Success indicator. */ pReturn = _wpclsQueryDetails(somSelf); ═══ wpclsQueryDetails Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryDetails Return Value - pReturn ═══ pReturn (PCLASSDETAILS) - returns Success indicator. NULL Error occurred Other Pointer to details information. ═══ wpclsQueryDetails - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pReturn (PCLASSDETAILS) - returns Success indicator. NULL Error occurred Other Pointer to details information. ═══ wpclsQueryDetails - Related Methods ═══  wpQueryDetailsData  wpclsQueryDetails  wpclsQueryDetailsInfo ═══ wpclsQueryDetails - Example Code ═══ This example shows an override of the method to invoke 'DisplayMethodInfo' in the WPSTUTOR sample program. SOM_Scope PCLASSDETAILS SOMLINK wpstutM_wpclsQueryDetails(M_WPSTutorial *somSelf) { /* M_WPSTutorialData *somThis = M_WPSTutorialGetData(somSelf); */ M_WPSTutorialMethodDebug("M_WPSTutorial","wpstutM_wpclsQueryDetails"); DisplayMethodInfo(IDS_WPCLSQUERYDETAILS); return (parent_wpclsQueryDetails(somSelf)); } ═══ wpclsQueryDetails - Topics ═══ Select an item: Syntax Parameters Returns Example Code Related Methods Glossary ═══ 3.21. wpclsQueryDetailsInfo ═══ ═══ wpclsQueryDetailsInfo - Syntax ═══ This method is called to allow the class object to specify its details to be used for its instances. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PCLASSFIELDINFO pClassFieldInfo; /* Pointer to details information. */ PULONG pSize; /* Total number of bytes of details data. */ ULONG ulReturn; /* Sum of the number of detail columns for the object. */ ulReturn = _wpclsQueryDetailsInfo(somSelf, pClassFieldInfo, pSize); ═══ wpclsQueryDetailsInfo Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryDetailsInfo Parameter - pClassFieldInfo ═══ pClassFieldInfo (PCLASSFIELDINFO) - in/out Pointer to details information. ═══ wpclsQueryDetailsInfo Parameter - pSize ═══ pSize (PULONG) - in/out Total number of bytes of details data. This total includes the details added by this class and ancestor classes. ═══ wpclsQueryDetailsInfo Return Value - ulReturn ═══ ulReturn (ULONG) - returns Sum of the number of detail columns for the object. This sum includes details added by this class and ancestor classes. ═══ wpclsQueryDetailsInfo - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pClassFieldInfo (PCLASSFIELDINFO) - in/out Pointer to details information. pSize (PULONG) - in/out Total number of bytes of details data. This total includes the details added by this class and ancestor classes. ulReturn (ULONG) - returns Sum of the number of detail columns for the object. This sum includes details added by this class and ancestor classes. ═══ wpclsQueryDetailsInfo - Remarks ═══ All objects which have information to display in details view must override this method. The two possible queries are: Query 1 A request for the CLASSFIELDINFO linked the list segment associated with an object. This information is needed just prior to changing the view of a container control to details view. If pClassFieldInfo is NULL (no subclasses have appended details data), the number of columns of details information for this class and all its superclasses is returned. If pClassFieldInfo is NON-NULL, the number of columns of details informtion is returned and *pClassFieldInfo points to the head of a linked list of CLASSFIELDINFO structures to which a linked list of CLASSFIELDINFO structures describing the details fields of objects of this subclass should be appended. For example,on input *pClassFieldInfo: CLASSFIELDINFO_1_grandparent_ CLASSFIELDINFO_2_grandparent CLASSFIELDINFO_1_parent on output, *pClassFieldInfo: CLASSFIELDINFO_1_grandparent_ CLASSFIELDINFO_2_grandparent CLASSFIELDINFO_1_parent CLASSFIELDINFO_1_self The correct way to handle this request is to do the following:  Call the parent method. The parent method returns the number of columns the ancestors have contributed.  Walk the chain of CLASSFIELDINFO structures to the end and append the chain of CLASSFIELDINFO structures for the current class (using the pNextFieldInfo element).  If *pClassFieldInfo is zero (indicating no parent columns), assign *pClassFieldInfo = beginning of CLASSFIELDINFO chain for this subclass.  Return the sum of the details columns of the parent and the current subclass. Note the following differences between the CLASSFIELDINFO and FIELDINFO structures:  The offFieldData and ulLenFieldData fields are required so that appropriate offsets for the data can be computed. The application is responsible for providing offFieldData and ulLenFieldData fields.  The ulReserved field should be left NULL.  Owner draw, comparison, and sort functions may be specified for the field. For example, if an object has three fields: typedef struct _SAMPLE_DETAIL_DATA { CDATE cdate; CTIME ctime; PSZ psz; } SAMPLE_DETAIL_DATA; classfieldinfo[0].offFieldData = FIELDOFFSET(SAMPLE,cdate); classfieldinfo[0].ulLenFieldData = FIELDOFFSET(SAMPLE,ctime) FIELDOFFSET(SAMPLE,cdate); classfieldinfo[1].offFieldData = FIELDOFFSET(SAMPLE,ctime); classfieldinfo[1].ulLenFieldData = FIELDOFFSET(SAMPLE,psz) - FIELDOFFSET(SAMPLE,ctime); classfieldinfo[2].offFieldData = FIELDOFFSET(SAMPLE,psz); classfieldinfo[2].ulLenFieldData = sizeof(SAMPLE) - FIELDOFFSET(SAMPLE,psz); Note that *pClassFieldInfo must be modified to point to the beginning of the CLASSFIELDINFO linked list only if *pClassFieldInfo is 0. The application must return the sum of the details columns of the parent and itself: return(n_cols + n_parent_cols); Note also that the fields MUST be set up sequentially. classfieldinfo[0] must point to data at an offset of 0. classfieldinfo[n] must point to data adjacent, and directly following that described by classfieldinfo[-1]. Query 2 The number of bytes of details data associated with an object. This information is needed prior to allocating memory for a container control insert record. If pSize is NON-NULL, the override should adjust *pSize by the number of bytes which must be added to the end of a MINIRECORDCORE structure to hold the details information for objects of this class. Example: *pSize += bytes_of_details_data; In the case of the above example, *pSize += sizeof(SAMPLE_DETAIL_DATA); Note: All class field pointers returned should be pointers to static data areas. ═══ wpclsQueryDetailsInfo - Usage ═══ This method is generally called only by the system. ═══ wpclsQueryDetailsInfo - How to Override ═══ This method should be overridden by classes that introduce class-specific details to be displayed in details view. The parent method must always be called before appending the request information. ═══ wpclsQueryDetailsInfo - Related Methods ═══  wpQueryDetailsData  wpclsQueryDetails  wpclsQueryDetailsInfo ═══ wpclsQueryDetailsInfo - Example Code ═══ This example adds details data for the Car object by appending FIELDINFO structures to *ppClassFieldInfo. SOM_Scope ULONG SOMLINK carM_wpclsQueryDetailsInfo(M_Car *somSelf, PCLASSFIELDINFO *ppClassFieldInfo, PULONG pSize) { ULONG cParentCol; PCLASSFIELDINFO pCFI; ULONG i; /* M_CarData *somThis = M_CarGetData(somSelf); */ M_CarMethodDebug("M_Car","carM_wpclsQueryDetailsInfo"); /* Always call the parent method first to retrieve the number of details columns and any data already defined in the details buffer. */ cParentCol = parent_wpclsQueryDetailsInfo(somSelf, ppClassFieldInfo, pSize); /* If details columns exist, add the size of ours to it */ if (pSize) *pSize += sizeof(CARDETAILS); /* If the request was for the chained fieldinfo structures * (ppClassFieldInfo is non-NULL), link them in * * eventually the chain will look like * * Grandad - Dad - Me - Kid - Grandkid * * I will be getting the pointer to the beginning of the chain * * If the beginning of the chain is 0, I will assign the address * of my first CLASSFIELDINFO structure to *ppClassFieldInfo. * Otherwise *pp points to the first column description in the * chain. We need to walk the chain and link our CLASSFIELDINFO * structures at the end. */ if (ppClassFieldInfo) { if (*ppClassFieldInfo) { pCFI = *ppClassFieldInfo; for (i=0;ipNextFieldInfo) ? pCFI->pNextFieldInfo : pCFI; pCFI->pNextFieldInfo = fieldinfo; } else { *ppClassFieldInfo = fieldinfo; } /* endif */ } /* endif */ return ((ULONG) (cParentColumns + NUM_CAR_FIELDS)); } ═══ wpclsQueryDetailsInfo - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.22. wpclsQueryEditString ═══ ═══ wpclsQueryEditString - Syntax ═══ This method is called to allow the class object to specify the text to be used in the edit pushbutton of the palette object's open view. #define INCL_WINWORKPLACE #include M_WPPalette *somSelf; /* Pointer to the WPPalette class object. */ PSZ ppointer; /* Pointer to the edit pushbutton string. */ ppointer = _wpclsQueryEditString(somSelf); ═══ wpclsQueryEditString Parameter - somSelf ═══ somSelf (M_WPPalette *) - input Pointer to the WPPalette class object. ═══ wpclsQueryEditString Return Value - ppointer ═══ ppointer (PSZ) - returns Pointer to the edit pushbutton string. ═══ wpclsQueryEditString - Parameters ═══ somSelf (M_WPPalette *) - input Pointer to the WPPalette class object. ppointer (PSZ) - returns Pointer to the edit pushbutton string. ═══ wpclsQueryEditString - Usage ═══ This method can be called at any time in order to determine the text of the edit pushbutton. ═══ wpclsQueryEditString - How to Override ═══ This method should be overridden in order to specify class-specific edit pushbutton text. The parent method is generally not called. ═══ wpclsQueryEditString - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Glossary ═══ 3.23. wpclsQueryError ═══ ═══ wpclsQueryError - Syntax ═══ This class method queries the current error code held within a class object. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ ULONG ulErrorId; /* ID of the last error. */ ulErrorId = _wpclsQueryError(somSelf); ═══ wpclsQueryError Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryError Return Value - ulErrorId ═══ ulErrorId (ULONG) - returns ID of the last error. Last error that occurred when using this class object. ═══ wpclsQueryError - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ulErrorId (ULONG) - returns ID of the last error. Last error that occurred when using this class object. ═══ wpclsQueryError - Remarks ═══ When an error occurs within a class method and that method subsequently fails, the calling procedure can retrieve the error code for that failed method call by using the wpclsQueryError method. Note that the error code is always that of the last method that failed. A successful method does not modify the error code held within a class object. This method is analogous to the WinGetErrorInfo and the WinGetLastError function calls that are used by Presentation Manager applications to diagnose the reason for the previous failing call to a Presentation Manager function call. The system-provided class methods will return error codes as defined in the header file PMERR.H. For example, the wpclsQueryObject method will normally log an error of WPERR_OBJECT_NOT_FOUND if it is unable to return an object pointer. ═══ wpclsQueryError - Usage ═══ This method should be called immediately after a class method has failed in order to diagnose why the failure occurred. ═══ wpclsQueryError - How to Override ═══ Never override this class method. ═══ wpclsQueryError - Related Methods ═══  wpclsSetError ═══ wpclsQueryError - Example Code ═══ This example finds all occurrences of an object type in a folder. VOID clsFindEverybody(SOMAny *self) { BOOL rc; /* Return from methods */ HFIND hFind = 0; /* Handle for repeated finds */ CLASS Class[2]; /* List of classes to look for */ OBJECT Object[10]; /* Objects returned from search */ ULONG ulCount = 10; /* Count of objects to find / or found */ WPFolder *folder = 0; /* Pointer to folder for search */ ULONG errorid = 0; /* Error returned from previous search */ CHAR sz[CCHMAXPATH]; /* Title string to look for */ PSZ title = sz; Class[0] = _WPFolder; Class[1] = NULL; /* Get the pointer to the desktop (since that is where we are looking) */ folder = _wpclsQueryFolder( _WPFolder, "", TRUE ); _wpclsSetError( _WPObject, 0 ); /* Reset the error indicators */ rc = 0; /* Attempt to find the first 10 objects matching our criteria */ ulCount = 10; rc =_wpclsFindObjectFirst(_WPObject, /* Class self pointer */ Class, /* Pointer to array of class objects */ &hFind, /* Handle for wpclsFindObjectNext */ NULL, /* Find EVERYTHING */ folder, /* Pointer to folder of interest */ TRUE, /* Search all folders in tree */ NULL, /* No extended criteria */ Object, /* Array of object pointers */ &ulCount ); /* Number requested and number found */ errorid = _wpclsQueryError( _WPObject); /* Get errorid (may still be OK) */ if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf(" _wpclsFindObjectFirst failed, errorid=%u\n", errorid ); return; } /* endif */ do { _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Look for next 10 objects */ rc =_wpclsFindObjectNext(_WPObject, /* Self */ hFind, /* Handle from previous Find */ Object, /* Objects found */ &ulCount ); /* Number to look for. On return, number found */ errorid = _wpclsQueryError( _WPObject ); if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf("_wpclsFindObjectNext failed, errorid=%u\n", errorid); return; } /* endif */ } while ( errorid == WPERR_BUFFER_OVERFLOW ); /* enddo */ _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Indicate find complete */ rc =_wpclsFindObjectEnd( _WPObject, hFind ); if (!rc) { errorid = _wpclsQueryError( _WPObject ); somPrintf( "_wpclsFindObjectEnd failed, errorid=%u\n", errorid ); return; } return; } ═══ wpclsQueryError - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.24. wpclsQueryExtendedCriteria ═══ ═══ wpclsQueryExtendedCriteria - Syntax ═══ The wpclsQueryExtendedCriteria method is called to allow the specified class to specify the extended criteria to be used on a search for instances of this class. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSZ Title; /* Pointer to the title specification for objects to be searched. */ ULONG ulSearchType; /* Flag indicating type of search to be performed. */ PVOID ExtendedCriteria; /* Pointer to a buffer that contains the class-specific extended search criteria. */ BOOL fSuccess; /* Success indicator. */ fSuccess = wpclsQueryExtendedCriteria(somSelf, Title, ulSearchType, ExtendedCriteria); ═══ wpclsQueryExtendedCriteria Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryExtendedCriteria Parameter - Title ═══ Title (PSZ) - input Pointer to the title specification for objects to be searched. This title may include the wildcard characters "*" and "?". ═══ wpclsQueryExtendedCriteria Parameter - ulSearchType ═══ ulSearchType (ULONG) - input Flag indicating type of search to be performed. SEARCH_ALL_FOLDERS Search all folders. SEARCH_THIS_FOLDER Search current folder only. SEARCH_THIS_TREE Search the current folder tree only. ═══ wpclsQueryExtendedCriteria Parameter - ExtendedCriteria ═══ ExtendedCriteria (PVOID) - output Pointer to a buffer that contains the class-specific extended search criteria. This buffer can be passed to the wpDoesObjectMatch method. ═══ wpclsQueryExtendedCriteria Return Value - fSuccess ═══ fSuccess (BOOL) - returns Success indicator. TRUE Successful completion. FALSE An error occurred or the user canceled the search operation. ═══ wpclsQueryExtendedCriteria - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. Title (PSZ) - input Pointer to the title specification for objects to be searched. This title may include the wildcard characters "*" and "?". ulSearchType (ULONG) - input Flag indicating type of search to be performed. SEARCH_ALL_FOLDERS Search all folders. SEARCH_THIS_FOLDER Search current folder only. SEARCH_THIS_TREE Search the current folder tree only. ExtendedCriteria (PVOID) - output Pointer to a buffer that contains the class-specific extended search criteria. This buffer can be passed to the wpDoesObjectMatch method. fSuccess (BOOL) - returns Success indicator. TRUE Successful completion. FALSE An error occurred or the user canceled the search operation. ═══ wpclsQueryExtendedCriteria - Remarks ═══ This method is called by the system during the processing of the Find and folder Include facilities. This method typically prompts the user to select the extended criteria. ═══ wpclsQueryExtendedCriteria - Usage ═══ This method can be called at any time in order to determine the extended search criteria to be used for finding objects of this class. ═══ wpclsQueryExtendedCriteria - How to Override ═══ This method should be overridden by classes which introduce extended search criteria for use by the Find and folder Include facilities. ═══ wpclsQueryExtendedCriteria - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Glossary ═══ 3.25. wpclsQueryFolder ═══ ═══ wpclsQueryFolder - Syntax ═══ This method is called to get a pointer to a folder object that corresponds to a given file system location. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSZ pLocation; /* Folder location. */ BOOL fLock; /* Lock object flag. */ WPFolder *Success; /* Success indicator. */ Success = _wpclsQueryFolder(somSelf, pLocation, fLock); ═══ wpclsQueryFolder Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryFolder Parameter - pLocation ═══ pLocation (PSZ) - input Folder location. This value can be in any of the following formats:  Predefined object IDs of system folders: "" The hidden folder. "" The currently active desktop. "" The System folder. "" The Templates folder. "" The System Setup folder. "" The Startup folder. "" The Information folder. "" The Drives folder.  Real name specified as a fully qualified path name. ═══ wpclsQueryFolder Parameter - fLock ═══ fLock (BOOL) - input Lock object flag. If this flag is false, the newly created object will be made dormant whenever the object and the folder containing the object are closed. If this flag is true, the new flag will remain active until the caller issues the wpUnlockObject method on it. ═══ wpclsQueryFolder Return Value - Success ═══ Success (WPFolder *) - returns Success indicator. NULL Error occurred Other Pointer to a folder object. ═══ wpclsQueryFolder - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pLocation (PSZ) - input Folder location. This value can be in any of the following formats:  Predefined object IDs of system folders: "" The hidden folder. "" The currently active desktop. "" The System folder. "" The Templates folder. "" The System Setup folder. "" The Startup folder. "" The Information folder. "" The Drives folder.  Real name specified as a fully qualified path name. fLock (BOOL) - input Lock object flag. If this flag is false, the newly created object will be made dormant whenever the object and the folder containing the object are closed. If this flag is true, the new flag will remain active until the caller issues the wpUnlockObject method on it. Success (WPFolder *) - returns Success indicator. NULL Error occurred Other Pointer to a folder object. ═══ wpclsQueryFolder - Remarks ═══ To obtain a real name from an object pointer, the wpQueryRealName method should be called. ═══ wpclsQueryFolder - Usage ═══ This method can be called at any time in order to determine the object pointer for a folder. ═══ wpclsQueryFolder - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryFolder - Example Code ═══ #define INCL_WINWORKPLACE #include SOMAny *objDesktop; SOMAny *objSysShadow; /* Get the object pointer of the desktop folder */ objDesktop = _wpclsQueryFolder( _WPFolder , "" /* Folder location */ ,TRUE); /* Keep active */ /* Create a shadow of the desktop */ objSysShadow = _wpCreateShadowObject( self , objDesktop /* Object to shadow */ ,FALSE); /* Make dormant when folder closes */ ═══ wpclsQueryFolder - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Glossary ═══ 3.26. wpclsQueryIcon ═══ ═══ wpclsQueryIcon - Syntax ═══ This method is called to allow the class object to specify the default icon to be used for its instances. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HPOINTER hptrSuccess; /* Success indicator. */ hptrSuccess = _wpclsQueryIcon(somSelf); ═══ wpclsQueryIcon Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryIcon Return Value - hptrSuccess ═══ hptrSuccess (HPOINTER) - returns Success indicator. NULL Error occurred Other Handle to an icon. ═══ wpclsQueryIcon - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hptrSuccess (HPOINTER) - returns Success indicator. NULL Error occurred Other Handle to an icon. ═══ wpclsQueryIcon - Remarks ═══ The class default icon can be loaded on wpclsInitData and freed on wpclsUnInitData. ═══ wpclsQueryIcon - Usage ═══ This method can be called at any time in order to determine the default icon for instances of this class. ═══ wpclsQueryIcon - How to Override ═══ This method is overridden in order to change the default icon for an instance of the class. ═══ wpclsQueryIcon - Related Methods ═══  wpclsQueryIcon  wpQueryIconData  wpSetIcon  wpSetIconData  wpQueryIcon  wpclsQueryIconData ═══ wpclsQueryIcon - Example Code ═══ This example returns the handle to an icon. SOM_Scope HPOINTER SOMLINK pviewM_wpclsQueryIcon(M_PictureViewer *somSelf) { /* M_PictureViewerData *somThis = M_PictureViewerGetData(somSelf); */ M_PictureViewerMethodDebug("M_PictureViewer","pviewM_wpclsQueryIcon"); /* return (parent_wpclsQueryIcon(somSelf)); don't call parent method */ return ( _hIcon ); /* Return own Icon */ } ═══ wpclsQueryIcon - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.27. wpclsQueryIconData ═══ ═══ wpclsQueryIconData - Syntax ═══ This class method allows the system to build the class default icon for a given class. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the class object for which you want the class icon data. */ PICONINFO pIconInfo; /* Pointer to a buffer. */ ULONG ulReturn; /* Buffer size or number of bytes required to hold the output data. */ ulReturn = _wpclsQueryIconData(somSelf, pIconInfo); ═══ wpclsQueryIconData Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the class object for which you want the class icon data. ═══ wpclsQueryIconData Parameter - pIconInfo ═══ pIconInfo (PICONINFO) - output Pointer to a buffer. Pointer to the buffer large enough to contain an ICONINFO data structure followed by the data needed to describe the icon. If pIconInfo is NULL, the return value is the required size of the buffer. ═══ wpclsQueryIconData Return Value - ulReturn ═══ ulReturn (ULONG) - returns Buffer size or number of bytes required to hold the output data. Depending of the contents of the pIconInfo parameter, ulReturn contains one of the following: pIconInfo ulReturn NULL Number of bytes required to hold the output data for this class. Not NULL Number of bytes written into the buffer. If ulReturn is 0, an error occurred. ═══ wpclsQueryIconData - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the class object for which you want the class icon data. pIconInfo (PICONINFO) - output Pointer to a buffer. Pointer to the buffer large enough to contain an ICONINFO data structure followed by the data needed to describe the icon. If pIconInfo is NULL, the return value is the required size of the buffer. ulReturn (ULONG) - returns Buffer size or number of bytes required to hold the output data. Depending of the contents of the pIconInfo parameter, ulReturn contains one of the following: pIconInfo ulReturn NULL Number of bytes required to hold the output data for this class. Not NULL Number of bytes written into the buffer. If ulReturn is 0, an error occurred. ═══ wpclsQueryIconData - Remarks ═══ If NULL is passed for the pIconInfo parameter, the caller is asking for the size of the ICONINFO buffer needed for this class (usually for memory allocation purposes). Otherwise, the pIconInfo parameter can always be assumed to be large enough to accommodate the ICONINFO and the variable data for this class. Note that the ICONINFO structure allows you to specify the default icon in three different ways:  Block of binary data  Icon file name  Module name and resource identifier However, only one mechanism need be supported by any given class. For example, a caller cannot request one of the three formats by prefilling the ICONINFO structure. ═══ wpclsQueryIconData - Usage ═══ This method may be called at any time. Typically, it would not be useful for another object class to make calls to this method. ═══ wpclsQueryIconData - How to Override ═══ Workplace classes that wish to have a unique class default icon must override this method and fill out the appropriate fields within the ICONINFO structure. In addition, the correct size for the ICONINFO must always be returned. ═══ wpclsQueryIconData - Related Methods ═══  wpQueryIcon  wpQueryIconData  wpSetIcon  wpSetIconData  wpclsQueryIcon ═══ wpclsQueryIconData - Example Code ═══ This example returns information about the icon associated with the class if pIconInfo is not NULL. SOM_Scope ULONG SOMLINK CalendarM_wpclsQueryIconData(M_Calendar *somSelf, PICONINFO pIconInfo) { M_CalendarData *somThis = M_CalendarGetData(somSelf); M_CalendarMethodDebug("M_Calendar","myfM_wpclsQueryIconData"); if (pIconInfo) { pIconInfo->fFormat = ICON_RESOURCE; pIconInfo->hmod = _clsQueryModuleHandle(somSelf); pIconInfo->resid = ID_ICON; } /* endif */ return (sizeof(ICONINFO)); } ═══ wpclsQueryIconData - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.28. wpclsQueryIconDataN ═══ ═══ wpclsQueryIconDataN - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method allows the system to build the class default animation icon for a given class. #define INCL_WINWORKPLACE #include M_WPFolder *somSelf; /* Pointer to the WPFolder class object. */ PICONINFO pIconInfo; /* Pointer to the icon information. */ ULONG ulcbIconInfo; /* Size of the buffer needed to store the ICONINFO data returned by this class object. */ ULONG ulIconIndex; /* Animation icon index. */ _wpclsQueryIconDataN(somSelf, pIconInfo, ulcbIconInfo, ulIconIndex); ═══ wpclsQueryIconDataN Parameter - somSelf ═══ somSelf (M_WPFolder *) - input Pointer to the WPFolder class object. ═══ wpclsQueryIconDataN Parameter - pIconInfo ═══ pIconInfo (PICONINFO) - input Pointer to the icon information. ═══ wpclsQueryIconDataN Parameter - ulcbIconInfo ═══ ulcbIconInfo (ULONG) - input Size of the buffer needed to store the ICONINFO data returned by this class object. ═══ wpclsQueryIconDataN Parameter - ulIconIndex ═══ ulIconIndex (ULONG) - input Animation icon index. This value must be 1. ═══ wpclsQueryIconDataN - Parameters ═══ somSelf (M_WPFolder *) - input Pointer to the WPFolder class object. pIconInfo (PICONINFO) - input Pointer to the icon information. ulcbIconInfo (ULONG) - input Size of the buffer needed to store the ICONINFO data returned by this class object. ulIconIndex (ULONG) - input Animation icon index. This value must be 1. ═══ wpclsQueryIconDataN - Remarks ═══ If NULLHANDLE is passed for the pIconInfo parameter, the caller is asking for the size of the ICONINFO buffer needed for this class usually for memory allocation purposes. Otherwise, the pIconInfo parameter can always be assumed to be large enough to accommodate the ICONINFO for this class. Note that the ICONINFO structure allows you to specify the default icon in three different ways:  An icon filename  A module name and resource identifier  A block of binary data However, only one mechanism needs to be supported for any given class. For example, a caller cannot request one of the three formats by prefilling the ICONINFO structure. ═══ wpclsQueryIconDataN - Usage ═══ This method may be called at any time. Typically, it would not be useful for another object class to make calls to this method. ═══ wpclsQueryIconDataN - How to Override ═══ Workplace classes that wish to have a unique class default animation icon must override this method and fill out the appropriate fields within the ICONINFO structure. In addition, the correct size for the ICONINFO must always be returned. ═══ wpclsQueryIconDataN - Related Methods ═══  wpQueryIcon  wpQueryIconData  wpSetIcon  wpSetIconData  wpclsQueryIconN ═══ wpclsQueryIconDataN - Topics ═══ Select an item: Syntax Parameters Remarks How to Override Usage Related Methods Glossary ═══ 3.29. wpclsQueryIconN ═══ ═══ wpclsQueryIconN - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This method is called to allow the class object to specify the default animation icon to be used for its instances. #define INCL_WINWORKPLACE #include M_WPFolder *somSelf; /* Pointer to the WPFolder class object. */ ULONG ulIconIndex; /* Animation icon index. */ HPOINTER hptr; /* Handle to the animation icon. */ hptr = _wpclsQueryIconN(somSelf, ulIconIndex); ═══ wpclsQueryIconN Parameter - somSelf ═══ somSelf (M_WPFolder *) - input Pointer to the WPFolder class object. ═══ wpclsQueryIconN Parameter - ulIconIndex ═══ ulIconIndex (ULONG) - input Animation icon index. This value must be 1. ═══ wpclsQueryIconN Return Value - hptr ═══ hptr (HPOINTER) - returns Handle to the animation icon. A return value of NULL indicates that there is no animation icon. ═══ wpclsQueryIconN - Parameters ═══ somSelf (M_WPFolder *) - input Pointer to the WPFolder class object. ulIconIndex (ULONG) - input Animation icon index. This value must be 1. hptr (HPOINTER) - returns Handle to the animation icon. A return value of NULL indicates that there is no animation icon. ═══ wpclsQueryIconN - Remarks ═══ This method is very similar to wpclsQueryIcon. The difference is that wpclsQueryIcon returns the handle for a normal object icon (the closed folder icon), while wpclsQueryIconN returns the handle for the animation icon (the open folder icon). ═══ wpclsQueryIconN - Usage ═══ This method can be called at any time. ═══ wpclsQueryIconN - How to Override ═══ This method generally not overridden. ═══ wpclsQueryIconN - Related Methods ═══  wpclsQueryIcon  wpQueryIconData  wpSetIcon  wpSetIconData  wpQueryIcon  wpclsQueryIconData  wpclsQueryIconDataN ═══ wpclsQueryIconN - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.30. wpclsQueryInstanceFilter ═══ ═══ wpclsQueryInstanceFilter - Syntax ═══ This method is called to allow the class object to specify the file title filters for instances of its class. #define INCL_WINWORKPLACE #include M_WPFileSystem *somSelf; /* Pointer to the WPFileSystem class object. */ PSZ psuccess; /* Success indicator. */ psuccess = _wpclsQueryInstanceFilter(somSelf); ═══ wpclsQueryInstanceFilter Parameter - somSelf ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. ═══ wpclsQueryInstanceFilter Return Value - psuccess ═══ psuccess (PSZ) - returns Success indicator. NULL Error occurred. Other A pointer to a string containing file title filters. This string can contain several file title filters separated by commas. For example: "*.TXT, *.DOC" ═══ wpclsQueryInstanceFilter - Parameters ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. psuccess (PSZ) - returns Success indicator. NULL Error occurred. Other A pointer to a string containing file title filters. This string can contain several file title filters separated by commas. For example: "*.TXT, *.DOC" ═══ wpclsQueryInstanceFilter - Remarks ═══ It is important that the values returned by this class method are restricted to class-specific filters. For example, returning a filter of "*.*" could effectively make the system unstable. ═══ wpclsQueryInstanceFilter - Usage ═══ This method can be called at any time in order to determine which file title filters are used to determine instances of this class. ═══ wpclsQueryInstanceFilter - How to Override ═══ This method should be overridden in order to automatically designate file objects as instances of this class. The value returned by the override method will replace the current title filter string which is used to designate instances. If the parent method is called, it should be called first. ═══ wpclsQueryInstanceFilter - Related Methods ═══  wpclsQueryInstanceType ═══ wpclsQueryInstanceFilter - Example Code ═══ This example shows how to designate files ending in an extension of .GIF as being associated with an instance of a GIFPicture object. SOM_Scope PSZ SOMLINK gifpicM_wpclsQueryInstanceFilter(M_GIFPicture *somSelf) { /* M_GIFPictureData *somThis = M_GIFPictureGetData(somSelf); */ M_GIFPictureMethodDebug("M_GIFPicture","gifpicM_wpclsQueryInstanceFilter"); /* return (parent_wpclsQueryInstanceFilter(somSelf)); Don't call parent */ return ( "*.GIF" ); } ═══ wpclsQueryInstanceFilter - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.31. wpclsQueryInstanceType ═══ ═══ wpclsQueryInstanceType - Syntax ═══ This method is called to allow the class object to specify the file types for instances of its class. #define INCL_WINWORKPLACE #include M_WPFileSystem *somSelf; /* Pointer to the WPFileSystem class object. */ PSZ psuccess; /* Success indicator. */ psuccess = _wpclsQueryInstanceType(somSelf); ═══ wpclsQueryInstanceType Parameter - somSelf ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. ═══ wpclsQueryInstanceType Return Value - psuccess ═══ psuccess (PSZ) - returns Success indicator. NULL Error occurred. Other A pointer to a string containing file types. This string can contain several file types separated by commas. For example: "Plain Text,C Code" ═══ wpclsQueryInstanceType - Parameters ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. psuccess (PSZ) - returns Success indicator. NULL Error occurred. Other A pointer to a string containing file types. This string can contain several file types separated by commas. For example: "Plain Text,C Code" ═══ wpclsQueryInstanceType - Remarks ═══ It is recommended that object classes define their own special type strings. ═══ wpclsQueryInstanceType - Usage ═══ This method can be called at any time in order to determine which file types are used to determine instances of this class. ═══ wpclsQueryInstanceType - How to Override ═══ This method should be overridden in order to automatically designate file objects as instances of this class. The value returned by the override method will replace the current type string which is used to designate instances. If the parent method is called, it should be called first. ═══ wpclsQueryInstanceType - Related Methods ═══  wpclsQueryInstanceFilter ═══ wpclsQueryInstanceType - Example Code ═══ This example associates two file types as being associated with the Picture object. SOM_Scope PSZ SOMLINK PictureM_wpclsQueryInstanceType(M_Picture *somSelf) { /* M_PictureData *somThis = M_PictureGetData(somSelf); */ M_PictureMethodDebug("M_Picture","PictureM_wpclsQueryInstanceType"); /* return (parent_wpclsQueryInstanceType(somSelf)); no call to parent */ return ( "JPG File,GIF File" ); } ═══ wpclsQueryInstanceType - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.32. wpclsQueryObject ═══ ═══ wpclsQueryObject - Syntax ═══ This class method returns the object pointer for a given persistent object handle. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HOBJECT hObject; /* Handle for a given object instance. */ WPObject *object; /* Pointer to the object. */ object = _wpclsQueryObject(somSelf, hObject); ═══ wpclsQueryObject Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryObject Parameter - hObject ═══ hObject (HOBJECT) - input Handle for a given object instance. ═══ wpclsQueryObject Return Value - object ═══ object (WPObject *) - returns Pointer to the object. The pointer to the object that corresponds to the given object handle or NULLHANDLE if that object no longer exists. ═══ wpclsQueryObject - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hObject (HOBJECT) - input Handle for a given object instance. object (WPObject *) - returns Pointer to the object. The pointer to the object that corresponds to the given object handle or NULLHANDLE if that object no longer exists. ═══ wpclsQueryObject - Remarks ═══ All workplace objects can be uniquely identified by a persistent object handle within a given machine. Once an object handle is obtained for an object (using the wpQueryHandle instance method), the handle can be used at any subsequent time even if the system was powered off in the meantime, provided that the object instance has not been destroyed. This method is intended for use by objects that wish to communicate with other objects using method calls. At any point in time, an object can reestablish contact with another object by using this method. For example, a WPShadow object will use this method to get the object pointer to the object it is currently shadowing when it is made awake. Note that the returned object is locked so that the called object can access the returned pointer without the risk of the object being made dormant. When the object pointer is no longer needed, the wpUnlockObject method should be invoked to permit the system to make that object dormant when all other locks on it have been released. Using HOBJECT for .INI files or files in which an application uses a rename/save/delete sequence is not supported. ═══ wpclsQueryObject - Usage ═══ This method can be called at any time. ═══ wpclsQueryObject - How to Override ═══ This class method is generally not overridden. ═══ wpclsQueryObject - Related Methods ═══  wpclsObjectFromHandle  wpclsQueryObjectFromFrame  wpclsQueryObjectFromPath ═══ wpclsQueryObject - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.33. wpclsQueryObjectFromFrame ═══ ═══ wpclsQueryObjectFromFrame - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method returns a pointer to the object associated with the specified frame window handle. #define INCL_WINWORKPLACE #include M_WPDesktop *somSelf; /* Pointer to the WPDesktop class object. */ HWND hwndFrame; /* Handle to the top-level frame window. */ WPObject *Object; /* Pointer to the object associated with hwndFrame. */ Object = _wpclsQueryObjectFromFrame(somSelf, hwndFrame); ═══ wpclsQueryObjectFromFrame Parameter - somSelf ═══ somSelf (M_WPDesktop *) - input Pointer to the WPDesktop class object. ═══ wpclsQueryObjectFromFrame Parameter - hwndFrame ═══ hwndFrame (HWND) - input Handle to the top-level frame window. ═══ wpclsQueryObjectFromFrame Return Value - Object ═══ Object (WPObject *) - returns Pointer to the object associated with hwndFrame. This parameter contains a pointer to the object of which its view has the given frame window handle as its top-level frame window handle. A return value of NULL indicates that either an associated object could not be found or an error occurred. ═══ wpclsQueryObjectFromFrame - Parameters ═══ somSelf (M_WPDesktop *) - input Pointer to the WPDesktop class object. hwndFrame (HWND) - input Handle to the top-level frame window. Object (WPObject *) - returns Pointer to the object associated with hwndFrame. This parameter contains a pointer to the object of which its view has the given frame window handle as its top-level frame window handle. A return value of NULL indicates that either an associated object could not be found or an error occurred. ═══ wpclsQueryObjectFromFrame - Remarks ═══ This method returns the object for which the handle is a view rather than the application implementing the view. For example, if the hwndFrame of a folder's view is passed in, this method returns the folder object. If the hwndFrame of the system editor is passed in, this method returns the object which is currently being viewed by the editor. In this case, if an associated object cannot be found, the system editor program object is returned. For instance, if the system editor is launched from the command line and its hwndFrame is passed in, the editor program object is returned. ═══ wpclsQueryObjectFromFrame - Usage ═══ This method can be called at any time. ═══ wpclsQueryObjectFromFrame - How to Override ═══ This method should not be overridden. ═══ wpclsQueryObjectFromFrame - Related Methods ═══  wpclsQueryObject  wpclsObjectFromHandle  wpclsQueryObjectFromPath ═══ wpclsQueryObjectFromFrame - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.34. wpclsQueryObjectFromPath ═══ ═══ wpclsQueryObjectFromPath - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method returns the object pointer for a file or directory. #define INCL_WINWORKPLACE #include M_WPFileSystem *somSelf; /* Pointer to the WPFileSystem class object. */ PSZ pszFQPath; /* String containing the fully qualified path name (or object ID). */ WPObject *pObject; /* Pointer to the object that represents the file or directory specified in pszFQPath. */ pObject = _wpclsQueryObjectFromPath(somSelf, pszFQPath); ═══ wpclsQueryObjectFromPath Parameter - somSelf ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. ═══ wpclsQueryObjectFromPath Parameter - pszFQPath ═══ pszFQPath (PSZ) - input String containing the fully qualified path name (or object ID). ═══ wpclsQueryObjectFromPath Return Value - pObject ═══ pObject (WPObject *) - returns Pointer to the object that represents the file or directory specified in pszFQPath. ═══ wpclsQueryObjectFromPath - Parameters ═══ somSelf (M_WPFileSystem *) - input Pointer to the WPFileSystem class object. pszFQPath (PSZ) - input String containing the fully qualified path name (or object ID). pObject (WPObject *) - returns Pointer to the object that represents the file or directory specified in pszFQPath. ═══ wpclsQueryObjectFromPath - Remarks ═══ The object is initially locked, so there is no risk of the object being made dormant before the object pointer is obtained. ═══ wpclsQueryObjectFromPath - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryObjectFromPath - Related Methods ═══  wpclsQueryObject ═══ wpclsQueryObjectFromPath - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Related Methods Glossary ═══ 3.35. wpclsQueryOpenFolders ═══ ═══ wpclsQueryOpenFolders - Syntax ═══ This class method enumerates all open folders for the specified class. #define INCL_WINWORKPLACE #include M_WPFolder *somSelf; /* Pointer to the WPFolder class object. */ WPFolder *Folder; /* Pointer to a folder object. */ ULONG ulOption; /* Flag indicating the folder to query. */ BOOL fLock; /* Lock the object flag. */ WPFolder *FldrObject; /* Pointer to the specified folder object. */ FldrObject = _wpclsQueryOpenFolders(somSelf, Folder, ulOption, fLock); ═══ wpclsQueryOpenFolders Parameter - somSelf ═══ somSelf (M_WPFolder *) - input Pointer to the WPFolder class object. ═══ wpclsQueryOpenFolders Parameter - Folder ═══ Folder (WPFolder *) - input Pointer to a folder object. This field is ignored unless QC_NEXT is specified in ulOption. ═══ wpclsQueryOpenFolders Parameter - ulOption ═══ ulOption (ULONG) - input Flag indicating the folder to query. Possible values are described in the following list: QC_FIRST Return the first open folder in the open-folder list. This value is specified on the class object if the passed object is not currently open. QC_LAST Return the last open folder. QC_NEXT Return the next open folder after Folder in the list. ═══ wpclsQueryOpenFolders Parameter - fLock ═══ fLock (BOOL) - input Lock the object flag. Possible values are described in the following list: TRUE The new flag will remain active until the caller issues wpUnlockObject on it. FALSE The newly created object will be made dormant whenever the object and the folder containing the object are closed. ═══ wpclsQueryOpenFolders Return Value - FldrObject ═══ FldrObject (WPFolder *) - returns Pointer to the specified folder object. A return value of NULL indicates that either an error occurred or QC_NEXT was requested on the last folder. ═══ wpclsQueryOpenFolders - Parameters ═══ somSelf (M_WPFolder *) - input Pointer to the WPFolder class object. Folder (WPFolder *) - input Pointer to a folder object. This field is ignored unless QC_NEXT is specified in ulOption. ulOption (ULONG) - input Flag indicating the folder to query. Possible values are described in the following list: QC_FIRST Return the first open folder in the open-folder list. This value is specified on the class object if the passed object is not currently open. QC_LAST Return the last open folder. QC_NEXT Return the next open folder after Folder in the list. fLock (BOOL) - input Lock the object flag. Possible values are described in the following list: TRUE The new flag will remain active until the caller issues wpUnlockObject on it. FALSE The newly created object will be made dormant whenever the object and the folder containing the object are closed. FldrObject (WPFolder *) - returns Pointer to the specified folder object. A return value of NULL indicates that either an error occurred or QC_NEXT was requested on the last folder. ═══ wpclsQueryOpenFolders - Usage ═══ This method can be called at any time. ═══ wpclsQueryOpenFolders - How to Override ═══ This method is generally not overridden. ═══ wpclsQueryOpenFolders - Related Methods ═══  wpContainsFolders ═══ wpclsQueryOpenFolders - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Related Methods Glossary ═══ 3.36. wpclsQuerySetting ═══ ═══ wpclsQuerySetting - Syntax ═══ This method returns the class object settings from the Settings notebook. #define INCL_WINWORKPLACE #include M_WPAbstract *somSelf; /* Pointer to the WPAbstract class object. */ PSZ pszSetting; /* Name of the setting that is to be queried. */ PVOID pValue; /* Buffer in which settings values are returned. */ ULONG ulValueLen; /* Length of pValue. */ ULONG ulReturnedData; /* Length of data returned in pValue. */ ulReturnedData = _wpclsQuerySetting(somSelf, pszSetting, pValue, ulValueLen); ═══ wpclsQuerySetting Parameter - somSelf ═══ somSelf (M_WPAbstract *) - input Pointer to the WPAbstract class object. ═══ wpclsQuerySetting Parameter - pszSetting ═══ pszSetting (PSZ) - input Name of the setting that is to be queried. ═══ wpclsQuerySetting Parameter - pValue ═══ pValue (PVOID) - in/out Buffer in which settings values are returned. If this parameter is NULL, only the length of the value of the setting is returned. ═══ wpclsQuerySetting Parameter - ulValueLen ═══ ulValueLen (ULONG) - input Length of pValue. ═══ wpclsQuerySetting Return Value - ulReturnedData ═══ ulReturnedData (ULONG) - returns Length of data returned in pValue. A return value of 0 indicates an error occurred, in which case no data is returned in pValue. ═══ wpclsQuerySetting - Parameters ═══ somSelf (M_WPAbstract *) - input Pointer to the WPAbstract class object. pszSetting (PSZ) - input Name of the setting that is to be queried. pValue (PVOID) - in/out Buffer in which settings values are returned. If this parameter is NULL, only the length of the value of the setting is returned. ulValueLen (ULONG) - input Length of pValue. ulReturnedData (ULONG) - returns Length of data returned in pValue. A return value of 0 indicates an error occurred, in which case no data is returned in pValue. ═══ wpclsQuerySetting - Remarks ═══ This is a virtual method and must be overridden by a subclass. Each subclass documents the possible values for pszSetting and pValue. These settings and values are specific for each subclass. Note that all settings have safe defaults, so it is never necessary to pass unnecessary settings to an object. For a list of settings and their associated values, see the individual classes. ═══ wpclsQuerySetting - Usage ═══ This method should never be called. It is a virtual method and must be overridden by a subclass. ═══ wpclsQuerySetting - How to Override ═══ This is a virtual method and must be overridden by a subclass. ═══ wpclsQuerySetting - Related Methods ═══  wpclsSetSetting ═══ wpclsQuerySetting - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.37. wpclsQuerySettingsPageSize ═══ ═══ wpclsQuerySettingsPageSize - Syntax ═══ This class method returns the default size of a Settings page in dialog units for instances of this object class. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSIZEL pSizl; /* Pointer to the default Settings page dimensions. */ BOOL rc; /* Success indicator. */ rc = _wpclsQuerySettingsPageSize(somSelf, pSizl); ═══ wpclsQuerySettingsPageSize Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQuerySettingsPageSize Parameter - pSizl ═══ pSizl (PSIZEL) - in/out Pointer to the default Settings page dimensions. A pointer to the SIZEL structure containing the cx and cy dimensions of the default Settings page for this class. ═══ wpclsQuerySettingsPageSize Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE The method class call was successful. FALSE The method class call was unsuccessful. ═══ wpclsQuerySettingsPageSize - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pSizl (PSIZEL) - in/out Pointer to the default Settings page dimensions. A pointer to the SIZEL structure containing the cx and cy dimensions of the default Settings page for this class. rc (BOOL) - returns Success indicator. TRUE The method class call was successful. FALSE The method class call was unsuccessful. ═══ wpclsQuerySettingsPageSize - Remarks ═══ An object class that has abnormally shaped Settings pages (for example, the pages may be very wide) can use this method to ensure that, when a Settings notebook is initially displayed for an instance of the object class, that Settings notebook will be of a suitable size to view the whole Settings page without clipping it. The size specified by this method is used only the very first time that a Settings notebook is displayed; thereafter, the Settings notebook size and position will be saved by the system on a per-object basis. ═══ wpclsQuerySettingsPageSize - Usage ═══ This method can be called at any time. ═══ wpclsQuerySettingsPageSize - How to Override ═══ Object classes with unusual size requirements for their Settings pages must override this class method and change the cx and cy values as necessary to accommodate their Settings page sizes. ═══ wpclsQuerySettingsPageSize - Related Methods ═══  wpOpen ═══ wpclsQuerySettingsPageSize - Example Code ═══ This example changes the size of the Settings page for the Person object. This size is only used when the settings are initially displayed. After that, the size and position are saved on a per-object basis. SOM_Scope BOOL SOMLINK PersonM_wpclsQuerySettingsPageSize(M_Person *somSelf, PSIZEL pSizl) { /* M_PersonData *somThis = M_PersonGetData(somSelf); */ M_PersonMethodDebug("M_Person","PersonM_wpclsQuerySettingsPageSize"); pSizl->Cx = 600; pSizl->Cy = 1200; /* return (parent_wpclsQuerySettingsPageSize(somSelf,pSizl)); */ return ( TRUE ); } ═══ wpclsQuerySettingsPageSize - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.38. wpclsQueryStyle ═══ ═══ wpclsQueryStyle - Syntax ═══ This method is called to allow the class object to specify the default object class style for its instances. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ ULONG ulReturn; /* Class style for this object. */ ulReturn = _wpclsQueryStyle(somSelf); ═══ wpclsQueryStyle Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryStyle Return Value - ulReturn ═══ ulReturn (ULONG) - returns Class style for this object. CLSSTYLE_DONTTEMPLATE Do not allow a create-template operation on objects of this class. CLSSTYLE_NEVERCOPY Do not allow a copy operation on objects of this class. CLSSTYLE_NEVERDELETE Do not allow a delete operation on objects of this class. CLSSTYLE_NEVERDRAG Do not allow a drag operation on objects of this class. CLSSTYLE_NEVERDROPON Do not allow a dropon operation on objects of this class. CLSSTYLE_NEVERLINK Do not allow a create-shadow operation on objects of this class. CLSSTYLE_NEVERMOVE Do not allow a move operation on objects of this class. CLSSTYLE_NEVERPRINT Do not allow a print of this object. CLSSTYLE_NEVERRENAME Do not allow the renaming of objects of this class. CLSSTYLE_NEVERSETTINGS Do not allow a settings operation on objects of this class. CLSSTYLE_NEVERVISIBLE Make instances of this class always invisible. ═══ wpclsQueryStyle - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ulReturn (ULONG) - returns Class style for this object. CLSSTYLE_DONTTEMPLATE Do not allow a create-template operation on objects of this class. CLSSTYLE_NEVERCOPY Do not allow a copy operation on objects of this class. CLSSTYLE_NEVERDELETE Do not allow a delete operation on objects of this class. CLSSTYLE_NEVERDRAG Do not allow a drag operation on objects of this class. CLSSTYLE_NEVERDROPON Do not allow a dropon operation on objects of this class. CLSSTYLE_NEVERLINK Do not allow a create-shadow operation on objects of this class. CLSSTYLE_NEVERMOVE Do not allow a move operation on objects of this class. CLSSTYLE_NEVERPRINT Do not allow a print of this object. CLSSTYLE_NEVERRENAME Do not allow the renaming of objects of this class. CLSSTYLE_NEVERSETTINGS Do not allow a settings operation on objects of this class. CLSSTYLE_NEVERVISIBLE Make instances of this class always invisible. ═══ wpclsQueryStyle - Remarks ═══ When an instance is initially created, it has the same object style (OBJSTYLE_xxx) flags as its class style (CLSSTYLE_xxx). ═══ wpclsQueryStyle - Usage ═══ This method can be called at any time in order to determine the default style for instances of this class. ═══ wpclsQueryStyle - How to Override ═══ This method should be overridden in order to modify the default object style for instances of this class. ═══ wpclsQueryStyle - Related Methods ═══  wpclsQueryStyle  wpQueryStyle  wpSetStyle ═══ wpclsQueryStyle - Example Code ═══ This sample shows how to remove the Print option from the menu for BigObject. SOM_Scope ULONG SOMLINK BigObjectM_wpclsQueryStyle(M_BigObject *somSelf) { /* M_BigObjectData *somThis = M_BigObjectGetData(somSelf); */ M_BigObjectMethodDebug("M_BigObject","BigObjectM_wpclsQueryStyle"); return ( parent_wpclsQueryStyle(somSelf) | CLSSTYLE_NEVERPRINT ); } ═══ wpclsQueryStyle - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.39. wpclsQueryTitle ═══ ═══ wpclsQueryTitle - Syntax ═══ This method is called to allow the class object to specify the default title for its instances. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSZ pTitle; /* Pointer to the default title for objects of this class. */ pTitle = _wpclsQueryTitle(somSelf); ═══ wpclsQueryTitle Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsQueryTitle Return Value - pTitle ═══ pTitle (PSZ) - returns Pointer to the default title for objects of this class. ═══ wpclsQueryTitle - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pTitle (PSZ) - returns Pointer to the default title for objects of this class. ═══ wpclsQueryTitle - Remarks ═══ The title is used as the default for new instances of this class. In addition, the title is used to describe the class in facilities such as Find, Include, Details, and Sort. The title can be loaded on wpclsInitData and freed on wpclsUnInitData. ═══ wpclsQueryTitle - Usage ═══ This method can be called at any time in order to determine the default title for instances of this class. ═══ wpclsQueryTitle - How to Override ═══ All classes should override this method, so that new objects and their classes always have a sensible default title. ═══ wpclsQueryTitle - Related Methods ═══  wpQueryTitle  wpclsQueryTitle  wpSetTitle ═══ wpclsQueryTitle - Example Code ═══ This example overrides this method to provide another title. SOM_Scope PSZ SOMLINK SampleM_wpclsQueryTitle(M_Sample *somSelf) { /* M_SampleData *somThis = M_SampleGetData(somSelf); */ M_SampleMethodDebug("M_Sample","SampleM_wpclsQueryTitle"); return( "My WPS Object" ); /* Return a new title */ } ═══ wpclsQueryTitle - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.40. wpclsRemoveObjects ═══ ═══ wpclsRemoveObjects - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method removes all specified objects from a given container and the in-use list. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HWND hwndCnr; /* Handle to the container object. */ PVOID *pRecordArray; /* Pointer to an array of MINIRECORDCORE objects that are to be removed. */ ULONG NumRecords; /* Number of records in pRecordArray. */ BOOL RemoveAll; /* Flag indicating whether to remove all records. */ BOOL rc; /* Success indicator. */ rc = _wpclsRemoveObjects(somSelf, hwndCnr, pRecordArray, NumRecords, RemoveAll); ═══ wpclsRemoveObjects Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsRemoveObjects Parameter - hwndCnr ═══ hwndCnr (HWND) - input Handle to the container object. ═══ wpclsRemoveObjects Parameter - pRecordArray ═══ pRecordArray (PVOID *) - input Pointer to an array of MINIRECORDCORE objects that are to be removed. ═══ wpclsRemoveObjects Parameter - NumRecords ═══ NumRecords (ULONG) - input Number of records in pRecordArray. ═══ wpclsRemoveObjects Parameter - RemoveAll ═══ RemoveAll (BOOL) - input Flag indicating whether to remove all records. Possible values are described in the following list: TRUE All records in the specified container are to be removed, and the in-use list for each object is to be cleaned up. FALSE Only records specified in pRecordArray are to be removed, and the in-use list is to be cleaned up for the same objects. ═══ wpclsRemoveObjects Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsRemoveObjects - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hwndCnr (HWND) - input Handle to the container object. pRecordArray (PVOID *) - input Pointer to an array of MINIRECORDCORE objects that are to be removed. NumRecords (ULONG) - input Number of records in pRecordArray. RemoveAll (BOOL) - input Flag indicating whether to remove all records. Possible values are described in the following list: TRUE All records in the specified container are to be removed, and the in-use list for each object is to be cleaned up. FALSE Only records specified in pRecordArray are to be removed, and the in-use list is to be cleaned up for the same objects. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsRemoveObjects - Remarks ═══ This method provides rapid removal of multiple objects from a container at one time. wpCnrRemoveObject performs the same function as this method, but it operates only on one object at a time. ═══ wpclsRemoveObjects - Usage ═══ This method can be called at any time to remove multiple objects from the container. ═══ wpclsRemoveObjects - How to Override ═══ This method is generally not overridden. ═══ wpclsRemoveObjects - Related Methods ═══  wpCnrInsertObject  wpCnrRemoveObject  wpclsInsertMultipleObjects ═══ wpclsRemoveObjects - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.41. wpclsSetError ═══ ═══ wpclsSetError - Syntax ═══ This class method sets the current error code within a class object. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ ULONG ulErrorId; /* Error code. */ BOOL rc; /* Success indicator. */ rc = _wpclsSetError(somSelf, ulErrorId); ═══ wpclsSetError Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsSetError Parameter - ulErrorId ═══ ulErrorId (ULONG) - input Error code. ═══ wpclsSetError Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE The error was successfully stored. FALSE The error was not successfully stored. ═══ wpclsSetError - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ulErrorId (ULONG) - input Error code. rc (BOOL) - returns Success indicator. TRUE The error was successfully stored. FALSE The error was not successfully stored. ═══ wpclsSetError - Remarks ═══ This method can be used when writing class methods for workplace objects that return BOOLEAN values. When a given class method fails, the class method can log its error code in the class object so that the caller can later retrieve it using the wpclsQueryError class method. The function is analogous to the WinSetErrorInfo function call that is used by Presentation Manager functions to log their error return codes. ═══ wpclsSetError - Usage ═══ It is recommended that this method be called only by all class methods when they do not execute successfully and nowhere else. ═══ wpclsSetError - How to Override ═══ Never override this class method. ═══ wpclsSetError - Related Methods ═══  wpclsQueryError ═══ wpclsSetError - Example Code ═══ This example finds all occurrences of an object type in a folder. VOID clsFindEverybody(SOMAny *self) { BOOL rc; /* Return from methods */ HFIND hFind = 0; /* Handle for repeated finds */ CLASS Class[2]; /* List of classes to look for */ OBJECT Object[10]; /* Objects returned from search */ ULONG ulCount = 10; /* Count of objects to find / or found */ WPFolder *folder = 0; /* Pointer to folder for search */ ULONG errorid = 0; /* Error returned from previous search */ CHAR sz[CCHMAXPATH]; /* Title string to look for */ PSZ title = sz; Class[0] = _WPFolder; Class[1] = NULL; /* Get the pointer to the desktop (since that is where we are looking) */ folder = _wpclsQueryFolder( _WPFolder, "", TRUE ); _wpclsSetError( _WPObject, 0 ); /* Reset the error indicators */ rc = 0; /* Attempt to find the first 10 objects matching our criteria */ ulCount = 10; rc =_wpclsFindObjectFirst(_WPObject, /* Class self pointer */ Class, /* Pointer to array of class objects */ &hFind, /* Handle for wpclsFindObjectNext */ NULL, /* Find EVERYTHING */ folder, /* Pointer to folder of interest */ TRUE, /* Search all folders in tree */ NULL, /* No extended criteria */ Object, /* Array of object pointers */ &ulCount ); /* Number requested and number found */ errorid = _wpclsQueryError( _WPObject); /* Get errorid (may still be OK) */ if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf(" _wpclsFindObjectFirst failed, errorid=%u\n", errorid ); return; } /* endif */ do { _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Look for next 10 objects */ rc =_wpclsFindObjectNext(_WPObject, /* Self */ hFind, /* Handle from previous Find */ Object, /* Objects found */ &ulCount ); /* Number to look for. On return, number found */ errorid = _wpclsQueryError( _WPObject ); if ((!rc && (errorid == WPERR_BUFFER_OVERFLOW)) || rc) { /***** Process objects found here ******/ } else { somPrintf("_wpclsFindObjectNext failed, errorid=%u\n", errorid); return; } /* endif */ } while ( errorid == WPERR_BUFFER_OVERFLOW ); /* enddo */ _wpclsSetError( _WPObject, 0 ); /* Reset error indicators */ rc = 0; /* Indicate find complete */ rc =_wpclsFindObjectEnd( _WPObject, hFind ); if (!rc) { errorid = _wpclsQueryError( _WPObject ); somPrintf( "_wpclsFindObjectEnd failed, errorid=%u\n", errorid ); return; } return; } ═══ wpclsSetError - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Example Code Related Methods Glossary ═══ 3.42. wpclsSetIcon ═══ ═══ wpclsSetIcon - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method sets the icon handle for a given object. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ HPOINTER hptrNewIcon; /* Icon handle to be set for the object. */ BOOL rc; /* Success indicator. */ rc = _wpclsSetIcon(somSelf, hptrNewIcon); ═══ wpclsSetIcon Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsSetIcon Parameter - hptrNewIcon ═══ hptrNewIcon (HPOINTER) - input Icon handle to be set for the object. ═══ wpclsSetIcon Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetIcon - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. hptrNewIcon (HPOINTER) - input Icon handle to be set for the object. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetIcon - Remarks ═══ The class default icon can be loaded using wpclsInitData and freed using wpclsUnInitData. ═══ wpclsSetIcon - Usage ═══ This method can be called at any time to set the object's default icon. ═══ wpclsSetIcon - How to Override ═══ This method is generally not overridden. ═══ wpclsSetIcon - Related Methods ═══  wpclsQueryIcon  wpQueryIcon  wpQueryIconData  wpSetIcon  wpSetIconData  wpclsQueryIcon  wpclsQueryIconData ═══ wpclsSetIcon - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.43. wpclsSetIconData ═══ ═══ wpclsSetIconData - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method sets the icon information for a given object. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PICONINFO pIconInfo; /* Pointer to the icon information structure. */ BOOL rc; /* Success indicator. */ rc = _wpclsSetIconData(somSelf, pIconInfo); ═══ wpclsSetIconData Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsSetIconData Parameter - pIconInfo ═══ pIconInfo (PICONINFO) - input Pointer to the icon information structure. ═══ wpclsSetIconData Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetIconData - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pIconInfo (PICONINFO) - input Pointer to the icon information structure. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetIconData - Usage ═══ This method can be called at any time to set icon information. ═══ wpclsSetIconData - How to Override ═══ ═══ wpclsSetIconData - Related Methods ═══  wpclsQueryIcon  wpQueryIcon  wpQueryIconData  wpSetIcon  wpSetIconData  wpclsQueryIconData ═══ wpclsSetIconData - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Related Methods Glossary ═══ 3.44. wpclsSetSetting ═══ ═══ wpclsSetSetting - Syntax ═══ This method sets the class object settings in the Settings notebook. #define INCL_WINWORKPLACE #include M_WPAbstract *somSelf; /* Pointer to the WPAbstract class object. */ PSZ pszSetting; /* Name of the setting that is to be set. */ PVOID pValue; /* Buffer which contains setting values. */ BOOL rc; /* Success indicator. */ rc = _wpclsSetSetting(somSelf, pszSetting, pValue); ═══ wpclsSetSetting Parameter - somSelf ═══ somSelf (M_WPAbstract *) - input Pointer to the WPAbstract class object. ═══ wpclsSetSetting Parameter - pszSetting ═══ pszSetting (PSZ) - input Name of the setting that is to be set. ═══ wpclsSetSetting Parameter - pValue ═══ pValue (PVOID) - input Buffer which contains setting values. ═══ wpclsSetSetting Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetSetting - Parameters ═══ somSelf (M_WPAbstract *) - input Pointer to the WPAbstract class object. pszSetting (PSZ) - input Name of the setting that is to be set. pValue (PVOID) - input Buffer which contains setting values. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetSetting - Remarks ═══ This is a virtual method and must be overridden by a subclass. Each object subclass documents the possible values for pszSetting and pValue. These settings and values are specific for each subclass. Note that all settings have safe defaults, so it is never necessary to pass unnecessary settings to an object. For a list of settings and their associated values, see the individual classes. ═══ wpclsSetSetting - Usage ═══ This method should never be called. It is a virtual method and must be overridden by a subclass. ═══ wpclsSetSetting - How to Override ═══ This is a virtual method and must be overridden by a subclass. ═══ wpclsSetSetting - Related Methods ═══  wpclsSetSetting ═══ wpclsSetSetting - Topics ═══ Select an item: Syntax Parameters Returns Remarks How to Override Usage Related Methods Glossary ═══ 3.45. wpclsSetSettingsPageSize ═══ ═══ wpclsSetSettingsPageSize - Syntax ═══ This method is specific to version 3, or higher, of the OS/2 operating system. This class method returns the default Settings page size. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ PSIZEL pSizel; /* Pointer to the structure containing the default width and height of the Settings page. */ BOOL rc; /* Success indicator. */ rc = _wpclsSetSettingsPageSize(somSelf, pSizel); ═══ wpclsSetSettingsPageSize Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsSetSettingsPageSize Parameter - pSizel ═══ pSizel (PSIZEL) - input Pointer to the structure containing the default width and height of the Settings page. ═══ wpclsSetSettingsPageSize Return Value - rc ═══ rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetSettingsPageSize - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. pSizel (PSIZEL) - input Pointer to the structure containing the default width and height of the Settings page. rc (BOOL) - returns Success indicator. TRUE Successful completion. FALSE Error occurred. ═══ wpclsSetSettingsPageSize - How to Override ═══ This method is generally not overridden. ═══ wpclsSetSettingsPageSize - Topics ═══ Select an item: Syntax Parameters Returns How to Override Glossary ═══ 3.46. wpclsUnInitData ═══ ═══ wpclsUnInitData - Syntax ═══ This method is called to allow the class object to free allocated resources. #define INCL_WINWORKPLACE #include M_WPObject *somSelf; /* Pointer to the WPObject class object. */ wpclsUnInitData(somSelf); ═══ wpclsUnInitData Parameter - somSelf ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. ═══ wpclsUnInitData - Return Value ═══ There is no return value for this method. ═══ wpclsUnInitData - Parameters ═══ somSelf (M_WPObject *) - input Pointer to the WPObject class object. There is no return value for this method. ═══ wpclsUnInitData - Usage ═══ This method is generally called only by the system when the class object is made dormant. The class object is made dormant when the last instance of this class is made dormant. ═══ wpclsUnInitData - How to Override ═══ Any class that overrides the wpclsInitData method to allocate resources for its metaclass instance variables should override this method to deallocate those resources. It is essential to pass this method onto the parent class object after performing override processing. ═══ wpclsUnInitData - Related Methods ═══  wpclsInitData ═══ wpclsUnInitData - Example Code ═══ This example overrides the method to free any data associated with the class. SOM_Scope void SOMLINK BearsM_wpclsUnInitData(M_Bears *somSelf) { APIRET rc = NO_ERROR; /* Return code from Dos API */ M_BearsData *somThis = M_BearsGetData(somSelf); M_BearsMethodDebug("M_Bears","myfM_wpclsUnInitData"); rc = DosFreeMem( _pBearClassData ); parent_wpclsUnInitData(somSelf); } ═══ wpclsUnInitData - Topics ═══ Select an item: Syntax Parameters Returns How to Override Usage Example Code Related Methods Glossary