* make the default core.ignore_files more specific
instead of blanket ignoring all dotfiles, we define a list of folders
and files to ignore. this makes the overall experience better.
* fix wrong path pattern
* add ignore_files to user init
the original hamburger menu icon is confusing. It is not a menu
and clicking it doesn't do anything. There is no reason why
we can't draw lite-xl's icon in place of that.
* Added in native modules with suffixes, giving priority to those with matching architectures and platforms.
* PowerPC isn't x86, and it's x86_64.
* Changed things over to allow compiler to set a tuple, makes more sense from a build perspective.
* Spelling mistake.
* Added in arm target tuples.
Commonly `ctrl+shift+r` is used in most editors for find and
replace operations, also the regexreplacepreview.lua plugin makes
a more appropriate use of this binding.
* Added a smoothing option to font loading.
* Added a font strikethrough option to font loading.
* Fixed underline applying incorrectly in cases of non-underlined fallback fonts being used.
Co-authored-by: Guldoman <giulio.lettieri@gmail.com>
This allows to use the Unix separator without resulting in ugly
suggestions that added the Windows separator too.
For example:
Before: `data/` -> `data/\core\`
After: `data/` -> `data/core\`
This caused issues when saving the user module with commands defined
inside it, as it resulted in the user-defined commands trying to
overwrite themselves and failing.
When a command is performed with parameters, those are now passed to the
predicate.
The predicate can then return, after the validity boolean, any other
value that will then be passed to the actual command.
If the predicate only returns the validity boolean, the original
parameters are passed through to the actual command.
This allows predicates to manipulate the received parameters, and allows
them to pass the result of an expensive computation to the actual
command, which won't have to recalculate it.
String and table predicates will now also return `core.active_view`.
When no `root` is specified and the initial `path` is empty, the initial
`path` becomes `.`.
This results in returned files/dirs that are prepended with `./`.
Now, in that case, `./` is removed.
This is mainly done to avoid requiring from the current working
directory of the editor.
This also avoids requiring from system paths, as it was already the case
for the native modules search path.
* Fix "hard" indent column info on status view.
* Update tabs calculation and add "byte" number info
* Add config.show_char_byte_info
* Add show char byte toggle command.
it should be added on the commands/statusbar.lua, but there is no config module loaded before and i won't to add it.
* Update config.lua
* Update statusview.lua
This is needed because users could try to enable plugins with
`config.plugins.plugin_name = true`.
Before, this would result in `common.merge` throwing an error; now it
just returns a copy of the "base" table.
The number of results from a pattern with groups must never be greater
than the number of token types for that pattern.
Also if a token type was undefined, it's now pushed as a `normal` one.
Before, this was only supported by Lua patterns.
This expects the regex to use the same syntax used for patterns. That
is, the token should be split by empty groups.
* Modified autoreload to use new dirwatch infrastructure, and added in nagview to verify that fs changes don't stomp on our changes, unless you want them to.
* Split out reload functionality to actual document, and added in a thread to check the document, in the cases where it wouldn't be covered by dirwatch.
* As per request from jgmdev, added in ability to show nagview always.
* Changed things over to use dirwatch.
* Made sure we redrew things, added in a contingency in 'save' for times when we load a non-existent file, and added some checks.
* Prevent adding duplicate bindings
* Clean reverse_map on overwrite or add direct
* Added get_bindings to complement get_binding
* Added doc comments for easier comprehension
* Check if command is function on add_direct
Currently some plugins had/have issues with predicates that check
if active view is a docview to perform certain operations like draw
in the case of minimap or lineguide. Since is() was checking the
entire inheritance tree it was returning true for views that inherit
from the same parent, which caused CommandView to be matched along
DocView, etc... This change does the following to solve the issue:
* Make Object:is() only match the top level parent of the object which
is more in line with what one would expect from a method named 'is'.
* Introduces Object:extends() which keeps the same functionality that
Object:is() offered before.
* Change to 1 click as per RFC on discord, with 100% in favour.
* Added in the ability to specify as a view name, so it doesn't modify the title, and also fixed a bug where if you clicked *over* the amount of times your config says, it wouldn't regsiter.
* Changed plugin to use keymap.
Using `get_active_node` might result in a locked `Node`; calling
`add_view` on that `Node` throws an error.
`get_active_node_default` always returns an unlocked `Node`.
* Send `mouseleft` event when the mouse leaves the window
* Call `View:on_mouse_left` when the mouse leaves the `View`
Previously `View:on_mouse_left` was called only when the mouse left the
window, and it was called on every visible `View`.
Now it gets also called when the mouse "changes" `View`, and only the
last `View` the mouse was on will receive the event.
Before the addition of multi-cursor support, we just returned the second
return value of the "replacer" function to the caller.
With the introduction of multi-cursors, we naively summed the second
return values for each cursor.
In some cases the "replacer" function doesn't return any second value,
so we tried to do math with `nil`, thus throwing errors.
Now the second return value is added to a table which is then returned
to the caller.
* Change to 1 click as per RFC on discord, with 100% in favour.
* Added in the ability to specify as a view name, so it doesn't modify the title, and also fixed a bug where if you clicked *over* the amount of times your config says, it wouldn't regsiter.
* Changed plugin to use keymap.
This allows `keymap.add` to map shortcuts to functions.
If the function returns `false`, the next command is executed (as if the
`predicate` of a `command` failed).