indentation issue #27

Closed
opened 2011-02-21 15:09:33 +01:00 by marijnh · 6 comments
marijnh commented 2011-02-21 15:09:33 +01:00 (Migrated from gitlab.com)

On 8b5c31d4b8 , each time I return to the line the text is indented.

On 8b5c31d4b81efd31b017c31ac462f754e3b86f65 , each time I return to the line the text is indented.
marijnh commented 2011-02-21 15:11:56 +01:00 (Migrated from gitlab.com)

I'll need way more context to know what you're talking about here. Which demo page, which browser, what exactly does 'returning to the line' mean?

I'll need _way_ more context to know what you're talking about here. Which demo page, which browser, what exactly does 'returning to the line' mean?
marijnh commented 2011-02-21 15:17:26 +01:00 (Migrated from gitlab.com)

I've tested on firefox and chrome with same issue :

Code is following:

<script>
    var myCodeMirror =
    CodeMirror.fromTextArea(document.getElementById("text"), {
        lineNumbers: true
    });
</script>

Full code http://friendpaste.com/IPOddWE0fhil4NkAX6U6I

I've just a textarea on the page. return to the line means when I hit the return to create a new line it automatically indent from 2 chars next line: http://bayimg.com/HadKOAADP

I've tested on firefox and chrome with same issue : Code is following: ``` <script> var myCodeMirror = CodeMirror.fromTextArea(document.getElementById("text"), { lineNumbers: true }); </script> ``` Full code http://friendpaste.com/IPOddWE0fhil4NkAX6U6I I've just a textarea on the page. return to the line means when I hit the return to create a new line it automatically indent from 2 chars next line: http://bayimg.com/HadKOAADP
marijnh commented 2011-02-21 15:18:42 +01:00 (Migrated from gitlab.com)
Maybe try reading the manual? http://codemirror.net/2/manual.html#option_enterMode
marijnh commented 2011-02-21 15:21:49 +01:00 (Migrated from gitlab.com)

It's still odd that the default js mode indent from 2 spaces when you go on the line. This isn't usual at all.

It's still odd that the default js mode indent from 2 spaces when you go on the line. This isn't usual at all.
marijnh commented 2011-02-21 15:23:04 +01:00 (Migrated from gitlab.com)

You either didn't finish your line with a semicolon, or opened a new block.

You either didn't finish your line with a semicolon, or opened a new block.
marijnh commented 2011-02-21 15:35:09 +01:00 (Migrated from gitlab.com)

ok.

ok.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
codemirror/codemirror5#27
No description provided.