From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bastien Newsgroups: gmane.emacs.bugs Subject: bug#16497: 24.3.50; `move-to-column' ignores invisible text at the beginning of the line, which create problems when using string-rectangle Date: Mon, 20 Jan 2014 17:25:20 +0100 Message-ID: <87k3dulixb.fsf@bzg.ath.cx> References: <87ob38gcp1.fsf@bzg.ath.cx> <83vbxfj3qo.fsf@gnu.org> <87sisj2ekl.fsf@bzg.ath.cx> <83eh42iry6.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1390235173 26296 80.91.229.3 (20 Jan 2014 16:26:13 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 20 Jan 2014 16:26:13 +0000 (UTC) Cc: 16497@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Jan 20 17:26:19 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1W5Hg2-0007pn-QC for geb-bug-gnu-emacs@m.gmane.org; Mon, 20 Jan 2014 17:26:19 +0100 Original-Received: from localhost ([::1]:53304 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W5Hg2-0003kx-Bg for geb-bug-gnu-emacs@m.gmane.org; Mon, 20 Jan 2014 11:26:18 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56584) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W5Hft-0003kZ-Qc for bug-gnu-emacs@gnu.org; Mon, 20 Jan 2014 11:26:15 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W5Hfn-0005I7-JG for bug-gnu-emacs@gnu.org; Mon, 20 Jan 2014 11:26:09 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:44505) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W5Hfn-0005Hz-FB for bug-gnu-emacs@gnu.org; Mon, 20 Jan 2014 11:26:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1W5Hfl-0006Kr-K2 for bug-gnu-emacs@gnu.org; Mon, 20 Jan 2014 11:26:03 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Bastien Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 20 Jan 2014 16:26:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 16497 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 16497-submit@debbugs.gnu.org id=B16497.139023512724295 (code B ref 16497); Mon, 20 Jan 2014 16:26:01 +0000 Original-Received: (at 16497) by debbugs.gnu.org; 20 Jan 2014 16:25:27 +0000 Original-Received: from localhost ([127.0.0.1]:58524 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1W5HfC-0006Jm-1b for submit@debbugs.gnu.org; Mon, 20 Jan 2014 11:25:26 -0500 Original-Received: from mail-we0-f175.google.com ([74.125.82.175]:63034) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1W5Hf9-0006JZ-Ai for 16497@debbugs.gnu.org; Mon, 20 Jan 2014 11:25:23 -0500 Original-Received: by mail-we0-f175.google.com with SMTP id p61so7180133wes.34 for <16497@debbugs.gnu.org>; Mon, 20 Jan 2014 08:25:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:in-reply-to:references:user-agent:date :message-id:mime-version:content-type; bh=BWSNGLAYNkv2SoEETdmBWYK4IukCQqX9yI8pc5JLLPU=; b=EJKCYyvcY/godyQJy+s4M/7yYLs1HyvcQVV4aMgNeh2x4nJm1AUT+w+r48WKSlzR4C adUSrNPGD+tUI9U8sBs9Xtuk3T2WniK0uSWrZPm5iCWwqr2/w4VC8H6N8ik2UUE+X+p4 5hsYjHUkocgNALCVmyr9gwywSOy6Y90Q9AtEp+RzaS4P8R4R+uCsTSUoP1xtvCE/3Sx0 fCTXClFFKRMxnQw/8RPppy0TtrNYpbrw9KZ5h01GQELExnpHWsNilDSqaG97S+el5iY9 9CJZ8CZTJChVPxJnrimmWO5yrhkyjQTfGkfwYKSNMHkxDXL6PWBtruEH6cUUzA5g4Pkk tHPw== X-Received: by 10.180.149.175 with SMTP id ub15mr10713264wib.44.1390235122123; Mon, 20 Jan 2014 08:25:22 -0800 (PST) Original-Received: from bzg.localdomain (AMontsouris-651-1-1-52.w90-46.abo.wanadoo.fr. [90.46.36.52]) by mx.google.com with ESMTPSA id po3sm2221953wjc.3.2014.01.20.08.25.20 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 20 Jan 2014 08:25:21 -0800 (PST) Original-Received: by bzg.localdomain (Postfix, from userid 1000) id 5242A1C2074C; Mon, 20 Jan 2014 17:25:20 +0100 (CET) In-Reply-To: <83eh42iry6.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 20 Jan 2014 17:38:41 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:83784 Archived-At: Eli Zaretskii writes: > move-to-column is a screen-moving command, and it has been skipping > invisible text for the past 18 years. It also accounts for various > other display-only features and artifacts. (It is a pity that this is > not documented; I think it's a documentation bug.) > > So now I'm wondering why you thought you should be using this > function, if what you need is (AFAIU) to get to the Nth character > starting from the beginning of a line. I don't think I should be using this command: I just used `string-rectangle' which uses it (see my original report.) > E.g., move-to-column also > accounts for double-width characters (it counts them as 2 columns), > and also for how composed characters are displayed (it could count N > composed characters as M ~= N columns). It also accounts for > characters displayed via display tables. Are you sure you want all > this in the job you need to do with the rectangle? > > Or maybe you just want line-move-to-column. Interestingly, the docstring of `line-move-to-column' is this: Try to find column COL, considering invisibility. This function works only in certain cases, because what we really need is for `move-to-column' and `current-column' to be able to ignore invisible text. suggesting to improve `move-to-column' and `current-column' by allowing them to handle invisible text. -- Bastien