all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#42194: 27.0.91; shr and rowspan
@ 2020-07-04 18:55 Mike Kupfer
  2020-07-17  0:18 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 7+ messages in thread
From: Mike Kupfer @ 2020-07-04 18:55 UTC (permalink / raw)
  To: 42194

Reproducer: save this sample HTML to a file and view it with eww:

-----8<-----8<-----
<html>
  <body>
    <table>
      <tr><td rowspan="3">text along left side of table</td></tr>
      <tr><td>row 1</td></tr>
      <tr><td>row 2</td></tr>
    </table>
  </body>
</html>
----->8----->8-----

I'm not terribly concerned about the exact formatting of the table, but
I do expect to see the "row 1" and "row 2" text somewhere.  Instead, all
I see is

-----8<-----8<-----
 text along left side of table  
----->8----->8-----

The test case is abstracted from some HTML-only notification emails that
I have started receiving.  With the "row 1" and "row 2" text missing,
the emails are close to useless.

I can't tell if I should expect shr to handle rowspan correctly.  (Is
there somewhere that documents known restrictions on the HTML that shr
can handle?)  If I shouldn't expect rowspan to be handled correctly (I
can imagine it's hard to get right), please treat this as a wishlist
(feature request) report.

I have verified that the problem also occurs with 26.1 and 26.3, and
I've reproduced it with "emacs -Q".

In GNU Emacs 27.0.91 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars)
 of 2020-06-06 built on alto
Windowing system distributor 'The X.Org Foundation', version 11.0.12004000
System Description: Debian GNU/Linux 10 (buster)

Recent messages:
Mark activated
Mark set [5 times]
Auto-saving...done
Auto-saving...done
Mark set [3 times]
Saving file /home/kupfer/Desktop/sample.html...
Wrote /home/kupfer/Desktop/sample.html
You can run the command ‘eww’ with G
Saving file /home/kupfer/Mail/drafts/1...
Wrote /home/kupfer/Mail/drafts/1

Configured using:
 'configure --prefix=/usr/local'

Configured features:
XPM JPEG TIFF GIF PNG SOUND GSETTINGS GLIB NOTIFY INOTIFY LIBSELINUX
GNUTLS LIBXML2 FREETYPE HARFBUZZ XFT ZLIB TOOLKIT_SCROLL_BARS LUCID X11
XDBE XIM MODULES THREADS PDUMPER GMP

Important settings:
  value of $LC_TIME: C
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  shell-dirtrack-mode: t
  delete-selection-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow emacsbug mh-identity mh-comp tabify man compile jka-compr info
eieio-opt speedbar sb-image ezimage dframe find-func help-fns radix-tree
url-file url-dired skeleton mh-letter mh-mime mh-gnus mh-show goto-addr
pp mule-util sort gnus-cite shr-color mail-extr gnus-async gnus-bcklg
gnus-kill mhtml-mode css-mode smie eww thingatpt url-queue color js
sgml-mode gnus-dup qp cl-extra help-mode gnus-ml disp-table misearch
multi-isearch mm-archive url-http url-gw url-cache url-auth url-handlers
gnutls nnrss mm-url nndoc nndraft nnmh network-stream nsm gnus-agent
gnus-srvr gnus-score score-mode nnvirtual gnus-msg gnus-art mm-uu
mml2015 mm-view mml-smime smime dig nntp gnus-cache gnus-sum url
url-proxy url-privacy url-expand url-methods url-history mailcap shr
url-cookie url-domsuf url-util url-parse url-vars svg xml dom browse-url
gnus-group gnus-undo gnus-start gnus-cloud nnimap nnmail mail-source
utf7 netrc nnoo parse-time iso8601 gnus-spec gnus-int gnus-range
gnus-win gnus nnheader wid-edit mh-thread mh-inc hl-line mh-tool-bar
mh-seq mh-xface mh-utils mh-folder which-func imenu mh-scan mh-e
mh-compat mh-buffers mh-loaddefs mdk-mail smtpmail auth-source cl-seq
eieio eieio-core cl-macs eieio-loaddefs json map sendmail message rmc
puny dired dired-loaddefs format-spec rfc822 mml mml-sec password-cache
epa derived epg epg-config gnus-util rmail rmail-loaddefs
text-property-search time-date subr-x seq gv mm-decode mm-bodies
mm-encode mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums
mail-prsvr mailabbrev mail-utils gmm-utils mailheader server noutline
outline easy-mmode cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles
cc-align cc-engine cc-vars cc-defs byte-opt bytecomp byte-compile cconv
shell pcomplete comint ansi-color ring xcscope easymenu advice delsel vc
vc-dispatcher timeclock cl-loaddefs cl-lib mdk-hacks tooltip eldoc
electric uniquify ediff-hook vc-hooks lisp-float-type 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 elisp-mode lisp-mode
prog-mode register page tab-bar menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu 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 charscript charprop case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote threads inotify dynamic-setting system-font-setting
font-render-setting x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 16 370501 40212)
 (symbols 48 27130 2)
 (strings 32 97049 6801)
 (string-bytes 1 3044610)
 (vectors 16 37863)
 (vector-slots 8 680245 49762)
 (floats 8 452 367)
 (intervals 56 35265 0)
 (buffers 1000 37))





^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#42194: 27.0.91; shr and rowspan
  2020-07-04 18:55 bug#42194: 27.0.91; shr and rowspan Mike Kupfer
@ 2020-07-17  0:18 ` Lars Ingebrigtsen
  2020-07-17  1:14   ` Lars Ingebrigtsen
  0 siblings, 1 reply; 7+ messages in thread
