asteria-archive-otori / Echidna

[WIP] A friendlier code editor than your current one.
Mozilla Public License 2.0
14 stars 0 forks source link

Implement basic extension support for MVP #5

Closed togetherwithasteria closed 2 years ago

togetherwithasteria commented 3 years ago

Visual Studio Code's .vsix file is nothing more than a .zip file. Once extracted, the JavaScript code is there and available to be run like a normal JavaScript file. Obviously, implementing this is not for our MVP target, but we still need to implement the basic extensions: themes, file icons, and product icon extensions. Obviously, the UI needs some theming and icons, so we obviously need support for these extensions.

Visual Studio Code has a brief reference on these (read: https://code.visualstudio.com/api/extension-guides/file-icon-theme, https://code.visualstudio.com/api/references/theme-color, and https://code.visualstudio.com/api/references/icons-in-labels), and from the documentation it seems that it will be easy for us to implement. The manifest file and the theme files are all in JSON format, which Qt has support for. As we use Rust now, then we will use Serde JSON for this.

The only problem for theming is that Qt's default UI components does not suit Visual Studio Code's UI (read: #3) As we moved to GTK, then we will face GNOME's Adwaita design, but I think only that, I'm thinking to just Adwaita though. Once we add the UI tweaks, including the manual painters shenanigans I mentioned, theme extension support will be completed.