Closed Bug 321433 Opened 20 years ago Closed 20 years ago

Don't enable selection for printing

Categories

(Core :: DOM: Selection, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: sharparrow1, Assigned: sharparrow1)

References

Details

Attachments

(1 file, 2 obsolete files)

Attached patch Patch (obsolete) — Splinter Review
Comment on attachment 206771 [details] [diff] [review] Patch Any thoughts on this?
Attachment #206771 - Flags: review?(roc)
Does printing only the selection still work?
Printing selection seems to work fine; I'm pretty sure selection controllers are per-presshell is per-PresShell. Some thoughts that might help: This acts as kind of an alternate, more comprehensive fix to bug 312415, I guess; it stops the selection painting/event code from being used in the first place. Text selection never displayed anyway when printing because of the weirdness of nsTextFrame::GetTextInfoForPainting, but I don't think that's really the right way to stop image selection from showing.
sorry, forgot to CC myself before. With this, can we remove the special-case selection disabling from nsTextFrame?
I suppose, but is it worth bothering? Isn't there some plan in the works to rewrite nsTextFrame, or at least the painting? That would make deleting the extra code moot, wouldn't it? Text painting is a serious mess at the moment, and it really needs a rewrite; very similar code doesn't really need to be repeated three times. Actually, the removal would need to touch all three versions. So, I'll do it if you like. The fix to bug 312415 could also be removed.
Comment on attachment 206771 [details] [diff] [review] Patch alright, let's go with this
Attachment #206771 - Flags: review?(roc) → review+
Attached patch Patch with some cleanup (obsolete) — Splinter Review
I think this is the version I'd like to check in; this includes a couple simple cleanups without any messy changes. If this patch is OK with you, do I need someone else to superreview?
Attachment #206771 - Attachment is obsolete: true
Attachment #209992 - Flags: review?(roc)
Comment on attachment 209992 [details] [diff] [review] Patch with some cleanup this is fine.
Attachment #209992 - Flags: superreview+
Attachment #209992 - Flags: review?(roc)
Attachment #209992 - Flags: review+
Don't check in the last patch; I just realized how the text painting logic works. I really hate badly labeled stuff. I couldn't test the last version properly because print clipping is broken, but the nsTextFrame changes are wrong.
Attached patch Final versionSplinter Review
Correct nsTextFrame.cpp changes. No other differences.
Attachment #209992 - Attachment is obsolete: true
Attachment #210939 - Flags: review?(roc)
Checked in.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: