Fixes #131. Change scope type to text.#132
Open
tad-lispy wants to merge 1 commit into
Open
Conversation
It seems Sublime Text 2 have a habit of pushing subsequent lines of wrapped **code** one indentation level to the right. It does not do this with **text** (as opposed to code). Whether scope is considered code or text depends on `scopeName` property. If it starts with `source.` - then it's code. If it starts with `text.` - then it's text. Probably it would be better to make prose text and code - code, but I don't know how to. I think this change makes sense in a way. In literate programming we focus on prose. So it's more text then source... Kinda :)
Owner
|
Thanks for doing the research. Before I merge -- are you sure that this is the only way to get the desired non-indented behavior? |
Author
|
Honestly I am not. Everything I know about syntaxes in ST2 I've learned while trying to resolve this issue. I've red this document about syntax definitions. It seems to mainly address ST1, but some info is relevant to 2 as well. Since your last comment I've spent some extra time and found nothing new. Also I am not sure if there will be any side effects with this change. I've changed this in my setup and everything seems to work. |
gregschlom
added a commit
to gregschlom/SublimeWiki
that referenced
this pull request
Jun 4, 2014
Before this fix:
Lorem ipsum dolor sit amet, consectetur adipisici
elit, sed do eiusmod tempor incididunt labore
et dolore magna aliqua. Ut enim ad minim veni,
quis nostrud exercitation ullamco laboris
After this fix:
Lorem ipsum dolor sit amet, consectetur adipisici
elit, sed do eiusmod tempor incididunt labore et
dolore magna aliqua. Ut enim ad minim veni, quis
nostrud exercitation ullamco laboris
More info here: jashkenas/coffee-script-tmbundle#132
"It seems Sublime Text 2 have a habit of pushing subsequent lines of
wrapped code one indentation level to the right. It does not do this
with text (as opposed to code). Whether scope is considered code or text
depends on scopeName property. If it starts with `source`. - then it's
code. If it starts with `text`. - then it's text."
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It seems Sublime Text 2 have a habit of pushing subsequent lines of wrapped code one indentation level to the right. It does not do this with text (as opposed to code). Whether scope is considered code or text depends on
scopeNameproperty. If it starts withsource.- then it's code. If it starts withtext.- then it's text. Probably it would be better to make prose text and code - code, but I don't know how to.I think this change makes sense in a way. In literate programming we focus on prose. So it's more text then source... Kinda :)
EDIT: Sorry. I thought if I name my commit like that it will be attached to #131 . Can this be merged with it?