From mboxrd@z Thu Jan  1 00:00:00 1970
Path: news.gmane.org!not-for-mail
From: Kan-Ru Chen <kanru@kanru.info>
Newsgroups: gmane.emacs.devel
Subject: Re: A patch for enforcing double-width CJK character display
Date: Wed, 11 Apr 2012 23:48:56 +0800
Message-ID: <87vcl646c7.fsf@isil.kanru.info>
References: <4F85A138.6090900@i-soft.com.cn>
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Trace: dough.gmane.org 1334159380 30829 80.91.229.3 (11 Apr 2012 15:49:40 GMT)
X-Complaints-To: usenet@dough.gmane.org
NNTP-Posting-Date: Wed, 11 Apr 2012 15:49:40 +0000 (UTC)
Cc: eliz@gnu.org, stepnem@gmail.com, emacs-devel@gnu.org
To: =?utf-8?B?6buE5bu65b+g?= <jianzhong.huang@i-soft.com.cn>
Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 11 17:49:38 2012
Return-path: <emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org>
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 <emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org>)
	id 1SHznc-0005ky-BT
	for ged-emacs-devel@m.gmane.org; Wed, 11 Apr 2012 17:49:36 +0200
Original-Received: from localhost ([::1]:53036 helo=lists.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org>)
	id 1SHznb-00009v-Ol
	for ged-emacs-devel@m.gmane.org; Wed, 11 Apr 2012 11:49:35 -0400
Original-Received: from eggs.gnu.org ([208.118.235.92]:53560)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <ckanru@gmail.com>) id 1SHznW-00009o-F8
	for emacs-devel@gnu.org; Wed, 11 Apr 2012 11:49:33 -0400
Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <ckanru@gmail.com>) id 1SHznO-0008Ig-6w
	for emacs-devel@gnu.org; Wed, 11 Apr 2012 11:49:30 -0400
Original-Received: from mail-pz0-f52.google.com ([209.85.210.52]:65133)
	by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <ckanru@gmail.com>)
	id 1SHzn9-0007td-Ed; Wed, 11 Apr 2012 11:49:07 -0400
Original-Received: by dake40 with SMTP id e40so1277367dak.39
	for <multiple recipients>; Wed, 11 Apr 2012 08:49:03 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
	h=sender:from:to:cc:subject:references:date:in-reply-to:message-id
	:user-agent:mime-version:content-type:content-transfer-encoding;
	bh=nJu4md6NrYfKzi4dJl4FqUQ/9Q76FngvkTXMhvs9Woc=;
	b=tWZ1y+zBPRn2qgv8tX7VD1s/fRAXO7/TCQwRD4QwyMjzmdf4T6U0nq+i1lIg+FhFRM
	Hxpn9gG88qv+U8vINsjtcqJd3KE9FupBWqOYMRNTp18yOgdJRPchrHX9PEoIhaCNNsb3
	bHHJzO7k2lGTyFqT5RN3ULaUuujGiG5UNR7WpMTZgWfT2IhxpbrCSh5Q6z8a6dAfmBg7
	5HXA5D5NNrVAK/wE6/4QfZonfx/UtojEOthHaTR414OiegQi9SLUJ4KDTqbs1Ola37Lh
	YAiHArAKtCQoaNgrz194nZ01uaJ35t1obJzzyHtZrw7faSbEHDEun2Cr9OCVZZ3JxmN8
	o9zg==
Original-Received: by 10.68.194.67 with SMTP id hu3mr22764474pbc.111.1334159343424;
	Wed, 11 Apr 2012 08:49:03 -0700 (PDT)
Original-Received: from isil.kanru.info (61-228-148-40.dynamic.hinet.net.
	[61.228.148.40])
	by mx.google.com with ESMTPS id y3sm3185917pbh.59.2012.04.11.08.49.00
	(version=TLSv1/SSLv3 cipher=OTHER);
	Wed, 11 Apr 2012 08:49:02 -0700 (PDT)
Original-Received: from localhost ([127.0.0.1] helo=isil.kanru.info)
	by isil.kanru.info with esmtp (Exim 4.77)
	(envelope-from <kanru@kanru.info>)
	id 1SHzmz-00037G-3z; Wed, 11 Apr 2012 23:48:57 +0800
In-Reply-To: <4F85A138.6090900@i-soft.com.cn> (=?utf-8?B?Ium7hOW7uuW/oCIn?=
	=?utf-8?B?cw==?= message of "Wed, 11 Apr 2012 23:20:24 +0800")
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 209.85.210.52
X-BeenThere: emacs-devel@gnu.org
X-Mailman-Version: 2.1.14
Precedence: list
List-Id: "Emacs development discussions." <emacs-devel.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/emacs-devel>,
	<mailto:emacs-devel-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/emacs-devel>
List-Post: <mailto:emacs-devel@gnu.org>
List-Help: <mailto:emacs-devel-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/emacs-devel>,
	<mailto:emacs-devel-request@gnu.org?subject=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:149600
Archived-At: <http://permalink.gmane.org/gmane.emacs.devel/149600>

[ CC:ed emacs-devel ]

Hi!

=E9=BB=84=E5=BB=BA=E5=BF=A0 <jianzhong.huang@i-soft.com.cn> writes:

> Here is a patch to fix double-width issue of CJK fonts when use Xft
> backend , just like some terminal did.

I like you idea to draw glyphs individually when the font is a CJK font.
I didn't realized that when the font changes, XftDrawGlyphs is called
again so we have a chance to examine the font!

Your patch probably needs some adjust to fit the coding style, but the
approach is great! Did you check that it also works with scaled fonts?
Like (text-scale-increase) multiple times.

  Kanru