Home » Developing U++ » UppHub » A terminal emulator widget for U++
| Re: A terminal emulator widget for U++ [message #53731 is a reply to message #51415] |
Sat, 25 April 2020 00:36   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello,
I have pushed the the critical performance fix that I mentioned in my last message.
The main culprit was using a Vector where a BiVector was a much better option. In fact, it seems to be the optimal solution to the scrollback/hsitory buffer problem. Removing elements from the beginning of a Vector, especially when its length > 64K is -not surprisingly- very slow. BiVector solves exactly this problem because a scrollback buffer is mutated only from the either end.
There was also a constant display refresh happening when a page was scrolled, even when a single line scrolled, degrading performance. This is fixed too.
Now Terminal ctrl's scroll speed / throughput can be very fast. (It is Even faster than the above given numbers: ~3.5 secoonds on the same test while acting as a both SSH (using Upp/SSH package) and local terminal. ("time find /usr/share" command was outputting > 300.000 file paths in these tests, with the size of scrollback buffer of each terminal was set to 64 k)
However, you can't see the real difference if you use the provided reference example codes, because they have a very rudimentary event loop.
If you are curious and you want to test the scrolling/throughput performance of Terminal ctrl, you can use the below code: While still rudimentary, it is closer to real world scenarios.
#include <Terminal/Terminal.h>
#include <Terminal/PtyProcess.h>
using namespace Upp;
const char *nixshell = "/bin/bash";
struct TerminalExample : TopWindow {
Terminal term;
PtyProcess pty;
TerminalExample()
{
SetRect(term.GetStdSize());
Sizeable().Zoomable().CenterScreen().Add(term.SizePos());
term.WhenBell = [=]() { BeepExclamation(); };
term.WhenTitle = [=](String s) { Title(s); };
term.WhenOutput = [=](String s) { pty.Write(s); };
term.WhenResize = [=]() { pty.SetSize(term.GetPageSize()); };
term.WhenLink = [=](const String& s) { PromptOK(s); };
term.InlineImages().Hyperlinks().WindowOps().DynamicColors();
term.SetHistorySize(65536);
}
void Run()
{
pty.Start(nixshell, Environment(), GetHomeDirectory());
OpenMain();
while(IsOpen() && pty.IsRunning()) {
int ms = 16;
String in = pty.Get();
if(!IsNull(in)) {
term.WriteUtf8(in);
int len = in.GetLength();
if(len >= 1024)
ms = 1024 * 16 / len; // Scale to workload...
}
ProcessEvents();
Sleep(ms);
}
}
};
GUI_APP_MAIN
{
TerminalExample().Run();
}
There are other improvements and bug fixes too (mostly on serialization/xmlization/jsonization fronts).
If you have any questions, criticism, bug reports, patches, ideas, let me know.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sat, 25 April 2020 01:06] Report message to a moderator
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #53956 is a reply to message #51415] |
Sun, 17 May 2020 22:20   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello,
Ranger, a terminal based file manager, can now show image previews via iterm2's inline image protocol, on terminal ctrl.

