Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
LESS support
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  7 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
IschaGast  
View profile  
 More options Jul 4 2012, 2:46 am
From: IschaGast <cont...@ischagast.nl>
Date: Tue, 3 Jul 2012 23:46:29 -0700 (PDT)
Local: Wed, Jul 4 2012 2:46 am
Subject: LESS support

I am a big fan of zencoding but it looks like there is no LESS support in
Sublime Text, is there a way to get this working?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sergey Chikuyonok  
View profile  
 More options Jul 4 2012, 4:01 am
From: Sergey Chikuyonok <serge....@gmail.com>
Date: Wed, 4 Jul 2012 12:01:53 +0400
Local: Wed, Jul 4 2012 4:01 am
Subject: Re: LESS support

The simplest solution is to modify zencoding/interface/editor.py file.  
You should update get_syntax() method (line 168) so it matches LESS scope but returns it as CSS.  

This method may look like this:

def get_syntax(self):
    """
    Returns current editor's syntax mode
    @return: str
    """
    view = active_view()
    scope = view.syntax_name(view.sel()[0].begin())
    default_type = 'html'
    doc_type = None

    try:
        if 'xsl' in scope:
            doc_type = 'xsl'
        else:
            doc_type = re.findall(r'\bhtml|js|less|css|xml|haml\b', scope)[0]
            # Sublime has back to front scopes ....
    except:
        doc_type = default_type

    if doc_type == 'less':
        # serve LESS documents as CSS
        doc_type = 'css'

    if not doc_type: doc_type = default_type
    return doc_type

___________________________________________
Сергей Чикуёнок
http://chikuyonok.ru
serge....@gmail.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jakethesnake  
View profile   Translate to Translated (View Original)
 More options Jul 11 2012, 7:44 am
From: jakethesnake <jake....@gmail.com>
Date: Wed, 11 Jul 2012 04:44:20 -0700 (PDT)
Local: Wed, Jul 11 2012 7:44 am
Subject: Re: LESS support

Hi there,

Is there a way to add Zen coding support to LESS files with Espresso for
mac? I am also looking to see if this is supported within PHPstorm software
also?

Thanks in advance


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sergey Chikuyonok  
View profile  
 More options Jul 11 2012, 7:53 am
From: Sergey Chikuyonok <serge....@gmail.com>
Date: Wed, 11 Jul 2012 15:53:10 +0400
Local: Wed, Jul 11 2012 7:53 am
Subject: Re: LESS support

It’s pretty hard right now: you have to modify minified JS file and update getSyntax() method of ZenEditor object in order to detect and handle LESS syntax.  
I’m working on new Zen Coding version with Espresso developers and I think new version will feature basic LESS support.

PHPStopm plugin is developed by JetBrains team from scratch so you’d better ask them.  

___________________________________________
Сергей Чикуёнок
http://chikuyonok.ru
serge....@gmail.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jakethesnake  
View profile   Translate to Translated (View Original)
 More options Jul 11 2012, 7:58 am
From: jakethesnake <jake....@gmail.com>
Date: Wed, 11 Jul 2012 04:58:55 -0700 (PDT)
Local: Wed, Jul 11 2012 7:58 am
Subject: Re: LESS support

Wow what a speedy reply!

Never used Google groups before, but this is great thanks! Yes I had a look
at the minified js file but it looked a bit too much. Thought it would be a
simple thing like adding a ".less" next to the ".css" and ".html" in a
settings file.

If you have something sorted for now, perhaps you could send me files that
I could replace within my TEA of Espresso package folder?
-Its fine if you dont.

Thanks for your help thus far!
-Jake


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sergey Chikuyonok  
View profile  
 More options Jul 11 2012, 8:04 am
From: Sergey Chikuyonok <serge....@gmail.com>
Date: Wed, 11 Jul 2012 16:04:57 +0400
Local: Wed, Jul 11 2012 8:04 am
Subject: Re: LESS support

In minified zen.js file, find ZenEditor.prototype.getSyntax function. The first variable is a map of Espresso syntax selectors and Zen Coding’s syntax and looks like this:
var c={"css, css *":"css","xsl, xsl *":"xsl","xml, xml *":"xml","haml, haml *":"haml"};

Try to add LESS syntax and map it to Zen Coding’s CSS syntax:
var c={"less, less *": "css", "css, css *":"css","xsl, xsl *":"xsl","xml, xml *":"xml","haml, haml *":"haml"};

___________________________________________
Сергей Чикуёнок
http://chikuyonok.ru
serge....@gmail.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jakethesnake  
View profile   Translate to Translated (View Original)
 More options Jul 11 2012, 8:16 am
From: jakethesnake <jake....@gmail.com>
Date: Wed, 11 Jul 2012 05:16:17 -0700 (PDT)
Local: Wed, Jul 11 2012 8:16 am
Subject: Re: LESS support

yes!! that worked!

Thank you so much!! you are the Zen master!! =)


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »