HC_Show_Device_Info

void HC_Show_Device_Info(char const *driver, char const *item, char *data)
void HC_Show_Device_Info(char const driver, char const item, char data)

Returns selected information about the physical device.

Occasionally, a program needs to know something specific about the graphical device it is running on. For example, it might need the number of available colors in order to know how to allocate them efficiently. Or it might require the screen resolution so as to judge how much detail to present, or it might need to be able to figure the true physical size of figures on the screen.

If the device cannot be started up before the inquiry is performed, see the note below.

If item is not applicable to the device represented by driver - for example, the number of pixels on a pen plotter - a blank or null string is returned.

The choices for item are as follows:

“yes” if the device has been started and it appears to be in working order, otherwise “no”.

This command differs from Show_Driver_Options() in that these characteristics cannot be modified by the program.

If the device is not started - i.e., if at least one update has not been done (via Get_Selection() , etc.) - Show_Device_Info() will force a call to Update_Display() in the hopes of acquiring a device it can show information about. An exception is if you’re asking whether the device exists yet (see “exists” above), no update is forced. You have to be wary of this extra update if Show_Device_Info() is called early in your initialization and your driver options (“subscreen” or “use window ID”, for example) have not been set up yet by your program. If this is a problem, just set window visibility off in the appropriate driver, which is most commonly “?picture” - Show_Device_Info() will be able to do its update but nothing will be drawn on the user’s screen.

Options that return the number of objects drawn in the last update are supported by the OpenGL driver only.

HC_Set_Driver_Options, HC_Set_Window, HC_Show_Font_Info, HC_Set_Rendering_Options.

Parameters

driver: The name of a segment that has a device driver attribute. Often “?Picture”.

item: The type of information to be returned by this call. Uppercase versus lowercase doesn’t matter.

data: The value of item for driver. Numeric values are returned as their alphanumeric equivalents. Returned to user. Passed by reference always.