Latest report...
Presently assuming a horizontal line glitch on login window means corrupt kext/boot cache + corrupt prefs. A boot with a clean login screen is a good start.
In fixing the archive/install, I have enabled the root user.
http://support.apple.com/kb/ht1528
The root user logs in with less frequent desktop corrupt line than normal user. Safeboot never logs in with desktop corrupt line.
Present theory looks like this:
1. Initial problem triggered by overheating - clogged fans, bad thermal paste, bad ATI driver
2. Corruption spreads though prefs files, esp those that load/write PRAM. First stage may be glitched desktop horizontal line artefact.
3. Worse corruption spreads through boot/kext caches.
4. Corruption in prefs spreads to window-drawing memory eventually causing graphics window glitches, hangs, freezes.
If corruption is present on login screen or worse problems and crashing, suggest deep clean and reapply latest system combo update.
DEEP CLEAN (first download and install AppleJack
http://applejack.sourceforge.net/)
1. shutdown
2. reset SMC (on MBP: remove power and battery then hold power button for 5 seconds)
3. startup
4. zap PRAM (hold cmd-opt-P-R when booting until the system chimes a second time)
5. single user boot (cmd-S while booting)
6. # applejack AUTO shutdown
7. safeboot (hold shift while booting)
REPLACE SUSPECT RESOURCES - minimal fix (if problems persist, archive/install from MacOS DVD)
1. Run latest OSComboUpater
2. Run latest SecurityUpdate (optional if an archive/install not done)
3. Enable root user
DELETE CORRUPT PREFERENCE FILES - start here if corruption of desktop on login
1. Login as root - if login screen is clean, continue, else try this step first and reboot
2. To show hidden files to delete, in the Terminal copy/paste (I have put these commands in a shell script file since I seem to have to run it a lot):
$ defaults write com.apple.finder AppleShowAllFiles TRUE
$ killall Finder
To revert back if desired:
$ defaults write com.apple.finder AppleShowAllFiles FALSE
$ killall Finder
3. Open windows in list view and sort by reverse date (newest last):
a. {user-root-home}/Library/Preferences
b. /Library/Preferences
c. {other users} /Library/Preferences
(NOTE I presently think prefs in /SystemConfiguration are OK. loginwindow.plist may be OK, not sure)
Delete these files if present - definitely need to get rid of the hidden files:
.GlobalPreferences.plist
com.apple.loginwindow.plist
com.apple.BezelServices.plist
com.apple.systemuiserver.plist
Also in Preferecnes/ByHost
.GlobalPreferences.plist.....
maybe:
com.apple.spotlight.plist
com.apple.finder.plist
In resolving the desktop horizontal line glitch, I have been deleting prefs, logging out and logging in again. Anything with a recent modification date is suspect. When I can login as root 4 consecutive times with a clean desktop, everything seems OK. Then login as user, also repeat a few times. It appears for the prefs than are common to /Library and {users}/Library, both need to be deleted at the same time and suggest deleting /Library one first, since it may be used to replicate the user versions. Repetitive clean login suggests prefs are good.
I did see one transient glitch in text (tearing artefact) writing this, which suggests I may have left out an earlier step. More later....