atom-haskell / ide-haskell

Haskell IDE plugin for Atom editor

Home Page:https://atom.io/packages/ide-haskell

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Annoying auto-ident behavior when pasting code

jhrcek opened this issue · comments

When I want to paste some code (using Ctrl+V) the editor does not take the current cursor's position into consideration. Instead it indents the pasted code below previous definition.

Steps to reproduce:
Write a function with some indented code like

f :: Int
f = g 0
  where
    g x = x + 1

Then copy it and paste it below the definition, making sure the cursor is in the first column below the definition before pressing Ctrl+V.
Actual behaviour: the pasted definition is indented below g of previous definition
Expected behaviour: the pasted definition begins where I placed the cursor.

Would it be possible to let the code be pasted where my cursor was without indenting it (which is the most intuitive behaviour you get in most other text editors)?

annoyinautoindent

Not really related to ide-haskell package, but oh well...
image

Oh, so that was the cause :-) Thanks for the tip. I'm closing the issue.