After experimenting with a modified cairo_test program that draws both with
cairo and with regular FLTK drawing functions to the same window, it seems
necessary to control for possible changes to the graphics context made by
cairo in Fl_Cocoa_Window_Driver::make_current() rather than in
cairo_create_surface().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13119 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Discussion "Screen buffer flipped in OSX Mojave running 1.4.x"
in fltk.general,
http://www.fltk.org/newsgroups.php?s36913+gfltk.general+v36915
describes a Cairo-using FLTK app that runs well after this modification.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13115 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Thus, Fl_cocoa.mm is completely independent from code of libfltk_gl.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13104 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
The problem was visible with test/mandelbrot and with layer-backed views.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13100 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Fl_Gl_Window_Driver::invalidate() instead of Fl_Gl_Window::invalidate() was called.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13091 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Part of the fix applies both to layer-backed and non layer-backed windows.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13090 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
The doc recommends to draw views with the displayLayer: method when the view manages itself
completely its own bitmap:
If your delegate implements the displayLayer: method, that implementation is responsible
for creating a bitmap and assigning it to the layer’s contents property.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13075 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This patch fixes two aspects described in STR #3119:
(a) enables detection and prefers pixel formats with composition
(b) selects no more than 32 bit colors (8 bits per pixel)
(a) was the reason for this STR, (b) was reported repeatedly in
fltk.general (see STR #3119).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13072 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
MacOS apps running under 10.14 AND linked with SDK 10.14 use a completely different way
to draw to the screen in comparison with the same app running under 10.13 or earlier:
all views are "layer-backed".
This commit makes FLTK apps running under 10.14 and linked with SDK 10.14 explicitly
use layers to draw to the screen.
FLTK apps remain downward compatible with earlier macOS versions.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13071 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
error: non-constant-expression cannot be narrowed from type 'int' to 'CGFloat'
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13070 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This is a working version of makesrcdist and "commandline compatible" with the
previous svn version.
Todo: There will likely be more or other commandline arguments to be more flexible
when building source tarballs or snapshots.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13069 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
The problem was visible with test/cube: when the window was minimized, only the left GL subwindow
was captured in the window icon.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13066 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Window capture by initWithFocusedViewRect: does not work if the app is linked against 10.14 SDK
and run under 10.14. In that case, capture is performed instead by CGWindowListCreateImage().
Detection of whether the app was linked against 10.14 SDK is done by checking whether
the FLView possesses a CALayer.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13062 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
The regression was detected by "FLTK 1.4 on macOS: Trouble compiling my Application with Makefile"
in fltk.general.
The fix is to have unbundled apps initialize under MacOS 10.13 as under earlier OS,
thus the new initialization procedure introduced for 10.13 is for bundled apps only.
Tested OK on 10.13.6 and 10.14 public beta 10.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13050 ea41ed52-d2ee-0310-a9c1-e6b18d33e121