New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request] Open Codi fullscreen in a 50/50 vertical split with an empty buffer #94
Comments
It could be behind a setting that is disabled by default, e.g: if (!exists('g:codi#fullscreen'))
let g:codi#fullscreen = 0
endif This will actually free up |
Hi @SidOfc, thanks for the feature request and the work you've done thus far on it! I think the notion of a fullscreen scratch is really workflow dependent, so I'm a bit hesitant to include it in the plugin. The code to configure it, as you have shown, is about a dozen lines long, so people can include it in their vimrc (like you have) on a want-to-use basis. However, I do like the idea of percentage-based splits; maybe we can parse I also think you bring up a good point that all of Codi's configuration is global. I would be open to adding configuration via local variables, to reduce the pain of one-off invocations with special settings. |
Hi @metakirby5, I completely understand that this feature is heavily workflow inspired and therefore may not be the right fit for the plugin. It could be a tip or trick in either a wiki or readme as well, I will look into adding this snippet somewhere other than this issue so that anyone can use this code. I would also love to see percentage support for It would even reduce the required snippet code and as you can see, it really only takes one line to do, maybe 2 when combining with user input. I could also write a PR for that instead, shouldn't take too long and I think I could even do it somewhere this week. I'm not exactly sure of a way to do one-off's for a particular invocation but that too sounds awesome! P.S. All this basically comes after playing around with it for about half an hour and being completely sold from that moment, thank you so much for providing us all with something like Codi 👍 😻 |
P.P.S. This issue can be closed if you want, whenever I have a PR for |
Hi there!
I came here to request a feature for this (awesome) plugin.
Out of the box Codi will always open with a fixed width next to the current buffer. In most of my use-cases I am debugging a large-ish file and I only want to focus on a small part of it, perhaps run some sample code to grasp exactly how it works or experiment with some new code or quickly demonstrate some feature etc...
What I wanted was essentially the following:
ruby
filetype for this example.ruby
(in this case)In this case, there are no "Actual results" I can offer. I have however, written a sample implementation of this functionality in my vimrc. It basically comes down to this:
The above function will always create a new empty tab with a
buftype=nofile
, set the filetype correctly, invert the LeaderLeader mapping and callCodi
.When LeaderLeader is pressed again, the current buffer will be destroyed and you will be returned where you left off.
I tested this snippet in the following Vim versions, each one working as expected:
Vim:
vim --version | head -5
MacVim:
mvim --version | head -5
NeoVim:
nvim --version | head -3
OS + version: macOS 10.13.6
Note: One issue I see here is that
g:codi#width
is overwritten, we could store it but we need to keep in mind that the buffer can be closed in unexpected ways (as I'm probably doing here with::silent! q!
).That's pretty much it, let me know if it is something worthwhile, I've already got my polyfill which works but wouldn't mind writing a proper PR for this either. I am quite busy this week but I could send a proposal somewhere next week if there is any interest.
If one of you implements it before I can, please by all means go ahead too :)
The text was updated successfully, but these errors were encountered: