[lazarus] Troubles implementing TScreen

Marc Weustink Marc.Weustink at cuperus.nl
Tue Feb 29 06:30:56 EST 2000


+ From: Hongli Lai [mailto:hongli at telekabel.nl]
+
+ I'm trying to implement TScreen, but I encountered a problem.
+ Lazarus is designed to be platform and widget independend.
+ But when I try to implement TScreen.Height and TScreen.Width,
+ I need to access GDK functions. I can also access Xlib
+ functions, but X is not available in
+ Win32 and some others OSses. What shall I do?

Look at the API function GetSystemMetrics(SM_CXSCREEN). Most times you can
safe call the API functions. They are made platform independent.

In most cases (if not all) you don't need access to GDK XLib or whetever
platform dependent libs. This access is handle by the Interface objects and
or WINAPI

Marc







More information about the Lazarus mailing list