By the way, I am planning to implement optional, range-based font substitution for Terminal ctrl v0.4 (2020.2, synced with U++).
My initial plan is to give the client the ability to compose a font list (using a simple structure called Terminal::RangeFont), and pass it to terminal ctrl instances so the client will be responsible for taking care of the list. (Similar to how Upp::Display objects are handled.)
If you have any other suggestions I have opened a ticket for it. Feel free to share your ideas.
Best regards,
Oblivion.
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
|
|
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54061 is a reply to message #54059] |
Thu, 28 May 2020 11:36   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello slashupp,
Quote:I want to test if Terminal fits the needs of my app, but fail to find
a HowTo on installing it in my upp-dev-environment (which is standard)
Yes, this is missing from the docs. I will update it next week. In the meantime,
How to get it:
Terminal is a regular ctrl. It does not require anything other than U++ (ver >= 2020.1, because I use some new color methods which simplified the color management code.)
If you want to try it out, you can:
a) Clone the upp-components git repository (This is the recommended way to get updates,etc.) and set up an assembly in TheIDE for upp-components/CtrlLib (It is no different than adding another "bazaar")
b) Simply download the repo, unzip it, and move the CtrlLib/Terminal folder to your preferred folder.
Now that you have the source code, It should compile out of the box. There should be no need for tweaking, etc.
How to use it:
Well, the upp-components/Examples section already contains example code for different, basic use cases, I suggest you check there and play with them first (if you haven't already).
They are pretty simple. A minimal example is here upp-components/Examples/TerminalExample
(That minimal example, by the way, can run almost anything, out of the box)
Steps to write your own code:
1) Check the API docs first. Terminal ctrl contains regular topic++ files for TheIDE. It should be available through TheIDE's help system.
2) Create a CtrlLib application (basic or with layout, it's up to you. Terminal ctrl contains a layout file, so you can use it in TheIDE's layout editor.)
3) Add Terminal ctrl to you app. As it is a regular ctrl, it can be added to your window or any other "parent" ctrl via Ctrl::Add() method.
4) If you are going to use it as a local terminal, using a pty (currently on POSIX only), then Terminal package contains a PtyProcess class.
Add #include <Terminal/PtyProcess.h> to your app. Then all you need to do is set up the events and loop.
Provided examples use a rudimentary loop which is sufficient for most cases but you can write much efficient loops that'll suit your personal need and use-case.
5) If you are going to use it as a GUI front end for, say, SSH shells, add uppsrc/Core/SSH package to you app, and connect the loop. See the rudimentary upp-components/Examples/SshTerminalExample
Again, this is just generic information on how to install and use it.
If you have any specific questions in the meanitme, I'll be happy to address them. 
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Thu, 28 May 2020 11:57] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54067 is a reply to message #54059] |
Fri, 29 May 2020 12:40   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
An example demonstrating the absolute minimum setup for a standalone terminal app, and two different loops:
#include <Terminal/Terminal.h>
#include <Terminal/PtyProcess.h>
using namespace Upp;
struct MinimalTerminalExample : TopWindow {
Terminal term; // A terminal ctrl instance.
PtyProcess pty; // A pseudoconsole process instance.
MinimalTerminalExample()
{
SetRect(0, 0, 800, 600);
Sizeable().Zoomable().CenterScreen().Add(term.SizePos());
term.WhenOutput = [=](String out) { pty.Write(out); }; // Terminal output
term.WhenResize = [=] { pty.SetSize(term.GetPageSize()); }; // Notifies the pty about page size changes.
pty.Start("/bin/bash", Environment(), GetHomeDirectory()); // Start a shell process on pty.
// For a reasonable throughput, a callback-based loop is sufficient.
SetTimeCallback(-1, [=] { term.WriteUtf8(pty.Get()); if(!pty.IsRunning()) Break(); });
}
// For very high throughput, below loop (or something better) can be used.
//
// void Run()
// {
// pty.Start("/bin/bash", Environment(), GetHomeDirectory());
// OpenMain();
// while(IsOpen() && pty.IsRunning()) {
// ProcessEvents();
// String s = pty.Get(); // PtyProcess reads are non-blocking.
// if(!IsNull(s))
// term.WriteUtf8(s);
// int l = s.GetLength();
// Sleep(l >= 1024 ? 1024 * 10 / l : 10); // Scale...
// }
// }
};
GUI_APP_MAIN
{
MinimalTerminalExample().Run();
}
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Fri, 29 May 2020 13:05] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54194 is a reply to message #51415] |
Sat, 06 June 2020 13:57   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello,
Terminal ctrl is updated. It has a number of under-the-hood improvements that lead to higher performance/throughput.
To give you an idea, here are some benchmark results I've been compiling (both synthetic and real-usage) for some time:
CPU: AMD FX 6100 - Black Edition (Six-core processor)
Memory: 8 GiB, DDR-3 1800 Mhz
Storage: 128 Gib SSD, 1Tib HDD
Graphics: AMD Radeon R7 240, 2GiB
Monitor: LCD, HD (1080p)
OS/Kernel: Arch/Linux 5.6 (x86_64)
Desktop: GNOME 3.36 (X11)
Framework: Ultimate++ 2020.1 (alpha)
Flags: GUI
Compilers: GCC 10.0.1 CLANG 10.0.0
Application: TerminalExample (with a high throughput loop).
Font: The same IBM Plex Mono, monospace font used in all tests.
Disclaimer: The benchmarks below do not represent any competition.
They don't represent any weak spots of the mentioned terminals. They are all high quality stuff.
The sole purpose of these benchmarks is to give an idea as to where the Terminal ctrl's "engine" performance stands ATM.
Note: All benchmarks are repeated 50 times, automatically.
The performance difference between GCC/CLANG builds is negligable.
The latest stable versions of the mentioned terminals are used in these tests (as of May-June 2020).
Results of command: "time find /usr", file count: 415897, page size: 237 x 55, Monospace Font)
Terminal Emulator real user sys Notes
----------------- ---------- ---------- ---------- ----------
Alacritty 0m3,776s 0m1,134s 0m2,637s Scrollback buffer size: 64k
Terminal ctrl 0m4,126s 0m1,202s 0m2,466s Scrollback buffer size: 64k
Kitty 0m5,608s 0m1,224s 0m2,763s Scrollback buffer size: 64k
Gnome Terminal 0m6,785s 0m1,243s 0m3,015s Scrollback buffer size: 64k
xterm 0m24,368s 0m1,661s 0m3,766s Scrollback buffer size: 64k
Terminal Emulator real user sys Notes
----------------- ---------- ---------- ---------- ----------
Simple terminal (0.8) 0m3,791s 0m1,162s 0m2,533s Has no scrollback buffer.
Terminal ctrl (0.3) 0m3,971s 0m1,120s 0m2,472s Scrollback disabled.
Terminal Emulator real user sys Notes
----------------- ---------- ---------- ---------- ----------
Terminal ctrl (0.3) 0m4,380s 0m1,479s 0m2,536s localhost, Scrollback buffer size: 2000 lines, no compression, (SshTerminalExample is used)
PuTTY (0.73) 0m40,828s 0m1,354s 0m3,071s localhost, Scrollback buffer size: 2000 lines, no compression
// Vte-bench, benchmark 1: scrolling. page size: 237 x 55, Monospace Font.
Terminal Emulator real user sys Notes
----------------- ---------- ---------- ---------- ----------
Alacritty 0m1,936s 0m0,001s 0m0,946s
Kitty 0m2,985s 0m0,000s 0m0,567s
Gnome Terminal 0m3,758s 0m0,001s 0m0,940s
Terminal ctrl 0m4,064s 0m0,000s 0m0,859s
Simple terminal (0.8) 0m4,623s 0m0,000s 0m1,105s
xterm 0m47,249s 0m0,000s 0m0,567s
// Vte-bench, benchmark 2: alt-screen-random-write, page size: 237 x 55, Monospace Font.
Terminal Emulator real user sys Notes
----------------- ---------- ---------- ---------- ----------
Alacritty 0m1,520s 0m0,000s 0m0,554s
Kitty 0m2,750s 0m0,000s 0m0,408s
Gnome Terminal 0m3,153s 0m0,004s 0m0,726s
Terminal ctrl 0m3,790s 0m0,000s 0m0,474s
Simple terminal (0.8) 0m7,097s 0m0,001s 0m0,825s
xterm 0m19,797s 0m0,001s 0m0,993s
// Vte-bench, benchmark 3: scrolling-in-region, page size: 237 x 55, Monospace Font.
Terminal Emulator real user sys Notes
----------------- ---------- ---------- ---------- ----------
Alacritty 0m3,337s 0m0,001s 0m3,297s
Gnome Terminal 0m5,280s 0m0,001s 0m3,254s
Kitty 0m6,326s 0m0,001s 0m6,034s
Terminal ctrl 0m6,739s 0m0,001s 0m4,033s
Simple terminal (0.8) 0m7,844s 0m0,001s 0m7,348s
xterm 3m36,599s 0m0,001s 0m11,011s
(Eventually I will add the final benchmark results to the Terminal package as a markdown file. Consider the above mentioned results only as a preview.)
If you have any questions, feature requests, bug reports, suggestions, criticism, etc. let me know.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sat, 06 June 2020 14:25] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54207 is a reply to message #51415] |
Tue, 09 June 2020 23:48   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello,
Terminal ctrl's TURTLE backend support was broken for some time.
The reason: Apparently there is no Upp::Append() method for image drag and drop (Or I am missing something...).
I've committed a patch to workaround this problem by disabling image drag-and-drops in Turtle backend.
A good news is that it is now possible to compile Terminal Ctrl for linux framebuffer, using the LinuxFrameBuffer package.
There are some rough edges (e.g. the mouse wheel does not work ATM), but it is basically working on linux framebuffer too. 
However, currently the support for linux framebuffer is "unofficial". If you are going to try it at all, TRY IT AT YOUR OWN RISK.
I will focus on these backends after the V0.4 release...
Best regards,
Oblivion.
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Tue, 09 June 2020 23:50] Report message to a moderator
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54214 is a reply to message #54210] |
Thu, 11 June 2020 11:08   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello Zbych,
Thank you for your efforts!
Indeed, it is working now. 
Since you are here, allow me to point out two problems I've encountered while testing both terminal package and others (uword, for example).
- Text mode is not disabled on linuxframebuffer based apps when they are run from the linux (tested with v5.6) console. (The framebuffer display is overwritten by text and messages). The "fix" seems to be setting the STDINPUT to KD_GRAPHICS and resetting it to KD_TEXT before the app exits (using ioctl). But since I don't know the specifics of LinuxFrameBuffer package, I can't give more info as to where the problem lies.
- Both on UWord and Terminal package, the return/enter keys are sending the keycode twice (or so it appears: text cursor is not moved to next line but two lines below.)
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Thu, 11 June 2020 11:08] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54276 is a reply to message #51415] |
Thu, 18 June 2020 00:36   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
I'm still working on range-based font substituiton feature. And I have finally prototyped the mechanism.
The screenshot below uses the legacy demo.txt file for demonstration. It displays four (default + additional three) fonts for different glyph ranges on the same page.
Font configuration:
IBM Plex Mono: 0x0020-0x07FF (Base glyphs)
Fira Code Mono: 0x2500-0x259f (Box drawing glyphs)
GNU Free Mono: 0x2800-0x28FF (Braille glyphs)
Awesome Mono: ------------- (Other glyphs)

