Mercurial > mxe-octave
comparison src/gnuplot-1-fixes.patch @ 6305:5c4b89a8328d
* src/gnuplot-1-fixes.patch: update patch for updated wxwidgets
author | John Donoghue <john.donoghue@ieee.org> |
---|---|
date | Sun, 10 Jul 2022 20:22:15 -0400 |
parents | 188f45ec88b1 |
children |
comparison
equal
deleted
inserted
replaced
6304:c2b696402a1e | 6305:5c4b89a8328d |
---|---|
228 - PANGOCAIRO_LIBS := $(shell $(PKG_CONFIG) --libs glib-2.0 gobject-2.0 pangocairo cairo | sed s_-Lc:_-L/c_g) | 228 - PANGOCAIRO_LIBS := $(shell $(PKG_CONFIG) --libs glib-2.0 gobject-2.0 pangocairo cairo | sed s_-Lc:_-L/c_g) |
229 + PANGOCAIRO_LIBS := $(shell $(PKG_CONFIG) --libs glib-2.0 gobject-2.0 pangocairo cairo pangowin32 --static | sed s_-Lc:_-L/c_g) | 229 + PANGOCAIRO_LIBS := $(shell $(PKG_CONFIG) --libs glib-2.0 gobject-2.0 pangocairo cairo pangowin32 --static | sed s_-Lc:_-L/c_g) |
230 CAIRO_OBJS := gp_cairo.$(O) gp_cairo_helpers.$(O) | 230 CAIRO_OBJS := gp_cairo.$(O) gp_cairo_helpers.$(O) |
231 TERMFLAGS += $(PANGOCAIRO_CFLAGS) | 231 TERMFLAGS += $(PANGOCAIRO_CFLAGS) |
232 endif | 232 endif |
233 diff -ur gnuplot-5.2.8.orig/src/wxterminal/wxt_gui.cpp gnuplot-5.2.8/src/wxterminal/wxt_gui.cpp | |
234 --- gnuplot-5.2.8.orig/src/wxterminal/wxt_gui.cpp 2022-07-07 14:55:37.393547149 -0400 | |
235 +++ gnuplot-5.2.8/src/wxterminal/wxt_gui.cpp 2022-07-07 15:00:56.929423748 -0400 | |
236 @@ -632,9 +632,9 @@ | |
237 | |
238 RECT rect; | |
239 rect.left = rect.top = 0; | |
240 - unsigned dpi = GetDPI(); | |
241 - rect.right = MulDiv(panel->plot.device_xmax, dpi, 10); | |
242 - rect.bottom = MulDiv(panel->plot.device_ymax, dpi, 10); | |
243 + wxSize dpi = GetDPI(); | |
244 + rect.right = MulDiv(panel->plot.device_xmax, dpi.GetWidth(), 10); | |
245 + rect.bottom = MulDiv(panel->plot.device_ymax, dpi.GetHeight(), 10); | |
246 HDC hmf = CreateEnhMetaFileW(NULL, fullpathFilename.wc_str(), &rect, NULL); | |
247 // The win32_printing surface makes an effort to use the GDI API wherever possible, | |
248 // which should reduce the file size in many cases. | |
249 @@ -700,12 +700,12 @@ | |
250 panel->plot.cr = cairo_create(surface); | |
251 // scale the plot according to the ratio of printer and screen dpi | |
252 wxSize ppi = wxdc->GetPPI(); | |
253 - unsigned dpi = 96; | |
254 + wxSize dpi(96,96); | |
255 #ifdef _WIN32 | |
256 dpi = GetDPI(); | |
257 #endif | |
258 - double scaleX = ppi.GetWidth() / (double) dpi; | |
259 - double scaleY = ppi.GetHeight() / (double) dpi; | |
260 + double scaleX = ppi.GetWidth() / (double) dpi.GetWidth(); | |
261 + double scaleY = ppi.GetHeight() / (double) dpi.GetHeight(); | |
262 cairo_surface_set_fallback_resolution(surface, ppi.GetWidth(), ppi.GetHeight()); | |
263 cairo_scale(panel->plot.cr, | |
264 scaleX / panel->plot.oversampling_scale, |