Not signed in (Sign In)

Categories

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

  1.  permalink

    I’m not sure weather or not this is related to this bug, http://intype.info/forums/discussion/96/intype-removes-too-many-symbols/, but if you do this:

    1. Go to any line, hit tab (one or multiple times) at the beginning of the line, type something
    2. Select all of that line
    3. Cut the line
    4. Paste it back in

    The tab(s) at the beginning will have disappeared.

    • CommentAuthormartincohen
    • CommentTimeJan 16th 2007 edited
     permalink

    This is actually a feature, I was writing about it somewhere on the forums.

    When pasting text, the actual position of caret determines the indentation for pasted text. This will however change soon. This has been implemented as an experimental feature. It’s the same algorithm as when inserting a snippet.

  2.  permalink

    Yeah, I can see that its useful, I only discovered it by accident when I was actually taking advantage of the feature, but i can imagine some situations where you wouldn’t want it. Tricky one.

    • CommentAuthormartincohen
    • CommentTimeJan 16th 2007 edited
     permalink

    I’ll change the behavior with Auto-Indentation feature (0.2.3), and will make it more smart and right.

  3.  permalink

    Cool. Its defiantly a useful feature, I think the only change that would need to be made is that if the caret is at the very beginning of the line when pasting in, then paste as usual with any tabs, but if its indented at all then strip them. That would make the most sense I think.

  4.  permalink

    There are too many conditions when thinking like that. It needs some simple algorithm that will handle it easy and effective.

    There are for example cases when you select first line without indentation and next lines including indentation. What should be done then?

  5.  permalink

    Hmm, well the way that I though it could work was if you paste when the caret is at the beginning of a line, everything is pasted in, as is, without any removal of any tabs.

    But when you paste in when the caret is tabbed in, the minimum number of tabs should be removed from the text being pasted in. So, if for example your pasting in three lines, two with two tabs at the beginning, and one with three, then two tabs will be stripped from the beginning of every line. That way, the indentation is retained, and then additional tabs can be added back onto the beginning of each line, depending on where the caret was at the time of pasting.

    I guess it probably is more complicated than that, but that’s just one way.