Not signed in (Sign In)

Categories

Vanilla 1.1.1 is a product of Lussumo. More Information: Documentation, Community Support.

    • CommentAuthornivaldo
    • CommentTimeJan 25th 2008
     permalink
    Hi,

    I have recently sent an email to Martin that went like this:
    I am now using Intype to do Ruby production code at work. I am getting more familiar with it and liking it ever so more. There is a quirk that I am not sure has already been reported...here it is:
    - let's say that you have some indented code and you press <enter>...you are taking to the next line with the same indentation...so far so good...however, if you decide to not place any code in that line because you want to have a visual separation between the last code segment and the next and you press <enter> again, you are taking to the next line with the same indentation...which is good, however, the line before that you left blank still has the spaces for the indentation...hhmmm...not so good. Do you agree?
    e.g.
    <space><space>hash = {}
    <space><space> (the spaces here should have been removed...)
    <space><space>array = []

    Martin responded to my email with this suggestion: well this is actually not a bug, but a feature. Once you insert a text, Intype never removes it. This would be rather optional functionality (such as `Clear whitespace at line end` on save). It's better than the alternative. But, I think that with custom command in JavaScript you will be able to work this out. Can you, please, post this to the forums, so people may discuss about it?

    So...thoughts? comments? suggestions?
    • CommentAuthorBen
    • CommentTimeJan 25th 2008
     permalink

    I would prefer a `Clear whitespace at line end` on save option.

    For me it seems the best solution.

  1.  permalink
    +1 for 'Clear whitespace at line end' on save option.
    •  
      CommentAuthordflock
    • CommentTimeJan 25th 2008
     permalink

    Yes, I agree – clear whitespace at line end on save, with javascript monkeying around if you want something else. Seem ok to me :)

    • CommentAuthorIngwar
    • CommentTimeJan 25th 2008
     permalink

    Automatic removal of white space characters from line ends could do a lot of harm. I think martin’s approach is right in this case. On the other hand I don’t consider automatically inserted indentation to be a part of that rule since it wasn’t the user who put those characters there in the first place. In EditPlus when you hit Enter and don’t decide to put any text there before hitting Enter again, all the inserted white space characters are being deleted, since the user did not modify that line. I think this is pretty intuitive behaviour and a great quality of life feature. It would be nice if Intype did the same.

    • CommentAuthordaryl
    • CommentTimeJan 25th 2008
     permalink

    When I use Intype I delete the characters manually. I have Intype setup to show indentation characters at the start and end of lines.

    At work I use Borland C++ Builder, which doesn’t save whitespace at the end of lines. I don’t know which I prefer. I like the way that in Borland I can move the cursor to anywhere in the file without creating whitespace up to the location.