diff options
| author | Manolo Gouy <Manolo> | 2016-02-12 11:49:32 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2016-02-12 11:49:32 +0000 |
| commit | bc83464b642caad491c70e3b54677dd50f6324b2 (patch) | |
| tree | 8bf8b6c7701423c40ba6e2290c89879600c8676a /test/device.cxx | |
| parent | 50ee3bcd66c4baa6bb3388f5b955d726bfc6bdd8 (diff) | |
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
Diffstat (limited to 'test/device.cxx')
| -rw-r--r-- | test/device.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
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); |
