all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Tino Calancha <tino.calancha@gmail.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Emacs developers <emacs-devel@gnu.org>,
	Tino Calancha <tino.calancha@gmail.com>
Subject: Re: tabulated-list: extend truncation into next align-right col
Date: Tue, 1 Nov 2016 12:31:42 +0900 (JST)	[thread overview]
Message-ID: <alpine.DEB.2.20.1611011229480.6087@calancha-pc> (raw)
In-Reply-To: <jwv1syw4b5x.fsf-monnier+emacs@gnu.org>



On Mon, 31 Oct 2016, Stefan Monnier wrote:

>> +  ;; TODO: don't truncate to `width' if the next column is align-right
>> +  ;; and has some space left.
> [...]
>> +(defvar-local tabulated-list--col-max-widths nil
>
> By "some space left" I meant "in the current line", so there shouldn't be
> any need to compute the maximum width.
Yeah, but we must preserve the legibility of the table.

If we calculate the maximum widths and we restrict the
truncation until one well-defined limit, then the table
looks nicer.

For instance, compare following two tables:

;; Without computing maximum widths:
C1  C2                                       Numbers
abc **************************************... 123456
abc *******************************************... 1
abc ************************************         123

;; With `tabulated-list--col-max-widths':
C1  C2                                       Numbers
abc **************************************... 123456
abc **************************************...      1
abc ************************************         123

With many rows this effect might have an impact on table
readability.



  reply	other threads:[~2016-11-01  3:31 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-31 17:41 tabulated-list: extend truncation into next align-right col Tino Calancha
2016-10-31 18:40 ` Stefan Monnier
2016-11-01  3:31   ` Tino Calancha [this message]
2016-11-01 12:41     ` Stefan Monnier
2016-11-01 13:25       ` Tino Calancha
2016-11-01 18:25       ` Tino Calancha
2016-11-02  0:38         ` Stefan Monnier
2016-11-02  5:06           ` Tino Calancha
2016-11-02  8:20             ` Tino Calancha
2016-11-02 12:27         ` Stefan Monnier
2016-11-02 15:08           ` Tino Calancha
2016-11-02 15:16             ` Tino Calancha
2016-11-04 14:35           ` Tino Calancha
2016-11-04 16:53             ` Tino Calancha
2016-11-04 17:29             ` Stefan Monnier
2016-11-07  1:59               ` Tino Calancha
2016-11-14  8:43                 ` Tino Calancha
2016-10-31 20:15 ` Drew Adams
2016-10-31 20:47   ` Mark Oteiza

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.20.1611011229480.6087@calancha-pc \
    --to=tino.calancha@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.