summaryrefslogtreecommitdiff
path: root/src/Fl_Copy_Surface.cxx
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2016-01-10 19:08:16 +0000
committerManolo Gouy <Manolo>2016-01-10 19:08:16 +0000
commiteeb65bef23b2d269ea38474c04a55ffca5c6e63e (patch)
treee00061d0a9dfd7b28e031b1f976ae31c852fac39 /src/Fl_Copy_Surface.cxx
parentacc50806538da470ba18a2f7b76ea65a64cb5f5c (diff)
1) Replicate in branch-1.3-porting all recent changes of branch-1.3
2) Advance branch-1.3-porting with new function Fl_X::capture_titlebar_and_borders() that contains all the platform-specific code of all operations related to drawing window borders and title bars. What is platform-specific and what is not is therefore much clearer, to ease porting. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11002 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Copy_Surface.cxx')
-rw-r--r--src/Fl_Copy_Surface.cxx14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/Fl_Copy_Surface.cxx b/src/Fl_Copy_Surface.cxx
index 1f0b654c5..a0b942b67 100644
--- a/src/Fl_Copy_Surface.cxx
+++ b/src/Fl_Copy_Surface.cxx
@@ -89,7 +89,7 @@ Fl_Copy_Surface::Fl_Copy_Surface(int w, int h) : Fl_Surface_Device(NULL)
int vdots = GetDeviceCaps(hdc, VERTRES);
ReleaseDC(NULL, hdc);
float factorw = (100. * hmm) / hdots;
- float factorh = (100. * vmm) / vdots + 0.5;
+ float factorh = (100. * vmm) / vdots;
RECT rect; rect.left = 0; rect.top = 0; rect.right = w * factorw; rect.bottom = h * factorh;
gc = CreateEnhMetaFile (NULL, NULL, &rect, NULL);
@@ -217,20 +217,10 @@ void Fl_Copy_Surface::prepare_copy_pdf_and_tiff(int w, int h)
#endif // __APPLE__
-#if !defined(__APPLE__)
-/** Copies a window and its borders and title bar to the clipboard. */
void Fl_Copy_Surface::draw_decorated_window(Fl_Window* win, int delta_x, int delta_y)
{
-#if defined(WIN32)
- helper->draw_decorated_window(win, delta_x, delta_y, this);
-#elif defined(__APPLE__)
-#elif defined(FL_PORTING)
-# pragma message "FL_PORTING: do you want to draw a window border around a printout"
-#else
- helper->draw_decorated_window(win, delta_x, delta_y, this);
-#endif
+ helper->draw_decorated_window(win, delta_x, delta_y);
}
-#endif
#if defined(WIN32)
#elif defined(__APPLE__)