From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: dalanicolai Newsgroups: gmane.emacs.bugs Subject: bug#54688: 29.0.50; Sliced image in margin looks bad Date: Sun, 3 Apr 2022 08:50:20 +0200 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000085f70e05dbba6d93" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32347"; mail-complaints-to="usenet@ciao.gmane.io" To: 54688@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Apr 03 08:57:14 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1nauAj-00089W-Mf for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 03 Apr 2022 08:57:13 +0200 Original-Received: from localhost ([::1]:51032 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nauAi-0003QU-Cc for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 03 Apr 2022 02:57:12 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:49062) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nauAZ-0003QK-16 for bug-gnu-emacs@gnu.org; Sun, 03 Apr 2022 02:57:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:53538) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nauAY-0003hj-Nc for bug-gnu-emacs@gnu.org; Sun, 03 Apr 2022 02:57:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nauAY-0007G8-LH for bug-gnu-emacs@gnu.org; Sun, 03 Apr 2022 02:57:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: dalanicolai Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 03 Apr 2022 06:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 54688 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.164896897827834 (code B ref -1); Sun, 03 Apr 2022 06:57:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 3 Apr 2022 06:56:18 +0000 Original-Received: from localhost ([127.0.0.1]:47429 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nau9p-0007Er-AK for submit@debbugs.gnu.org; Sun, 03 Apr 2022 02:56:17 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:38536) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nau9n-0007Ej-1c for submit@debbugs.gnu.org; Sun, 03 Apr 2022 02:56:15 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:48966) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nau9m-0003N7-Q3 for bug-gnu-emacs@gnu.org; Sun, 03 Apr 2022 02:56:14 -0400 Original-Received: from [2607:f8b0:4864:20::92a] (port=36551 helo=mail-ua1-x92a.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nau9k-0003eT-Mx for bug-gnu-emacs@gnu.org; Sun, 03 Apr 2022 02:56:14 -0400 Original-Received: by mail-ua1-x92a.google.com with SMTP id w21so2601522uan.3 for ; Sat, 02 Apr 2022 23:56:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:from:date:message-id:subject:to; bh=PxoDK7lFPSQ/9nwoeBcZRMrs7s0fcgZO3BTzTcJnoW4=; b=kBY3tKQGs+ScPSKuiEbSFzQ6z+ZJ8l41EWMv0AVkQb58dBiSpnGdiO3CLE24sX+WyD 5WBLlHeA4tqulvyik9Fs72S45HqT3DSeERuTADpiinz8JluewKAqPjE1+QMqEKY4Z3wF o3M4516eHsQWDxs94wg5vtBMDPLoJD8LN1x7ujlp42Vn9eFXIC0xVvvxmLkIbgck5mLZ 9NU0jLsG01HgMdPlUsBcMSOE9ObCB41ypHyoXz406SjA3FNoVf6Bcl8xSTYgrI/l7qL6 UNFubmnNfdzT1N+8vkCEKnsEeR+x9NRQI1DvMiOIZ+iaw1i5og0xUzavq8OLEUWMFnNX YHaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=PxoDK7lFPSQ/9nwoeBcZRMrs7s0fcgZO3BTzTcJnoW4=; b=i4M70CH2PD1U3rEcbT7EGHJuyKYj3I/ss62Od3Pq26AQJcbb9F/xN36ixtWldq1ooE zHfBMFho73wwtJAaQ8iNeq9aL2Mh2V47RfZTarurUdzly1Jst1DY9V5YK8cG/UjD/Kmq xVEenznRKziqgFT6lA3+Hk7A1IFnVsNjPC4kd6uU7LQgVw+eJNuAbPvS0e7O6IK6Ti33 SZ8th82/EZiHdDhHxsVWIlf9fK0q/oyH6es7m17cgsBpHO2nwGtPLQJLtMEnpwm4tApz tmDlV3dNVijcnkgGBq0BiKzU0H1Um/QtZr4cVKP5iejasNH+n4u99SI44lF7kVuItMkF ULhw== X-Gm-Message-State: AOAM530/s92slTD6ZuAjlkJ0l5MhKkSAcrt+qwQ8JTDTRwyFmiTIOeIf tqPBX80il2ct+b65YLqbJfrkuV/qOeUZwfRqkia8cvvnQYB8IQ== X-Google-Smtp-Source: ABdhPJyHHivpot/lOvxQkl09k7qn1LVxA7X0Q/oJfFg+yiN4RLEgUupfvdPzI20cZ/8WJASoQOSVTiRwwrBTjTxsGqM= X-Received: by 2002:a81:1697:0:b0:2e9:d8ed:278 with SMTP id 145-20020a811697000000b002e9d8ed0278mr17409445yww.452.1648968631447; Sat, 02 Apr 2022 23:50:31 -0700 (PDT) X-Host-Lookup-Failed: Reverse DNS lookup failed for 2607:f8b0:4864:20::92a (failed) Received-SPF: pass client-ip=2607:f8b0:4864:20::92a; envelope-from=dalanicolai@gmail.com; helo=mail-ua1-x92a.google.com X-Spam_score_int: -6 X-Spam_score: -0.7 X-Spam_bar: / X-Spam_report: (-0.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, PDS_HP_HELO_NORDNS=0.659, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:229316 Archived-At: --00000000000085f70e05dbba6d93 Content-Type: text/plain; charset="UTF-8" Passing 'left-margin' for the AREA parameter in `insert-sliced-image` results in bad looking image. To reproduce from `emacs -q` evaluate the following code example: (with-current-buffer (get-buffer-create "test") (setq left-margin-width 5) (insert-sliced-image (svg-image (let* ((ph (line-pixel-height)) (size (* 2 ph)) (svg (svg-create size size))) (svg-circle svg ph ph ph :fill "red") svg)) nil 'left-margin 2) (switch-to-buffer (current-buffer))) when instead of 'left-margin', nil is passed as value (i.e. the text is inserted in the text area), then everything looks fine. In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.31, cairo version 1.17.4) of 2022-01-29 built on fedora Repository revision: 96533c18b7f9d75dce9e6bb534a16ed4ccf44ad1 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12014000 System Description: Fedora Linux 35 (Workstation Edition) Configured using: 'configure --with-modules --with-cairo --with-native-compilation --with-json' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON LIBSELINUX LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE XIM XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: marginalia-mode: t savehist-mode: t vertico-mode: t global-evil-surround-mode: t evil-surround-mode: t recentf-mode: t shell-dirtrack-mode: t evil-mode: t evil-local-mode: t windmove-mode: t global-undo-tree-mode: t undo-tree-mode: t override-global-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t indent-tabs-mode: t transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message yank-media rmc dired dired-loaddefs rfc822 mml mml-sec epa epg rfc6068 epg-config gnus-util time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mule-util cursor-sensor format-all language-id inheritenv gitter derived pcase let-alist posframe transient format-spec request autorevert filenotify mail-utils notifications dbus avy shr-tag-pre-highlight language-detection shr text-property-search pixel-fill kinsoku puny svg xml ewoc marginalia savehist orderless vertico evil-surround evil-nerd-commenter evil-nerd-commenter-operator evil-nerd-commenter-sdk sgml-mode facemenu dom which-key bind-map recentf tree-widget wid-edit evil evil-keybindings evil-integration evil-maps evil-commands reveal flyspell ispell evil-jumps evil-command-window evil-types evil-search evil-ex shell pcomplete comint ansi-color evil-macros evil-repeat evil-states evil-core comp comp-cstr warnings rx advice evil-common windmove thingatpt rect evil-digraphs evil-vars ring edmacro kmacro undo-tree diff cl-extra help-mode use-package use-package-ensure use-package-delight use-package-diminish use-package-bind-key bind-key easy-mmode use-package-core finder-inf info package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs password-cache json map url-vars seq gv subr-x byte-opt bytecomp byte-compile cconv cl-loaddefs cl-lib chemacs iso-transl tooltip eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit x multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 350688 17872) (symbols 48 22237 1) (strings 32 115274 5006) (string-bytes 1 3507701) (vectors 16 225348) (vector-slots 8 1419197 79043) (floats 8 90951 50) (intervals 56 651 0) (buffers 992 13)) --00000000000085f70e05dbba6d93 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Passing 'left-margin' for the AREA parameter in `i= nsert-sliced-image`
results in bad looking image. To reproduce from `ema= cs -q` evaluate the
following code example:

