implemented parts of graphics