course change for Kephra
Kephra, an editor for programming (mostly Perl) written in WxPerl is my main project since I stumbled into the Perl community. Most people I know already heard of it - but I want to write about a new development that might be helpful for some, which might consider to use it even if it has a very limited feature set (forth rewrite baby!).
It was silent for some time - because being my main project - I tried to cram all my other ideas, mainly KBOS into it which bogged progress down. Maybe there will be an Object System just for Kephra, solving some issues I saw nowhere else dressed. But for now I'm surprised how much progress is possible, If you just focus on churning out features.
I took stage sed (which is the bare minimal editor I once wrote as proof of concept) and just started to adding features and fixing issues. Sed stands for Single document EDitor and that is all what next release will bring. Am I serious ? and why should you care? Well I'm German - we never joke and it has strengths in its editing capability which sound like - 'duh its an editor - but if you see how many so called Editors and IDE neglect this area while focusing on the big guns like refactoring, debugging and git integration.
But what do I mean with editing is the ability to navigate and shape text as easily as possible. For illustration lets consider the following scenario:
I want to add a sub to a class which is somewhat similar to another already existing. So i skip the subs down in the file by hitting thee times <Ctrl>+<PgDown> and were thereat the start of the sub. To select it its enough to hit <Ctrl>+<Shift>+<Down> twice and we have both blocks which selected - <Ctrl>+<C> obviously copies the selection. Now we have to go back where we were editing - <Ctrl>+<E> - done. And then <Ctrl>+<V> - the sub is pasted and we can start to take what we need from it. The first two line we can discard - <Ctrl>+<X> twice. Yes its the normal cut command but if nothing is selected it cuts the current line, because 1) why waste precious key space (I'm looking at you nano) and 2) as programmers we think in line of code anyway and 3) it's not like we overloaded the command with something radically different. Then the next 3 lines have to move to the end - but to select them from start to end are too much key strokes. So lets just move the cursor into the first line, press <Shift> and <Down> twice. It is enough the selection spans on arbitrary positions over the 3 lines in question. Now hit <Alt> and lets got for a ride Move the line with cursor (<Up> and <Down>) but also <Left> and <Right> the indent and dedent - which is especially handy if you move single lines (which doesn't even needs selection).
Some of the other very simple but deeply practical features are doubling text and rectangular selection to editing several lines at ones. And its the many little details like a search bar that can not cover text like a search dialog. which can be easily extended into replace bar and back. A block comment functions which comments all selected lines with '#~ ' so it doesn't interfere with special comment (which you can still use with another command) and the space at the end of '#~' is also important so you can still read the commented code easily. Its not rocket science but lot of work and eye for details.
Good - now you know what I mean by editing. More features to come and the next stage (1.n releases) will have more than one doc, a little project handling and a config dialog. But let's not get ahead of ourselves again. Kephra is meant to be easy to use, configurable hackable, but for deep feature sets you need integrate specialized tools.