>
> On 27.02.2010, at 16:04, manolo gouy wrote:
>
> >> To Matt: the fluid/image code will probably not help much, because it
> >> renders the image into an Fl_Offscreen first, and that's what we =
> don't
> >> want to do here. At least not with the device abstraction in place.
> >=20
> > What would be needed is help to build an X11 print dialog.
>
> If you can send me a picture of a sample dialog (or multiple with the =
> widgets marked that you want in your implementation), I'll be happy to =
> design such a box.
>
> - Matthias=
>
Many thanks Matt.
I have no precise layout idea, but a conceptual idea of what is needed.
The dialog should:
- select the desired printer (to start with, it could just use the
current default one)
- select the desired paper format
- select portrait/landscape
- ask for desired page range (all pages or frompage-topage)
This should be implemented in two functions of src/Fl_PS_Printer.cxx:
int Fl_PS_Printer::start_job(int pages, int *firstpage, int *lastpage) {
// TODO should start a print dialog
// create a temp file where PS output will go
// put temp file name in ps_filename_ member variable
// return page range to caller through arguments
return Fl_PSfile_Device::start_postscript_job(pages,format);
}
void Fl_PS_Printer::end_job(void)
{
Fl_PSfile_Device::end_job();
// TODO should print the ps_filename_ file and delete it
}
_______________________________________________
fltk-dev mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-dev