plotting a trace using cairo