It has its rough edges, but "it works" fine with a negligable performance hit. 
Note that this feature will not be available before v0.4.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Thu, 18 June 2020 00:39] Report message to a moderator
|
|
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54293 is a reply to message #54292] |
Sun, 21 June 2020 22:36   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello Zbych,
Quote:
I did some research and it appears that turning keyboard off in virtual terminal is correct solution.
Unfortunately neither ioctl(tty_handle, KDSKBMUTE, 1) nor ioctl(tty_handle, KDSKBMODE, K_RAW) solves the problem with keys leaking to the console.
They simply return error "Operation not permitted".
Again, thank you very much for your efforts!
Also thanks for the links.
I am going to look into LinuxFrameBuffer code in the following days and if I can come up with a workaround or solution, I'll send a patch to review.
By the way, did you try to set STDIN_FILENO to KD_GRAPHICS too? because IIRC, that (Setting both input and output to graphics mode) was the trick used by an app whose name I forgot now, some time ago.)
I'd really love to see Terminal ctrl run on linux frame buffer, because then I can get rid of unnecessary cruft on my personal servers.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54294 is a reply to message #54293] |
Sun, 21 June 2020 22:47   |
Zbych
Messages: 332 Registered: July 2009
|
Senior Member |
|
|
Oblivion wrote on Sun, 21 June 2020 22:36
By the way, did you try to set STDIN_FILENO to KD_GRAPHICS too?
Do you mean using STDIN_FILENO in ioctl(STDIN_FILENO, KDSETMODE, KD_GRAPHICS)?
it returns error: Inappropriate ioctl for device (25)
In my tests I pass path to virtual terminal manually (for example /dev/tty3), I decided to leave tty number autodetection as next step.
[Updated on: Sun, 21 June 2020 22:55] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54345 is a reply to message #54338] |
Sun, 28 June 2020 11:57   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello Zbych,
I have attached the patched LinuxFrameBuffer package for you to review. Feel free to comment on it.
Package is compiled with the latest stable GCC and CLANG on Linux v5.4 and v5.6 machines.
For testing, I used the supplied LinuxFrameBufferExample (UWord) code, Terminal ctrl, and some other U++ examples made to run on FB backend.
Changes/additions:
- Automatic VT allocation mechanism is implemented.
Since U++ suppports function keys from F1 to F12, I have limited the valid VT numbers within tty1-tty12 range (This can be easily changed if required).
- Accordingly, VT switching is implemented.
Since we mute the vt keyboard input, this required manual handling of the linux signals, and as a result the vt handle had to be made a global static integeer (atomic).
- To prevent any screen buffer damage, U++ linuxframebuffer backend now does not copy the drawn image onto framebuffer when the
vt is switched away (i,e., whem it loses focus).
- Accordingly, CTRL + ALT + [F1-f12] key combinations are reserved for VT switching.
Remaining issues:
- SHIFT keys are not working properly. (Can't get any capital letters.)
- No double click.
- No key repeat.
I am not sure about the security implications though. If you find any problem, let me know.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sun, 28 June 2020 12:04] Report message to a moderator
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54413 is a reply to message #51415] |
Tue, 14 July 2020 14:44   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello,
Moving towards the v0.4, Terminal ctrl has gained a new feature:
- Application clipboard manipulation protocol (OSC 52) is implemented.
This optional feature grants clipboard read and write access to applications that supports OSC 52
OSC 52 is supported by many terminals, including xterm, and apps such as tmux.
However, this feature should be handled with care by the client code, as it may pose a security threat.
Terminal ctrl already takes some security measures though:
1) Terminal ctrl gives the client code a granular control over this protocol.
2) In compliance with the principle of least astonishment, the feature is disabled by default.
3) It will work IFF it is enabled && the ctrl instance has focus (to prevent spamming, etc.)
Accordingly, the API and specs docs are updated.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Tue, 14 July 2020 14:47] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54493 is a reply to message #51415] |
Sat, 01 August 2020 20:48   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
Aside from small updates, there were no news about Terminal ctrl for some time.
Here is a screenshot of the upcoming v0.4 (2020.2) of Terminal ctrl on Windows 10, scheduled to be published in October 2020:

