From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: filebat Mark Newsgroups: gmane.emacs.help Subject: Re: Postfixing ' emacs' to all frame titles. Date: Sat, 31 Jul 2010 11:41:08 +0800 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=000e0cd2e012eafa60048ca6bc9d X-Trace: dough.gmane.org 1280547716 27419 80.91.229.12 (31 Jul 2010 03:41:56 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 31 Jul 2010 03:41:56 +0000 (UTC) Cc: help-gnu-emacs@gnu.org, Kevin Rodgers To: Lennart Borgman Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Jul 31 05:41:53 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Of2xM-00009v-4J for geh-help-gnu-emacs@m.gmane.org; Sat, 31 Jul 2010 05:41:52 +0200 Original-Received: from localhost ([127.0.0.1]:57804 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Of2xL-0008Fj-IR for geh-help-gnu-emacs@m.gmane.org; Fri, 30 Jul 2010 23:41:51 -0400 Original-Received: from [140.186.70.92] (port=45894 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Of2wh-0008Do-Gl for help-gnu-emacs@gnu.org; Fri, 30 Jul 2010 23:41:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Of2wg-0005xZ-4S for help-gnu-emacs@gnu.org; Fri, 30 Jul 2010 23:41:11 -0400 Original-Received: from mail-pv0-f169.google.com ([74.125.83.169]:58406) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Of2wf-0005xS-St for help-gnu-emacs@gnu.org; Fri, 30 Jul 2010 23:41:10 -0400 Original-Received: by pvc30 with SMTP id 30so1509495pvc.0 for ; Fri, 30 Jul 2010 20:41:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=ccBIn+92K8RoeS9XcRWqevapHdxhJlBOe/8f+v/ivB4=; b=K5d9oXU26C+hj+qQy0/xyJ6PIb5oeOgS8O6Pi/pJqxOTfXkRv2UCTqOFpFPmDZ5HhG pps9tJ5go7uwh8rzaHgVqb3xvUaNuF1c1eixEitWiRCqcaPcbYtMpZ9+5uo0KhzkFe2M rW2+e3zReXYY913ABTT0PA/qzYziTsuuDbxy8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=JBVNeTFHExM8t90LTF1RgG17T8SOAIubVtQjyGPSIU70urUPKTlUhuBx4FV9t40tzr mbXheGP8uaaeg+PtLr1vpPCGwS7uEeyDaPumpWFhyj0ma4QYncXAXhmsyyHV1tU0Uac9 RvDnSF8Z0opwvBo9F9k7suToSJcZ9L64Vij8Q= Original-Received: by 10.142.234.4 with SMTP id g4mr542030wfh.89.1280547668818; Fri, 30 Jul 2010 20:41:08 -0700 (PDT) Original-Received: by 10.142.209.12 with HTTP; Fri, 30 Jul 2010 20:41:08 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:74365 Archived-At: --000e0cd2e012eafa60048ca6bc9d Content-Type: text/plain; charset=ISO-8859-1 Hi Lennart I tried (setq frame-title-format "%f - Emacs"), it's cool. However, the full filename of "%f" is usually too long. Can I truncate the string with fixed length? Regards, Denny On 7/28/10, Lennart Borgman wrote: > > On Wed, Jul 28, 2010 at 3:14 PM, Kevin Rodgers > wrote: > > > > Tim Visher wrote: > >> > >> Hi everyone, > >> > >> I'm wondering if there's a simple way to postfix ' emacs' to all frame > >> titles without resorting to [elisp from the web][1]. Couldn't find > >> anything in Chapter 25 but I didn't search much harder than that. > >> > >> [1]: http://www.emacswiki.org/emacs/FrameTitle > > > > No, you need to use Emacs Lisp: that is the "format" of customizations > > in ~/.emacs (M-x customize notwithstanding). > > > > Here's what I use: > > > > (setq frame-title-format > > '("" invocation-name "-" emacs-version "@" system-name ":" > > (buffer-file-name "%f" "%b"))) > > > > In EmacsW32 I use > > (setq frame-title-format "%b - Emacs") > > This is probably what people on ms windows expect. Is that what people > on other GUI systems expect as well? > > -- Thanks & Regards Denny Zhang --000e0cd2e012eafa60048ca6bc9d Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi Lennart

I tried=A0 (setq frame-title-format "%f - Emacs"= ;), it's cool.

However, the full filename of "%f" is u= sually too long.
Can I truncate the string with fixed length?

Reg= ards,
Denny

On 7/28/10, Lennart Borgman <lennart.borgman@gmail.com> wrote:
On Wed, Jul 28, 2010 at 3:14 PM, Kevin Rodgers
<kevin.d.rodgers@gmail.com> wrote:
><= br> > Tim Visher wrote:
>>
>> Hi everyone,
>&= gt;
>> I'm wondering if there's a simple way to postfix ' em= acs' to all frame
>> titles without resorting to [elisp from = the web][1].=A0=A0Couldn't find
>> anything in Chapter 25 but= I didn't search much harder than that.
>>
>> [1]: http://www.emacswiki.org/emacs/FrameTitle
>
> No, = you need to use Emacs Lisp: that is the "format" of customization= s
> in ~/.emacs (M-x customize notwithstanding).
>
> Here&#= 39;s what I use:
>
> (setq frame-title-format
>=A0=A0= =A0=A0=A0=A0'("" invocation-name "-" emacs-version = "@" system-name ":"
>=A0=A0=A0=A0=A0=A0=A0=A0(buffer-file-name "%f" "%b"= ;)))



In EmacsW32 I use

=A0=A0(setq frame-title-fo= rmat "%b - Emacs")

This is probably what people on ms wi= ndows expect. Is that what people
on other GUI systems expect as well?




--
Thanks & Regards

Denny Zhang
--000e0cd2e012eafa60048ca6bc9d--