Next: , Previous: Balloon style files, Up: Inner workings   [Contents][Index]


12.5 Printing in TTY with KMS

Since Linux VT (TTY) does not have capabilities for returning the position of the cursor, the screen must always be cleared before printing the ponies to make sure the pony’s colours is not lost, i.e. reduced to mare 16 colours, during print. The colours are reduced if the pony’s position on the screen is changed. This is only relevant with KMS support. The clear the screen we print “\e[H\e[2J” (\e is ESC) in at beginning. “\e[H” places the cursor at the beginning of the screen, and “\e[2J” clears everything on the screen after, and including at, the cursor. If we would use “\ec” (that is a reset), we would also turn off num. lock and caps. lock.