From bc83464b642caad491c70e3b54677dd50f6324b2 Mon Sep 17 00:00:00 2001 From: Manolo Gouy Date: Fri, 12 Feb 2016 11:49:32 +0000 Subject: Add Fl_Shared_Image *Fl_Image_Surface::highres_image() to draw into high-resolution bitmap. This new member function returns a high resolution bitmap image scaled to the adequate drawing size. This allows to create a bitmap image able to fill all pixels of a high resolution display. This is functional only for the Mac OS platform. On other platforms, the new member function returns an unscaled bitmap. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11158 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- test/device.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/device.cxx b/test/device.cxx index a1c83a53f..c0fec4a1e 100644 --- a/test/device.cxx +++ b/test/device.cxx @@ -563,13 +563,13 @@ void copy(Fl_Widget *, void *data) { H = target->h(); decorated = 0; } - rgb_surf = new Fl_Image_Surface(W, H); + rgb_surf = new Fl_Image_Surface(W, H, 1); rgb_surf->set_current(); if (decorated) rgb_surf->draw_decorated_window(target->as_window()); else rgb_surf->draw(target); - Fl_Image *img = rgb_surf->image(); + Fl_Image *img = rgb_surf->highres_image(); delete rgb_surf; Fl_Display_Device::display_device()->set_current(); Fl_Window* g2 = new Fl_Window(img->w()+10, img->h()+10); -- cgit v1.2.3