4 ms·
> Take ImGui (https://github.com/ocornut/imgui https://github.com/ocornut/imgui, an immediate mode GUI library) for example - the examples are much closer to TU
by slightwinder 3y ago
> Take ImGui (https://github.com/ocornut/imgui https://github.com/ocornut/imgui, an immediate mode GUI library) for example - the examples are much closer to TUI interfaces than a Swift UI app - the only difference between that an a terminal UI would be that the lines are thinner and that text has non-uniform spacing.
What I see there is a spatial interface with complex layout, z-axis and graphical elements. A bit hard to replicate on a normal terminal.
> Does that make ImGui a TUI?
TUI and GUI are not defined by the actual complexity of a real application, but the environment which gives them theoretical abilities. With a GUI, you can have pixel-perfect control over every element. With a TUI, you are normally limited to character-level of control. Of course can you also use pixels without a desktop, but you would still leave the terminal-environment and enter the framebuffer for this or something similar. Though, to be fair, at this point it indeed can become a bit fuzzy.
- arghwhat 3y ago> With a GUI, you can have pixel-perfect control over every element. With a TUI, you are normally limited to character-level of control. So when I have pixel-perfect content render in a terminal emulator through Sixel graphics, and have inconsistent font rendition and problematic CSS box wrapping in a Web or Electron app, does that make the former GUI and the latter TUI? ;) > TUI and GUI are not defined by the actual complexity of a real application, but the environment which gives them theoretical abilities. And indeed, this gets to my point. The difference between a GUI and a TUI framework is more akin of the difference between, say, SwiftUI and WinForms, than something presenting a different mental model or experience for users. There are aesthetic differences, but there are just as stark differences between Win32, Aero, Metro and Sun Valley Windows GUI styles. Sure, modern GUI applications can do more, but no user cares that Outlook could have had pressure-sensitive, angle-dependent Wacom tablet tool integration, and no so user would care that a TUI email client can't.