From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id EBtaG/OfjmB93gAAgWs5BA (envelope-from ) for ; Sun, 02 May 2021 14:49:55 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id sAsPF/OfjmAwcwAA1q6Kng (envelope-from ) for ; Sun, 02 May 2021 12:49:55 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id BD7BB2DE60 for ; Sun, 2 May 2021 14:49:54 +0200 (CEST) Received: from localhost ([::1]:43428 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldBXk-00050O-6H for larch@yhetil.org; Sun, 02 May 2021 08:49:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36252) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ldBX0-0004zA-HT for emacs-orgmode@gnu.org; Sun, 02 May 2021 08:49:06 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:59327) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ldBWv-0003od-RC for emacs-orgmode@gnu.org; Sun, 02 May 2021 08:49:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ldBWv-0006ut-ON for emacs-orgmode@gnu.org; Sun, 02 May 2021 08:49:01 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#48148: 27.2; ox-ascii breaks TITLE line wrongly when 2 width char is used Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: emacs-orgmode@gnu.org Resent-Date: Sun, 02 May 2021 12:49:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48148 X-GNU-PR-Package: org-mode X-GNU-PR-Keywords: To: Nicolas Goaziou Received: via spool by 48148-submit@debbugs.gnu.org id=B48148.161995972026569 (code B ref 48148); Sun, 02 May 2021 12:49:01 +0000 Received: (at 48148) by debbugs.gnu.org; 2 May 2021 12:48:40 +0000 Received: from localhost ([127.0.0.1]:42638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldBWZ-0006uT-RD for submit@debbugs.gnu.org; Sun, 02 May 2021 08:48:40 -0400 Received: from eggs.gnu.org ([209.51.188.92]:56162) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldBWX-0006uL-SU for 48148@debbugs.gnu.org; Sun, 02 May 2021 08:48:38 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:60126) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldBWS-0003ZT-Kk; Sun, 02 May 2021 08:48:32 -0400 Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3054 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ldBWS-0001lO-3g; Sun, 02 May 2021 08:48:32 -0400 Date: Sun, 02 May 2021 15:48:14 +0300 Message-Id: <83tunl714h.fsf@gnu.org> From: Eli Zaretskii In-Reply-To: <871rap9vn3.fsf@nicolasgoaziou.fr> (message from Nicolas Goaziou on Sun, 02 May 2021 14:18:24 +0200) References: <87h7jm2es2.wl-shingo.fg8@gmail.com> <83bl9t8vnb.fsf@gnu.org> <87h7jla6ih.fsf@nicolasgoaziou.fr> <8335v58ppu.fsf@gnu.org> <871rap9vn3.fsf@nicolasgoaziou.fr> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: emacs-orgmode@gnu.org List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: shingo.fg8@gmail.com, 48148@debbugs.gnu.org Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1619959794; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post; bh=MyacBmMdlxrB91WRESPE2yWkh1jcYnwAAK3ICiuyii8=; b=NUo1Z1BKAIZ5je77lqfL1ocPHrHmoROAAA63AhTC4tcdH308O0C3GI76F7vAGqCJjTR1hP 7U2NWoHQvHieO6DYQYwWi5I3Tgfqntbl9Z+bQWlhA3m2AUu0WmAuWreulZIfPFu+m+r434 091D3dsWWyQyAEgJhd8cqakCZ+cgvswVT9e5SNbbtsb6JTQRGQvQjr2sgRf6e8DxA+XPZB HrST2vyvgBQ9a7UBGUci0eBoMAcuD1az4Ee0uAY+noPmGFYDkSVW+OXjP2+LjeYwxGobet YqE1JiFyOGJujkIypuBHCfbKXxjEVWRby8L5hFJi/+YdOd4W7uKVRFAX0s2wFg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1619959794; a=rsa-sha256; cv=none; b=oMOD4/2pK7zt0aMOryBNog/gUpDdtHCQVuNVa9DFJmJGwhs7hruyECw8BDkxfZVBpsj6yF HaX/lsXD6r1WGfbrxe22nB34vCmbeq6vE7RgNbSnZR4TaTOsJYhuszPS8uLJ3W8O/2qDPg a0/ugPUP23zhsvpTTla4SYJydQadIqJc0AX49+rGGGX/CD2wXuMXnqyzspcse1LJREa+lt exsnNokkS8h/UuXHInElmGnPJGmVXWWLWHNSfA6i4/K7Geqj+VN6Htr+b0VnXXlipX0ugm xQYw3izGd+TsURA9Kf0KOu0T2I3Z0iQAXF7W5Q1KQyjeSY0/+ycL0/e4CgzZjw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -1.46 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: BD7BB2DE60 X-Spam-Score: -1.46 X-Migadu-Scanner: scn0.migadu.com X-TUID: L8wV8CSGrA7H > From: Nicolas Goaziou > Cc: shingo.fg8@gmail.com, 48148@debbugs.gnu.org > Date: Sun, 02 May 2021 14:18:24 +0200 > > My problem is that I have some string, _which is not displayed anywhere_ > yet. I need to obtain its real width along with the width of a single > character in order to compute the length argument in `make-string'. The width of any text on display is meaningless unless you also tell in what window will it be displayed. That's because some of the factors that affect the display width depend on the window and the buffer shown by that window. So assuming the string you have will eventually be displayed in some window -- and most strings in Emacs are of that kind -- you should use that window up front. Otherwise, the value you get from other methods can only be an approximation, which will sometimes be close, and sometimes quite far from the truth.