4coder » Forums » For anyone who is interested, here is my take on 4coder modal custom layer
nicoco
nj
22 posts
#13643 For anyone who is interested, here is my take on 4coder modal custom layer
6 months, 3 weeks ago Edited by nj on June 8, 2018, 5:40 a.m. Reason: Moved to Gitlab

I put some work in here, so I figured it can be nice for new users to look at it as a reference for customizing (or use it if they like the idea).
4coder_modal on gitlab.
It is still experemental and I'm updating it as I go, so don't count on it to be solid enough to not crash in the middle of your work.
Mr4thDimention
Allen Webster
382 posts
2 projects

Heyo

#13646 For anyone who is interested, here is my take on 4coder modal custom layer
6 months, 3 weeks ago

Woah, this is substantial!

I'm going to start reading this tonight to see what you've got going on here.

Are you open to questions? Would you like my notes on it?
nicoco
nj
22 posts
#13648 For anyone who is interested, here is my take on 4coder modal custom layer
6 months, 3 weeks ago Edited by nj on Nov. 30, 2017, 10:06 a.m.

Of caurse (for both)! also you can use anything you like from it. I love your work and I'd be happy to help it :)
nicoco
nj
22 posts
#13649 For anyone who is interested, here is my take on 4coder modal custom layer
6 months, 3 weeks ago

Also, I hope you're not angry about me copying some of your functions to change very small things and posting it there...
joe513
22 posts
#13650 For anyone who is interested, here is my take on 4coder modal custom layer
6 months, 3 weeks ago Edited by joe513 on Nov. 30, 2017, 1:14 p.m.

Thanks for sharing this, I will be trying it out this weekend.
nicoco
nj
22 posts
#13668 For anyone who is interested, here is my take on 4coder modal custom layer
6 months, 3 weeks ago

I've added a partial implementation for keyboard macros. It's still buggy and lacking (some things are not yet supported in 4coder), but I've already found it very useful when performing repeatative tasks.
You can check it out in the repo.
nicoco
nj
22 posts
#13934 For anyone who is interested, here is my take on 4coder modal custom layer
5 months, 2 weeks ago Edited by nj on Jan. 7, 2018, 1:49 p.m.

Added a search mode, added support for pasting into a search query (only with the search mode) o/
Also, while not working with macros it doesn't crash 4coder.

Edit: now search works partially with macros (printing won't work, only playing back).
Edit2: added also partial support for goto in macros.

Allen if you see this: adding a set_command_input procedure will make my macros sooooo happpyyyyy :D
nicoco
nj
22 posts
#14243 For anyone who is interested, here is my take on 4coder modal custom layer
4 months, 2 weeks ago

Added "desc" command to describe a given key binding command, using the new command metadata system.
nicoco
nj
22 posts
#15508 For anyone who is interested, here is my take on 4coder modal custom layer
2 weeks, 4 days ago Edited by nj on June 6, 2018, 11:06 a.m.

Updated the custom layer to support 4coder 4.0.27, adding the steps that I needed for the upgrade:
1
replaced `Range get_range(View_Summary *view)` with `Range get_view_range(View_Summary *view)`

1
replaced `clipboard_copy(Application_Links *app, int32_t start, int32_t end, Buffer_Summary *buffer_out, uint32_t access)` with `bool32 post_buffer_range_to_clipboard(Application_Links *app, Partition *scratch, int32_t clipboard_index, Buffer_Summary *buffer, int32_t first, int32_t one_past_last)`

1
2
replaced `bool32 get_current_name(char **name_out, int32_t *len_out)` with `global_config.user_name`
Note that the way to get the config variables changed - now you can access the global_config struct directly.

1
replaced `default_4coder_initialize(Application_Links *app)` with `default_4coder_initialize(Application_Links *app, int32_t override_font_size, bool32 override_hinting)`


Notes for Allen:
The meta generators tends to add undefined garbage to the meta tables from the example files. On Linux the linker fails silently, and the error message does not make sense. On Windows the situation is better as the linker gives meaningful error messages.
Mr4thDimention
Allen Webster
382 posts
2 projects

Heyo

#15512 For anyone who is interested, here is my take on 4coder modal custom layer
2 weeks, 4 days ago

nicoco

Notes for Allen:
The meta generators tends to add undefined garbage to the meta tables from the example files. On Linux the linker fails silently, and the error message does not make sense. On Windows the situation is better as the linker gives meaningful error messages.


Ahh shoot, that's a bit of a tricky situation, but I definitely have to do something about that. Thanks for bringing it up.