I'd like to create a Lesson for Programmers, to teach Special-Keys like: {} [] () $%&/ and other. For this i'd like to add a lesson wich has Sourcecode inside: <?php echo "This is a lesson for teaching SourceCode-Typing"; if( $var == "myValue"){ echo "Yes it is"; else { print("No, it is not"); } ?> Problem to create such a lesson is, that the "tab"-Key (4 spaces), to indent the code not working on ktouch. Please make it possible to use ech of this keys. Reproducible: Always
First thanks for creating a lesson targeted at programmers. This could become a very valuable asset for KTouch. At the moment the the tab key is actively ignored by KTouch. Changing the event handling to allow tabs to be entered is easy, but I have also implement something that the user can distinguished tabs from normal spaces so he is able decide which key to press from looking at the lesson text. I the end I am not sure how useful the ability to train tabs is really. For one, not all source code is indent with tabs, but with spaces, although I agree indenting with spaces in training environment would be no fun at all since you have type a lot of spaces, which directly leads to my second argument: Almost everyone develops with some sort an advanced editor handling the indentation at least partially automatically. Therefore I don't see overly strong need to train typing of indentation at all and it makes the lessons less enjoyable as they could be. Maybe you should focus on single statements in your lessons? This would avoid the whole indentation issue altogether.
You could easy visualize a tab with a horizontaly brakcet with 4 spaces: |____|
Can be closed after nearly 10 years.... to tight the bug-list a bit. I see no chance, that this would ever be implemented.