Page MenuHomePhabricator

download as pdf does not take the tag <code> into account
Closed, ResolvedPublic


Author: bobby.prani

downloaded pdf from wikipedia

when you download an article on wikipedia as a pdf, it does not take the tag <code> into account. Because of this, the formatting in the pdf is changed compared to the formatting in HTML.


The worked examples in the algorithm are all as plain text when viewed in the pdf.

Compare with Print-to-pdf in Firefox which gives similar formatting.

Version: unspecified
Severity: normal




Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 21 2014, 11:31 PM
bzimport added a project: Collection.
bzimport set Reference to bz29354.

bobby.prani wrote:

print-to-pdf from firefox


<source></source> works fine though

I'm not sure if this is a dupe, as I remember discussing with someone about this recently.

But that might've been on IRC

There's a couple of very similar related bugs about too

I don't know anything about the mwlib software, but just from the context in the diff [0] it looks like you have it backwards. Shouldn't it be "Code: [PreFormatted]" not the other way around?


volker.haas wrote:

I tested the change and it works. But I agree, the diff (and the "configuration" of "forbidden_parents") looks wrong. When I came up with that type of mapping it probably made sense. But from todays perspective the configuration looks pretty stupid. Maybe I'll change it some day...

Fair enough, thanks for clarifying :)