From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.devel Subject: Re: "Adobe Brackets like" editing in emacs Date: Wed, 26 Mar 2014 22:35:44 +0100 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7bdc1bd0a7ed5004f5894234 X-Trace: ger.gmane.org 1395869797 7286 80.91.229.3 (26 Mar 2014 21:36:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 26 Mar 2014 21:36:37 +0000 (UTC) Cc: arthur miller , "emacs-devel@gnu.org" To: Mathias Dahl Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Mar 26 22:36:47 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1WSvV9-0003ev-Gc for ged-emacs-devel@m.gmane.org; Wed, 26 Mar 2014 22:36:47 +0100 Original-Received: from localhost ([::1]:50425 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WSvV9-0003jB-2U for ged-emacs-devel@m.gmane.org; Wed, 26 Mar 2014 17:36:47 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43774) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WSvV4-0003j4-Qx for emacs-devel@gnu.org; Wed, 26 Mar 2014 17:36:44 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WSvV3-0005fU-4X for emacs-devel@gnu.org; Wed, 26 Mar 2014 17:36:42 -0400 Original-Received: from mail-ie0-x236.google.com ([2607:f8b0:4001:c03::236]:55701) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WSvV2-0005bC-Ss for emacs-devel@gnu.org; Wed, 26 Mar 2014 17:36:41 -0400 Original-Received: by mail-ie0-f182.google.com with SMTP id y20so2353528ier.13 for ; Wed, 26 Mar 2014 14:36:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=wa8fBEk8p/HFLJtC7UiAYeZj+IDcGKatyhPY+F+mhOw=; b=bn39+IdWvQN+sqe5jMrbQDI/EC0Ex38rZYD54BLKQ75jTv+SeXS/gEPQ/UoleN5i5N ZDE1M6eQ0/7SBdYT0ZzYyX4rAy4MXx/M15Omi0UEyYfNM6vZb6mvYTuSgvLSZyTnuT7h UGxqmDdfrSe5YfwSvr+H8CL9PQgl+3VOckOr8L0BxG6pdJrpESy0ddJx3OkwZ7YkuL9O 0VMZ6pu8d63UY43tJj/0OAr0DO8IIkfsNfjpdz8LQKnl71dYm1TbtzNk5HUNjPnbk/nC oRZeE360pJ2vNwoLUzORqshWW87PS/eAF/htnv/fXVT68yCl072ba/LB8DXjirM4jyYP Nejg== X-Received: by 10.50.62.104 with SMTP id x8mr26532722igr.37.1395869784466; Wed, 26 Mar 2014 14:36:24 -0700 (PDT) Original-Received: by 10.42.229.1 with HTTP; Wed, 26 Mar 2014 14:35:44 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4001:c03::236 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:171017 Archived-At: --047d7bdc1bd0a7ed5004f5894234 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable I have tested Brackets a bit the latest days, using it beside Emacs. It was not as integrated to the browser as I thought, but it is still useful. I have used it to edit CSS files and mixed files. It looks up all the places that it think might apply to an element in HTML. Unfortunately it does not seem to have one of those features I really would like: Parsing CSS media queries. It does not tell me which media query is used where and what the limits are for them. It does not even show the media queries at all in the Quick Edit (which is the feature we are discussing). I think it is the same for CSS classes. I guess they just stopped the development before implementing such useful features. It is of course quite a bit more complex to implement that part, both on the parsing level and UI level. Still, it is useful. And implementing those simple features in Emacs would not be that hard, I think. A crucial part would be to setup the connection between different files. (A little bit of that is in nXhtml.) And yes, it could be used with other languages too. Perhaps it can be useful for class-based languages, but that requires good parsing. On Wed, Mar 26, 2014 at 10:21 PM, Mathias Dahl wrot= e: > Hi Arthur, > > This is a very interesting feature! Not only would it be useful for the > scenario described by you and others in this thread, but I also think it > would be useful for temporarily showing definitions from another place in > the same file that you are editing. Sure, there are tooltips, overlays an= d > whatnot that can do the same thing ("intellisense") but sometimes actuall= y > seeing the full definition right where you are might be useful. No need t= o > jump back and forth, with a key you could show the definition of a functi= on > where you are, and with another key it would be hidden. You would be able > to copy pieces of text from it and whatever. That being said, I have neve= r > ever seen a feature like this before, and that could be an indication tha= t > it is not actually useful, or no-one has thought of a crazy idea before t= he > Adobe people did it... > > /Mathias > > > On Tue, Mar 18, 2014 at 2:29 PM, arthur miller wr= ote: > >> Hi, >> >> my name is Arthur, and I just subscribed to this list. Though I am new t= o >> this list, I am not so new to Emacs.I have just a question/thought about= a >> feature I would like see in Emacs, hope you don't mind. >> >> Lately Adobes Brackets editor has got some popularity (It seems to be >> pretty much Emacs on javascript). I am not really into using it full tim= e, >> since I am good with Emacs, but I do like the idea of mulitple file edit= ing >> in one buffer. It is like context-aware multi-file editing or what it >> should be called. They use it to edit css or javascript while editing ht= ml >> file, s=C3=A5 that one does not have to switch between buffers/files. It= seems >> pretty handy, and I would kind-a like to see implementation for C/C++ >> (macros, templates) and so on. >> >> I think it shouldn't be impossible to do now, since Emacs already can >> split window and show multiple buffers. How difficult would it be to add= a >> mode/feature to "expand" a buffer (split window) under the current line = and >> load exact part of a file with of course correct langauge mode and so on= . I >> guess semantic package would be needed since it seems to be similar cont= ext >> awareness as it is needed for code completition. >> >> I am not knowledgable about Emacs internals, so I don't really know wher= e >> to hack, but wonder if something similar is already implemented or "on t= he >> way". >> >> >> > --047d7bdc1bd0a7ed5004f5894234 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
I have tested Brackets a bit the latest days, using it bes= ide Emacs. It was not as integrated to the browser as I thought, but it is = still useful. I have used it to edit CSS files and mixed files. It looks up= all the places that it think might apply to an element in HTML. Unfortunat= ely it does not seem to have one of those features I really would like: Par= sing CSS media queries. It does not tell me which media query is used where= and what the limits are for them. It does not even show the media queries = at all in the Quick Edit (which is the feature we are discussing).

I think it is the same for CSS classes.

I guess they just stoppe= d the development before implementing such useful features. It is of course= quite a bit more complex to implement that part, both on the parsing level= and UI level.

Still, it is useful. And implementing those simple features in Emacs wo= uld not be that hard, I think. A crucial part would be to setup the connect= ion between different files. (A little bit of that is in nXhtml.)

And yes, it could be used with other languages too. Perhaps it can be usefu= l for class-based languages, but that requires good parsing.

=


On Wed, Mar 26, 2014 at 10:21 PM, Mathias Dahl <mathias.dahl@gmail.co= m> wrote:
Hi Arthur,
<= br>
This is a very interesting feature! Not only would it be usef= ul for the scenario described by you and others in this thread, but I also = think it would be useful for temporarily showing definitions from another p= lace in the same file that you are editing. Sure, there are tooltips, overl= ays and whatnot that can do the same thing ("intellisense") but s= ometimes actually seeing the full definition right where you are might be u= seful. No need to jump back and forth, with a key you could show the defini= tion of a function where you are, and with another key it would be hidden. = You would be able to copy pieces of text from it and whatever. That being s= aid, I have never ever seen a feature like this before, and that could be a= n indication that it is not actually useful, or no-one has thought of a cra= zy idea before the Adobe people did it...

/Mathias


On Tu= e, Mar 18, 2014 at 2:29 PM, arthur miller <arthur.miller@live.com= > wrote:
Hi,

my name is Arthur, and I just subscribed = to this list. Though I am new to this list, I am not so new to Emacs.I have= just a question/thought about a feature I would like see in Emacs, hope yo= u don't mind.

Lately Adobes Brackets editor has got some popularity (It seems to be p= retty much Emacs on javascript). I am not really into using it full time, s= ince I am good with Emacs, but I do like the idea of mulitple file editing = in one buffer. It is like context-aware multi-file editing or what it shoul= d be called. They use it to edit css or javascript while editing html file,= s=C3=A5 that one does not have to switch between buffers/files. It seems p= retty handy, and I would kind-a like to see implementation for C/C++ (macro= s, templates) and so on.

I think it shouldn't be impossible to do now, since Emacs already c= an split window and show multiple buffers. How difficult would it be to add= a mode/feature to "expand" a buffer (split window) under the cur= rent line and load exact part of a file with of course correct langauge mod= e and so on. I guess semantic package would be needed since it seems to be = similar context awareness as it is needed for code completition.

I am not knowledgable about Emacs internals, so I don't really know= where to hack, but wonder if something similar is already implemented or &= quot;on the way".




--047d7bdc1bd0a7ed5004f5894234--