anchor.diff:  
   (defpackage :mezzano.gui.memory-monitor
     (:use :cl :mezzano.gui.font)
  -  (:export #:spawn))
  +  (:export #:spawn)
  +  (:local-nicknames (:gui :mezzano.gui)
  +                    (:comp :mezzano.gui.compositor)
  +                    (:sync :mezzano.sync)
  +                    (:sup :mezzano.supervisor)
  +                    (:int :mezzano.internals)))
   
   (in-package :mezzano.gui.memory-monitor)
  +
  +(defclass graph-sampler ()
  +  ((%sample-function :initarg :function :reader sampler-function)
  +   (%colour :initarg :colour :reader sampler-colour)
  +   (%name :initarg :name :reader sampler-name)
  +   (%history :initform nil :accessor sampler-history)
  +   (%scale :initarg :scale :accessor sampler-scale)
  +   (%autoscale :initform 0 :accessor sampler-autoscale)
  +   (%last-scale :initform 0 :accessor sampler-last-scale))
  +  (:default-initargs :scale nil))
   
   (defclass memory-monitor ()
     ((%frame :initarg :frame :accessor frame)
      (%window :initarg :window :accessor window)
  -   (%fifo :initarg :fifo :accessor fifo)))
  +   (%fifo :initarg :fifo :accessor fifo)
  +   (%mode :initarg :mode :accessor mode)
  +   (%samplers :initarg :samplers :accessor samplers)
  +   (%graph-column :initform 0 :accessor graph-column)))
   
   (defgeneric dispatch-event (app event)
     (:method (f e)))
  
positive.code:                 (#x100 (mezzano.gui:make-colour-from-octets 121 121 121)) ; other
                  (t (mezzano.gui:make-colour 1 1 1)))))))) ; mixed
  
  (defun main (open-width open-height)
    (with-simple-restart (abort "Close memory monitor")
      (catch 'quit
  
negative.code: (defmethod dispatch-event (app (event mezzano.gui.compositor:key-event))
    (when (not (mezzano.gui.compositor:key-releasep event))
      (let* ((ch (mezzano.gui.compositor:key-key event)))
        (cond ((char-equal ch #\P)
               (setf (mode app) :physical-visualizer)
               (throw 'redraw nil))
              ((char-equal ch #\G)
               (setf (mode app) :graphs)
               (throw 'redraw nil))
              ((char-equal ch #\Space)
               ;; refresh current window
               (throw 'redraw nil))))))
  
  