VisualStudio Code on Haiku

First and foremost my Drag[en]gine used layout system which is inspired by existing layout systems (not constraint systems). I do not align horizontally or vertically. I do not use “auto” or “*” values for columns or grids. I do not touch individual widgets. I just say “use this layout for this container”… done. Any count of widgets laid out as desired and I can just add and remove widgets without dealing with details. That’s a layout system. You can think of it as high level language versus low level language just that a real layout system does is not implemented using a constraint system but has specialized code.

@dragon and how does it work? How would you, for example, replicate the view I made above?

Hi, not being a native English speaker, I may be missing something in translation.
You seem to be considering layout and constraints based systems are different things while in my understanding they are tied one to another (i.e.: you define layouts that impose constraints on individual widgets).
Can you be more specific on your take on constraint vs layout?

1 Like

Honestly, Drag[en]gine does appear to be constraint based. I am not familiar with the source, so dont know exactly where to look, but looking at e.g. https://github.com/LordOfDragons/dragengine/blob/master/src/launcher/android/src/gui/widgets/dealWidgetLayoutFlow.cpp#L119 widgets layout horizontally or vertically, and dealWidgetLayoutFlow::LayoutWidgets() solves by dividing the available horizontal or vertical space among children according to some properties set on them such as fill, center etc.

It’s worth pointing out that constraint based just means that things are sized automatically according to some set of (probably dynamic) limitations, they don’t have to be literally based on explicit linear constraints and solved by linear optimisation. In many cases doing so would be using a sledgehammer to crack a walnut, and that is also why haiku provides several different “layouters” I believe. I think some haiku layouters use similar strategies to drag[en]gine, although they do operate over more general constraints.

I think that there is essentially a misunderstanding here about terminology and the difference between API (i.e. interface) and implementation.

4 Likes

I am a pretty big fan of VSC so I’m kinda sad it looks like it’s not going to be possible to get it up and running on Haiku. I get the issues with Electron though and why it’s not really feasible to port it. I have wondered about an alternate route though.

VSC can also run as a server / web application and it actually works really well. This is a project to make it easier to get it up and running as a server:

I think it’s main dependency is just nodejs, which iirc does work on Haiku. If it’s possible to get the server portion working with just node, then once the WebKit2 web view is done it wouldn’t be too hard to make a dedicated app that would spawn a node child process to run the server on a custom socket and then open up a web view that’s pointed to that socket. The UI could then be customized to more Haiku like. This would give users an IDE that they are familiar with, that has an extensive ecosystem of extensions, that’s well integrated with the OS, but doesn’t have all of the bloat of electron. I think that there are a lot of web developers out there that might be more interested in Haiku if it had VSC.

3 Likes

Wow - didn’t think this would work ! (Falcon on Haiku 64bit)
Don’t expect too much :slight_smile:

9 Likes

Sorry to jump in here and change the topic but what’s going on with that Dock? Are we looking to get sued by Apple, Inc.!?

1 Like

Very suspicious with that Chrome icon. Maybe a prank?

2 Likes

No prank - see my HiQDock available on besly repo

This is my private 3rd party software so I hope Haiku can’t get sued by Apple - and I hope I don’t get sued either :slight_smile:

3 Likes

Don’t get me wrong - it looks good but Apple are very protective of their UIs.

Is there any way it can be configured to look more “Haiku-ish”?

Hi @dwt - don’t worry about Apple - there are so many ‘docks’ out there for Linux and Windows that are meant to emulate the Apple dock.

You can configure the HiQDock launcher icons to be any .svg or .png image you want - you can even convert the .hvif icon to an .svg (see all the instructions over at this forum thread HiQDock ... New Dock coming soon - #163 by hey68you or PM me for any questions)

I like to use these “Uos” icons in addition to converting the .hvif icons to .svg: https://github.com/zayronxio/Uos-fulldistro-icons

There are many more icon sets over at KDE store that you can download as zipped files and put the icons into the HiQDockIcons folder - Full Icon Themes - KDE Store

Docks for Linux/Windows:

https://www.makeuseof.com/best-dock-apps-for-linux/

Very cool! I tried it in WebPositive and it crashed the browser. One thing that limits it in an actual browser window is that the browser interferes with a lot of the hot keys. If I create a WPA in macOS it’s more or less indistinguishable from the locally installed version. Would love to see it working well, at least in the browser, on Haiku someday.