diff -Nurd octave-3.2.4.orig/src/display.cc octave-3.2.4/src/display.cc --- octave-3.2.4.orig/src/display.cc 2009-08-13 01:56:02.000000000 -0400 +++ octave-3.2.4/src/display.cc 2011-08-30 15:15:37.000000000 -0400 @@ -26,13 +26,7 @@ #include -#if defined (OCTAVE_USE_WINDOWS_API) -#include -#elif defined (HAVE_FRAMEWORK_CARBON) -#include -#elif defined (HAVE_X_WINDOWS) #include -#endif #include "display.h" #include "error.h" @@ -44,52 +38,6 @@ { if (query) { -#if defined (OCTAVE_USE_WINDOWS_API) - - HDC hdc = GetDC (0); - - if (hdc) - { - dp = GetDeviceCaps (hdc, BITSPIXEL); - - ht = GetDeviceCaps (hdc, VERTRES); - wd = GetDeviceCaps (hdc, HORZRES); - - double ht_mm = GetDeviceCaps (hdc, VERTSIZE); - double wd_mm = GetDeviceCaps (hdc, HORZSIZE); - - rx = wd * 25.4 / wd_mm; - ry = ht * 25.4 / ht_mm; - } - else - warning ("no graphical display found"); - -#elif defined (HAVE_FRAMEWORK_CARBON) - - CGDirectDisplayID display = CGMainDisplayID (); - - if (display) - { - dp = CGDisplayBitsPerPixel (display); - - ht = CGDisplayPixelsHigh (display); - wd = CGDisplayPixelsWide (display); - - CGSize sz_mm = CGDisplayScreenSize (display); - - // On modern Mac systems (>= 10.5) CGSize is a struct keeping 2 - // CGFloat values, but the CGFloat typedef is not present on - // older systems, so use double instead. - double ht_mm = sz_mm.height; - double wd_mm = sz_mm.width; - - rx = wd * 25.4 / wd_mm; - ry = ht * 25.4 / ht_mm; - } - else - warning ("no graphical display found"); - -#elif defined (HAVE_X_WINDOWS) const char *display_name = getenv ("DISPLAY"); @@ -124,11 +72,6 @@ } else warning ("X11 DISPLAY environment variable not set"); -#else - - warning ("no graphical display found"); - -#endif } }