From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Hong Xu Newsgroups: gmane.emacs.help Subject: How to make c-indent-line-region respect indent-tabs-mode when it's already aligned? Date: Sat, 30 May 2015 01:28:13 -0700 Message-ID: <87k2vqii5e.fsf@home.hong.me> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: ger.gmane.org 1432995186 15999 80.91.229.3 (30 May 2015 14:13:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 30 May 2015 14:13:06 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat May 30 16:12:58 2015 Return-path: Envelope-to: geh-help-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 1YyhVQ-0007Gr-FL for geh-help-gnu-emacs@m.gmane.org; Sat, 30 May 2015 16:12:56 +0200 Original-Received: from localhost ([::1]:39572 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YyhVP-0005jW-Ie for geh-help-gnu-emacs@m.gmane.org; Sat, 30 May 2015 10:12:55 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58913) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yyc80-0000fI-TY for help-gnu-emacs@gnu.org; Sat, 30 May 2015 04:28:25 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yyc7w-0002yI-NL for help-gnu-emacs@gnu.org; Sat, 30 May 2015 04:28:24 -0400 Original-Received: from sender163-mail.zoho.com ([74.201.84.163]:24420) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yyc7w-0002xw-Fb for help-gnu-emacs@gnu.org; Sat, 30 May 2015 04:28:20 -0400 Original-Received: from localhost (cpe-104-32-170-214.socal.res.rr.com [104.32.170.214]) by mx.zohomail.com with SMTPS id 1432974497754165.21486697388275; Sat, 30 May 2015 01:28:17 -0700 (PDT) X-Zoho-Virus-Status: 1 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x X-Received-From: 74.201.84.163 X-Mailman-Approved-At: Sat, 30 May 2015 10:12:44 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:104683 Archived-At: --=-=-= Content-Type: text/plain Hi, Currently it seems that c-indent-line-region ignores the value of indent-tabs-mode. For example, I have the following in a buffer int main() { int x; } and my indent-tabs-mode is nil. If 8 spaces is what expected, calling c-indent-line-or-region would do nothing. However, if it's not aligned int main() { int x; } calling c-indent-line-or-region would correct the tab with appropriate number of spaces. Is there a different line indentation function which respects indent-tabs-mode even the line is already aligned? Thanks, Hong --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJVaXSdAAoJECZsfTOCL4R4z5YQAJ09lY/1jWvIl8GXYKIKRhcS huZ76oi1FLFRNZ2Sa9FtVtI5hzV4WA94qDdWsld8kCEzpMZ/Z9yKrUsqSC+jDtoT hWaB1X2wC4nwtjxa7ki5vX+VnY5VMMpmhiXS3BUqGZJfjCzdca2kMyxQAkCMifGH MD0kyZ+AqMr3N1/kNnt8YIwPQy0IOKqeh8HqfqnlCzPaqGSadcmMLHZtryw/6K6B NWQKkxKiLYTrcDZlhgEbYwwe0PLqzKknsZiVJ/tgvFCX3oEy9GmKZuS21kv6643+ XA9zHgz/LAvSCGtgdWYm4fAoPqgzOfoRoa33ksj6eUf8EyopRQTsCe8D7+SxbGX2 lY95EzyenxfdG3ewe1CX+rMX3Yd6RBqRTeJypD005xtawIbQoxZW1KV6GCSavk81 9c4d5P2RYZurKex0UME3Hidgn4MIZgSSVHPPReJYDN+rgr2uHrwd3wAH7fzj7bRo /qJzBerzYlXA8shNPoZs1d25VvAQpO0p/9gFHDMFzqU+FinD7VO2y146FaAY7CmK OcpuH21EYc/5QPfFdM99bDhGRTuyAxK5+opyNyy0K8VMtoAnjAuSFQ4zqEDHmxNo ts9TKY11JyKqHAgTIhGbJBEJw7xNyGBz0bkcp/YxcaAx7MuiePHiJT4RIY1zQZMG boHAB6aoyNeVF991ven3 =78Qt -----END PGP SIGNATURE----- --=-=-=--