National Instruments 320685D-01 Drums User Manual


 
Chapter 6 Building Multiplatform Applications
©
National Instruments Corporation 6-3 LabWindows/CVI Programmer Reference Manual
Externally Compiled Modules
Although you can use externally compiled modules in LabWindows/CVI as this manual
describes, the best medium for application portability is ANSI C source code. Object modules
are not directly portable from one platform to another because the object file formats on the
various platforms differ.
For example, the object file formats are different among Windows 3.1, Windows 95/NT, and
UNIX systems. Although SPARCstations have the same computer architecture, Solaris 1.x
(Sun OS 4.x) and Solaris 2.x also use different object file formats that make object modules
non-portable even between these two systems.
To use an externally compiled module across platforms, you must recompile the source code
for the module with a compiler for the target system.
Multiplatform User Interface Guidelines
Function panel (.fp) files are portable across platforms.
User Interface Resource (
.uir) files are portable across platforms.
Image file formats other than PCX (
.pcx) are not portable.
Color hue and intensity differences between platforms are unavoidable.
The only fonts sure to be available on all platforms are the National Instruments fonts.
National Instruments fonts of the same name resemble each other stylistically from one
platform to another, although some relative size differences might exist. The National
Instruments Meta Fonts are of uniform size (height) relative to the rest of the user interface
and are the most portable family of fonts available. However, the width of the National
Instruments Meta Fonts might differ slightly from one platform to another. Allow for extra
space in the width of all control labels to assure consistent appearance.
You might find the User Interface library functions
GetCtrlBoundingRect,
GetTextDisplaySize, and GetScreenSize useful in calculating and compensating for
font-size discrepancies between platforms.
The order in which LabWindows/CVI processes user interface events might differ between
Windows and UNIX platforms. This happens because of differences between the underlying
window management systems that LabWindows/CVI uses.
You must not assign the forward <Delete> key as a hot-key in your user interface, because
that key does not exist on all platforms.
00ProRef.book : 06chap06.fm Page 3 Monday, March 9, 1998 3:23 PM