From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pierre Neidhardt Subject: Re: 01/03: ui: Only display link in capable terminals. Date: Mon, 24 Feb 2020 17:15:24 +0100 Message-ID: <878sksc677.fsf@ambrevar.xyz> References: <20200224101817.20439.52918@vcs0.savannah.gnu.org> <20200224101818.9A1FC206ED@vcs0.savannah.gnu.org> <8736b0m21m.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:38860) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j6GOI-0001u1-6V for guix-devel@gnu.org; Mon, 24 Feb 2020 11:15:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j6GOG-0008LP-N6 for guix-devel@gnu.org; Mon, 24 Feb 2020 11:15:29 -0500 In-Reply-To: <8736b0m21m.fsf@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane-mx.org@gnu.org Sender: "Guix-devel" To: Ludovic =?utf-8?Q?Court=C3=A8s?= , guix-devel@gnu.org, zimoun --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Ludovic Court=C3=A8s writes: > So people see less information on terminals that support hyperlinks, > right? > > I think there should be as much information displayed whether or not the > terminal supports hyperlinks. Otherwise it can be confusing. > (Especially since we can=E2=80=99t tell whether the terminal really suppo= rts > hyperlinks: we don=E2=80=99t know whether it displays clickable links.) > > Thoughts? The file/URL was not displayed in terminals that support hyperlinks. This was also true before this commit. The user has to guess that they are clickable. I agree that displaying the file / URL in all cases and making the clickable if possible would be an improvement. >> --- a/guix/ui.scm >> +++ b/guix/ui.scm >> @@ -1637,7 +1637,7 @@ DURATION-RELATION with the current time." >> (let* ((file (generation-file-name profile number)) >> (link (if (supports-hyperlinks?) >> (cut file-hyperlink file <>) >> - identity)) >> + (cut format #f (G_ "~a~%file: ~a") <> file))) >> (header (format #f (link (highlight (G_ "Generation ~a\t~a")= )) > > I understand it=E2=80=99s a matter of taste, but I=E2=80=99m not a fan of= the extra > line here. You mean the "~%" in "~a~%file: ~a"? How would you like to display it? =2D-=20 Pierre Neidhardt https://ambrevar.xyz/ --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAl5T9pwACgkQm9z0l6S7 zH81JAf+N2dKpWSk8sUEDlcQnDweQc2ZfTafaxwBO1wPOzAXzTVRgnPZi3v27vDD 2e82NKi/CyaoztuEE8yKo9BWNrYBRBXwftAGAW4tv7B0Wl7slKBCfoPbsDgnRavr IY84KmeJS1PTGmrrqzKnNo7kVzhOa09rlpCCaFohW6DkSMxMbQIqCZLa1fFCGZnY +OQxAmemxeVKa3gUCBQC/M/kwATfNy/Vwxxeu4QTeVoUmC/6L8q0RePLeamx33YY FsxfE9Bf8mC5jQNY0RCXECJIvUwlTpaqlv3KlQF4WMpcyLJz33+C0iG9cNoH1KVU vedvqoNIDAvZ81RKAQh1J2Lu6IXCDw== =RCn+ -----END PGP SIGNATURE----- --=-=-=--