Converts from real-world dimensions to pixels
Format
#include <Xm/XmP.h> XmImportOperator XmeToHorizontalPixelsWidget widgetint offsetXtArgVal *value
DESCRIPTION
XmeToHorizontalPixels converts a horizontal distance from a real-world dimensional unit (such as thousandths of an inch) to pixels. This conversion is based on the horizontal resolution of the screen. The choice of real-world dimensional unit is stored in the XmNunitType resource.
For example, suppose that widget has an XmNunitType resource value of Xm1000TH_INCHES. If the input value were 2000 (meaning 2000/1000 inches or 2 inches), then XmeToHorizontalPixels determines how many horizontal pixels fall within 2 inches. Because different screens have different resolutions, the returned value might be 160 pixels on one screen and 200 pixels on another.
XmeToHorizontalPixels is an XmImportProc.
Typically, your widget will call this function from a synthetic resource record.
RETURN
Returns one of the following XmImportOperator values:
Motif's synthetic resource mechanism is typically the caller of XmeToHorizontalPixels. Therefore, if XmeToHorizontalPixels returns XmSYTHETIC_LOAD, Motif synthetic resource mechanism will take care of copying (and casting) value into the resource symbolized by offset.
RELATED
XmeFromHorizontalPixels(3), XmeFromVerticalPixels(3), and XmeToVerticalPixels(3).