Documented segment.py. Progress on frameelt.py (the last remaining)