Return the type of frames on TERMINAL.
TERMINAL may be a terminal id, a display name or a frame. If it
is a frame, its type is returned. If TERMINAL is omitted or nil,
it defaults to the selected frame's terminal device. All frames
on a given display are of the same type.