Live data from Hacker News

Lite: A lightweight text editor written in Lua

github.com

51–60 of 81 posts

Re: Lite: A lightweight text editor written in Lua

#51
post #48

I would like to know more details about how the UI is build. So far I have found this [1]. A tutorial-like post will be welcome, though. [1] https://rxi.github.io/lite_an_implementation_overview.html

The UI is done using an immediate rendering model.

It is entirely composed of two rendering operations, drawing solid color rects, or rendering text from a true type font.

You can read a bit about the underlying technology here: https://rxi.github.io/cached_software_rendering.html

It's quite brilliant.

Re: Lite: A lightweight text editor written in Lua

#52
Related:

Lite XL: A lightweight text editor written in Lua - https://news.ycombinator.com/item?id=28669439 - Sept 2021 (60 comments)

Show HN: Lite – A small, fast text editor - https://news.ycombinator.com/item?id=23126458 - May 2020 (256 comments)

Show HN: Lite – A lightweight text editor written in Lua - https://news.ycombinator.com/item?id=22987195 - April 2020 (3 comments)

Re: Lite: A lightweight text editor written in Lua

#53
post #44
post #40

Earlier quoted context omitted.

It is common for build time or runtime dependencies to change in incompatible ways meaning eventually you might not even be able to run it or even built it from source.

a dependency change is no longer an author's problem when they have pinned down versions.

Pinning can be problematic since it blocks security updates.

Re: Lite: A lightweight text editor written in Lua

#54
post #43

Earlier quoted context omitted.

Pretty sure the same is true for Vim or Neovim Yes; especially Neovim, which not only has several GUI’s but it's designed to be embeddable, including into VS Code or a web browser. Neovim has native support for LSP and Treesitter, which enables it to IDE-like things. Neovim is extensible using Lua 5.1 and comes with LuaJIT for speed. It’s not just a command line thing.

No, it is a command line thing. Neovim and vim are just the editor component of the bigger tools that is something like vscode. To get Neovim kind of things to be anywhere near usable for modern day development work, you need to bolt a file browser, intellisense, command line section, remote editing section, container plugins, plugin installer, settings section etc etc on top of it, and is not really a trivial job fo…

> To get Neovim kind of things to be anywhere near usable for modern day development work, you need to bolt a file browser, intellisense, command line section, remote editing section, container plugins, plugin installer, settings section etc etc on top of it

Why?

Neovim has multiple package managers. It has GUIs like https://github.com/neovide/neovide, it has support for LSP which can do something? Many people are comfortable with programming in an environment like that

It also has a terminal (even though if you use neovim you probably prefer to open terminals outside the IDE) and support remote editing too

Here are some links

https://github.com/wbthomason/packer.nvim & https://github.com/junegunn/vim-plug

https://neovide.dev/

https://neovim.io/doc/user/nvim_terminal_emulator.html

https://neovim.io/doc/user/remote.html

Re: Lite: A lightweight text editor written in Lua

#55
post #16

Earlier quoted context omitted.

I mean open source IDE's, real full featured developer environments for writing code. I don't talk about Open Source projects in general, but about competition for VS Code or Eclipse. There is something like Sublime Text, but it's not really open source and free. Edit: With Vim and stuff I get your point, but I would say it's not really comparable to an UI-based IDE, it is command line stuff. Even if many people pref…

