Home Download Buy Blog Forum Support

Zen Coding ( CSS Snippets )

Re: Zen Coding ( CSS Snippets )

Postby firefusion on Sun Nov 28, 2010 9:20 am

Now this is probably very strange but i reinstalled the version on Google then open the default keymap and looked for the change here...

https://bitbucket.org/sublimator/zencod ... 87ff705fd8

Which had already been applied to that version but it still wasn't working for me. So I switch it back to the massive key binding that was removed and now my custom snippets and Zen are working fine together :)
firefusion
 
Posts: 218
Joined: Fri Oct 16, 2009 7:37 am

Re: Zen Coding ( CSS Snippets )

Postby firefusion on Mon Nov 29, 2010 5:16 pm

Spoke too soon. It has the bug of not working with snippets containing ":" :(
firefusion
 
Posts: 218
Joined: Fri Oct 16, 2009 7:37 am

Re: Zen Coding ( CSS Snippets )

Postby ignat on Sat Dec 04, 2010 2:33 pm

Zen-coding plugin is great. Thanks for that.

I have some questions:
1) Format CSS rule doesn't work - http://code.google.com/p/zen-coding/wiki/Filters
If you prefer this coding style, you'll definitely want to modify zen_settings file and add this filter as default one for CSS syntax. But remember: you should add html filter first

Have tryed to change alias to "html, fc" inside "Sublime Text\Packages\ZenCoding\zencoding\filters\format-css.py" - no effect.

2) Is it possible, to expand abbrreviations like "input:t" on Tab for html? Alt+E is not convenient.

3) How to add text inside link or some block, when we use ctrl+alt+enter? Like, we should get this:
Code: Select all
<div>
    <div>sometext</div>
    <div><a href="#">someanchor</a></div>
</div>

We type: div>div+(div>a)
What about text, which command is used for it?

4) html:5 doesn't work inside html files. Should I remove default sumlimetext packages for html and css?
On tab no effect, on alt+e it removes "html:5" and gives nothing.

5) How do I add for html snippet, extra edition point for #:
Code: Select all
'a': '<a href="#"></a>'

Like ${1:#} (if we don't change, it will keep #, else it should replace #)

6) Seems there are snippets and abbreviations for html, and none of them work on tab key? How to make them work for this key?

Thanks.
ignat
 
Posts: 4
Joined: Tue Jul 20, 2010 1:55 pm

Re: Zen Coding ( CSS Snippets )

Postby ignat on Sun Dec 05, 2010 12:18 pm

sublimator, some of the items are bug reporting...
ignat
 
Posts: 4
Joined: Tue Jul 20, 2010 1:55 pm

Re: Zen Coding ( CSS Snippets )

Postby ignat on Sun Dec 05, 2010 1:01 pm

sublimator, what about the most important, in html nothing from zen-coding works on tab?
Last edited by ignat on Mon Dec 06, 2010 4:55 pm, edited 1 time in total.
ignat
 
Posts: 4
Joined: Tue Jul 20, 2010 1:55 pm

Re: Zen Coding ( CSS Snippets )

Postby Sublimaz on Mon Dec 13, 2010 2:53 pm

this plugin is very buggy.

example - you get some big piece of code through ctrl+alt+enter command, then remove a half and... you have to press on Tab key dozens of times while counter for removed code will not be switched off.

the problem is about editing points for snippets, plugin doesn't know that sometimes I don't use them, so it always gives me an extra job - press on Tab and see that nothing changes (it jumps from removed editing point to another one removed, lol), you can feel yourself like an idiot. This bug is like a bunch into the sky.
Sublimaz
 
Posts: 18
Joined: Mon Dec 13, 2010 2:27 pm

Re: Zen Coding ( CSS Snippets )

Postby firefusion on Wed Dec 15, 2010 7:39 am

Wow, I just tried the new version on Bitbucket
https://bitbucket.org/sublimator/zencoding/

That's way better sublimator! All the bugs seem fixed and it's way faster it seems. Thank you!!!
firefusion
 
Posts: 218
Joined: Fri Oct 16, 2009 7:37 am

Re: Zen Coding ( CSS Snippets )

Postby Sublimaz on Wed Dec 15, 2010 11:35 am

sublimator, dude, snippets like .class { type something and press tab; } don't expand (when there is no new line).

also, when I have <div>|</div> and press Enter, its better to expand to
Code: Select all
<div>
    |
</div>

(with tab)

Not to
Code: Select all
<div>
|
</div>


similar to all block-level elemetns.

one more important bug - abbreviations and snippets expand only when you type shortcut without remarks. So, if you type fser and then remark it with fset, tab won't work for this. But alt+e works.
Sublimaz
 
Posts: 18
Joined: Mon Dec 13, 2010 2:27 pm

Re: Zen Coding ( CSS Snippets )

Postby Sublimaz on Thu Dec 16, 2010 4:59 pm

no, I'm using fixed 1.2.2 version (without last changes).

with extra keymap file inside A folder (zencoding/a/Default.sublime-keymap). Source of this file:
Code: Select all
<bindings>
   <binding key="/[A-Za-z0-9#.&gt;+*:$_!@-]+/,tab" command="zenHTML $1" uuid="59b1aa64-38c6-11df-84d2-00037af1a101">
      <context name="selector" value="text.html -   source - meta.tag, punctuation.definition.tag.begin, meta.scope.between-tag-pair.html"/>
      <context name="allSelectionsEmpty" value="true"/>
      <context name="allPreceedingText" value="(^|\s*)[A-Za-z0-9#.&gt;+*:$_!@-]*$"/>
      <context name="noFollowingText"   value="\S"/>
      <context name="hasNextField" value="true"/>
   </binding>
   <binding key="/[A-Za-z0-9#.&gt;+*:$_!@-]+/,tab" command="zenHTML $1" uuid="59b1aa65-38c6-11df-a961-00037af1a101">
      <context name="selector" value="text.html -   source - meta.tag, punctuation.definition.tag.begin, meta.scope.between-tag-pair.html"/>
      <context name="allSelectionsEmpty" value="true"/>
      <context name="allPreceedingText" value="(^|\s*)[A-Za-z0-9#.&gt;+*:$_!@-]*$"/>
      <context name="hasNextField" value="false"/>
   </binding>
</bindings>


so the shortcuts like "ul>li*8" now work for me by Tab. If I move these bindings to default keymap file (its be default), they work only by alt+e.

can you fix please cursor point for block-level elements? Like
Code: Select all
<div>
    |
</div>
Sublimaz
 
Posts: 18
Joined: Mon Dec 13, 2010 2:27 pm

Re: Zen Coding ( CSS Snippets )

Postby Sublimaz on Fri Jan 28, 2011 12:34 pm

Zen Coding doesn't work on sublimetext2?
Sublimaz
 
Posts: 18
Joined: Mon Dec 13, 2010 2:27 pm

PreviousNext

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 20 guests