🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.vhdl
Article #478

Re: Custom indentation in Emacs Vhdl-mode

#478
From: haws
Date: Fri, 12 Jan 2007 17:58
28 lines
2541 bytes
Ok, thanks! I guess that solution will do!

I thought I'd have to change the syntactic meaning of "use", but
vhdl-mode is kinda complicated (20k lines), so I probably don't want to
mess there anyway :)

Mike Treseler escreveu:

> Hugo wrote:
> > So, any ideas on how to indent the use's relative to "library ieee" ? I
> > know it's pretty silly thing...
> >
> > The only way I know to accomplish that would be a post-beautifier
> > function that fixes those lines.. but this sounds rather ugly... :)
>
> Since I hijacked your thread, here's an idea.
>
> Yes. If you look at the source for vhdl-beautify-buffer you will
> see that it is pretty tightly wound. I would write a
> wrapper function called vhdl-align-use that would
> call beautify then find the first USE, insert three spaces, etc.
> Something like:
>
> (defun align-use () "Indent vhdl use clauses"
>   (vhdl-beautify-buffer)
>   (beginning-of-buffer)
> ;;code to search for "use" lines and insert three spaces goes here.
> )
Technical Details
Message-ID: <1168624707.414984.208870@l53g2000cwa.googlegroups.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!postnews.google.com!l53g2000cwa.googlegroups.com!not-for-mail
References: <1168527687.560869.42360@k58g2000hse.googlegroups.com> <3k2fq2l3lgvcfe7t45o1binaef0872p5ok@4ax.com> <50polbF1grf3jU1@mid.individual.net> <1168621500.477449.295080@l53g2000cwa.googlegroups.com> <50q047F1haip3U1@mid.individual.net>

Show Full Headers
Complete Article Headers
X-Google-Thread: 1089ad,6f128e08e545a086
X-Google-Thread: 103b8b,a3b884cc1c70814
X-Google-Attributes: gid1089ad,gid103b8b,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: arc1-ca.pugleaf.net!g2news2.google.com!postnews.google.com!l53g2000cwa.googlegroups.com!not-for-mail
From: "haws" <hugows@gmail.com>
Newsgroups: comp.lang.vhdl,gnu.emacs.help
Subject: Re: Custom indentation in Emacs Vhdl-mode
Date: 12 Jan 2007 09:58:27 -0800
Organization: http://groups.google.com
Lines: 29
Message-ID: <1168624707.414984.208870@l53g2000cwa.googlegroups.com>
References: <1168527687.560869.42360@k58g2000hse.googlegroups.com>
   <3k2fq2l3lgvcfe7t45o1binaef0872p5ok@4ax.com>
   <50polbF1grf3jU1@mid.individual.net>
   <1168621500.477449.295080@l53g2000cwa.googlegroups.com>
   <50q047F1haip3U1@mid.individual.net>
NNTP-Posting-Host: 201.21.235.16
Mime-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
X-Trace: posting.google.com 1168624719 17195 127.0.0.1 (12 Jan 2007 17:58:39 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Fri, 12 Jan 2007 17:58:39 +0000 (UTC)
In-Reply-To: <50q047F1haip3U1@mid.individual.net>
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; pt-BR; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 fw.datacom-telematica.com.br:3128 (squid/2.5.STABLE6)
Complaints-To: groups-abuse@google.com
Injection-Info: l53g2000cwa.googlegroups.com; posting-host=201.21.235.16;
   posting-account=pG57fA0AAADtQ-4h1MyvjXjZpSNZC0zj