(with-current-buffer = (get-buffer-create "test")
=C2=A0 (setq left-margin-width 5)=C2=A0 (insert-sliced-image (svg-image (let* ((ph (line-pixel-height))=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(s= ize (* 2 ph))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0(svg (svg-create size size)))
=C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 (svg-circle svg ph ph ph :fill "red")=
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 svg))
=C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0ni= l
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0'left-margin
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A02)
=C2=A0 (switch-to-buffer (cu= rrent-buffer)))

when instead of 'left-margin', nil is passed= as value (i.e. the text is
inserted in the text area), then everything = looks fine.

In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+= Version 3.24.31, cairo version 1.17.4)
=C2=A0of 2022-01-29 built on fed= ora
Repository revision: 96533c18b7f9d75dce9e6bb534a16ed4ccf44ad1
Rep= ository branch: master
Windowing system distributor 'The X.Org Found= ation', version 11.0.12014000
System Description: Fedora Linux 35 (W= orkstation Edition)

Configured using:
=C2=A0'configure --with= -modules --with-cairo --with-native-compilation
=C2=A0--with-json'
Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS G= SETTINGS HARFBUZZ JPEG JSON
LIBSELINUX LIBXML2 MODULES NATIVE_COMP NOTIF= Y INOTIFY PDUMPER PNG RSVG
SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SC= ROLL_BARS X11 XDBE XIM XPM
GTK3 ZLIB

