Community
Participate
Working Groups
This thread is an extension of https://bugs.eclipse.org/bugs/show_bug.cgi?id=424141. The task is quite easy simply fill a canvas inside a window with objects and don't care about them. If the window is resized or other windows being dragged over the "canvas window" forcing redraw and paintControl method to be executed and resulting in an inconsistent scene: Don't care, just continue filling the canvas. I used the method in the thread linked above to create the two uploaded screencasts: SWT_RWT_GC_incompatible.mp4 and RWT_Patched_Version.mp4. I thought modifying GCOperationWriter will do the job but what I actually did was preventing the json array from being cleared. Leading in a stall at around 1000 operations. So I started patching the javascript client in a very naive way. You can see that in RWT_Patched_Version.mp4: After a resize the canvas will be scaled rather than resized but it showes the incompatibility: With the current implementation we will never be able to place more than 1000 individual objects on a canvas. The canvas example the RAP Team provided (http://rap.eclipsesource.com/rapdemo/examples#canvas) shows the same weakness: All objects being placed are kept inside a container. But this approach does not make sense if we dont care about the objects or if there are just too much and we simply want an object model to be visualized. I think in the sense of single sourcing (SWT~RWT) it is important to adapt the behaviour to the one real SWT provides. Since there are probably applications that rely on the feature of an always cleared canvas-gc-scene it would be ideal to have a simple switch allowing the developer to use RWTs current behaviour and the one provided by SWT. Kind regards Daniel
Created attachment 238967 [details] Problem visualization
Created attachment 238968 [details] Requirement visualization
The RWT side example (browser) will fill both big rectangualar areas with colored rectangles and not as desired (see SWT side example (normal window)) the right one with black rectangles only. This is caused instantiating the GC outside the run method: https://bugs.eclipse.org/bugs/show_bug.cgi?id=424141#c1 (first comment). In RWT_Patched_Version.mp4 after refreshing the browser you'll see the same behaviour as in the unpatched version: The browser is given time to get/set all size contraints.
(In reply to Daniel Keck from comment #2) > Created attachment 238968 [details] > Requirement visualization It seems only VLC Player will show the screencasts without errors. E.g. Quicktime will show only a green screen for almost the half of the video.