News for hackers. Stuff that matters.
Re:Turbo Vision 2.0 – a modern port by vintagedave on Saturday April 25, 2026 @04:07AM (#47899642)
How awesome to see this on the front page! I've been writing a wrapper for this repo. Right now I'm running Turbo Vision -- this repo -- under .Net on macOS. It's a magical feeling.

The wrapper gives a higher level API, and solves some of the things like the rather antique palette API (or wraps it), is adding layout, etc.

```

var lMenuBar := new MenuBar;

  lMenuBar

    .Add(lDocumentMenu)

    .Add(lViewMenu)

    .Add(lDialogsMenu)

    .Add(new Menu('~A~pp').AddItem('E~x~it', Commands.Quit));

  fApplication.SetMenuBar(lMenuBar);
```

(This is Oxygene, currently compiling to .Net. Can be used from any .Net language of course, even Go or Swift with our toolchain, but as an assembly, consumed by anything. Using PInvoke for the native TV binaries.)

Heavily in progress :D The repo is still private and I'm working on things like basing palettes on the surfaces controls are placed on today and tomorrow. Todos are cleaning up layouts, adding a few more basic (for today) missing controls, etc.

I had experimented with libraries like Terminal.GUI, which was (still is?) in the middle of a v2 transition and really difficult to get behaving without bugs. And Claude is a great lesson about TUIs and libraries that have been built without real terminal consideration -- lots of what not to do. I found myself missing Turbo Vision and thinking, why not just have a modern version? Then I found this repo, saw it was updated for Unicode, etc... I am very grateful to the author.

Re:Turbo Vision 2.0 – a modern port by magicalhippo on Saturday April 25, 2026 @04:13AM (#47899663)
> This is Oxygene

For those who aren't familiar[1], it's part of RemObjects' Elements[2] suite, which allows you to use and mix several different popular languages in addition to the Pascal-based Oxygene across Windows, MacOS, Linux, Android etc.

[1]: https://www.remobjects.com/elements/oxygene/

[2]: https://www.remobjects.com/elements/

Re:Turbo Vision 2.0 – a modern port by justinclift on Saturday April 25, 2026 @10:15AM (#47901715)
That looks interesting. Pity they only have IDE's for Win/macOS though. :(

I mean, deploying on Linux is good, but not having an IDE that runs on Linux is a disappointment.

Re:Turbo Vision 2.0 – a modern port by vintagedave on Saturday April 25, 2026 @11:05AM (#47902047)
We've thought of it. Most customers are Win & Mac based. The vast majority of the IDE is shared code with only thin native UI wrappers (genuinely native, done the Right Way, aka non-Electron :D) and I admit to having been tempted to point an AI at the source and a copy of Qt and asking it to add a third one, a Linux GUI. We don't normally use AI for most of our coding, but I think with two prior examples and a thin layer only, it'd be a pretty cool experiment.
Re:Turbo Vision 2.0 – a modern port by justinclift on Saturday April 25, 2026 @09:22PM (#47906403)
If you do have a go at that and want someone to test the end result, you're welcome to ping me to try it out? :)

(email addr is in my HN profile)

--

As a data point, I develop with Go professionally and use Linux (exclusively) both at home and at work. Some of my developer team mates at work use macOS, and others use Windows.

Many of the other places I've worked have been fairly Linux (and/or macOS) heavy too. Not so much Windows heavy in the last few years, and I personally expect the trend of less Windows usage to continue due to Microsoft continuing to degrade its user experience.

Re:Turbo Vision 2.0 – a modern port by actionfromafar on Saturday April 25, 2026 @05:16AM (#47899969)
I wanted to do the same. I have used Terminal.Gui but would prefer TV and so considered a wrapper. Would be really interesting to see your wrapper.
Re:Turbo Vision 2.0 – a modern port by vintagedave on Saturday April 25, 2026 @10:17AM (#47901735)
Happy to share. It's really not in a shareable state right now, so that's 'happy in a few days maybe' if that's ok :) But you can ping me and I can let you know when it is? Drop me an email, username at gmail.
Re:Turbo Vision 2.0 – a modern port by lepicz on Saturday April 25, 2026 @08:08AM (#47900792)
> It's a magical feeling.

hehe working with this TV library scratches my nostalgia itch :D

it probably saved me from futile efforts like writing apps for GEOS or joining the one person Hurd team.

Re:Turbo Vision 2.0 – a modern port by FpUser on Saturday April 25, 2026 @12:05PM (#47902474)
I did not use TV directly but I loved the design so I used basic ideas for my own DOS UI library for Turbo Pascal. It was completely graphical and implemented using built in assembly. In order to save RAM my Window manager would save invisible regions to disk.
Re:Turbo Vision 2.0 – a modern port by electroly on Saturday April 25, 2026 @10:56AM (#47901974)
I've done some work with this tvision port as well. Every time I use a new TUI framework, I'm disappointed. Invariably, Turbo Vision is better.

I'm actually working on my own .NET wrapper, too. I don't think I'm as far as you, though. I'm mimicking the Windows Forms API as closely as possible and I want to have a drag-and-drop TUI designer.

Some examples of my wrapper: https://github.com/brianluft/terminalforms/tree/main/src/Ter...

I did most of the hard integration work on the C++ side: https://github.com/brianluft/terminalforms/tree/main/src/tfc... -- exporting simple C functions that I can call with P/Invoke so that the C# side is mainly about organizing into classes. It took a couple tries to find a design that didn't fall apart when I got into more complicated stuff. Initially I went too hard into "everything that you can do in C++ should be possible in C#"--this was maddeningly complex. I was using placement new to stick the C++ objects into C# buffers, you could effectively subclass the C++ classes from the C# side, it was getting way too involved. I switched to a much more direct and less flexible approach. I decided the flexibility should be on the C# side.

I'm curious how your P/Invoke system works.

Re:Turbo Vision 2.0 – a modern port by vintagedave on Saturday April 25, 2026 @11:03AM (#47902026)
Nice! Mimicking that API is a great idea - a very different approach to mine and I love seeing it :) We shall clearly be in great competition in the future!

(Joking aside, I actually hope great cooperation, not competition... it's what open source is for. Seeing someone else is making a .Net wrapper as well is just plain awesome and I wish you the best. I really like the different API style.)

Re:Turbo Vision 2.0 – a modern port by electroly on Saturday April 25, 2026 @11:07AM (#47902061)
Definitely. Reach out to me or magiblot if you ever need any help. I love this stuff, and magiblot is extremely responsive. They have helped me many times and even made changes to tvision to support my use cases.

As a stretch goal, you might try to integrate https://github.com/magiblot/turbo too. This is a Scintilla-based text editor control implemented in tvision. We worked together to make it embeddable in other programs (because I wanted it in mine). Example usage: https://github.com/tmbasic/tmbasic/blob/master/src/tmbasic/C...

Also, I assume you know about the Turbo Vision Pascal and C++ books. They're really helpful. I transcribed both books to Markdown for easy searching if you want it.

Re:Turbo Vision 2.0 – a modern port by vintagedave on Saturday April 25, 2026 @03:29PM (#47903880)
I will, and thankyou.

That editor is really impressive. I'll see if I can wrap it too! Can I ask what your editor integration is for, what project?

I know the books exist, but I haven't read them. It's possible I even had a copy as a child - we had many of them but I never wrote Turbo Vision code, just Turbo Pascal in plain text or graphics modes. Then I moved on to Delphi. I would love to find both in MD - are they publicly available?

I realised I never answered your question about P/Invoke: I wrote (as in got an AI to generate) a flat C wrapper using the handle pattern, and then reimplemented classes back in Oxygene Pascal. I'm experimenting with new controls now, eg a tab/page view and others. Each is just a class that has its own view, plus some management extras, such as what max rendering it supports (I'm adding DOS character sets through to Powerline in rendering tabs, borders, etc.) It's all churning quite a bit as I do something, realise it may not be the best approach matching the TV model, rethink - learning a lot about TV's architecture at the time - so no more solid answer than that currently simply because it may be outdated tomorrow :)

Rather than focusing heavily on inheritance, I'm leaning more towards soft interfaces (duck typing) and wrapping via composition. This is just personal preference. But the concept is, if something looks like it is able to hold controls, it is treated as though it can hold controls, for example.

Re:Turbo Vision 2.0 – a modern port by electroly on Sunday April 26, 2026 @12:26PM (#47911514)
I used it for https://tmbasic.com to build an IDE in the style of Turbo Pascal for my toy language. Originally, I was going to implement the TV wrapper framework and UI builder in this project instead, so you could write TUIs in TMBASIC, but that ultimately felt like a waste for a toy language. With .NET someone might actually use it :P

I've sent you an email with the Turbo Vision books in Markdown, if you didn't receive it, hit me up via the email in my profile.

Re:Turbo Vision 2.0 – a modern port by guestbest on Saturday April 25, 2026 @02:49PM (#47903604)
Must be serendipity as I’ve been working on a TUI drama nd drop designer like a terminal Visual Basic 4. I’ve tried Visual Basic for dos and it was as streamlined as the windows version