Copying graphics contexts
Copy graphics context attributes to another GC using copyGC:dest:. The following example creates a GC, sets its foreground and background attributes, and then copies these attributes to a new GC.
| oldGC newGC |
oldGC := CgWindow default
createGC: None
values: nil.
oldGC
setForeground: CgWindow default blackPixel;
setBackground: CgWindow default whitePixel.
newGC := CgWindow default
createGC: None
values: nil.
oldGC
copyGC: GCForeground | GCBackground
dest: newGC
Last modified date: 01/29/2015