After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 332884 - [Patch] draw_print signal not emitted correctly for embedded objects
[Patch] draw_print signal not emitted correctly for embedded objects
Status: RESOLVED FIXED
Product: GtkHtml
Classification: Other
Component: Printing
3.10.x
Other Linux
: Normal normal
: ---
Assigned To: gtkhtml-maintainers
Evolution QA team
Depends on:
Blocks: 327625
 
 
Reported: 2006-02-28 19:46 UTC by Andreas Köhler
Modified: 2006-03-25 17:52 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
First try (464 bytes, patch)
2006-02-28 19:46 UTC, Andreas Köhler
committed Details | Review

Description Andreas Köhler 2006-02-28 19:46:27 UTC
HTMLEmbedded declares a "draw_print" signal that will be emitted while printing (at least). But the code sends 0 as signal, so no printing of embedded objects is possible.

Attached patch (one-liner) should solve this issue.
Comment 1 Andreas Köhler 2006-02-28 19:46:59 UTC
Created attachment 60350 [details] [review]
First try
Comment 2 Chris Shoemaker 2006-03-19 04:34:00 UTC
I confirm that this patch does indeed enable the printing of embedded objects in gtkhtml 3.10.0.  Please commit.

Comment 3 Srinivasa Ragavan 2006-03-22 10:13:51 UTC
rohini:ping
Comment 4 Rohini 2006-03-22 11:02:32 UTC
Patch doesn't work when printing mail with textarea.
Comment 5 Andreas Köhler 2006-03-22 17:53:51 UTC
I would say this is another bug then.
Comment 6 André Klapper 2006-03-22 18:51:15 UTC
rohini: what "does not work"? is it getting worse (then we should not get the patch in), or does it remain as it was (then we should get it in asap)?
Comment 7 André Klapper 2006-03-22 18:57:57 UTC
uhm, sorry for changing the patch status, restoring the previous state.
seems like firefox's reload button did not update the dropdown menu.
Comment 8 Chris Shoemaker 2006-03-22 23:48:34 UTC
Are we all looking at the same patch?

Before patch:
g_signal_emit_by_name(GTK_OBJECT(embedded_widget), 0, "draw_print", 
   printer->context);

After patch:
g_signal_emit_by_name(G_OBJECT(embedded_widget), "draw_print", 
   printer->context);

I downloaded the GtkHtml source and tested this patch, not because I doubted the correctness, since it obviously fixes a typo, but because I wanted to see whether it would fix bug#327625, which it does.  

Surely a patch to pass the *signal-name* as the second argument of g_signal_emit_by_name() is uncontroversial!

Comment 9 Rohini 2006-03-23 03:31:35 UTC
Patch can be committed because it fixes a typo. But printing of embedded objects is still not possible. 

As suggested in comment 5, filed bug 335602.

Changing patch-status. 
Comment 10 André Klapper 2006-03-25 17:27:36 UTC
rohini: yeah, in evolution perhaps. that's evo's problem.
this is about gnucash. :-)
Comment 11 André Klapper 2006-03-25 17:52:18 UTC
committed both to cvs head and to gnome-2-14 branch:
http://cvs.gnome.org/viewcvs/gtkhtml/src/htmlprinter.c?r1=1.86&r2=1.87
http://cvs.gnome.org/viewcvs/gtkhtml/src/htmlprinter.c?r1=1.86&r2=1.86.2.1

patch will be included in gtkhtml-3.10.1 and gtkhtml-3.11.x.

thanks for the patch, closing as fixed.