Comments (11)
I use the ZenCoding package as well, and your test case is working just fine for me. Are you sure both packages are updated to the most recent?
from less-sublime.
I believe they are. At least within the last week or so. I've just recently started using Sublime. I am on a Mac, however. Though I don't know if that would be relevant.
I couldn't find the binding for "Tab" expression expansion in the ZenCoding package to look at or edit its scope selector. It wasn't in the usual keymap settings file, at least.
from less-sublime.
If you're using Package Control, you can pull up the command palette shift+cmd+p
, type in Upgrade Package
and it will list any packages that are out of date. Please make sure you do this to rule out old versions.
from less-sublime.
It's saying there's nothing to update. I may try reverting all of my keymap files. Maybe I broke something while configuring keys. Though I didn't do that much :S
from less-sublime.
I've just reverted all preferences and commented all of my custom keymappings, and completely destroyed the ZenCoding and LESS packages (including the "Backups" folder which I noticed was preserving preferences?) and reinstalled them both. Also after removing pretty much all of my other packages to avoid conflicts.
Press "tab" in a .less file still doesn't do anything besides add a tab (I restarted Sublime). Blarg.
from less-sublime.
Oh I see what's happening now. I've never used tab completion for the ZenCoding package. I always use the "zen as you type" command (which is pretty awesome btw: ctrl+alt+enter
). It looks like you're right.. the synthesized tab snippets are not working properly. It looks like ZenCoding is also conflicting with Sublime's native auto-complete as well. This issue should be moved to the ZenCoding package for sure.
https://bitbucket.org/sublimator/sublime-2-zencoding
from less-sublime.
Ah, okay. I've posted on that project. Still, did you notice that the scope reports differently inside the body {|} in LESS than in CSS? LESS seems not to have a meta.property-list.css equivalent. But you're confident that has nothing to do with the failed "tab" functionality?
Thanks again for your help with this! I'll make due with Zen As you Type :P
from less-sublime.
Yea, the LESS tmLanguage is a different beast than CSS.. because of the nesting and all.
For what it's worth, I did figure out how to fix the native Sublime autocomplete by editing the ZenCoding config. But unfortunately it disables all tab-completions (along with the zen auto-complete tips). For folks like me who only use zen as you type
this is a viable workaround.
Packages/ZenCoding/zen-coding.sublime-setting
"disable_completions": true,
from less-sublime.
Ah, I edited something similar on line 31 of Packages/ZenCoding/zencoding/zen_settings.py
I hadn't noticed anything missing in the autocomplete though? Though I've had LESS and ZenCoding installed from Day 1 of using Sublime, so I'm likely to start seeing new things now, then... Heh.
Thanks again!
from less-sublime.
@aaronmw yea when disable_completions: false
Zen will override Sublime's native (and really helpful) auto-complete with the contextual snippets. Ideally, they could both coexist peacefully- but Zen seems to be strictly matching against css properties & values.
from less-sublime.
I've noticed some different suggestions, but Sublime's suggestions (besides "color") seem to be pretty lacking? Like "w" autocompletes to "width", but not "width: |;" which I guess is what Zen is for.
Also, I've just noticed that this setting is required to be "true" in order to have Zen auto-expand when pressing tab (in HTML, anyway):
// When enabled, pressing tab will insert the best matching completion.
// When disabled, tab will only trigger snippets or insert a tab.
// Shift+tab can be used to insert an explicit tab when tab_completion is
// enabled.
"tab_completion": true
That's in Sublime's Preferences.sublime-settings file, and with it "true" (as I've always had it, apparently) you can type "ul>li*5" in HTML and just press TAB to expand it, rather than Zen as you Type. It's this functionality that just doesn't seem to be firing in LESS documents, but almost certainly because Zen is being too picky about what it figures is a CSS file. A glance at these two files suggests it's pretty hard-coded to work with CSS and SCSS files.
Packages/ZenCoding/sublimezen.py
Packages/ZenCoding/sublimezenplugin.py
Unless I'm reading them wrong. I'm no Python developer.
from less-sublime.
Related Issues (20)
- Variables' names with @media breaks syntax highlighting
- Mixin indentation issue HOT 3
- 2.1.0 can not work in vue HOT 1
- <style lang="less"><style> HOT 3
- Single line commenting does not work in ST 3.1 (stable) HOT 1
- Comment Block Sublime 3 HOT 8
- Less autocompile not working in Network file HOT 1
- Highlighting for Ruleset Maps is broken HOT 3
- New error in Sublime about LESS package HOT 1
- Sublime 2 crashes HOT 1
- Sync up with Sass
- Differences in colouring HOT 4
- CSS property completion inconsistency HOT 1
- Improve symbol index and goto definition HOT 1
- ` @page` breaks syntax HOT 1
- Syntax highlighting breaks when using Maps lookup syntax HOT 1
- Red error on nested curly braces HOT 3
- Autocomplete variables AFTER a property does not seem to work? HOT 14
- Less syntax highlighting does not take effect HOT 1
- LESS for ST4 HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from less-sublime.