Skip to content
forked from markd2/GrafDemo

A little demo program showing off various Core Graphics features.

Notifications You must be signed in to change notification settings

GTMYang/GrafDemo

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GrafDemo

A little demo program showing off various Core Graphics features. It's a sample program for a set of posts over at the Big Nerd Ranch blog:

Here are some other, possibly interesting, CG-related blog posts:

Digital Dashboard

Behold the main menu it all of its glory:

For the demo windows, the left-hand view is implemented in Objective-C, the right-hand view is implemented in Swift, and the window controllers alternate ObjC and Swift implementations.

Simple

Simple is a view that shows basic drawing, as well as GState hygiene. The "Sloppy" toggle turns off some GState management, showing attribute settings leak out in other method's drawing.

Lines

Here are things related to lines. End caps, line joins, drawing mechanisms, and line phases.

Paths

A sampler of the different path component calls. Click and drag the control points to see how they behave.

Arcs

The plethora of "arc" calls are confusing. Here they are with influence lines and tweakable settings.

Transforms

Transformations are a-fine thing.

PostScript

A bit of history - Core Graphics is based on the PostScript drawing model. CG also includes a full postscript interpreter. This window lets you enter code and run it. Worst IDE Evar.

Interesting Docs

About

A little demo program showing off various Core Graphics features.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Objective-C 74.9%
  • Swift 25.1%