[whatwg] [html5] onbeforeprint/onafterprint (was window.print() undefined)
Matthew Raymond
mattraymond at earthlink.net
Wed Jul 20 09:30:10 PDT 2005
Dean Edwards wrote:
> Matthew Raymond wrote:
>>1) The feature can be abused.
>
> All features can be abused.
Yes, but some more than others.
>>2) It alters the standard behavior of the browser.
>
> No it doesn't.
Uh, yes it does. Perhaps the problem is that CSS clouds the issue.
Since CSS is not required for HTML compliance, let's look at how a
non-CSS browser would be effected by onbeforeprint/onafterprint. Without
these events, the printout of the page would always match what you have
on screen (barring the user agent deliberately making it look
different). Therefore, while using this browser, if I see something that
says the following...
| Matthew is a great guy.
...and I print it, I would expect the printer to print out this:
| Matthew is a great guy.
By contrast, I would not expect the printer to give me the following:
| Matthew is a complete luzor!!!
That's what these events enable, and that's a fundamental alteration
of the expected behavior of a user agent's printing function.
>>3) It can be easily disabled with a modified open source browser or
>>browser extension.
>
> So?
So it's useless for keeping people from printing stuff without paying
if the people in question really want to print something. Also, you
could probably also use copying and pasting to a word processor to do a
complete end run around these events.
>>4) It's use cases are partially covered by CSS.
>
> ditto.
>
>>5) There are existing workarounds.
>
> ditto.
So we should ignore both cost and benefit when implementing new markup???
>>6) An alternative has been proposed that has less potential for abuse,
>>is more powerful, and doesn't change basic browser functionality.
>
> What alternative?
I'm covering that in a separate email to Anne right now, but I've
mentioned it several times before.
More information about the whatwg
mailing list