That's Windows powershell (tm) running natively on the basic terminal example, on Windows 10. 
This is possible because Windows 10 has a brand new pseudoconsole api. (Thus you can also run plain cmd.exe, or other console apps...)
I am implementing this in PtyProcess class, without requiring any API change, so the Terminal reference examples can be run without changing the code.
Hopefully, this will mature with v0.4.
Best regards,
Oblivion
-
Attachment: Capture.JPG
(Size: 61.01KB, Downloaded 1428 times)
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54618 is a reply to message #51415] |
Fri, 21 August 2020 13:29   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
Today marks a rather important milestone for Terminal ctrl: Windows 10 pseudoconsole API support.
The support is implemented in PtyProcess class, so nothing new is introduced. Thanks to Mirek, you only need to enable the WIN10 flag in theIDE's main package configuration settings ("GUI WIN10"). So you will need the nightly builds of Upp to run Windows 10 pty with Terminal ctrl.
It is tested with the bundled CLANG and MSVC19 (MSVC19 requires comdlg32.lib via Windows SDK)
Since the support is experimental at the moment, you can expect some glitches (If you find any, let me know).
Git examples are also updated to reflect the changes. You can check them to see what is changed (or rather, not changed.)
For other, under-the-hood improvements and changes, you can check the git commit history.
Note that Terminal package is still in v0.3 phase. v0.4 (or 2020.2) is still two months away, and will bring in more improvements, and hopefully a refined win10 pty support.)
Here is a screenshot of the stock terminal splitter example, running multiple instances of cmd.exe with resizing support. (You can also run powershell instead):

