From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Kangas Newsgroups: gmane.emacs.devel Subject: Re: Using more and/or better icons in Emacs Date: Fri, 9 Apr 2021 12:46:57 -0500 Message-ID: References: <0342c2d5-02dd-ad9e-5b8e-dfe52f6469c6@daniel-mendler.de> <264397e8-5a03-9eff-436c-639d76514775@daniel-mendler.de> <82c86e8f-06e7-a7ed-56c5-5f6766df591b@daniel-mendler.de> <597310b6-892c-a7d9-a663-f270ed3b0f0e@yandex.ru> <2f0b4786-d569-27e6-fa8a-fb47bf08b166@yandex.ru> <0279fbc8-74c3-3766-2b26-b3eb933a501e@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9796"; mail-complaints-to="usenet@ciao.gmane.io" To: Dmitry Gutov , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Apr 09 19:47:48 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lUvER-0002Sb-VO for ged-emacs-devel@m.gmane-mx.org; Fri, 09 Apr 2021 19:47:47 +0200 Original-Received: from localhost ([::1]:51844 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lUvEQ-0003tw-QG for ged-emacs-devel@m.gmane-mx.org; Fri, 09 Apr 2021 13:47:46 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:42208) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lUvDg-0003V9-UC for emacs-devel@gnu.org; Fri, 09 Apr 2021 13:47:01 -0400 Original-Received: from mail-pj1-f43.google.com ([209.85.216.43]:46809) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lUvDf-0004kc-AX for emacs-devel@gnu.org; Fri, 09 Apr 2021 13:47:00 -0400 Original-Received: by mail-pj1-f43.google.com with SMTP id q6-20020a17090a4306b02900c42a012202so3549904pjg.5 for ; Fri, 09 Apr 2021 10:46:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to; bh=1Wg41RcU619/E15PAaH+2bj5kKR+RGmF1PTSKpTL02I=; b=Sdyy1iLhupSwyHlICLcLXksJwZHerQw5WD5I1iyKYThp25xjbTXa0fSRNUvjogkvFE nf6KJIPaFgT7kREQLRzDcTsBBifu+p7hwtEQNCXjCNa/fox3fgWU8O2oDo/r5e8bq9Dq LMj7cz/XhAIafFaBC01gTrcM2I9VIdQ+E9zbApkEgnJ++X1PcDNa8tB/vR7N+qJnt0Tk aq7GsixV7MEBMnAQBaGZqtxfjBUmhFQf7IyZbK6C4SBzpwjY4W2RNxEODJw6e5o6lamN XqNNRPUopJbJzuXzImtIAAuUDcRE30kqQjpwvMB+/UoW4ULNaAaAmOh/UG7rzucDFSPz 7D/A== X-Gm-Message-State: AOAM530ebf284c+md3QOmOATs6wM0vvRu7z+xo5v6FqU3IT/qtxt1Vlp VyTayLsNVbAKNChMZtxzRWF6rXc+whJO9cq8TsQ= X-Google-Smtp-Source: ABdhPJw/u1zQZVPx9B5nrFPqOM23VjVQx2QbavNd3CoFnTKI2JP3aPXKPZQ8yVHZgKuGJQwqa5cRCHTJzxGNjHn2e/g= X-Received: by 2002:a17:90a:c249:: with SMTP id d9mr15185837pjx.104.1617990417889; Fri, 09 Apr 2021 10:46:57 -0700 (PDT) Original-Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Fri, 9 Apr 2021 12:46:57 -0500 In-Reply-To: Received-SPF: pass client-ip=209.85.216.43; envelope-from=stefankangas@gmail.com; helo=mail-pj1-f43.google.com X-Spam_score_int: -13 X-Spam_score: -1.4 X-Spam_bar: - X-Spam_report: (-1.4 / 5.0 requ) BAYES_00=-1.9, FREEMAIL_FORGED_FROMDOMAIN=0.25, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:267733 Archived-At: Dmitry Gutov writes: > On 09.04.2021 15:22, Stefan Kangas wrote: >> all-the-icons.el does distribute TTF fonts, but IIUC that's simply >> packaged up versions of free sets that were originally distributed in >> SVG. >> >> So what I meant was that we could look at what sets they are linking to, >> get the original SVG files and then use those. That's what I did for >> the Material icon toolbar mock-up. > > Ah, that's a very good idea. For this to work, we obviously need to insert SVG files that are the same height as the current face. Experimenting with this now, using my patch, (insert-image (find-image '((:type svg :file "material/file/ic_folder_24px.svg")))) I'm getting an SVG in the buffer that is actually taller than the line. When we added new SVG icons to customize recently, Alan Third fiddled with the height and viewport in the SVG file to force it to be the same height as the line. But is there any way to do this directly from Emacs? It seems like a pain to have to edit the SVG file for every icon (and my attempts at doing so has failed so far...). In a web browser, I think you would just set the CSS width and height to whatever you want and the browser would resize the image to fit.