GetNearestColor function Null safety gdi32

int GetNearestColor(
  1. int hdc,
  2. int color

The GetNearestColor function retrieves a color value identifying a color from the system palette that will be displayed when the specified color value is used.

COLORREF GetNearestColor(
  HDC      hdc,
  COLORREF color


int GetNearestColor(int hdc, int color) {
  final _GetNearestColor = _gdi32.lookupFunction<
      Uint32 Function(IntPtr hdc, Uint32 color),
      int Function(int hdc, int color)>('GetNearestColor');
  return _GetNearestColor(hdc, color);