If you have any questions, suggestions, bug reports, etc., let me know.
Cheers!
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Fri, 21 August 2020 13:33] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #54744 is a reply to message #51415] |
Sat, 05 September 2020 16:45   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
There is a project called Monotty text-based desktop environment.
This project, which I've been tracking for some time, has set up a public ssh server where you can test both yout terminal emulator and the monontty desktop prototype.
It is cool stuff (with images made of unicode glyphs, 24-bit color transparency,etc.)
You can test the stock ssh terminal example by setting the url to:
After that you get this:


Consider it also as a demo for the SshShell component of Core/SSH package.
Best regards,
Oblivion.
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sat, 05 September 2020 16:51] Report message to a moderator
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #55134 is a reply to message #51415] |
Tue, 13 October 2020 12:41   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Ok then, since there is no objection, the Terminal widget will be officially renamed as TerminalCtrl from version 2020.2 (0.4) on.
In the meantime, I'd like to share some news about my personal, pet project:
A robust and easy-to-use, multitabbed, cross-platform terminal emulator (which will also have support for SSH2 connections) I am currently writing in tribute to U++ 
As I've mentioned before, its project codename is "toad" (it may change in the future). It is a pre-alpha software now, but once it hits alpha (0.1) I will release it under BSD license on a separate git repo. (most stuff - sans SSH infrastructure - is already up and working.)
Here is a screenshot (on linux, GNOME 3.38):

