summaryrefslogtreecommitdiff
path: root/gtk/gtkprintoperation-unix.c
Commit message (Collapse)AuthorAgeFilesLines
* Better version of the previous patchMatthias Clasen2007-04-291-15/+13
| | | | svn path=/trunk/; revision=17712
* Don't leak a file descriptor, and don't make the error dialog modal.Mattthias Clasen2007-04-291-3/+2
| | | | | | | | | | | | | 2007-04-29 Mattthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c (_gtk_print_operation_platform_backend_launch_preview): Don't leak a file descriptor, and don't make the error dialog modal. (#421985, Morten Welinder) svn path=/trunk/; revision=17708
* Support passing a print settings file to the preview command. (#403717,Matthias Clasen2007-04-291-16/+57
| | | | | | | | | | | | | | | 2007-04-29 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c (_gtk_print_operation_platform_backend_launch_preview): Support passing a print settings file to the preview command. (#403717, Christian Persch) * gtk/gtksettings.c: Document %s in the gtk-print-preview-command setting. svn path=/trunk/; revision=17704
* Remove debug spewMatthias Clasen2007-03-221-2/+0
| | | | svn path=/trunk/; revision=17551
* Initialize the do_preview field of PrintResponseData. (#396703, ChristianMatthias Clasen2007-03-101-0/+2
| | | | | | | | | | | 2007-03-10 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c: Initialize the do_preview field of PrintResponseData. (#396703, Christian Persch) svn path=/trunk/; revision=17453
* Move a few settings to gtksettings.c to make sure they show up in theMatthias Clasen2006-12-311-30/+0
| | | | | | | | | | | | | | | 2006-12-30 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c: * gtk/gtkprintbackend.c: * gtk/gtkfilechooserdefault.c: * gtk/gtksettings.c: Move a few settings to gtksettings.c to make sure they show up in the docs. (#365364, Christian Persch) svn path=/trunk/; revision=16992
* Replace a lot of idle and timeout calls by the new gdk_threads api.Matthias Clasen2006-12-221-0/+3
| | | | | | | 2006-12-22 Matthias Clasen <mclasen@redhat.com> * *.c: Replace a lot of idle and timeout calls by the new gdk_threads api.
* Commit a patch by Behdad to fix typos, omissions and other errors in theMatthias Clasen2006-09-101-1/+1
| | | | | | | | 2006-09-10 Matthias Clasen <mclasen@redhat.com> * Commit a patch by Behdad to fix typos, omissions and other errors in the symbol aliasing, and add checks for local PLT entries. (#354687, Behdad Esfahbod)
* Don't specify explicit format capabilities. (#346505, Christian Persch)Matthias Clasen2006-08-311-3/+1
| | | | | | | 2006-08-31 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c (get_print_dialog): Don't specify explicit format capabilities. (#346505, Christian Persch)
* Fix some typos with inline property docs. (#347065, John Finlay)Matthias Clasen2006-07-101-1/+1
| | | | | | | | | | | | 2006-07-10 Matthias Clasen <mclasen@redhat.com> * gtk/gtkaction.c: * gtk/gtkiconview.c: * gtk/gtkprintbackend.c: * gtk/gtkprintoperation-unix.c: * gtk/gtkscrolledwindow.c: * gtk/gtktoolbar.c: Fix some typos with inline property docs. (#347065, John Finlay)
* Add a preview capabilityMatthias Clasen2006-06-301-1/+2
|
* Apply a patch by John Palmieri to use buffered io using GIOChannels, cleanMatthias Clasen2006-06-211-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2006-06-21 Matthias Clasen <mclasen@redhat.com> Apply a patch by John Palmieri to use buffered io using GIOChannels, clean up error handling and support Cups 1.2 api in the printing code. * acconfig.h: * configure.in: Detect Cups 1.2 * gtk/gtkdebug.h: * gtk/gtkmain.c: Add a printing debug key. * gtk/gtkprintbackend.[hc]: Remove the GError parameter from gtk_print_backend_print_stream, and take a GIOChannel instead of an fd. * gtk/gtkprinter-private.h: * gtk/gtkprinter.c: Replace the fd parameter of _gtk_printer_create_cairo_surface by a GIOChannel. * gtk/gtkprintjob.[hc]: Remove the GError parameter from gtk_print_job_send and make it return void. * gtk/gtkprintoperation-unix.c: * gtk/gtkprintjob.c: Adjust callers, add some debugging support. * modules/printbackends/Makefile.am: Fix DIST_SUBDIRS. * modules/printbackends/cups/Makefile.am: * modules/printbackends/lpr/Makefile.am: Add debug CFLAGS. * modules/printbackends/cups/gtkcupsutils.[hc]: * modules/printbackends/cups/gtkprintbackendcups.c: * modules/printbackends/file/gtkprintbackendfile.c: * modules/printbackends/lpr/gtkprintbackendfile.c: Adapt to the GIOChannel and GError changes, add debug output
* Another forgotten change.Matthias Clasen2006-06-191-1/+2
|
* Require cvs glib.Matthias Clasen2006-06-161-14/+49
| | | | | | | | | | | | | 2006-06-16 Matthias Clasen <mclasen@redhat.com> * configure.in: Require cvs glib. * gtk/gtkprintoperation-unix.c: (_gtk_print_operation_platform_backend_create_preview_surface): Don't use a temporary directory for preview files, since it is not clear who cleans it up. Instead, use g_mkstemp() directly to create a temp pdf file, and make the preview app responsible for cleaning it up.
* Move the registration of the gtk-print-preview-command setting fromMatthias Clasen2006-06-161-0/+31
| | | | | | | | | | 2006-06-16 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c: * gtk/gtkprintbackend.c: Move the registration of the gtk-print-preview-command setting from gtkprintbackend.c to gtkprintoperation-unix.c, to make sure it is registered before the first use. Also, document the two settings.
* When starting a preview from the print dialog, set the action to PREVIEW.Matthias Clasen2006-06-161-0/+2
| | | | | | | | | 2006-06-16 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c (handle_print_response): When starting a preview from the print dialog, set the action to PREVIEW. * gtk/gtkprintoperation.c: Cosmetic changes.
* Mark preview filename as translatable.Matthias Clasen2006-06-161-3/+4
|
* make print-to-pdf show up againMatthias Clasen2006-06-161-2/+4
|
* Fix bug 344518Matthias Clasen2006-06-111-1/+3
|
* Don't include gtkprinter-private.h here.Matthias Clasen2006-06-081-0/+1
| | | | | | | | | | | | | | | 2006-06-08 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintbackend.h: Don't include gtkprinter-private.h here. * gtk/gtkprintunixdialog.c: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintjob.c: * gtk/gtkprintbackend.c: Instead include it here. * gtk/gtk.symbols: * gtk/gtkprintoperation.h: * gtk/gtkprintoperation.c: Rename pdf_target to export_filename.
* Get rid of GTK_PRINT_OPERATION_RESULT_PREVIEW.Matthias Clasen2006-06-081-12/+12
| | | | | | | | | | 2006-06-08 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation.h (GtkPrintOperationResult): Get rid of GTK_PRINT_OPERATION_RESULT_PREVIEW. * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation.c: Update all users.
* Fix up unix fallout from previous change.Alexander Larsson2006-06-081-2/+2
| | | | | | | 2006-06-08 Alexander Larsson <alexl@redhat.com> * gtk/gtkprintoperation-unix.c (finish_print): Fix up unix fallout from previous change.
* Update windows to build with new APIs and first cut at preview work.Alexander Larsson2006-06-081-2/+33
| | | | | | | | | | | | | | | | 2006-06-08 Alexander Larsson <alexl@redhat.com> * gtk/gtkprintoperation-win32.c: Update windows to build with new APIs and first cut at preview work. * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation.c Various updates needed when making the preview work on win32. * tests/print-editor.c: Print, don't preview.
* Clean up APIs: Make async a setting instead of separate calls. CombineAlexander Larsson2006-06-071-19/+10
| | | | | | | | | | | | | | | | | | | 2006-06-07 Alexander Larsson <alexl@redhat.com> * gtk/gtk.symbols: * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation.[ch]: Clean up APIs: Make async a setting instead of separate calls. Combine settings like show_dialog, show_preview and pdf_target into an action enum that you pass to gtk_print_dialog_run(). * tests/print-editor.c: * tests/testnouiprint.c: * tests/testprint.c: * demos/gtk-demo/printing.c: Update to new APIs
* Add a GtkPrintOperation::show-preview propertyMatthias Clasen2006-06-031-3/+9
|
* CleanupsMatthias Clasen2006-06-031-64/+65
|
* Add gtkprintoperationpreview.[ch] Set default preview command. HardcodedAlexander Larsson2006-06-021-66/+234
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2006-06-02 Alexander Larsson <alexl@redhat.com> * gtk/Makefile.am: Add gtkprintoperationpreview.[ch] Set default preview command. Hardcoded for now. * gtk/gtkmarshalers.list: Add BOOLEAN:OBJECT,OBJECT,OBJECT * gtk/gtkprintbackend.c: Add preview command property. * gtk/gtkprintcontext.[ch]: Make less dependent on PrintOperation for output settings Externally set cairo_t and dpi. Resettable. Create fontmap without metrics hinting (so that print preview text layout doesn't depend on zoom level). * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation.[ch]: Initial work on print preview API and default implementation using an external preview app. * gtk/gtkprintoperation-win32.c: Some needed updates. Not done, needs more work. * gtk/gtkprintoperationpreview.[ch]: New interface used in print preview api. * gtk/gtkprintunixdialog.c: Add print preview dialog. * tests/print-editor.c: Test using an custom print preview widget.
* bits from the preview patchMatthias Clasen2006-06-011-1/+1
|
* use canonical signal namesMatthias Clasen2006-06-011-1/+1
|
* Change some function names to be longer and better.Matthias Clasen2006-05-311-1/+1
| | | | | | | | | | | | | | | 2006-05-31 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintcontext.h: * gtk/gtkprintcontext.c: * gtk/gtkprintoperation.c: * gtk/gtkprintoperation-unix.c: Change some function names to be longer and better. gtk_print_context_get_cairo -> gtk_print_context_get_cairo_context gtk_print_context_get_fontmap -> gtk_print_context_get_pango_fontmap gtk_print_context_create_context -> gtk_print_context_create_pango_context gtk_print_context_create_layout -> gtk_print_context_create_pango_layout Update all callers.
* Custom tab labelMatthias Clasen2006-05-241-13/+19
|
* Add gtk_print_unix_dialog_set_manual_capabilities that controls whatAlexander Larsson2006-05-241-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | 2006-05-24 Alexander Larsson <alexl@redhat.com> * gtk/gtk.symbols: * gtk/gtkprintunixdialog.[ch]: Add gtk_print_unix_dialog_set_manual_capabilities that controls what widgets to enable in the dialog depending on the apps capabilities. * gtk/gtkprintbackend.[ch]: * gtk/gtkprinter-private.h: * gtk/gtkprinter.c: * gtk/gtkprintjob.h: Add printer_get_capabilities to backend. Move some fallback calls to the printbackend base class. * gtk/gtkprintoperation-unix.c: Set manual capabilities * modules/printbackends/cups/gtkprintbackendcups.c: Implement get_capabilities * modules/printbackends/lpr/gtkprintbackendlpr.c: * modules/printbackends/pdf/gtkprintbackendpdf.c: Move some methods to baseclass.
* Add a boolean show-progress property, and show a progress dialog if it isMatthias Clasen2006-05-231-2/+6
| | | | | | | | | | | | | | | | 2006-05-23 Matthias Clasen <mclasen@redhat.com> * gtk/gtk.symbols: * gtk/gtkprintoperation.h: * gtk/gtkprintoperation.c: Add a boolean show-progress property, and show a progress dialog if it is set to TRUE. * gtk/gtkprintoperation.c (pdf_end_run): * gtk/gtkprintoperation-win32.c (win32_end_run): * gtk/gtkprintoperation-unix.c (unix_end_run): * gtk/gtkprintoperation-private.h: Add a cancelled parameter to end_run, and call it even if the print operation was cancelled.
* Add gtk_print_unix_dialog_add_custom_tabAlexander Larsson2006-05-231-1/+22
| | | | | | | | | | | | | | | 2006-05-23 Alexander Larsson <alexl@redhat.com> * gtk/gtk.symbols: * gtk/gtkprintunixdialog.[ch]: Add gtk_print_unix_dialog_add_custom_tab * gtk/gtkprintoperation-unix.c: Implement custom widgets for unix. Fix some warnings by including cairo-ps/pdf.h * gtk/gtkprintoperation-win32.c: Mark string for translation.
* Added gtk_print_job_set/get_track_print_statusAlexander Larsson2006-05-151-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | 2006-05-15 Alexander Larsson <alexl@redhat.com> * gtk/gtkprintjob.[ch]: Added gtk_print_job_set/get_track_print_status * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation.[ch]: Add gtk_print_operation_set_track_print_status. * gtk/gtkprintoperation-unix.c: Implement track_print_status on unix * gtk/gtkprintoperation-win32.c: Implement track_print_status on win32 * gtk/gtk.symbols: Added symbols * modules/printbackends/cups/gtkprintbackendcups.c: Implement track_print_status for cups * tests/print-editor.c: Test track_print_status.
* Implement per-page paper sizes.Alexander Larsson2006-05-051-0/+14
| | | | | | | | | | | | | | | | | | 2006-05-05 Alexander Larsson <alexl@redhat.com> * gtk/gtkprintoperation-unix.c: Implement per-page paper sizes. * gtk/gtkprintoperation.c: Implement per-page paper sizes for pdf output. Make gtk_print_operation_set_pdf_target() work again * tests/Makefile.am: * tests/testprint.c: * tests/testprintfileoperation.[ch]: Add more test code for printing support. This tests per-page paper sizes & orientation and deriving from GtkPrintOperation.
* Added new symbolsAlexander Larsson2006-05-041-42/+343
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2006-05-04 Alexander Larsson <alexl@redhat.com> * gtk/gtk.symbols: Added new symbols * gtk/gtkpagesetupunixdialog.c: * gtk/gtkprintunixdialog.c: Destroy backends when finalizing dialogs. Fix printer leak in selected_printer_changed. * gtk/gtkprintbackend.[ch]: Convert from interface to baseclass. Move printer hashtable here so that the baseclass can handle the slightly complicated ownership model. Add gtk_print_backend_destroy which runs the dispose method, causing the ref-cycles between the backend and its printers to be broken. Add gtk_print_backend_unref_at_idle(). * gtk/gtkprinter.[ch]: GtkPrinter objects now ref their backend so that its always availible, since its needed for the printer object to work. This causes a reference-cycle that is broken using gtk_print_backend_destroy. Add gtk_printer_compare. * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation.c: Implement !show_dialog for unix. Make sure the print data is fully spooled before returning from a sync run_dialog. * modules/printbackends/cups/gtkcupsutils.[ch]: Add gtk_cups_request_ipp_add_strings * modules/printbackends/cups/gtkprintbackendcups.c: * modules/printbackends/cups/gtkprintercups.c: * modules/printbackends/lpr/gtkprintbackendlpr.c: * modules/printbackends/pdf/gtkprintbackendpdf.c: Convert backends to derive instead of implementing interface. Move common code into baseclass. CUPS: Remove the printer polling in dispose, not finalize. In the cups watch, remove the backend at idle instead of immediately, since the unref can cause the module to be unloaded. Limit the number of printer attributes requested Get printer uri in initial printer listing so that we can use the printer object immediately. * tests/Makefile.am: * tests/testnouiprint.c: Add testcase for !show_dialog.
* Don't use gtk_dialog_run for the error dialog, and improve the dialog inBEFORE_FEDERICO_FILENAME_ENTRY_MERGEMatthias Clasen2006-05-031-9/+13
| | | | | | | | 2006-05-03 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c (unix_finish_send): Don't use gtk_dialog_run for the error dialog, and improve the dialog in other ways. (#340510, Christian Persch)
* Use a priv variable when accessing priv multiple times in the sameChristian Persch2006-05-021-25/+24
| | | | | | | | | | | | | | 2006-05-02 Christian Persch <chpe@cvs.gnome.org> * gtk/gtkpagesetupunixdialog.c: * gtk/gtkprintcontext.c: * gtk/gtkprinter.c: * gtk/gtkprinteroptionwidget.c: * gtk/gtkprintjob.c: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation.c: * gtk/gtkprintunixdialog.c: Use a priv variable when accessing priv multiple times in the same function. Bug #340288.
* forgotten filesMatthias Clasen2006-04-241-6/+4
|
* Refactor the gtk_print_operation_run() code and add an _async version.Matthias Clasen2006-04-241-53/+239
| | | | | | | | | | | | | | | | | | | 2006-04-24 Matthias Clasen <mclasen@redhat.com> * gtk/gtk.symbols: * gtk/gtkprintoperation.c (gtk_print_operation_run_async): Refactor the gtk_print_operation_run() code and add an _async version. * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation-unix.c (_gtk_print_operation_platform_backend_run_dialog_async) (gtk_print_run_page_setup_dialog_async): Variants of the run functions which don't call gtk_dialog_run(), but only show the dialog and return, and handle the response in a signal handler. * gtk/gtkprintoperation-win32.c (gtk_print_run_page_setup_dialog_async) (_gtk_print_operation_platform_backend_run_dialog_async): Implement these by calling the sync versions.
* CleanupsMatthias Clasen2006-04-241-11/+12
|
* Return a copy of the original page setup if the dialog was canceled.Matthias Clasen2006-04-241-5/+11
| | | | | | | 2006-04-24 Matthias Clasen <mclasen@redhat.com> * gtk/gtkprintoperation-unix.c (gtk_print_run_page_setup_dialog): Return a copy of the original page setup if the dialog was canceled.
* Match parameter names with the headers.Matthias Clasen2006-04-241-0/+16
| | | | | | | | | | | | | | | | | | | 2006-04-24 Matthias Clasen <mclasen@redhat.com> * gtk/gtkclipboard.h: * gtk/gtkprinter.c: * gtk/gtkprintsettings.h: * gtk/gtkprintsettings.c: Match parameter names with the headers. * gtk/gtkprintoperation-unix.c (gtk_print_run_page_setup_dialog): Add docs. * gtk/gtktextbufferrichtext.c (gtk_text_buffer_deserialize): * gtk/gtkstatusicon.c (gtk_status_icon_get_storage_type): * gtk/gtktreeview.c (gtk_tree_view_set_search_position_func): * gtk/gtktreeview.c (gtk_tree_view_get_headers_clickable): * gtk/gtkcellrendererspin.c (gtk_cell_renderer_spin_new): * gtk/gtkmenu.c (gtk_menu_get_for_attach_widget): Fix the docs.
* Merge the gtk-printing branch. For more detailed ChangeLog entries, seeAlexander Larsson2006-04-211-0/+243
2006-04-21 Alexander Larsson <alexl@redhat.com> Merge the gtk-printing branch. For more detailed ChangeLog entries, see the branch. * .cvsignore: * Makefile.am: * configure.in: * docs/tools/widgets.c: * gtk+-unix-print-2.0.pc.in: * gtk/Makefile.am: * gtk/gen-paper-names.c: * gtk/gtk.h: * gtk/gtk.symbols: * gtk/gtkenums.h: * gtk/gtkiconfactory.c: * gtk/gtkmarshalers.list: * gtk/gtkpagesetup.[ch]: * gtk/gtkpagesetupunixdialog.[ch]: * gtk/gtkpapersize.[ch]: * gtk/gtkprint-win32.[ch]: * gtk/gtkprintbackend.[ch]: * gtk/gtkprintcontext.[ch]: * gtk/gtkprinter-private.h: * gtk/gtkprinter.[ch]: * gtk/gtkprinteroption.[ch]: * gtk/gtkprinteroptionset.[ch]: * gtk/gtkprinteroptionwidget.[ch]: * gtk/gtkprintjob.[ch]: * gtk/gtkprintoperation-private.h: * gtk/gtkprintoperation-unix.c: * gtk/gtkprintoperation-win32.c: * gtk/gtkprintoperation.[ch]: * gtk/gtkprintsettings.[ch]: * gtk/gtkprintunixdialog.[ch]: * gtk/paper_names.c: * gtk/paper_names_offsets.c: Platform independent printing API and implementations for unix and windows. * gtk/gtkstock.h: * gtk/stock-icons/24/gtk-orientation-landscape.png: * gtk/stock-icons/24/gtk-orientation-portrait.png: * gtk/stock-icons/24/gtk-orientation-reverse-landscape.png: Add stock icons for page orientation. * modules/Makefile.am: * modules/printbackends/Makefile.am: * modules/printbackends/cups/Makefile.am: * modules/printbackends/cups/gtkcupsutils.[ch]: * modules/printbackends/cups/gtkprintbackendcups.[ch]: * modules/printbackends/cups/gtkprintercups.[ch]: Cups printing backend for unix. * modules/printbackends/lpr/Makefile.am: * modules/printbackends/lpr/gtkprintbackendlpr.[ch]: lpr printing backend for unix. * modules/printbackends/pdf/Makefile.am: * modules/printbackends/pdf/gtkprintbackendpdf.[ch]: print-to-pdf printing backend for unix. * tests/.cvsignore: * tests/Makefile.am: * tests/print-editor.c: Test application for printing. * gdk/gdk.symbols: * gdk/win32/gdkevents-win32.c: * gdk/win32/gdkwin32.h: Add gdk_win32_set_modal_dialog_libgtk_only so that we can pump the mainloop while displaying a win32 common dialog. * gdk/directfb/Makefile.am: Whitespace cleanup.