From: Lars Ingebrigtsen @ 2020-07-17  0:18 UTC (permalink / raw)
  To: Mike Kupfer; +Cc: 42194

Mike Kupfer <mkupfer@alum.berkeley.edu> writes:

> I'm not terribly concerned about the exact formatting of the table, but
> I do expect to see the "row 1" and "row 2" text somewhere.  Instead, all
> I see is
>
> -----8<-----8<-----
>  text along left side of table  
> ----->8----->8-----

Yeah, I can reproduce this, and I see what the problem is.  The way shr
computes rowspan layouts is by adding "dummy" TD elements in the rows
that the spanning element should cover, but this messes up the
calculation of how many columns there really are.  So it's basically a
off-by-one error, but I'm not quite sure what the best way to fix this
is...

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#42194: 27.0.91; shr and rowspan
  2020-07-17  0:18 ` Lars Ingebrigtsen
@ 2020-07-17  1:14   ` Lars Ingebrigtsen
  2020-07-17  3:55     ` Eli Zaretskii
  2020-07-19 18:55     ` Mike Kupfer
  0 siblings, 2 replies; 7+ messages in thread
From: Lars Ingebrigtsen @ 2020-07-17  1:14 UTC (permalink / raw)
  To: Mike Kupfer; +Cc: 42194

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Mike Kupfer <mkupfer@alum.berkeley.edu> writes:
>
>> I'm not terribly concerned about the exact formatting of the table, but
>> I do expect to see the "row 1" and "row 2" text somewhere.  Instead, all
>> I see is
>>
>> -----8<-----8<-----
>>  text along left side of table  
>> ----->8----->8-----

This is now fixed in Emacs 28.1.

Eli, I think the fix should be safe for Emacs 27.1, too, but I've been
out of the loop and I'm not sure what the status is at the moment.  This
isn't exactly a critical bug -- rowspan isn't used that much these days,
and it's a very old bug.

On the other hand, I think it's a pretty safe fix to add, so should I
cherry-pick it for Emacs 27.1?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#42194: 27.0.91; shr and rowspan
  2020-07-17  1:14   ` Lars Ingebrigtsen
@ 2020-07-17  3:55     ` Eli Zaretskii
  2020-07-17 13:00       ` Lars Ingebrigtsen
  2020-07-19 18:55     ` Mike Kupfer
  1 sibling, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2020-07-17  3:55 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 42194, mkupfer

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: 42194@debbugs.gnu.org, eli Eli Zaretskii <eliz@gnu.org>
> Date: Fri, 17 Jul 2020 03:14:59 +0200
> 
> Eli, I think the fix should be safe for Emacs 27.1, too, but I've been
> out of the loop and I'm not sure what the status is at the moment.  This
> isn't exactly a critical bug -- rowspan isn't used that much these days,
> and it's a very old bug.
> 
> On the other hand, I think it's a pretty safe fix to add, so should I
> cherry-pick it for Emacs 27.1?

The above generally translates into "don't put this on emacs-27".  But
maybe if you tell more details about how it is safe, I will change my
mind about this.

Thanks.





^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#42194: 27.0.91; shr and rowspan
  2020-07-17  3:55     ` Eli Zaretskii
@ 2020-07-17 13:00       ` Lars Ingebrigtsen
  2020-07-17 13:52         ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Lars Ingebrigtsen @ 2020-07-17 13:00 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 42194, mkupfer

Eli Zaretskii <eliz@gnu.org> writes:

> The above generally translates into "don't put this on emacs-27".  But
> maybe if you tell more details about how it is safe, I will change my
> mind about this.

So does this mean that Emacs 27 is in the "critical bug fixes only"
state?

This is certainly not a critical bug (or a regression), so I'm not
backporting the fix, then.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#42194: 27.0.91; shr and rowspan
  2020-07-17 13:00       ` Lars Ingebrigtsen
@ 2020-07-17 13:52         ` Eli Zaretskii
  0 siblings, 0 replies; 7+ messages in thread
From: Eli Zaretskii @ 2020-07-17 13:52 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 42194, mkupfer

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: mkupfer@alum.berkeley.edu,  42194@debbugs.gnu.org
> Date: Fri, 17 Jul 2020 15:00:32 +0200
> 
> So does this mean that Emacs 27 is in the "critical bug fixes only"
> state?

I hope to have RC1 soon.  So yes.





^ permalink raw reply	[flat|nested] 7+ messages in thread

* bug#42194: 27.0.91; shr and rowspan
  2020-07-17  1:14   ` Lars Ingebrigtsen
  2020-07-17  3:55     ` Eli Zaretskii
@ 2020-07-19 18:55     ` Mike Kupfer
  1 sibling, 0 replies; 7+ messages in thread
From: Mike Kupfer @ 2020-07-19 18:55 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 42194

Lars Ingebrigtsen wrote:

> This is now fixed in Emacs 28.1.

Thanks!

I applied 510da73b4a to my copy of 27.0.91, and it works there, too.  (I
understand about it being too late for 27.1.  I just wanted to note it
in the bug report in case someone else hits this issue and wants to
manually apply the fix.)

cheers,
mike





^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2020-07-19 18:55 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-07-04 18:55 bug#42194: 27.0.91; shr and rowspan Mike Kupfer
2020-07-17  0:18 ` Lars Ingebrigtsen
2020-07-17  1:14   ` Lars Ingebrigtsen
2020-07-17  3:55     ` Eli Zaretskii
2020-07-17 13:00       ` Lars Ingebrigtsen
2020-07-17 13:52         ` Eli Zaretskii
2020-07-19 18:55     ` Mike Kupfer

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.