Important settings:
=C2= =A0 value of $LANG: en_US.UTF-8
=C2=A0 value of $XMODIFIERS: @im=3Dibus<= br>=C2=A0 locale-coding-system: utf-8-unix

Major mode: Lisp Interact= ion

Minor modes in effect:
=C2=A0 marginalia-mode: t
=C2=A0 sa= vehist-mode: t
=C2=A0 vertico-mode: t
=C2=A0 global-evil-surround-mod= e: t
=C2=A0 evil-surround-mode: t
=C2=A0 recentf-mode: t
=C2=A0 sh= ell-dirtrack-mode: t
=C2=A0 evil-mode: t
=C2=A0 evil-local-mode: t=C2=A0 windmove-mode: t
=C2=A0 global-undo-tree-mode: t
=C2=A0 undo-= tree-mode: t
=C2=A0 override-global-mode: t
=C2=A0 tooltip-mode: t=C2=A0 global-eldoc-mode: t
=C2=A0 eldoc-mode: t
=C2=A0 show-paren-m= ode: t
=C2=A0 electric-indent-mode: t
=C2=A0 mouse-wheel-mode: t
= =C2=A0 tool-bar-mode: t
=C2=A0 menu-bar-mode: t
=C2=A0 file-name-shad= ow-mode: t
=C2=A0 global-font-lock-mode: t
=C2=A0 font-lock-mode: t=C2=A0 blink-cursor-mode: t
=C2=A0 auto-composition-mode: t
=C2=A0 = auto-encryption-mode: t
=C2=A0 auto-compression-mode: t
=C2=A0 line-n= umber-mode: t
=C2=A0 indent-tabs-mode: t
=C2=A0 transient-mark-mode: = t

Load-path shadows:
None found.

Features:
(shadow sort= mail-extr emacsbug message yank-media rmc dired
dired-loaddefs rfc822 m= ml mml-sec epa epg rfc6068 epg-config gnus-util
time-date mm-decode mm-b= odies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader sendm= ail rfc2047 rfc2045 ietf-drums mm-util
mail-prsvr mule-util cursor-senso= r format-all language-id inheritenv
gitter derived pcase let-alist posfr= ame transient format-spec request
autorevert filenotify mail-utils notif= ications dbus avy
shr-tag-pre-highlight language-detection shr text-prop= erty-search
pixel-fill kinsoku puny svg xml ewoc marginalia savehist ord= erless
vertico evil-surround evil-nerd-commenter evil-nerd-commenter-ope= rator
evil-nerd-commenter-sdk sgml-mode facemenu dom which-key bind-map<= br>recentf tree-widget wid-edit evil evil-keybindings evil-integration
e= vil-maps evil-commands reveal flyspell ispell evil-jumps
evil-command-wi= ndow evil-types evil-search evil-ex shell pcomplete
comint ansi-color ev= il-macros evil-repeat evil-states evil-core comp
comp-cstr warnings rx a= dvice evil-common windmove thingatpt rect
evil-digraphs evil-vars ring e= dmacro kmacro undo-tree diff cl-extra
help-mode use-package use-package-= ensure use-package-delight
use-package-diminish use-package-bind-key bin= d-key easy-mmode
use-package-core finder-inf info package browse-url url= url-proxy
url-privacy url-expand url-methods url-history url-cookie url= -domsuf
url-util mailcap url-handlers url-parse auth-source cl-seq eieio=
eieio-core cl-macs eieio-loaddefs password-cache json map url-vars seq<= br>gv subr-x byte-opt bytecomp byte-compile cconv cl-loaddefs cl-lib
che= macs iso-transl tooltip eldoc paren electric uniquify ediff-hook
vc-hook= s lisp-float-type elisp-mode mwheel term/x-win x-win
term/common-win x-d= nd tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace n= ewcomment text-mode lisp-mode prog-mode register
page tab-bar menu-bar r= fn-eshadow isearch easymenu timer select
scroll-bar mouse jit-lock font-= lock syntax font-core term/tty-colors
frame minibuffer cl-generic cham g= eorgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean= japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european e= thiopic indian cyrillic
chinese composite emoji-zwj charscript charprop = case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloade= d nadvice button
loaddefs faces cus-face macroexp files window text-prop= erties overlay
sha1 md5 base64 format env code-pages mule custom widget = keymap
hashtable-print-readable backquote threads dbusbind inotify
dy= namic-setting system-font-setting font-render-setting cairo
move-toolbar= gtk x-toolkit x multi-tty make-network-process
native-compile emacs)
Memory information:
((conses 16 350688 17872)
=C2=A0(symbols 48 = 22237 1)
=C2=A0(strings 32 115274 5006)
=C2=A0(string-bytes 1 3507701= )
=C2=A0(vectors 16 225348)
=C2=A0(vector-slots 8 1419197 79043)
= =C2=A0(floats 8 90951 50)
=C2=A0(intervals 56 651 0)
=C2=A0(buffers 9= 92 13))
--00000000000085f70e05dbba6d93--