LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Is the terminal in gui mode a pesuoterminal? (https://www.linuxquestions.org/questions/linux-newbie-8/is-the-terminal-in-gui-mode-a-pesuoterminal-4175596923/)

luofeiyu 01-06-2017 10:34 AM

Is the terminal in gui mode a pesuoterminal?
 
To set reboot with text mode.
When login in with text mode,to input tty ,you get tty1.
Now,to input `startx` to jump into gui mode.
To enter terminal in the gui mode started from tty1 to inupt.

tty
/dev/pts/0

Is the terminal in gui mode a pesuoterminal?
Someone said it is just a X server started from tty1,not pesuoterminal.

rtmistler 01-06-2017 12:53 PM

Hi, it's rather hard to tell exactly what you're talking about.

However a terminal in UI mode, showing on the desktop, is a terminal. Same as if you boot to non-GUI mode and type into a console. Both are a Linux process which you are running. The only differences are the visual attribute differences of them; such as the UI based one may have scrollbars and a recall buffer to allow you to see some large number of lines, whereas the non-GUI one does not have a scrollbar.

Does this answer your question?

BW-userx 01-06-2017 01:17 PM

that thing inside of your DE/WM is a terminal emulator. That thing you see if you where to hit Ctrl+Alt+F[1-12] is your terminal.

jpollard 01-06-2017 04:47 PM

Quote:

Originally Posted by rtmistler (Post 5651329)
Hi, it's rather hard to tell exactly what you're talking about.

However a terminal in UI mode, showing on the desktop, is a terminal. Same as if you boot to non-GUI mode and type into a console. Both are a Linux process which you are running. The only differences are the visual attribute differences of them; such as the UI based one may have scrollbars and a recall buffer to allow you to see some large number of lines, whereas the non-GUI one does not have a scrollbar.

Does this answer your question?

When the tty device is identified as "pty" it is a pseudoterminal. This means that to the application/shell it appears and is used exactly like a hardware terminal. The kernel provides the emulation of the device. When used as part of a GUI based terminal, the GUI part is usually emulating a terminal using a Window for output, and the keyboard/mouse for input. The kernel is given the keyboard input which then passes it through the pseudoterminal emulation. That emulation usually causes an echo (not always, as terminal based editors usually turn that off) which is passed back to the GUI part to decide how and where to display it. This is how the various terminal types are emulated.

In the case of the linux tty devices, these are ALSO emulated - by the kernel as if they were a hardware device without a GUI.

One specific difference between between a real terminal and emulated terminals is that the speed (stty speed) can be set to anything - it really doesn't make any sense as there is no hardware UART involved (it usually defaults to 38400).

The default serial lines on most PCs are identified as /dev/ttyS0 and /dev/ttyS1 (there may be more than two shown, but by default only two would work depending on the motherboard and/or extra interfaces). These actually use the baud rate for sending/receiving as well as the modem control signals, and hardware control signals (clear to send, ready to send).

The pseudoterminals are also used for remote connections (ssh and others). If there are no ptys defined (accidentally deleted?) then remote ssh connections using a terminal cannot be established.

BW-userx 01-06-2017 05:04 PM

furthermore, you could hook up dummy terminals within your place of dwelling all leading back to your one Linux box.


All times are GMT -5. The time now is 09:35 AM.