I like Zed currently. It seems to get closest to my IDE needs by natively integrating with LSP while still being ridiculously fast (that JetBrains is building Fleet, which is also nice, but by comparison to their existing suite extremely lacking. Both closed source though :/

What's Zed business model? It's going to be closed source, right? :(

Re: Lite: A lightweight text editor written in Lua

#56
post #27

Earlier quoted context omitted.

I don't mean to screw up the whole vibe of your comment, but... if 0 then print('0 is true') else print('0 is false') end prints "0 is true". The reason why "you can just do `if str:find('a')`" is because it returns nil. string.find never returns 0.

That's what I mean. It never returns 0, so is thus always truthy if it finds something. If you do `if (str.indexOf("a"))` in javascript; you'll miss out on the case where the string starts with "a", because the index returned 0, which is falsy. EDIT: Oh, sorry, I see what you mean. You're right, my bad. EDIT2: I guess, let me rephrase. 0 is rarely returned for things, so the falsiness of it doesn't usually enter into…

[deleted]

Re: Lite: A lightweight text editor written in Lua

#57
post #43

Earlier quoted context omitted.

Pretty sure the same is true for Vim or Neovim Yes; especially Neovim, which not only has several GUI’s but it's designed to be embeddable, including into VS Code or a web browser. Neovim has native support for LSP and Treesitter, which enables it to IDE-like things. Neovim is extensible using Lua 5.1 and comes with LuaJIT for speed. It’s not just a command line thing.

No, it is a command line thing. Neovim and vim are just the editor component of the bigger tools that is something like vscode. To get Neovim kind of things to be anywhere near usable for modern day development work, you need to bolt a file browser, intellisense, command line section, remote editing section, container plugins, plugin installer, settings section etc etc on top of it, and is not really a trivial job fo…

To get Neovim kind of things to be anywhere near usable for modern day development work… blah blah

We don’t roll like that anymore; you can just use one of several distributions that are pre-configured; most of these are 1-line installs:

    bash 
It’s basically the best of both worlds—-IDE--like functionality all set and ready to go out of the box but totally customizable. And blazingly fast; launch times are * LunarVim: https://www.lunarvim.org

* VaporNvim: https://github.com/VapourNvim/VapourNvim

* NvChad: https://nvchad.com

* AstroNvim: https://astronvim.github.io

Re: Lite: A lightweight text editor written in Lua

#58
post #33
post #32

Earlier quoted context omitted.

Thanks for reaching out! At the moment I can't think of anything specific. It was just some small papercuts that added up enough to prevent me from using it regularly, not a lack of features. But lite-xl did show me that building a text editor isn't as difficult as I first thought, and I now have many ideas for my own personal editor that I might make one day. If I ever give lite-xl another try I'll be sure to share…

Fair enough; totally understand. If you ever can think of anything please don't hesitate to fire up an issue on the tracker. We're (very slowly) going through them.

any plans for an M1 native build?

Re: Lite: A lightweight text editor written in Lua

#59
post #43

Earlier quoted context omitted.

No, it is a command line thing. Neovim and vim are just the editor component of the bigger tools that is something like vscode. To get Neovim kind of things to be anywhere near usable for modern day development work, you need to bolt a file browser, intellisense, command line section, remote editing section, container plugins, plugin installer, settings section etc etc on top of it, and is not really a trivial job fo…

> To get Neovim kind of things to be anywhere near usable for modern day development work, you need to bolt a file browser, intellisense, command line section, remote editing section, container plugins, plugin installer, settings section etc etc on top of it Why? Neovim has multiple package managers. It has GUIs like https://github.com/neovide/neovide , it has support for LSP which can do something? Many people are c…

Yeah its basically a Do it Yourself kit, not sure if you got the message I wrote in my comment. That is a negative, not a positive. Majority of the people don't have the time, or in many cases competence to spend several man months/years building things like these. Even if you do, you still won't be close to the complete vscode experience.

Re: Lite: A lightweight text editor written in Lua

#60
post #43

Earlier quoted context omitted.

No, it is a command line thing. Neovim and vim are just the editor component of the bigger tools that is something like vscode. To get Neovim kind of things to be anywhere near usable for modern day development work, you need to bolt a file browser, intellisense, command line section, remote editing section, container plugins, plugin installer, settings section etc etc on top of it, and is not really a trivial job fo…

To get Neovim kind of things to be anywhere near usable for modern day development work… blah blah We don’t roll like that anymore; you can just use one of several distributions that are pre-configured; most of these are 1-line installs: bash It’s basically the best of both worlds—-IDE--like functionality all set and ready to go out of the box but totally customizable. And blazingly fast; launch times are * LunarVim:…

Tried to install LunarVim a few months back and it stubbornly refused to install because I had to manually install some dependencies, and then it had issues with the versions of those dependencies. It didn't even have a brew package.

Life is too short to waste working around these issues, when there is already vscode, why should one go about wasting hours to weeks of time working around these tools which don't even give a full experience.

In some cases, like this this tool in current discussion 'Lite' aren't even actively maintained(a.k.a abandonware).

Much ado about nothing

- William Shakespeare

Post reply on HN