If you have any questions, ideas, bug reports, etc. let me know.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
|
|
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #55726 is a reply to message #55721] |
Thu, 03 December 2020 16:25   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello hongnod.
Thank you for your kind words!
Quote:I am watching your "Terminal" project for a duration of time. It looks amazing. I just want to know if the "toad" out will be something like XShell?
Yes, but Toad will be lighter. The prealpha (unreleased) version already has a (experimental sftp browser).
My focus with Toad is to provide
a) A cross-platform terminal emulator in U++ style (=single directory with few to none external dependencies, that can also be compiled to work on web browsers and on Linux framebuffer)
b) An ssh2 terminal with x11 forwarding.
c) An integrated sftp browser and a multithreaded sftp/scp file transfer client.
Steps a and b is basically done (I'm polishing them)
Step c is a TODO (done ATM only experimentally).
It is already delayed but its initial public beta will hopefully be released in the second quarter of 2021
In the meantime I will continue improving the TerminalCtrl
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Thu, 03 December 2020 16:26] Report message to a moderator
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #55739 is a reply to message #51415] |
Sat, 05 December 2020 16:21   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
Terminal package is now tagged as 2020.2 (v0.4)
There's a lot of changes under the hood but here are some highlights:
Terminal package, release: 2020.2, overview:
* Terminal class is finally renamed as TerminalCtrl. (Upp::Terminal will be available as an alias, until 2021.1 (v0.5) release tag).
* Fixed to compile with MSC 19.
* TerminalCtrl now officially supports Windows 10's native pseudoconsole api via the unified, basic interface of PtyProcess class.
* iterm2's inline images protocol is implemented and polished.
* Clipboard manipulation protocol (OSC 52) is implemented.
* Middle-drag (in application mouse-tracking mode) is implemented.
* Right-drag (in application mouse-tracking mode) is implemented.
* Auto-hide option for mouse cursor is added.
* Word selection is implemented. (double-click selection)
* Line selection is implemented. (triple-click selection)
* Text selection mechanism is refactored using the new range-based methods.
* Copy-on-select style text selection is added.
* Text cursor (caret) width is now automatically adjusted to cell width (i.e. reacts to single/double width unciode codepoints).
* Space character can now have overline/underline/strikeout attributes.
* Key handling is further improved across supported platforms.
* Scheduled time callbacks are now properly cleared on object destruction. (MT-fortification)
* Performance/throughput is further improved by removing the now redundant calls to page refresh methods.
* Hyperlink tooltips now display the decoded URL.
* RGBA, CMY and CMYK color text specifications (formatting and scanning) is now supported.
* Brightness component of faint colors is now correctly calculated.
* Jsonization and Xmlization support is added.
* More switches are added to the TerminalCtrl.usc (layout file).
* PtyProcess api docs are added.
* TerminalCtrl::InlineImage structure is documented.
- Terminal overview doc is removed.
Enjoy! 
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Sat, 05 December 2020 16:27] Report message to a moderator
|
|
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #56155 is a reply to message #51415] |
Mon, 01 February 2021 21:18   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
This is going to be an announcement:
I have decided to move several packages from upp-components to UppHub. And the Terminal package is one of them.
So in the following two weeks I will move the package and the example code to its own github repository.
In this way,
1) You will be able to download and update TerminalCtrl source code, examples via TheIDE's package manager, into the upp sandbox (no need to setup any assembly, etc.) with a single and simple click.
2) You won't have to download the whole upp-components repository to get TerminalCtrl and its examples.
This, however, does not mean that upp-components is dead. On the contrary, it will be maintained and synchronized with the upphub version as usual.
Besides, upp-components, and especially Terminal package gets a lot of hits, as it is referenced in various places in terminal emulation scene, and terminal emulator developer portals, and redirects curious people to Ultimate++. And I don't want to lose that. 
What I will do is to add a notice to the installation instructions and packages list in the upp-components readme file stating that these packages are also available via upphub, in TheIDE - nightly.
If you have any questions, objections, suggestions, etc let me know.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Mon, 01 February 2021 21:30] Report message to a moderator
|
|
|
|
|
|
|
|
| Re: A terminal emulator widget for U++ [message #56240 is a reply to message #56236] |
Fri, 12 February 2021 21:58   |
 |
Klugier
Messages: 1117 Registered: September 2012 Location: Poland, Kraków
|
Senior Contributor |
|
|
Hello Oblivion,
Glad to hear that it is available on UppHub I tested the TerminalExample and found one problems. The path inside terminal is not displayed correctly (it has the same color as terminal area). Here is the screenshot:

Maybe it is somehow related to white them. Please check!
Klugier
U++ - one framework to rule them all.
[Updated on: Fri, 12 February 2021 21:59] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #56241 is a reply to message #56240] |
Fri, 12 February 2021 22:26   |
Oblivion
Messages: 1266 Registered: August 2007
|
Senior Contributor |
|
|
Hello Klugier,
Quote:. The path inside terminal is not displayed correctly (it has the same color as terminal area). Here is the screenshot:
Thanks for reporting this!
However, I am unable to reproduce it on my two machines (Arch Linux, GNOME.) Tried with several different normal/dark themes. It seems to be working. (Even "powerline" styles are working! )
It is possibly theme related.
If you have time, could you please provide the below information:
- The TERM variable
- The SHELL variable
- Is Adjust to dark theme on? (You can check it via context menu)
- Is Light colors mode on? ( You can check it via context menu)
- Have you tried it with other terminals? (e.g. xterm, Konsole, etc.) xterm would be a good criterion to compare.
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
[Updated on: Fri, 12 February 2021 22:28] Report message to a moderator
|
|
|
|
| Re: A terminal emulator widget for U++ [message #56242 is a reply to message #56241] |
Fri, 12 February 2021 23:00   |
 |
Klugier
Messages: 1117 Registered: September 2012 Location: Poland, Kraków
|
Senior Contributor |
|
|
Hello,
It is fine with Konsole and VS Code however, the xterm doesn't display colors correctly. The color tune up doesn't help. The values for $TERM, $SHELL and $PS1 are as follow:
xterm
/bin/bash
\[\033[01;32m\][\u@\h\[\033[01;37m\] \W\[\033[01;32m\]]\$\[\033[00m\]
I think the root cause of the problem is that distro do some overrides.
Klugier
U++ - one framework to rule them all.
[Updated on: Fri, 12 February 2021 23:02] Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Wed May 06 12:17:12 GMT+2 2026
Total time taken to generate the page: 0.01847 seconds
|