en:docs:fapi:viogetconfig

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
en:docs:fapi:viogetconfig [2021/08/20 08:58] – created prokusheven:docs:fapi:viogetconfig [2021/09/19 05:21] (current) prokushev
Line 1: Line 1:
 {{page>en:templates:fapiint}} {{page>en:templates:fapiint}}
 +
 +====== VioGetConfig ======
  
 This call returns the video display configuration. This call returns the video display configuration.
  
-==Syntax==+===== Syntax ===== 
 +<code c>
  VioGetConfig (ConfigID, ConfigData, VioHandle)  VioGetConfig (ConfigID, ConfigData, VioHandle)
 +</code>
 +===== Parameters =====
  
-==Parameters== +  * ConfigID ([[USHORT]]) - input: Identifies for which display configuration information is being requested: 
-;ConfigID (USHORT) - input: Identifies for which display configuration information is being requested: +    0 - Current configuration 
-::0 - Current configuration +    1 - Primary configuration 
-::1 - Primary configuration +    2 - Secondary configuration
-::2 - Secondary configuration +
-:For OS/2 1.2, when ConfigID = 0, the current configuration is returned rather than the primary configuration (as was returned in OS/2 1.0 and 1.1). This change makes the OS/2 mode version of VioGetConfig match the family API version that has returned the current configuration starting with OS/2 1.0. OS/2 1.0 and 1.1 applications that issued VioGetConfig to determine the display configuration benefit from this change. The application can run on the configuration selected by the operator (by issuing the MODE command before invoking the application) rather than switching away from the operator selected display. +
-;ConfigData (P[[VIOCONFIGINFO]]) - output: Address of structure where the display configuration is returned. +
-;VioHandle (HVIO) - input : This must be zero unless the caller is a Presentation Manager application, in which case it must be the value returned by VioGetPs.+
  
-==Return Code== +For OS/2 1.2, when ConfigID = 0, the current configuration is returned rather than the primary configuration (as was returned in OS/2 1.0 and 1.1). This change makes the OS/2 mode version of VioGetConfig match the family API version that has returned the current configuration starting with OS/2 1.0. OS/2 1.0 and 1.1 applications that issued VioGetConfig to determine the display configuration benefit from this change. The application can run on the configuration selected by the operator (by issuing the MODE command before invoking the application) rather than switching away from the operator selected display. 
-;rc (USHORT) - return:Return code descriptions are: + 
-*0 NO_ERROR +  * ConfigData ([[PVIOCONFIGINFO]]) - output: Address of structure where the display configuration is returned. 
-*421 ERROR_VIO_INVALID_PARMS +  * VioHandle ([[HVIO]]) - input : This must be zero unless the caller is a Presentation Manager application, in which case it must be the value returned by VioGetPs. 
-*436 ERROR_VIO_INVALID_HANDLE + 
-*438 ERROR_VIO_INVALID_LENGTH +===== Return Code ===== 
-*465 ERROR_VIO_DETACHED+ 
 +rc ([[USHORT]]) - return 
 + 
 +Return code descriptions are: 
 + 
 +  *0 NO_ERROR 
 +  *421 ERROR_VIO_INVALID_PARMS 
 +  *436 ERROR_VIO_INVALID_HANDLE 
 +  *438 ERROR_VIO_INVALID_LENGTH 
 +  *465 ERROR_VIO_DETACHED 
 + 
 +===== Remarks =====
  
-==Remarks== 
 The values returned may not be correct if the adapter cannot be properly identified by the Base Video Handler (BVH) selected at system installation time. It can also be incorrect if the physical setup does not match that indicated by the presence of the adapter or by adapter switches. For example, it is impossible to detect the absence of a display on a CGA or the display attached to an EGA, despite the setup switches. The values returned may not be correct if the adapter cannot be properly identified by the Base Video Handler (BVH) selected at system installation time. It can also be incorrect if the physical setup does not match that indicated by the presence of the adapter or by adapter switches. For example, it is impossible to detect the absence of a display on a CGA or the display attached to an EGA, despite the setup switches.
  
-==Bindings== +===== Bindings ===== 
-===C=== + 
-<PRE>+==== C ===
 + 
 +<code c>
 typedef struct _VIOCONFIGINFO {  /* vioin  */ typedef struct _VIOCONFIGINFO {  /* vioin  */
   USHORT  cb     ;               /* Length of this data structure */   USHORT  cb     ;               /* Length of this data structure */
Line 54: Line 67:
  
 USHORT           rc;            /* return code */ USHORT           rc;            /* return code */
-</PRE>+</code>
  
-===MASM=== +====MASM==== 
-<PRE>+<code asm>
 VIOCONFIGINFO struc VIOCONFIGINFO struc
   vioin_cb            dw  ? ;Length of this data structure   vioin_cb            dw  ? ;Length of this data structure
Line 82: Line 95:
  
 Returns WORD Returns WORD
-</PRE>+</code>